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.

Showing 1-10 of 11 results. Next

A052528 Expansion of (1 - x)/(1 - 2*x - 2*x^2 + 2*x^3).

Original entry on oeis.org

1, 1, 4, 8, 22, 52, 132, 324, 808, 2000, 4968, 12320, 30576, 75856, 188224, 467008, 1158752, 2875072, 7133632, 17699904, 43916928, 108966400, 270366848, 670832640, 1664466176, 4129863936, 10246994944, 25424785408, 63083832832
Offset: 0

Views

Author

encyclopedia(AT)pommard.inria.fr, Jan 25 2000

Keywords

Comments

Form the graph with matrix A = [1,1,1,1; 1,0,0,0; 1,0,0,0; 1,0,0,1]. Then a(n) counts closed walks of length n at the degree 5 vertex. - Paul Barry, Oct 02 2004
Equals the INVERT transform of (1, 3, 1, 1, 1, ...). - Gary W. Adamson, Apr 27 2009
a(n) is also the number of vertex-transitive cover graphs of lattice quotients of essential lattice congruences of the weak order on the symmetric group S_{n+1}. See Table 1 in the Hoang/Mütze reference in the Links section. - Torsten Muetze, Nov 28 2019

Crossrefs

Programs

  • GAP
    a:=[1,1,4];; for n in [4..30] do a[n]:=2*a[n-1]+2*a[n-2]-2*a[n-3]; od; a; # G. C. Greubel, May 12 2019
  • Magma
    R:=PowerSeriesRing(Integers(), 30); Coefficients(R!( (1-x)/(1 -2*x-2*x^2+2*x^3) )); // G. C. Greubel, May 12 2019
    
  • Maple
    spec := [S,{S=Sequence(Prod(Z,Union(Z,Z,Sequence(Z))))},unlabeled]:
    seq(combstruct[count](spec,size=n), n=0..20);
  • Mathematica
    LinearRecurrence[{2,2,-2}, {1,1,4}, 30] (* G. C. Greubel, May 12 2019 *)
  • PARI
    my(x='x+O('x^30)); Vec((1-x)/(1-2*x-2*x^2+2*x^3)) \\ G. C. Greubel, May 12 2019
    
  • Sage
    ((1-x)/(1-2*x-2*x^2+2*x^3)).series(x, 30).coefficients(x, sparse=False) # G. C. Greubel, May 12 2019
    

Formula

G.f.: (1 - x)/(1 - 2*x - 2*x^2 + 2*x^3).
Recurrence: a(1) = 1, a(0) = 1, a(2) = 4, 2*a(n) - 2*a(n+1) - 2*a(n+2) + a(n+3) = 0.
a(n) = Sum_{alpha=RootOf(2*Z^3-2*Z^2-2*Z+1)} (1/37)*(5 - 9*alpha^2 + 12*alpha)* alpha^(-1 - n).
a(n) = 2*a(n-2) + Sum_{i=0..n-1} a(i). - Yuchun Ji, Dec 29 2018

Extensions

More terms from James Sellers, Jun 06 2000

A052987 Expansion of (1-2x^2)/(1-2x-2x^2+2x^3).

Original entry on oeis.org

1, 2, 4, 10, 24, 60, 148, 368, 912, 2264, 5616, 13936, 34576, 85792, 212864, 528160, 1310464, 3251520, 8067648, 20017408, 49667072, 123233664, 305766656, 758666496, 1882398976, 4670597632, 11588660224, 28753717760, 71343560704
Offset: 0

Views

Author

encyclopedia(AT)pommard.inria.fr, Jan 25 2000

Keywords

Comments

Form the graph with matrix A=[1,1,1,1;1,0,0,0;1,0,0,0;1,0,0,1]. Then the sequence 1,1,2,4,... with g.f. (1-x-2x^2)/(1-2x-2x^2+2x^3) counts closed walks of length n at the degree 3 vertex. - Paul Barry, Oct 02 2004
Equals INVERT transform of the Jacobsthal sequence A001045 prefaced with a 1:
[1, 1, 1, 3, 5, 11, 21, 43, ...]. - Gary W. Adamson, May 27 2009

Crossrefs

Programs

  • Maple
    spec := [S,{S=Sequence(Union(Prod(Sequence(Prod(Union(Z,Z),Z)),Z),Z))},unlabeled ]: seq(combstruct[count ](spec,size=n), n=0..20);
  • Mathematica
    InvertTransform[ser_, n_] := CoefficientList[ Series[1/(1 - x ser), {x,0,n}],x];
    Jacobsthal := (2x^2-1)/((x + 1)(2x - 1));
    PadLeft[InvertTransform[Jacobsthal, 29],29,1] (* Peter Luschny, Jan 10 2019 *)

