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.

Previous Showing 11-20 of 62 results. Next

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

Original entry on oeis.org

1, 4, 16, 72, 312, 1368, 5976, 26136, 114264, 499608, 2184408, 9550872, 41759064, 182582424, 798301656, 3490399512, 15261008472, 66725422488, 291742318296, 1275579489816, 5577192379224, 24385054076568, 106618316505048
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.
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 corner squares the 512 berserkers lead to 42 berserker sequences, see the cross-references for some examples.
The sequence above corresponds to just one A[5] vectors with decimal value 495. This vector leads for the side squares to 4*A154964 (for n >= 1 with a(0) = 1) and for the central square to 2*A180141 (for n >= 1 with a(0)=1).
This sequence belongs to a family of sequences with g.f. (1 + x + k*x^2)/(1 - 3*x + (k-4)*x^2), see A123620.

Crossrefs

Cf. A180140 (side squares) and A180147 (central square).
Cf. Berserker sequences corner squares [numerical value A[5]]: 4*A055099 [0, with leading 1 added], A180143 [16], 4*A001353 [17, n>=1 and a(0)=1], A123620 [3], 2*A018916 [19, with leading 1 added], A000302 [15], 4*A179606 [111, with leading 1 added], A089979 [343], 4*A001076 [95, n>=1 and a(0)=1], A180145 [191], A180141 [495, this sequence], 4*A090017 [383, n>=1 and a(0)=1].

