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.

A268995 T(n,k)=Number of nXk binary arrays with some element plus some horizontally or antidiagonally adjacent neighbor totalling two not more than once.

Original entry on oeis.org

2, 4, 4, 7, 13, 8, 13, 35, 41, 16, 23, 103, 174, 126, 32, 41, 278, 805, 849, 379, 64, 72, 763, 3331, 6009, 4083, 1121, 128, 126, 2037, 14080, 37987, 43512, 19416, 3272, 256, 219, 5421, 57287, 244397, 421450, 308112, 91491, 9449, 512, 379, 14264, 232449, 1506570
Offset: 1

Views

Author

R. H. Hardin, Feb 17 2016

Keywords

Comments

Table starts
....2.....4.......7........13..........23............41..............72
....4....13......35.......103.........278...........763............2037
....8....41.....174.......805........3331.........14080...........57287
...16...126.....849......6009.......37987........244397.........1506570
...32...379....4083.....43512......421450.......4097199........38241770
...64..1121...19416....308112.....4583103......66954420.......946498448
..128..3272...91491...2144780....49084071....1073436321.....22995344760
..256..9449..427863..14730784...519385102...16957258387....550731432312
..512.27049.1988142.100087792..5442503771..264744926212..13040291111728
.1024.76866.9187653.674045392.56571775611.4093941136805.305911647779632

Examples

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

Crossrefs

Column 1 is A000079.
Row 1 is A208354(n+1).

Formula

Empirical for column k:
k=1: a(n) = 2*a(n-1)
k=2: a(n) = 6*a(n-1) -11*a(n-2) +6*a(n-3) -a(n-4)
k=3: a(n) = 10*a(n-1) -31*a(n-2) +30*a(n-3) -9*a(n-4)
k=4: a(n) = 16*a(n-1) -88*a(n-2) +200*a(n-3) -208*a(n-4) +96*a(n-5) -16*a(n-6) for n>7
k=5: [order 8] for n>9
k=6: [order 10] for n>12
k=7: [order 14] for n>16
Empirical for row n:
n=1: a(n) = 2*a(n-1) +a(n-2) -2*a(n-3) -a(n-4)
n=2: a(n) = 2*a(n-1) +5*a(n-2) -4*a(n-3) -11*a(n-4) -6*a(n-5) -a(n-6)
n=3: [order 9]
n=4: [order 16]
n=5: [order 26]
n=6: [order 42]
n=7: [order 68]

A269075 T(n,k)=Number of nXk binary arrays with some element plus some horizontally, diagonally or antidiagonally adjacent neighbor totalling two not more than once.

Original entry on oeis.org

2, 4, 4, 7, 11, 8, 13, 27, 32, 16, 23, 76, 123, 89, 32, 41, 185, 521, 537, 244, 64, 72, 489, 1887, 3288, 2343, 659, 128, 126, 1204, 7477, 17713, 20400, 10167, 1760, 256, 219, 3059, 27042, 102545, 165607, 123976, 43959, 4657, 512, 379, 7539, 102070, 542112
Offset: 1

Views

Author

R. H. Hardin, Feb 19 2016

Keywords

Comments

Table starts
....2.....4.......7........13..........23...........41.............72
....4....11......27........76.........185..........489...........1204
....8....32.....123.......521........1887.........7477..........27042
...16....89.....537......3288.......17713.......102545.........542112
...32...244....2343.....20400......165607......1383105.......10778640
...64...659...10167....123976.....1529241.....18220241......210476400
..128..1760...43959....742688....14011359....236272677.....4064720816
..256..4657..189465...4397376...127528641...3024972401....77785162880
..512.12228..814359..25791040..1154377943..38333973609..1477636398784
.1024.31899.3491691.150081504.10400164377.481701017577.27897108860960

Examples

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

Crossrefs

Column 1 is A000079.
Column 2 is A268744.
Row 1 is A208354(n+1).

Formula

