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

A048746 Partial sums of A048655.

Original entry on oeis.org

1, 6, 17, 44, 109, 266, 645, 1560, 3769, 9102, 21977, 53060, 128101, 309266, 746637, 1802544, 4351729, 10506006, 25363745, 61233500, 147830749, 356895002, 861620757, 2080136520, 5021893801, 12123924126, 29269742057, 70663408244, 170596558549, 411856525346, 994309609245
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    Accumulate[LinearRecurrence[{2,1},{1,5},30]] (* Harvey P. Dale, May 23 2012 *)
    LinearRecurrence[{3, -1, -1},{1, 6, 17},26] (* Ray Chandler, Aug 03 2015 *)
    Table[2 Fibonacci[n, 2] + 3 Fibonacci[n + 1, 2] - 2, {n, 0, 10}] (* Vladimir Reshetnikov, Sep 27 2016 *)

Formula

a(n) = 2*a(n-1) + a(n-2) + 4; a(0)=1, a(1)=6.
a(n) = ((6 + 5*sqrt(2))*(1 + sqrt(2))^n + (6 - 5*sqrt(2))*(1 - sqrt(2))^n)/4 - 2. [Corrected by Stefano Spezia, May 26 2024]
From Colin Barker, Sep 19 2012: (Start)
a(n) = 3*a(n-1) - a(n-2) - a(n-3).
G.f.: (1+3*x)/((1-x)*(1-2*x-x^2)). (End)
a(n) = 2*Pell(n) + 3*Pell(n+1) - 2, where Pell = A000129. - Vladimir Reshetnikov, Sep 27 2016
E.g.f.: exp(x)*(6*cosh(sqrt(2)*x) + 5*sqrt(2)*sinh(sqrt(2)*x) - 4)/2. - Stefano Spezia, May 26 2024

Extensions

Corrected and extended by T. D. Noe, Nov 07 2006

A048739 Expansion of 1/((1 - x)*(1 - 2*x - x^2)).

Original entry on oeis.org

1, 3, 8, 20, 49, 119, 288, 696, 1681, 4059, 9800, 23660, 57121, 137903, 332928, 803760, 1940449, 4684659, 11309768, 27304196, 65918161, 159140519, 384199200, 927538920, 2239277041, 5406093003, 13051463048, 31509019100, 76069501249
Offset: 0

Views

Author

Keywords

Comments

Partial sums of Pell numbers A000129.
W(n){1,3;2,-1,1} = Sum_{i=1..n} W(i){1,2;2,-1,0}, where W(n){a,b; p,q,r} implies x(n) = p*x(n-1) - q*x(n-2) + r; x(0)=a, x(1)=b.
Number of 2 X (n+1) binary arrays with path of adjacent 1's from upper left to lower right corner. - R. H. Hardin, Mar 16 2002
Binomial transform of A029744. - Paul Barry, Apr 23 2004
Number of (s(0), s(1), ..., s(n+2)) such that 0 < s(i) < 4 and |s(i) - s(i-1)| <= 1 for i = 1,2,...,n+2, s(0) = 1, s(n+2) = 3. - Herbert Kociemba, Jun 16 2004
Equals row sums of triangle A153346. - Gary W. Adamson, Dec 24 2008
Equals the sum of the terms of the antidiagonals of A142978. - J. M. Bergot, Nov 13 2012
a(p-2) == 0 mod p where p is an odd prime, see A270342. - Altug Alkan, Mar 15 2016
Also, the lexicographically earliest sequence of positive integers such that for n > 3, {sqrt(2)*a(n)} is located strictly between {sqrt(2)*a(n-1)} and {sqrt(2)*a(n-2)} where {} denotes the fractional part. - Ivan Neretin, May 02 2017
a(n+1) is the number of weak orderings on {1,...,n} that are weakly single-peaked w.r.t. the total ordering 1 < ... < n. - J. Devillet, Oct 06 2017

References

  • Allombert, Bill, Nicolas Brisebarre, and Alain Lasjaunias. "On a two-valued sequence and related continued fractions in power series fields." The Ramanujan Journal 45.3 (2018): 859-871. See Theorem 3, d_{4n+3}.

Crossrefs

