login
A308515
Take all the integer-sided triangles with perimeter n and side lengths a, b and c such that a <= b <= c and c is prime. a(n) is the sum of all the b's.
0
0, 0, 0, 0, 2, 2, 5, 3, 3, 0, 12, 9, 9, 5, 27, 18, 18, 13, 13, 7, 7, 0, 51, 45, 45, 38, 108, 93, 93, 76, 76, 57, 57, 36, 153, 133, 133, 111, 256, 222, 222, 199, 199, 174, 174, 147, 357, 316, 316, 272, 272, 225, 225, 193, 193, 159, 159, 123, 453, 420, 420
OFFSET
1,5
FORMULA
a(n) = Sum_{k=1..floor(n/3)} Sum_{i=k..floor((n-k)/2)} sign(floor((i+k)/(n-i-k+1))) * A010051(n-i-k) * i.
MATHEMATICA
Table[Sum[Sum[i (PrimePi[n - i - k] - PrimePi[n - i - k - 1]) Sign[Floor[(i + k)/(n - i - k + 1)]], {i, k, Floor[(n - k)/2]}], {k, Floor[n/3]}], {n, 100}]
CROSSREFS
Sequence in context: A258803 A157495 A308143 * A361328 A128134 A157223
KEYWORD
nonn
AUTHOR
Wesley Ivan Hurt, Jun 03 2019
STATUS
approved