cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A254667 The nonnegative numbers with 2 instead of 1.

Original entry on oeis.org

0, 2, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62
Offset: 0

Views

Author

Paul Curtz, Feb 04 2015

Keywords

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).
0 followed by A000012(n) is not in the OEIS. See A054977.
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).

Examples

			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 + ...
		

Crossrefs

Programs

  • Magma
    m:=25; R:=PowerSeriesRing(Integers(), m); Coefficients(R!((2*x-2*x^2+x^3)/(1-x)^2)); // G. C. Greubel, Aug 03 2018
  • 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 *)
  • PARI
    {a(n) = n + (n==1)}; /* Michael Somos, Feb 09 2015 */
    

Formula

a(n) = (A164558(n) + (-1)^(n+1)*A164555(n))/A027642(n).
a(n) = A063524(n) + A001477(n). - David A. Corneth, Aug 03 2018
G.f.: (2*x - 2*x^2 + x^3) / (1 - x)^2. - Michael Somos, Feb 09 2015