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

A098588 a(n) = 2^n for n = 0..4; for n > 4, a(n) = 2*a(n-1) + a(n-5).

Original entry on oeis.org

1, 2, 4, 8, 16, 33, 68, 140, 288, 592, 1217, 2502, 5144, 10576, 21744, 44705, 91912, 188968, 388512, 798768, 1642241, 3376394, 6941756, 14272024, 29342816, 60327873, 124032140, 255006036, 524284096, 1077911008, 2216149889
Offset: 0

Views

Author

Paul Barry, Sep 16 2004

Keywords

Comments

a(n) equals the number of n-length words on {0,1,2} such that 0 appears only in a run whose length is a multiple of 5. - Milan Janjic, Feb 17 2015

Crossrefs

Programs

  • Magma
    I:=[1,2,4,8,16]; [n le 5 select I[n] else 2*Self(n-1) +Self(n-5): n in [1..30]]; // G. C. Greubel, Feb 03 2018
  • Mathematica
    CoefficientList[Series[1/(1-2*x-x^5), {x,0,50}], x] (* or *) LinearRecurrence[{2,0,0,0,1}, {1,2,4,8,16}, 50] (* G. C. Greubel, Feb 03 2018 *)
  • PARI
    x='x+O('x^30); Vec(1/(1-2*x-x^5)) \\ G. C. Greubel, Feb 03 2018
    

Formula

G.f.: 1/(1-2*x-x^5).
a(n) = Sum_{k=0..floor(n/4)} Sum_{i=0..n} binomial(n-4k, i)binomial(i, k).
G.f.: G(0), where G(k)= 1 + x*(2+x^4)/(1 - x*(2+x^4)/(x*(2+x^4) + 1/G(k+1) )); (continued fraction). - Sergei N. Gladkovskii, Jul 03 2013
Lim_{n->infinity} a(n)/a(n+1) = 0.486389... is a real root of -1 + 2Z + Z^5 = 0. - Sergei N. Gladkovskii, Jul 03 2013

A180675 The Ca3 sums of the Pell-Jacobsthal triangle A013609.

Original entry on oeis.org

1, 1, 1, 9, 97, 1041, 11169, 119833, 1285697, 13794337, 148000449, 1587907625, 17036776865, 182788823089, 1961154631009, 21041371248697, 225754408665729, 2422135536207937, 25987269043538817, 278819307278968905
Offset: 0

Views

Author

Johannes W. Meijer, Sep 21 2010

Keywords

Comments

The a(n+3) represent the Ca3 sums of the Pell-Jacobsthal triangle A013609. See A180662 for information about these camel and other chess sums.

Crossrefs

Cf. A077949 (Ca1), A008998 (Ca2), A180675 (Ca3), A092467 (Ca4).

Programs

  • Maple
    nmax:=20: a(0):=1: a(1):=1: a(2):=1: for n from 3 to nmax do a(n) := 11*a(n-1)-3*a(n-2)+a(n-3) od: seq(a(n),n=0..nmax);
  • Mathematica
    LinearRecurrence[{11,-3,1},{1,1,1},20] (* Harvey P. Dale, Jun 23 2013 *)

Formula

a(n) = 11*a(n-1)-3*a(n-2)+a(n-3) with a(0)=1, a(1)=1 and a(2)=1.
a(n+2) = add(A013609(n+2*k,3*k),k=0..floor(n)).
GF(x) = (1-10*x-7*x^2)/(1-11*x+3*x^2-x^3).

A214260 First differences of A052980.

Original entry on oeis.org

0, 1, 3, 6, 13, 29, 64, 141, 311, 686, 1513, 3337, 7360, 16233, 35803, 78966, 174165, 384133, 847232, 1868629, 4121391, 9090014, 20048657, 44218705, 97527424, 215103505, 474425715, 1046378854, 2307861213
Offset: 0

Views

Author

Philippe Deléham, Jul 22 2012

Keywords

Comments

1 -> 123, 2 -> 12, 3 -> 2, starting with 1 gives the sequence: 1, 123, 123122, 1231221231212, ... the n-th term has a(n) digits.
Ternary words of length n-1 with subwords (0,1), (1,1) and (1,2) not allowed. - Olivier Gérard, Aug 28 2012