First row of table A083087.
With a different offset, a(4n)=A008843(n), a(4n-2)=8*A001110(n), a(2n-1)=A001652(n).

Programs

  • Maple
    a:=n->sum(fibonacci(i,2), i=0..n): seq(a(n), n=1..29); # Zerinvary Lajos, Mar 20 2008
  • Mathematica
    Join[{a=1,b=3},Table[c=2*b+a+1;a=b;b=c,{n,60}]] (* Vladimir Joseph Stephan Orlovsky, Feb 01 2011 *)
    CoefficientList[Series[1/(1-3x+x^2+x^3),{x,0,30}],x] (* or *) LinearRecurrence[{3,-1,-1},{1,3,8},30] (* Harvey P. Dale, Jun 13 2011 *)
  • PARI
    a(n)=local(w=quadgen(8));-1/2+(3/4+1/2*w)*(1+w)^n+(3/4-1/2*w)*(1-w)^n
    
  • PARI
    vector(100, n, n--; floor((1+sqrt(2))^(n+2)/4)) \\ Altug Alkan, Oct 07 2015
    
  • PARI
    Vec(1/((1-x)*(1-2*x-x^2)) + O(x^40)) \\ Michel Marcus, May 06 2017

Formula

a(n) = 2*a(n-1) + a(n-2) + 1 with n > 1, a(0)=1, a(1)=3.
a(n) = ((2 + (3*sqrt(2))/2)*(1 + sqrt(2))^n - (2 - (3*sqrt(2))/2)*(1 - sqrt(2))^n )/(2*sqrt(2)) - 1/2.
a(0)=1, a(n+1) = ceiling(x*a(n)) for n > 0, where x = 1+sqrt(2). - Paul D. Hanna, Apr 22 2003
a(n) = 3*a(n-1) - a(n-2) - a(n-3). With two leading zeros, e.g.f. is exp(x)(cosh(sqrt(2)x)-1)/2. a(n) = Sum_{k=0..floor((n+2)/2)} binomial(n+2, 2k+2)2^k. - Paul Barry, Aug 16 2003
-a(-3-n) = A077921(n). - N. J. A. Sloane, Sep 13 2003
E.g.f.: exp(x)(cosh(x/sqrt(2)) + sqrt(2)sinh(x/sqrt(2)))^2. - N. J. A. Sloane, Sep 13 2003
a(n) = floor((1+sqrt(2))^(n+2)/4). - Bruno Berselli, Feb 06 2013
a(n) = (((1-sqrt(2))^(n+2) + (1+sqrt(2))^(n+2) - 2) / 4). - Altug Alkan, Mar 16 2016
2*a(n) = A001333(n+2)-1. - R. J. Mathar, Oct 11 2017
a(n) = Sum_{k=0..n} binomial(n+1,k+1)*2^floor(k/2). - Tony Foster III, Oct 12 2017

Extensions

Corrected and extended by Larry Reeves (larryr(AT)acm.org), Jun 11 2002

A048654 a(n) = 2*a(n-1) + a(n-2); a(0)=1, a(1)=4.

Original entry on oeis.org

1, 4, 9, 22, 53, 128, 309, 746, 1801, 4348, 10497, 25342, 61181, 147704, 356589, 860882, 2078353, 5017588, 12113529, 29244646, 70602821, 170450288, 411503397, 993457082, 2398417561, 5790292204
Offset: 0

Views

Author

Keywords

Comments

Generalized Pellian with second term equal to 4.
The generalized Pellian with second term equal to s has the terms a(n) = A000129(n)*s + A000129(n-1). The generating function is -(1+s*x-2*x)/(-1+2*x+x^2). - R. J. Mathar, Nov 22 2007

Crossrefs

