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

A059220 The array in A059219 read by antidiagonals in 'up' direction.

Original entry on oeis.org

1, 0, 1, 2, 1, 0, 0, 2, 3, 5, 15, 12, 8, 5, 0, 0, 15, 27, 39, 48, 55, 239, 221, 190, 152, 103, 55, 0, 0, 239, 460, 680, 871, 1025, 1137, 1199, 6810, 6553, 6062, 5374, 4493, 3471, 2336, 1199, 0, 0, 6810, 13363, 19903, 25958, 31351, 35884, 39399, 41847
Offset: 1

Views

Author

N. J. A. Sloane, Jan 18 2001

Keywords

Examples

			The array begins
   1   1   0   5   0  55   0 ...
   0   1   3   5  48  55   ...
   2   2   8  39 103  ...
   0  12  27 152 ...
  15  15 190 ...
   0 221 ...
		

Crossrefs

Programs

  • Maple
    See A059219 for Maple code.
  • Mathematica
    max = 9; t[0, 0] = 1; t[0, ?EvenQ] = 0; t[?OddQ, 0] = 0; t[n_, k_] /; OddQ[n + k] (* up *) := t[n, k] = t[n+1, k-1] + Sum[t[n, j], {j, 0, k-1}]; t[n_, k_] /; EvenQ[n + k] (* down *) := t[n, k] = t[n-1, k+1] + Sum[t[j, k], {j, 0, n-1}]; Table[t[n - k, k], {n, 0, max}, {k, 0, n}] // Flatten (* Jean-François Alcover, Aug 19 2013 *)

Extensions

More terms from Floor van Lamoen, Jan 19 2001

A059235 The array in A059219 read by antidiagonals in the direction in which it was constructed.

Original entry on oeis.org

1, 0, 1, 0, 1, 2, 0, 2, 3, 5, 0, 5, 8, 12, 15, 0, 15, 27, 39, 48, 55, 0, 55, 103, 152, 190, 221, 239, 0, 239, 460, 680, 871, 1025, 1137, 1199, 0, 1199, 2336, 3471, 4493, 5374, 6062, 6553, 6810, 0, 6810, 13363, 19903, 25958, 31351, 35884, 39399, 41847, 43108, 0
Offset: 1

Views

Author

N. J. A. Sloane, Jan 18 2001

Keywords

Examples

			The array begins
1 1 0 5 0 55 0 ...
0 1 3 5 48 55 ...
2 2 8 39 103 ...
0 12 27 152 ...
15 15 190 ...
0 221 ...
		

Crossrefs