Crossrefs

Programs

  • Mathematica
    LinearRecurrence[{2,0,1},{0,1,3},30] (* Harvey P. Dale, Sep 04 2017 *)

Formula

Recurrence: a(0) = 0, a(1) = 1, a(2) = 3, a(n+1) = 2*a(n) + a(n-2).
G.f.: x*(1+x)/(1-2*x-x^3).
a(n) = A052980(n) + A052980(n-2) = A052980(n+1) - A052980(n).
a(n+1) = A078061(n)*(-1)^n.
a(0) = 0, a(n) = A008998(n-1) + A008998(n-2) for n>0.
a(n+1) = Sum_{k=0..n} C(n-k, floor(k/2))*2^(n-k-floor(k/2)).

A317495 Triangle read by rows: T(0,0) = 1; T(n,k) =2 * T(n-1,k) + T(n-3,k-1) for k = 0..floor(n/3); T(n,k)=0 for n or k < 0.

Original entry on oeis.org

1, 2, 4, 8, 1, 16, 4, 32, 12, 64, 32, 1, 128, 80, 6, 256, 192, 24, 512, 448, 80, 1, 1024, 1024, 240, 8, 2048, 2304, 672, 40, 4096, 5120, 1792, 160, 1, 8192, 11264, 4608, 560, 10, 16384, 24576, 11520, 1792, 60, 32768, 53248, 28160, 5376, 280, 1, 65536, 114688, 67584, 15360, 1120, 12
Offset: 0

Views

Author

Zagros Lalo, Jul 30 2018

Keywords

Comments

The numbers in rows of the triangle are along a "second layer" of skew diagonals pointing top-left in center-justified triangle given in A013609 ((1+2*x)^n) and along a "second layer" of skew diagonals pointing top-right in center-justified triangle given in A038207 ((2+x)^n), see links. (Note: First layer skew diagonals in center-justified triangles of coefficients in expansions of (1+2*x)^n and (2+x)^n are given in A128099 and A207538 respectively.)
The coefficients in the expansion of 1/(1-2x-x^3) are given by the sequence generated by the row sums.
The row sums give A008998 and Pisot sequences E(4,9), P(4,9) when n > 1, see A020708.
If s(n) is the row sum at n, then the ratio s(n)/s(n-1) is approximately 2.205569430400..., when n approaches infinity.

Examples

			Triangle begins:
       1;
       2;
       4;
       8,      1;
      16,      4;
      32,     12;
      64,     32,      1;
     128,     80,      6;
     256,    192,     24;
     512,    448,     80,      1;
    1024,   1024,    240,      8;
    2048,   2304,    672,     40;
    4096,   5120,   1792,    160,     1;
    8192,  11264,   4608,    560,    10;
   16384,  24576,  11520,   1792,    60;
   32768,  53248,  28160,   5376,   280,   1;
   65536, 114688,  67584,  15360,  1120,  12;
  131072, 245760, 159744,  42240,  4032,  84;
  262144, 524288, 372736, 112640, 13440, 448, 1;
		

References

  • Shara Lalo and Zagros Lalo, Polynomial Expansion Theorems and Number Triangles, Zana Publishing, 2018, ISBN: 978-1-9995914-0-3, pp. 358, 359.

Crossrefs

Row sums give A008998, A020708.
Cf. A000079 (column 0), A001787 (column 1), A001788 (column 2), A001789 (column 3), A003472 (column 4).

Programs

  • GAP
    Flat(List([0..20],n->List([0..Int(n/3)],k->2^(n-3*k)/(Factorial(n-3*k)*Factorial(k))*Factorial(n-2*k)))); # Muniru A Asiru, Jul 31 2018
    
  • Magma
    /* As triangle */ [[2^(n-3*k)/(Factorial(n-3*k)*Factorial(k))* Factorial(n-2*k): k in [0..Floor(n/3)]]: n in [0.. 15]]; // Vincenzo Librandi, Sep 05 2018
  • Mathematica
    t[n_, k_] := t[n, k] = 2^(n - 3k)/((n - 3 k)! k!) (n - 2 k)!; Table[t[n, k], {n, 0, 18}, {k, 0, Floor[n/3]} ]  // Flatten
    t[0, 0] = 1; t[n_, k_] := t[n, k] = If[n < 0 || k < 0, 0, 2 t[n - 1, k] + t[n - 3, k - 1]]; Table[t[n, k], {n, 0, 18}, {k, 0, Floor[n/3]}] // Flatten

