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 10 results.

A155116 a(n) = 3*a(n-1) + 3*a(n-2), n>2, a(0)=1, a(1)=2, a(2)=8.

Original entry on oeis.org

1, 2, 8, 30, 114, 432, 1638, 6210, 23544, 89262, 338418, 1283040, 4864374, 18442242, 69919848, 265086270, 1005018354, 3810313872, 14445996678, 54768931650, 207644784984, 787241149902, 2984657804658, 11315696863680, 42901064005014
Offset: 0

Views

Author

Philippe Deléham, Jan 20 2009

Keywords

Comments

From Johannes W. Meijer, Aug 14 2010: (Start)
A berserker sequence, see A180140 and A180147. For the central square 16 A[5] vectors with decimal values between 3 and 384 lead to this sequence. These vectors lead for the corner squares to A123620 and for the side squares to A180142.
This sequence belongs to a family of sequences with GF(x)=(1-(2*k-1)*x-k*x^2)/(1-3*x+(k-4)*x^2). Berserker sequences that are members of this family are A000007 (k=2), A155116 (k=1; this sequence), A000302 (k=0), 6*A179606 (k=-1; with leading 1 added) and 2*A180141 (k=-2; n>=1 and a(0)=1). Some other members of this family are (-2)*A003688 (k=3; with leading 1 added), (-4)*A003946 (k=4; with leading 1 added), (-6)*A002878 (k=5; with leading 1 added) and (-8)*A033484 (k=6; with leading 1 added).
Inverse binomial transform of A101368 (without the first leading 1).
(End)

Crossrefs

Sequences of the form a(n) = m*(a(n-1) + a(n-2)) with a(0)=1, a(1) = m-1, a(2) = m^2 -1: A155020 (m=2), this sequence (m=3), A155117 (m=4), A155119 (m=5), A155127 (m=6), A155130 (m=7), A155132 (m=8), A155144 (m=9), A155157 (m=10).

Programs

  • Magma
    m:=3; [1] cat [n le 2 select (m-1)*(m*n-(m-1)) else m*(Self(n-1) + Self(n-2)): n in [1..30]]; // G. C. Greubel, Mar 25 2021
    
  • Mathematica
    With[{m=3}, LinearRecurrence[{m, m}, {1, m-1, m^2-1}, 30]] (* G. C. Greubel, Mar 25 2021 *)
  • PARI
    Vec((1-x-x^2)/(1-3*x-3*x^2)+O(x^99)) \\ Charles R Greathouse IV, Jan 12 2012
    
  • Sage
    m=3; [1]+[-(m-1)*(sqrt(m)*i)^(n-2)*chebyshev_U(n, -sqrt(m)*i/2) for n in (1..30)] # G. C. Greubel, Mar 25 2021

Formula

G.f.: (1-x-x^2)/(1-3*x-3*x^2).
a(n) = 2*A125145(n-1), n>=1 .
a(n) = ( (2+4*A)*A^(-n-1) + (2+4*B)*B^(-n-1) )/21 with A=(-3+sqrt(21))/6 and B=(-3-sqrt(21))/6 for n>=1 with a(0)=1. [corrected by Johannes W. Meijer, Aug 12 2010]
Contribution from Johannes W. Meijer, Aug 14 2010: (Start)
a(n) = A123620(n)/2 for n>=1.
(End)
a(n) = (1/3)*[n=0] - 2*(sqrt(3)*i)^(n-2)*ChebyshevU(n, -sqrt(3)*i/2). - G. C. Greubel, Mar 25 2021

A180140 Eight rooks and one berserker on a 3 X 3 chessboard. G.f.: (1+x+x^2)/(1-3*x-5*x^2).

Original entry on oeis.org

1, 4, 18, 74, 312, 1306, 5478, 22964, 96282, 403666, 1692408, 7095554, 29748702, 124723876, 522915138, 2192364794, 9191670072, 38536834186, 161568852918, 677390729684, 2840016453642, 11907003009346, 49921091296248
Offset: 0