Programs

  • Haskell
    a048654 n = a048654_list !! n
    a048654_list =
       1 : 4 : zipWith (+) a048654_list (map (* 2) $ tail a048654_list)
    -- Reinhard Zumkeller, Aug 01 2011
    
  • Magma
    R:=PowerSeriesRing(Integers(), 40); Coefficients(R!((1+2*x)/(1-2*x-x^2))); // G. C. Greubel, Jul 26 2018
    
  • Mathematica
    LinearRecurrence[{2,1},{1,4},30] (* Harvey P. Dale, Jul 27 2011 *)
  • Maxima
    a[0]:1$
    a[1]:4$
    a[n]:=2*a[n-1]+a[n-2]$
    A048654(n):=a[n]$
    makelist(A048654(n),n,0,30); /* Martin Ettl, Nov 03 2012 */
    
  • PARI
    a(n)=(([0, 1; 1,2]^n)*[1,4]~)[1] \\ Charles R Greathouse IV, May 18 2015
    
  • SageMath
    [lucas_number1(n+1,2,-1) +2*lucas_number1(n,2,-1) for n in (0..40)] # G. C. Greubel, Aug 09 2022

Formula

a(n) = ((3+sqrt(2))*(1+sqrt(2))^n - (3-sqrt(2))*(1-sqrt(2))^n)/2*sqrt(2).
a(n) = 2*A000129(n+2) - 3*A000129(n+1). - Creighton Dement, Oct 27 2004
G.f.: (1+2*x)/(1-2*x-x^2). - Philippe Deléham, Nov 03 2008
a(n) = binomial transform of 1, 3, 2, 6, 4, 12, ... . - Al Hakanson (hawkuu(AT)gmail.com), Aug 08 2009
E.g.f.: exp(x)*cosh(sqrt(2)*x) + 3*exp(x)*sinh(sqrt(2)*x)/sqrt(2). - Vaclav Kotesovec, Feb 16 2015
a(n) is the denominator of the continued fraction [4, 2, ..., 2, 4] with n-1 2's in the middle. For the numerators, see A221174. - Greg Dresden and Tongjia Rao, Sep 02 2021
a(n) = A001333(n) + A000129(n). - G. C. Greubel, Aug 09 2022

A005409 Number of polynomials of height n: a(1)=1, a(2)=1, a(3)=4, a(n) = 2*a(n-1) + a(n-2) + 2 for n >= 4.

Original entry on oeis.org

1, 1, 4, 11, 28, 69, 168, 407, 984, 2377, 5740, 13859, 33460, 80781, 195024, 470831, 1136688, 2744209, 6625108, 15994427, 38613964, 93222357, 225058680, 543339719, 1311738120, 3166815961, 7645370044, 18457556051, 44560482148, 107578520349, 259717522848
Offset: 1

Views

Author

N. J. A. Sloane, S. M. Diano

Keywords

Comments

Starting with n=1, the sum of the antidiagonals of the array in a comment from Cloitre regarding A002002. - Gerald McGarvey, Aug 12 2004
Cumulative sum of A001333. - Sture Sjöstedt, Nov 15 2011
a(n) is the number of self-avoiding walks on a 3 rows X n columns grid of squares, starting top-left, ending bottom-left, using moves of R(ight), L(eft), U(p), D(own). E.g., for 3 X 1 there is just the path (D,D), and a(1) = 1. For 3 X 2, there are 4 paths (D,D) (D,R,D,L) (R,D,D,L) and (R,D,L,D) and a(2) = 4. - Toby Gottfried, Mar 04 2013
Define a triangle to have T(n,1) = n*(n-1)+1 and T(n,n) = n; the other terms T(r,c) = T(r-1,c) + T(r-1,c-1) + T(r-2,c-1). The sum of the terms in row(n+1) minus those in row(n) = a(n+2). - J. M. Bergot, Apr 30 2013
Since the terms of the sequence are all finite, it can be used in enumerating all polynomials with integer coefficients. Since each polynomial has only a finite number of roots, this enumeration can be used in turn to enumerate the algebraic numbers. Cantor uses this to derive the existence of transcendental numbers as a corollary of his stronger result that no enumerable sequence of real numbers can include all of them. - Morgan L. Owens, May 15 2022
For n > 1, also the rank of the (n-1)-Pell graph. - Eric W. Weisstein, Aug 01 2023

References

  • R. Courant and H. Robbins, What is Mathematics?, Oxford Univ. Press, 1941, p. 103.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Cf. A214931 (walks on grids with 4 rows), A006189 (grids with 3 columns).
Cf. A216211 (grids with 4 columns).

