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 85 results. Next

A197054 T(n,k)=Number of nXk 0..4 arrays with each element equal to the number of its horizontal and vertical zero neighbors.

Original entry on oeis.org

1, 2, 2, 2, 2, 2, 3, 4, 4, 3, 4, 6, 10, 6, 4, 5, 10, 18, 18, 10, 5, 7, 16, 38, 42, 38, 16, 7, 9, 26, 78, 108, 108, 78, 26, 9, 12, 42, 156, 274, 358, 274, 156, 42, 12, 16, 68, 320, 692, 1132, 1132, 692, 320, 68, 16, 21, 110, 654, 1754, 3580, 4468, 3580, 1754, 654, 110, 21, 28
Offset: 1

Views

Author

R. H. Hardin, Oct 09 2011

Keywords

Comments

Every 0 is next to 0 0's, every 1 is next to 1 0's, every 2 is next to 2 0's, every 3 is next to 3 0's, every 4 is next to 4 0's
Also, the number of maximal independent vertex sets in the grid graph P_n X P_k. - Andrew Howroyd, May 16 2017

Examples

			Table starts
..1...2....2.....3......4.......5........7.........9.........12..........16
..2...2....4.....6.....10......16.......26........42.........68.........110
..2...4...10....18.....38......78......156.......320........654........1326
..3...6...18....42....108.....274......692......1754.......4442.......11248
..4..10...38...108....358....1132.....3580.....11382......36270......114992
..5..16...78...274...1132....4468....17742.....70616.....281202.....1117442
..7..26..156...692...3580...17742....88056....439338....2192602....10912392
..9..42..320..1754..11382...70616...439338...2745186...17155374...106972582
.12..68..654..4442..36270..281202..2192602..17155374..134355866..1049189170
.16.110.1326.11248.114992.1117442.10912392.106972582.1049189170.10264692132
...
Some solutions for n=6 k=4
..0..2..1..0....0..2..0..1....2..0..2..0....0..3..0..2....0..2..1..0
..2..0..1..2....1..1..1..1....0..2..1..1....2..0..4..0....3..0..1..2
..1..1..2..0....1..0..2..0....2..1..0..2....1..2..0..2....0..3..1..0
..0..3..0..3....1..1..1..1....0..2..2..0....0..1..1..1....2..0..1..2
..3..0..4..0....0..3..0..2....3..0..1..2....1..1..1..0....1..1..2..0
..0..3..0..2....2..0..3..0....0..2..1..0....1..0..1..1....0..2..0..2
		

Crossrefs

Column 1 is A000931(n+6).
Column 2 is A006355(n+1).
Columns 3-7 are A197049, A197050, A197051, A197052, A197053.
Main diagonal is A197048.
Cf. A089934 (independent sets), A218354 (dominating sets).

A006367 Number of binary vectors of length n+1 beginning with 0 and containing just 1 singleton.

Original entry on oeis.org

1, 0, 2, 2, 5, 8, 15, 26, 46, 80, 139, 240, 413, 708, 1210, 2062, 3505, 5944, 10059, 16990, 28646, 48220, 81047, 136032, 228025, 381768, 638450, 1066586, 1780061, 2968040, 4944519, 8230370, 13689118, 22751528, 37786915, 62716752, 104028245
Offset: 0

Views

Author

David M. Bloom

Keywords

Comments

Number of compositions of n+1 containing exactly one 1. - Emeric Deutsch, Mar 08 2002
Number of permutations with one fixed point avoiding 231 and 321.
A singleton is a run of length 1. - Michael Somos, Nov 29 2014
Second column of A105422. - Michael Somos, Nov 29 2014
Number of weak compositions of n with one 0 and no 1's. Example: Combine one 0 with the compositions of 5 without 1 to get a(5) = 8 weak compositions: 0,5; 5,0; 0,2,3; 0,3,2; 2,0,3; 3,0,2; 2,3,0; 3,2,0. - Gregory L. Simay, Mar 21 2018