Views

Author

Johannes W. Meijer, Aug 13 2010, Jun 15 2013

Keywords

Comments

a(n) gives the number of n-move routes of a fairy chess piece starting in a given side square (m = 2, 4, 6, 8) on a 3 X 3 chessboard. This fairy chess piece behaves like a rook on the four side and four corner (m = 1, 3, 7, 9) squares but on the center square (m = 5) it goes berserk and turns into a berserker. For this sequence, the berserker can move to three of the side squares and three of the corners from the center.
The berserker is one of the Lewis chessmen which were discovered in 1831 on the Isle of Lewis. They are carved from walrus ivory in Scandinavian style of the 12th century. The pawns look like decorated tombstones. The pieces have all human representations with facial expressions varying from gloom to anger. Some of the rooks show men biting their shield in the manner of berserkers. According to Hooper and Whyld none looks happy.
Let A be the adjacency matrix of the graph G, where V(G) = {v1, v2, v3, v4, v5, v6, v7, v8, v9}. Then the (m, k) entry of A^n is the number of different vm-vk walks of length n in G, see the Chartrand reference. In the adjacency matrix A, see the Maple program, the A[1], A[3], A[7] and A[9] vectors represent the rook moves on the corner squares, the A[2], A[4], A[6] and A[8] vectors represent the rook moves on the side squares and the A[5] vector represents the moves of the berserker. On a 3 X 3 chessboard there are 2^9 = 512 ways a berserker could move from the center square (off the center the berserker behaves like a rook) so there are 512 different berserkers.
For the side squares the 512 berserker vectors lead to 42 different sequences, see the overview of berserker sequences. There are 16 berserker vectors that lead to the sequence given above. Their decimal [binary] values are: 111 [001 101 111] , 207 [011 001 111], 231 [011 100 111], 237 [011 101 101], 303 [100 101 111], 363 [101 101 011], 366 [101 101 110], 399 [110 001 111], 423 [110 100 111], 429 [110 101 101], 459 [111 001 011], 462 [111 001 110], 483 [111 100 011], 486 [111 100 110], 489 [111 101 001] and 492 [111 101 100]. These berserker vectors lead for the corner squares to sequence 4*A179606 (with leading term 1 added) and for the central square to sequence 6*A179606 (with leading term 1 added).
This sequence belongs to a family of sequences with GF(x)=(1+x-k*x^2)/(1-3*x+(k-4)*x^2), see A180142.

References

  • Gary Chartrand, Introductory Graph Theory, pp. 217-221, 1984.
  • David Hooper and Kenneth Whyld, The Oxford Companion to Chess, pp. 131, 225, 1992.

Crossrefs

Cf. A180141 (corner squares) and A180147 (central square).
Cf. Berserker sequences side squares: 4*A007482 (with leading 1 added), A180144, A003500 (n>=1 and a(0)=1), A180142, A000302, A180140 (this sequence), 2*A001077 (n>=1 and a(0)=1), A180146, 4*A154964 (n>=1 and a(0)=1), 4*A123347 (with leading 1 added).

Programs

  • Maple
    nmax:=22; m:=2; A[1]:=[0, 1, 1, 1, 0, 0, 1, 0, 0]: A[2]:=[1, 0, 1, 0, 1, 0, 0, 1, 0]: A[3]:= [1, 1, 0, 0, 0, 1, 0, 0, 1]: A[4]:= [1, 0, 0, 0, 1, 1, 1, 0, 0]: A[5]:=[0, 0, 1, 1, 0, 1, 1, 1, 1]: A[6]:=[0, 0, 1, 1, 1, 0, 0, 0, 1]: A[7]:=[1, 0, 0, 1, 0, 0, 0, 1, 1]: A[8]:=[0, 1, 0, 0, 1, 0, 1, 0, 1]: A[9]:=[0, 0, 1, 0, 0, 1, 1, 1, 0]: A:= Matrix([A[1], A[2], A[3], A[4], A[5], A[6], A[7], A[8], A[9]]): for n from 0 to nmax do B(n):=A^n: a(n):= add(B(n)[m, k], k=1..9): od: seq(a(n), n=0..nmax);
  • Mathematica
    CoefficientList[Series[(1+x+x^2)/(1-3*x-5*x^2), {x, 0, 22}],x] (* or *) LinearRecurrence[{3,5,0},{1,4,18},23] (* Indranil Ghosh, Mar 05 2017 *)
  • PARI
    print(Vec((1 + x + x^2)/(1- 3*x - 5*x^2) + O(x^23))); \\ Indranil Ghosh, Mar 05 2017