Empirical for column k:
k=1: a(n) = 2*a(n-1)
k=2: a(n) = 4*a(n-1) -2*a(n-2) -4*a(n-3) -a(n-4)
k=3: a(n) = 10*a(n-1) -31*a(n-2) +24*a(n-3) +21*a(n-4) -18*a(n-5) -9*a(n-6)
k=4: a(n) = 12*a(n-1) -40*a(n-2) +8*a(n-3) +92*a(n-4) -32*a(n-5) -64*a(n-6) for n>7
k=5: [order 12]
k=6: [order 14]
k=7: [order 24] for n>25
Empirical for row n:
n=1: a(n) = 2*a(n-1) +a(n-2) -2*a(n-3) -a(n-4)
n=2: a(n) = 2*a(n-1) +5*a(n-2) -6*a(n-3) -9*a(n-4)
n=3: a(n) = 4*a(n-1) +8*a(n-2) -34*a(n-3) -16*a(n-4) +60*a(n-5) -25*a(n-6)
n=4: [order 8]
n=5: [order 14]

A103450 A figurate number triangle read by rows.

Original entry on oeis.org

1, 1, 1, 1, 3, 1, 1, 5, 5, 1, 1, 7, 12, 7, 1, 1, 9, 22, 22, 9, 1, 1, 11, 35, 50, 35, 11, 1, 1, 13, 51, 95, 95, 51, 13, 1, 1, 15, 70, 161, 210, 161, 70, 15, 1, 1, 17, 92, 252, 406, 406, 252, 92, 17, 1, 1, 19, 117, 372, 714, 882, 714, 372, 117, 19, 1, 1, 21, 145, 525, 1170, 1722, 1722, 1170, 525, 145, 21, 1
Offset: 0

Views

Author

Paul Barry, Feb 06 2005

Keywords

Comments

Row coefficients are the absolute values of the coefficients of the characteristic polynomials of the n X n matrices A(n) with A(n){i,i} = 2, i>0, A(n){i,j} = 1, otherwise (starts with (0,0) position).
The triangle can be generated by the matrix multiplication A007318 * A114219s, where A114219s = 0; 0,1; 0,1,1; 0,-1,2,1; 0,1,-2,3,1; 0,-1,2,-3,4,1; ... = A097807 * A128229 is a signed variant of A114219. - Gary W. Adamson, Feb 20 2007

Examples

			From _Roger L. Bagula_, Oct 21 2008: (Start)
The triangle begins:
  1;
  1,  1;
  1,  3,   1;
  1,  5,   5,   1;
  1,  7,  12,   7,   1;
  1,  9,  22,  22,   9,   1;
  1, 11,  35,  50,  35,  11,   1;
  1, 13,  51,  95,  95,  51,  13,   1;
  1, 15,  70, 161, 210, 161,  70,  15,   1;
  1, 17,  92, 252, 406, 406, 252,  92,  17,  1;
  1, 19, 117, 372, 714, 882, 714, 372, 117, 19, 1; ... (End)
		

Crossrefs

Row sums are A045623.
Columns include: A000326, A002412, A002418, A005408.

Programs

  • Magma
    A103450:= func< n,k | k eq 0 select 1 else Binomial(n, k)*(k*(n-k) + n)/n >;
    [A103450(n,k): k in [0..n], n in [0..12]]; // G. C. Greubel, Jun 17 2021
    
  • Mathematica
    (* First program *)
    p[x_, n_]:= p[x, n]= If[n==0, 1, (-1+x)^(n-2)*(1 -(n+1)*x +x^2)];
    T[n_, k_]:= T[n,k]= (-1)^(n+k)*SeriesCoefficient[p[x, n], {x, 0, k}];
    Table[T[n, k], {n,0,12}, {k,0,n}]//Flatten (* Roger L. Bagula and Gary W. Adamson, Oct 21 2008 *)(* corrected by G. C. Greubel, Jun 17 2021 *)
    (* Second program *)
    T[n_, k_]:= If[k==0, 1, Binomial[n, k]*(n*(k+1) -k^2)/n];
    Table[T[n, k], {n,0,16}, {k,0,n}]//Flatten (* G. C. Greubel, Jun 17 2021 *)
  • Sage
    def A103450(n, k): return 1 if (k==0) else binomial(n, k)*(k*(n-k) + n)/n
    flatten([[A103450(n,k) for k in (0..n)] for n in (0..12)]) # G. C. Greubel, Jun 17 2021

