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

A002605 a(n) = 2*(a(n-1) + a(n-2)), a(0) = 0, a(1) = 1.

Original entry on oeis.org

0, 1, 2, 6, 16, 44, 120, 328, 896, 2448, 6688, 18272, 49920, 136384, 372608, 1017984, 2781184, 7598336, 20759040, 56714752, 154947584, 423324672, 1156544512, 3159738368, 8632565760, 23584608256, 64434348032, 176037912576, 480944521216, 1313964867584
Offset: 0

Views

Author

Keywords

Comments

Individually, both this sequence and A028859 are convergents to 1 + sqrt(3). Mutually, both sequences are convergents to 2 + sqrt(3) and 1 + sqrt(3)/2. - Klaus E. Kastberg (kastberg(AT)hotkey.net.au), Nov 04 2001
The number of (s(0), s(1), ..., s(n+1)) such that 0 < s(i) < 6 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
The same sequence may be obtained by the following process. Starting a priori with the fraction 1/1, the denominators of fractions built according to the rule: add top and bottom to get the new bottom, add top and 4 times the bottom to get the new top. The limit of the sequence of fractions is sqrt(4). - Cino Hilliard, Sep 25 2005
The Hankel transform of this sequence is [1, 2, 0, 0, 0, 0, 0, 0, 0, ...]. - Philippe Deléham, Nov 21 2007
[1, 3; 1, 1]^n *[1, 0] = [A026150(n), a(n)]. - Gary W. Adamson, Mar 21 2008
(1 + sqrt(3))^n = A026150(n) + a(n)*sqrt(3). - Gary W. Adamson, Mar 21 2008
a(n+1) is the number of ways to tile a board of length n using red and blue tiles of length one and two. - Geoffrey Critzer, Feb 07 2009
Starting with offset 1 = INVERT transform of the Jacobsthal sequence, A001045: (1, 1, 3, 5, 11, 21, ...). - Gary W. Adamson, May 12 2009
Starting with "1" = INVERTi transform of A007482: (1, 3, 11, 39, 139, ...). - Gary W. Adamson, Aug 06 2010
An elephant sequence, see A175654. For the corner squares four A[5] vectors, with decimal values 85, 277, 337 and 340, lead to this sequence (without the leading 0). For the central square these vectors lead to the companion sequence A026150, without the first leading 1. - Johannes W. Meijer, Aug 15 2010
The sequence 0, 1, -2, 6, -16, 44, -120, 328, -896, ... (with alternating signs) is the Lucas U(-2,-2)-sequence. - R. J. Mathar, Jan 08 2013
a(n+1) counts n-walks (closed) on the graph G(1-vertex;1-loop,1-loop,2-loop,2-loop). - David Neil McGrath, Dec 11 2014
Number of binary strings of length 2*n - 2 in the regular language (00+11+0101+1010)*. - Jeffrey Shallit, Dec 14 2015
For n >= 1, a(n) equals the number of words of length n - 1 over {0, 1, 2, 3} in which 0 and 1 avoid runs of odd lengths. - Milan Janjic, Dec 17 2015
a(n+1) is the number of compositions of n into parts 1 and 2, both of two kinds. - Gregory L. Simay, Sep 20 2017
Number of associative, quasitrivial, and order-preserving binary operations on the n-element set {1, ..., n} that have neutral elements. - J. Devillet, Sep 28 2017
(1 + sqrt(3))^n = A026150(n) + a(n)*sqrt(3), for n >= 0; integers in the real quadratic number field Q(sqrt(3)). - Wolfdieter Lang, Feb 10 2018
Starting with 1, 2, 6, 16, ..., number of permutations of length n>0 avoiding the partially ordered pattern (POP) {1>3, 1>4} of length 4. That is, number of length n permutations having no subsequences of length 4 in which the first element is larger than the third and fourth elements. - Sergey Kitaev, Dec 09 2020
a(n) is the number of tilings of a 2 X n board missing one corner cell, with 1 X 1 and L-shaped tiles (where the L-shaped tiles cover 3 squares). Compare to A127864. - Greg Dresden and Yilin Zhu, Jul 17 2025

References

  • John Derbyshire, Prime Obsession, Joseph Henry Press, April 2004, p. 16.

Crossrefs

First differences are given by A026150.
a(n) = A073387(n, 0), n>=0 (first column of triangle).
Equals (1/3) A083337. First differences of A077846. Pairwise sums of A028860 and abs(A077917).
a(n) = A028860(n)/2 apart from the initial terms.
Row sums of A081577 and row sums of triangle A156710.
The following sequences (and others) belong to the same family: A001333, A000129, A026150, A046717, A015518, A084057, A063727, A002533, A002532, A083098, A083099, A083100, A015519.
Cf. A175289 (Pisano periods).
Cf. A002530.
Cf. A127864.

Programs

  • Haskell
    a002605 n = a002605_list !! n
    a002605_list =
       0 : 1 : map (* 2) (zipWith (+) a002605_list (tail a002605_list))
    -- Reinhard Zumkeller, Oct 15 2011
    
  • Magma
    [Floor(((1 + Sqrt(3))^n - (1 - Sqrt(3))^n)/(2*Sqrt(3))): n in [0..30]]; // Vincenzo Librandi, Aug 18 2011
    
  • Magma
    [n le 2 select n-1 else 2*Self(n-1) + 2*Self(n-2): n in [1..30]]; // G. C. Greubel, Jan 07 2018
  • Maple
    a[0]:=0:a[1]:=1:for n from 2 to 50 do a[n]:=2*a[n-1]+2*a[n-2]od: seq(a[n], n=0..33); # Zerinvary Lajos, Dec 15 2008
    a := n -> `if`(n<3, n, 2^(n-1)*hypergeom([1-n/2, (1-n)/2], [1-n], -2));
    seq(simplify(a(n)), n=0..29); # Peter Luschny, Dec 16 2015
  • Mathematica
    Expand[Table[((1 + Sqrt[3])^n - (1 - Sqrt[3])^n)/(2Sqrt[3]), {n, 0, 30}]] (* Artur Jasinski, Dec 10 2006 *)
    a[n_]:=(MatrixPower[{{1,3},{1,1}},n].{{1},{1}})[[2,1]]; Table[a[n],{n,-1,40}] (* Vladimir Joseph Stephan Orlovsky, Feb 19 2010 *)
    LinearRecurrence[{2, 2}, {0, 1}, 30] (* Robert G. Wilson v, Apr 13 2013 *)
    Round@Table[Fibonacci[n, Sqrt[2]] 2^((n - 1)/2), {n, 0, 20}] (* Vladimir Reshetnikov, Oct 15 2016 *)
    nxt[{a_,b_}]:={b,2(a+b)}; NestList[nxt,{0,1},30][[All,1]] (* Harvey P. Dale, Sep 17 2022 *)
  • PARI
    Vec(x/(1-2*x-2*x^2)+O(x^99)) \\ Charles R Greathouse IV, Jun 10 2011
    
  • PARI
    A002605(n)=([2,2;1,0]^n)[2,1] \\ M. F. Hasler, Aug 06 2018
    
  • Sage
    [lucas_number1(n,2,-2) for n in range(0, 30)] # Zerinvary Lajos, Apr 22 2009
    
  • Sage
    a = BinaryRecurrenceSequence(2,2)
    print([a(n) for n in (0..29)])  # Peter Luschny, Aug 29 2016
    

Formula