Formula

G.f.: (1+x+x^2)/(1-3*x-5*x^2).
a(n) = 3*a(n-1) + 5*a(n-2) for n>=3 with a(0)=1, a(1)=4 and a(2)=18.
a(n) = ((22+54*A)*A^(-n-1) + (22+54*B)*B^(-n-1))/145 with A=(-3+sqrt(29))/10 and B=(-3-sqrt(29))/10 for n>=1 with a(0)=1.
5*a(n) = 2*( A015523(n) + 3*A015523(n+1)), n>0 - R. J. Mathar, May 11 2013

A180147 Eight rooks and one berserker on a 3 X 3 chessboard. G.f.: (1 + 3*x)/(1 - 4*x - 3*x^2 + 6*x^3).

Original entry on oeis.org

1, 7, 31, 139, 607, 2659, 11623, 50827, 222223, 971635, 4248247, 18574555, 81213151, 355086787, 1552539271, 6788138539, 29679651247, 129767784979, 567381262423, 2480750497147, 10846539065983, 47424120180835
Offset: 0

Views

Author

Johannes W. Meijer, Aug 13 2010

Keywords

Comments

The a(n) represent the number of n-move routes of a fairy chess piece starting in the central square (m = 5) on a 3 X 3 chessboard. This fairy chess piece behaves like a rook on the eight side and corner squares but on the central square the rook goes berserk and turns into a berserker, see A180140.
On a 3 X 3 chessboard there are 2^9 = 512 ways to go berserk on the central square (we assume here that a berserker might behave like a rook). The berserker is represented by the A[5] vector in the fifth row of the adjacency matrix A, see the Maple program. For the central squares the 512 berserkers lead to 42 berserker sequences, see the cross-references for some examples.
The sequence above corresponds to six A[5] vectors with decimal values between 191 and 506. These vectors lead for the corner squares to A180145 and for the side squares to A180146.

Crossrefs

Cf. A180141 (corner squares), A180140 (side squares), A180147 (central square).
Cf. Berserker sequences central square [numerical values A[5]]: A000007 [0], A000012 [16], 2*A001835 [17, n>=1 and a(0)=1], A155116 [3], A077829 [7], A000302 [15], 6*A179606 [111, with leading 1 added], 2*A033887 [95, n>=1 and a(0)=1], A180147 [191, this sequence], 2*A180141 [495, n>=1 and a(0)=1], 4*A107979 [383, with leading 1 added].

Programs

  • Maple
    with(LinearAlgebra): nmax:=22; m:=5; A[5]:=[0,1,0,1,1,1,1,1,1]: A:= Matrix([[0,1,1,1,0,0,1,0,0], [1,0,1,0,1,0,0,1,0], [1,1,0,0,0,1,0,0,1], [1,0,0,0,1,1,1,0,0], A[5], [0,0,1,1,1,0,0,0,1], [1,0,0,1,0,0,0,1,1], [0,1,0,0,1,0,1,0,1], [0,0,1,0,0,1,1,1,0]]): for n from 0 to nmax do B(n):=A^n: a(n):= add(B(n)[m,k],k=1..9): od: seq(a(n), n=0..nmax);
  • Mathematica
    CoefficientList[Series[(1+3x)/(1-4x-3x^2+6x^3),{x,0,40}],x] (* or *) LinearRecurrence[{4,3,-6},{1,7,31},40] (* Harvey P. Dale, Oct 10 2011 *)

