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 21-30 of 34 results. Next

A027980 a(n) = Sum_{k=0..n-1} T(n,k)*T(n,2n-k), T given by A027960.

Original entry on oeis.org

1, 13, 48, 176, 580, 1844, 5667, 17047, 50404, 147090, 424686, 1215528, 3453733, 9752641, 27393240, 76587284, 213260152, 591707612, 1636514439, 4513276555, 12414985996, 34071252918, 93305816418, 255027755856, 695815086025, 1895348847349, 5154987856512, 14000952578552
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

  • GAP
    List([0..40], n-> (n+1)*Lucas(1,-1,2*n+2)[2] - Fibonacci(2*n+1) -(-1)^n); # G. C. Greubel, Oct 01 2019
  • Magma
    [(n+1)*Lucas(2*n+2) - Fibonacci(2*n+1) -(-1)^n: n in [0..40]]; // G. C. Greubel, Oct 01 2019
    
  • Maple
    with(combinat); f:=fibonacci; seq((n+1)*(f(2*n+3) + f(2*n+1)) - f(2*n+1) -(-1)^n, n=0..40); # G. C. Greubel, Oct 01 2019
  • Mathematica
    Table[(n+1)*LucasL[2*n+2] -Fibonacci[2*n+1] -(-1)^n, {n,0,40}] (* G. C. Greubel, Oct 01 2019 *)
  • PARI
    vector(41, n, f=fibonacci; n*(f(2*n+1) + f(2*n-1)) - f(2*n-1) + (-1)^n) \\ G. C. Greubel, Oct 01 2019
    
  • Sage
    [(n+1)*lucas_number2(2*n+2,1,-1) - fibonacci(2*n+1) -(-1)^n for n in (0..40)] # G. C. Greubel, Oct 01 2019
    

Formula

G.f.: (1 +8*x -12*x^2 +6*x^3)/ ((1+x)*(1-3*x+x^2)^2). - Colin Barker, Nov 25 2014
a(n) = (n+1)*Lucas(2*n) - Fibonacci(2*n+1) - (-1)^n. - G. C. Greubel, Oct 01 2019

Extensions

Terms a(24) onward added by G. C. Greubel, Oct 01 2019

A027982 a(n) = Sum_{k=0..2*n} (k+1)*T(n, 2*n-k), T given by A027960.

Original entry on oeis.org

1, 10, 38, 108, 270, 632, 1426, 3148, 6854, 14784, 31674, 67508, 143278, 303016, 638882, 1343388, 2817942, 5898128, 12320650, 25689988, 53477246, 111148920, 230686578, 478150508, 989855590, 2046820192, 4227858266, 8724152148, 17985175374, 37044092744
Offset: 0

Views

Author

Keywords

Crossrefs

Cf. A027960.

Programs

  • Magma
    A027982:= func< n | (2*n+11)*2^n -2*(3*n+5) >; // G. C. Greubel, Jun 07 2025
    
  • Mathematica
    LinearRecurrence[{6,-13,12,-4},{1,10,38,108},40] (* Harvey P. Dale, Oct 28 2020 *)
  • PARI
    Vec((1+4*x-9*x^2-2*x^3)/((1-x)^2*(1-2*x)^2) + O(x^100)) \\ Colin Barker, Nov 25 2014
    
  • Python
    def A027982(n): return (2*n+11)*2**n -2*(3*n+5) # G. C. Greubel, Jun 07 2025

Formula

From Colin Barker, Nov 25 2014: (Start)
a(n) = (-10 + 11*2^n + 2*(-3 + 2^n)*n).
a(n) = 6*a(n-1) - 13*a(n-2) + 12*a(n-3) - 4*a(n-4).
G.f.: (1 + 4*x - 9*x^2 - 2*x^3) / ((1-x)^2*(1-2*x)^2). (End)
E.g.f.: (11 + 4*x)*exp(2*x) - 2*(5 + 3*x)*exp(x). - G. C. Greubel, Jun 07 2025

Extensions

More terms from Colin Barker, Nov 25 2014

A027984 a(n) = Sum_{k=0..n} T(n, k)*T(n, n+k), T given by A027960.

Original entry on oeis.org