Formula

T(n,k) = 2^(n - 3k) / ((n - 3k)! k!) * (n - 2k)! where n >= 0 and k = 0..floor(n/3).

A332647 a(n) = 2*a(n-1) + a(n-3) with a(0) = 3, a(1) = 2, a(2) = 4.

Original entry on oeis.org

3, 2, 4, 11, 24, 52, 115, 254, 560, 1235, 2724, 6008, 13251, 29226, 64460, 142171, 313568, 691596, 1525363, 3364294, 7420184, 16365731, 36095756, 79611696, 175589123, 387274002, 854159700, 1883908523, 4155091048, 9164341796, 20212592115, 44580275278, 98324892352
Offset: 0

Views

Author

Greg Dresden, Feb 18 2020

Keywords

Comments

a(n) is the number of ways to tile a bracelet of length n with black trominos, and black or white squares.

Crossrefs

Cf. A008998, A052980. Equals one more than A080204.

Programs

  • Magma
    a:=[3,2,4]; [n le 3 select a[n] else 2*Self(n-1)+Self(n-3):n in [1..33]]; // Marius A. Burtea, Feb 18 2020
    
  • Mathematica
    LinearRecurrence[{2, 0, 1}, {3, 2, 4}, 50]
  • PARI
    Vec((3 - 4*x) / (1 - 2*x - x^3) + O(x^30)) \\ Colin Barker, Feb 18 2020
    
  • PARI
    polsym(x^3-2*x^2-1, 44) \\ Joerg Arndt, May 28 2020

Formula

a(n) = 2*a(n-1) + a(n-3).
a(n) = w1^n + w2^n + w3^n where w1,w2,w3 are the three roots of x^3-2x^2-1=0.
For n>2, a(n) = round(w1^n) for w1 the single real root of x^3-2x^2-1=0.
G.f.: (3 - 4*x) / (1 - 2*x - x^3). - Colin Barker, Feb 18 2020
a(n) = A008998(n) + 2*A008998(n-3) = 3*A008998(n) - 4*A008998(n-1).
a(n) = (5*b(n) - b(n-1) - b(n-2))/2 where b(n) = A052980(n). - Greg Dresden, Mar 10 2020
a(n) = A080204(n) + 1. - Greg Dresden, May 27 2020

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

Original entry on oeis.org

1, -3, 6, -13, 29, -64, 141, -311, 686, -1513, 3337, -7360, 16233, -35803, 78966, -174165, 384133, -847232, 1868629, -4121391, 9090014, -20048657, 44218705, -97527424, 215103505, -474425715, 1046378854, -2307861213, 5090148141, -11226675136, 24761211485, -54612571111, 120451817358
Offset: 0

Views

Author

N. J. A. Sloane, Nov 17 2002

Keywords

Programs

  • Mathematica
    CoefficientList[Series[(1-x)/(1+2x+x^3),{x,0,40}],x] (* or *) LinearRecurrence[ {-2,0,-1},{1,-3,6},40] (* Harvey P. Dale, Dec 15 2017 *)
  • PARI
    Vec((1-x)/(1+2*x+x^3)+O(x^99)) \\ Charles R Greathouse IV, Sep 27 2012

Formula

a(n) = (-1)^n*sum{k=0..n, C(n-k,floor(k/2))*2^(n-k-floor(k/2))}. [Paul Barry, Oct 20 2009]
(-1)^n*a(n) = A008998(n)+A008998(n-1). - R. J. Mathar, Jul 08 2022

