|
|
A173707
|
|
Partial sums of floor(n^3/3).
|
|
1
|
|
|
0, 0, 2, 11, 32, 73, 145, 259, 429, 672, 1005, 1448, 2024, 2756, 3670, 4795, 6160, 7797, 9741, 12027, 14693, 17780, 21329, 25384, 29992, 35200, 41058, 47619, 54936, 63065, 72065, 81995, 92917, 104896, 117997, 132288, 147840, 164724, 183014, 202787, 224120, 247093, 271789, 298291, 326685, 357060, 389505, 424112, 460976, 500192, 541858
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,3
|
|
COMMENTS
|
|
|
LINKS
|
|
|
FORMULA
|
a(n) = Sum_{k=0..n} floor(k^3/3).
a(n) = round((n^4 + 2*n^3 + n^2 - 4*n)/12).
a(n) = round((n^4 + 2*n^3 + n^2 - 4*n - 2)/12).
a(n) = floor((n^4 + 2*n^3 + n^2 - 4*n)/12).
a(n) = ceiling((n+1)*(n^3 + n^2 - 4)/12).
a(n) = a(n-3) + n^3 - 3*n^2 + 5*n - 4, n > 2.
G.f.: x^2*(2 + 3*x + x^3) / ( (1+x+x^2)*(1-x)^5 ).
a(n) = n^4/12 + n^3/6 + n^2/12 - n/3 - 1/9 + A061347(n+1)/9. (End)
|
|
EXAMPLE
|
a(4) = floor(1/3) + floor(8/3) + floor(27/3) + floor(64/3) = 32.
|
|
MAPLE
|
A061347 := proc(n) op(1+(n mod 3), [-2, 1, 1]) ; end proc:
A173707 := proc(n) n^4/12+n^3/6+n^2/12-n/3-1/9 ; %+A061347(n+1)/9 ; end proc:
# program replaced by a structured version by R. J. Mathar, Nov 26 2010
|
|
MATHEMATICA
|
Table[Sum[Floor[k^3/3], {k, 0, n}], {n, 0, 60}] (* G. C. Greubel, Nov 23 2016 *)
Accumulate[Table[Floor[n^3/3], {n, 0, 60}]] (* or *) LinearRecurrence[{4, -6, 5, -5, 6, -4, 1}, {0, 0, 2, 11, 32, 73, 145}, 60] (* Harvey P. Dale, May 29 2018 *)
|
|
PROG
|
(Magma) [Floor((n^4+2*n^3+n^2-4*n)/12): n in [0..60]]; // Vincenzo Librandi, May 08 2011
(Sage) [floor(n*(n^3 +2*n^2 +n -4)/12) for n in (0..60)] # G. C. Greubel, Jul 02 2019
(Python)
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,easy
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|