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 31-40 of 73 results. Next

A107857 a(n) = floor[(phi + n mod 2)*a(n-1)], a(1)=1.

Original entry on oeis.org

1, 1, 2, 3, 7, 11, 28, 45, 117, 189, 494, 799, 2091, 3383, 8856, 14329, 37513, 60697, 158906, 257115, 673135, 1089155, 2851444, 4613733, 12078909, 19544085, 51167078, 82790071, 216747219, 350704367, 918155952, 1485607537, 3889371025
Offset: 1

Views

Author

Roger L. Bagula, Jun 12 2005

Keywords

Comments

A switched sequence with alternating limits of the golden mean and its square. The sequence uses only one initial term. Note that lim_{n->oo} a(n)/a(n-1) does not exist.
The consecutive pairs (2,3), (7,11), (28,45) occur as pairs in columns 2 and 3 of the Wythoff array, A035513. Suppose (l(n)) and (u(n)) are the lower and upper Beatty sequences of positive irrational numbers rClark Kimberling, Nov 24 2010

Crossrefs

Programs

  • Magma
    [ n eq 1 select 1 else Floor(((Sqrt(5)+1)/2+(n mod 2))*Self(n-1)): n in [1..35] ];
  • Mathematica
    Phi = N[(Sqrt[5] + 1)/2] F[1] = 1; F[n__] := F[n] = If[Mod[n, 2] == 0, Floor[Phi*F[n - 1]], Floor[(Phi + 1)*F[n -1]]] a = Table[F[n], {n, 1, 50}]
    LinearRecurrence[{1,4,-4,1,-1},{1,1,2,3,7},40] (* Harvey P. Dale, Mar 31 2023 *)
  • PARI
    a(n)=if(n<2,1,floor((phi+n%2)*a(n-1)))
    

Formula

G.f.: -x*(-1+3*x^2-x^3+x^4) / ( (x-1)*(x^4+4*x^2-1) ). - R. J. Mathar, Sep 11 2011
a(2n+2) = (1/2)*(Fib(3n+2) + 1), a(2n+1) = (1/2)*(Fib(3n+1) + 1).
a(n) = a(n-1) + 4*a(n-2) - 4*a(n-3) + a(n-4) - a(n-5). - Wesley Ivan Hurt, May 04 2025

Extensions

Edited and better name by Ralf Stephan, Nov 24 2010

A048878 Generalized Pellian with second term of 9.

Original entry on oeis.org

1, 9, 37, 157, 665, 2817, 11933, 50549, 214129, 907065, 3842389, 16276621, 68948873, 292072113, 1237237325, 5241021413, 22201322977, 94046313321, 398386576261, 1687592618365, 7148757049721, 30282620817249, 128279240318717, 543399582092117, 2301877568687185
Offset: 0

Views

Author

Keywords

Examples

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

Crossrefs

Programs

  • Maple
    with(combinat): a:=n->5*fibonacci(n-1,4)+fibonacci(n,4): seq(a(n), n=1..16); # Zerinvary Lajos, Apr 04 2008
  • Mathematica
    LinearRecurrence[{4,1},{1,9},31] (* or *) CoefficientList[ Series[ (1+5x)/(1-4x-x^2),{x,0,30}],x] (* Harvey P. Dale, Jul 12 2011 *)
  • PARI
    { default(realprecision, 2000); for (n=0, 2000, a=round(((7+sqrt(5))*(2+sqrt(5))^n - (7-sqrt(5))*(2-sqrt(5))^n )/10*sqrt(5)); if (a > 10^(10^3 - 6), break); write("b048878.txt", n, " ", a); ); } \\ Harry J. Smith, May 31 2009

Formula

a(n) = ( (7+sqrt(5))(2+sqrt(5))^n - (7-sqrt(5))(2-sqrt(5))^n )/2*sqrt(5).
G.f.: (1+5*x)/(1-4*x-x^2). - Philippe Deléham, Nov 03 2008
a(n) = F(3*n+3) + F(3*n-2); F = A000045. - Yomna Bakr and Greg Dresden, May 25 2024

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

Original entry on oeis.org

0, 1, 3, 14, 58, 247, 1045, 4428, 18756, 79453, 336567, 1425722, 6039454, 25583539, 108373609, 459077976, 1944685512, 8237820025, 34895965611, 147821682470, 626182695490, 2652552464431, 11236392553213, 47598122677284
Offset: 0

Views

Author

Creighton Dement, Jul 24 2005

Keywords

Comments

A001076(n) = a(n) + a(n+1). Program "Superseeker" finds: A033887(n+1) = a(n+2) - a(n); Elements of even index in the sequence: A049661(n) = (F(6n+1)-1)/4; A015448(n+2) = a(n+2) + 2*a(n+1) + a(n)

