OFFSET
0,3
LINKS
OEIS Wiki, Figurate numbers
Eric Weisstein's World of Mathematics, Pyramidal Number
Index entries for linear recurrences with constant coefficients, signature (-3,-2,2,3,1).
FORMULA
G.f.: x*(1 - 7*x)/((x - 1)*(x + 1)^4).
a(n) = ((-1)^n*(16*n^3 + 30*n^2 - 4*n - 9) + 9) /24.
a(n) = Sum_{k = 0..n} (-1)^k*A007585(k).
Sum_{n>=1} 1/a(n) = -0.9251958836055717745244669... . - Vaclav Kotesovec, Feb 26 2016
MATHEMATICA
Table[((-1)^n (16 n^3 + 30 n^2 - 4 n - 9) + 9)/24, {n, 0, 40}]
LinearRecurrence[{-3, -2, 2, 3, 1}, {0, -1, 10, -28, 62}, 41]
PROG
(Magma) [((-1)^n*(16*n^3+30*n^2-4*n-9)+9)/24: n in [0..40]]; // Vincenzo Librandi, Feb 27 2016
CROSSREFS
KEYWORD
easy,sign
AUTHOR
Ilya Gutkovskiy, Feb 26 2016
STATUS
approved