Examples

			a(4) = 5 because among the 2^4 compositions of 5 only 4+1,1+4,2+2+1,2+1+2,1+2+2 contain exactly one 1.
a(4) = 5 because the binary vectors of length 4+1 beginning with 0 and with exactly one singleton are: 00001, 00100, 00110, 01100, 01111. - _Michael Somos_, Nov 29 2014
G.f. = 1 + 2*x^2 + 2*x^3 + 5*x^4 + 8*x^5 + 15*x^6 + 26*x^7 + 46*x^8 + ...
		

Crossrefs

Programs

  • Magma
    I:=[1,0]; [n le 2 select I[n] else Self(n-1)+Self(n-2)+Fibonacci(n-3): n in [1..40]]; // Vincenzo Librandi, Feb 20 2014
    
  • Mathematica
    nn=36; CoefficientList[Series[1/(1 -x/(1-x) +x)^2, {x, 0, nn}], x] (* Geoffrey Critzer, Feb 18 2014 *)
    a[n_]:= If[ n<0, SeriesCoefficient[((1-x)/(1+x-x^2))^2, {x, 0, -2-n}], SeriesCoefficient[((1-x)/(1-x-x^2))^2, {x, 0, n}]]; (* Michael Somos, Nov 29 2014 *)
  • PARI
    Vec( (1-x)^2/(1-x-x^2)^2 + O(x^66) ) \\ Joerg Arndt, Feb 20 2014
    
  • PARI
    {a(n) = if( n<0, n = -2-n; polcoeff( (1 - x)^2 / (1 + x - x^2)^2 + x * O(x^n), n), polcoeff( (1 - x)^2 / (1 - x - x^2)^2 + x * O(x^n), n))}; /* Michael Somos, Nov 29 2014 */
    
  • Python
    from sympy import fibonacci
    from sympy.core.cache import cacheit
    @cacheit
    def a(n): return 1 if n==0 else 0 if n==1 else a(n - 1) + a(n - 2) + fibonacci(n - 3)
    print([a(n) for n in range(51)]) # Indranil Ghosh, Jul 20 2017
    
  • SageMath
    def A006367(n): return (1/5)*(n*lucas_number2(n-2, 1, -1) + fibonacci(n+1) + 4*fibonacci(n-1))
    [A006367(n) for n in (0..40)] # G. C. Greubel, Apr 06 2022

Formula

a(n) = a(n-1) + a(n-2) + Fibonacci(n-3).
G.f.: (1-x)^2/(1-x-x^2)^2. - Emeric Deutsch, Mar 08 2002
a(n) = A010049(n+1) - A010049(n). - R. J. Mathar, May 30 2014
Convolution square of A212804. - Michael Somos, Nov 29 2014
a(n) = -(-1)^n * A004798(-1-n) for all n in Z. - Michael Somos, Nov 29 2014
0 = a(n)*(-2*a(n) - 7*a(n+1) + 2*a(n+2) + a(n+3)) + a(n+1)*(-4*a(n+1) + 10*a(n+2) - 2*a(n+3)) + a(n+2)*(+4*a(n+2) - 7*a(n+3)) + a(n+3)*(+2*a(n+3)) for all n in Z. - Michael Somos, Nov 29 2014
a(n) = (n*Lucas(n-2) + Fibonacci(n))/5 + Fibonacci(n-1). - Ehren Metcalfe, Jul 29 2017

A118658 a(n) = 2*F(n-1) = L(n) - F(n), where F(n) and L(n) are Fibonacci and Lucas numbers respectively.

Original entry on oeis.org

2, 0, 2, 2, 4, 6, 10, 16, 26, 42, 68, 110, 178, 288, 466, 754, 1220, 1974, 3194, 5168, 8362, 13530, 21892, 35422, 57314, 92736, 150050, 242786, 392836, 635622, 1028458, 1664080, 2692538, 4356618, 7049156, 11405774, 18454930, 29860704, 48315634, 78176338
Offset: 0

Views

Author

Bill Jones (b92057(AT)yahoo.com), May 18 2006

Keywords

Comments

