OFFSET
0,2
COMMENTS
An autosequence of the first kind is a sequence whose main diagonal in the difference table is A000004 = 0's.
This is the case for a(n).
Difference table of a(n):
0, 2, 2, 3, 4, 5, ...
2, 0, 1, 1, 1, 1, ...
-2, 1, 0, 0, 0, 0, ...
3, -1, 0, 0, 0, 0, ...
-4, 1, 0, 0, 0, 0, ...
5, -1, 0, 0, 0, 0, ...
etc.
The inverse binomial transform of a(n) is (-1)^(n+1)*a(n).
What is the meaning of a(n)?
Among many others, A015441 is an autosequence of the first kind.
General form for such autosequence.
Starting from the first upper diagonal s0, s1, s2, s3, s4, ...,
the autosequence is
0, s0, s0, s0 + s1, s0 + 2*s1, s0 + 3*s1 + s2, s0 + 4*s1 + 3*s2, ... .
After 0, the corresponding coefficients are A011973(n).
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..2500
Index entries for linear recurrences with constant coefficients, signature (2,-1).
FORMULA
G.f.: (2*x - 2*x^2 + x^3) / (1 - x)^2. - Michael Somos, Feb 09 2015
EXAMPLE
G.f. = 2*x + 2*x^2 + 3*x^3 + 4*x^4 + 5*x^5 + 6*x^6 + 7*x^7 + 8*x^8 + ...
MATHEMATICA
CoefficientList[Series[(2*x-2*x^2+x^3)/(1-x)^2, {x, 0, 60}], x] (* G. C. Greubel, Aug 03 2018 *)
a[ n_] := n + Boole[n == 1]; (* Michael Somos, Aug 19 2018 *)
Join[{0, 2}, Range[2, 70]] (* Harvey P. Dale, Oct 10 2024 *)
PROG
(PARI) {a(n) = n + (n==1)}; /* Michael Somos, Feb 09 2015 */
(Magma) m:=25; R<x>:=PowerSeriesRing(Integers(), m); Coefficients(R!((2*x-2*x^2+x^3)/(1-x)^2)); // G. C. Greubel, Aug 03 2018
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Paul Curtz, Feb 04 2015
STATUS
approved