Formula

G.f.: -(-1+2*x^2)/(1-2*x-2*x^2+2*x^3)
Recurrence: {a(0)=1, a(2)=4, a(1)=2, 2*a(n)-2*a(n+1)-2*a(n+2)+a(n+3)=0}
Sum(1/37*(6+7*_alpha+4*_alpha^2)*_alpha^(-1-n), _alpha=RootOf(2*_Z^3-2*_Z^2-2*_Z+1)).

Extensions

More terms from James Sellers, Jun 05 2000

A384646 Expansion of (1+x) / (1-x-5*x^2-2*x^3).

Original entry on oeis.org

1, 2, 7, 19, 58, 167, 495, 1446, 4255, 12475, 36642, 107527, 315687, 926606, 2720095, 7984499, 23438186, 68800871, 201960799, 592841526, 1740247263, 5108376491, 14995295858, 44017672839, 129210905111, 379289861022, 1113379732255, 3268250847587, 9593729230906
Offset: 0

Views

Author

Sean A. Irvine, Jun 05 2025

Keywords

Comments

Number of walks of length n starting at vertex 0 in the following graph:
1---2
/|\ |
0 | \ |
\| \|
4---3.
Also, by symmetry, the number of walks of length n starting at vertex 2 in the same graph.

Examples

			a(2)=7 because we have the walks 0-1-0, 0-1-2, 0-1-3, 0-1-4, 0-4-0, 0-4-1, 0-4-3.
		

Crossrefs

Cf. A384647 (vertex 1), A384648 (vertices 3 and 4), A077937 (missing edge {1,3}).

Programs

  • Maple
    a:= n->  (<<0|1|0|0|1>, <1|0|1|1|1>, <0|1|0|1|0>, <0|1|1|0|1>, <1|1|0|1|0>>^n. <<1,1,1,1,1>>)[1,1]:
    seq(a(n), n=0..32);
  • Mathematica
    CoefficientList[Series[(1+x) / (1-x-5*x^2-2*x^3), {x, 0, 32}], x]

Formula

a(n) = A353964(n)+A353964(n-1). - R. J. Mathar, Jun 07 2025

A077847 Expansion of (1-x)^(-1)/(1-2*x-2*x^2+2*x^3).

Original entry on oeis.org

1, 3, 9, 23, 59, 147, 367, 911, 2263, 5615, 13935, 34575, 85791, 212863, 528159, 1310463, 3251519, 8067647, 20017407, 49667071, 123233663, 305766655, 758666495, 1882398975, 4670597631, 11588660223, 28753717759, 71343560703, 177017236479, 439214158847
Offset: 0

Views

Author

N. J. A. Sloane, Nov 17 2002

Keywords

Crossrefs

Cf. A052987.

Programs

  • Mathematica
    CoefficientList[Series[(1-x)^(-1)/(1-2x-2x^2+2x^3),{x,0,40}],x] (* or *) LinearRecurrence[{3,0,-4,2},{1,3,9,23},40] (* Harvey P. Dale, Apr 02 2013 *)
  • PARI
    Vec((1-x)^(-1)/(1-2*x-2*x^2+2*x^3)+O(x^99)) \\ Charles R Greathouse IV, Sep 26 2012

Formula

a(n) = -1+2*A077937(n)-2*A077937(n-2). [From R. J. Mathar, Nov 10 2009]
a(0)=1, a(1)=3, a(2)=9, a(3)=23, a(n)=3*a(n-1)-4*a(n-3)+2*a(n-4). - Harvey P. Dale, Apr 02 2013

A077981 Expansion of 1/(1+2*x-2*x^2-2*x^3).

Original entry on oeis.org

1, -2, 6, -14, 36, -88, 220, -544, 1352, -3352, 8320, -20640, 51216, -127072, 315296, -782304, 1941056, -4816128, 11949760, -29649664, 73566592, -182532992, 452899840, -1123732480, 2788198656, -6918062592, 17165057536, -42589842944, 105673675776, -262196922368
Offset: 0

Views

Author

N. J. A. Sloane, Nov 17 2002

Keywords

Crossrefs

Cf. A077937.