Formula

T(n, k) = binomial(n-1, k-1)*(k*(n-k) + n)/k with T(n, 0) = 1.
T(n, k) = T(n-1, k-1) + T(n-1, k) + binomial(n-2, k-1) with T(n, 0) = 1.
Column k is generated by (1+k*x)*x^k/(1-x)^(k+1).
Rows are coefficients of the polynomials P(0, x) = 1, P(n, x) = (1+x)^(n-2)*(1 +(n+1)*x + x^2) for n>0.
T(n,k) = Sum_{j=0..n} binomial(k, k-j)*binomial(n-k, j)*(j+1). - Paul Barry, Oct 28 2006
A signed version arises from the coefficients of the polynomials defined by: p(x, 0) = 1, p(x, 1) = (-1 +x), p(x, 2) = (1 -3*x +x^2), p(x,n) = (-1 +x)^(n-2)*(1 - (n + 1)*x + x^2); T(n, k) = (-1)^(n+k)*coefficient of x^k of ( p(x,n) ). - Roger L. Bagula and Gary W. Adamson, Oct 21 2008
T(2*n+1, n) = A141222(n). - Emanuele Munarini, Jun 01 2012 [corrected by Werner Schulte, Nov 27 2021]
G.f.: is 1 / ( (1-q*x/(1-x)) * (1-x/(1-q*x)) ). - Joerg Arndt, Aug 27 2013
Sum_{k=0..floor(n/2)} T(n-k, k) = (1/5)*((-n+5)*Fibonacci(n+1) + (3*n- 2)*Fibonacci(n)) = A208354(n). - G. C. Greubel, Jun 17 2021
T(2*n, n) = A000984(n) * (n + 2) / 2 for n >= 0. - Werner Schulte, Nov 27 2021

A268750 T(n,k)=Number of nXk binary arrays with some element plus some horizontally or vertically adjacent neighbor totalling two no more than once.

Original entry on oeis.org

2, 4, 4, 7, 11, 7, 13, 32, 32, 13, 23, 89, 143, 89, 23, 41, 244, 623, 623, 244, 41, 72, 659, 2615, 4110, 2615, 659, 72, 126, 1760, 10830, 26334, 26334, 10830, 1760, 126, 219, 4657, 44067, 165019, 255651, 165019, 44067, 4657, 219, 379, 12228, 177429, 1016807
Offset: 1

Views

Author

R. H. Hardin, Feb 12 2016

Keywords

Comments

Table starts
...2.....4.......7........13..........23............41.............72
...4....11......32........89.........244...........659...........1760
...7....32.....143.......623........2615.........10830..........44067
..13....89.....623......4110.......26334........165019........1016807
..23...244....2615.....26334......255651.......2425799.......22577073
..41...659...10830....165019.....2425799......34732937......487682438
..72..1760...44067...1016807....22577073.....487682438....10319681062
.126..4657..177429...6183665...207252725....6746117783...215027310572
.219.12228..707163..37209717..1880654551...92215499119..4425392044505
.379.31899.2796840.221970102.16909709308.1248437108837.90177748184504

Examples

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

Crossrefs

Column 1 is A208354(n+1).

Formula

Empirical for column k:
k=1: a(n) = 2*a(n-1) +a(n-2) -2*a(n-3) -a(n-4)
k=2: a(n) = 4*a(n-1) -2*a(n-2) -4*a(n-3) -a(n-4)
k=3: a(n) = 4*a(n-1) +8*a(n-2) -24*a(n-3) -38*a(n-4) +4*a(n-5) +12*a(n-6) -a(n-8)
k=4: [order 10]
k=5: [order 18]
k=6: [order 22]
k=7: [order 42]

A268781 T(n,k) = Number of n X k binary arrays with some element plus some horizontally, vertically, diagonally or antidiagonally adjacent neighbor totalling two no more than once.