1, 6, 20, 58, 161, 436, 1165, 3088, 8146, 21426, 56255, 147538, 386681, 1013026, 2653240, 6948058, 18193141, 47634936, 124717445, 326526748, 854877926, 2238131506, 5859556195, 15340601158, 40162350961, 105146619486, 275277778940
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

  • Magma
    A027984:= func< n | (5*Fibonacci(2*n+2) +Lucas(2*n+1) -Lucas(n+3))/2 >;
    [A027984(n): n in [0..40]]; // G. C. Greubel, Jun 10 2025
    
  • Mathematica
    LinearRecurrence[{4,-3,-2,1}, {1,6,20,58}, 41] (* G. C. Greubel, Jun 10 2025 *)
  • PARI
    T027960(r,n) = if(r<0||n>2*r, return(0)); if(n==0||n==2*r, return(1)); if(n==1, 3, T027960(r-1, n-1)+T027960(r-1, n-2));
    a(n) = sum(k=0, n, T027960(n, k)*T027960(n, n+k)); \\ Michel Marcus, Feb 25 2015
    
  • SageMath
    L = lucas_number2
    def A027984(n): return (5*fibonacci(2*n+2) +L(2*n+1,1,-1) -L(n+3,1,-1))//2
    print([A027984(n) for n in range(41)]) # G. C. Greubel, Jun 10 2025

Formula

Conjectures from Colin Barker, Feb 25 2015: (Start)
a(n) = 4*a(n-1) - 3*a(n-2) - 2*a(n-3) + a(n-4).
G.f.: (1-x)*(1+x)*(1+2*x) / ((1-3*x+x^2)*(1-x-x^2)). (End)
a(n) = (1/2)*(5*A000045(2*n+2) + A000032(2*n+1) - A000032(n+3)). - G. C. Greubel, Jun 10 2025

A027985 a(n) = Sum_{k=0..2*n-1} T(n, k)*T(n, k+1), T given by A027960.

Original entry on oeis.org

6, 35, 144, 564, 2186, 8468, 32856, 127729, 497454, 1940525, 7580656, 29651385, 116111194, 455138499, 1785707924, 7011933544, 27554583254, 108355491404, 426368213364, 1678704356644, 6613026412314, 26064305550054, 102777232982624
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Magma
    f:= func< n,k | (&+[Binomial(2*n-k+j,j)*Lucas(2*(k-n-j)): j in [0..k-n-1]]) >;
    A027960:= func< n,k | k le n select Lucas(k+1) else Lucas(k+1) - f(n,k) >;
    A027985:= func< n | (&+[A027960(n,k)*A027960(n,k+1): k in [0..2*n-1]]) >;
    [A027985(n): n in [1..40]]; // G. C. Greubel, Jun 13 2025
    
  • Mathematica
    f[n_, k_]:= f[n,k]= Sum[Binomial[2*n-k+j,j]*LucasL[2*(k-n-j)], {j,0,k-n-1}];
    A027960[n_, k_]:= LucasL[k+1] - f[n,k]*Boole[k>n];
    A027985[n_]:= A027985[n]= Sum[A027960[n,k]*A027960[n,k+1], {k,0,2*n-1}];
    Table[A027985[n], {n,40}] (* G. C. Greubel, Jun 13 2025 *)
  • SageMath
    def L(n): return lucas_number2(n,1,-1)
    def f(n,k): return sum(binomial(2*n-k+j,j)*L(2*(k-n-j)) for j in range(k-n))
    def A027960(n,k): return L(k+1) - f(n,k)*int(k>n)
    def A027985(n): return sum(A027960(n,k)*A027960(n,k+1) for k in range(2*n))
    print([A027985(n) for n in range(1,41)]) # G. C. Greubel, Jun 13 2025

Formula

a(n) = A360278(n) - 1 + Sum_{k=n..2*n-1} A027960(n,k)*A027960(n,k+1), for n >= 1. - G. C. Greubel, Jun 13 2025

A027986 a(n) = Sum_{k=0..2*n-2} T(n, k)*T(n, k+2), T given by A027960.

Original entry on oeis.org

20, 100, 420, 1694, 6746, 26735, 105722, 417613, 1648692, 6507197, 25681362, 101359219, 400094756, 1579568360, 6237401648, 24635828774, 97327071806, 384596629610, 1520138671688, 6009885957464, 23765835521966, 94003008751940
Offset: 2

