OFFSET
1,12
LINKS
Wikipedia, Integer Triangle
FORMULA
a(n) = Sum_{k=1..floor(n/3)} Sum_{i=k..floor((n-k)/2)} (i^2 + k^2 + (n-i-k)^2) * m * (1 - ceiling(m) + floor(m)) * sign(floor((i+k)/(n-i-k+1))), where m = sqrt((n/2)*(n/2-i)*(n/2-k)*(i+k-n/2)).
MATHEMATICA
Table[Sum[Sum[(i^2 + k^2 + (n - i - k)^2 + Sqrt[(n/2) (n/2 - i) (n/2 - k) (i + k - n/2)]) (1 - Ceiling[Sqrt[(n/2) (n/2 - i) (n/2 - k) (i + k - n/2)]] + Floor[Sqrt[(n/2) (n/2 - i) (n/2 - k) (i + k - n/2)]])*Sign[Floor[(i + k)/(n - i - k + 1)]], {i, k, Floor[(n - k)/2]}], {k, Floor[n/3]}], {n, 100}]
CROSSREFS
KEYWORD
nonn
AUTHOR
Wesley Ivan Hurt, May 12 2019
STATUS
approved