Original entry on oeis.org

2, 4, 4, 7, 11, 7, 13, 26, 26, 13, 23, 65, 91, 65, 23, 41, 148, 316, 316, 148, 41, 72, 343, 1031, 1462, 1031, 343, 72, 126, 766, 3354, 6383, 6383, 3354, 766, 126, 219, 1709, 10615, 27531, 38483, 27531, 10615, 1709, 219, 379, 3752, 33344, 115391, 224960
Offset: 1

Views

Author

R. H. Hardin, Feb 13 2016

Keywords

Comments

Table starts
...2....4......7......13........23.........41...........72...........126
...4...11.....26......65.......148........343..........766..........1709
...7...26.....91.....316......1031.......3354........10615.........33344
..13...65....316....1462......6383......27531.......115391........478849
..23..148...1031....6383.....38483.....224960......1288693.......7271509
..41..343...3354...27531....224960....1755113.....13493468.....101738555
..72..766..10615..115391...1288693...13493468....140404442....1425678976
.126.1709..33344..478849...7271509..101738555...1425678976...19400886875
.219.3752.103339.1957904..40511381..758303322..14341399141..262072220011
.379.8195.317958.7940136.223527424.5590121407.142487073304.3491534799847

Examples

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

Crossrefs

Column 1 is A208354(n+1).
Diagonal is A143870.

Formula

Empirical for column k:
k=1: a(n) = 2*a(n-1) +a(n-2) -2*a(n-3) -a(n-4).
k=2: a(n) = 2*a(n-1) +3*a(n-2) -4*a(n-3) -4*a(n-4).
k=3: a(n) = 4*a(n-1) +2*a(n-2) -16*a(n-3) -a(n-4) +12*a(n-5) -4*a(n-6).
k=4: [order 8].
k=5: [order 12].
k=6: [order 16].
k=7: [order 28].

A269089 T(n,k)=Number of nXk binary arrays with some element plus some horizontally, vertically or antidiagonally adjacent neighbor totalling two not more than once.

Original entry on oeis.org

2, 4, 4, 7, 11, 7, 13, 30, 30, 13, 23, 76, 114, 76, 23, 41, 191, 428, 428, 191, 41, 72, 467, 1531, 2238, 1531, 467, 72, 126, 1127, 5387, 11314, 11314, 5387, 1127, 126, 219, 2686, 18590, 55620, 80422, 55620, 18590, 2686, 219, 379, 6339, 63347, 268289, 555789
Offset: 1

Views

Author

R. H. Hardin, Feb 19 2016

Keywords

Comments

Table starts
...2.....4......7.......13.........23..........41............72............126
...4....11.....30.......76........191.........467..........1127...........2686
...7....30....114......428.......1531........5387.........18590..........63347
..13....76....428.....2238......11314.......55620........268289........1274435
..23...191...1531....11314......80422......555789.......3761534.......25063389
..41...467...5387....55620.....555789.....5372270......50865307......473602013
..72..1127..18590...268289....3761534....50865307.....673690710.....8768989835
.126..2686..63347..1274435...25063389...473602013....8768989835...159449028034
.219..6339.213490..5982734..164926651..4353444165..112658396453..2861259712706
.379.14840.713237.27813229.1074440360.39602482120.1431998499913.50787612264272

Examples

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

Crossrefs

Column 1 is A208354(n+1).

Formula

Empirical for column k:
k=1: a(n) = 2*a(n-1) +a(n-2) -2*a(n-3) -a(n-4)
k=2: a(n) = 2*a(n-1) +3*a(n-2) -2*a(n-3) -6*a(n-4) -4*a(n-5) -a(n-6)
k=3: [order 10]
k=4: [order 16]
k=5: [order 26]
k=6: [order 42]
k=7: [order 68]

A208514 Triangle of coefficients of polynomials u(n,x) jointly generated with A208515; see the Formula section.

Original entry on oeis.org