Formula

G.f.: (1+3*x)/(1 - 4*x - 3*x^2 + 6*x^3).
a(n) = 4*a(n-1) + 3*a(n-2) - 6*a(n-3) with a(0)=1, a(1)=7 and a(2)=31.
a(n) = -1/2 + (7+6*A)*A^(-n-1)/22 + (7+6*B)*B^(-n-1)/22 with A=(-3+sqrt(33))/12 and B=(-3-sqrt(33))/12.
a(n) = A180146(n) + 3*A180146(n-1) with A180146(-1) = 0.

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

Original entry on oeis.org

1, 4, 16, 60, 228, 864, 3276, 12420, 47088, 178524, 676836, 2566080, 9728748, 36884484, 139839696, 530172540, 2010036708, 7620627744, 28891993356, 109537863300, 415289569968, 1574482299804, 5969315609316, 22631393727360, 85802128010028, 325300565212164
Offset: 0

Views

Author

N. J. A. Sloane, Nov 20 2006

Keywords

Comments

From Johannes W. Meijer, Aug 14 2010: (Start)
A berserker sequence, see A180141. For the corner squares 16 A[5] vectors with decimal values between 3 and 384 lead to this sequence. These vectors lead for the side squares to A180142 and for the central square to A155116.
This sequence belongs to a family of sequences with GF(x) = (1+x+k*x^2)/(1-3*x+(k-4)*x^2). Berserker sequences that are members of this family are 4*A055099(n) (k=2; with leading 1 added), A123620 (k=1; this sequence), A000302 (k=0), 4*A179606 (k=-1; with leading 1 added) and A180141 (k=-2). Some other members of this family are 4*A003688 (k=3; with leading 1 added), 4*A003946 (k=4; with leading 1 added), 4*A002878 (k=5; with leading 1 added) and 4*A033484 (k=6; with leading 1 added).
(End)
a(n) is the number of length n sequences on an alphabet of 4 letters that do not contain more than 2 consecutive equal letters. For example, a(3)=60 because we count all 4^3=64 words except: aaa, bbb, ccc, ddd. - Geoffrey Critzer, Mar 12 2014

Crossrefs

Column 4 in A265584.

Programs

  • Magma
    [1] cat [Round(((2^(1-n)*(-(3-Sqrt(21))^(1+n) + (3+Sqrt(21))^(1+n))))/(3*Sqrt(21))): n in [1..50]]; // G. C. Greubel, Oct 26 2017
  • Mathematica
    nn=25;CoefficientList[Series[(1-z^(m+1))/(1-r z +(r-1)z^(m+1))/.{r->4,m->2},{z,0,nn}],z] (* Geoffrey Critzer, Mar 12 2014 *)
    CoefficientList[Series[(1 + x + x^2)/(1 - 3 x - 3 x^2), {x, 0, 40}], x] (* Vincenzo Librandi, Mar 14 2014 *)
    LinearRecurrence[{3,3},{1,4,16},30] (* Harvey P. Dale, Jul 14 2023 *)
  • PARI
    my(x='x+O('x^50)); Vec((1+x+x^2)/(1-3*x-3*x^2)) \\ G. C. Greubel, Oct 16 2017
    

Formula

a(0)=1, a(1)=4, a(2)=16, a(n)=3*a(n-1)+3*a(n-2) for n>2. - Philippe Deléham, Sep 18 2009
a(n) = ((2^(1-n)*(-(3-sqrt(21))^(1+n) + (3+sqrt(21))^(1+n)))) / (3*sqrt(21)) for n>0. - Colin Barker, Oct 17 2017

A180142 Eight rooks and one berserker on a 3 X 3 chessboard. G.f.: (1 + x - x^2)/(1 - 3*x - 3*x^2).