A144401 Padovan ( A000931) version of A038137: expansion of polynomials as antidiagonal: p(x,n)=1/(1-x-x^3)^n.

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 3, 3, 2, 1, 4, 6, 6, 3, 1, 5, 10, 13, 11, 4, 1, 6, 15, 24, 27, 18, 6, 1, 7, 21, 40, 55, 51, 30, 9, 1, 8, 28, 62, 100, 116, 94, 50, 13, 1, 9, 36, 91, 168, 231, 234, 171, 81, 19, 1, 10, 45, 128, 266, 420, 505, 460, 303, 130, 28, 1, 11, 55, 174, 402, 714, 987, 1065
Offset: 1

Views

Author

Roger L. Bagula and Gary W. Adamson, Oct 03 2008

Keywords

Comments

Row sums are: 1, 2, 4, 9, 20, 44, 97, 214, 472, 1041, 2296, 5064, 11169, 24634, 54332 (cf. A008998).
These polynomials are sort of pseudo-combinations with the last element Padovan instead of one.
If you subtract the binomial triangle sequence you get:
{0},
{0, 0},
{0, 0, 0},
{0, 0, 0, 1},
{0, 0, 0, 2, 2},
{0, 0, 0, 3, 6, 3},
{0, 0, 0, 4, 12, 12, 5},
{0, 0, 0, 5, 20, 30, 23, 8},
{0, 0, 0, 6, 30, 60, 66, 42, 12}

Examples

			{1},
{1, 1},
{1, 2, 1},
{1, 3, 3, 2},
{1, 4, 6, 6, 3},
{1, 5, 10, 13, 11, 4},
{1, 6, 15, 24, 27, 18, 6},
{1, 7, 21, 40, 55, 51, 30, 9},
{1, 8, 28, 62, 100, 116, 94, 50, 13},
{1, 9, 36, 91, 168, 231, 234, 171, 81, 19},
{1, 10, 45, 128, 266, 420, 505, 460, 303, 130, 28},
{1, 11, 55, 174, 402, 714, 987, 1065, 879, 527, 208, 41},
{1, 12, 66, 230, 585, 1152, 1792, 2220, 2175, 1640, 906, 330, 60},
{1, 13, 78, 297, 825, 1782, 3072, 4278, 4815, 4320, 3006, 1539, 520, 88},
{1, 14, 91, 376, 1133, 2662, 5028, 7752, 9807, 10122, 8391, 5424, 2586, 816, 129}
		

Crossrefs

Programs

  • Mathematica
    Clear[f, b, a, g, h, n, t]; f[t_, n_] = 1/(1 - t - t^3)^n; a = Table[Table[SeriesCoefficient[Series[f[t, m], {t, 0, 30}], n], {n, 0, 30}], {m, 1, 31}]; b = Table[Table[a[[n - m + 1]][[m]], {m, 1, n }], {n, 1, 15}]; Flatten[b]

Formula

p(x,n)=1/(1-x-x^3)^n; t(n,m)=anti_diagonal_expansion(p(x,n)).

A228815 Symmetric triangle, read by rows, related to Fibonacci numbers.

Original entry on oeis.org

0, 1, 1, 1, 2, 1, 2, 5, 5, 2, 3, 10, 14, 10, 3, 5, 20, 36, 36, 20, 5, 8, 38, 83, 106, 83, 38, 8, 13, 71, 182, 281, 281, 182, 71, 13, 21, 130, 382, 690, 834, 690, 382, 130, 21, 34, 235, 778, 1606, 2268, 2268, 1606, 778, 235, 34, 55, 420, 1546, 3586, 5780, 6750
Offset: 0

Views

Author

Philippe Deléham, Oct 30 2013

Keywords

Comments

Triangles satisfying the same recurrence: A091533, A091562, A185081, A205575, A209137, A209138.

Examples

			Triangle begins :
0
1, 1
1, 2, 1
2, 5, 5, 2
3, 10, 14, 10, 3
5, 20, 36, 36, 20, 5
8, 38, 83, 106, 83, 38, 8
13, 71, 182, 281, 281, 182, 71, 13
21, 130, 382, 690, 834, 690, 382, 130, 21
34, 235, 778, 1606, 2268, 2268, 1606, 778, 235, 34
55, 420, 1546, 3586, 5780, 6750, 5780, 3586, 1546, 420, 55
		

Crossrefs

Cf. A000045 (1st column), A001629 (2nd column), A008998, A152011, A261055 (3rd column).