1, 1, 1, 1, 2, 2, 1, 3, 4, 3, 1, 4, 6, 7, 5, 1, 5, 8, 12, 13, 8, 1, 6, 10, 18, 24, 23, 13, 1, 7, 12, 25, 38, 46, 41, 21, 1, 8, 14, 33, 55, 78, 88, 72, 34, 1, 9, 16, 42, 75, 120, 158, 165, 126, 55, 1, 10, 18, 52, 98, 173, 255, 313, 307, 219, 89, 1, 11, 20, 63, 124, 238
Offset: 1

Views

Author

Clark Kimberling, Feb 28 2012

Keywords

Comments

u(n,n) = Fibonacci(n), A000045
u(n+1,n) = A208354(n)
col 1: A000012
col 2: A000027
col 3: A005843
col 4: A055998
col 5: A140090

Examples

			First five rows:
1
1...1
1...2...2
1...3...4...3
1...4...6...7...5
First five polynomials u(n,x):
1
1 + x
1 + 2x + 2x^2
1 + 3x + 4x^2 + 3x^3
1 + 4x + 6x^2 + 7x^3 + 5x^4
		

Crossrefs

Cf. A208515.

Programs

  • Mathematica
    u[1, x_] := 1; v[1, x_] := 1; z = 16;
    u[n_, x_] := u[n - 1, x] + x*v[n - 1, x];
    v[n_, x_] := x*u[n - 1, x] + x*v[n - 1, x] + 1;
    Table[Expand[u[n, x]], {n, 1, z/2}]
    Table[Expand[v[n, x]], {n, 1, z/2}]
    cu = Table[CoefficientList[u[n, x], x], {n, 1, z}];
    TableForm[cu]
    Flatten[%]    (* A208514 *)
    Table[Expand[v[n, x]], {n, 1, z}]
    cv = Table[CoefficientList[v[n, x], x], {n, 1, z}];
    TableForm[cv]
    Flatten[%]    (* A208515 *)

Formula

u(n,x)=u(n-1,x)+x*v(n-1,x),
v(n,x)=x*u(n-1,x)+x*v(n-1,x)+1,
where u(1,x)=1, v(1,x)=1.

A211164 Number of compositions of n with at most one odd part.

Original entry on oeis.org

1, 1, 1, 3, 2, 8, 4, 20, 8, 48, 16, 112, 32, 256, 64, 576, 128, 1280, 256, 2816, 512, 6144, 1024, 13312, 2048, 28672, 4096, 61440, 8192, 131072, 16384, 278528, 32768, 589824, 65536, 1245184, 131072, 2621440, 262144, 5505024, 524288, 11534336, 1048576, 24117248
Offset: 0

Views

Author

Alois P. Heinz, Jan 30 2013

Keywords

Examples

			a(3) = 3: [3], [1,2], [2,1].
a(4) = 2: [4], [2,2].
a(5) = 8: [5], [3,2], [2,3], [1,4], [4,1], [1,2,2], [2,1,2], [2,2,1].
a(6) = 4: [6], [4,2], [2,4], [2,2,2].
a(8) = 8: [8], [4,4], [2,6], [6,2], [2,2,4], [4,2,2], [2,4,2], [2,2,2,2].
		

Crossrefs

Bisection gives: A011782 (even part), A001792 (odd part).
Cf. A208354.

Programs

  • Maple
    a:= n-> `if`(n<2, 1, 2^iquo(n-2, 2) *
            `if`(irem(n, 2)=0, 1, iquo(n+3, 2))):
    seq(a(n), n=0..60);
  • PARI
    Vec((1-x)^2*(1+x)*(1+2*x)/(1-2*x^2)^2 + O(x^50)) \\ Colin Barker, May 07 2016

Formula

G.f.: -(2*x^4-x^3-3*x^2+x+1)/(-4*x^4+4*x^2-1).
From Colin Barker, May 07 2016: (Start)
a(n) = 2^((n-7)/2+5/2) for n>0 and even.
a(n) = 2^((n-7)/2)*(2*n+6) for n>0 and odd.
a(n) = 4*a(n-2)-4*a(n-4) for n>4.
(End)