Original entry on oeis.org

1, 4, 14, 54, 204, 774, 2934, 11124, 42174, 159894, 606204, 2298294, 8713494, 33035364, 125246574, 474845814, 1800277164, 6825368934, 25876938294, 98106921684, 371951579934, 1410175504854, 5346381254364, 20269670277654, 76848154596054, 291353474621124
Offset: 0

Views

Author

Johannes W. Meijer, Aug 13 2010

Keywords

Comments

The a(n) represent the number of n-move routes of a fairy chess piece starting in a given side square (m = 2, 4, 6 or 8) on a 3 X 3 chessboard. This fairy chess piece behaves like a rook on the eight side and corner squares but on the central square the rook goes berserk and turns into a berserker, see A180140.
The sequence above corresponds to 16 A[5] vectors with decimal values between 3 and 384. These vectors lead for the corner squares to A123620 and for the central square to A155116.
This sequence appears among the members of a family of sequences with g.f. (1 + x - k*x^2)/(1 - 3*x + (k-4)*x^2). Berserker sequences that are members of this family are 4*A007482 (k=2; with leading 1 added), A180142 (k=1; this sequence), A000302 (k=0), A180140 (k=-1) and 4*A154964 (k=-2; n>=1 and a(0)=1). Some other members of this family are 2*A180148 (k=3; with leading 1 added), 4*A025192 (k=4; with leading 1 added), 2*A005248 (k=5; with leading 1 added) and A123932 (k=6).

Crossrefs

Cf. A180141 (corner squares), A180140 (side squares), A180147 (central square).

Programs

  • Maple
    with(LinearAlgebra): nmax:=23; m:=2; A[5]:=[0,0,0,0,0,0,0,1,1]: A:= Matrix([[0,1,1,1,0,0,1,0,0], [1,0,1,0,1,0,0,1,0], [1,1,0,0,0,1,0,0,1], [1,0,0,0,1,1,1,0,0], A[5], [0,0,1,1,1,0,0,0,1], [1,0,0,1,0,0,0,1,1], [0,1,0,0,1,0,1,0,1], [0,0,1,0,0,1,1,1,0]]): for n from 0 to nmax do B(n):=A^n: a(n):= add(B(n)[m,k],k=1..9): od: seq(a(n), n=0..nmax);
    # second Maple program:
    a:= n-> ceil((<<0|1>, <3|3>>^n. <<2/3, 4>>)[1,1]):
    seq(a(n), n=0..25);  # Alois P. Heinz, Jul 14 2021
  • Mathematica
    LinearRecurrence[{3, 3}, {1, 4, 14}, 26] (* Jean-François Alcover, Jan 18 2025 *)

Formula

G.f.: (1 + x - x^2)/(1 - 3*x - 3*x^2).
a(n) = 3*a(n-1) + 3*a(n-2) for n >= 2 with a(0)=1, a(1)=4 and a(2)=14.
a(n) = (6-2*A)*A^(-n-1)/21 + (6-2*B)*B^(-n-1)/21 with A=(-3+sqrt(21))/6 and B=(-3-sqrt(21))/6.
Lim_{k->infinity} a(2*n+k)/a(k) = 2*A000244(n)/(A003501(n) - A004254(n)*sqrt(21)) for n >= 1.
Lim_{k->infinity} a(2*n-1+k)/a(k) = 2*A000244(n)/(A004253(n)*sqrt(21) - 3*A030221(n-1)) for n >= 1.

A180143 Eight rooks and one berserker on a 3 X 3 chessboard. G.f.: (1 + x^2)/(1 - 4*x + x^2 + 2*x^3).

Original entry on oeis.org

1, 4, 16, 58, 208, 742, 2644, 9418, 33544, 119470, 425500, 1515442, 5397328, 19222870, 68463268, 243835546, 868433176, 3092970622, 11015778220, 39233275906, 139731384160, 497660704294, 1772444881204, 6312656052202
Offset: 0

Views