Crossrefs

Programs

  • Maple
    seriestolist(series(-x/((1+x)*(x^2+4*x-1)), x=0,25)); -or- Floretion Algebra Multiplication Program, FAMP Code: 1jbaseseq[(- 'i + 'j - i' + j' - 'kk' - 'ik' - 'jk' - 'ki' - 'kj')(+ .5'i + .5i' + .5'jj' + .5'kk')]
  • Mathematica
    Table[(Fibonacci[3n+1]-(-1)^n)/4, {n, 0, 20}] (* Vladimir Reshetnikov, Oct 28 2015 *)
  • PARI
    concat(0, Vec(x/((1+x)*(1-x^2-4*x)) + O(x^100))) \\ Altug Alkan, Oct 28 2015

Formula

G.f.: -x/((1+x)*(x^2+4*x-1)).
a(n) = (-1)^n/2 * Sum_{k=0..n} (-1)^k*Fibonacci(3*k). - Gary Detlefs, Jan 03 2013
a(n) = (Fibonacci(3*n+1)-(-1)^n)/4, where Fibonacci(n) = A000045(n). - Vladimir Reshetnikov, Oct 28 2015

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

A213893 Fixed points of a sequence h(n) defined by the minimum number of 4's in the relation n*[n,4,4,...,4,n] = [x,...,x] between simple continued fractions.

Original entry on oeis.org

3, 7, 43, 67, 103, 127, 163, 223, 283, 367, 463, 487, 523, 547, 607, 643, 727, 787, 823, 883, 907, 1063, 1123, 1303, 1327, 1423, 1447, 1543, 1567, 1627, 1663, 1723, 1747, 1783, 1867, 1987, 2083, 2143, 2203, 2287, 2347, 2383, 2467, 2683, 2707, 2767, 2803, 2887
Offset: 1

Views

Author

Art DuPre, Jun 23 2012

Keywords

Comments

In a variant of A213891, multiply n by a number with simple continued fraction [n,4,4,...,4,n] and increase the number of 4's until the continued fraction of the product has the same first and last entry (called x in the NAME). Examples are
2*[2,4,2] = [4,2,4],
3*[3,4,4,4,3] = [9,1,2,2,2,1,9],
4*[4,4,4] = [16,1,16],
5*[5,4,4,4,4,5] = [26,5,1,1,5,26].
The number of 4's needed defines the sequence h(n) = 1, 3, 1, 4, 3, 7, 3, 3, 9, ... (n>=2).
The current sequence contains the fixed points of h, i.e., those n where h(n)=n.
We conjecture that this sequence contains prime numbers analogous to the sequence of prime numbers A000057, in the sense that, instead of referring to the Fibonacci sequences(sequences satisfying f(n) = f(n-1) + f(n-2) with arbitrary positive integer values for f(1) and f(2)) it refers to the sequences satisfying f(n) = 4*f(n-1) + f(n-2), A001076, A001077, A015448, etc. This would mean that a prime is in the sequence if and only if it divides some term in each of the sequences satisfying f(n) = 4*f(n-1) + f(n-2).
The above sequence h() is recorded as A262214. - M. F. Hasler, Sep 15 2015

Crossrefs

