|
|
A050409
|
|
Truncated square pyramid numbers: a(n) = Sum_{k = n..2*n} k^2.
|
|
13
|
|
|
0, 5, 29, 86, 190, 355, 595, 924, 1356, 1905, 2585, 3410, 4394, 5551, 6895, 8440, 10200, 12189, 14421, 16910, 19670, 22715, 26059, 29716, 33700, 38025, 42705, 47754, 53186, 59015, 65255, 71920, 79024, 86581, 94605, 103110, 112110, 121619
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,2
|
|
LINKS
|
|
|
FORMULA
|
a(n) = n*(n+1)*(14*n+1)/6.
G.f.: x*(5+9*x)/(1-x)^4.
E.g.f.: x*(30 + 57*x + 14*x^2)*exp(x)/6. - G. C. Greubel, Oct 30 2019
|
|
MAPLE
|
|
|
MATHEMATICA
|
LinearRecurrence[{4, -6, 4, -1}, {0, 5, 29, 86}, 40] (* Vincenzo Librandi, Jun 22 2012 *)
Table[(n(n+1)(14n+1))/6, {n, 0, 40}] (* Harvey P. Dale, Mar 08 2020 *)
|
|
PROG
|
(Magma) [&+[k^2: k in [n..2*n]]: n in [0..40]]; // Bruno Berselli, Feb 11 2011
(Magma) I:=[0, 5, 29, 86]; [n le 4 select I[n] else 4*Self(n-1)-6*Self(n-2)+4*Self(n-3)-Self(n-4): n in [1..40]]; // Vincenzo Librandi, Jun 22 2012
(PARI) a(n)=sum(k=n, n+n, k^2)
(PARI) vector(40, n, n*(n-1)*(14*n-13)/6) \\ G. C. Greubel, Oct 30 2019
(Sage) [n*(n+1)*(14*n+1)/6 for n in (0..40)] # G. C. Greubel, Oct 30 2019
(GAP) List([0..40], n-> n*(n+1)*(14*n+1)/6); # G. C. Greubel, Oct 30 2019
|
|
CROSSREFS
|
Cf. A304993: Sum_{k = n..2*n} k*(k+1)/2.
|
|
KEYWORD
|
nonn,easy,nice
|
|
AUTHOR
|
Klaus Strassburger (strass(AT)ddfi.uni-duesseldorf.de), Dec 22 1999
|
|
STATUS
|
approved
|
|
|
|