login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 


A145067
Zero followed by partial sums of A008865.
3
0, -1, 1, 8, 22, 45, 79, 126, 188, 267, 365, 484, 626, 793, 987, 1210, 1464, 1751, 2073, 2432, 2830, 3269, 3751, 4278, 4852, 5475, 6149, 6876, 7658, 8497, 9395, 10354, 11376, 12463, 13617, 14840, 16134, 17501, 18943, 20462, 22060, 23739, 25501
OFFSET
1,4
FORMULA
a(1) = 0; a(n) = a(n-1) + (n-1)^2 - 2 for n > 0.
a(n) = Sum_{k=1...n-1} (k^2-2) = A000330(n-1)-2*A000027(n-1) = (n-1)*(2*n^2-n-12)/6. - Christoph Pacher (christoph.pacher(AT)ait.ac.at), Jul 23 2010
G.f.: -x^2*(1-5*x+2*x^2)/(1-x)^4. - Colin Barker, Apr 04 2012
EXAMPLE
a(2) = a(1) + 1^2 - 2 = 0 + 1 - 2 = -1; a(3) = a(2) + 2^2 - 2 = -1 + 4 - 2 = 1.
MATHEMATICA
lst={0}; s=0; Do[s+=n^2 - 2; AppendTo[lst, s], {n, 5!}]; lst
Table[Sum[(i^2 + n - 1), {i, 0, n}], {n, -1, 41}] (* Zerinvary Lajos, Jul 11 2009 *)
Join[{0}, Accumulate[Range[50]^2-2]] (* Harvey P. Dale, Jul 23 2018 *)
PROG
(PARI) {a=2; for(n=0, 42, print1(a=a+n^2-2, ", "))}
CROSSREFS
Cf. A008865 (n^2 - 2), A002522 (n^2 + 1), A145066 (partial sums of A002522, starting at n=1), A005563 ((n+1)^2 - 1), A051925 (zero followed by partial sums of A005563), A000330.
Sequence in context: A211529 A069099 A172473 * A112684 A189584 A239360
KEYWORD
sign,easy
AUTHOR
EXTENSIONS
Edited by Klaus Brockhaus, Oct 17 2008
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified September 24 07:53 EDT 2024. Contains 376188 sequences. (Running on oeis4.)