Views

Author

Keywords

Crossrefs

Cf. A027960.

Programs

  • Magma
    f:= func< n,k | (&+[Binomial(2*n-k+j,j)*Lucas(2*(k-n-j)): j in [0..k-n-1]]) >;
    A027960:= func< n,k | k le n select Lucas(k+1) else Lucas(k+1) - f(n,k) >;
    A027986:= func< n | (&+[A027960(n,k)*A027960(n,k+2): k in [0..2*n-2]]) >;
    [A027986(n): n in [2..40]]; // G. C. Greubel, Jun 14 2025
    
  • Mathematica
    f[n_, k_]:= f[n,k]= Sum[Binomial[2*n-k+j,j]*LucasL[2*(k-n-j)], {j,0,k-n-1}];
    A027960[n_, k_]:= LucasL[k+1] -f[n,k]*Boole[k>n];
    A027986[n_]:= A027986[n]= Sum[A027960[n,k]*A027960[n,k+2], {k,0,2*n-2}];
    Table[A027986[n], {n,2,40}] (* G. C. Greubel, Jun 14 2025 *)
  • SageMath
    @CachedFunction
    def T(n, k): # T = A027960
        if (k>2*n): return 0
        elif (kA027986(n): return sum(T(n,k)*T(n,k+2) for k in range(2*n-1))
    print([A027986(n) for n in range(2,41)]) # G. C. Greubel, Jun 14 2025

Formula

a(n) = A000032(2*n+1) - 7 + 3*(n mod 2) + Sum_{k=n-1..2*n-2} A027960(n, k)*A027960(n, k+2). - G. C. Greubel, Jun 14 2025

A027987 a(n) = Sum_{k=0..2*n-3} T(n, k)*T(n, k+3), T given by A027960.

Original entry on oeis.org

58, 272, 1154, 4757, 19378, 78422, 315994, 1269270, 5086294, 20345092, 81265106, 324240331, 1292556986, 5149091916, 20500830986, 81586994576, 324577199086, 1290904257426, 5133037194706, 20407032157936, 81119882902118
Offset: 3

Views

Author

Keywords

Crossrefs

Cf. A027960.

Programs

  • Magma
    f:= func< n,k | (&+[Binomial(2*n-k+j,j)*Lucas(2*(k-n-j)): j in [0..k-n-1]]) >;
    A027960:= func< n,k | k le n select Lucas(k+1) else Lucas(k+1) - f(n,k) >;
    A027987:= func< n | (&+[A027960(n,k)*A027960(n,k+3): k in [0..2*n-3]]) >;
    [A027987(n): n in [3..40]]; // G. C. Greubel, Jun 14 2025
    
  • Mathematica
    T[n_, k_]:= T[n,k]= If[k2*n, 0, T[n-1,k-1] + T[n-1,k-2]]];
    A027987[n_]:= A027987[n]= Sum[T[n,k]*T[n,k+3], {k,0,2*n-3}]; (* T = A027960 *)
    Table[A027987[n], {n,3,50}] (* G. C. Greubel, Jun 14 2025 *)
  • SageMath
    @CachedFunction
    def T(n, k): # T = A027960
        if (k>2*n): return 0
        elif (kA027987(n): return sum(T(n,k)*T(n,k+3) for k in range(2*n-2))
    print([A027987(n) for n in range(2,41)]) # G. C. Greubel, Jun 14 2025

Formula

a(n) = A000032(n)^2 - 9 + Sum_{k=n-2..2*n-3} A027960(n,k)*A027960(n,k+3). - G. C. Greubel, Jun 14 2025

A000204 Lucas numbers (beginning with 1): L(n) = L(n-1) + L(n-2) with L(1) = 1, L(2) = 3.

Original entry on oeis.org

1, 3, 4, 7, 11, 18, 29, 47, 76, 123, 199, 322, 521, 843, 1364, 2207, 3571, 5778, 9349, 15127, 24476, 39603, 64079, 103682, 167761, 271443, 439204, 710647, 1149851, 1860498, 3010349, 4870847, 7881196, 12752043, 20633239, 33385282, 54018521, 87403803, 141422324
Offset: 1

Views

Author

Keywords

Comments

See A000032 for the version beginning 2, 1, 3, 4, 7, ...
Also called Schoute's accessory series (see Jean, 1984). - N. J. A. Sloane, Jun 08 2011
L(n) is the number of matchings in a cycle on n vertices: L(4)=7 because the matchings in a square with edges a, b, c, d (labeled consecutively) are the empty set, a, b, c, d, ac and bd. - Emeric Deutsch, Jun 18 2001
This comment covers a family of sequences which satisfy a recurrence of the form a(n) = a(n-1) + a(n-m), with a(n) = 1 for n = 1..m - 1, a(m) = m + 1. The generating function is (x + m*x^m)/(1 - x - x^m). Also a(n) = 1 + n*Sum_{i=1..n/m} binomial(n - 1 - (m - 1)*i, i - 1)/i. This gives the number of ways to cover (without overlapping) a ring lattice (or necklace) of n sites with molecules that are m sites wide. Special cases: m = 2: A000204, m = 3: A001609, m = 4: A014097, m = 5: A058368, m = 6: A058367, m = 7: A058366, m = 8: A058365, m = 9: A058364.
L(n) is the number of points of period n in the golden mean shift. The number of orbits of length n in the golden mean shift is given by the n-th term of the sequence A006206. - Thomas Ward, Mar 13 2001
Row sums of A029635 are 1, 1, 3, 4, 7, ... - Paul Barry, Jan 30 2005
a(n) counts circular n-bit strings with no repeated 1's. E.g., for a(5): 00000 00001 00010 00100 00101 01000 01001 01010 10000 10010 10100. Note #{0...} = fib(n+1), #{1...} = fib(n-1), #{000..., 001..., 100...} = a(n-1), #{010..., 101...} = a(n-2). - Len Smiley, Oct 14 2001
Row sums of the triangle in A182579. - Reinhard Zumkeller, May 07 2012
If p is prime then L(p) == 1 (mod p). L(2^k) == -1 (mod 2^(k+1)) for k = 0,1,2,... - Thomas Ordowski, Sep 25 2013
Satisfies Benford's law [Brown-Duncan, 1970; Berger-Hill, 2017]. - N. J. A. Sloane, Feb 08 2017

Examples

			G.f. = x + 3*x^2 + 4*x^3 + 7*x^4 + 11*x^5 + 18*x^6 + 29*x^7 + 47*x^8 + ...
		

References

  • P. Bachmann, Niedere Zahlentheorie (1902, 1910), reprinted Chelsea, NY, 1968, vol. 2, p. 69.
  • L. Comtet, Advanced Combinatorics, Reidel, 1974, p. 46.
  • Leonhard Euler, Introductio in analysin infinitorum (1748), sections 216 and 229.
  • G. Everest, A. van der Poorten, I. Shparlinski and T. Ward, Recurrence Sequences, Amer. Math. Soc., 2003; see esp. p. 255.
  • G. H. Hardy and E. M. Wright, An Introduction to the Theory of Numbers. 3rd ed., Oxford Univ. Press, 1954, p. 148.
  • Silvia Heubach and Toufik Mansour, Combinatorics of Compositions and Words, CRC Press, 2010.
  • V. E. Hoggatt, Jr., Fibonacci and Lucas Numbers. Houghton, Boston, MA, 1969.
  • R. V. Jean, Mathematical Approach to Pattern and Form in Plant Growth, Wiley, 1984. See p. 5. - N. J. A. Sloane, Jun 08 2011
  • Thomas Koshy, "Fibonacci and Lucas Numbers with Applications", John Wiley and Sons, 2001.
  • 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).
  • S. Vajda, Fibonacci and Lucas numbers and the Golden Section, Ellis Horwood Ltd., Chichester, 1989.