A240847 a(n) = 2*a(n-1) + a(n-2) - 2*a(n-3) - a(n-4) for n>3, a(0)=a(1)=a(3)=0, a(2)=1.

Original entry on oeis.org

0, 0, 1, 0, 1, 0, 0, -2, -5, -12, -25, -50, -96, -180, -331, -600, -1075, -1908, -3360, -5878, -10225, -17700, -30509, -52390, -89664, -153000, -260375, -442032, -748775, -1265832, -2136000, -3598250, -6052061, -10164540
Offset: 0

Views

Author

Paul Curtz, Apr 13 2014

Keywords

Comments

F1(m, n) is the difference table of a(n):
0, 0, 1, 0, 1, 0, 0, -2, ...
0, 1, -1, 1, -1, 0, -2, -3, ...
1, -2, 2, -2, 1, -2, -1, -4, ...
-3, 4, -4, 3, -3, 1, -3, -2, ...
7, -8, 7, -6, 4, -4, 1, -4, ...
-15, 15, -13, 10, -8, 5, -5, 1, ...
30, -28, 23, -18, 13, -10, 6, -6, ...
The recurrence holds for every row and every signed column.
Main diagonal: F1(n, n) = A001477(n).
First upper diagonal: F1(n, n+1) = -A001477(n).
F1(m, n) = F1(m, n-1) + F1(m+1, n-1).
Inverse binomial transform: 0, 0, 1, -3, 7, -15, 30, ... = 0, 0, followed by (-1)^n*A023610(n). Without signs: F2(0, n) = 0, 0, 1, 3, 7, 15, 30, ... = b(n) has the same recurrence.
F1(0, n) + F2(0, n) = 0, followed by A099920(n).
a(n) and b(n) are reciprocal by their inverse binomial transform.
0, followed by A001629(n) is an autosequence.
F1(m, 1) = (-1)^n*A029907(n).
F1(1, n) = 0, 1, -1, 1, -1, followed by -A226432(n+3).
F1(m, 2) = (-1)^n*A208354(n).

Crossrefs

Cf. A000032, A000045, A001629 (main sequence for the recurrence), A067331.

Programs

  • GAP
    List([0..40], n-> (6*Fibonacci(n-3) - (n-3)*Lucas(1,-1,n-3)[2])/5 ); # G. C. Greubel, Feb 06 2020
  • Magma
    [(6*Fibonacci(n-3) - (n-3)*Lucas(n-3))/5: n in [0..40]]; // G. C. Greubel, Feb 06 2020
    
  • Maple
    with(combinat): seq( ((n+3)*fibonacci(n-3) - 2*(n-3)*fibonacci(n-2))/5, n=0..40); # G. C. Greubel, Feb 06 2020
  • Mathematica
    a[n_]:= a[n]= 2*a[n-1] +a[n-2] -2*a[n-3] -a[n-4]; a[0]= a[1]= a[3]= 0; a[2]= 1; Table[a[n], {n, 0, 33}] (* Jean-François Alcover, Apr 17 2014 *)
    CoefficientList[Series[x^2*(1-2*x)/(1-x-x^2)^2, {x, 0, 40}], x] (* Vincenzo Librandi, May 09 2014 *)
    nxt[{a_,b_,c_,d_}]:={b,c,d,2d+c-2b-a}; NestList[nxt,{0,0,1,0},40][[All,1]] (* Harvey P. Dale, Sep 17 2022 *)
  • PARI
    Vec(x^2*(1-2*x)/(1-x-x^2)^2 + O(x^100)) \\ Colin Barker, Apr 13 2014
    
  • PARI
    vector(41, n, my(m=n-1); ((m+3)*fibonacci(m-3) - 2*(m-3)*fibonacci(m-2) )/5 ) \\ G. C. Greubel, Feb 06 2020
    
  • Sage
    [((n+3)*fibonacci(n-3) - 2*(n-3)*fibonacci(n-2))/5 for n in (0..40)] # G. C. Greubel, Feb 06 2020
    

Formula