a(n) = (-I*sqrt(2))^(n-1)*U(n-1, I/sqrt(2)) where U(n, x) is the Chebyshev U-polynomial. - Wolfdieter Lang
G.f.: x/(1 - 2*x - 2*x^2).
From Paul Barry, Sep 17 2003: (Start)
E.g.f.: x*exp(x)*(sinh(sqrt(3)*x)/sqrt(3) + cosh(sqrt(3)*x)).
a(n) = (1 + sqrt(3))^(n-1)*(1/2 + sqrt(3)/6) + (1 - sqrt(3))^(n-1)*(1/2 - sqrt(3)/6), for n>0.
Binomial transform of 1, 1, 3, 3, 9, 9, ... Binomial transform is A079935. (End)
a(n) = Sum_{k=0..floor(n/2)} binomial(n - k, k)*2^(n - k). - Paul Barry, Jul 13 2004
a(n) = A080040(n) - A028860(n+1). - Creighton Dement, Jan 19 2005
a(n) = Sum_{k=0..n} A112899(n,k). - Philippe Deléham, Nov 21 2007
a(n) = Sum_{k=0..n} A063967(n,k). - Philippe Deléham, Nov 03 2006
a(n) = ((1 + sqrt(3))^n - (1 - sqrt(3))^n)/(2*sqrt(3)).
a(n) = Sum_{k=0..n} binomial(n, 2*k + 1) * 3^k.
Binomial transform of expansion of sinh(sqrt(3)x)/sqrt(3) (0, 1, 0, 3, 0, 9, ...). E.g.f.: exp(x)*sinh(sqrt(3)*x)/sqrt(3). - Paul Barry, May 09 2003
a(n) = (1/3)*Sum_{k=1..5} sin(Pi*k/2)*sin(2*Pi*k/3)*(1 + 2*cos(Pi*k/6))^n, n >= 1. - Herbert Kociemba, Jun 02 2004
a(n+1) = ((3 + sqrt(3))*(1 + sqrt(3))^n + (3 - sqrt(3))*(1 - sqrt(3))^n)/6. - Al Hakanson (hawkuu(AT)gmail.com), Jun 29 2009
Antidiagonals sums of A081577. - J. M. Bergot, Dec 15 2012
G.f.: Q(0)*x/2, where Q(k) = 1 + 1/(1 - x*(4*k + 2 + 2*x)/(x*(4*k + 4 + 2*x) + 1/Q(k+1) )); (continued fraction). - Sergei N. Gladkovskii, Aug 30 2013
a(n) = 2^(n - 1)*hypergeom([1 - n/2, (1 - n)/2], [1 - n], -2) for n >= 3. - Peter Luschny, Dec 16 2015
Sum_{k=0..n} a(k)*2^(n-k) = a(n+2)/2 - 2^n. - Greg Dresden, Feb 11 2022
a(n) = 2^floor(n/2) * A002530(n). - Gregory L. Simay, Sep 22 2022
From Peter Bala, May 08 2024: (Start)
G.f.: x/(1 - 2*x - 2*x^2) = Sum_{n >= 0} x^(n+1) *( Product_{k = 1..n} (k + 2*x + 1)/(1 + k*x) )
Also x/(1 - 2*x - 2*x^2) = Sum_{n >= 0} (2*x)^n *( x*Product_{k = 1..n} (m*k + 2 - m + x)/(1 + 2*m*k*x) ) for arbitrary m (both series are telescoping). (End)
a(n) = A127864(n-1) + A127864(n-2). - Greg Dresden and Yilin Zhu, Jul 17 2025

Extensions

Edited by N. J. A. Sloane, Apr 15 2009

A026150 a(0) = a(1) = 1; a(n+2) = 2*a(n+1) + 2*a(n).

Original entry on oeis.org

1, 1, 4, 10, 28, 76, 208, 568, 1552, 4240, 11584, 31648, 86464, 236224, 645376, 1763200, 4817152, 13160704, 35955712, 98232832, 268377088, 733219840, 2003193856, 5472827392, 14952042496, 40849739776
Offset: 0

Views

Author

Keywords

Comments