Programs

  • GAP
    a:=[1,-2,6];; for n in [4..30] do a[n]:=-2*a[n-1]+2*a[n-2]+ 2*a[n-3]; od; a; # G. C. Greubel, Jun 25 2019
  • Magma
    R:=PowerSeriesRing(Integers(), 30); Coefficients(R!( 1/(1+2*x-2*x^2-2*x^3) )); // G. C. Greubel, Jun 25 2019
    
  • Mathematica
    LinearRecurrence[{-2,2,2}, {1,-2,6}, 30] (* or *) CoefficientList[ Series[1/(1+2*x-2*x^2-2*x^3), {x,0,30}], x] (* G. C. Greubel, Jun 25 2019 *)
  • PARI
    Vec(1/(1+2*x-2*x^2-2*x^3) + O(x^30)) \\ Michel Marcus, Jun 19 2015
    
  • Sage
    (1/(1+2*x-2*x^2-2*x^3)).series(x, 30).coefficients(x, sparse=False) # G. C. Greubel, Jun 25 2019
    

Formula

a(n) = (-1)^n * A077937(n). - Ivan Neretin, Jun 19 2015

A091595 Triangle read by rows: T(n,m) := Sum_{k=0..floor((n-m)/2)} binomial(n-2k,m) * binomial(n-m-k,k) * 2^k.

Original entry on oeis.org

1, 1, 1, 3, 2, 1, 5, 5, 3, 1, 11, 12, 8, 4, 1, 21, 27, 22, 12, 5, 1, 43, 62, 55, 36, 17, 6, 1, 85, 137, 137, 99, 55, 23, 7, 1, 171, 304, 330, 264, 164, 80, 30, 8, 1, 341, 663, 784, 682, 466, 256, 112, 38, 9, 1, 683, 1442, 1833, 1720, 1278, 772, 382, 152, 47, 10, 1, 1365, 3109, 4235, 4257, 3402, 2234, 1218, 550, 201, 57, 11, 1
Offset: 0

Views

Author

Paul Barry, Jan 23 2004

Keywords

Comments

A Jacobsthal related number number triangle.

Examples

			Rows begin:
   1,
   1,   1,
   3,   2,   1,
   5,   5,   3,  1,
  11,  12,   8,  4,  1,
  21,  27,  22, 12,  5,  1,
  43,  62,  55, 36, 17,  6, 1,
  85, 137, 137, 99, 55, 23, 7, 1,
  ...
		

Crossrefs

Columns include A001045, A091596. Row sums are A077937.

Formula

k-th column has g.f. 1/(1-x-2x^2) * ( x*(1-2x^2)/(1-x-2x^2) )^k.

A107300 a(n) = 2*a(n-1) + 2*a(n-2) - 2*a(n-3) with a(0)=3, a(1)=2, a(3)=8.

Original entry on oeis.org

3, 2, 8, 14, 40, 92, 236, 576, 1440, 3560, 8848, 21936, 54448, 135072, 335168, 831584, 2063360, 5119552, 12702656, 31517696, 78201600, 194033280, 481434368, 1194532096, 2963866368, 7353928192
Offset: 0

Views

Author

Roger L. Bagula, May 20 2005

Keywords

Crossrefs

Cf. A077937.

Programs

  • Magma
    I:=[3,2,8]; [n le 3 select I[n] else 2*(Self(n-1) +Self(n-2) -Self(n-3)): n in [1..46]]; // G. C. Greubel, May 02 2022
    
  • Mathematica
    LinearRecurrence[{2,2,-2}, {3,2,8}, 46]
  • SageMath
    def A107300_list(prec):
        P. = PowerSeriesRing(ZZ, prec)
        return P( (3-4*x-2*x^2)/(1-2*x-2*x^2+2*x^3) ).list()
    A107300_list(45) # G. C. Greubel, May 02 2022

Formula

G.f.: (3-4*x-2*x^2)/(1-2*x-2*x^2+2*x^3). [Sep 28 2009]
a(n) = 3*A077937(n) - 4*A077937(n-1) - 2*A077937(n-2). [Sep 28 2009]
a(n) = 2*(b1^n + b2^n + b3^n)/(b1 + b2 + b3), where b1, b2, and b3 and the roots of x^3 = 2*x^2 + 2*x - 2.

Extensions

Definition replaced by recurrence by the Associate Editors of the OEIS, Sep 28 2009

A384647 Expansion of (1+3*x+x^2) / (1-x-5*x^2-2*x^3).

Original entry on oeis.org

1, 4, 10, 32, 90, 270, 784, 2314, 6774, 19912, 58410, 171518, 503392, 1477802, 4337798, 12733592, 37378186, 109721742, 322079856, 945444938, 2775287702, 8146672104, 23914000490, 70197936414, 206061283072, 604878966122, 1775581254310, 5212098651064
Offset: 0

