|
|
A266085
|
|
Alternating sum of heptagonal numbers.
|
|
2
|
|
|
0, -1, 6, -12, 22, -33, 48, -64, 84, -105, 130, -156, 186, -217, 252, -288, 328, -369, 414, -460, 510, -561, 616, -672, 732, -793, 858, -924, 994, -1065, 1140, -1216, 1296, -1377, 1462, -1548, 1638, -1729, 1824, -1920, 2020, -2121, 2226, -2332, 2442, -2553
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,3
|
|
LINKS
|
|
|
FORMULA
|
G.f.: -x*(1 - 4*x)/((1 - x)*(1 + x)^3).
a(n) = ((10*n^2 + 4*n - 3)*(-1)^n + 3)/8.
a(n) = Sum_{k = 0..n} (-1)^k*A000566(k).
Lim_{n -> infinity} a(n + 1)/a(n) = -1.
E.g.f.: (1/8)*exp(-x)*(-3 + 3*exp(2*x) - 14*x + 10*x^2). - Stefano Spezia, Nov 13 2019
|
|
MATHEMATICA
|
Table[((10 n^2 + 4 n - 3) (-1)^n + 3)/8, {n, 0, 50}]
CoefficientList[Series[(x - 4 x^2)/(x^4 + 2 x^3 - 2 x - 1), {x, 0, 50}], x] (* Vincenzo Librandi, Dec 21 2015 *)
LinearRecurrence[{-2, 0, 2, 1}, {0, -1, 6, -12}, 60] (* Harvey P. Dale, Jan 26 2023 *)
|
|
PROG
|
(Magma) [((10*n^2+4*n-3)*(-1)^n+3)/8: n in [0..50]]; // Vincenzo Librandi, Dec 21 2015
(Magma) R<x>:=PowerSeriesRing(Integers(), 50); [0] cat Coefficients(R!(-x*(1 - 4*x)/((1 - x)*(1 + x)^3))); // Marius A. Burtea, Nov 13 2019
(PARI) x='x+O('x^100); concat(0, Vec(-x*(1-4*x)/((1-x)*(1+x)^3))) \\ Altug Alkan, Dec 21 2015
|
|
CROSSREFS
|
|
|
KEYWORD
|
sign,easy
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|