Crossrefs

Programs

  • Haskell
    a000204 n = a000204_list !! n
    a000204_list = 1 : 3 : zipWith (+) a000204_list (tail a000204_list)
    -- Reinhard Zumkeller, Dec 18 2011
    
  • Magma
    [Lucas(n): n in [1..30]]; // G. C. Greubel, Dec 17 2017
    
  • Maple
    A000204 := proc(n) option remember; if n <=2 then 2*n-1; else procname(n-1)+procname(n-2); fi; end;
    with(combinat): A000204 := n->fibonacci(n+1)+fibonacci(n-1);
    # alternative Maple program:
    L:= n-> (<<1|1>, <1|0>>^n. <<2, -1>>)[1, 1]:
    seq(L(n), n=1..50);  # Alois P. Heinz, Jul 25 2008
    # Alternative:
    a := n -> `if`(n=1, 1, `if`(n=2, 3, hypergeom([(1-n)/2, -n/2], [1-n], -4))):
    seq(simplify(a(n)), n=1..39); # Peter Luschny, Sep 03 2019
  • Mathematica
    c = (1 + Sqrt[5])/2; Table[Expand[c^n + (1 - c)^n], {n, 30}] (* Artur Jasinski, Oct 05 2008 *)
    Table[LucasL[n, 1], {n, 36}] (* Zerinvary Lajos, Jul 09 2009 *)
    LinearRecurrence[{1, 1},{1, 3}, 50] (* Sture Sjöstedt, Nov 28 2011 *)
    lukeNum[n_] := If[n < 1, 0, LucasL[n]]; (* Michael Somos, May 18 2015 *)
    lukeNum[n_] := SeriesCoefficient[x D[Log[1 / (1 - x - x^2)], x], {x, 0, n}]; (* Michael Somos, May 18 2015 *)
  • PARI
    A000204(n)=fibonacci(n+1)+fibonacci(n-1) \\ Michael B. Porter, Nov 05 2009
    
  • Python
    from functools import cache
    @cache
    def a(n): return [1, 3][n-1] if n < 3 else a(n-1) + a(n-2)
    print([a(n) for n in range(1, 41)]) # Michael S. Branicky, Nov 13 2022
    
  • Python
    [(i:=-1)+(j:=2)] + [(j:=i+j)+(i:=j-i) for  in range(100)] # _Jwalin Bhatt, Apr 02 2025
  • Sage
    def A000204():
        x, y = 1, 2
        while true:
           yield x
           x, y = x + y, x
    a = A000204(); print([next(a) for i in range(39)])  # Peter Luschny, Dec 17 2015
    
  • Scala
    def lucas(n: BigInt): BigInt = {
      val zero = BigInt(0)
      def fibTail(n: BigInt, a: BigInt, b: BigInt): BigInt = n match {
        case `zero` => a
        case _ => fibTail(n - 1, b, a + b)
      }
      fibTail(n, 2, 1)
    }
    (1 to 50).map(lucas()) // _Alonso del Arte, Oct 20 2019
    