Author

Johannes W. Meijer, Aug 13 2010

Keywords

Comments

The a(n) represent the number of n-move routes of a fairy chess piece starting in a given corner square (m = 1, 3, 7 or 9) on a 3 X 3 chessboard. This fairy chess piece behaves like a rook on the eight side and corner squares but on the central square the rook goes berserk and turns into a berserker, see A180140.
The sequence above corresponds to just one A[5] vectors with decimal value 16. This vector leads for the side squares to A180144 and for the central square to A000012.

Crossrefs

Cf. A180141 (corner squares), A180140 (side squares), A180147 (central square).

Programs

  • Maple
    with(LinearAlgebra): nmax:=23; m:=1; A[5]:=[0,0,0,0,1,0,0,0,0]: A:= Matrix([[0,1,1,1,0,0,1,0,0], [1,0,1,0,1,0,0,1,0], [1,1,0,0,0,1,0,0,1], [1,0,0,0,1,1,1,0,0], A[5], [0,0,1,1,1,0,0,0,1], [1,0,0,1,0,0,0,1,1], [0,1,0,0,1,0,1,0,1], [0,0,1,0,0,1,1,1,0]]): for n from 0 to nmax do B(n):=A^n: a(n):= add(B(n)[m,k],k=1..9): od: seq(a(n), n=0..nmax);

Formula

G.f.: (1+x^2)/(1 - 4*x + x^2 + 2*x^3).
a(n) = 4*a(n-1) - 1*a(n-2) - 2*a(n-3) with a(0)=1, a(1)=4 and a(2)=16.
a(n) = -1/2 + (9+12*A)*A^(-n-1)/34 + (9+12*B)*B^(-n-1)/34 with A=(-3+sqrt(17))/4 and B=(-3-sqrt(17))/4.
Lim_{k->infinity} a(n+k)/a(k) = (-1)^(n)*(2)^(n+1)/((2*A007482(n) - 3*A007482(n-1)) - A007482(n-1)*sqrt(17)) for n >= 1.

A180146 Eight rooks and one berserker on a 3 X 3 chessboard. G.f.: 1/(1 - 4*x - 3*x^2 + 6*x^3).

Original entry on oeis.org

1, 4, 19, 82, 361, 1576, 6895, 30142, 131797, 576244, 2519515, 11016010, 48165121, 210591424, 920764999, 4025843542, 17602120621, 76961423116, 336496993075, 1471259517922, 6432760512217, 28125838644184, 122974079005855
Offset: 0

Views

Author

Johannes W. Meijer, Aug 13 2010

Keywords

Comments

The a(n) represent the number of n-move routes of a fairy chess piece starting in a given side square (m = 2, 4, 6 or 8) on a 3 X 3 chessboard. This fairy chess piece behaves like a rook on the eight side and corner squares but on the central square the rook goes berserk and turns into a berserker, see A180140.
The sequence above corresponds to 6 A[5] vectors with decimal values between 191 and 506. These vectors lead for the corner squares to A180145 and for the central square to A180147.

Crossrefs

Cf. A180141 (corner squares), A180140 (side squares), A180147 (central square).

Programs

  • Maple
    with(LinearAlgebra): nmax:=22; m:=2; A[5]:=[0,1,0,1,1,1,1,1,1]: A:= Matrix([[0,1,1,1,0,0,1,0,0], [1,0,1,0,1,0,0,1,0], [1,1,0,0,0,1,0,0,1], [1,0,0,0,1,1,1,0,0], A[5], [0,0,1,1,1,0,0,0,1], [1,0,0,1,0,0,0,1,1], [0,1,0,0,1,0,1,0,1], [0,0,1,0,0,1,1,1,0]]): for n from 0 to nmax do B(n):=A^n: a(n):= add(B(n)[m,k],k=1..9): od: seq(a(n), n=0..nmax);
  • Mathematica
    Join[{a=1,b=4},Table[c=3*b+6*a+1;a=b;b=c,{n,60}]] (* Vladimir Joseph Stephan Orlovsky, Jan 18 2011 *)