Programs

  • Maple
    with(LinearAlgebra): nmax:=22; m:=1; A[5]:= [1,1,1,1,0,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
    LinearRecurrence[{3, 6}, {1, 4, 16}, 23] (* Jean-François Alcover, Jan 18 2025 *)

Formula

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

A054458 Convolution triangle based on A001333(n), n >= 1.

Original entry on oeis.org

1, 3, 1, 7, 6, 1, 17, 23, 9, 1, 41, 76, 48, 12, 1, 99, 233, 204, 82, 15, 1, 239, 682, 765, 428, 125, 18, 1, 577, 1935, 2649, 1907, 775, 177, 21, 1, 1393, 5368, 8680, 7656, 4010, 1272, 238, 24, 1, 3363, 14641, 27312, 28548, 18358, 7506, 1946, 308, 27, 1
Offset: 0

Views

Author

Wolfdieter Lang, Apr 26 2000

Keywords

Comments

In the language of the Shapiro et al. reference (given in A053121) such a lower triangular (ordinary) convolution array, considered as a matrix, belongs to the Bell-subgroup of the Riordan-group.
The G.f. for the row polynomials p(n,x) (increasing powers of x) is LPell(z)/(1-x*z*LPell(z)) with LPell(z) given in 'Formula'.
Column sequences are A001333(n+1), A054459(n), A054460(n) for m=0..2.
Mirror image of triangle in A209696. - Philippe Deléham, Mar 24 2012
Subtriangle of the triangle given by (0, 3, -2/3, -1/3, 0, 0, 0, 0, 0, 0, 0, ...) DELTA (1, 0, 0, 0, 0, 0, 0, 0, 0, 0, ...) where DELTA is the operator defined in A084938. - Philippe Deléham, Mar 25 2012
Riordan array ((1+x)/(1-2*x-x^2), (x+x^2)/(1-2*x-x^2)). - Philippe Deléham, Mar 25 2012

Examples

			Fourth row polynomial (n=3): p(3,x)= 17+23*x+9*x^2+x^3.
Triangle begins :
  1
  3, 1
  7, 6, 1
  17, 23, 9, 1
  41, 76, 48, 12, 1
  99, 233, 204, 82, 15, 1
  239, 682, 765, 428, 125, 18, 1. - _Philippe Deléham_, Mar 25 2012
(0, 3, -2/3, -1/3, 0, 0, 0, ...) DELTA (1, 0, 0, 0, ...) begins :
  1
  0, 1
  0, 3, 1
  0, 7, 6, 1
  0, 17, 23, 9, 1
  0, 41, 76, 48, 12, 1
  0, 99, 233, 204, 82, 15, 1
  0, 239, 682, 765, 428, 125, 15, 1. - _Philippe Deléham_, Mar 25 2012
		

Crossrefs

Cf. A002203(n+1)/2. Row sums: A055099(n).

Formula

a(n, m) := ((n-m+1)*a(n, m-1) + (2n-m)*a(n-1, m-1) + (n-1)*a(n-2, m-1))/(4*m), n >= m >= 1; a(n, 0)= A001333(n+1); a(n, m) := 0 if n
G.f. for column m: LPell(x)*(x*LPell(x))^m, m >= 0, with LPell(x)= (1+x)/(1-2*x-x^2) = g.f. for A001333(n+1).
G.f.: (1+x)/(1-2*x-y*x-x^2-y*x^2). - Philippe Deléham, Mar 25 2012
T(n,k) = 2*T(n-1,k) + T(n-1,k-1) + T(n-2,k) + T(n-2,k-1), T(0,0) = T(1,1) = 1, T(1,0) = 3 and T(n,k) = 0 if k<0 or if k>n. - Philippe Deléham, Mar 25 2012
Sum_{k=0..n} T(n,k)*x^k = A040000(n), A001333(n+1), A055099(n), A126473(n), A126501(n), A126528(n) for x = -1, 0, 1, 2, 3, 4 respectively. - Philippe Deléham, Mar 25 2012

A181245 T(n,k) = Number of n X k binary matrices with no 2 X 2 circuit having pattern 0101 in any orientation.

Original entry on oeis.org

2, 4, 4, 8, 14, 8, 16, 50, 50, 16, 32, 178, 322, 178, 32, 64, 634, 2066, 2066, 634, 64, 128, 2258, 13262, 23858, 13262, 2258, 128, 256, 8042, 85126, 275690, 275690, 85126, 8042, 256, 512, 28642, 546410, 3185462, 5735478, 3185462, 546410, 28642, 512, 1024
Offset: 1

Author

R. H. Hardin, Oct 10 2010

Keywords

Comments

Table starts
....2......4.........8..........16.............32...............64
....4.....14........50.........178............634.............2258
....8.....50.......322........2066..........13262............85126
...16....178......2066.......23858.........275690..........3185462
...32....634.....13262......275690........5735478........119310334
...64...2258.....85126.....3185462......119310334.......4468252414
..128...8042....546410....36806846.....2481942354.....167341334542
..256..28642...3507314...425288998....51630303190....6267120468434
..512.102010..22512862..4914052362..1074033301458..234710735573170
.1024.363314.144506294.56780001474.22342450688162.8790181730741270

Examples

			All solutions for 2X2
..0..0....0..0....0..0....0..0....0..1....0..1....0..1....1..0....1..0....1..0
..0..0....0..1....1..0....1..1....0..0....0..1....1..1....0..0....1..0....1..1
...
..1..1....1..1....1..1....1..1
..0..0....0..1....1..0....1..1
		

Crossrefs

Main diagonal is A133130.
Column 2 is A055099.
Column 3 is A133129.

Formula

Empirical column 1: a(n)=2*a(n-1)
Empirical column 2: a(n)=3*a(n-1)+2*a(n-2)
Empirical column 3: a(n)=6*a(n-1)+3*a(n-2)-2*a(n-3)
Empirical column 4: a(n)=10*a(n-1)+20*a(n-2)-21*a(n-3)-30*a(n-4)+8*a(n-5)
Empirical column 5: a(n)=21*a(n-1)+9*a(n-2)-278*a(n-3)+73*a(n-4)+790*a(n-5)-662*a(n-6)+29*a(n-7)+69*a(n-8)-10*a(n-9)
Empirical column 6: a(n)=36*a(n-1)+120*a(n-2)-2391*a(n-3)-3905*a(n-4)+50702*a(n-5)+27152*a(n-6)-396016*a(n-7)+154999*a(n-8)+751787*a(n-9)-499260*a(n-10)-410368*a(n-11)+355981*a(n-12)+38077*a(n-13)-70276*a(n-14)+6203*a(n-15)+3386*a(n-16)-622*a(n-17)+28*a(n-18)
Empirical column 7: a(n)=77*a(n-1)-429*a(n-2)-16791*a(n-3)+132938*a(n-4)+1140609*a(n-5)-11250708*a(n-6)-21101443*a(n-7)+356560316*a(n-8)-276630106*a(n-9)-3595865197*a(n-10)+5253257444*a(n-11)+16399879057*a(n-12)-30419637636*a(n-13)-37486637674*a(n-14)+87632998667*a(n-15)+40083109062*a(n-16)-140235056122*a(n-17)-7589163210*a(n-18)+128111780723*a(n-19)-23221600421*a(n-20)-65939015129*a(n-21)+21868944788*a(n-22)+18307048178*a(n-23)-8259596531*a(n-24)-2431120428*a(n-25)+1497147381*a(n-26)+85285300*a(n-27)-123174410*a(n-28)+8581030*a(n-29)+3300116*a(n-30)-512304*a(n-31)+18304*a(n-32)

A212835 T(n,k)=Number of 0..k arrays of length n+1 with 0 never adjacent to k.

Original entry on oeis.org

2, 7, 2, 14, 17, 2, 23, 50, 41, 2, 34, 107, 178, 99, 2, 47, 194, 497, 634, 239, 2, 62, 317, 1106, 2309, 2258, 577, 2, 79, 482, 2137, 6306, 10727, 8042, 1393, 2, 98, 695, 3746, 14407, 35954, 49835, 28642, 3363, 2, 119, 962, 6113, 29114, 97127, 204994, 231521
Offset: 1

Author

R. H. Hardin May 28 2012

Keywords

Comments

Table starts
.2.....7......14.......23........34.........47.........62..........79
.2....17......50......107.......194........317........482.........695
.2....41.....178......497......1106.......2137.......3746........6113
.2....99.....634.....2309......6306......14407......29114.......53769
.2...239....2258....10727.....35954......97127.....226274......472943
.2...577....8042....49835....204994.....654797....1758602.....4159927
.2..1393...28642...231521...1168786....4414417...13667858....36590017
.2..3363..102010..1075589...6663906...29760487..106226618...321839625
.2..8119..363314..4996919..37994674..200635007..825593474..2830847119
.2.19601.1293962.23214443.216628994.1352612477.6416514026.24899654327

Examples

			Some solutions for n=5 k=4
..1....4....1....1....1....3....2....1....1....4....3....1....0....2....2....3
..1....3....0....4....2....4....1....1....2....2....3....4....1....3....3....1
..1....3....3....1....3....3....2....2....2....4....3....3....1....1....0....3
..1....3....0....4....2....3....3....3....4....2....2....0....4....4....2....1
..1....4....0....3....2....2....3....3....4....4....0....1....4....3....4....2
..1....2....0....4....3....1....0....2....4....2....3....2....1....4....3....4
		

Crossrefs

Column 2 is A001333(n+2)
Column 3 is A055099(n+1)
Column 4 is A126473(n+1)
Column 5 is A126501(n+1)
Column 6 is A126528(n+1)
Row 1 is A008865(n+1)

Formula

Empirical for column k: a(n) = k*a(n-1) +(k-1)*a(n-2)
Empirical for rows:
n=1: a(k) = k^2 + 2*k - 1
n=2: a(k) = k^3 + 3*k^2 - k - 1
n=3: a(k) = k^4 + 4*k^3 - 4*k + 1
n=4: a(k) = k^5 + 5*k^4 + 2*k^3 - 8*k^2 + k + 1
n=5: a(k) = k^6 + 6*k^5 + 5*k^4 - 12*k^3 - 3*k^2 + 6*k - 1
n=6: a(k) = k^7 + 7*k^6 + 9*k^5 - 15*k^4 - 13*k^3 + 15*k^2 - k - 1
n=7: a(k) = k^8 + 8*k^7 + 14*k^6 - 16*k^5 - 30*k^4 + 24*k^3 + 8*k^2 - 8*k + 1

A184761 T(n,k)=Half the number of nXk binary arrays with no 1 having an adjacent 1 both above and to its left.

Original entry on oeis.org

1, 2, 2, 4, 7, 4, 8, 25, 25, 8, 16, 89, 163, 89, 16, 32, 317, 1056, 1056, 317, 32, 64, 1129, 6847, 12397, 6847, 1129, 64, 128, 4021, 44391, 145778, 145778, 44391, 4021, 128, 256, 14321, 287802, 1713803, 3110914, 1713803, 287802, 14321, 256, 512, 51005, 1865917
Offset: 1

Author

R. H. Hardin Jan 21 2011

Keywords

Comments

Table starts
...1......2........4...........8.............16...............32
...2......7.......25..........89............317.............1129
...4.....25......163........1056...........6847............44391
...8.....89.....1056.......12397.........145778..........1713803
..16....317.....6847......145778........3110914.........66363023
..32...1129....44391.....1713803.......66363023.......2568513843
..64...4021...287802....20148584.....1415755252......99419347147
.128..14321..1865917...236878817....30202770902....3848174315295
.256..51005.12097367..2784890782...644326291402..148949599913987
.512.181657.78431296.32740859687.13745636657969.5765325542821919

Examples

			Some solutions for 4X3
..1..1..0....1..0..0....0..1..1....0..0..0....0..0..1....1..0..0....0..0..0
..0..0..0....0..0..1....0..0..1....0..0..1....1..0..0....0..1..0....1..0..1
..1..1..0....1..0..1....1..1..0....0..0..1....1..1..0....0..0..1....1..0..1
..0..0..0....0..0..0....0..0..1....1..1..0....0..1..0....1..0..0....0..1..0
		

Crossrefs

Column 2 is A007484(n-1) and 1/2 A055099 and 1/4 A104934(n+1)

A287839 Number of words of length n over the alphabet {0,1,...,10} such that no two consecutive terms have distance 9.

Original entry on oeis.org

1, 11, 117, 1247, 13289, 141619, 1509213, 16083463, 171399121, 1826575451, 19465548357, 207441511727, 2210673955769, 23558830139779, 251063019088173, 2675542001860183, 28512861152219041, 303857405535211691, 3238164083417650197, 34508642672922983807
Offset: 0

Author

David Nacin, Jun 07 2017

Keywords

Comments

In general, the number of sequences on {0,1,...,10} such that no two consecutive terms have distance 6+k for k in {0,1,2,3,4} has generating function (-1 - x)/(-1 + 10*x + (2*k+1)*x^2).

Programs

  • Maple
    a:=proc(n) option remember; if n=0 then 1 elif n=1 then 11 elif n=2 then 117 else 10*a(n-1)+7*a(n-2); fi; end: seq(a(n), n=0..30); # Wesley Ivan Hurt, Nov 25 2017
  • Mathematica
    LinearRecurrence[{10, 7}, {1, 11, 117}, 20]
  • PARI
    Vec((1 + x) / (1 - 10*x - 7*x^2) + O(x^30)) \\ Colin Barker, Nov 25 2017
  • Python
    def a(n):
     if n in [0,1,2]:
      return [1, 11, 117][n]
     return 10*a(n-1) + 7*a(n-2)
    

Formula

For n>2, a(n) = 10*a(n-1) + 7*a(n-2), a(0)=1, a(1)=11, a(2)=117.
G.f.: (-1 - x)/(-1 + 10 x + 7 x^2).
a(n) = (((5-4*sqrt(2))^n*(-3+2*sqrt(2)) + (3+2*sqrt(2))*(5+4*sqrt(2))^n)) / (4*sqrt(2)). - Colin Barker, Nov 25 2017

A254600 Numbers of words on alphabet {0,1,...,10} with no subwords ii, for i from {0,1}.

Original entry on oeis.org

1, 11, 119, 1289, 13961, 151211, 1637759, 17738489, 192124721, 2080893611, 22538058599, 244108628489, 2643928812281, 28636265779211, 310158017102639, 3359306563039289, 36384487784316641, 394078636910520011, 4268246759164049879, 46229175323835178889
Offset: 0

Author

Milan Janjic, Feb 02 2015

Keywords

Comments

a(n) equals the number of sequences over the alphabet {0,1,...,9,10} such that no two consecutive terms have distance 10. - David Nacin, Jun 02 2017

Crossrefs

Programs

  • Magma
    [n le 1 select 11^n else 10*Self(n)+9*Self(n-1): n in [0..20]]; // Bruno Berselli, Feb 03 2015
    
  • Mathematica
    RecurrenceTable[{a[0]==1, a[1]==11, a[n]== 10a[n-1] +9a[n-2]}, a[n], {n, 0, 25}]
    Table[(-3 I)^(n-1)*(ChebyshevU[n-1, 5*I/3] - 3*I*ChebyshevU[n, 5*I/3]), {n,0,25}] (* G. C. Greubel, Feb 13 2021 *)
  • PARI
    Vec((x+1) / (1-10*x-9*x^2) + O(x^30)) \\ Colin Barker, Jan 21 2017
    
  • Sage
    [(-3*i)^(n-1)*( chebyshev_U(n-1, 5*i/3) -3*i*chebyshev_U(n, 5*i/3) ) for n in (0..30)] # G. C. Greubel, Feb 13 2021

Formula

G.f.: (1+x)/(1-10*x-9*x^2).
a(n) = 10*a(n-1) + 9*a(n-2) with n>1, a(0) = 1, a(1) = 11.
a(n) = ((5-sqrt(34))^n*(-6+sqrt(34)) + (5+sqrt(34))^n*(6+sqrt(34))) / (2*sqrt(34)). - Colin Barker, Jan 21 2017
a(n) = (-3*i)^(n-1) * (ChebyshevU(n-1, 5*i/3) - 3*i*ChebyshevU(n, 5*i/3)). - G. C. Greubel, Feb 13 2021

A287831 Number of sequences over the alphabet {0,1,...,9} such that no two consecutive terms have distance 8.

Original entry on oeis.org

1, 10, 96, 924, 8892, 85572, 823500, 7924932, 76265388, 733938084, 7063035084, 67970944260, 654116708844, 6294876045156, 60578584659468, 582976518206148, 5610260171812140, 53990200655546148, 519573366930788172, 5000101506310370436, 48118353758378062956
Offset: 0

Author

David Nacin, Jun 02 2017

Keywords

Comments

In general, the number of sequences over the alphabet {0,1,...,9} such that no two consecutive terms have distance 5+k for k in {0,1,2,3,4} is given by a(n) = 9*a(n-1) + 2*k*a(n-2), a(0)=1, a(1)=10.

Programs

  • Mathematica
    LinearRecurrence[{9, 6}, {1, 10}, 30]
  • Python
    def a(n):
     if n in [0, 1]:
      return [1, 10][n]
     return 9*a(n-1)+6*a(n-2)

Formula

a(n) = 9*a(n-1) + 6*a(n-2), a(0)=1, a(1)=10.
G.f.: (-1 - x)/(-1 + 9*x + 6*x^2).
a(n) = ((1 - 11/sqrt(105))/2)*((9 - sqrt(105))/2)^n + ((1 + 11/sqrt(105))/2)*((9 + sqrt(105))/2)^n.

A254657 Numbers of words on alphabet {0,1,...,8} with no subwords ii, where i is from {0,1,2}.

Original entry on oeis.org

1, 9, 78, 678, 5892, 51204, 444984, 3867096, 33606672, 292055952, 2538087648, 22057036896, 191684821056, 1665820789824, 14476675244928, 125808326698368, 1093326665056512, 9501463280642304, 82571666235477504, 717582109567673856, 6236086873954255872
Offset: 0

Author

Milan Janjic, Feb 04 2015

Keywords

Programs

  • Magma
    [n le 1 select 9^n else 8*Self(n)+6*Self(n-1): n in [0..20]];
    
  • Mathematica
    RecurrenceTable[{a[0] == 1, a[1] == 9, a[n] == 8 a[n - 1] + 6 a[n - 2]}, a[n], {n, 0, 20}]
  • PARI
    Vec((1+x)/(1-8*x-6*x^2) + O(x^30)) \\ Colin Barker, Nov 16 2016

Formula

G.f.: (1 + x)/(1 - 8*x - 6*x^2).
a(n) = 8*a(n-1) + 6*a(n-2) with n>1, a(0) = 1, a(1) = 9.
a(n) = (((4-sqrt(22))^n*(-5+sqrt(22)) + (4+sqrt(22))^n*(5+sqrt(22))))/(2*sqrt(22)). - Colin Barker, Nov 16 2016

A255256 Number A(n,k) of 2-colorings of a k X n rectangle such that no nontrivial subsquare has monochromatic corners; square array A(n,k), n>=0, k>=0, read by antidiagonals.

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 4, 4, 1, 1, 8, 14, 8, 1, 1, 16, 50, 50, 16, 1, 1, 32, 178, 276, 178, 32, 1, 1, 64, 634, 1498, 1498, 634, 64, 1, 1, 128, 2258, 8352, 10980, 8352, 2258, 128, 1, 1, 256, 8042, 46730, 85138, 85138, 46730, 8042, 256, 1, 1, 512, 28642, 260204, 655090, 781712, 655090, 260204, 28642, 512, 1
Offset: 0

Author

Alois P. Heinz, Feb 19 2015

Keywords

Examples

			A(2,2) = 2^(2*2) - 2 = 14 because there are exactly two of sixteen 2-colorings of the 2 X 2 square resulting in nontrivial subsquares with monochromatic corners.
Square array A(n,k) begins:
  1,  1,    1,     1,      1,       1,        1, ...
  1,  2,    4,     8,     16,      32,       64, ...
  1,  4,   14,    50,    178,     634,     2258, ...
  1,  8,   50,   276,   1498,    8352,    46730, ...
  1, 16,  178,  1498,  10980,   85138,   655090, ...
  1, 32,  634,  8352,  85138,  781712,  6965108, ...
  1, 64, 2258, 46730, 655090, 6965108, 58339148, ...
		

Crossrefs

Columns (or rows) k=0-5 give: A000012, A000079, A055099, A133357, A255255, A255262.
Main diagonal gives A018803.
Previous Showing 11-20 of 62 results. Next