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 11-20 of 21 results. Next

A135138 a(n) = 5*a(n-2) + 2*a(n-3).

Original entry on oeis.org

0, 0, 1, 0, 5, 2, 25, 20, 129, 150, 685, 1008, 3725, 6410, 20641, 39500, 116025, 238782, 659125, 1425960, 3773189, 8448050, 21717865, 49786628, 125485425, 292368870, 727000381, 1712815200, 4219739645, 10018076762, 24524328625, 58529863100
Offset: 0

Views

Author

Paul Curtz, Feb 13 2008

Keywords

Comments

a(n+2), n>=0, is the (5,2)-Padovan sequence p(5,2;n)with o.g.f. 1/(1-5*x^2-2*x^3). See A000931(n+3) ((1,1)-Padovan), and the W. Lang link given there, also for a combinatorial interpretation. - Wolfdieter Lang, Jun 28 2010

Crossrefs

Cf. A135139.

Programs

  • Mathematica
    a = {0, 0, 1}; Do[AppendTo[a, 5*a[[ -2]] + 2*a[[ -3]]], {40}]; a (* Stefan Steinerberger, Feb 15 2008 *)
    LinearRecurrence[{0, 5, 2}, {0, 0, 1}, 100] (* G. C. Greubel, Sep 28 2016 *)

Formula

From R. J. Mathar, Feb 15 2008: (Start)
O.g.f.: -x^2 / ( (2*x+1)*(x^2+2*x-1) ).
a(n) = [(-2)^n + A078343(n)]/7. (End)

Extensions

More terms from R. J. Mathar and Stefan Steinerberger, Feb 15 2008

A164581 a(n) = 5*a(n - 1) + a(n - 2), with a(0)=1, a(1)=2.

Original entry on oeis.org

1, 2, 11, 57, 296, 1537, 7981, 41442, 215191, 1117397, 5802176, 30128277, 156443561, 812346082, 4218173971, 21903215937, 113734253656, 590574484217, 3066606674741, 15923607857922, 82684645964351, 429346837679677, 2229418834362736, 11576441009493357
Offset: 0

Views

Author

Vincenzo Librandi, Aug 17 2009

Keywords

Crossrefs

Programs

  • Magma
    [ n le 2 select (n) else 5*Self(n-1)+Self(n-2): n in [1..25] ]; // Vincenzo Librandi, Sep 12 2013
    
  • Mathematica
    LinearRecurrence[{5, 1}, {1, 2}, 40] (* or *) Rest[CoefficientList[Series [x (1 - 3 x) / (1 - 5 x - x^2), {x, 0, 40}], x]] (* Harvey P. Dale, May 02 2011 *)
  • PARI
    Vec((1-3*x)/(1-5*x-x^2) + O(x^40)) \\ Colin Barker, Oct 13 2015

Formula

a(n) = 5*a(n-1)+a(n-2) = A052918(n)-3*A052918(n-1).
G.f.: (1-3*x)/(1-5*x-x^2).
a(n) = A052918(n) + A015449(n). - R. J. Mathar, Jul 06 2012
a(n) = (2^(-1-n)*((5-sqrt(29))^n*(1+sqrt(29))+(-1+sqrt(29))*(5+sqrt(29))^n))/sqrt(29). - Colin Barker, Oct 13 2015
a(n) = Sum_{k=0..n-2} A168561(n-2,k)*5^k + 2 * Sum_{k=0..n-1} A168561(n-1,k)*5^k, n>0. - R. J. Mathar, Feb 14 2024
a(n) = A052918(n) -3*A052918(n-1). - R. J. Mathar, Feb 14 2024
From Peter Bala, Jul 08 2025: (Start)
The following series telescope:
Sum_{n >= 1} 1/(a(n) - 7*(-1)^n/a(n)) = 3/10, since 1/(a(n) - 7*(-1)^n/a(n)) = b(n) - b(n+1), where b(n) = (1/5) * (a(n) + a(n-1)) / (a(n)*a(n-1)).
Sum_{n >= 1} (-1)^(n+1)/(a(n) - 7*(-1)^n/a(n)) = 1/10, since 1/(a(n) - 7*(-1)^n/a(n)) = c(n) + c(n+1), where c(n) = (1/5) * (a(n) - a(n-1)) / (a(n)*a(n-1)). (End)

A220414 a(n) = 6*a(n-1) - a(n-2), with a(1) = 13, a(2) = 73.