Formula

Expansion of x(1 + 2x)/(1 - x - x^2). - Simon Plouffe, dissertation 1992; multiplied by x. - R. J. Mathar, Nov 14 2007
a(n) = A000045(2n)/A000045(n). - Benoit Cloitre, Jan 05 2003
For n > 1, L(n) = F(n + 2) - F(n - 2), where F(n) is the n-th Fibonacci number (A000045). - Gerald McGarvey, Jul 10 2004
a(n+1) = 4*A054886(n+3) - A022388(n) - 2*A022120(n+1) (a conjecture; note that the above sequences have different offsets). - Creighton Dement, Nov 27 2004
a(n) = Sum_{k=0..floor((n+1)/2)} (n+1)*binomial(n - k + 1, k)/(n - k + 1). - Paul Barry, Jan 30 2005
L(n) = A000045(n+3) - 2*A000045(n). - Creighton Dement, Oct 07 2005
L(n) = A000045(n+1) + A000045(n-1). - John Blythe Dobson, Sep 29 2007
a(n) = 2*Fibonacci(n-1) + Fibonacci(n), n >= 1. - Zerinvary Lajos, Oct 05 2007
L(n) is the term (1, 1) in the 1 X 2 matrix [2, -1].[1, 1; 1, 0]^n. - Alois P. Heinz, Jul 25 2008
a(n) = phi^n + (1 - phi)^n = phi^n + (-phi)^(-n) = ((1 + sqrt(5))^n + (1 - sqrt(5))^n)/(2^n) where phi is the golden ratio (A001622). - Artur Jasinski, Oct 05 2008
a(n) = A014217(n+1) - A014217(n-1). See A153263. - Paul Curtz, Dec 22 2008
a(n) = ((1 + sqrt(5))^n - (1 - sqrt(5))^n)/(2^n*sqrt(5)) + ((1 + sqrt(5))^(n - 1) - (1 - sqrt(5))^(n - 1))/(2^(n - 2)*sqrt(5)). - Al Hakanson (hawkuu(AT)gmail.com), Jan 12 2009, Jan 14 2009
From Hieronymus Fischer, Oct 20 2010 (Start)
Continued fraction for n odd: [L(n); L(n), L(n), ...] = L(n) + fract(Fib(n) * phi).
Continued fraction for n even: [L(n); -L(n), L(n), -L(n), L(n), ...] = L(n) - 1 + fract(Fib(n)*phi). Also: [L(n) - 2; 1, L(n) - 2, 1, L(n) - 2, ...] = L(n) - 2 + fract(Fib(n)*phi). (End)
INVERT transform of (1, 2, -1, -2, 1, 2, ...). - Gary W. Adamson, Mar 07 2012
L(2n - 1) = floor(phi^(2n - 1)); L(2n) = ceiling(phi^(2n)). - Thomas Ordowski, Jun 15 2012
a(n) = hypergeom([(1 - n)/2, -n/2], [1 - n], -4) for n >= 3. - Peter Luschny, Sep 03 2019
E.g.f.: 2*(exp(x/2)*cosh(sqrt(5)*x/2) - 1). - Stefano Spezia, Jul 26 2022

