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 71-80 of 115 results. Next

A163070 a(n) = ((4+sqrt(5))*(2+sqrt(5))^n + (4-sqrt(5))*(2-sqrt(5))^n)/2.

Original entry on oeis.org

4, 13, 56, 237, 1004, 4253, 18016, 76317, 323284, 1369453, 5801096, 24573837, 104096444, 440959613, 1867934896, 7912699197, 33518731684, 141987625933, 601469235416, 2547864567597, 10792927505804, 45719574590813
Offset: 0

Views

Author

Al Hakanson (hawkuu(AT)gmail.com), Jul 20 2009

Keywords

Comments

Binomial transform of A163069. Second binomial transform of A163141. Inverse binomial transform of A163071.

Crossrefs

Programs

  • Magma
    Z:=PolynomialRing(Integers()); N:=NumberField(x^2-5); S:=[ ((4+r)*(2+r)^n+(4-r)*(2-r)^n)/2: n in [0..21] ]; [ Integers()!S[j]: j in [1..#S] ]; // Klaus Brockhaus, Jul 21 2009
    
  • Mathematica
    LinearRecurrence[{4,1},{4,13},30] (* Harvey P. Dale, Sep 19 2011 *)
  • PARI
    x='x+O('x^30); Vec((4-3*x)/(1-4*x-x^2)) \\ G. C. Greubel, Jan 08 2018

Formula

a(n) = 4*a(n-1) + a(n-2) for n > 1; a(0) = 4, a(1) = 13.
G.f.: (4-3*x)/(1-4*x-x^2).
a(n) = 2*A000032(3*n) + 5*A000045(3*n)/2 = 2*A014448(n) + 5*A001076(n). - Diego Rattaggi, Aug 09 2020

Extensions

Edited and extended beyond a(5) by Klaus Brockhaus, Jul 21 2009

A189800 a(n) = 6*a(n-1) + 8*a(n-2), with a(0)=0, a(1)=1.

Original entry on oeis.org

0, 1, 6, 44, 312, 2224, 15840, 112832, 803712, 5724928, 40779264, 290475008, 2069084160, 14738305024, 104982503424, 747801460736, 5326668791808, 37942424436736, 270267896954880, 1925146777223168, 13713023838978048, 97679317251653632, 695780094221746176
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

  • Magma
    I:=[0,1]; [n le 2 select I[n] else 6*Self(n-1)+8*Self(n-2): n in [1..30]]; // Vincenzo Librandi, Nov 14 2011
    
  • Mathematica
    LinearRecurrence[{6, 8}, {0, 1}, 50]
    CoefficientList[Series[-(x/(-1+6 x+8 x^2)),{x,0,50}],x] (* Harvey P. Dale, Jul 26 2011 *)
  • PARI
    a(n)=([0,1; 8,6]^n*[0;1])[1,1] \\ Charles R Greathouse IV, Oct 03 2016

Formula

G.f.: x/(1 - 2*x*(3+4*x)). - Harvey P. Dale, Jul 26 2011

A203319 a(n) = n*Fibonacci(n) * Sum_{d|n} 1/(d*Fibonacci(d)).

Original entry on oeis.org

1, 3, 7, 19, 26, 81, 92, 267, 358, 848, 980, 3061, 3030, 7976, 11042, 25099, 27150, 78642, 79440, 219884, 270704, 584862, 659112, 1977909, 1950651, 4735370, 6204499, 14189096, 14912642, 43168586, 41734340, 110786987, 135815060, 290854380, 339428752, 953889058, 893839230
Offset: 1

Views

Author

Paul D. Hanna, Jan 01 2012

Keywords

Examples

			L.g.f.: L(x) = x + 3*x^2/2 + 7*x^3/3 + 19*x^4/4 + 26*x^5/5 + 81*x^6/6 +...
where
L(x) = x*(1 + x + 2*x^2 + 3*x^3 + 5*x^4 + 8*x^5 +...+ F(n+1)*x^n +...) +
x^2/2*(1 + 3*x^2 + 8*x^4 + 21*x^6 + 55*x^8 +...+ F(2*n+2)*x^(2*n) +...) +
x^3/3*(1 + 4*x^3 + 17*x^6 + 72*x^9 +...+ F(3*n+3)/2*x^(3*n) +...) +
x^4/4*(1 + 7*x^4 + 48*x^8 + 329*x^12 +...+ F(4*n+4)/3*x^(4*n) +...) +
x^5/5*(1 + 11*x^5 + 122*x^10 + 1353*x^15 +...+ F(5*n+5)/5*x^(5*n) +...) +
x^6/6*(1 + 18*x^6 + 323*x^12 + 5796*x^18 +...+ F(6*n+6)/8*x^(6*n) +...) +...
here F(n) = Fibonacci(n) = A000045(n).
Equivalently,
L(x) = x/(1-x-x^2) + (x^2/2)/(1-3*x^2+x^4) + (x^3/3)/(1-4*x^3-x^6) + (x^4/4)/(1-7*x^4+x^8) +...+ (x^n/n)/(1 - Lucas(n)*x^n + (-1)^n*x^(2*n)) +...
here Lucas(n) = A000032(n).
Exponentiation of the l.g.f. equals the g.f. of A203318:
exp(L(x)) = 1 + x + 2*x^2 + 4*x^3 + 9*x^4 + 16*x^5 + 36*x^6 + 64*x^7 +...+ A203318(n)*x^n +...
		

Crossrefs

Cf. A203318, A203321; A203414 (Pell variant).
Cf. A000032 (Lucas), A000045 (Fibonacci), A001906, A001076, A004187, A049666, A049660, A049667.

Programs

  • Mathematica
    a[n_] := n Fibonacci[n] DivisorSum[n, 1/(# Fibonacci[#]) &]; Array[a, 40] (* Jean-François Alcover, Dec 23 2015 *)
  • PARI
    {a(n)=if(n<1,0, n*fibonacci(n)*sumdiv(n,d,1/(d*fibonacci(d))) )}
    
  • PARI
    {Lucas(n)=fibonacci(n-1)+fibonacci(n+1)}
    {a(n)=n*polcoeff(sum(m=1,n+1,(x^m/m)/(1-Lucas(m)*x^m+(-1)^m*x^(2*m)+x*O(x^n))),n)}
    
  • PARI
    {Lucas(n)=fibonacci(n-1)+fibonacci(n+1)}
    {a(n)=local(L=x); L=sum(m=1, n, x^m/m*exp(sum(k=1, floor((n+1)/m), Lucas(m*k)*x^(m*k)/k)+x*O(x^n))); n*polcoeff(L,n)}
    
  • PARI
    {a(n)=local(A=1+x+x*O(x^n),F=1/(1-x-x^2+x*O(x^n))); A=exp(sum(m=1, n+1, x^m/m*round(prod(k=0, m-1, subst(F, x, exp(2*Pi*I*k/m)*x+x*O(x^n)))))); n*polcoeff(log(A), n)}

Formula

Equals the logarithmic derivative of A203318.
L.g.f.: L(x) = Sum_{n>=1} a(n)*x^n/n satisfies:
(1) L(x) = Sum_{n>=1} x^n/n * Sum_{k>=0} F(n*k+n)/F(n) * x^(n*k) where F(n) = Fibonacci(n).
(2) L(x) = Sum_{n>=1} x^n/n * exp( Sum_{k>=1} Lucas(n*k)*x^(n*k)/k ) where Lucas(n) = A000032(n).
(3) L(x) = Sum_{n>=1} x^n/n * 1/(1 - Lucas(n)*x^n + (-1)^n*x^(2*n)) where Lucas(n) = A000032(n).
(4) L(x) = Sum_{n>=1} x^n/n * G_n(x^n) where G_n(x^n) = Product_{k=0..n-1} G(u^k*x) where G(x) = 1/(1-x-x^2) and u is an n-th root of unity.

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

Original entry on oeis.org

1, 2, 7, 28, 117, 494, 2091, 8856, 37513, 158906, 673135, 2851444, 12078909, 51167078, 216747219, 918155952, 3889371025, 16475640050, 69791931223, 295643364940, 1252365390981, 5305104928862, 22472785106427, 95196245354568, 403257766524697, 1708227311453354, 7236167012338111, 30652895360805796
Offset: 0

Views

Author

N. J. A. Sloane, Dec 05 2013

Keywords

Comments

For n > 2, a(n) is the number of tilings of (a 2 X (n+1) rectangle missing the top right and top left 1 X 1 cells) using 1 X 1 squares, dominoes and right trominoes. Compare with similar tiling sequences A001076 and A110679. - Greg Dresden and Yilin Zhu, Jul 10 2025

Crossrefs

Programs

  • Magma
    I:=[1,2,7]; [n le 3 select I[n] else 5*Self(n-1)- 3*Self(n-2)-Self(n-3): n in [1..30]]; // Vincenzo Librandi, Jun 24 2017
    
  • Mathematica
    LinearRecurrence[{5, -3, -1}, {1, 2, 7}, 30] (* Vincenzo Librandi, Jun 24 2017 *)
    CoefficientList[Series[(1-3x)/(1-5x+3x^2+x^3),{x,0,30}],x] (* Harvey P. Dale, Oct 19 2024 *)
  • PARI
    Vec((1-3*x)/(1-5*x+3*x^2+x^3) + O(x^30)) \\ Felix Fröhlich, Apr 15 2019
    
  • Sage
    [(fibonacci(3*n+1) +1)/2 for n in (0..30)] # G. C. Greubel, Apr 19 2019

Formula

a(n) = 5*a(n-1) - 3*a(n-2) - a(n-3). - N. J. A. Sloane, Jun 23 2017
a(n) = (Fibonacci(3*n+1) + 1)/2 = Sum_{k=0..n} Fibonacci(3*k-1). - Ehren Metcalfe, Apr 15 2019
a(2*n) = A294262(2*n); a(2*n+1) = A254627(2*n+2). See "6 interlaced bisections" link. - Hermann Stamm-Wilbrandt, Apr 18 2019

A296239 a(n) = distance from n to nearest Fibonacci number.

Original entry on oeis.org

0, 0, 0, 0, 1, 0, 1, 1, 0, 1, 2, 2, 1, 0, 1, 2, 3, 4, 3, 2, 1, 0, 1, 2, 3, 4, 5, 6, 6, 5, 4, 3, 2, 1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 16, 15, 14, 13, 12, 11, 10, 9
Offset: 0

Views

Author

Rémy Sigrist, Dec 09 2017

Keywords

Comments

The Fibonacci numbers correspond to sequence A000045.
This sequence is analogous to:
- A051699 (distance to nearest prime),
- A053188 (distance to nearest square),
- A053646 (distance to nearest power of 2),
- A053615 (distance to nearest oblong number),
- A053616 (distance to nearest triangular number),
- A061670 (distance to nearest power),
- A074989 (distance to nearest cube),
- A081134 (distance to nearest power of 3),
The local maxima of the sequence correspond to positive terms of A004695.
a(n) = 0 iff n = A000045(k) for some k >= 0.
a(n) = 1 iff n = A061489(k) for some k > 4.
For any n >= 0, abs(a(n+1) - a(n)) <= 1.
For any n > 0, a(n) < n, and a^k(n) = 0 for some k > 0 (where a^k denotes the k-th iterate of a); k equals A105446(n) for n = 1..80 (and possibly more values).
a(n) > max(a(n-1), a(n+1)) iff n = A001076(k) for some k > 1.

Examples

			For n = 42:
- A000045(9) = 34 <= 42 <= 55 = A000045(10),
- a(42) = min(42 - 34, 55 - 42) = min(8, 13) = 8.
		

Crossrefs

Programs

  • Mathematica
    fibPi[n_] := 1 + Floor[ Log[ GoldenRatio, 1 + n*Sqrt@5]]; f[n_] := Block[{m = fibPi@ n}, Min[n - Fibonacci[m -1], Fibonacci[m] - n]]; Array[f, 81, 0] (* Robert G. Wilson v, Dec 11 2017 *)
    With[{nn=80,fibs=Fibonacci[Range[0,20]]},Table[Abs[n-Nearest[fibs,n]][[1]],{n,0,nn}]] (* Harvey P. Dale, Jul 02 2022 *)
  • PARI
    a(n) = for (i=1, oo, if (n<=fibonacci(i), return (min(n-fibonacci(i-1), fibonacci(i)-n))))

Formula

a(n) = abs(n - Fibonacci(floor(log(sqrt(20)*n)/log((1 + sqrt(5))/2)-1))). - Jon E. Schoenfield, Dec 14 2017

A015541 Expansion of x/(1 - 5*x - 7*x^2).

Original entry on oeis.org

0, 1, 5, 32, 195, 1199, 7360, 45193, 277485, 1703776, 10461275, 64232807, 394392960, 2421594449, 14868722965, 91294775968, 560554940595, 3441838134751, 21133075257920, 129758243232857, 796722742969725, 4891921417478624, 30036666288181195
Offset: 0

Views

Author

Keywords

Comments

Pisano period lengths: 1, 3, 8, 6, 8, 24, 6, 6, 24, 24, 5, 24, 12, 6, 8, 12, 16, 24, 120, 24, ... - R. J. Mathar, Aug 10 2012

Crossrefs

Programs

Formula

a(n) = 5*a(n-1) + 7*a(n-2).

A015544 Lucas sequence U(5,-8): a(n+1) = 5*a(n) + 8*a(n-1), a(0)=0, a(1)=1.

Original entry on oeis.org

0, 1, 5, 33, 205, 1289, 8085, 50737, 318365, 1997721, 12535525, 78659393, 493581165, 3097180969, 19434554165, 121950218577, 765227526205, 4801739379641, 30130517107845, 189066500576353, 1186376639744525, 7444415203333449, 46713089134623445
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

  • Magma
    [n le 2 select n-1 else 5*Self(n-1) + 8*Self(n-2): n in [1..30]]; // Vincenzo Librandi, Nov 13 2012
    
  • Mathematica
    a[n_]:=(MatrixPower[{{1,2},{1,-6}},n].{{1},{1}})[[2,1]]; Table[Abs[a[n]],{n,-1,40}] (* Vladimir Joseph Stephan Orlovsky, Feb 19 2010 *)
    LinearRecurrence[{5, 8}, {0, 1}, 30] (* Vincenzo Librandi, Nov 13 2012 *)
  • PARI
    A015544(n)=imag((2+quadgen(57))^n) \\ M. F. Hasler, Mar 06 2009
    
  • PARI
    x='x+O('x^30); concat([0], Vec(x/(1 - 5*x - 8*x^2))) \\ G. C. Greubel, Jan 01 2018
  • Sage
    [lucas_number1(n,5,-8) for n in range(0, 21)] # Zerinvary Lajos, Apr 24 2009
    

Formula

a(n) = 5*a(n-1) + 8*a(n-2).
G.f.: x/(1 - 5*x - 8*x^2). - M. F. Hasler, Mar 06 2009

Extensions

More precise definition by M. F. Hasler, Mar 06 2009

A024551 a(n) = floor(a(n-1)/(sqrt(5) - 2)) for n > 0 and a(0) = 1.

Original entry on oeis.org

1, 4, 16, 67, 283, 1198, 5074, 21493, 91045, 385672, 1633732, 6920599, 29316127, 124185106, 526056550, 2228411305, 9439701769, 39987218380, 169388575288, 717541519531, 3039554653411, 12875760133174, 54542595186106, 231046140877597
Offset: 0

Views

Author

Keywords

Programs

  • Mathematica
    a[0] = 1;
    a[n_] := Floor[a[n - 1]/FractionalPart[Sqrt[5]]]
    Table[a[n], {n, 0, 60}]
    (* Clark Kimberling, Aug 16 2012 *)
    a[0]=1;
    a[1]=4;
    a[2]=16;
    a[n_]:=Floor[a[n-1]^2/a[n-2]]+3
    Table[a[n],{n,0,60}]
    With[{c=Sqrt[5]-2},NestList[Floor[#/c]&,1,30]] (* Harvey P. Dale, Jul 18 2018 *)
  • PARI
    a(n)=([0,1,0; 0,0,1; -1,-3,5]^n*[1;4;16])[1,1] \\ Charles R Greathouse IV, Jan 20 2017
    
  • PARI
    step(n)=2*n + sqrtint(5*n^2)
    a(n)=if(n, step(a(n-1)), 1) \\ Charles R Greathouse IV, Jan 20 2017

Formula

a(n) = 5*a(n-1) - 3*a(n-2) - a(n-3). - Clark Kimberling, Aug 16 2012
G.f.: (-x^2-x+1)/[(1-x)(1-4x-x^2)].
a(n) = (3*Fibonacci(3*n+2) + 1)/4 = 1 + 3*Sum_{k=0..n} A001076(k). - Ehren Metcalfe, Apr 15 2019

A099014 a(n) = Fibonacci(n)*(Fibonacci(n-1)^2 + Fibonacci(n+1)^2).

Original entry on oeis.org

0, 1, 5, 20, 87, 365, 1552, 6565, 27825, 117844, 499235, 2114729, 8958240, 37947545, 160748653, 680941780, 2884516383, 12219006325, 51760543280, 219261176861, 928805254905, 3934482189716, 16666734024715, 70601418270865
Offset: 0

Views

Author

Paul Barry, Sep 22 2004

Keywords

Comments

Form the matrix A=[1,1,1,1;3,2,1,0;3,1,0,0;1,0,0,0]=(binomial(3-j,i)). Then a(n)=(2,3)-element of A^n.

Crossrefs

Programs

  • Magma
    [Fibonacci(n)*(Fibonacci(n-1)^2+Fibonacci(n+1)^2): n in [0..30]]; // Vincenzo Librandi, Jun 05 2011
    
  • Mathematica
    CoefficientList[Series[x*(1 + 2*x - x^2)/(1 - 3*x - 6*x^2 + 3*x^3 + x^4), {x, 0, 50}], x] (* G. C. Greubel, Dec 31 2017 *)
    Join[{0},#[[2]](#[[1]]^2+#[[3]]^2)&/@Partition[Fibonacci[ Range[ 0,30]],3,1]] (* or *) LinearRecurrence[{3,6,-3,-1},{0,1,5,20},30] (* Harvey P. Dale, Oct 17 2021 *)
  • PARI
    a(n)=fibonacci(n)*(fibonacci(n-1)^2+fibonacci(n+1)^2) \\ Charles R Greathouse IV, Jun 05 2011

Formula

G.f.: x*(1+2*x-x^2)/(1-3*x-6*x^2+3*x^3+x^4) = x*(1+2*x-x^2)/((1+x-x^2)*(1-4*x-x^2)).
a(n) = Sum_{k=0..n} (-1)^(k+1)*Fib(k)*(0^(n-k) + 6*A001076(n-k)).
a(n) = ((-1)^n*Fib(n) + 3*Fib(3*n))/5. - Ehren Metcalfe, May 21 2016

A110527 a(n+3) = 3*a(n+2) + 5*a(n+1) + a(n), a(0) = 0, a(1) = 1, a(2) = 8.

Original entry on oeis.org

0, 1, 8, 29, 128, 537, 2280, 9653, 40896, 173233, 733832, 3108557, 13168064, 55780809, 236291304, 1000946021, 4240075392, 17961247585, 76085065736, 322301510525, 1365291107840, 5783465941881, 24499154875368
Offset: 0

Views

Author

Creighton Dement, Jul 24 2005

Keywords

Comments

A048878(n) = a(n) + a(n+1). Compare with A110526.

Crossrefs

Programs

  • Maple
    seriestolist(series(-x*(1+5*x)/((1+x)*(x^2+4*x-1)), x=0,25)); -or- Floretion Algebra Multiplication Program, FAMP Code: 1lesseq[(- 'i + 'j - i' + j' - 'kk' - 'ik' - 'jk' - 'ki' - 'kj')(+ .5'i + .5i' + .5'jj' + .5'kk')], apart from initial term.
  • Mathematica
    LinearRecurrence[{3,5,1},{0,1,8},30] (* Harvey P. Dale, Feb 12 2015 *)
  • PARI
    x='x+O('x^50); concat(0, Vec(-x*(1+5*x)/((1+x)*(x^2+4*x-1)))) \\ G. C. Greubel, Aug 30 2017

Formula

G.f.: -x*(1+5*x)/((1+x)*(x^2+4*x-1)).
a(n) = (-1)^n + 3*A001076(n) - A015448(n). - Ehren Metcalfe, Nov 18 2017
a(n) = (-1)^n + 2*A110526(n) + A110679(n-2) for n >= 2. - Yomna Bakr and Greg Dresden, May 25 2024
Previous Showing 71-80 of 115 results. Next