Original entry on oeis.org

13, 73, 425, 2477, 14437, 84145, 490433, 2858453, 16660285, 97103257, 565959257, 3298652285, 19225954453, 112057074433, 653116492145, 3806641878437, 22186734778477, 129313766792425, 753695865976073, 4392861429064013, 25603472708408005, 149227974821384017
Offset: 1

Views

Author

Keywords

Comments

a(n) is the area of the 4-generalized Fibonacci snowflake.
a(n) is the area of the 5-generalized Fibonacci snowflake, for n >= 2.
From Wolfdieter Lang, Feb 07 2015: (Start)
This sequence gives one part of the positive proper (sometimes called primitive) solutions y of the Pell equation x^2 - 2*y^2 = - 7^2 based on the fundamental solution (x0, y0) = (-1, 5). The corresponding x solutions are given in A254757.
The other part of the proper solutions are given in (A254758(n), A254759(n)) for n >= 0.
The improper positive solutions come from 7*(x(n), y(n)) with the positive proper solutions of the Pell equation x^2 - 2*y^2 = -1 given in (A001653(n-1), A002315(n)), for n >= 1. (End)
The terms of this sequence are hypotenuses of Pythagorean triangles whose difference between legs is equal to 7. - César Aguilera, Sep 29 2023

Examples

			From _Wolfdieter Lang_, Feb 07 2015: (Start)
Pell equation x^2 - 2*y^2 = -7^2 instance:
A254757(3)^2 - 2*a(3)^2 = 601^2 - 2*425^2 = -49. (End)
		

Crossrefs

Programs

  • Magma
    I:=[13, 73]; [n le 2 select I[n] else 6*Self(n-1) - Self(n-2): n in [1..25]]; // Vincenzo Librandi, Feb 01 2013
  • Maple
    with(orthopoly): a := n -> `if`(n=1,13,13*U(n-1,3)-5*U(n-2,3)):
    seq(a(n),n=1..22); # (after Wolfdieter Lang) Peter Luschny, Feb 07 2015
  • Mathematica
    t = {13, 73}; Do[AppendTo[t, 6*t[[-1]] - t[[-2]]], {30}]; t (* T. D. Noe, Dec 20 2012 *)
    LinearRecurrence[{6,-1},{13,73},40] (* Harvey P. Dale, Jan 26 2013 *)

Formula

a(n) = A078343(n)^2 + A078343(n+1)^2 = A060569(2*n-1).
G.f.: (13-5*x)/(x^2-6*x+1). - Harvey P. Dale, Jan 26 2013
From Wolfdieter Lang, Feb 07 2015: (Start)
a(n) = 13*S(n-1, 6) - 5*S(n-2, 6), n >= 1, with Chebyshev's S-polynomials evaluated at x = 6 (see A049310).
a(n) = 6*a(n-1) - a(n-2), n >= 2, with a(0) = 5 and a(1) = 13.
a(n) = irrational part of z(n), where z(n) = (-1+5*sqrt(2))*(3+2*sqrt(2))^n, n >= 1. (End)

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

Original entry on oeis.org

2, 2, 1, 3, 4, 8, 9, 19, 22, 46, 53, 111, 128, 268, 309, 647, 746, 1562, 1801, 3771, 4348, 9104, 10497, 21979, 25342, 53062, 61181, 128103, 147704, 309268, 356589, 746639, 860882, 1802546, 2078353, 4351731, 5017588, 10506008, 12113529, 25363747, 29244646, 61233502
Offset: 0

Views

Author

Raphie Frank, Dec 30 2015

Keywords

Comments

This sequence gives all x in N | 2*x^2 - 7(-1)^x = y^2. The companion sequence to this sequence, giving y values, is A266505.
A266505(n)/a(n) converges to sqrt(2).
Alternatively, 1/4*(3*A002203(floor[n/2]) - A002203(n-(-1)^n)), where A002203 gives the Companion Pell numbers, or, in Lucas sequence notation, V_n(2, -1).
Alternatively, bisection of A266506.
Alternatively, A048654(n -1) and A078343(n + 1) interlaced.
Alternatively, A100525(n-1), A266507(n), A038761(n) and A253811(n) interlaced.
Let b(n) = (a(n) - a(n)(mod 2))/2, that is b(n) = {1, 1, 0, 1, 2, 4, 4, 9, 11, 23, 26, 55, 64, ...}. Then:
A006452(n) = {b(4n+0) U b(4n+1)} gives n in N such that n^2 - 1 is triangular;
A216134(n) = {b(4n+2) U b(4n+3)} gives n in N such that n^2 + n + 1 is triangular (indices of Sophie Germain triangular numbers);
A216162(n) = {b(4n+0) U b(4n+2) U b(4n+1) U b(4n+3)}, sequences A006452 and A216134 interlaced.