Programs

  • Haskell
    a005409 n = a005409_list !! (n-1)
    a005409_list = 1 : scanl1 (+) (tail a001333_list)
    -- Reinhard Zumkeller, Jul 08 2012
    
  • Magma
    [1] cat [n le 2 select n^2 else 2*Self(n-1) +Self(n-2) +2: n in [1..30]]; // G. C. Greubel, Apr 22 2021
    
  • Mathematica
    Join[{1}, RecurrenceTable[{a[1] == 1, a[2] == 4, a[n] == 2 a[n - 1] + a[n - 2] + 2}, a[n], {n, 30}]] (* Harvey P. Dale, Jul 27 2011 *)
    Join[{1}, CoefficientList[Series[(x + 1)/((x - 1) (x^2 + 2 x - 1)), {x, 0, 40}], x]] (* Vladimir Joseph Stephan Orlovsky, Jan 21 2012 *)
    Join[{1}, Fibonacci[Range[2, 35], 2] -1] (* G. C. Greubel, Apr 22 2021 *)
    Join[{1}, LinearRecurrence[{3, -1, -1}, {1, 4, 11}, 20]] (* Eric W. Weisstein, Aug 01 2023 *)
  • PARI
    a(n)=polcoeff(1+x*(1+x)/(1-3*x+x^2+x^3)+x*O(x^n),n) \\ Paul D. Hanna
    
  • Sage
    [1]+[lucas_number1(n,2,-1) -1 for n in (2..35)] # G. C. Greubel, Apr 22 2021

Formula

a(n) = A000129(n) - 1, n > 1.
a(n) = ((1+sqrt(2))^n - (1-sqrt(2))^n)/(2*sqrt(2))-1 for n > 1, a(1)=1.
G.f.: 1 + x*(1+x)/( (1-x)*(1-2*x-x^2) ). - Simon Plouffe in his 1992 dissertation.
a(n) = 3*a(n-1) - a(n-2) - a(n-3). - Toby Gottfried, Mar 08 2013
(1, 4, 11, 28, ...) = (1, 2, 2, 2, ...) * the Pell sequence starting (1, 2, 5, 12, 29, ...); such that, for example: a(5) = (2, 2, 2, 1) dot (1, 2, 5, 12) = (2 + 4 + 10 + 12) = 48. - Gary W. Adamson May 21 2013
E.g.f.: 1 + exp(x)*(2*(cosh(sqrt(2)*x) - 1) + sqrt(2)*sinh(sqrt(2)*x))/2. - Stefano Spezia, Jun 26 2022

Extensions

Additional comments from Barry E. Williams

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

Original entry on oeis.org

-1, 2, 3, 8, 19, 46, 111, 268, 647, 1562, 3771, 9104, 21979, 53062, 128103, 309268, 746639, 1802546, 4351731, 10506008, 25363747, 61233502, 147830751, 356895004, 861620759, 2080136522, 5021893803, 12123924128, 29269742059, 70663408246, 170596558551, 411856525348
Offset: 0

Views

Author

Benoit Cloitre, Nov 22 2002

Keywords

Comments

Inverse binomial transform of -1, 1, 6, 22, 76, 260, ... (see A111566). Binomial transform of -1, 3, -2, 6, -4, 12, -8, 24, -16, ... (see A162255). - R. J. Mathar, Oct 02 2012

Examples

			G.f. = -1 + 2*x + 3*x^2 + 8*x^3 + 19*x^4 + 46*x^5 + 111*x^6 + ... - _Michael Somos_, Jun 30 2022
		

References

  • H. S. M. Coxeter, 1998, Numerical distances among the circles in a loxodromic sequence, Nieuw Arch. Wisk, 16, pp. 1-9.

Crossrefs

Programs

  • Haskell
    a078343 n = a078343_list !! n
    a078343_list = -1 : 2 : zipWith (+)
                            (map (* 2) $ tail a078343_list) a078343_list
    -- Reinhard Zumkeller, Jan 04 2013
    
  • Magma
    m:=30; R:=PowerSeriesRing(Integers(), m); Coefficients(R!((1-4*x)/(-1+2*x+x^2))); // G. C. Greubel, Jul 26 2018
  • Maple
    f:=proc(n) option remember; if n=0 then RETURN(-1); fi; if n=1 then RETURN(2); fi; 2*f(n-1)+f(n-2); end;
  • Mathematica
    Table[4 Fibonacci[n, 2] - Fibonacci[n + 1, 2], {n, 0, 30}] (* Vladimir Reshetnikov, Sep 27 2016 *)
    LinearRecurrence[{2,1},{-1,2},40] (* Harvey P. Dale, Apr 15 2019 *)
  • PARI
    a(n)=([0,1;1,2]^n*[-1;2])[1,1] \\ Charles R Greathouse IV, Jun 11 2015
    