Views

Author

Sean A. Irvine, Jun 05 2025

Keywords

Comments

Number of walks of length n starting at vertex 1 in the following graph:
1---2
/|\ |
0 | \ |
\| \|
4---3.

Examples

			a(2)=10 because we have the walks 1-0-1, 1-0-4, 1-2-1, 1-2-3, 1-3-1, 1-3-2, 1-3-4, 1-4-0, 1-4-1, 1-4-3.
		

Crossrefs

Cf. A384646 (vertices 0, 2), A384648 (vertices 3 and 4), A077937 (missing edge {1,3}).

Programs

  • Maple
    a:= n->  (<<0|1|0|0|1>, <1|0|1|1|1>, <0|1|0|1|0>, <0|1|1|0|1>, <1|1|0|1|0>>^n. <<1,1,1,1,1>>)[2,1]:
    seq(a(n), n=0..32);
  • Mathematica
    CoefficientList[Series[(1+3*x+x^2) / (1-x-5*x^2-2*x^3), {x, 0, 32}], x]

A384648 Expansion of (1+2*x+x^2) / (1-x-5*x^2-2*x^3).

Original entry on oeis.org

1, 3, 9, 26, 77, 225, 662, 1941, 5701, 16730, 49117, 144169, 423214, 1242293, 3646701, 10704594, 31422685, 92239057, 270761670, 794802325, 2333088789, 6848623754, 20103672349, 59012968697, 173228577950, 508500766133, 1492669593277, 4381630579842
Offset: 0

Views

Author

Sean A. Irvine, Jun 05 2025

Keywords

Comments

Number of walks of length n starting at vertex 0 in the following graph:
1---2
/|\ |
0 | \ |
\| \|
4---3.
Also, by symmetry, the number of walks of length n starting at vertex 4 in the same graph.

Examples

			a(2)=9 because we have the walks 3-1-0, 3-1-2, 3-1-3, 3-1-4, 3-2-1, 3-2-3, 3-4-0, 3-4-1, 3-4-3.
		

Crossrefs

Cf. A384646 (vertices 0 and 2), A384647 (vertex 1), A077937 (missing edge {1,3}).

Programs

  • Maple
    a:= n->  (<<0|1|0|0|1>, <1|0|1|1|1>, <0|1|0|1|0>, <0|1|1|0|1>, <1|1|0|1|0>>^n. <<1,1,1,1,1>>)[4,1]:
    seq(a(n), n=0..32);
  • Mathematica
    CoefficientList[Series[(1+2*x+x^2) / (1-x-5*x^2-2*x^3), {x, 0, 32}], x]

A106666 Expansion of g.f. (1-4*x^2+2*x^3)/((1-x)*(1-2*x-2*x^2+2*x^3)).

Original entry on oeis.org

1, 3, 5, 13, 29, 73, 177, 441, 1089, 2705, 6705, 16641, 41281, 102433, 254145, 630593, 1564609, 3882113, 9632257, 23899521, 59299329, 147133185, 365065985, 905799681, 2247464961, 5576397313, 13836125185, 34330115073, 85179685889
Offset: 0

Views

Author

Creighton Dement, May 13 2005

Keywords

Comments

Floretion Algebra Multiplication Program, FAMP Code: 1vesseq[I*J*cyc(I)] with I = + .5'ii' + .5'kk' + .5'ik' + .5'jk' + .5'ki' + .5'kj' and J = + .5'i + .5i' - .5'ii' + .5'jj' + .5'kk' + .5e

Crossrefs

Programs

  • Magma
    R:=PowerSeriesRing(Integers(), 50); Coefficients(R!(  (1-4*x^2+2*x^3)/((1-x)*(1-2*x-2*x^2+2*x^3)) )); // G. C. Greubel, Sep 08 2021
    
  • Mathematica
    LinearRecurrence[{3,0,-4,2},{1,3,5,13},30] (* Harvey P. Dale, Jul 28 2015 *)
  • SageMath
    def A106666_list(prec):
        P. = PowerSeriesRing(QQ, prec)
        return P( (1-4*x^2+2*x^3)/((1-x)*(1-2*x-2*x^2+2*x^3)) ).list()
    A106666_list(50) # G. C. Greubel, Sep 08 2021

Formula

Superseeker results: a(n+1) - a(n) = A052970(n+2); a(n+2) - a(n) = A052987(n+2).
a(0)=1, a(n) = 2*A077937(n-1) + 1.
Showing 1-10 of 11 results. Next