Crossrefs

Programs

  • Magma
    I:=[2,2,1,3]; [n le 4 select I[n] else 2*Self(n-2)+Self(n-4): n in [1..70]]; // Vincenzo Librandi, Dec 31 2015
    
  • Mathematica
    LinearRecurrence[{0, 2, 0, 1}, {2, 2, 1, 3}, 70] (* Vincenzo Librandi, Dec 31 2015 *)
    Table[SeriesCoefficient[(1 - x) (2 + 4 x + x^2)/(1 - 2 x^2 - x^4), {x, 0, n}], {n, 0, 41}] (* Michael De Vlieger, Dec 31 2015 *)
  • PARI
    Vec((1-x)*(2+4*x+x^2)/(1-2*x^2-x^4) + O(x^50)) \\ Colin Barker, Dec 31 2015

Formula

a(n) = 1/sqrt(8)*(+sqrt(2)*(1+sqrt(2))^(floor(n/2)-(-1)^n)*(-1)^n - 3*(1-sqrt(2))^(floor(n/2)-(-1)^n) + sqrt(2)*(1-sqrt(2))^(floor(n/2)-(-1)^n)*(-1)^n + 3*(1+sqrt(2))^(floor(n/2)-(-1)^n)).
a(n) = 1/4*((3*((1+sqrt(2))^floor(n/2)+(1-sqrt(2))^floor(n/2))) - (-1)^n*((1+sqrt(2))^(floor(n/2)-(-1)^n)+(1-sqrt(2))^(floor(n/2)-(-1)^n))).
a(2n) = (+sqrt(2)*(1+sqrt(2))^(n-1) - 3 *(1-sqrt(2))^(n-1) + sqrt(2)*(1-sqrt(2))^(n-1) + 3*(1 + sqrt(2))^(n-1))/sqrt(8) = A048654(n -1).
a(2n) = 1/4*((3*((1+sqrt(2))^n+(1-sqrt(2))^n)) - ((1+sqrt(2))^(n-1)+(1-sqrt(2))^(n-1))) = A048654(n -1).
a(2n + 1) = (-sqrt(2)*(1+sqrt(2))^(n+1) - 3 *(1-sqrt(2))^(n+1) - sqrt(2)*(1-sqrt(2))^(n+1) + 3*(1+sqrt(2))^(n+1))/sqrt(8) = A078343(n + 1).
a(2n + 1) =1/4*((3*((1+sqrt(2))^n+(1-sqrt(2))^n)) + ((1+sqrt(2))^(n+1)+(1-sqrt(2))^(n+1))) = A078343(n + 1).
a(4n + 0) = 6*a(4n - 4) - a(4n - 8) = A100525(n-1).
a(4n + 1) = 6*a(4n - 3) - a(4n - 7) = A266507(n).
a(4n + 2) = 6*a(4n - 2) - a(4n - 6) = A038761(n).
a(4n + 3) = 6*a(4n - 1) - a(4n - 5) = A253811(n).
sqrt(2*a(n)^2 - 7(-1)^a(n))*sgn(2*n - 1) = A266505(n).
(a(2n + 1) + a(2n))/2 = A002203(n), where A002203 gives the companion Pell numbers.
(a(2n + 1) - a(2n))/2 = A000129(n), where A000129 gives the Pell numbers.
(a(2n+2) + a(2n+1))*2 = A002203(n+2)
(a(2n+2) - a(2n+1))*2 = A002203(n-1).
G.f.: (1-x)*(2+4*x+x^2) / (1-2*x^2-x^4). - Colin Barker, Dec 31 2015

A266505 a(n) = 2*a(n - 2) + a(n - 4) with a(0) = -1, a(1) = 1, a(2) = 3, a(3) = 5.

Original entry on oeis.org

-1, 1, 3, 5, 5, 11, 13, 27, 31, 65, 75, 157, 181, 379, 437, 915, 1055, 2209, 2547, 5333, 6149, 12875, 14845, 31083, 35839, 75041, 86523, 181165, 208885, 437371, 504293, 1055907, 1217471, 2549185, 2939235, 6154277, 7095941, 14857739, 17131117, 35869755, 41358175, 86597249, 99847467
Offset: 0