Formula

G.f.: x*(1+y)/(1-x-x*y-x^2-x^2*y-x^2*y^2).
T(n,k) = T(n-1,k) + T(n-1,k-1) + T(n-2,k) + T(n-2,k-1) + T(n-2,k-2), T(0,0) = 0, T(1,0) = T(1,1) = 1, T(n,k) = 0 if k<0 or if k>n.
Sum_{k = 0..n} T(n,k)*x^k = A000045(n), 2*A015518(n), 3*A015524(n), 4*A200069(n) for x = 0, 1, 2, 3 respectively.
Sum_{k = 0..floor(n/2)} T(n-k,k) = A008998(n+1).

A257365 Triangle, read by rows, T(n,k) = Sum_{m=0..(n-k)/2} C(k,m)*C(n-2*m,k).

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 4, 3, 1, 1, 6, 8, 4, 1, 1, 8, 16, 13, 5, 1, 1, 10, 28, 32, 19, 6, 1, 1, 12, 44, 68, 55, 26, 7, 1, 1, 14, 64, 128, 136, 86, 34, 8, 1, 1, 16, 88, 220, 296, 241, 126, 43, 9, 1, 1, 18, 116, 352, 584, 592, 393, 176, 53, 10, 1
Offset: 0

Views

Author

Vladimir Kruchinin, Apr 21 2015

Keywords

Comments

From Emanuele Munarini, Feb 21 2017: (Start)
T(n,k) is the number of lattice paths from (0,0) to (n,k) using steps X=(1,0), D=(1,1) and E=(3,1).
Row sums = A008998.
Central coefficients = A006139. (End)

Examples

			1;
1, 1;
1, 2, 1;
1, 4, 3, 1;
1, 6, 8, 4, 1;
1, 8, 16, 13, 5, 1;
		

Crossrefs

Cf. A006139.

Programs

  • Mathematica
    Table[Sum[Binomial[k, m] Binomial[n - 2 m, k], {m, 0, (n - k)/2}], {n, 0, 10}, {k, 0, n}] // Flatten (* Michael De Vlieger, Apr 21 2015 *)
  • Maxima
    T(n,k):=sum(binomial(k,m)*binomial(n-2*m,k),m,0,(n-k)/2);

Formula

G.f.: 1/(1-y-x*(1+y^2)).
From Emanuele Munarini, Feb 21 2017: (Start)
G.f. for the triangle: 1/(1-x-x*y-x^3*y).
Recurrence: T(n+3,k+1) = T(n+2,k+1) + T(n+2,k) + T(n,k). (End)

A335242 a(n) = 2*a(n-1) + a(n-3) for n >= 4, with initial values a(0) = 1, a(1) = 0, a(2) = 2, and a(3) = 3.

Original entry on oeis.org

1, 0, 2, 3, 6, 14, 31, 68, 150, 331, 730, 1610, 3551, 7832, 17274, 38099, 84030, 185334, 408767, 901564, 1988462, 4385691, 9672946, 21334354, 47054399, 103781744, 228897842, 504850083, 1113481910, 2455861662, 5416573407, 11946628724, 26349119110, 58114811627
Offset: 0

Views

Author

Greg Dresden, May 28 2020

Keywords

Comments

a(n) is the number of ways to tile this 2 X n strip (with one extra square added at the top left) with dominoes and L-shaped trominoes (also called polyominoes):
._
|| _
|||_||| . . .
|||_||| . . .

Examples

			a(2) = 2 thanks to the following two tilings (where the L-shaped trominoes are tiled with X's and the dominoes are left blank):
._            _
|X|_         | |_
|X|X|  and   |_|X|
|_ _|        |X X|
		

Crossrefs

Programs

  • Mathematica
    LinearRecurrence[{2, 0, 1}, {1, 0, 2, 3}, 40]

Formula

a(n) = 2*a(n-1) + a(n-3) for n >= 4.
a(n) = A008998(n-2) + A052980(n-2) for n >= 2.
G.f.: (2*x^3-2*x^2+2*x-1)/(x^3+2*x-1).
Previous Showing 11-20 of 25 results. Next