Formula

For the unsigned version: a(1)=1; a(2)=2; a(n) = Sum_{k=2..n-1} (a(k) + a(k-1)).
a(n) is asymptotic to (1/4)*(-2+3*sqrt(2))*(1+sqrt(2))^n.
a(n) = A048746(n-3) + 2, for n > 2. - Ralf Stephan, Oct 17 2003
a(n) = 2*A000129(n) - A000129(n-1) if n > 0; abs(a(n)) = Sum_{k=0..floor(n/2)} (C(n-k-1, k) - C(n-k-1, k-1))2^(n-2k). - Paul Barry, Dec 23 2004
O.g.f.: (1-4*x)/(-1 + 2*x + x^2). - R. J. Mathar, Feb 15 2008
a(n) = 4*Pell(n) - Pell(n+1), where Pell = A000129. - Vladimir Reshetnikov, Sep 27 2016
a(n) = -(-1)^n * A048654(-n) = ( (-2+3*sqrt(2))*(1+sqrt(2))^n + (-2-3*sqrt(2))*(1-sqrt(2))^n )/4 for all n in Z. - Michael Somos, Jun 30 2022
2*a(n+1)^2 = A048655(n)^2 + (-1)^n*7. - Philippe Deléham, Mar 07 2023
E.g.f.: 3*exp(x)*sinh(sqrt(2)*x)/sqrt(2) - exp(x)*cosh(sqrt(2)*x). - Stefano Spezia, May 26 2024

Extensions

Entry revised by N. J. A. Sloane, Apr 29 2004

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

Original entry on oeis.org

-1, 3, 5, 13, 31, 75, 181, 437, 1055, 2547, 6149, 14845, 35839, 86523, 208885, 504293, 1217471, 2939235, 7095941, 17131117, 41358175, 99847467, 241053109, 581953685, 1404960479, 3391874643, 8188709765, 19769294173, 47727298111, 115223890395, 278175078901, 671574048197
Offset: 0

Views

Author

Paul Curtz, Feb 21 2008

Keywords

Comments

Double binomial transform of [1, 3, -5, 13, -31, 75, -181, ...] = the Pell-like sequence A048655: (1, 5, 11, 27, 65, 157, ...). - Gary W. Adamson, Jul 23 2008

Crossrefs

Programs

  • Magma
    I:=[-1,3]; [n le 2 select I[n] else 2*Self(n-1) + Self(n-2): n in [1..30]]; // G. C. Greubel, May 22 2021
    
  • Mathematica
    LinearRecurrence[{2,1},{-1,3},25] (* G. C. Greubel, Oct 17 2016 *)
  • PARI
    a(n)=([0,1; 1,2]^n*[-1;3])[1,1] \\ Charles R Greathouse IV, Oct 17 2016
    
  • Sage
    [(lucas_number2(n,2,-1) + 2*lucas_number2(n-1,2,-1))/2 for n in (0..30)] # G. C. Greubel, May 22 2021

Formula

From R. J. Mathar, Feb 23 2008: (Start)
O.g.f.: (-1 + 5*x)/(1 - 2*x - x^2).
a(n) = 5*A000129(n) - A000129(n+1). (End)
a(n) = ((3+sqrt(2))*(1+sqrt(2))^n + (3-sqrt(2))*(1-sqrt(2))^n)/2 with offset 0. - Al Hakanson (hawkuu(AT)gmail.com), Jun 17 2009
a(n) = (1/2)*(A002203(n) + 2*A002203(n-1)). - G. C. Greubel, May 22 2021

Extensions

More terms from R. J. Mathar, Feb 23 2008

A143095 (1, 2, 4, 8, ...) interleaved with (4, 8, 16, 32, ...).