Views

Author

Raphie Frank, Dec 30 2015

Keywords

Comments

a(n)/A266504(n) converges to sqrt(2).
Alternatively, bisection of A266506.
Alternatively, A135532(n) and A048655(n) interlaced.
Alternatively, A255236(n-1), A054490(n), A038762(n) and A101386(n) interlaced.
Let b(n) = (a(n) - (a(n) mod 2))/2, that is b(n) = {-1, 0, 1, 2, 2, 5, 6, 13, 15, 32, 37, 78, 90, ...}. Then:
A006451(n) = {b(4n+0) U b(4n+1)} gives n in N such that triangular(n) + 1 is square;
A216134(n) = {b(4n+2) U b(4n+3)} gives n in N such that triangular(n) follows form n^2 + n + 1 (twice a triangular number + 1).

Crossrefs

Programs

  • Magma
    I:=[-1,1,3,5]; [n le 4 select I[n] else 2*Self(n-2)+Self(n-4): n in [1..70]]; // Vincenzo Librandi, Dec 31 2015
    
  • Maple
    a:=proc(n) option remember; if n=0 then -1 elif n=1 then 1 elif n=2 then 3 elif n=3 then 5 else 2*a(n-2)+a(n-4); fi; end:  seq(a(n), n=0..50); # Wesley Ivan Hurt, Jan 01 2016
  • Mathematica
    LinearRecurrence[{0, 2, 0, 1}, {-1, 1, 3, 5}, 70] (* Vincenzo Librandi, Dec 31 2015 *)
    Table[SeriesCoefficient[(-1 + 3 x) (1 + x)^2/(1 - 2 x^2 - x^4), {x, 0, n}], {n, 0, 42}] (* Michael De Vlieger, Dec 31 2015 *)
  • PARI
    my(x='x+O('x^40)); Vec((-1+3*x)*(1+x)^2/(1-2*x^2-x^4)) \\ G. C. Greubel, Jul 26 2018

Formula

G.f.: (-1 + 3*x)*(1 + x)^2/(1 - 2*x^2 - x^4).
a(n) = (-(1+sqrt(2))^floor(n/2)*(-1)^n - sqrt(8)*(1-sqrt(2))^floor(n/2) - (1-sqrt(2))^floor(n/2)*(-1)^n + sqrt(8)*(1+sqrt(2))^floor(n/2))/2.
a(n) = 3*(((1+sqrt(2))^floor(n/2)-(1-sqrt(2))^floor(n/2))/sqrt(8)) - (-1)^n*(((1+sqrt(2))^(floor(n/2)-(-1)^n)-(1-sqrt(2))^(floor(n/2)-(-1)^n))/sqrt(8)).
a(n) = (3*A000129(floor(n/2)) - A000129(n-(-1)^n)), where A000129 gives the Pell numbers.
a(n) = sqrt(2*A266504(n)^2 - 7*(-1)^A266504(n))*sgn(2*n-1), where A266504 gives all x in N such that 2*x^2 - 7*(-1)^x = y^2. This sequence gives associated y values.
a(2n) = (-(1 + sqrt(2))^n - sqrt(8)*(1 - sqrt(2))^n - (1 - sqrt(2))^n + sqrt(8)*(1 + sqrt(2))^n)/2 = a(2n) = A135532(n).
a(2n) = 3*(((1+sqrt(2))^n-(1-sqrt(2))^n)/sqrt(8)) - (((1+sqrt(2))^(n-1)-(1-sqrt(2))^(n-1))/sqrt(8)) = A135532(n).
a(2n+1) = (+(1 + sqrt(2))^n - sqrt(8)*(1 - sqrt(2))^n + (1 - sqrt(2))^n + sqrt(8)*(1 + sqrt(2))^n)/2 = a(2n + 1) = A048655(n).
a(2n+1) = 3*(((1+sqrt(2))^n-(1-sqrt(2))^n)/sqrt(8)) + (((1+sqrt(2))^(n+1)-(1-sqrt(2))^(n+1))/sqrt(8)) = A048655(n).
a(4n + 0) = 6*a(4n - 4) - a(4n - 8) = A255236(n-1).
a(4n + 1) = 6*a(4n - 3) - a(4n - 7) = A054490(n).
a(4n + 2) = 6*a(4n - 2) - a(4n - 6) = A038762(n).
a(4n + 3) = 6*a(4n - 1) - a(4n - 5) = A101386(n).
(sqrt(2*(a(2n + 1) )^2 + 14*(-1)^floor(n/2)))/2 = A266504(n).
(a(2n + 1) + a(2n))/8 = A000129(n), where A000129 gives the Pell numbers.
a(2n + 1) - a(2n) = A002203(n), where A002203 gives the companion Pell numbers.
(a(2n + 2) + a(2n + 1))/2 = A000129(n+2).
(a(2n + 2) - a(2n + 1))/2 = A000129(n-1).

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