Formula

G.f.: 1/(1 - 4*x - 3*x^2 + 6*x^3).
a(n) = 4*a(n-1) + 3*a(n-2) - 6*a(n-3) with a(-2)=0, a(-1)=0, a(0)=1, a(1)=4 and a(2)=19.
a(n) = (-1/8) + (13+30*A)*A^(-n-1)/88 + (13+30*B)*B^(-n-1)/88 with A=(-3+sqrt(33))/12 and B=(-3-sqrt(33))/12.

A180145 Eight rooks and one berserker on a 3 X 3 chessboard. G.f.: (1 - 3*x^2)/(1 - 4*x - 3*x^2 + 6*x^3).

Original entry on oeis.org

1, 4, 16, 70, 304, 1330, 5812, 25414, 111112, 485818, 2124124, 9287278, 40606576, 177543394, 776269636, 3394069270, 14839825624, 64883892490, 283690631212, 1240375248574, 5423269532992, 23712060090418, 103675797469204
Offset: 0

Views

Author

Johannes W. Meijer, Aug 13 2010

Keywords

Comments

The a(n) represent the number of n-move routes of a fairy chess piece starting in a given corner square (m = 1, 3, 7 or 9) on a 3 X 3 chessboard. This fairy chess piece behaves like a rook on the eight side and corner squares but on the central square the rook goes berserk and turns into a berserker, see A180140.
The sequence above corresponds to 6 A[5] vectors with decimal values between 191 and 506. These vectors lead for the side squares to A180146 and for the central square to A180147.

Crossrefs

Cf. A180141 (corner squares), A180140 (side squares), A180147 (central square).

Programs

  • Maple
    with(LinearAlgebra): nmax:=22; m:=1; A[5]:=[0,1,0,1,1,1,1,1,1]: A:= Matrix([[0,1,1,1,0,0,1,0,0], [1,0,1,0,1,0,0,1,0], [1,1,0,0,0,1,0,0,1], [1,0,0,0,1,1,1,0,0], A[5], [0,0,1,1,1,0,0,0,1], [1,0,0,1,0,0,0,1,1], [0,1,0,0,1,0,1,0,1], [0,0,1,0,0,1,1,1,0]]): for n from 0 to nmax do B(n):=A^n: a(n):= add(B(n)[m,k],k=1..9): od: seq(a(n), n=0..nmax);

Formula

G.f.: (1-3*x^2)/(1 - 4*x - 3*x^2 + 6*x^3).
a(n) = 4*a(n-1) + 3*a(n-2) - 6*a(n-3) with a(0)=1, a(1)=4 and a(2)=16.
a(n) = 1/4 + (7+6*A)*A^(-n-1)/44 + (7+6*B)*B^(-n-1)/44 with A=(-3+sqrt(33))/12 and B=(-3-sqrt(33))/12.
a(n) = A180146(n) - 3*A180146(n-2) with A180146(-2) = A180146(-1) = 0.

A018916 Define the sequence T(a(0),a(1)) by a(n+2) is the greatest integer such that a(n+2)/a(n+1) < a(n+1)/a(n) for n >= 0. This is T(2,8).

Original entry on oeis.org

2, 8, 31, 120, 464, 1794, 6936, 26816, 103676, 400832, 1549696, 5991432, 23164064, 89556864, 346244592, 1338650240, 5175487232, 20009459744, 77360538496, 299091179520, 1156345798592, 4470662117376, 17284466110464, 66825172844672
Offset: 0

Views

Author

Keywords

Comments

From Johannes W. Meijer, Aug 14 2010: (Start)
The sequence b(n+1)=2*a(n), n>= 0 with b(0)=1, is a berserker sequence, see A180141. For the corner squares 16 A[5] vectors, with decimal values between 19 and 400, lead to the b(n) sequence.
(End)
Not to be confused with the Pisot T(2,8) sequence, which is A004171. - R. J. Mathar, Feb 13 2016