Original entry on oeis.org

1, 4, 2, 8, 4, 16, 8, 32, 16, 64, 32, 128, 64, 256, 128, 512, 256, 1024, 512, 2048, 1024, 4096, 2048, 8192, 4096, 16384, 8192, 32768, 16384, 65536, 32768, 131072, 65536, 262144, 131072, 524288, 262144, 1048576, 524288, 2097152, 1048576, 4194304
Offset: 0

Views

Author

Keywords

Comments

Partial sums are in A079360. a(n) = A076736(n+5). - Klaus Brockhaus, Jul 27 2009

Crossrefs

Cf. A048655.

Programs

  • Maple
    seq(coeff(series((1+4*x)/(1-2*x^2), x, n+1), x, n), n = 0..45); # G. C. Greubel, Mar 13 2020
  • Mathematica
    nn=30;With[{p=2^Range[0,nn]},Riffle[Take[p,nn-2],Drop[p,2]]] (* Harvey P. Dale, Oct 03 2011 *)
  • Maxima
    A143095(n):=(5-3*(-1)^n)*2^(1/4*(2*n-1+(-1)^n))/2$
    makelist(A143095(n),n,0,30); /* Martin Ettl, Nov 03 2012 */
    
  • PARI
    for(n=0, 41, print1((5-3*(-1)^n)*2^(1/4*(2*n-1+(-1)^n))/2, ",")) \\ Klaus Brockhaus, Jul 27 2009
    
  • Sage
    [(5 -3*(-1)^n)*2^((2*n-1+(-1)^n)/4)/2 for n in (0..45)] # G. C. Greubel, Mar 13 2020

Formula

Inverse binomial transform of A048655: (1, 5, 11, 27, 65, 157, ...).
a(n) = A135530(n+1). - R. J. Mathar, Aug 02 2008
From Klaus Brockhaus, Jul 27 2009: (Start)
a(n) = (5 - 3*(-1)^n) * 2^((2*n-1+(-1)^n)/4)/2.
a(n) = 2*a(n-2) for n > 1; a(0) = 1, a(1) = 4.
G.f.: (1+4*x)/(1-2*x^2). (End)
a(n+3) = a(n+2)*a(n+1)/a(n). - Reinhard Zumkeller, Mar 04 2011

Extensions

More terms from Klaus Brockhaus, Jul 27 2009

A164095 a(n) = 2*a(n-2) for n > 2; a(1) = 5, a(2) = 6.

Original entry on oeis.org

5, 6, 10, 12, 20, 24, 40, 48, 80, 96, 160, 192, 320, 384, 640, 768, 1280, 1536, 2560, 3072, 5120, 6144, 10240, 12288, 20480, 24576, 40960, 49152, 81920, 98304, 163840, 196608, 327680, 393216, 655360, 786432, 1310720, 1572864, 2621440, 3145728
Offset: 1

Views

Author

Klaus Brockhaus, Aug 10 2009

Keywords

Comments

Interleaving of A020714 and A007283 without initial term 3.
Partial sums are in A164096.
Binomial transform is A048655 without initial 1, second binomial transform is A161941 without initial 2, third binomial transform is A164037, fourth binomial transform is A161731 without initial 1, fifth binomial transform is A164038, sixth binomial transform is A164110.

Crossrefs

