|
|
A238531
|
|
Expansion of (1 - x + x^2)^2 / (1 - x)^3 in powers of x.
|
|
2
|
|
|
1, 1, 3, 5, 8, 12, 17, 23, 30, 38, 47, 57, 68, 80, 93, 107, 122, 138, 155, 173, 192, 212, 233, 255, 278, 302, 327, 353, 380, 408, 437, 467, 498, 530, 563, 597, 632, 668, 705, 743, 782, 822, 863, 905, 948, 992, 1037, 1083, 1130, 1178, 1227, 1277, 1328, 1380
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,3
|
|
COMMENTS
|
|
|
LINKS
|
|
|
FORMULA
|
Euler transform of length 6 sequence [1, 2, 2, 0, 0, -2].
Binomial transform of [1, 0, 2, -2, 3, -4, 5, -6, ...].
a(n) = p(-1) where p(x) is the unique degree-n polynomial such that p(k) = a(k) for k = 0, 1, ..., n.
G.f.: (1 - x + x^2)^2 / (1 - x)^3.
a(n) = a(1 - n) for all n in Z.
a(n + 1) = A133263(n) if n>=0. a(n) = (n^2 - n) / 2 + 2 unless n=0 or n=1.
(1 + x^2 + x^3 + x^4 + ...)*(1 + x + 2x^2 + 3x^3 + 4x^4 + ...) = (1 + x + 3x^2 + 5x^3 + 8x^4 + 12x^5 + ...). - Gary W. Adamson, Jul 27 2010
|
|
EXAMPLE
|
G.f. = 1 + x + 3*x^2 + 5*x^3 + 8*x^4 + 12*x^5 + 17*x^6 + 23*x^7 + 30*x^8 + ...
|
|
MATHEMATICA
|
a[ n_] := (n^2 - n) / 2 + If[ n == 0 || n == 1, 1, 2];
CoefficientList[Series[(1-x+x^2)^2/(1-x)^3, {x, 0, 50}], x] (* G. C. Greubel, Aug 07 2018 *)
|
|
PROG
|
(PARI) {a(n) = (n^2 - n) / 2 + 2 - (n==0) - (n==1)};
(PARI) {a(n) = if( n<0, n = 1-n); polcoeff( (1 - x + x^2)^2 / (1 - x)^3 + x * O(x^n), n)};
(Magma) m:=50; R<x>:=PowerSeriesRing(Integers(), m); Coefficients(R!((1-x+x^2)^2/(1-x)^3)); // G. C. Greubel, Aug 07 2018
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,easy
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|