Extensions

Additional comments from Yong Kong (ykong(AT)curagen.com), Dec 16 2000
Plouffe Maple line edited by N. J. A. Sloane, May 13 2008

A036563 a(n) = 2^n - 3.

Original entry on oeis.org

-2, -1, 1, 5, 13, 29, 61, 125, 253, 509, 1021, 2045, 4093, 8189, 16381, 32765, 65533, 131069, 262141, 524285, 1048573, 2097149, 4194301, 8388605, 16777213, 33554429, 67108861, 134217725, 268435453, 536870909, 1073741821, 2147483645
Offset: 0

Views

Author

Keywords

Comments

a(n+1) is the n-th number with exactly n 1's in binary representation. - Reinhard Zumkeller, Mar 06 2003
Berstein and Onn: "For every m = 3k+1, the Graver complexity of the vertex-edge incidence matrix of the complete bipirtite graph K(3,m) satisfies g(m) >= 2^(k+2)-3." - Jonathan Vos Post, Sep 15 2007
Row sums of triangle A135857. - Gary W. Adamson, Dec 01 2007
a(n) = A164874(n-1,n-2) for n > 2. - Reinhard Zumkeller, Aug 29 2009
Starting (1, 5, 13, ...) = eigensequence of a triangle with A016777: (1, 4, 7, 10, ...) as the left border and the rest 1's. - Gary W. Adamson, Jul 24 2010
An elephant sequence, see A175655. For the central square just one A[5] vector, with decimal value 186, leads to this sequence (n >= 2). For the corner squares this vector leads to the companion sequence A123203. - Johannes W. Meijer, Aug 15 2010
First differences of A095264: A095264(n+1) - A095264(n) = a(n+2). - J. M. Bergot, May 13 2013
a(n+2) is given by the sum of n-th row of triangle of powers of 2: 1; 2 1 2; 4 2 1 2 4; 8 4 2 1 2 4 8; ... - Philippe Deléham, Feb 24 2014
Also, the decimal representation of the x-axis, from the left edge to the origin, of the n-th stage of growth of the two-dimensional cellular automaton defined by "Rule 643", based on the 5-celled von Neumann neighborhood, initialized with a single black (ON) cell at stage zero. See A283508. - Robert Price, Mar 09 2017
a(n+3) is the value of the Ackermann function A(3,n) or ack(3,n). - Olivier Gérard, May 11 2018

Examples

			a(2) = 1;
a(3) = 2 + 1 + 2 = 5;
a(4) = 4 + 2 + 1 + 2 + 4 = 13;
a(5) = 8 + 4 + 2 + 1 + 2 + 4 + 8 = 29; etc. - _Philippe Deléham_, Feb 24 2014
		

Crossrefs

Row sums of triangular array A027960. A column of A119725.

Programs

Formula