Essentially the same as A006355, A047992, A054886, A055389, A068922, A078642, A090991. - Philippe Deléham, Sep 20 2006 and Georg Fischer, Oct 07 2018
Also the number of matchings in the (n-2)-pan graph. - Eric W. Weisstein, Jun 30 2016
Also the number of maximal independent vertex sets (and minimal vertex covers) in the (n-1)-ladder graph. - Eric W. Weisstein, Jun 30 2017

Crossrefs

Programs

Formula

From Philippe Deléham, Sep 20 2006: (Start)
a(0)=2, a(1)=0; for n > 1, a(n) = a(n-1) + a(n-2).
G.f. (2 - 2*x)/(1 - x - x^2).
a(0)=2 and a(n) = 2*A000045(n-1) for n > 0. (End)
a(n) = A006355(n) + 0^n. - M. F. Hasler, Nov 05 2014
a(n) = Lucas(n-2) + Fibonacci(n-2). - Bruno Berselli, May 27 2015
a(n) = 3*Fibonacci(n-2) + Fibonacci(n-5). - Bruno Berselli, Feb 20 2017
a(n) = 2*A212804(n). - Bruno Berselli, Feb 21 2017
E.g.f.: 2*exp(x/2)*(5*cosh(sqrt(5)*x/2) - sqrt(5)*sinh(sqrt(5)*x/2))/5. - Stefano Spezia, Apr 18 2022

Extensions

More terms from Philippe Deléham, Sep 20 2006
Corrected by T. D. Noe, Nov 01 2006

A220062 Number A(n,k) of n length words over k-ary alphabet, where neighboring letters are neighbors in the alphabet; square array A(n,k), n>=0, k>=0, read by antidiagonals.

Original entry on oeis.org

1, 1, 0, 1, 1, 0, 1, 2, 0, 0, 1, 3, 2, 0, 0, 1, 4, 4, 2, 0, 0, 1, 5, 6, 6, 2, 0, 0, 1, 6, 8, 10, 8, 2, 0, 0, 1, 7, 10, 14, 16, 12, 2, 0, 0, 1, 8, 12, 18, 24, 26, 16, 2, 0, 0, 1, 9, 14, 22, 32, 42, 42, 24, 2, 0, 0, 1, 10, 16, 26, 40, 58, 72, 68, 32, 2, 0, 0
Offset: 0

Views

Author

Alois P. Heinz, Dec 03 2012

Keywords

Comments

Equivalently, the number of walks of length n-1 on the path graph P_k. - Andrew Howroyd, Apr 17 2017

Examples

			A(5,3) = 12: there are 12 words of length 5 over 3-ary alphabet {a,b,c}, where neighboring letters are neighbors in the alphabet: ababa, ababc, abcba, abcbc, babab, babcb, bcbab, bcbcb, cbaba, cbabc, cbcba, cbcbc.
Square array A(n,k) begins:
  1,  1,  1,  1,  1,   1,   1,   1, ...
  0,  1,  2,  3,  4,   5,   6,   7, ...
  0,  0,  2,  4,  6,   8,  10,  12, ...
  0,  0,  2,  6, 10,  14,  18,  22, ...
  0,  0,  2,  8, 16,  24,  32,  40, ...
  0,  0,  2, 12, 26,  42,  58,  74, ...
  0,  0,  2, 16, 42,  72, 104, 136, ...
  0,  0,  2, 24, 68, 126, 188, 252, ...
		

Crossrefs

Columns k=0, 2-10 give: A000007, A040000, A029744(n+2) for n>0, A006355(n+3) for n>0, A090993(n+1) for n>0, A090995(n-1) for n>2, A129639, A153340, A153362, A153360.
Rows 0-6 give: A000012, A001477, A005843(k-1) for k>0, A016825(k-2) for k>1, A008590(k-2) for k>2, A113770(k-2) for k>3, A063164(k-2) for k>4.
Main diagonal gives: A102699.