Original entry on oeis.org

2, 8, 46, 268, 1562, 9104, 53062, 309268, 1802546, 10506008, 61233502, 356895004, 2080136522, 12123924128, 70663408246, 411856525348, 2400475743842, 13990997937704, 81545511882382, 475282073356588, 2770146928257146, 16145599496186288, 94103450048860582
Offset: 0

Views

Author

Raphie Frank, Dec 30 2015

Keywords

Comments

Bisection of A078343 = A078343(2*n + 1).
Quadrisection of A266504 = A266504(4*n + 1).
Octasection of A266506 = A266506(8*n + 2).

Crossrefs

Bisection of A078343 = A078343(2n + 1).
Quadrisection of A266504 = A266504(4n + 1).
Octasection of A266506 = A266506(8n + 2).
Equals 2*A038723(n).

Programs

  • Magma
    I:=[2,8]; [n le 2 select I[n] else 6*Self(n-1)-Self(n-2): n in [1..70]]; // Vincenzo Librandi, Dec 31 2015
    
  • Mathematica
    LinearRecurrence[{6, -1}, {2, 8}, 70] (* Vincenzo Librandi, Dec 31 2015 *)
    Table[SeriesCoefficient[2 (1 - 2 x)/(1 - 6 x + x^2), {x, 0, n}], {n, 0, 22}] (* Michael De Vlieger, Dec 31 2015 *)
  • PARI
    Vec(2*(1-2*x)/(1-6*x+x^2) + O(x^30)) \\ Colin Barker, Dec 31 2015

Formula

a(n) = (-sqrt(2)*(1+sqrt(2))^(2*n+1) - 3 *(1-sqrt(2))^(2*n+1) - sqrt(2)*(1-sqrt(2))^(2*n+1) + 3*(1+sqrt(2))^(2*n+1))/sqrt(8).
G.f.: 2*(1-2*x) / (1-6*x+x^2). - Colin Barker, Dec 31 2015

A117894 Triangle, row sums = Pell numbers, A000129.

Original entry on oeis.org

1, 1, 1, 1, 2, 2, 1, 3, 3, 5, 1, 4, 4, 8, 12, 1, 5, 5, 11, 19, 29, 1, 6, 6, 14, 26, 46, 70, 1, 7, 7, 17, 33, 63, 111, 169, 1, 8, 8, 20, 40, 80, 152, 268, 408, 1, 9, 9, 23, 47, 97, 193, 367, 647, 985
Offset: 0

Views

Author

Gary W. Adamson, Mar 30 2006

Keywords

Comments

Deleting the right border gives triangle A117895.

Examples

			First few rows of the triangle are:
  1;
  1, 1;
  1, 2, 2;
  1, 3, 3,  5;
  1, 4, 4,  8, 12;
  1, 5, 5, 11, 19, 29;
  1, 6, 6, 14, 26, 46,  70;
  1, 7, 7, 17, 33, 63, 111, 169;
...
Row 4 of A117584 = (1, 4, 7, 12). Difference terms (1, 3, 3, 5) = row 4 of A117894.
		

Crossrefs

Programs

  • Magma
    Pell:= func< n | Round(((1+Sqrt(2))^n - (1-Sqrt(2))^n)/(2*Sqrt(2))) >;
    [k eq 0 select 1 else (k-n)*Pell(k+1) + (3*n-3*k+1)*Pell(k): k in [0..n], n in [0..12]]; // G. C. Greubel, Sep 27 2021
    
  • Mathematica
    T[n_, k_]:= T[n, k]= If[k==0, 1, (k-n)*Fibonacci[k+1, 2] + (3*n-3*k+1)*Fibonacci[k, 2]]; Table[T[n, k], {n,0,12}, {k,0,n}]//Flatten (* G. C. Greubel, Sep 27 2021 *)
  • Sage
    def P(n): return lucas_number1(n, 2, -1)
    def A117894(n,k): return 1 if (k==0) else (k-n)*P(k+1) + (3*n-3*k+1)*P(k)
    flatten([[A117894(n,k) for k in (0..n)] for n in (0..12)]) # G. C. Greubel, Sep 27 2021