Programs

  • Magma
    [ n le 2 select n+4 else 2*Self(n-2): n in [1..40] ];
  • Mathematica
    LinearRecurrence[{0,2},{5,6},50] (* or *) With[{nn=20},Riffle[NestList[ 2#&,5,nn],NestList[2#&,6,nn]]] (* Harvey P. Dale, Aug 15 2020 *)

Formula

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

A048694 Generalized Pellian with second term equal to 7.

Original entry on oeis.org

1, 7, 15, 37, 89, 215, 519, 1253, 3025, 7303, 17631, 42565, 102761, 248087, 598935, 1445957, 3490849, 8427655, 20346159, 49119973, 118586105, 286292183, 691170471, 1668633125, 4028436721, 9725506567
Offset: 0

Views

Author

Keywords

Comments

Pisano period lengths: 1, 1, 8, 4, 12, 8, 6, 4, 24, 12, 24, 8, 28, 6, 24, 8, 16, 24, 40, 12, ... . - R. J. Mathar, Aug 10 2012

Crossrefs

Programs

  • Maple
    with(combinat): a:=n->5*fibonacci(n, 2)+fibonacci(n+1, 2): seq(a(n), n=0..26); # Zerinvary Lajos, Apr 04 2008
  • Mathematica
    a[n_]:=(MatrixPower[{{1,2},{1,1}},n].{{6},{1}})[[2,1]]; Table[a[n],{n,0,40}] (* Vladimir Joseph Stephan Orlovsky, Feb 20 2010 *)
    LinearRecurrence[{2,1},{1,7},40] (* Harvey P. Dale, Jul 22 2011 *)
  • Maxima
    a[0]:1$
    a[1]:7$
    a[n]:=2*a[n-1]+a[n-2]$
    A048694(n):=a[n]$
    makelist(A048694(n),n,0,30); /* Martin Ettl, Nov 03 2012 */

Formula

a(n) = ((6+sqrt(2))(1+sqrt(2))^n - (6-sqrt(2))(1-sqrt(2))^n)/2*sqrt(2).
a(n) = 2*a(n-1) + a(n-2); a(0)=1, a(1)=7.
G.f.: (1+5*x)/(1 - 2*x - x^2). - Philippe Deléham, Nov 03 2008
a(n) = ((1+sqrt(18))(1+sqrt(2))^n+(1-sqrt(18))(1-sqrt(2))^n)/2 offset 0. a(n) = first binomial transform of 1,6,2,12,4,24. - Al Hakanson (hawkuu(AT)gmail.com), Aug 01 2009

A048696 Generalized Pellian with second term equal to 9.

Original entry on oeis.org

1, 9, 19, 47, 113, 273, 659, 1591, 3841, 9273, 22387, 54047, 130481, 315009, 760499, 1836007, 4432513, 10701033, 25834579, 62370191, 150574961, 363520113, 877615187, 2118750487, 5115116161, 12348982809, 29813081779, 71975146367
Offset: 0

Views

Author

Keywords

Comments

Binomial transform of 5,6,10,12,20,24,40. - Al Hakanson (hawkuu(AT)gmail.com), Aug 12 2009
Binomial transform of A164587. Inverse binomial transform of A164298. - Klaus Brockhaus, Aug 17 2009
For n > 0: a(n) = A105082(n) - A105082(n-1). - Reinhard Zumkeller, Dec 15 2013

Crossrefs

Programs

  • Haskell
    a048696 n = a048696_list !! n
    a048696_list = 1 : 9 : zipWith (+)
                   a048696_list (map (2 *) $ tail a048696_list)
    -- Reinhard Zumkeller, Dec 15 2013
  • Magma
    [ n le 2 select 8*n-7 else 2*Self(n-1)+Self(n-2): n in [1..28] ]; // Klaus Brockhaus, Aug 17 2009
    
  • Maple
    with(combinat): a:=n->7*fibonacci(n, 2)+fibonacci(n+1, 2): seq(a(n), n=0..25); # Zerinvary Lajos, Apr 04 2008
  • Mathematica
    a[n_]:=(MatrixPower[{{1,2},{1,1}},n].{{8},{1}})[[2,1]]; Table[a[n],{n,0,40}] (* Vladimir Joseph Stephan Orlovsky, Feb 20 2010 *)
    LinearRecurrence[{2,1},{1,9},30] (* Harvey P. Dale, Apr 20 2012 *)
  • Maxima
    a[0]:1$
    a[1]:9$
    a[n]:=2*a[n-1]+a[n-2]$
    A048696(n):=a[n]$
    makelist(A048696(n),n,0,30); /* Martin Ettl, Nov 03 2012 */
    

Formula

a(n) = 2*a(n-1) + a(n-2); a(0)=1, a(1)=9.
a(n) = ((4*sqrt(2)+1)(1+sqrt(2))^n - (4*sqrt(2)-1)(1-sqrt(2))^n)/2.
G.f.: (1+7*x)/(1 - 2*x - x^2). - Philippe Deléham, Nov 03 2008
Showing 1-10 of 23 results. Next