a(n) = 2*a(n-1) + 3.
The sequence 1, 5, 13, ... has a(n) = 4*2^n-3. These are the partial sums of A151821. - Paul Barry, Aug 25 2003
a(n) = A118654(n-3, 6), for n > 2. - N. J. A. Sloane, Sep 29 2006
Row sums of triangle A130459 starting (1, 5, 13, 29, 61, ...). - Gary W. Adamson, May 26 2007
Row sums of triangle A131112. - Gary W. Adamson, Jun 15 2007
Binomial transform of [1, 4, 4, 4, ...] = (1, 5, 13, 29, 61, ...). - Gary W. Adamson, Sep 20 2007
a(n) = 2*StirlingS2(n,2) - 1, for n > 0. - Ross La Haye, Jul 05 2008
a(n) = A000079(n) - 3. - Omar E. Pol, Dec 21 2008
From Mohammad K. Azarian, Jan 14 2009: (Start)
G.f.: 1/(1-2*x) - 3/(1-x).
E.g.f.: exp(2*x) - 3*exp(x). (End)
For n >= 3, a(n) = 2<+>n, where operation <+> is defined in A206853. - Vladimir Shevelev, Feb 17 2012
a(n) = 3*a(n-1) - 2*a(n-2) for n > 1, a(0)=-2, a(1)=-1. - Philippe Deléham, Dec 23 2013
Sum_{n>=1} 1/a(n) = A331372. - Amiram Eldar, Nov 18 2020

A027961 a(n) = Lucas(n+2) - 3.

Original entry on oeis.org

1, 4, 8, 15, 26, 44, 73, 120, 196, 319, 518, 840, 1361, 2204, 3568, 5775, 9346, 15124, 24473, 39600, 64076, 103679, 167758, 271440, 439201, 710644, 1149848, 1860495, 3010346, 4870844, 7881193, 12752040, 20633236, 33385279, 54018518
Offset: 1

Views

Author

Keywords

Comments

Sum of the first n Lucas numbers, that is, A000204(1) to A000204(n). - T. D. Noe, Oct 10 2005

Crossrefs

T(n, n+1), T given by A027960.

Programs

  • GAP
    List([1..40], n-> Lucas(1, -1, n+2)[2] -3 ); # G. C. Greubel, Jun 01 2019
  • Magma
    [Lucas(n+2)-3: n in [1..40]]; // Vincenzo Librandi, Apr 16 2011
    
  • Maple
    a[0]:=0:a[1]:=1:for n from 2 to 50 do a[n]:=a[n-1]+a[n-2]+3 od: seq(a[n],n=1..40); # Miklos Kristof, Mar 09 2005
    with(combinat): seq(fibonacci(n)+fibonacci(n+2)-3, n=2..40); # Zerinvary Lajos, Jan 31 2008
    g:=(1+z^2)/(1-z-z^2): gser:=series(g, z=0, 43): seq(coeff(gser, z, n)-3, n=3..40); # Zerinvary Lajos, Jan 09 2009
  • Mathematica
    LucasL[Range[3, 40]] - 3 (* Alonso del Arte, Sep 26 2013 *)
  • PARI
    vector(40, n, fibonacci(n+3) +fibonacci(n+1) -3) \\ G. C. Greubel, Dec 18 2017
    
  • PARI
    first(n) = Vec(x*(1+2*x)/((1-x)*(1-x-x^2)) + O(x^(n+1))) \\ Iain Fox, Dec 19 2017
    
  • Sage
    [lucas_number2(n+2, 1, -1) -3 for n in (1..40)] # G. C. Greubel, Jun 01 2019
    

Formula

a(0) = 0, a(1) = 1, a(n) = a(n-1) + a(n-2) + 3.
a(n) = A000204(n+2) - 3 = A000045(2n+4)/A000045(n+2) - 3. - Benoit Cloitre, Jan 05 2003
G.f.: x*(1+2*x)/((1-x)*(1-x-x^2)). Differences of A023537. - Ralf Stephan, Feb 07 2004
a(n) = A101220(3, 1, n). - Ross La Haye, Jan 28 2005
a(n) = F(n) + F(n+2) - 3, n >= 2, where F(n) is the n-th Fibonacci number. - Zerinvary Lajos, Jan 31 2008
a(n) = Sum_{k=1..n} ((-1/phi)^k + (phi)^k) where phi = 1/2+1/2*sqrt(5). - Dimitri Papadopoulos, Jan 07 2016
a(n) = 2*a(n-1)-a(n-3) for n>3. - Wesley Ivan Hurt, Jan 07 2016