Formula

Rows are composed of difference terms of triangle A117584.
Rows sum to Pell numbers, A000129.
From G. C. Greubel, Sep 27 2021: (Start)
T(n, k) = (k-n)*A000129(k+1) + (3*n-3*k+1)*A000129(k) with T(n,0) = 1.
T(n, k) = A117584(n+1, k+1) - A117584(n+1, k) with T(n, 0) = 1.
T(n, 1) = n for n >= 1.
T(n, 2) = n for n >= 2.
T(n, n) = [n=0] + A000129(n).
T(n, n-1) = 2*[n=0] + A078343(n). (End)

A117895 Triangle T(n, k) = (k-n)*A000129(k+1) + (3*n-3*k+1)*A000129(k) with T(n,0) = 1, for 0 <= k <= n-1, read by rows.

Original entry on oeis.org

1, 1, 2, 1, 3, 3, 1, 4, 4, 8, 1, 5, 5, 11, 19, 1, 6, 6, 14, 26, 46, 1, 7, 7, 17, 33, 63, 111, 1, 8, 8, 20, 40, 80, 152, 268, 1, 9, 9, 23, 47, 97, 193, 367, 647, 1, 10, 10, 26, 54, 114, 234, 466, 886, 1562, 1, 11, 11, 29, 61, 131, 275, 565, 1125, 2139, 3771, 1, 12, 12, 32, 68, 148, 316, 664, 1364, 2716, 5164, 9104
Offset: 0

Views

Author

Gary W. Adamson, Mar 30 2006

Keywords

Comments

Successive deletions of the right borders of triangle A117894 produces triangles whose row sums = generalized Pell sequences starting (1, 2...), (1, 3...), (1, 4...); etc. Row sums of A117894 = A000129: (1, 2, 5...). Row sums of A117895 = A001333: (1, 3, 7...). Deletion of the border of A117895 would produce a triangle with row sums of the Pell sequence A048654 (1, 4, 9...); and so on.

Examples

			First few rows of the triangle are:
  1;
  1, 2;
  1, 3, 3;
  1, 4, 4,  8;
  1, 5, 5, 11, 19;
  1, 6, 6, 14, 26, 46;
  1, 7, 7, 17, 33, 63, 111;
  1, 8, 8, 20, 40, 80, 152, 268;
...
Row 4, (1, 4, 4, 8) is produced by adding (0, 1, 1, 3) to row 4 of A117894: (1, 3, 3, 5).
		

Crossrefs

Programs

  • Magma
    Pell:= func< n | Round(((1+Sqrt(2))^n - (1-Sqrt(2))^n)/(2*Sqrt(2))) >;
    [k eq 0 select 1 else (k-n)*Pell(k+1) + (3*n-3*k+1)*Pell(k): k in [0..n-1], n in [0..12]]; // G. C. Greubel, Sep 27 2021
    
  • Mathematica
    T[n_, k_]:= T[n, k]= If[k==0, 1, (k-n)*Fibonacci[k+1, 2] + (3*n-3*k +1)*Fibonacci[k, 2]]; Table[T[n, k], {n,0,12}, {k,0,n-1}]//Flatten (* G. C. Greubel, Sep 27 2021 *)
  • Sage
    def P(n): return lucas_number1(n, 2, -1)
    def A117895(n,k): return 1 if (k==0) else (k-n)*P(k+1) + (3*n-3*k+1)*P(k)
    flatten([[A117895(n,k) for k in (0..n-1)] for n in (0..12)]) # G. C. Greubel, Sep 27 2021

Formula

Delete right border of triangle A117894. Alternatively, let row 1 = 1 and using the heading 0, 1, 1, 3, 7, 17, 41, 99, 239...(i.e. A001333 starting with 0, 1, 1, 3...); add the first n terms of the heading to n-th row of triangle A117894.
From G. C. Greubel, Sep 27 2021: (Start)
T(n, k) = (k-n)*A000129(k+1) + (3*n-3*k+1)*A000129(k) with T(n,0) = 1.
T(n, 1) = n+1 for n >= 1.
T(n, 2) = n+1 for n >= 2.
T(n, n) = 2*[n=0] + A078343(n). (End)