Programs

  • Mathematica
    f[m_, n_] := Block[{c, k = 1}, c[x_, y_] := ContinuedFraction[x FromContinuedFraction[Join[{x}, Table[m, {y}], {x}]]]; While[First@ c[n, k] != Last@ c[n, k], k++]; k]; Select[Range[2, 1000], f[4, #] == # &] (* Michael De Vlieger, Sep 16 2015 *)
  • PARI
    {a(n) = local(t, m=1); if( n<2, 0, while( 1,
       t = contfracpnqn( concat([n, vector(m,i,4), n]));
       t = contfrac(n*t[1,1]/t[2,1]);
       if(t[1]
    				

A226328 a(0)=1, a(1)=-2; a(n+2) = a(n+1) + a(n) + (period 3: repeat 3, 1, -1).

Original entry on oeis.org

1, -2, 2, 1, 2, 6, 9, 14, 26, 41, 66, 110, 177, 286, 466, 753, 1218, 1974, 3193, 5166, 8362, 13529, 21890, 35422, 57313, 92734, 150050, 242785, 392834, 635622, 1028457, 1664078, 2692538, 4356617, 7049154, 11405774, 18454929, 29860702, 48315634, 78176337
Offset: 0

Views

Author

Paul Curtz, Jun 04 2013

Keywords

Comments

a(n+1)/a(n) -> the golden ratio, A001622.
a(3*n)+a(3*n+1)+a(3*n+2) = 1,9,49,217,929,... = b(n), and b(n+1)-b(n) = 8*A015448(n+1).

Examples

			a(2)=-2+1+3=2, a(3)=2-2+1=1, a(4)=1+2-1=2, a(5)=2+1+3=6.
a(0)=F(-3)+F(n)-1=2+0-1=1,  a(1)=-1+1-2=-2, a(2)=1+1-0=2.
a(3)=1+4*0=1, a(4)=-2+4*1=2, a(5)=2+4*1=6, a(6)=1+4*2=9.
		

Crossrefs

Programs

  • Magma
    I:=[1,-2,2,1,2]; [n le 5 select I[n] else Self(n-1)+Self(n-2)+Self(n-3)-Self(n-4)-Self(n-5): n in [1..40]]; // Vincenzo Librandi, Jun 05 2013
  • Mathematica
    CoefficientList[Series[(2 x^4 + 3 x^2 - 3 x + 1) / (x^5 + x^4 - x^3 - x^2 - x + 1), {x, 0, 40}], x] (* Vincenzo Librandi, Jun 05 2013 *)
    LinearRecurrence[{1, 1, 1, -1, -1}, {1, -2, 2, 1, 2}, 40] (* Hugo Pfoertner, Feb 12 2024 *)
  • PARI
    Vec((2*x^4+3*x^2-3*x+1)/(x^5+x^4-x^3-x^2-x+1)+O(x^99)) \\ Charles R Greathouse IV, Jun 04 2013
    

Formula

a(n) = F(n-3) + F(n) - A010872(n+1).
a(n+3) = a(n) + 4*F(n).
G.f.: (2*x^4+3*x^2-3*x+1)/( (x-1)*(x^2+x-1)*(1+x+x^2) ). [Charles R Greathouse IV, Jun 04 2013]
a(n) = A057078(n+1) +2*A212804(n) -1. - R. J. Mathar, Jun 26 2013

Extensions

a(23) corrected by Charles R Greathouse IV, Jun 04 2013
More terms from Bruno Berselli, Jun 04 2013

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

Original entry on oeis.org

1, 8, 33, 140, 593, 2512, 10641, 45076, 190945, 808856, 3426369, 14514332, 61483697, 260449120, 1103280177, 4673569828, 19797559489, 83863807784, 355252790625, 1504874970284, 6374752671761
Offset: 0

Views

Author

Keywords

Comments

Generalized Pellian with second term of 8.

Crossrefs

Programs

  • Haskell
    a048877 n = a048877_list !! n
    a048877_list = 1 : 8 : zipWith (+) a048877_list (map (* 4) $ tail a048877_list)
    -- Reinhard Zumkeller, May 01 2013
  • Maple
    with(combinat): a:=n->4*fibonacci(n-1,4)+fibonacci(n,4): seq(a(n), n=1..16); # Zerinvary Lajos, Apr 04 2008
  • Mathematica
    CoefficientList[Series[(1+4x)/(1-4x-x^2),{x,0,20}],x]  (* Harvey P. Dale, Mar 30 2011 *)
    LinearRecurrence[{4,1},{1,8},30] (* Harvey P. Dale, Nov 03 2013 *)

Formula

a(n) = ((6+sqrt(5))*(2+sqrt(5))^n - (6-sqrt(5))*(2-sqrt(5))^n )/(2*sqrt(5)).
G.f.: (1+4*x)/(1-4*x-x^2). - Philippe Deléham, Nov 03 2008
a(n)=4*a(n-1) + a(n-2); a(0)=1, a(1)=8.

A048879 Generalized Pellian with second term of 10.

Original entry on oeis.org

1, 10, 41, 174, 737, 3122, 13225, 56022, 237313, 1005274, 4258409, 18038910, 76414049, 323695106, 1371194473, 5808472998, 24605086465, 104228818858, 441520361897, 1870310266446, 7922761427681, 33561355977170, 142168185336361, 602234097322614
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

  • Haskell
    a048879 n = a048879_list !! n
    a048879_list = 1 : 10 : zipWith (+)
                            a048879_list (map (* 4) $ tail a048879_list)
    -- Reinhard Zumkeller, Mar 03 2014
  • Maple
    with(combinat): a:=n->6*fibonacci(n-1,4)+fibonacci(n,4): seq(a(n), n=1..16); # Zerinvary Lajos, Apr 04 2008
  • Mathematica
    LinearRecurrence[{4,1},{1,10},30] (* Harvey P. Dale, Jul 18 2011 *)

Formula

a(n) = ((8+sqrt(5))*(2+sqrt(5))^n - (8-sqrt(5))*(2-sqrt(5))^n)2*sqrt(5).
From Philippe Deléham, Nov 03 2008: (Start)
a(n) = 4*a(n-1) + a(n-2); a(0)=1, a(1)=10.
G.f.: (1+6*x)/(1-4*x-x^2). (End)
For n >= 1, a(n) equals the denominator of the continued fraction [4, 4, ..., 4, 10] (with n copies of 4). The numerator of that continued fraction is a(n+1). - ZhenShu Luan, Aug 05 2019

Extensions

More terms from Harvey P. Dale, Jul 18 2011

A099843 A transform of the Fibonacci numbers.

Original entry on oeis.org

1, -5, 21, -89, 377, -1597, 6765, -28657, 121393, -514229, 2178309, -9227465, 39088169, -165580141, 701408733, -2971215073, 12586269025, -53316291173, 225851433717, -956722026041, 4052739537881, -17167680177565, 72723460248141, -308061521170129, 1304969544928657
Offset: 0

Views

Author

Paul Barry, Oct 27 2004

Keywords

Comments

The g.f. is the transform of the g.f. of A000045 under the mapping G(x) -> (-1/(1+x))*G((x-1)/(x+1)). In general this mapping transforms x/(1-k*x-k*x^2) into (1-x)/(1 + 2(k+1)*x - (2*k-1)*x^2).
Pisano period lengths: 1, 1, 8, 2, 20, 8, 16, 4, 8, 20, 10, 8, 28, 16, 40, 8, 12, 8, 6, 20, ... - R. J. Mathar, Aug 10 2012

Crossrefs

Cf. A084326 (shifted unsigned inverse binomial transform), A152174 (binomial transform).

Programs

  • Magma
    [(-1)^n*Fibonacci(3*n+2): n in [0..40]]; // G. C. Greubel, Apr 20 2023
    
  • Maple
    a:= n-> (<<0|1>, <1|-4>>^n.<<1, -5>>)[1,1]:
    seq(a(n), n=0..24);  # Alois P. Heinz, Apr 21 2023
  • Mathematica
    CoefficientList[Series[(1-x)/(1+4*x-x^2), {x,0,30}], x] (* Vladimir Joseph Stephan Orlovsky, Jun 10 2011 *)
    LinearRecurrence[{-4,1},{1,-5},30] (* Harvey P. Dale, Aug 13 2015 *)
  • SageMath
    [(-1)^n*fibonacci(3*n+2) for n in range(41)] # G. C. Greubel, Apr 20 2023

Formula

G.f.: (1-x)/(1+4*x-x^2).
a(n) = (sqrt(5)-2)^n * (1/2 - 3*sqrt(5)/10) + (-sqrt(5)-2)^n * (1/2 + 3*sqrt(5)/10).
a(n) = (-1)^n*Fibonacci(3*n+2).
a(n) = -4*a(n-1) + a(n-2), a(0)=1, a(1)=-5. - Philippe Deléham, Nov 03 2008
a(n) = (-1)^n*(A001076(n) + A001076(n+1)). - R. J. Mathar, Aug 10 2012
a(n) = (-1)^n*A015448(n+1). - R. J. Mathar, May 07 2019

A134489 a(n) = Fibonacci(5*n + 2).

Original entry on oeis.org

1, 13, 144, 1597, 17711, 196418, 2178309, 24157817, 267914296, 2971215073, 32951280099, 365435296162, 4052739537881, 44945570212853, 498454011879264, 5527939700884757, 61305790721611591, 679891637638612258
Offset: 0

Views

Author

Artur Jasinski, Oct 28 2007

Keywords

Comments

The o.g.f. of {F(m*n + 2)}_{n>=0}, for m = 1, 2, ..., is
G(m,x) = (1 + F(m - 2)*x) / (1 - L(m)*x + (-1)^m*x^2), with F = A000045 and F(-1) = 1, and L = A000032. - Wolfdieter Lang, Feb 06 2023

Crossrefs

Programs

  • Magma
    [Fibonacci(5*n+2): n in [0..50]]; // Vincenzo Librandi, Apr 20 2011
  • Mathematica
    Table[Fibonacci[5n + 2], {n, 0, 30}]
    LinearRecurrence[{11,1},{1,13},20] (* Harvey P. Dale, May 05 2022 *)

Formula

From R. J. Mathar, Jul 04 2011: (Start)
G.f.: (-1-2*x) / (-1 + 11*x + x^2).
a(n) = 2*A049666(n) + A049666(n+1). (End)
a(n) = A000045(A016873(n)). - Michel Marcus, Nov 05 2013
Previous Showing 31-40 of 73 results. Next