Programs

  • Mathematica
    max = 10; t[0, 0] = 1; t[0, ?EvenQ] = 0; t[?OddQ, 0] = 0; t[n_, k_] /; OddQ[n+k](*up*):= t[n, k] = t[n+1, k-1] + Sum[t[n, j], {j, 0, k-1}]; t[n_, k_] /; EvenQ[n+k](*down*):= t[n, k] = t[n-1, k+1] + Sum[t[j, k], {j, 0, n-1}]; Table[tn = Table[t[n-k, k], {k, 0, n}]; If[OddQ[n], tn, tn // Reverse] , {n, 0, max}] // Flatten (* Jean-François Alcover, Nov 20 2012 *)

Extensions

More terms from Larry Reeves (larryr(AT)acm.org), Jan 24 2001

A059237 Variation of Boustrophedon transform described in A059219 applied to sequence 0,1,0,0,0,....

Original entry on oeis.org

0, 1, 2, 5, 16, 59, 258, 1296, 7362, 46609, 325147, 2477212, 20460278, 182076531, 1736623109, 17672266151, 191111489038, 2188592796698, 26458831601847, 336735773968857, 4500142285227330, 63007188219787855, 922312862937555109
Offset: 0

Views

Author

N. J. A. Sloane, Jan 20 2001

Keywords

Crossrefs

Programs

  • Maple
    aaa := proc(m,n) option remember; local i,j,r,s,t1; if m=0 and n=0 then RETURN(0); fi; if m=1 and n=0 then RETURN(1); fi; if n = 0 and m mod 2 = 1 then RETURN(0); fi; if m = 0 and n mod 2 = 0 then RETURN(0); fi; s := m+n; if s mod 2 = 1 then t1 := aaa(m+1,n-1); for j from 0 to n-1 do t1 := t1+aaa(m,j); od: else t1 := aaa(m-1,n+1); for j from 0 to m-1 do t1 := t1+aaa(j,n); od: fi; RETURN(t1); end; # the n-th antidiagonal in the up direction is aaa(n,0), aaa(n-1,1), aaa(n-2,2), ..., aaa(0,n)

A059216 Variation of Boustrophedon transform applied to all-1's sequence (see Comments for details).

Original entry on oeis.org

1, 2, 5, 14, 45, 169, 740, 3721, 21142, 133850, 933770, 7114115, 58758459, 522892624, 4987285553, 50751731950, 548839590949, 6285265061237, 75985249771496, 967047685739501, 12923640789599709, 180945893711983990, 2648725169100050894
Offset: 1

Views

Author

Floor van Lamoen, Jan 18 2001

Keywords

Comments

Variation of Boustrophedon transform applied to all-1's sequence. Fill an array by diagonals in alternating directions - 'up' and 'down'. The first element of each diagonal is 1. When 'going up', add to the previous element the elements of the row the new element is in. When 'going down', add to the previous element the elements of the column the new element is in. The final element of the n-th diagonal is a(n).

Examples

			The array begins
   1  2  1 14  1 ...
   1  3 10 15 ...
   5  6 26 ...
   1 37 ...
  45 ...
		

Crossrefs

Programs

  • Maple
    # To get the array used to produce this sequence:
    aaa := proc(m,n) option remember; local i,j,r,s,t1; if m=0 and n=0 then RETURN(1); fi; if n = 0 and m mod 2 = 1 then RETURN(1); fi; if m = 0 and n mod 2 = 0 then RETURN(1); fi; s := m+n; if s mod 2 = 1 then t1 := aaa(m+1,n-1); for j from 0 to n-1 do t1 := t1+aaa(m,j); od: else t1 := aaa(m-1,n+1); for j from 0 to m-1 do t1 := t1+aaa(j,n); od: fi; RETURN(t1); end; # the n-th antidiagonal in the up direction is aaa(n,0), aaa(n-1,1), aaa(n-2,2), ..., aaa(0,n)
    # To get the array formed when the transformation is applied to an arbitrary input sequence b = [b[1], b[2], ..., b[N]]:
    aab := proc(b,N,m,n) local i, j, r, s, t1; option remember; if m>N or n>N then error "asking for too many terms"; fi; if m = 0 and n mod 2 = 0 then RETURN(b[n+1]) end if; if n = 0 and m mod 2 = 1 then RETURN(b[m+1]) end if; s := m + n; if s mod 2 = 1 then t1 := aab(b,N,m + 1, n - 1); for j from 0 to n - 1 do t1 := t1 + aab(b,N,m, j) end do else t1 := aab(b,N,m - 1, n + 1); for j from 0 to m - 1 do t1 := t1 + aab(b,N,j, n) end do end if; RETURN(t1) end proc;
    # To get the output sequence when the transformation is applied to an arbitrary input sequence b = [b[1], b[2], ..., b[N]]:
    ff := proc(b) local N,t1,i; N := min(35, nops(b)); t1 := []; for i from 0 to N-1 do if i mod 2 = 0 then t1 := [op(t1),aab(b,N,i,0)]; else t1 := [op(t1),aab(b,N,0,i)]; fi; od: t1; end;
  • Mathematica
    max = 22; t[0, 0] = 1; t[0, ?EvenQ] = 1; t[?OddQ, 0] = 1; t[n_, k_] /; OddQ[n + k](*up*):= t[n, k] = t[n + 1, k - 1] + Sum[t[n, j], {j, 0, k - 1}]; t[n_, k_] /; EvenQ[n + k](*down*):= t[n, k] = t[n - 1, k + 1] + Sum[t[j, k], {j, 0, n - 1}]; tnk = Table[t[n, k], {n, 0, max}, {k, 0, max - n}]; Join[{1}, Rest[Union[tnk[[1]], tnk[[All, 1]]]]] (* Jean-François Alcover, Jun 15 2012 *)

Extensions

More terms from N. J. A. Sloane and Larry Reeves (larryr(AT)acm.org), Jan 23 2001

A059502 a(n) = (3*n*F(2n-1) + (3-n)*F(2n))/5 where F() = Fibonacci numbers A000045.

Original entry on oeis.org

0, 1, 3, 9, 27, 80, 234, 677, 1941, 5523, 15615, 43906, 122868, 342409, 950727, 2631165, 7260579, 19982612, 54865566, 150316973, 411015705, 1121818311, 3056773383, 8316416134, 22593883752, 61301547025, 166118284299, 449639574897, 1215751720491, 3283883157848
Offset: 0

Views

Author

Floor van Lamoen, Jan 19 2001

Keywords

Comments

Substituting x(1-x)/(1-2x) into x/(1-x)^2 yields g.f. of sequence.
Variation of A059216 (and of Boustrophedon transform) applied to 1,2,3,4,...: fill an array by diagonals, each time in the same direction, say the 'up' direction. The first column is 1,2,3,4,... For the next element of a diagonal, add to the previous element the elements of the row the new element is in. The first row gives a(n).

Examples

			The array (see A059503) begins
  1 3  9 27 80 ...
  2 5 14 40 ...
  3 7 19 ...
  4 9  5 ...
		

Crossrefs

Programs

  • Magma
    [(3*n*Fibonacci(2*n-1)+(3-n)*Fibonacci(2*n))/5: n in [0..100]]; // Vincenzo Librandi, Apr 23 2011
  • Mathematica
    Table[(3n Fibonacci[2n-1]+(3-n)Fibonacci[2n])/5,{n,0,30}] (* or *) CoefficientList[Series[x(1-x)(1-2x)/(1-3x+x^2)^2,{x,0,30}],x] (* Harvey P. Dale, Apr 23 2011 *)
  • PARI
    a(n)=(3*n*fibonacci(2*n-1)+(3-n)*fibonacci(2*n))/5
    

Formula

a(n) = 2*a(n-1) + Sum{m<=n-2} a(m) + A001519(n-2).
G.f.: x*(1 - x)*(1 - 2*x)/(1 - 3*x + x^2)^2. - Emeric Deutsch, Oct 07 2002
a(n) = A147703(n,1). - Philippe Deléham, Nov 29 2008
a(n) = A001871(n-1) - 3*A001871(n-2) + 2*A001871(n-3). - R. J. Mathar, Apr 09 2019
E.g.f.: 2*exp(3*x/2)*(5*x*cosh(sqrt(5)*x/2) + 3*sqrt(5)*sinh(sqrt(5)*x/2))/25. - Stefano Spezia, Mar 04 2025

A059217 The array in A059216 read by antidiagonals in 'up' direction.

Original entry on oeis.org

1, 1, 2, 5, 3, 1, 1, 6, 10, 14, 45, 37, 26, 15, 1, 1, 46, 84, 121, 150, 169, 740, 686, 592, 471, 321, 170, 1, 1, 741, 1428, 2111, 2704, 3183, 3532, 3721, 21142, 20347, 18826, 16685, 13953, 10777, 7255, 3722, 1, 1, 21143, 41491, 61798, 80598
Offset: 1

Views

Author

Floor van Lamoen, Jan 18 2001

Keywords

Examples

			The array begins
   1  2  1 14  1 ...
   1  3 10 15 ...
   5  6 26 ...
   1 37 ...
  45 ...
		

Crossrefs

Programs

  • Maple
    See A059216 for Maple code.
  • Mathematica
    max = 9; t[0, 0] = 1; t[0, ?EvenQ] = 1; t[?OddQ, 0] = 1; t[n_, k_] /; OddQ[n + k](*up*):= t[n, k] = t[n+1, k-1] + Sum[t[n, j], {j, 0, k-1}]; t[n_, k_] /; EvenQ[n + k](*down*):= t[n, k] = t[n-1, k+1] + Sum[t[j, k], {j, 0, n-1}]; Table[t[n-k, k], {n, 0, max}, {k, 0, n}] // Flatten (* Jean-François Alcover, Sep 16 2013 *)

A027994 a(n) = (F(2n+3) - F(n))/2 where F() = Fibonacci numbers A000045.

Original entry on oeis.org

1, 2, 6, 16, 43, 114, 301, 792, 2080, 5456, 14301, 37468, 98137, 256998, 672946, 1761984, 4613239, 12078110, 31621701, 82787980, 216743836, 567446112, 1485598681, 3889356696, 10182482353, 26658108074, 69791870526, 182717549872, 478360854115, 1252365133866, 3278734743901, 8583839415648, 22472784017272
Offset: 0

Views

Author

Keywords

Comments

Substituting x*(1-x)/(1-2x) into x^2/(1-x^2) yields x^2*(g.f. of sequence).
The number of (s(0), s(1), ..., s(n+1)) such that 0 < s(i) < 5 and |s(i) - s(i-1)| <= 1 for i = 1,2,...,n+1, s(0) = 2, s(n+1) = 3. - Herbert Kociemba, Jun 02 2004
Diagonal sums of triangle in A125171. - Philippe Deléham, Jan 14 2014

Crossrefs

Programs

  • Magma
    [(Fibonacci(2*n+3)-Fibonacci(n))/2 : n in [0..40]]; // Vincenzo Librandi, Jan 01 2025
  • Mathematica
    Table[(Fibonacci[2n+3]-Fibonacci[n])/2,{n,0,30}] (* or *) LinearRecurrence[{4,-3,-2,1},{1,2,6,16},30] (* Harvey P. Dale, Apr 28 2022 *)
  • PARI
    a(n)=(fibonacci(2*n+3)-fibonacci(n))/2
    

Formula

G.f.: (1-x)^2/((1-x-x^2)*(1-3*x+x^2)). - Floor van Lamoen and N. J. A. Sloane, Jan 21 2001
a(n) = Sum_{k=0..n} T(n, k)*T(n, n+k), T given by A027926.
a(n) = 2*a(n-1) + Sum_{m < n-1} a(m) + F(n-1) = A059512(n+2) - F(n) where F(n) is the n-th Fibonacci number (A000045). - Floor van Lamoen, Jan 21 2001
a(n) = (2/5)*Sum_{k=1..4} sin(2*Pi*k/5)*sin(3*Pi*k/5)*(1+2*cos(Pi*k/5))^(n+1). - Herbert Kociemba, Jun 02 2004
a(-1-2n) = A056014(2n), a(-2n) = A005207(2n-1).
E.g.f.: exp(3*x/2)*cosh(sqrt(5)*x/2) + exp(x/2)*(2*exp(x) - 1)*sinh(sqrt(5)*x/2)/sqrt(5). - Stefano Spezia, Jan 01 2025

A059503 The array in A059502 read by antidiagonals in 'up' direction.

Original entry on oeis.org

1, 2, 3, 3, 5, 9, 4, 7, 14, 27, 5, 9, 19, 40, 80, 6, 11, 24, 53, 114, 234, 7, 13, 29, 66, 148, 323, 677, 8, 15, 34, 79, 182, 412, 910, 1941, 9, 17, 39, 92, 216, 501, 1143, 2551, 5523, 10, 19, 44, 105, 250, 590, 1376, 3161, 7120, 15615, 11, 21, 49, 118
Offset: 0

Views

Author

Floor van Lamoen, Jan 19 2001

Keywords

Examples

			The array begins
1 3 9 27 80 ...
2 5 14 40 ...
3 7 19 ...
4 9 5 ...
		

Crossrefs

Rows give A059502, A059505, A059506, A059507, A059508; main diagonal = A059509.

Programs

  • Mathematica
    T[n_, k_] := ((3 - k)*Fibonacci[2*k] + (5*n + 3*k)*Fibonacci[2*k - 1])/5;
    TableForm[Table[T[n, k], {n, 0, 5}, {k, 1, 5}]]
    Table[T[n - k, k + 1], {n, 0, 10}, {k, 0, n}]//Flatten (* G. C. Greubel, Sep 10 2017 *)

Formula

T(n,k) = ((3 - k)*Fibonacci(2*k) + (5*n + 3*k)*Fibonacci(2*k - 1))/5. - G. C. Greubel, Sep 10 2017

A059720 Triangle T(n,k), 0<=k<=n, formed from coefficients when formula for n-th diagonal of triangle in A059718 is written as a sum of binomial coefficients.

Original entry on oeis.org

1, 0, 1, 0, 2, 1, 0, 5, 6, 2, 0, 15, 29, 20, 5, 0, 55, 148, 158, 80, 16, 0, 239, 818, 1185, 910, 366, 61, 0, 1199, 4964, 9094, 9392, 5696, 1904, 272, 0, 6810, 32989, 73026, 94833, 77011, 38719, 11080, 1385, 0, 43108, 238931, 619904, 970152, 988040, 663904, 285424, 71424, 7936
Offset: 0

Views

Author

N. J. A. Sloane, Feb 09 2001

Keywords

Comments

I would very much like to find a formula for this - N. J. A. Sloane.

Examples

			1; 0,1; 0,2,1; 0,5,6,2; 0,15,29,20,5; ... E.g. the n=3 diagonal in A059718 has the formula b(m) = 0 + 5*m + 6*C(m,2) + 2*C(m,3) and so the third row here is 0, 5, 6, 2.
		

Crossrefs

Interesting because it connects a mysterious sequence (A059219, the left edge) with a known sequence (A000111, the right edge). Cf. A059724, A059725, A059726.

A059512 For n>=2, the number of (s(0), s(1), ..., s(n-1)) such that 0 < s(i) < 5 and |s(i) - s(i-1)| <= 1 for i = 1,2,....,n-1, s(0) = 2, s(n-1) = 2.

Original entry on oeis.org

0, 1, 1, 3, 7, 18, 46, 119, 309, 805, 2101, 5490, 14356, 37557, 98281, 257231, 673323, 1762594, 4614226, 12079707, 31624285, 82792161, 216750601, 567457058, 1485616392, 3889385353, 10182528721, 26658183099, 69791991919
Offset: 0

Views

Author

Floor van Lamoen, Jan 21 2001

Keywords

Comments

Substituting x(1-x)/(1-2x) into x/(1-x^2) yields g.f. of sequence.

Crossrefs

a(1-2n)=A005207(2n), a(-2n)=A056014(2n+1).

Programs

  • Mathematica
    CoefficientList[Series[x(1-x)(1-2x)/((1-x-x^2)(1-3x+x^2)), {x,0,30}], x]  (* Harvey P. Dale, Apr 23 2011 *)
  • PARI
    a(n)=(fibonacci(2*n-1)+fibonacci(n-2))/2

Formula

a(n) = 2a(n-1) + Sum{mA000045).
G.f.: x(1-x)(1-2x)/((1-x-x^2)(1-3x+x^2)).
a(n+1)=sum{k=0..floor(n/2), C(n,2k)*F(2k+1)}. [From Paul Barry, Oct 14 2009]
Showing 1-10 of 19 results. Next