Extensions

New name and more terms added by G. C. Greubel, Sep 27 2021

A135139 a(n) = 5*a(n-2) + 2*a(n-3).

Original entry on oeis.org

1, 2, 4, 12, 24, 68, 144, 388, 856, 2228, 5056, 12852, 29736, 74372, 174384, 431332, 1020664, 2505428, 5965984, 14568468, 34840776, 84774308, 203340816, 493553092, 1186252696, 2874447092, 6918369664, 16744740852, 40340742504, 97560443588
Offset: 0

Views

Author

Paul Curtz, Feb 13 2008

Keywords

Crossrefs

Cf. A135138.

Programs

  • Mathematica
    a = {1, 2, 4}; Do[AppendTo[a, 5*a[[ -2]] + 2*a[[ -3]]], {40}]; a (* Stefan Steinerberger, Feb 15 2008 *)
    LinearRecurrence[{0,5,2},{1,2,4},30] (* Harvey P. Dale, May 25 2012 *)

Formula

From R. J. Mathar, Feb 15 2008: (Start)
O.g.f.: 4*(x-2)/(7*(x^2+2*x-1)) - 1/(7*(1+2*x)).
a(n) = (4*A078343(n+1)-(-2)^n)/7.
a(n) = A135138(n+2) + 2*A135138(n+1) - A135138(n). (End)

Extensions

More terms from R. J. Mathar and Stefan Steinerberger, Feb 15 2008

A217975 Integers k such that 2*k^2 - 7 is a square.

Original entry on oeis.org

2, 4, 8, 22, 46, 128, 268, 746, 1562, 4348, 9104, 25342, 53062, 147704, 309268, 860882, 1802546, 5017588, 10506008, 29244646, 61233502, 170450288, 356895004, 993457082, 2080136522, 5790292204, 12123924128, 33748296142, 70663408246, 196699484648
Offset: 1

Views

Author

Sture Sjöstedt, Oct 16 2012

Keywords

Comments

a(n) gives y-values solving the Diophantine equation x^2 + 7 = 2*y^2. A077446(n) gives the x-values. - Sture Sjöstedt, Oct 16 2012
Positive values of x (or y) satisfying x^2 - 6xy + y^2 + 28 = 0. - Colin Barker, Feb 08 2014

Examples

			Since 2(4^2) - 7 = 25 = 5^2, and 4 is the second number with this property, a(2) = 4.
		

Crossrefs

Cf. A077442 (2*n^2 + 7 is a square).

Programs

  • Magma
    I:=[2, 4, 8, 22]; [n le 4 select I[n] else 6*Self(n-2)-Self(n-4): n in [1..31]]; // Vincenzo Librandi, Oct 16 2012
    
  • Mathematica
    LinearRecurrence[{0, 6, 0, -1}, {2, 4, 8, 22}, 50] (* Sture Sjöstedt, Oct 16 2012 *)
  • PARI
    Vec(2*x*(1-x)*(x^2+3*x+1)/(x^2-2*x-1)/(x^2+2*x-1)+O(x^99)) \\ Charles R Greathouse IV, Oct 24 2012

Formula

a(n) = 6*a(n - 2) - a(n - 4) with a(1)=2, a(2)=4, a(3)=8, a(4)=22. - Sture Sjöstedt, Oct 16 2012
a(n)*a(n+3)-a(n+1)*a(n+2) = 10-2*(-1)^n. - Bruno Berselli, Oct 25 2012
a(n) = 2*A006452(n). - R. J. Mathar, Oct 17 2012
G.f.: -2*x*(x - 1)*(x^2 + 3*x + 1)/((x^2 - 2*x - 1)*(x^2 + 2*x - 1)). - Colin Barker, Oct 24 2012
a(n) = a(-n+1) = ((4+sqrt(2))*(1-(-1)^n*sqrt(2))^(2*floor(n/2))+(4-sqrt(2))*(1+(-1)^n*sqrt(2))^(2*floor(n/2)))/4. - Bruno Berselli, Oct 25 2012
a(2n-1) = A078343(2n-1), a(2n) = A100525(n-1). - Bruno Berselli, Oct 25 2012
Previous Showing 11-20 of 21 results. Next