Programs

  • Maple
    b:= proc(n, i, k) option remember; `if`(n=0, 1,
          `if`(i=0, add(b(n-1, j, k), j=1..k),
          `if`(i>1, b(n-1, i-1, k), 0)+
          `if`(i b(n, 0, k):
    seq(seq(A(n, d-n), n=0..d), d=0..14);
  • Mathematica
    b[n_, i_, k_] := b[n, i, k] = If[n == 0, 1, If[i == 0, Sum[b[n-1, j, k], {j, 1, k}], If[i>1, b[n-1, i-1, k], 0] + If[iJean-François Alcover, Jan 19 2015, after Alois P. Heinz *)
  • PARI
    TransferGf(m,u,t,v,z)=vector(m,i,u(i))*matsolve(matid(m)-z*matrix(m,m,i,j,t(i,j)),vectorv(m,i,v(i)));
    ColGf(m,z)=1+z*TransferGf(m, i->1, (i,j)->abs(i-j)==1, j->1, z);
    a(n,k)=Vec(ColGf(k,x) + O(x^(n+1)))[n+1];
    for(n=0, 7, for(k=0, 7, print1( a(n,k), ", ") ); print(); );
    \\ Andrew Howroyd, Apr 17 2017

A002062 a(n) = Fibonacci(n) + n.

Original entry on oeis.org

0, 2, 3, 5, 7, 10, 14, 20, 29, 43, 65, 100, 156, 246, 391, 625, 1003, 1614, 2602, 4200, 6785, 10967, 17733, 28680, 46392, 75050, 121419, 196445, 317839, 514258, 832070, 1346300, 2178341, 3524611, 5702921, 9227500, 14930388, 24157854, 39088207, 63246025
Offset: 0

Views

Author

Keywords

Comments

Let A006355(n+4)_0%20-%20A066982(n+1)_1%20(conjecture);%20(a(n))%20=%20em%5BK*%20%5Dseq(%20.25'i%20-%20.25'j%20-%20.25'k%20-%20.25i'%20+%20.25j'%20-%20.75k'%20-%20.25'ii'%20-%20.25'jj'%20-%20.25'kk'%20-%20.25'ij'%20-%20.25'ik'%20-%20.75'ji'%20+%20.25'jk'%20-%20.25'ki'%20-%20.75'kj'%20+%20.75e),%20apart%20from%20initial%20term.%20-%20_Creighton%20Dement">x indicate the sequence offset. Then a(n+2)_0 = A006355(n+4)_0 - A066982(n+1)_1 (conjecture); (a(n)) = em[K* ]seq( .25'i - .25'j - .25'k - .25i' + .25j' - .75k' - .25'ii' - .25'jj' - .25'kk' - .25'ij' - .25'ik' - .75'ji' + .25'jk' - .25'ki' - .75'kj' + .75e), apart from initial term. - _Creighton Dement, Nov 19 2004

References

  • R. Honsberger, Ingenuity in Math., Random House, 1970, p. 96.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

  • GAP
    List([0..50], n-> Fibonacci(n)+n); # G. C. Greubel, Jul 09 2019
  • Haskell
    a002062 n = a000045 n + toInteger n
    a002062_list = 0 : 2 : 3 : (map (subtract 1) $
       zipWith (-) (map (* 2) $ drop 2 a002062_list) a002062_list)
    -- Reinhard Zumkeller, Oct 03 2012
    
  • Magma
    [Fibonacci(n)+n: n in [0..50]]; // G. C. Greubel, Jul 09 2019
    
  • Maple
    a:= n-> combinat[fibonacci](n)+n: seq(a(n), n=0..50); # Zerinvary Lajos, Mar 20 2008
  • Mathematica
    Table[Fibonacci[n]+n,{n,0,50}] (* Harvey P. Dale, Jul 27 2011 *)
  • MuPAD
    numlib::fibonacci(n)+n $ n = 0..50; // Zerinvary Lajos, May 08 2008
    
  • PARI
    a(n)=fibonacci(n) + n \\ Charles R Greathouse IV, Oct 03 2016
    
  • Sage
    [fibonacci(n)+n for n in (0..50)] # G. C. Greubel, Jul 09 2019
    

Formula

G.f.: x*(-2+3*x) / ( (x^2+x-1)*(x-1)^2 ). - Simon Plouffe in his 1992 dissertation
From Wolfdieter Lang: (Start)
Convolution of natural numbers n >= 1 with Fibonacci numbers F(k), k >= -3, (F(-k)=(-1)^(k+1)*F(k));
G.f.: x*(2-3*x)/((1-x-x^2)*(1-x)^2). (End)
a(n) = 2*a(n-1) - a(n-3) - 1. - Kieren MacMillan, Nov 08 2008
a(n) = 3*a(n-1) - 2*a(n-2) - a(n-3) + a(n-4). - Emmanuel Vantieghem, May 19 2016
E.g.f.: 2*exp(x/2)*sinh(sqrt(5)*x/2)/sqrt(5) + x*exp(x). - Ilya Gutkovskiy, Apr 11 2017

A200871 T(n,k)=Number of 0..k arrays x(0..n+1) of n+2 elements without any interior element greater than both neighbors or less than both neighbors.

Original entry on oeis.org

6, 17, 10, 36, 37, 16, 65, 94, 77, 26, 106, 195, 236, 163, 42, 161, 356, 567, 602, 343, 68, 232, 595, 1168, 1673, 1528, 723, 110, 321, 932, 2163, 3886, 4917, 3882, 1523, 178, 430, 1389, 3704, 7973, 12890, 14455, 9858, 3209, 288, 561, 1990, 5973, 14932, 29325
Offset: 1

Views

Author

R. H. Hardin Nov 23 2011

Keywords

Comments

Table starts
...6....17.....36......65.....106......161......232.......321.......430
..10....37.....94.....195.....356......595......932......1389......1990
..16....77....236.....567....1168.....2163.....3704......5973......9184
..26...163....602....1673....3886.....7973....14932.....26073.....43066
..42...343...1528....4917...12890....29325....60112....113745....201994
..68...723...3882...14455...42744...107777...241718....495495....945790
.110..1523...9858...42479..141688...395929...971416...2156867...4424298
.178..3209..25038..124851..469726..1454643..3904290...9389377..20696974
.288..6761..63592..366959.1557320..5344795.15693816..40880321..96838448
.466.14245.161514.1078565.5163158.19638715.63085186.177996275.453123270

Examples

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

Crossrefs

Column 1 is A006355(n+4)
Row 1 is A084990(n+1)

Programs

  • Mathematica
    t[0,k_,x_,y_] := 1; t[n_,k_,x_,y_] := t[n,k,x,y] = Sum[If[z <= x <= y || y <= x <= z, t[n-1, k, z, x], 0], {z, k+1}]; t[n_, k_] := Sum[t[n, k, x, y], {x, k+1}, {y, k+1}]; TableForm@ Table[t[n, k], {n, 8}, {k, 8}] (* Giovanni Resta, Mar 05 2014 *)

Formula

Empirical for columns:
k=1: a(n) = a(n-1) +a(n-2)
k=2: a(n) = 2*a(n-1) +a(n-4)
k=3: a(n) = 2*a(n-1) +a(n-2) +2*a(n-4) +a(n-5)
k=4: a(n) = 3*a(n-1) -a(n-2) +a(n-3) +4*a(n-4) +a(n-6) +a(n-7)
k=5: a(n) = 3*a(n-1) +a(n-3) +7*a(n-4) +3*a(n-5) +2*a(n-6) +3*a(n-7) +a(n-8)
k=6: a(n) = 4*a(n-1) -3*a(n-2) +4*a(n-3) +9*a(n-4) +7*a(n-6) +6*a(n-7) +a(n-8) +2*a(n-9) +a(n-10)
k=7: a(n) = 4*a(n-1) -2*a(n-2) +4*a(n-3) +15*a(n-4) +6*a(n-5) +12*a(n-6) +16*a(n-7) +7*a(n-8) +5*a(n-9) +4*a(n-10) +a(n-11)
Empirical for rows:
n=1: a(k) = (1/3)*k^3 + 2*k^2 + (8/3)*k + 1
n=2: a(k) = (1/12)*k^4 + (3/2)*k^3 + (47/12)*k^2 + (7/2)*k + 1
n=3: a(k) = (1/60)*k^5 + (3/4)*k^4 + (15/4)*k^3 + (25/4)*k^2 + (127/30)*k + 1
n=4: a(k) = (1/360)*k^6 + (7/24)*k^5 + (197/72)*k^4 + (185/24)*k^3 + (1667/180)*k^2 + 5*k + 1
n=5: a(k) = (1/2520)*k^7 + (17/180)*k^6 + (281/180)*k^5 + (64/9)*k^4 + (4927/360)*k^3 + (2303/180)*k^2 + (604/105)*k + 1
n=6: a(k) = (1/20160)*k^8 + (19/720)*k^7 + (211/288)*k^6 + (1889/360)*k^5 + (44167/2880)*k^4 + (15991/720)*k^3 + (5689/336)*k^2 + (391/60)*k + 1
n=7: a(k) = (1/181440)*k^9 + (131/20160)*k^8 + (8893/30240)*k^7 + (4621/1440)*k^6 + (118933/8640)*k^5 + (83957/2880)*k^4 + (763489/22680)*k^3 + (36343/1680)*k^2 + (9169/1260)*k + 1

A218064 T(n,k) = Number of n X k arrays of the minimum value of corresponding elements and their horizontal or antidiagonal neighbors in a random 0..1 n X k array.

Original entry on oeis.org

2, 2, 4, 4, 6, 8, 6, 18, 16, 16, 10, 42, 74, 42, 32, 16, 108, 260, 308, 110, 64, 26, 268, 1046, 1664, 1282, 288, 128, 42, 676, 3974, 10246, 10566, 5338, 754, 256, 68, 1694, 15578, 60804, 99934, 66978, 22228, 1974, 512, 110, 4258, 60242, 368220, 925904, 975296
Offset: 1

Views

Author

R. H. Hardin Oct 19 2012

Keywords

Comments

Table starts
....2.....2........4..........6...........10..............16................26
....4.....6.......18.........42..........108.............268...............676
....8....16.......74........260.........1046............3974.............15578
...16....42......308.......1664........10246...........60804............368220
...32...110.....1282......10566........99934..........925904...........8679594
...64...288.....5338......66978.......975296........14096488.........204211050
..128...754....22228.....424332......9519284.......214514380........4803404048
..256..1974....92562....2687866.....92918894......3263893360......112984025006
..512..5168...385450...17025060....907013406.....49658510202.....2657601417086
.1024.13530..1605108..107835994...8853740672....755518606946....62512388662498
.2048.35422..6684066..683025864..86425318934..11494629017172..1470427119098160
.4096.92736.27834106.4326234664.843636853718.174881679122376.34587669928567490

Examples

			Some solutions for n=3, k=4
..1..0..0..0....0..0..1..0....1..1..1..1....0..0..0..0....1..0..0..0
..1..0..1..0....0..0..0..0....1..1..0..0....1..1..0..0....0..0..0..0
..0..0..0..0....1..0..0..1....1..0..0..0....0..0..0..0....1..1..0..1
		

Crossrefs

Column 2 is A025169(n-1).
Row 1 is A006355(n+1).

A218897 T(n,k)=Number of nXk arrays of the minimum value of corresponding elements and their horizontal, diagonal or antidiagonal neighbors in a random 0..1 nXk array.

Original entry on oeis.org

2, 2, 4, 4, 6, 8, 6, 18, 16, 16, 10, 34, 72, 38, 32, 16, 86, 212, 286, 98, 64, 26, 180, 786, 1096, 1162, 244, 128, 42, 426, 2594, 6280, 6422, 4700, 614, 256, 68, 930, 9110, 28598, 54726, 35812, 19046, 1542, 512, 110, 2140, 31062, 149238, 373612, 463746, 202662
Offset: 1

Views

Author

R. H. Hardin Nov 08 2012

Keywords

Comments

Table starts
....2.....2........4..........6...........10.............16...............26
....4.....6.......18.........34...........86............180..............426
....8....16.......72........212..........786...........2594.............9110
...16....38......286.......1096.........6280..........28598...........149238
...32....98.....1162.......6422........54726.........373612..........2880294
...64...244.....4700......35812.......463746........4575512.........52413310
..128...614....19046.....202662......3960146.......57116962........969423130
..256..1542....77198....1143320.....33785542......710022390......17870306268
..512..3872...312944....6451714....288335090.....8831593874.....329607859688
.1024..9726..1268694...36412818...2461034914...109858747456....6079480914622
.2048.24426..5143506..205486910..21006978672..1366468080924..112133703714680
.4096.61348.20852924.1159668470.179319456042.16997248406138.2068302082008760

Examples

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

Crossrefs

Column 2 is A217631
Row 1 is A006355(n+1)

A245869 T(n,k)=Number of length n+2 0..k arrays with some pair in every consecutive three terms totalling exactly k.

Original entry on oeis.org

6, 19, 10, 36, 45, 16, 61, 100, 103, 26, 90, 193, 256, 239, 42, 127, 318, 549, 676, 553, 68, 168, 493, 960, 1629, 1764, 1281, 110, 217, 712, 1579, 3102, 4753, 4624, 2967, 178, 270, 993, 2368, 5515, 9726, 13961, 12100, 6873, 288, 331, 1330, 3433, 8840, 18505, 30900
Offset: 1

Views

Author

R. H. Hardin, Aug 04 2014

Keywords

Comments

Table starts
.....6.......19........36.........61..........90..........127..........168
....10.......45.......100........193.........318..........493..........712
....16......103.......256........549.........960.........1579.........2368
....26......239.......676.......1629........3102.........5515.........8840
....42......553......1764.......4753........9726........18505........31176
....68.....1281......4624......13961.......30900........63241.......113024
...110.....2967.....12100......40901.......97602.......214315.......404264
...178.....6873.....31684.....119953......309078.......729097......1455496
...288....15921.....82944.....351649......977664......2475985......5223552
...466....36881....217156....1031057.....3094038......8415217.....18775816
...754....85435....568516....3022933.....9789654.....28590415.....67437448
..1220...197911...1488400....8863117....30977796.....97151683....242306240
..1974...458463...3896676...25986061....98020170....330100459....870461352
..3194..1062035..10201636...76189749...310161870...1121650903...3127322696
..5168..2460217..26708224..223384017...981426624...3811203385..11235107264
..8362..5699123..69923044..654949861..3105480558..12950003383..40363689352
.13530.13202089.183060900.1920277409..9826505742..44002376953.145010699592
.21892.30582803.479259664.5630150189.31093507092.149514426895.520968428032

Examples

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

Crossrefs

Column 1 is A006355(n+4)
Column 3 is A206981(n+2)
Row 1 is A090381.

Formula

Empirical for column k:
k=1: a(n) = a(n-1) +a(n-2)
k=2: a(n) = 2*a(n-1) +a(n-2) -a(n-4) -a(n-5)
k=3: a(n) = 2*a(n-1) +2*a(n-2) -a(n-3)
k=4: a(n) = 3*a(n-1) +a(n-2) -a(n-3) -5*a(n-4) -8*a(n-5) +3*a(n-6)
k=5: a(n) = 2*a(n-1) +4*a(n-2) -a(n-3)
k=6: a(n) = 3*a(n-1) +3*a(n-2) -a(n-3) -9*a(n-4) -24*a(n-5) +5*a(n-6)
k=7: a(n) = 2*a(n-1) +6*a(n-2) -a(n-3)
k=8: a(n) = 3*a(n-1) +5*a(n-2) -a(n-3) -13*a(n-4) -48*a(n-5) +7*a(n-6)
k=9: a(n) = 2*a(n-1) +8*a(n-2) -a(n-3)
Empirical for row n:
n=1: a(n) = 2*a(n-1) -2*a(n-3) +a(n-4)
n=2: a(n) = 3*a(n-1) -2*a(n-2) -2*a(n-3) +3*a(n-4) -a(n-5)
n=3: a(n) = 2*a(n-1) +a(n-2) -4*a(n-3) +a(n-4) +2*a(n-5) -a(n-6)
n=4: a(n) = 3*a(n-1) -a(n-2) -5*a(n-3) +5*a(n-4) +a(n-5) -3*a(n-6) +a(n-7)
n=5: a(n) = 2*a(n-1) +2*a(n-2) -6*a(n-3) +6*a(n-5) -2*a(n-6) -2*a(n-7) +a(n-8)
n=6: a(n) = 3*a(n-1) -8*a(n-3) +6*a(n-4) +6*a(n-5) -8*a(n-6) +3*a(n-8) -a(n-9)
n=7: a(n) = 2*a(n-1) +3*a(n-2) -8*a(n-3) -2*a(n-4) +12*a(n-5) -2*a(n-6) -8*a(n-7) +3*a(n-8) +2*a(n-9) -a(n-10)
From Robert Israel, Aug 06 2024: (Start) For odd k, T(n,k) = 2 T(n-1,k) + (k-1) T(n-2,k) - T(n-3,k).
For even k, T(n,k) = 3 T(n-1,k) + (k-3) T(n-2,k) - T(n-3,k) + (2 k - 3) T(n-4,k) - k (k-2) T(n-5,k) + (k-1) T(n-6,k).
See links. (End)

A248461 T(n,k)=Number of length n+2 0..k arrays with no three consecutive terms having the sum of any two elements equal to twice the third.

Original entry on oeis.org

6, 18, 10, 48, 36, 16, 96, 148, 72, 26, 174, 380, 460, 144, 42, 282, 862, 1512, 1436, 288, 68, 432, 1652, 4272, 6040, 4488, 576, 110, 624, 2956, 9684, 21182, 24160, 14040, 1152, 178, 870, 4860, 20236, 56782, 105026, 96736, 43940, 2304, 288, 1170, 7642, 37868
Offset: 1

Views

Author

R. H. Hardin, Oct 06 2014

Keywords

Comments

Table starts
...6...18......48.......96.......174........282.........432.........624
..10...36.....148......380.......862.......1652........2956........4860
..16...72.....460.....1512......4272.......9684.......20236.......37868
..26..144....1436.....6040.....21182......56782......138534......295078
..42..288....4488....24160....105026.....332940......948412.....2299356
..68..576...14040....96736....520788....1952254.....6493036....17917712
.110.1152...43940...387488...2582406...11447368....44452660...139623544
.178.2304..137532..1552448..12805334...67123652...304332258..1088015294
.288.4608..430508..6220480..63497776..393591402..2083523194..8478351478
.466.9216.1347652.24926080.314866606.2307892826.14264241960.66067495706

Examples

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

Crossrefs

Column 1 is A006355(n+4)
Column 2 is A005010

Formula

Empirical for column k:
k=1: a(n) = a(n-1) +a(n-2)
k=2: a(n) = 2*a(n-1)
k=3: a(n) = 2*a(n-1) +3*a(n-2) +4*a(n-3) -3*a(n-4) -12*a(n-5) -4*a(n-6)
k=4: a(n) = 3*a(n-1) +5*a(n-2) +2*a(n-3) -16*a(n-4) -28*a(n-5) -8*a(n-6)
k=5: [order 12]
k=6: [order 16]
k=7: [order 22]
Empirical for row n:
n=1: a(n) = 3*a(n-1) -2*a(n-2) -2*a(n-3) +3*a(n-4) -a(n-5); also a cubic polynomial plus a constant quasipolynomial with period 2
n=2: a(n) = 2*a(n-1) -a(n-3) -2*a(n-5) +2*a(n-6) +a(n-8) -2*a(n-10) +a(n-11); also a quartic polynomial plus a linear quasipolynomial with period 12
n=3: [order 27; also a degree 5 polynomial plus a quadratic quasipolynomial with period 840]
n=4: [order 61]
Previous Showing 11-20 of 85 results. Next