OFFSET
0,4
COMMENTS
Partial sums of A001971.
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 0..5000
Mircea Merca, Inequalities and Identities Involving Sums of Integer Functions J. Integer Sequences, Vol. 14 (2011), Article 11.9.1.
Index entries for linear recurrences with constant coefficients, signature (3,-3,1,1,-3,3,-1).
FORMULA
a(n) = Sum_{k=0..n} round(k^2/8).
a(n) = round((2*n^3+3*n^2+4*n)/48).
a(n) = round((2*n+1)*(2*n^2+2*n+3)/96).
a(n) = floor((n+2)*(2*n^2-n+6)/48).
a(n) = ceiling((2*n^3+3*n^2+4*n-9)/48).
a(n) = a(n-4)+n*(n-3)/2+2, n>3.
G.f.: x^2*(1-x+x^2) / ( (1+x)*(x^2+1)*(x-1)^4 ). - R. J. Mathar, Nov 26 2010
a(n) = 3*(-1)^n/32+n^2/16+n/12+n^3/24+1/32-A057077(n)/8. - R. J. Mathar, Nov 26 2010
EXAMPLE
a(5) = round(1/8) + round(4/8) + round(9/8) + round(16/8) + round(25/8) = 0 + 1 + 1 + 2 + 3 = 7.
MAPLE
A057077 := proc(n) op( 1+(n mod 4), [1, 1, -1, -1]) ; end proc:
seq(A173722(n), n=0..80) ; # R. J. Mathar, Nov 26 2010
MATHEMATICA
Table[Floor[(n + 2)*(2*n^2 - n + 6)/48], {n, 0, 50}] (* G. C. Greubel, Nov 29 2016 *)
PROG
(PARI) a(n)=(n+2)*(2*n^2-n+6)\48 \\ Charles R Greathouse IV, Oct 19 2022
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Mircea Merca, Nov 26 2010
STATUS
approved