A023537 a(n) = Lucas(n+4) - (3*n+7).

Original entry on oeis.org

1, 5, 13, 28, 54, 98, 171, 291, 487, 806, 1324, 2164, 3525, 5729, 9297, 15072, 24418, 39542, 64015, 103615, 167691, 271370, 439128, 710568, 1149769, 1860413, 3010261, 4870756, 7881102, 12751946, 20633139, 33385179, 54018415, 87403694, 141422212, 228826012
Offset: 1

Views

Author

Keywords

Comments

Define a triangle with T(n, 1) = n*(n-1) + 1 and T(n, n) = n for n = 1, 2, 3, ... The interior terms T(r, c) = T(r - 1, c) + T(r - 2, c - 1); this triangle will give the sum of terms in row(n) = a(n). The rows begin 1; 3 2; 7 3 3; 13 6 5 4; 21 13 8 7 5 having row(n) sums 1, 5, 13, 28, 54. - J. M. Bergot, Feb 17 2013

References

  • Wolfdieter Lang in "Applications of Fibonacci Numbers", Vol. 7, p. 235, eds.: G. E. Bergum et al, Kluwer, 1998.

Crossrefs

Programs

  • GAP
    List([1..40], n-> Lucas(1, -1, n+4)[2] -(3*n+7) ); # G. C. Greubel, Jun 01 2019
    
  • Magma
    [Lucas(n+4) -(3*n+7): n in [1..40]]; // Vincenzo Librandi, Apr 16 2011
    
  • Maple
    with(combinat): L:=n->fibonacci(n+2)-fibonacci(n-2): seq(L(n),n=0..12): seq(L(n+4)-3*n-7,n=1..40); # Emeric Deutsch, Aug 08 2005
  • Mathematica
    Table[LucasL[n + 4] - (3n + 7), {n, 40}] (* Alonso del Arte, Feb 17 2013 *)
  • PARI
    Vec(x*(1+2*x)/((1-x-x^2)*(1-x)^2) + O(x^40)) \\ Colin Barker, Mar 11 2017
    
  • Sage
    [lucas_number2(n+4, 1, -1) -(3*n+7) for n in (1..40)] # G. C. Greubel, Jun 01 2019
    
  • Scala
    def lucas(n: BigInt): BigInt = {
      val zero = BigInt(0)
      def fibTail(n: BigInt, a: BigInt, b: BigInt): BigInt = n match {
        case `zero` => a
        case _ => fibTail(n - 1, b, a + b)
      }
      fibTail(n, 2, 1)
    }
    (1 to 40).map(n => lucas(n + 4) - (3 * n + 7)) // Alonso del Arte, Oct 20 2019

Formula

Convolution of natural numbers with Lucas numbers A000204.
a(n) = A027960(n+1, n+3).
From Wolfdieter Lang: (Start)
a(n) = 7*(F(n+1) - 1) + 4*F(n) - 3*n; F(n) = A000045 (Fibonacci);
G.f.: x*(1 + 2*x)/((1-x)^2*(1 - x - x^2)). (End)
a(n) - a(n-1) = A101220(3, 1, n). - Ross La Haye, May 31 2006
a(n+1) - a(n) = A027961(n+1). - R. J. Mathar, Feb 21 2013
From Colin Barker, Mar 11 2017: (Start)
a(n) = -4 + (2^(-1 - n)*((1 - sqrt(5))^n*(-15 + 7*sqrt(5)) + (1 + sqrt(5))^n*(15 + 7*sqrt(5)))) / sqrt(5) - 3*(1+n).
a(n) = 3*a(n-1) - 2*a(n-2) - a(n-3) + a(n-4) for n > 4. (End)
From G. C. Greubel, Jun 08 2025: (Start)
a(n) = a(n-1) + a(n-2) + 3*n - 2.
a(n) = Sum_{i=0..n-1} Sum_{j=0..i} A027960(i,j).
E.g.f.: exp(x/2)*( 7*cosh(sqrt(5)*x/2) + 3*sqrt(5)*sinh(sqrt(5)*x/2) ) - (3*x+7)*exp(x). (End)

Extensions

More terms from Emeric Deutsch, Aug 08 2005
Previous Showing 21-30 of 34 results. Next