a(n+1)/A002605(n) converges to sqrt(3). - Mario Catalani (mario.catalani(AT)unito.it), Apr 22 2003
a(n+1)/a(n) converges to 1 + sqrt(3) = 2.732050807568877293.... - Philippe Deléham, Jul 03 2005
Binomial transform of expansion of cosh(sqrt(3)x) (A000244 with interpolated zeros); inverse binomial transform of A001075. - Philippe Deléham, Jul 04 2005
The same sequence may be obtained by the following process. Starting a priori with the fraction 1/1, the numerators of fractions built according to the rule: add top and bottom to get the new bottom, add top and 3 times the bottom to get the new top. The limit of the sequence of fractions is sqrt(3). - Cino Hilliard, Sep 25 2005
Inverse binomial transform of A001075: (1, 2, 7, 26, 97, 362, ...). - Gary W. Adamson, Nov 23 2007
Starting (1, 4, 10, 28, 76, ...), the sequence is the binomial transform of [1, 3, 3, 9, 9, 27, 27, 81, 81, ...], and inverse binomial transform of A001834: (1, 5, 19, 71, 265, ...). - Gary W. Adamson, Nov 30 2007
[1, 3; 1, 1]^n * [1,0] = [a(n), A002605(n)]. - Gary W. Adamson, Mar 21 2008
(1 + sqrt(3))^n = a(n) + A002605(n)*(sqrt(3)). - Gary W. Adamson, Mar 21 2008
Equals right border of triangle A143908. Also, starting (1, 4, 10, 28, ...) = row sums of triangle A143908 and INVERT transform of (1, 3, 3, 3, ...). - Gary W. Adamson, Sep 06 2008
a(n) is the number of compositions of n when there are 1 type of 1 and 3 types of other natural numbers. - Milan Janjic, Aug 13 2010
An elephant sequence, see A175655. For the central square four A[5] vectors, with decimal values 85, 277, 337 and 340, lead to this sequence (without the first leading 1). For the corner squares these vectors lead to the companion sequence A002605 (without the leading 0). - Johannes W. Meijer, Aug 15 2010
Pisano period lengths: 1, 1, 1, 1, 24, 1, 48, 1, 3, 24, 10, 1, 12, 48, 24, 1,144, 3,180, 24, ... - R. J. Mathar, Aug 10 2012
(1 + sqrt(3))^n = a(n) + A002605(n)*sqrt(3), for n >= 0; integers in the real quadratic number field Q(sqrt(3)). - Wolfdieter Lang, Feb 10 2018
a(n) is also the number of solutions for cyclic three-dimensional stable matching instances with master preference lists of size n (Escamocher and O'Sullivan 2018). - Guillaume Escamocher, Jun 15 2018
Starting from a(1), first differences of A005665. - Ivan N. Ianakiev, Nov 22 2019
Number of 3-permutations of n elements avoiding the patterns 231, 312. See Bonichon and Sun. - Michel Marcus, Aug 19 2022

Examples

			G.f. = 1 + x + 4*x^2 + 10*x^3 + 28*x^4 + 76*x^5 + 208*x^6 + 568*x^7 + ...
		

References

  • John Derbyshire, Prime Obsession, Joseph Henry Press, April 2004, see p. 16.

Crossrefs

First differences of A002605.
The following sequences (and others) belong to the same family: A001333, A000129, A026150, A002605, A046717, A015518, A084057, A063727, A002533, A002532, A083098, A083099, A083100, A015519.

Programs

  • Haskell
    a026150 n = a026150_list !! n
    a026150_list = 1 : 1 : map (* 2) (zipWith (+) a026150_list (tail
    a026150_list))
    -- Reinhard Zumkeller, Oct 15 2011
    
  • Magma
    [n le 2 select 1 else 2*Self(n-1) + 2*Self(n-2): n in [1..30]]; // G. C. Greubel, Jan 07 2018
  • Maple
    with(combstruct):ZL0:=S=Prod(Sequence(Prod(a, Sequence(b))), a):ZL1:=Prod(begin_blockP, Z, end_blockP):ZL2:=Prod(begin_blockLR, Z, Sequence(Prod(mu_length, Z), card>=1), end_blockLR): ZL3:=Prod(begin_blockRL, Sequence(Prod(mu_length, Z), card>=1), Z, end_blockRL):Q:=subs([a=Union(ZL2,ZL2,ZL2), b=ZL1], ZL0), begin_blockP=Epsilon, end_blockP=Epsilon, begin_blockLR=Epsilon, end_blockLR=Epsilon, begin_blockRL=Epsilon, end_blockRL=Epsilon, mu_length=Epsilon:temp15:=draw([S, {Q}, unlabelled], size=15):seq(count([S, {Q}, unlabelled], size=n)/3, n=2..27); # Zerinvary Lajos, Mar 08 2008
  • Mathematica
    Expand[Table[((1 + Sqrt[3])^n + (1 - Sqrt[3])^n)/(2), {n, 0, 30}]] (* Artur Jasinski, Dec 10 2006 *)
    LinearRecurrence[{2, 2}, {1, 1}, 30] (* T. D. Noe, Mar 25 2011 *)
    Round@Table[LucasL[n, Sqrt[2]] 2^(n/2 - 1), {n, 0, 20}] (* Vladimir Reshetnikov, Oct 15 2016 *)
  • Maxima
    a(n) := if n<=1 then 1 else 2*a(n-1)+2*a(n-2);
    makelist(a(n),n,0,20); /* Emanuele Munarini, Apr 14 2017 */
    
  • PARI
    {a(n) = if( n<0, 0, real((1 + quadgen(12))^n))};
    
  • Sage
    from sage.combinat.sloane_functions import recur_gen2; it = recur_gen2(1,1,2,2); [next(it) for i in range(30)] # Zerinvary Lajos, Jun 25 2008
    
  • Sage
    [lucas_number2(n,2,-2)/2 for n in range(0, 26)] # Zerinvary Lajos, Apr 30 2009
    

Formula

a(n) = (1/2)*((1 + sqrt(3))^n + (1 - sqrt(3))^n). - Benoit Cloitre, Oct 28 2002
G.f.: (1 - x)/(1 - 2*x - 2*x^2).
a(n) = a(n-1) + A083337(n-1). A083337(n)/a(n) converges to sqrt(3). - Mario Catalani (mario.catalani(AT)unito.it), Apr 29 2003
From Paul Barry, May 15 2003: (Start)
a(n) = Sum_{k=0..floor(n/2)} C(n, 2k)*3^k;
E.g.f.: exp(x)*cosh(sqrt(3)x). (End)
a(n) = Sum_{k=0..n} A098158(n,k)*3^(n - k). - Philippe Deléham, Dec 26 2007
a(n) = upper left and lower right terms of [1, 1; 3, 1]^n. (1 + sqrt(3))^n = a(n) + A083337(n)/(sqrt(3)). - Gary W. Adamson, Mar 12 2008
a(n) = A080040(n)/2. - Philippe Deléham, Nov 19 2008
If p[1] = 1, and p[i] = 3, (i > 1), and if A is Hessenberg matrix of order n defined by: A[i,j] = p[j-i+1], (i <= j), A[i,j] = -1, (i = j + 1), and A[i,j] = 0 otherwise. Then, for n >= 1, a(n) = det A. - Milan Janjic, Apr 29 2010
a(n) = 2 * A052945(n-1). - Vladimir Joseph Stephan Orlovsky, Mar 24 2011
a(n) = round((1 + sqrt(3))^n/2) for n > 0. - Bruno Berselli, Feb 04 2013
G.f.: G(0)/2, where G(k)= 1 + 1/(1 - x*(3*k - 1)/(x*(3*k + 2) - 1/G(k+1))); (continued fraction). - Sergei N. Gladkovskii, May 25 2013
a(n) = (-sqrt(2)*i)^n*T(n,sqrt(2)*i/2), with i = sqrt(-1) and the Chebyshev T-polynomials (A053120). - Wolfdieter Lang, Feb 10 2018

A030195 a(n) = 3*a(n-1) + 3*a(n-2), a(0)=0, a(1)=1.

Original entry on oeis.org

0, 1, 3, 12, 45, 171, 648, 2457, 9315, 35316, 133893, 507627, 1924560, 7296561, 27663363, 104879772, 397629405, 1507527531, 5715470808, 21668995017, 82153397475, 311467177476, 1180861724853, 4476986706987, 16973545295520
Offset: 0

Views

Author

Keywords

Comments

Scaled Chebyshev U-polynomials evaluated at I*sqrt(3)/2.
Number of zeros in the substitution system {0 -> 1111100, 1 -> 10} at step n from initial string "1" (1 -> 10 -> 101111100 -> ...). - Ilya Gutkovskiy, Apr 10 2017
a(n+1) is the number of compositions of n having parts 1 and 2, both of three kinds. - Gregory L. Simay, Sep 21 2017
More generally, define a(n) = k*a(n-1) + k*a(n-2), a(0) = 0 and a(1) = 1. Then g.f. a(n) = 1/(1 - k*x - k*x^2) and a(n+1) is the number of compositions of n having parts 1 and 2, both of k kinds. - Gregory L. Simay, Sep 22 2017

Examples

			G.f. = x + 3*x^2 + 12*x^3 + 45*x^4 + 171*x^5 + 648*x^6 + 2457*x^7 + ...
		

Crossrefs

Programs

  • Haskell
    a030195 n = a030195_list !! n
    a030195_list =
       0 : 1 : map (* 3) (zipWith (+) a030195_list (tail a030195_list))
    -- Reinhard Zumkeller, Oct 14 2011
    
  • Magma
    I:=[0,1]; [n le 2 select I[n] else 3*Self(n-1) + 3*Self(n-2): n in [1..30]]; // G. C. Greubel, Jan 24 2018
  • Mathematica
    CoefficientList[Series[1/(1-3x-3x^2), {x, 0, 25}], x] (* Zerinvary Lajos, Mar 22 2007 *)
    LinearRecurrence[{3, 3}, {0, 1}, 24] (* Or *)
    RecurrenceTable[{a[n] == 3 a[n - 1] + 3 a[n - 2], a[0] == 0, a[1] == 1}, a, {n, 0, 23}] (* Robert G. Wilson v, Aug 18 2012 *)
  • PARI
    {a(n) = n--; polchebyshev(n, 2, I*sqrt(3)/2) * (-I*sqrt(3))^n};
    
  • Sage
    [lucas_number1(n,3,-3) for n in range(0, 25)] # Zerinvary Lajos, Apr 22 2009
    

Formula

a(n+1) = (-I*sqrt(3))^n*U(n, I*sqrt(3)/2).
G.f.: x / (1 - 3*x - 3*x^2).
a(n+1) = Sum_{k=0..floor(n/2)} 3^(n-k)*binomial(n-k, k). - Emeric Deutsch, Nov 14 2001
a(n) = (p^n - q^n)/sqrt(21); p = (3 + sqrt 21)/2, q = (3 - sqrt 21)/2. - Gary W. Adamson, Jul 02 2003
For n > 0, a(n) = Sum_{k=0..n-1} (2^k)*A063967(n-1,k). - Gerald McGarvey, Jul 23 2006
a(n+1) = Sum_{k=0..n} 2^k*A063967(n,k). - Philippe Deléham, Nov 03 2006

Extensions

Edited by Ralf Stephan, Aug 02 2004
I simplified the definition. As a result the offsets in some of the formulas may need to shifted by 1. - N. J. A. Sloane, Apr 01 2006
Formulas shifted to match offset. - Charles R Greathouse IV, Jan 31 2011

A030528 Triangle read by rows: a(n,k) = binomial(k,n-k).

Original entry on oeis.org

1, 1, 1, 0, 2, 1, 0, 1, 3, 1, 0, 0, 3, 4, 1, 0, 0, 1, 6, 5, 1, 0, 0, 0, 4, 10, 6, 1, 0, 0, 0, 1, 10, 15, 7, 1, 0, 0, 0, 0, 5, 20, 21, 8, 1, 0, 0, 0, 0, 1, 15, 35, 28, 9, 1, 0, 0, 0, 0, 0, 6, 35, 56, 36, 10, 1, 0, 0, 0, 0, 0, 1, 21, 70, 84, 45, 11, 1, 0, 0, 0, 0, 0, 0, 7, 56, 126, 120, 55, 12, 1
Offset: 1

Views

Author

Keywords

Comments

A convolution triangle of numbers obtained from A019590.
a(n,m) := s1(-1; n,m), a member of a sequence of triangles including s1(0; n,m)= A023531(n,m) (unit matrix) and s1(2; n,m)= A007318(n-1,m-1) (Pascal's triangle).
The signed triangular matrix a(n,m)*(-1)^(n-m) is the inverse matrix of the triangular Catalan convolution matrix A033184(n+1,m+1), n >= m >= 0, with A033184(n,m) := 0 if n
Riordan array (1+x, x(1+x)). The signed triangle is the Riordan array (1-x,x(1-x)), inverse to (c(x),xc(x)) with c(x) g.f. for A000108. - Paul Barry, Feb 02 2005 [with offset 0]
Also, a(n,k)=number of compositions of n into k parts of 1's and 2's. Example: a(6,4)=6 because we have 2211, 2121, 2112, 1221, 1212 and 1122. - Emeric Deutsch, Apr 05 2005 [see MacMahon and Riordan. - Wolfdieter Lang, Jul 27 2023]
Subtriangle of A026729. - Philippe Deléham, Aug 31 2006
a(n,k) is the number of length n-1 binary sequences having no two consecutive 0's with exactly k-1 1's. Example: a(6,4)=6 because we have 01011, 01101, 01110, 10101, 10110, 11010. - Geoffrey Critzer, Jul 22 2013
Mirrored, shifted Fibonacci polynomials of A011973. The polynomials (illustrated below) of this entry have the property that p(n,t) = t * [p(n-1,t) + p(n-2,t)]. The additive properties of Pascal's triangle (A007318) are reflected in those of these polynomials, as can be seen in the Example Section below and also when the o.g.f. G(x,t) below is expanded as the series x*(1+x) + t * [x*(1+x)]^2 + t^2 * [x*(1+x)]^3 + ... . See also A053122 for a relation to Cartan matrices. - Tom Copeland, Nov 04 2014
Rows of this entry appear as columns of an array for an infinitesimal generator presented in the Copeland link. - Tom Copeland, Dec 23 2015
For n >= 2, the n-th row is also the coefficients of the vertex cover polynomial of the (n-1)-path graph P_{n-1}. - Eric W. Weisstein, Apr 10 2017
With an additional initial matrix element a_(0,0) = 1 and column of zeros a_(n,0) = 0 for n > 0, these are antidiagonals read from bottom to top of the numerical coefficients of the Maurer-Cartan form matrix of the Leibniz group L^(n)(1,1) presented on p. 9 of the Olver paper, which is generated as exp[c. * M] with (c.)^n = c_n and M the Lie infinitesimal generator A218272. Cf. A011973. And A169803. - Tom Copeland, Jul 02 2018

Examples

			Triangle starts:
  [ 1]  1
  [ 2]  1   1
  [ 3]  0   2   1
  [ 4]  0   1   3   1
  [ 5]  0   0   3   4   1
  [ 6]  0   0   1   6   5   1
  [ 7]  0   0   0   4  10   6   1
  [ 8]  0   0   0   1  10  15   7   1
  [ 9]  0   0   0   0   5  20  21   8   1
  [10]  0   0   0   0   1  15  35  28   9   1
  [11]  0   0   0   0   0   6  35  56  36  10   1
  [12]  0   0   0   0   0   1  21  70  84  45  11   1
  [13]  0   0   0   0   0   0   7  56 126 120  55  12   1
  ...
From _Tom Copeland_, Nov 04 2014: (Start)
For quick comparison to other polynomials:
  p(1,t) = 1
  p(2,t) = 1 + 1 t
  p(3,t) = 0 + 2 t + 1 t^2
  p(4,t) = 0 + 1 t + 3 t^2 + 1 t^3
  p(5,t) = 0 + 0   + 3 t^2 + 4 t^3 +  1 t^4
  p(6,t) = 0 + 0   + 1 t^2 + 6 t^3 +  5 t^4 +  1 t^5
  p(7,t) = 0 + 0   + 0     + 4 t^3 + 10 t^4 +  6 t^5 + 1 t^6
  p(8,t) = 0 + 0   + 0     + 1 t^3 + 10 t^4 + 15 t^5 + 7 t^6 + 1 t^7
  ...
Reading along columns gives rows for Pascal's triangle. (End)
		

References

  • P. A. MacMahon, Combinatory Analysis, Two volumes (bound as one), Chelsea Publishing Company, New York, 1960, Vol. I, nr. 124, p. 151.
  • John Riordan, An Introduction to Combinatorial Analysis, John Wiley & Sons, London, 1958. eq. (35), p.124, 11. p. 154.

Crossrefs

Row sums A000045(n+1) (Fibonacci). a(n, 1)= A019590(n) (Fermat's last theorem). Cf. A049403.

Programs

  • Magma
    /* As triangle */ [[Binomial(k, n-k): k in [1..n]]: n in [1.. 15]]; // Vincenzo Librandi, Nov 05 2014
  • Maple
    for n from 1 to 12 do seq(binomial(k,n-k),k=1..n) od; # yields sequence in triangular form - Emeric Deutsch, Apr 05 2005
  • Mathematica
    nn=10;CoefficientList[Series[(1+x)/(1-y x - y x^2),{x,0,nn}],{x,y}]//Grid (* Geoffrey Critzer, Jul 22 2013 *)
    Table[Binomial[k, n - k], {n, 13}, {k, n}] // Flatten (* Michael De Vlieger, Dec 23 2015 *)
    CoefficientList[Table[x^(n/2 - 1) Fibonacci[n + 1, Sqrt[x]], {n, 10}],
       x] // Flatten (* Eric W. Weisstein, Apr 10 2017 *)

Formula

a(n, m) = 2*(2*m-n+1)*a(n-1, m)/n + m*a(n-1, m-1)/n, n >= m >= 1; a(n, m) := 0, n
G.f. for m-th column: (x*(1+x))^m.
As a number triangle with offset 0, this is T(n, k) = Sum_{i=0..n} (-1)^(n+i)*binomial(n, i)*binomial(i+k+1, 2k+1). The antidiagonal sums give the Padovan sequence A000931(n+5). Inverse binomial transform of A078812 (product of lower triangular matrices). - Paul Barry, Jun 21 2004
G.f.: (1 + x)/(1 - y*x - y*x^2). - Geoffrey Critzer, Jul 22 2013 [offset 0] [with offset 1: g.f. of row polynomials in y: x*(1+x)*y/(1 - x*(1+x)*y). - Wolfdieter Lang, Jul 27 2023]
From Tom Copeland, Nov 04 2014: (Start)
O.g.f: G(x,t) = x*(1+x) / [1 - t*x*(1+x)] = -P[Cinv(-x),t], where P(x,t)= x / (1 + t*x) and Cinv(x)= x*(1-x) are the compositional inverses in x of Pinv(x,t) = -P(-x,t) = x / (1 - t*x) and C(x) = [1-sqrt(1-4*x)]/2, an o.g.f. for the shifted Catalan numbers A000108.
Therefore, Ginv(x,t) = -C[Pinv(-x,t)] = {-1 + sqrt[1 + 4*x/(1+t*x)]}/2, which is -A124644(-x,t).
This places this array in a family of arrays related by composition of P and C and their inverses and interpolation by t, such as A091867 and A104597, and associated to the Catalan, Motzkin, Fine, and Fibonacci numbers. Cf. A104597 (polynomials shifted in t) A125145, A146559, A057078, A000045, A155020, A125145, A039717, A001792, A057862, A011973, A115139. (End)

Extensions

More terms from Emeric Deutsch, Apr 05 2005

A002697 a(n) = n*4^(n-1).

Original entry on oeis.org

0, 1, 8, 48, 256, 1280, 6144, 28672, 131072, 589824, 2621440, 11534336, 50331648, 218103808, 939524096, 4026531840, 17179869184, 73014444032, 309237645312, 1305670057984, 5497558138880, 23089744183296
Offset: 0

Keywords

Comments

Coefficient of x^(2n-2) in Chebyshev polynomial T(2n) is -a(n).
Let M_n be the n X n matrix m_(i,j) = 1 + 2*abs(i-j); then det(M_n) = (-1)^(n-1)*a(n-1). - Benoit Cloitre, May 28 2002
Number of subsequences 00 in all words of length n+1 on the alphabet {0,1,2,3}. Example: a(2)=8 because we have 000,001,002,003,100,200,300 (the other 57=A125145(3) words of length 3 have no subsequences 00). a(n) = Sum_{k=0..n} k*A128235(n+1, k). - Emeric Deutsch, Feb 27 2007
Let P(A) be the power set of an n-element set A. Then a(n) = the sum of the size of the symmetric difference of x and y for every subset {x,y} of P(A). - Ross La Haye, Dec 30 2007 (See the comment from Bernard Schott below.)
Let P(A) be the power set of an n-element set A and B be the Cartesian product of P(A) with itself. Then remove (y,x) from B when (x,y) is in B and x != y and call this R35. Then a(n) = the sum of the size of the symmetric difference of x and y for every (x,y) of R35. [proposed edit of comment just above; by Ross La Haye]
The numbers in this sequence are the Wiener indices of the graphs of n-cubes (Boolean hypercubes). For example, the 3-cube is the graph of the standard cube whose Wiener index is 48. - K.V.Iyer, Feb 26 2009
From Gary W. Adamson, Sep 06 2009: (Start)
Starting (1, 8, 48, ...) = 4th binomial transform of [1, 4, 0, 0, 0, ...].
Equals the sum of terms in 2^n X 2^n semi-magic square arrays in which each row and column is composed of a binomial frequency of terms in the set (1, 3, 5, 7, ...).
The first few such arrays = [1] [1,3; 3,1]; /Q.
[1, 3, 5, 3;
3, 1, 3, 5;
5, 3, 1, 3;
3, 5, 3, 1]
(sum of terms = 48, with a binomial frequency of (1, 2, 1) as to (1, 3, 5) in each row and column)
[1, 3, 5, 3, 5, 7, 5, 3;
3, 1, 3, 5, 7, 5, 3, 5;
5, 3, 1, 3, 5, 3, 5, 7;
3, 5, 3, 1, 3, 5, 7, 5;
5, 7, 5, 3, 1, 3, 5, 3;
7, 5, 3, 5, 3, 1, 3, 5;
5, 3, 5, 7, 5, 3, 1, 3;
3, 5, 7, 5, 3, 5, 3, 1]
(sum of terms = 256, with each row and column composed of one 1, three 3's, three 5's, and one 7)
... (End)
Let P(A) be the power set of an n-element set A and B be the Cartesian product of P(A) with itself. Then a(n) = the sum of the size of the intersection of x and y for every (x,y) of B. - Ross La Haye, Jan 05 2013
Following the last comment of Ross, A002699 is the similar sequence when "intersection" is replaced by "symmetric difference" and A212698 is the similar sequence when "intersection" is replaced by "union". - Bernard Schott, Jan 04 2013
Also, following the first comment of Ross, A082134 is the similar sequence when "symmetric difference" is replaced by "intersection" and A133224 is the similar sequence when "symmetric difference" is replaced by "union". - Bernard Schott, Jan 15 2013
Let [n] denote the set {1,2,3,...,n} and denote an n-permutation of the elements of [n] by p = p(1)p(2)p(3)...p(n), where p(i) is the i-th entry in the linear order given by p. Then (p(i),p(j)) is an inversion of p if i < j but p(i) > p(j). Denote the number of inversions of p by inv(p) and call a 2n-permutation p = p(1)p(2)...p(2n) 2-ordered if p(1) < p(3) < ... < p(2n-1) and p(2) < p(4) < ... < p(2n). Then Sum(inv(p)) = n*4^(n-1), where the sum is taken over all 2-ordered 2n-permutations of p. See Bona reference below. - Ross La Haye, Jan 21 2014
Sum over all peaks of Dyck paths of semilength n of the product of the x and y coordinates. - Alois P. Heinz, May 29 2015
Sum of the number of all edges over all j-dimensional subcubes of the boolean hypercube graph of dimension n, Q_n, for all j, so a(n) = Sum_{j=1..n} binomial(n,j)*2^(n-j) * j*2^(j-1). - Constantinos Kourouzides, Mar 24 2024

Examples

			From _Bernard Schott_, Jan 04 2013: (Start)
See the comment about intersection of X and Y.
If A={b,c}, then in P(A) we have:
{b}Inter{b}={b},
{b}Inter{b,c}={b},
{c}Inter{c}={c},
{c}Inter{b,c}={c},
{b,c}Inter{b}={b},
{b,c}Inter{c}={c},
{b,c}Inter{b,c}={b,c}
and : #{b}+ #{b}+ #{c}+ #{c}+ #{b}+ #{c}+ #{b,c} = 8 = 2*4^(2-1) = a(2).
The other intersections are empty.
(End)
		

References

  • Miklos Bona, Combinatorics of Permutations, Chapman and Hall/CRC, 2004, pp. 1, 43, 64.
  • C. Lanczos, Applied Analysis. Prentice-Hall, Englewood Cliffs, NJ, 1956, p. 516.
  • 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).

Programs

Formula

a(n) = n*4^(n-1).
G.f.: x/(1-4x)^2. a(n+1) is the convolution of powers of 4 (A000302). - Wolfdieter Lang, May 16 2003
Third binomial transform of n. E.g.f.: x*exp(4x). - Paul Barry, Jul 22 2003
a(n) = Sum_{k=0..n} k*binomial(2*n, 2*k). - Benoit Cloitre, Jul 30 2003
For n>=0, a(n+1) = Sum_{i+j+k+l=n} binomial(2i, i)*binomial(2j, j)*binomial(2k, k)*binomial(2l, l). - Philippe Deléham, Jan 22 2004
a(n) = Sum_{k=0..n} 4^(n-k)*binomial(n-k+1, k)*binomial(1, (k+1)/2)*(1-(-1)^k)/2. - Paul Barry, Oct 15 2004
Sum_{n>0} 1/a(n) = 8*log(2) - 4*log(3). - Jaume Oliver Lafont, Sep 11 2009
a(0) = 0, a(n) = 4*a(n-1) + 4^(n-1). - Vincenzo Librandi, Dec 31 2010
a(n+1) is the convolution of A000984 with A002457. - Rui Duarte, Oct 08 2011
a(0) = 0, a(1) = 1, a(n) = 8*a(n-1) - 16*a(n-2). - Harvey P. Dale, Jan 18 2012
a(n) = A002699(n)/2 = A212698(n)/3. - Bernard Schott, Jan 04 2013
G.f.: W(0)*x/2 , where W(k) = 1 + 1/( 1 - 4*x*(k+2)/( 4*x*(k+2) + (k+1)/W(k+1) )); (continued fraction). - Sergei N. Gladkovskii, Aug 19 2013
Sum_{n>=1} (-1)^(n+1)/a(n) = 4*log(5/4). - Amiram Eldar, Oct 28 2020
a(n) = (1/2)*Sum_{k=0..n} k*binomial(2*n, k). Compare this with the formula of Benoit Cloitre above. - Wolfdieter Lang, Nov 12 2021
a(n) = (-1)^(n-1)*det(M(n)) for n > 0, where M(n) is the n X n symmetric Toeplitz matrix whose first row consists of 1, 3, ..., 2*n-1. - Stefano Spezia, Aug 04 2022

A291382 p-INVERT of (1,1,0,0,0,0,...), where p(S) = 1 - 2 S - S^2.

Original entry on oeis.org

2, 7, 22, 70, 222, 705, 2238, 7105, 22556, 71608, 227332, 721705, 2291178, 7273743, 23091762, 73308814, 232731578, 738846865, 2345597854, 7446508273, 23640235416, 75050038224, 238259397096, 756395887969, 2401310279090, 7623377054503, 24201736119310
Offset: 0

Author

Clark Kimberling, Sep 04 2017

Keywords

Comments

Suppose s = (c(0), c(1), c(2), ...) is a sequence and p(S) is a polynomial. Let S(x) = c(0)*x + c(1)*x^2 + c(2)*x^3 + ... and T(x) = (-p(0) + 1/p(S(x)))/x. The p-INVERT of s is the sequence t(s) of coefficients in the Maclaurin series for T(x). Taking p(S) = 1 - S gives the "INVERT" transform of s, so that p-INVERT is a generalization of the "INVERT" transform (e.g., A033453).
In the following guide to p-INVERT sequences using s = (1,1,0,0,0,...) = A019590, in some cases t(1,1,0,0,0,...) is a shifted version of the cited sequence:
p(S) t(1,1,0,0,0,...)
1 - S A000045 (Fibonacci numbers)
1 - S^2 A094686
1 - S^3 A115055
1 - S^4 A291379
1 - S^5 A281380
1 - S^6 A281381
1 - 2 S A002605
1 - 3 S A125145
(1 - S)^2 A001629
(1 - S)^3 A001628
(1 - S)^4 A001629
(1 - S)^5 A001873
(1 - S)^6 A001874
1 - S - S^2 A123392
1 - 2 S - S^2 A291382
1 - S - 2 S^2 A124861
1 - 2 S - S^2 A291383
(1 - 2 S)^2 A073388
(1 - 3 S)^2 A291387
(1 - 5 S)^2 A291389
(1 - 6 S)^2 A291391
(1 - S)(1 - 2 S) A291393
(1 - S)(1 - 3 S) A291394
(1 - 2 S)(1 - 3 S) A291395
(1 - S)(1 - 2 S) A291393
(1 - S)(1 - 2 S)(1 - 3 S) A291396
1 - S - S^3 A291397
1 - S^2 - S^3 A291398
1 - S - S^2 - S^3 A186812
1 - S - S^2 - S^3 - S^4 A291399
1 - S^2 - S^4 A291400
1 - S - S^4 A291401
1 - S^3 - S^4 A291402
1 - 2 S^2 - S^4 A291403
1 - S^2 - 2 S^4 A291404
1 - 2 S^2 - 2 S^4 A291405
1 - S^3 - S^6 A291407
(1 - S)(1 - S^2) A291408
(1 - S^2)(1 - S)^2 A291409
1 - S - S^2 - 2 S^3 A291410
1 - 2 S - S^2 + S^3 A291411
1 - S - 2 S^2 + S^3 A291412
1 - 3 S + S^2 + S^3 A291413
1 - 2 S + S^3 A291414
1 - 3 S + S^2 A291415
1 - 4 S + S^2 A291416
1 - 4 S + 2 S^2 A291417

Programs

  • Mathematica
    z = 60; s = x + x^2; p = 1 - 2 s - s^2;
    Drop[CoefficientList[Series[s, {x, 0, z}], x], 1]  (* A019590 *)
    Drop[CoefficientList[Series[1/p, {x, 0, z}], x], 1]  (* A291382 *)

Formula

G.f.: (-2 - 3 x - 2 x^2 - x^3)/(-1 + 2 x + 3 x^2 + 2 x^3 + x^4).
a(n) = 2*a(n-1) + 3*a(n-2) + 2*a(n-3) + a(n-4) for n >= 5.

A028859 a(n+2) = 2*a(n+1) + 2*a(n); a(0) = 1, a(1) = 3.

Original entry on oeis.org

1, 3, 8, 22, 60, 164, 448, 1224, 3344, 9136, 24960, 68192, 186304, 508992, 1390592, 3799168, 10379520, 28357376, 77473792, 211662336, 578272256, 1579869184, 4316282880, 11792304128, 32217174016, 88018956288, 240472260608, 656982433792, 1794909388800, 4903783645184, 13397386067968
Offset: 0

Keywords

Comments

Number of words of length n without adjacent 0's from the alphabet {0,1,2}. For example, a(2) counts 01,02,10,11,12,20,21,22. - Antonio G. Astudillo (afg_astudillo(AT)hotmail.com), Jun 12 2001
Individually, both this sequence and A002605 are convergents to 1+sqrt(3). Mutually, both sequences are convergents to 2+sqrt(3) and 1+sqrt(3)/2. - Klaus E. Kastberg (kastberg(AT)hotkey.net.au), Nov 04 2001 [Can someone clarify what is meant by the obscure second phrase, "Mutually..."? - M. F. Hasler, Aug 06 2018]
Add a loop at two vertices of the graph C_3=K_3. a(n) counts walks of length n+1 between these vertices. - Paul Barry, Oct 15 2004
Prefaced with a 1 as (1 + x + 3x^2 + 8x^3 + 22x^4 + ...) = 1 / (1 - x - 2x^2 - 3x^3 - 5x^4 - 8x^5 - 13x^6 - 21x^7 - ...). - Gary W. Adamson, Jul 28 2009
Equals row 2 of the array in A180165, and the INVERTi transform of A125145. - Gary W. Adamson, Aug 14 2010
Pisano period lengths: 1, 1, 3, 1, 24, 3, 48, 1, 9, 24, 10, 3, 12, 48, 24, 1, 144, 9, 180, 24, .... - R. J. Mathar, Aug 10 2012
Also the number of independent vertex sets and vertex covers in the n-centipede graph. - Eric W. Weisstein, Sep 21 2017
From Gus Wiseman, May 19 2020: (Start)
Conjecture: Also the number of length n + 1 sequences that cover an initial interval of positive integers and whose non-adjacent parts are weakly decreasing. For example, (3,2,3,1,2) has non-adjacent pairs (3,3), (3,1), (3,2), (2,1), (2,2), (3,2), all of which are weakly decreasing, so is counted under a(11). The a(1) = 1 through a(3) = 8 sequences are:
(1) (11) (111)
(12) (121)
(21) (211)
(212)
(221)
(231)
(312)
(321)
The case of compositions is A333148, or A333150 for strict compositions, or A333193 for strictly decreasing parts. A version for ordered set partitions is A332872. Standard composition numbers of these compositions are A334966. Unimodal normal sequences are A227038. See also: A001045, A001523, A032020, A100471, A100881, A115981, A329398, A332836, A332872.
(End)
Number of 2-compositions of n+1 restricted to parts 1 and 2 (and allowed zeros); see Hopkins & Ouvry reference. - Brian Hopkins, Aug 16 2020
The number of ternary strings of length n not containing 00. Complement of A186244. - R. J. Mathar, Feb 13 2022

References

  • S. J. Cyvin and I. Gutman, Kekulé structures in benzenoid hydrocarbons, Lecture Notes in Chemistry, No. 46, Springer, New York, 1988 (see p. 73).

Crossrefs

Cf. A155020 (same sequence with term 1 prepended).
Cf. A002605.

Programs

  • Haskell
    a028859 n = a028859_list !! n
    a028859_list =
       1 : 3 : map (* 2) (zipWith (+) a028859_list (tail a028859_list))
    -- Reinhard Zumkeller, Oct 15 2011
    
  • Maple
    a[0]:=1:a[1]:=3:for n from 2 to 24 do a[n]:=2*a[n-1]+2*a[n-2] od: seq(a[n],n=0..24); # Emeric Deutsch
  • Mathematica
    a[n_]:=(MatrixPower[{{1,3},{1,1}},n].{{2},{1}})[[2,1]]; Table[a[n],{n,0,40}] (* Vladimir Joseph Stephan Orlovsky, Feb 20 2010 *)
    Table[2^(n - 1) Hypergeometric2F1[(1 - n)/2, -n/2, -n, -2], {n, 20}] (* Eric W. Weisstein, Jun 14 2017 *)
    LinearRecurrence[{2, 2}, {1, 3}, 20] (* Eric W. Weisstein, Jun 14 2017 *)
  • PARI
    a(n)=([1,3;1,1]^n*[2;1])[2,1] \\ Charles R Greathouse IV, Mar 27 2012
    
  • PARI
    A028859(n)=([1,1]*[2,2;1,0]^n)[1] \\ M. F. Hasler, Aug 06 2018

Formula

a(n) = a(n-1) + A052945(n) = A002605(n) + A002605(n-1).
G.f.: -(x+1)/(2*x^2+2*x-1).
a(n) = [(1+sqrt(3))^(n+2)-(1-sqrt(3))^(n+2)]/(4*sqrt(3)). - Emeric Deutsch, Feb 01 2005
If p[i]=fibonacci(i+1) and if A is the Hessenberg matrix of order n defined by: A[i,j]=p[j-i+1], (i<=j), A[i,j]=-1, (i=j+1), and A[i,j]=0 otherwise. Then, for n>=1, a(n-1)= det A. - Milan Janjic, May 08 2010
a(n) = 3^n - A186244(n). - Toby Gottfried, Mar 07 2013
E.g.f.: exp(x)*(cosh(sqrt(3)*x) + 2*sinh(sqrt(3)*x)/sqrt(3)). - Stefano Spezia, Mar 02 2024

Extensions

Definition completed by M. F. Hasler, Aug 06 2018

A080040 a(n) = 2*a(n-1) + 2*a(n-2) for n > 1; a(0)=2, a(1)=2.

Original entry on oeis.org

2, 2, 8, 20, 56, 152, 416, 1136, 3104, 8480, 23168, 63296, 172928, 472448, 1290752, 3526400, 9634304, 26321408, 71911424, 196465664, 536754176, 1466439680, 4006387712, 10945654784, 29904084992, 81699479552, 223207129088, 609813217280, 1666040692736, 4551707820032
Offset: 0

Author

Mario Catalani (mario.catalani(AT)unito.it), Jan 21 2003

Keywords

Comments

The Lucas sequence V_n(2,-2). - Jud McCranie, Mar 02 2012
The signed version 2, -2, 8, -20, 56, -152, 416, -1136, 3104, -8480, 23168, ... is the Lucas sequence V(-2,-2). - R. J. Mathar, Jan 08 2013
After a(2) equals round((1+sqrt(3))^n) = 1, 3, 7, 20, 56, 152, ... - Jeremy Gardiner, Aug 11 2013
Also the number of independent vertex sets and vertex covers in the n-sunlet graph. - Eric W. Weisstein, Sep 27 2017

Crossrefs

Programs

  • Haskell
    a080040 n = a080040_list !! n
    a080040_list =
       2 : 2 : map (* 2) (zipWith (+) a080040_list (tail a080040_list))
    -- Reinhard Zumkeller, Oct 15 2011
    
  • Magma
    a:=[2,2]; [n le 2 select a[n] else 2*Self(n-1) + 2*Self(n-2):n in [1..27]]; Marius A. Burtea, Jan 20 2020
    
  • Magma
    R:=PowerSeriesRing(Rationals(), 27); Coefficients(R!( (2-2*x)/(1-2*x-2*x^2))); // Marius A. Burtea, Jan 20 2020
  • Mathematica
    CoefficientList[Series[(2 - 2 t)/(1 - 2 t - 2 t^2), {t, 0, 30}], t]
    With[{c = {2, 2}}, LinearRecurrence[c, c, 20]] (* Harvey P. Dale, Apr 24 2016 *)
    Round @ Table[LucasL[n, Sqrt[2]] 2^(n/2), {n, 0, 20}] (* Vladimir Reshetnikov, Sep 15 2016 *)
    Table[(1 - Sqrt[3])^n + (1 + Sqrt[3])^n, {n, 0, 20}] // Expand (* Eric W. Weisstein, Sep 27 2017 *)
  • PARI
    a(n)=([0,1; 2,2]^n*[2;2])[1,1] \\ Charles R Greathouse IV, Apr 08 2016
    
  • Sage
    from sage.combinat.sloane_functions import recur_gen2b; it = recur_gen2b(2,2,2,2, lambda n: 0); [next(it) for i in range(27)] # Zerinvary Lajos, Jul 16 2008
    
  • Sage
    [lucas_number2(n,2,-2) for n in range(0, 27)] # Zerinvary Lajos, Apr 30 2009
    

Formula

G.f.: (2-2*x)/(1-2*x-2*x^2).
a(n) = (1+sqrt(3))^n + (1-sqrt(3))^n.
a(n) = 2*A026150(n). - Philippe Deléham, Nov 19 2008
G.f.: G(0), where G(k) = 1 + 1/(1 - x*(3*k-1)/(x*(3*k+2) - 1/G(k+1))); (continued fraction). - Sergei N. Gladkovskii, Jun 11 2013
a(n) = 2*2^floor(n/2)*A002531(n). - Ralf Stephan, Sep 08 2013
a(n) = [x^n] ( 1 + x + sqrt(1 + 2*x + 3*x^2) )^n for n >= 1. - Peter Bala, Jun 29 2015
E.g.f.: 2*exp(x)*cosh(sqrt(3)*x). - Stefano Spezia, Mar 02 2024

A064613 Second binomial transform of the Catalan numbers.

Original entry on oeis.org

1, 3, 10, 37, 150, 654, 3012, 14445, 71398, 361114, 1859628, 9716194, 51373180, 274352316, 1477635912, 8016865533, 43773564294, 240356635170, 1326359740956, 7351846397334, 40913414754324, 228508350629892
Offset: 0

Author

Karol A. Penson, Sep 24 2001

Keywords

Comments

Exponential convolution of Catalan numbers and powers of 2. - Vladeta Jovovic, Dec 03 2004
Hankel transform of this sequence gives A000012 = [1,1,1,1,1,...]. - Philippe Deléham, Oct 24 2007
a(n) is the number of Motzkin paths of length n in which the (1,0)-steps at level 0 come in 3 colors and those at a higher level come in 4 colors. Example: a(3)=37 because, denoting U=(1,1), H=(1,0), and D=(1,-1), we have 3^3 = 27 paths of shape HHH, 3 paths of shape HUD, 3 paths of shape UDH, and 4 paths of shape UHD. - Emeric Deutsch, May 02 2011
a(n) is the number of Schroeder paths of semilength n in which the (2,0)-steps come in 2 colors and having no (2,0)-steps at levels 1,3,5,... - José Luis Ramírez Ramírez, Mar 30 2013
From Tom Copeland, Nov 08 2014: (Start)
This array is one of a family of Catalan arrays related by compositions of the special fractional linear (Möbius) transformations P(x,t)=x/(1-t*x); its inverse Pinv(x,t) = P(x,-t); and an o.g.f. of the Catalan numbers A000108, C(x) = [1-sqrt(1-4x)]/2; and its inverse Cinv(x) = x*(1-x). (Cf A126930.)
O.g.f.: G(x) = C[P[P(x,-1),-1]] = C[P(x,-2)] = (1-sqrt(1-4*x/(1-2*x)))/2 = x*A064613(x).
Ginv(x) = Pinv[Cinv(x),-2] = P[Cinv(x),2] = x(1-x)/[1+2x(1-x)] = (x-x^2)/[1+2(x-x^2)] = x - 3 x^2 + 8 x^3 - ... is -A155020(-x) ignoring first term there. (Cf. A146559, A125145.)(End)

Crossrefs

Programs

  • Magma
    I:=[3,10]; [1] cat [n le 2 select I[n] else ((8*n-2)*Self(n-1)-(12*n-12)*Self(n-2))div (n+1): n in [1..30]]; // Vincenzo Librandi, Jan 23 2017
  • Mathematica
    CoefficientList[Series[(1-Sqrt[(1-6*x)/(1-2*x)])/2/x, {x, 0, 20}], x] (* Vaclav Kotesovec, Jun 29 2013 *)
    a[n_] := 2^n Hypergeometric2F1[1/2, -n, 2, -2];
    Array[a, 22, 0] (* Peter Luschny, Jan 27 2020 *)
  • PARI
    x='x+O('x^66); Vec((1-sqrt((1-6*x)/(1-2*x)))/(2*x)) /* Joerg Arndt, Mar 31 2013 */
    

Formula

a(n) = Sum_{k=0..n} binomial(n, k)*binomial(2*k, k)*2^(n-k)/(k+1).
a(n) = 2^n*hypergeom([1/2, -n], [2], -2).
G.f.: (1-sqrt((1-6*x)/(1-2*x)))/(2*x). - Vladeta Jovovic, May 03 2003
With offset 1: a(1) = 1, a(n) = 2^(n-1) + Sum_{i=1..n-1} a(i)*a(n-i). - Benoit Cloitre, Mar 16 2004
D-finite with recurrence (n+1)*a(n) = (8*n-2)*a(n-1) - (12*n-12)*a(n-2). - Vladeta Jovovic, Jul 16 2004
E.g.f.: exp(4*x)*(BesselI(0, 2*x) - BesselI(1, 2*x)). - Vladeta Jovovic, Dec 03 2004
Inverse binomial transform of A104455. - Philippe Deléham, Nov 30 2007
G.f.: 1/(1-3*x-x^2/(1-4*x-x^2/(1-4*x-x^2/(1-4*x-x^2/(1-... (continued fraction). - Paul Barry, Jul 02 2009
a(n) = Sum_{0<=k<=n} A052179(n,k)*(-1)^k. - Philippe Deléham, Nov 28 2009
From Gary W. Adamson, Jul 21 2011: (Start)
a(n) = the upper left term in M^n, M = an infinite square production matrix as follows:
3, 1, 0, 0, ...
1, 3, 1, 0, ...
1, 1, 3, 1, ...
1, 1, 1, 3, ...
... (End)
a(n) ~ 2^(n-3/2)*3^(n+3/2)/(n^(3/2)*sqrt(Pi)). - Vaclav Kotesovec, Jun 29 2013
G.f. A(x) satisfies: A(x) = 1/(1 - 2*x) + x * A(x)^2. - Ilya Gutkovskiy, Jun 30 2020

Extensions

Name clarified using a comment of Vladeta Jovovic by Peter Bala, Jan 27 2020

A104455 Expansion of e.g.f. exp(5*x)*(BesselI(0,2*x) - BesselI(1,2*x)).

Original entry on oeis.org

1, 4, 17, 77, 371, 1890, 10095, 56040, 320795, 1881524, 11250827, 68330773, 420314629, 2612922694, 16389162537, 103587298965, 659071002195, 4217699773140, 27129590096595, 175303621195647, 1137400502295081, 7406899253418414, 48396105031873197, 317180187174490902, 2084542632685363221
Offset: 0

Author

Paul Barry, Mar 08 2005

Keywords

Comments

Third binomial transform of A000108. In general, the k-th binomial transform of A000108 will have g.f. (1-sqrt((1-(k+4)*x)/(1-k*x)))/(2*x), e.g.f. exp((k+2)*x)*(BesselI(0,2*x) - BesselI(1,2*x)) and a(n) = Sum_{i=0..n} C(n,i)*C(i)*k^(n-i).
Hankel transform of this sequence gives A000012 = [1,1,1,1,1,1,1,...]. - Philippe Deléham, Oct 24 2007
In general, the k-th binomial transform of A000108 can be generated from M^n, M = the production matrix of the form shown in the formula section, with a diagonal (k+1, k+1, k+1, ...). - Gary W. Adamson, Jul 21 2011
a(n) is the number of Schroeder paths of semilength n in which the H=(2,0) steps come in 3 colors and having no (2,0)-steps at levels 1,3,5,... - José Luis Ramírez Ramírez, Mar 30 2013
From Tom Copeland, Nov 08 2014: (Start)
This array is one of a family of Catalan arrays related by compositions of the special fractional linear (Möbius) transformations P(x,t) = x/(1-t*x); its inverse Pinv(x,t) = P(x,-t); and an o.g.f. of the Catalan numbers A000108, C(x) = [1-sqrt(1-4*x)]/2; and its inverse Cinv(x) = x*(1-x). (Cf A091867.)
O.g.f.: G(x) = C[P[P[P(x,-1),-1]]-1] = C[P(x,-3)] = [1-sqrt(1-4*x/(1-3*x)]/2 = x*A104455(x).
Ginv(x) = Pinv[Cinv(x),-3]= P[Cinv(x),3] = x*(1-x)/[1+3*x*(1-x)] = (x-x^2)/[1+3(x-x^2)] = x*A125145(-x). (Cf. A030528.) (End)

Crossrefs

Programs

  • Mathematica
    CoefficientList[Series[(1-Sqrt[(1-7*x)/(1-3*x)])/(2*x), {x, 0, 20}], x] (* Vaclav Kotesovec, Oct 17 2012 *)
  • PARI
    x='x+O('x^66); Vec((1-sqrt((1-7*x)/(1-3*x)))/(2*x)) \\ Joerg Arndt, Mar 31 2013

Formula

G.f.: (1-sqrt((1-7*x)/(1-3*x)))/(2*x).
a(n) = Sum_{k=0..n} C(n, k)*C(k)*3^(n-k).
a(n) = 3^n+Sum_{k=0..n-1} a(k)*a(n-1-k), a(0)=1. - Philippe Deléham, Dec 12 2009
From Gary W. Adamson, Jul 21 2011: (Start)
a(n) = upper left term of M^n, M = an infinite square production matrix as follows:
4, 1, 0, 0, ...
1, 4, 1, 0, ...
1, 1, 4, 1, ...
1, 1, 1, 4, ...
(End)
D-finite with recurrence: (n+1)*a(n) = 2*(5*n-1)*a(n-1) - 21*(n-1)*a(n-2). - Vaclav Kotesovec, Oct 17 2012
a(n) ~ 7^(n+3/2)/(8*sqrt(Pi)*n^(3/2)). - Vaclav Kotesovec, Oct 17 2012
G.f. A(x) satisfies: A(x) = 1/(1 - 3*x) + x * A(x)^2. - Ilya Gutkovskiy, Jun 30 2020
Showing 1-10 of 23 results. Next