Programs

  • Mathematica
    LinearRecurrence[{4, 0, -2}, {2, 8, 31}, 25] (* Vincenzo Librandi, Feb 15 2016 *)
  • PARI
    T(a0, a1, maxn) = a=vector(maxn); a[1]=a0; a[2]=a1; for(n=3, maxn, a[n]=ceil(a[n-1]^2/a[n-2])-1); a
    T(2, 8, 30) \\ Colin Barker, Feb 14 2016

Formula

From Johannes W. Meijer, Aug 14 2010: (Start)
G.f.: (2-x^2)/(1-4*x+2*x^3).
a(n) = 4*a(n-1)-2*a(n-3) with a(0)=2, a(1)=8 and a(2)=31.
a(n) = (119-24*z1-64*z1^2)*z1^(-n-1)/202+(119-24*z2-64*z2^2)*z2^(-n-1)/202+(119-24*z3-64*z3^2)*z3^(-n-1)/202 with alpha=2*arctan(sqrt(303)/9), p=(sqrt(6)/3)*sin((alpha+Pi)/6), q=sqrt(2)*cos((alpha+Pi)/6), z1:=2*p, z2=(-q-p) and z3=(q-p).
(End)

Extensions

More terms from Johannes W. Meijer, Aug 14 2010

A180144 Eight rooks and one berserker on a 3 X 3 chessboard. G.f.: (1 - 2*x^2)/(1 - 4*x + x^2 + 2*x^3).

Original entry on oeis.org

1, 4, 13, 46, 163, 580, 2065, 7354, 26191, 93280, 332221, 1183222, 4214107, 15008764, 53454505, 190381042, 678052135, 2414918488, 8600859733, 30632416174, 109098967987, 388561736308, 1383883144897, 4928772907306
Offset: 0

Views

Author

Johannes W. Meijer, Aug 13 2010

Keywords

Comments

The a(n) represent the number of n-move routes of a fairy chess piece starting in a given side square (m = 2, 4, 6 or 8) on a 3 X 3 chessboard. This fairy chess piece behaves like a rook on the eight side and corner squares but on the central square the rook goes berserk and turns into a berserker, see A180140.
The sequence above corresponds to just one A[5] vector with decimal value 16. This vector leads for the corner squares to A180143 and for the central square to A000012.

Crossrefs

Cf. A180141 (corner squares), A180140 (side squares), A180147 (central square).

Programs

  • Maple
    with(LinearAlgebra): nmax:=23; m:=2; A[5]:=[0,0,0,0,1,0,0,0,0]: A:= Matrix([[0,1,1,1,0,0,1,0,0], [1,0,1,0,1,0,0,1,0], [1,1,0,0,0,1,0,0,1], [1,0,0,0,1,1,1,0,0], A[5], [0,0,1,1,1,0,0,0,1], [1,0,0,1,0,0,0,1,1], [0,1,0,0,1,0,1,0,1], [0,0,1,0,0,1,1,1,0]]): for n from 0 to nmax do B(n):=A^n: a(n):= add(B(n)[m,k],k=1..9): od: seq(a(n), n=0..nmax);

Formula

G.f.: (1-2*x^2)/(1 - 4*x + x^2 + 2*x^3).
a(n) = 4*a(n-1) - 1*a(n-2) - 2*a(n-3) with a(0)=1, a(1)=4 and a(2)=13.
a(n) = 1/4 + (21-6*A)*A^(-n-1)/68 + (21-6*B)*B^(-n-1)/68 with A=(-3+sqrt(17))/4 and B=(-3-sqrt(17))/4.
Lim_{k->infinity} a(n+k)/a(k) = (-1)^(n)*(2)^(n+1)/((2*A007482(n) - 3*A007482(n-1)) - A007482(n-1)*sqrt(17)) for n >= 1.
Showing 1-10 of 10 results.