a(n) = 0, 0, 1, 0, 1, 0, 0, followed by -A067331.
G.f.: x^2*(1-2*x)/(1-x-x^2)^2. - Colin Barker, Apr 13 2014
a(n) = ( (10*n + (3-5*n)*t)*(1+t)^n + (10*n-(3-5*n)*t)*(1-t)^n )/(25*2^n), where t=sqrt(5). - Bruno Berselli, Apr 17 2014
a(n) = (6*Fibonacci(n-3) - (n-3)*Lucas(n-3))/5 = ((n+3)*Fibonacci(n-3) - 2*(n-3)*Fibonacci(n-2))/5. - G. C. Greubel, Feb 06 2020

A336014 Irregular triangle read by rows: T(n,1) = T(n,2) = T(n,3*n-2) = T(n,3*n-1) = n for n >= 1 and T(n,k) = T(n-1,k-2) + T(n-1,k-1) for n > 1, 3 <= k <= 3*(n-1).

Original entry on oeis.org

1, 1, 2, 2, 2, 2, 2, 3, 3, 4, 4, 4, 4, 3, 3, 4, 4, 6, 7, 8, 8, 8, 7, 6, 4, 4, 5, 5, 8, 10, 13, 15, 16, 16, 15, 13, 10, 8, 5, 5, 6, 6, 10, 13, 18, 23, 28, 31, 32, 31, 28, 23, 18, 13, 10, 6, 6, 7, 7, 12, 16, 23, 31, 41, 51, 59, 63, 63, 59, 51, 41, 31, 23, 16, 12, 7, 7
Offset: 1

Views

Author

Lechoslaw Ratajczak, Jul 04 2020

Keywords

Comments

The number of terms in row n is 3*n-1 = A016789(n-1).
The sum of row n is equal to 2*A094002(n-1) = 2*A188589(n).
Fibonacci(n) = T(n+k,n) - T(n+k-1,n) for n >= 1, k = 1,2,3,...
The elements b(k) of the main diagonal, superdiagonal 1 and all subdiagonals have the recursive formula: b(k) = 2*b(k-1) + b(k-2) - 2*b(k-3) - b(k-4) for k > 4.

Examples

			Triangle begins:
n\k 1  2  3  4  5  6  7  8  9 10 11 12 13 14 15 16 17 18 19 20...
1   1  1
2   2  2  2  2  2
3   3  3  4  4  4  4  3  3
4   4  4  6  7  8  8  8  7  6  4  4
5   5  5  8 10 13 15 16 16 15 13 10  8  5  5
6   6  6 10 13 18 23 28 31 32 31 28 23 18 13 10  6  6
7   7  7 12 16 23 31 41 51 59 63 63 59 51 41 31 23 16 12  7  7
...
		

Crossrefs

Superdiagonal 1 is A029907 for n >= 1.
The main diagonal is A208354 for n >= 1.
Subdiagonal 1 is A102702(n-1) for n >= 1.
Subdiagonal 2 is A206268(n+2) for n >= 1 (conjectured).
Subdiagonal 3 is A191830(n+3) for n >= 1.

Formula

T(n,k) = T(n,3*k-n) for 1 <= k <= 3*n-1.
T(n,k) = Sum_{u=2*(n-k)+3..2*n-k+1} ceiling(u/2)*A065941(k-2,u-2*(n-k)-3) for n >= 3, 3 <= k <= n.
T(n,k) = Sum_{m1=1..k-n} A208354(m1)*binomial(n-m1-1, k-n-m1) + Sum_{m2=1..2*n-k} A208354(m2)*binomial(n-m2-1, 2*n-k-m2) for n >= 2, n+1 <= k <= 2*n-1.
T(n,k) = Sum_{u=2*(k-2*n)+3..k-n+1} ceiling(u/2)*A065941(3*n-k-2,u-2*(k-2*n)-3) for n>= 3, 2*n <= k <= 3*(n-1).
T(n,k) = A208354(k) + (n-k)*Fibonacci(k) for n >= 3, 3 <= k <= n.
T(n,k) = A029907(k-1) + (n-k+1)*Fibonacci(k) for n >= 2, 3 <= k <= n+1.
Showing 1-10 of 10 results.