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

A216162 Sequences A006452 and A216134 interlaced.

Original entry on oeis.org

1, 0, 1, 1, 2, 4, 4, 9, 11, 26, 23, 55, 64, 154, 134, 323, 373, 900, 781, 1885, 2174, 5248, 4552, 10989, 12671, 30590, 26531, 64051, 73852, 178294, 154634, 373319, 430441, 1039176, 901273, 2175865, 2508794, 6056764, 5253004, 12681873, 14622323, 35301410
Offset: 0

Views

Author

Raphie Frank, Sep 07 2012

Keywords

Crossrefs

Cf. A000129.
For some k in n:
a(2n) = A006452 (k^2 - 1 is triangular).
a(2n + 1) = A216134 (T_k and 2T_k + 1 are triangular).
a(2n + 1) - a(2n) = A006451 (T_k + 1 is square).
a(2n + 1) + a(2n) = A124124 (T_k and (T_k - 1)/2 are triangular).
a(4n + 1) + a(4n + 2) = A001108 (T_k is square).
a(4n + 3) + a(4n + 4) = A001652 (T_k and 2T_k are triangular).
Sum(a(n)) - 1 = A048776 for even n (the second partial summation of the Pell numbers).

Programs

  • PARI
    Vec((-1-x^3+5*x^4-3*x^5-2*x^6+x^7-2*x^8+x^9)/((x-1)*(1+x)*(x^4-2*x^2-1)*(x^4+2*x^2-1))+O(x^99)) \\ Charles R Greathouse IV, Jun 12 2015

Formula

(a(2n) + a(2n - 1)) - (a(2n - 2) + a(2n - 3)) = A000129(n); n>1.
It follows that sqrt(2) = lim n --> infinity ((a(2n + 2) + a(2n + 1)) - (a(2n - 2) + a(2n - 3)))/((a(2n + 2) + a(2n + 1)) - (a(2n) + a(2n - 1))).
G.f. ( -1-x^3+5*x^4-3*x^5-2*x^6+x^7-2*x^8+x^9 ) / ( (x-1)*(1+x)*(x^4-2*x^2-1)*(x^4+2*x^2-1) ). - R. J. Mathar, Sep 08 2012

Extensions

Edited by N. J. A. Sloane, May 24 2021

A006452 a(n) = 6*a(n-2) - a(n-4).

Original entry on oeis.org

1, 1, 2, 4, 11, 23, 64, 134, 373, 781, 2174, 4552, 12671, 26531, 73852, 154634, 430441, 901273, 2508794, 5253004, 14622323, 30616751, 85225144, 178447502, 496728541, 1040068261, 2895146102, 6061962064, 16874148071, 35331704123
Offset: 0

Views

Author

Keywords

Comments

Solution to a Diophantine equation.
Integers k such that k^2-1 is a triangular number. - Benoit Cloitre, Apr 05 2002
For all elements "x" of the sequence, 8*x^2 - 7 is a square. - Gregory V. Richardson, Oct 07 2002
a(n) mod 10 is a sequence of period 12: repeat (1, 1, 2, 4, 1, 3, 4, 4, 3, 1, 4, 2). - Paul Curtz, Dec 07 2012
a(n)^2 - 1 = A006454(n - 1) is a Sophie Germain triangular number of the second kind as defined in A217278. - Raphie Frank, Feb 08 2013
Except for the first term, positive values of x (or y) satisfying x^2 - 6xy + y^2 + 7 = 0. - Colin Barker, Feb 04 2014
Except for the first term, positive values of x (or y) satisfying x^2 - 34xy + y^2 + 252 = 0. - Colin Barker, Mar 04 2014
From Wolfdieter Lang, Feb 26 2015: (Start)
a(n+1), for n >= 0, gives one half of all positive y solutions of the Pell equation x^2 - 2*y^2 = -7. The corresponding x-solutions are x(n) = A077446(n+1).
See a comment on A077446 for the first and second class solutions separately, and the connection to the Pell equation X^2 - 2*Y^2 = 14. (End)
For n > 0, a(n) is the n-th almost balancing number of second type (see Tekcan and Erdem). - Stefano Spezia, Nov 26 2022

Examples

			n = 3: 11^2 - 2*(2*4)^2 = -7 (see the Pell comment above);
(4*4)^2 - 2*11^2 = +14. - _Wolfdieter Lang_, Feb 26 2015
		

References

  • A. J. Gottlieb, How four dogs meet in a field, etc., Technology Review, Jul/Aug 1973 pp. 73-74.
  • Jeffrey Shallit, personal communication.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

  • Magma
    I:=[1,1,2,4]; [n le 4 select I[n] else 6*Self(n-2)-Self(n-4): n in [1..30]]; // Vincenzo Librandi, Jun 09 2013
    
  • Maple
    A006452:=-(z-1)*(z**2+3*z+1)/(z**2+2*z-1)/(z**2-2*z-1); # conjectured by Simon Plouffe in his 1992 dissertation; gives sequence except for one of the leading 1's
  • Mathematica
    s=0;lst={1}; Do[s+=n;If[Sqrt[s+1]==Floor[Sqrt[s+1]],AppendTo[lst, Sqrt[s+1]]], {n,0,8!}]; lst (* Vladimir Joseph Stephan Orlovsky, Apr 02 2009 *)
    a[0]=a[1]= 1; a[2]=2; a[3]=4; a[n_]:= 6*a[n-2] -a[n-4]; Array[a, 30, 0] (* Robert G. Wilson v, Jun 11 2010 *)
    CoefficientList[Series[(1+x-4x^2-2x^3)/((1-2x-x^2)(1+2x-x^2)), {x, 0, 50}], x] (* Vincenzo Librandi, Jun 09 2013 *)
  • PARI
    a(n)=([0,1,0,0; 0,0,1,0; 0,0,0,1; -1,0,6,0]^n*[1;1;2;4])[1,1] \\ Charles R Greathouse IV, May 10 2016
    
  • SageMath
    def A001333(n): return lucas_number2(n, 2, -1)/2
    def A006452(n): return (A001333(n+1) + (-1)^n *A001333(n-2))/4
    [A006452(n) for n in range(41)] # G. C. Greubel, Jan 22 2023

Formula

Bisection: a(2n) = A006452(n). a(2n+1) = A038723(n).
G.f.: ( 1+x-4*x^2-2*x^3 ) / ( (1-2*x-x^2)*(1+2*x-x^2) ).
From Gregory V. Richardson, Oct 07 2002: (Start)
For n (even), a(n) = ( ((3 + sqrt(8))^((n/2)+1) - (3 - sqrt(8))^((n/2)+1)) - 2*((3 + sqrt(8))^((n/2)-1) - (3 - sqrt(8))^((n/2)-1)) ) / (6*sqrt(8)).
For n (odd), a(n) = ( ((3 + sqrt(8))^((n+1)/2) - (3 - sqrt(8))^((n+1)/2)) - 2*((3 + sqrt(8))^((n-1)/2) - (3 - sqrt(8))^((n-1)/2)) ) / (2*sqrt(8)).
Limit_{n->oo} a(n)/a(n-2) = 3 + sqrt(8).
If n is odd, lim_{n->oo} a(n)/a(n-1) = (9 + 2*sqrt(8))/7.
If n is even, lim_{n->oo} a(n)/a(n-1) = (11 + 3*sqrt(8))/7. (End)
a(n+2) = (A001333(n+3) + (-1)^n *A001333(n))/4. - Paul Curtz, Dec 06 2012
a(n+2) = sqrt(17*a(n)^2 + 6*(sqrt(8*a(n)^2 - 7))*a(n)*sgn(2*n - 1) - 7) with a(0) = 1, a(1) = 1. - Raphie Frank, Feb 08 2013
a(n+2) = (A216134(n+2) - A216134(n))/2. - Raphie Frank, Feb 11 2013
E.g.f.: (2*cosh(sqrt(2)*x)*(2*cosh(x) - sinh(x)) + sqrt(2)*(3*cosh(x) - sinh(x))*sinh(sqrt(2)*x))/4. - Stefano Spezia, Nov 26 2022

Extensions

More terms from James Sellers, May 03 2000

A006454 Solution to a Diophantine equation: each term is a triangular number and each term + 1 is a square.

Original entry on oeis.org

0, 3, 15, 120, 528, 4095, 17955, 139128, 609960, 4726275, 20720703, 160554240, 703893960, 5454117903, 23911673955, 185279454480, 812293020528, 6294047334435, 27594051024015, 213812329916328, 937385441796000, 7263325169820735, 31843510970040003, 246739243443988680
Offset: 0

Views

Author

Keywords

Comments

Alternative definition: a(n) is triangular and a(n)/2 is the harmonic average of consecutive triangular numbers. See comments and formula section of A005563, of which this sequence is a subsequence. - Raphie Frank, Sep 28 2012
As with the Sophie Germain triangular numbers (A124174), 35 = (a(n) - a(n-6))/(a(n-2) - a(n-4)). - Raphie Frank, Sep 28 2012
Sophie Germain triangular numbers of the second kind as defined in A217278. - Raphie Frank, Feb 02 2013
Triangular numbers m such that m+1 is a square. - Bruno Berselli, Jul 15 2014
From Vladimir Pletser, Apr 30 2017: (Start)
Numbers a(n) which are the triangular number T(b(n)), where b(n) is the sequence A006451(n) of numbers n such that T(n)+1 is a square.
a(n) also gives the x solutions of the 3rd-degree Diophantine Bachet-Mordell equation y^2 = x^3 + K, with y = T(b(n))*sqrt(T(b(n))+1) = A285955(n) and K = T(b(n))^2 = A285985(n), the square of the triangular number of b(n) = A006451(n).
Also: This sequence is a subsequence of A000217(n), namely A000217(A006451(n)). (End)

Examples

			From _Raphie Frank_, Sep 28 2012: (Start)
35*(528 - 15) + 0 = 17955 = a(6),
35*(4095 - 120) + 3 = 139128 = a(7),
35*(17955 - 528) + 15 = 609960 = a(8),
35*(139128 - 4095) + 120 = 4726275 = a(9). (End)
From _Raphie Frank_, Feb 02 2013: (Start)
a(7) = 139128 and a(9) = 4726275.
a(9) = (2*(sqrt(8*a(7) + 1) - 1)/2 + 3*sqrt(a(7) + 1) + 1)^2 - 1 = (2*(sqrt(8*139128 + 1) - 1)/2 + 3*sqrt(139128 + 1) + 1)^2 - 1 = 4726275.
a(9) = 1/2*((3*(sqrt(8*a(7) + 1) - 1)/2 + 4*sqrt(a(7) + 1) + 1)^2 + (3*(sqrt(8*a(7) + 1) - 1)/2 + 4*sqrt(a(7) + 1) + 1)) = 1/2*((3*(sqrt(8*139128 + 1) - 1)/2 + 4*sqrt(139128 + 1) + 1)^2 + (3*(sqrt(8*139128 + 1) - 1)/2 + 4*sqrt(139128 + 1) + 1)) = 4726275. (End)
From _Vladimir Pletser_, Apr 30 2017: (Start)
For n=2, b(n)=5, a(n)=15
For n=5, b(n)=90, a(n)= 4095
For n = 3, A006451(n) = 15. Therefore, A000217(A006451(n)) = A000217(15) = 120. (End)
		

References

  • Edward J. Barbeau, Pell's Equation, New York: Springer-Verlag, 2003, p. 17, Exercise 1.2.
  • Allan J. Gottlieb, How four dogs meet in a field, and other problems, Technology Review, Jul/August 1973, pp. 73-74.
  • Vladimir Pletser, On some solutions of the Bachet-Mordell equation for large parameter values, to be submitted, April 2017.
  • Jeffrey Shallit, personal communication.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Cf. sqrt(a(n) + 1) = A006452(n + 1) = A216162(2n + 2) and (sqrt(8a(n) + 1) - 1)/2 = A006451.
Cf. A217278, A124174, A216134. - Raphie Frank, Feb 02 2013
Subsequence of A182334.

Programs

  • Magma
    I:=[0,3,15,120,528,4095]; [n le 6 select I[n] else 35*(Self(n-2) - Self(n-4)) + Self(n-6): n in [1..30]]; // Vincenzo Librandi, Dec 21 2015
    
  • Maple
    A006454:=-3*z*(1+4*z+z**2)/(z-1)/(z**2-6*z+1)/(z**2+6*z+1); # conjectured (correctly) by Simon Plouffe in his 1992 dissertation
    restart: bm2:=-1: bm1:=0: bp1:=2: bp2:=5: print ('0,0','1,3','2,15'); for n from 3 to 1000 do b:= 8*sqrt((bp1^2+bp1)/2+1)+bm2; a:=b*(b+1)/2; print(n,a); bm2:=bm1; bm1:=bp1; bp1:=bp2; bp2:=b; end do: # Vladimir Pletser, Apr 30 2017
  • Mathematica
    Clear[a]; a[0] = a[1] = 1; a[2] = 2; a[3] = 4; a[n_] := 6a[n - 2] - a[n - 4]; Array[a, 40]^2 - 1 (* Vladimir Joseph Stephan Orlovsky, Mar 03 2011 *)
    LinearRecurrence[{1,34,-34,-1,1},{0,3,15,120,528},30] (* Harvey P. Dale, Feb 18 2023 *)
  • PARI
    concat(0, Vec(3*x*(1 + 4*x + x^2) / ((1 - x)*(1 - 6*x + x^2)*(1 + 6*x + x^2)) + O(x^30))) \\ Colin Barker, Apr 30 2017

Formula

a(n) = A006451(n)*(A006451(n)+1)/2.
a(n) = A006452(n)^2 - 1. - Joerg Arndt, Mar 04 2011
a(n) = 35*(a(n-2) - a(n-4)) + a(n-6). - Raphie Frank, Sep 28 2012
From Raphie Frank, Feb 01 2013: (Start)
a(0) = 0, a(1) = 3, and a(n+2) = (2x + 3y + 1)^2 - 1 = 1/2*((3x + 4y + 1)^2 + (3x + 4y + 1)) where x = (sqrt(8*a(n) + 1) - 1)/2 = A006451(n) = 1/2*(A216134(n + 1) + A216134(n - 1)) and y = sqrt(a(n) + 1) = A006452(n + 1) = 1/2*(A216134(n + 1) - A216134(n - 1)).
Note that A216134(n + 1) = x + y, and A216134(n + 3) = (2x + 3y + 1) + (3x + 4y + 1) = (5x + 7y + 2), where A216134 gives the indices of the Sophie Germain triangular numbers. (End)
a(n) = (1/64)*(((4 + sqrt(2))*(1 -(-1)^(n+1)*sqrt(2))^(2* floor((n+1)/2)) + (4 - sqrt(2))*(1 + (-1)^(n+1)*sqrt(2))^(2*floor((n+1)/2))))^2 - 1. - Raphie Frank, Dec 20 2015
From Vladimir Pletser, Apr 30 2017: (Start)
Since b(n) = 8*sqrt(T(b(n-2))+1)+ b(n-4) = 8*sqrt((b(n-2)*(b(n-2)+1)/2)+1)+ b(n-4), with b(-1)=-1, b(0)=0, b(1)=2, b(2)=5 (see A006451) and a(n) = T(b(n)) (this sequence), we have:
a(n) = ((8*sqrt((b(n-2)*(b(n-2)+1)/2)+1)+ b(n-4))*(8*sqrt((b(n-2)*(b(n-2)+1)/2)+1)+ b(n-4)+1)/2). (End)
From Colin Barker, Apr 30 2017: (Start)
G.f.: 3*x*(1 + 4*x + x^2) / ((1 - x)*(1 - 6*x + x^2)*(1 + 6*x + x^2)).
a(n) = a(n-1) + 34*a(n-2) - 34*a(n-3) - a(n-4) + a(n-5) for n > 4.
(End)
a(n) = (A001109(n/2+1) - 2*A001109(n/2))^2 - 1 if n is even, and (A001109((n+3)/2) - 4*A001109((n+1)/2))^2 - 1 if n is odd (Subramaniam, 1999). - Amiram Eldar, Jan 13 2022

Extensions

Better description from Harvey P. Dale, Jan 28 2001
More terms from Larry Reeves (larryr(AT)acm.org), Feb 07 2001
Minor edits by N. J. A. Sloane, Oct 24 2009

A124174 Sophie Germain triangular numbers tr: 2*tr+1 is also a triangular number.

Original entry on oeis.org

0, 1, 10, 45, 351, 1540, 11935, 52326, 405450, 1777555, 13773376, 60384555, 467889345, 2051297326, 15894464365, 69683724540, 539943899076, 2367195337045, 18342198104230, 80414957735001, 623094791644755, 2731741367653000, 21166880717817451, 92798791542467010
Offset: 1

Views

Author

Zak Seidov, Dec 04 2006

Keywords

Comments

Sophie Germain triangular numbers are one of an infinite number of triangular number sets tr where 2*tn^2*tr + tn is a triangular number: tr and tn both also being triangular numbers with tn being held constant. For the present numbers, a(n) = tr, 8*(2*tr + 1) + 1 = 16*tr + 9 is also a square, the square root of which is 2*y+1 with y being the argument of the triangular number 2*tr + 1. Now (1/2)*(y^2+y) = a^2 + a + 1 from the definition of Sophie Germain triangular numbers. Multiply both sides by 4 and subtract 3 to get 2*y^2 + 2*y - 3 = 4*a^2 + 4*a + 1 (a square). Cf. A124124: Numbers y such that 2*y^2 + 2*y - 3 is a square. The values y are the same y such that 2*y+1 = sqrt(16*tr + 9). - Kenneth J Ramsey, Jun 25 2011
Values of k such that 2*k+1 and 9*k+1 are both triangular numbers. - Colin Barker, Jun 29 2016

Crossrefs

Programs

  • Magma
    I:=[0,1,10,45]; [n le 4 select I[n] else 34*Self(n-2)-Self(n-4)+11: n in [1..30]]; // Vincenzo Librandi, Sep 29 2011
    
  • Maple
    a:= n-> (Matrix([[10, 1, 0, 0, 1]]). Matrix(5, (i, j)-> if i=j-1 then 1 elif j=1 then [1, 34, -34, -1, 1][i] else 0 fi)^n)[1, 4]: seq(a(n), n=1..30); # Alois P. Heinz, Apr 27 2009
  • Mathematica
    LinearRecurrence[{1,34,-34,-1,1}, {0,1,10,45,351},30] (* Harvey P. Dale, Sep 28 2011 *)
  • PARI
    a=[0, 1, 10, 45, 351];for(n=5,20,a=concat(a,a[#a]+34*a[#a-1]- 34*a[#a-2]-a[#a-3]+a[#a-4]));a \\ Charles R Greathouse IV, Sep 29 2011

Formula

a(n) = (A124124(n)^2 + A124124(n)-2)/4.
a(n) = 35*(a(n-2) - a(n-4)) + a(n-6).
From Peter Pein, Dec 04 2006: (Start)
a(n) = -11/32 + (-3 - 2*sqrt(2))^n/64 + (5*(3 - 2*sqrt(2))^n)/32 + (-3 - 2*sqrt(2))^n/(32*sqrt(2)) - (5*(3 - 2*sqrt(2))^n)/(32*sqrt(2)) + (-3 + 2*sqrt(2))^n/64 - (-3 + 2*sqrt(2))^n/(32*sqrt(2)) + (5*(3 + 2*sqrt(2))^n)/32 + (5*(3 + 2*sqrt(2))^n)/(32*sqrt(2));
O.g.f.: (x*(1 + 9*x + x^2))/((1 - x)*(1 - 6*x + x^2)*(1 + 6*x + x^2));
E.g.f.: (-22*exp(x) + exp(-3*x+2*x*sqrt(2))*(1-sqrt(2)) - 5*exp(3*x-2*x*sqrt(2))*(-2 + sqrt(2)) + exp(-3*x-2*x*sqrt(2))*(1+sqrt(2)) + 5*exp(3*x+2*x*sqrt(2))*(2+sqrt(2)))/64. (End)
a(n) = 34*a(n-2) - a(n-4) + 11. - Kieren MacMillan, Nov 08 2008
a(n) = a(n-1) + 34*a(n-2) - 34*a(n-3) - a(n-4) + a(n-5) with a(0)=0, a(1)=1, a(2)=10, a(3)=45, a(4)=351. - Harvey P. Dale, Sep 28 2011
a(n) = x*(x + 1)/2 where x = A216134(n) = (2*A000129(n) + (-1)^n*(A000129(2*floor(n/2) - 1) - (-1)^n)/2). - Raphie Frank, Jan 04 2013
a(n+2) = 1/2*((3/2*sqrt(8*a(n) + 1) + sqrt(16*a(n) + 9) - 1/2)*(3/2*sqrt(8*a(n) + 1) + sqrt(16*a(n) + 9) + 1/2)); a(0) = 0, a(1) = 1. - Raphie Frank, Jan 29 2013

Extensions

More terms from Alois P. Heinz, Apr 27 2009

A077443 Numbers k such that (k^2 - 7)/2 is a square.

Original entry on oeis.org

3, 5, 13, 27, 75, 157, 437, 915, 2547, 5333, 14845, 31083, 86523, 181165, 504293, 1055907, 2939235, 6154277, 17131117, 35869755, 99847467, 209064253, 581953685, 1218515763, 3391874643, 7102030325, 19769294173, 41393666187, 115223890395, 241259966797, 671574048197
Offset: 1

Views

Author

Gregory V. Richardson, Nov 06 2002

Keywords

Comments

Lim_{n -> inf} a(n)/a(n-2) = 3 + 2*sqrt(2) = R1*R2. Lim_{k -> inf} a(2*k-1)/a(2*k) = (9 + 4*sqrt(2))/7 = R1 = A156649 (ratio #1). Lim_{k -> inf} a(2*k)/a(2*k-1) = (11 + 6*sqrt(2))/7 = R2 (ratio #2).
Also gives solutions > 3 to the equation x^2-4 = floor(x*r*floor(x/r)) where r=sqrt(2). - Benoit Cloitre, Feb 14 2004
From Paul Curtz, Dec 15 2012: (Start)
a(n-1) and A006452(n) are companions. Like A000129 and A001333.
Reduced mod 10 this is a sequence of period 12: 3, 5, 3, 7, 5, 7, 7, 5, 7, 3, 5, 3.
(End)
The Pisano periods (periods of the sequence reducing a(n) modulo m) for m>=1 are 1, 1, 8, 4, 12, 8, 6, 4, 24, 12, 24, 8, 28, ... R. J. Mathar, Dec 15 2012
Positive values of x (or y) satisfying x^2 - 6xy + y^2 + 56 = 0. - Colin Barker, Feb 08 2014
From Wolfdieter Lang, Feb 05 2015: (Start)
a(n+1) gives for n >= 0 all positive x solutions of the (generalized) Pell equation x^2 - 2*y^2 = +7.
The corresponding y solutions are given in A077442(n), n >= 0. The, e.g., the Nagell reference for finding all solutions.
Because the primitive Pythagorean triangle (3,4,5) is the only one with the sum of legs equal to 7 all positive solutions (x(n),y(n)) = (a(n+1),A077442(n)) of the Pell equation x^2 - 2*y^2 = +7 satisfy x(n) - y(n) < y(n) if n >= 1; only the first solution (x(0),y(0)) = (3,2) satisfies 3-1 > 1. Proof: Primitive Pythagorean triangles are characterized by the positive integer pairs [u,v] with u+v odd, gcd(u,v) = 1 and u > v. See the Niven et al. reference, Theorem 5.5, p. 232. The leg sum is L = (u+v)^2 - 2*v^2. With L = 7, x = u+v and y = v, every solution (x(n),y(n)) with x(n)-y(n) = u(n) > v(n) = y(n) will correspond to a primitive Pythagorean triangle. Note that because of gcd(x,y) = 1 also gcd(u,v) = 1. But there is only one such triangle with L=7, namely the one with [u(0),v(0)] = [2,1]. All other solutions with n >= 1 must therefore satisfy x(n)-y(n) < y(n). (End)
For n > 0, a(n+1) is the n-th almost Lucas-cobalancing number of first type (see Tekcan and Erdem). - Stefano Spezia, Nov 25 2022

Examples

			a(3)^2 - 2*A077442(2)^2 = 13^2 - 2*9^2 = +7. - _Wolfdieter Lang_, Feb 05 2015
		

References

  • A. H. Beiler, "The Pellian." Ch. 22 in Recreations in the Theory of Numbers: The Queen of Mathematics Entertains. Dover, New York, New York, pp. 248-268, 1966.
  • L. E. Dickson, History of the Theory of Numbers, Vol. II, Diophantine Analysis. AMS Chelsea Publishing, Providence, Rhode Island, 1999, pp. 341-400.
  • Peter G. L. Dirichlet, Lectures on Number Theory (History of Mathematics Source Series, V. 16); American Mathematical Society, Providence, Rhode Island, 1999, pp. 139-147.
  • T. Nagell, Introduction to Number Theory, Chelsea Publishing Company, 1964, Theorem 109, pp. 207-208 with Theorem 104, pp. 197-198.
  • Ivan Niven, Herbert S. Zuckerman and Hugh L. Montgomery, An Introduction to the Theory Of Numbers, Fifth Edition, John Wiley and Sons, Inc., NY 1991.

Crossrefs

Programs

  • Mathematica
    LinearRecurrence[{0,6,0,-1},{3,5,13,27},50] (* Sture Sjöstedt, Oct 09 2012 *)

Formula

a(2n+1) = A038762(n). a(2n) = A101386(n-1).
The same recurrences hold for the odd and the even indices: a(n+2) = 6*a(n) - a(n-2), a(n+1) = 3*a(n) + 2*(2*a(n)^2-14)^0.5 - Richard Choulet, Oct 11 2007
O.g.f.: -x*(x-1)*(3*x^2+8*x+3) / ( (x^2+2*x-1)*(x^2-2*x-1) ). - R. J. Mathar, Nov 23 2007
If n is even a(n) = (1/2)*(3+sqrt(2))*(3+2*sqrt(2))^(-n/2) + (1/2)*(3-sqrt(2))*(3-2*sqrt(2))^(-n/2); if n is odd a(n) = (1/2)*(3+sqrt(2))*(3+2*sqrt(2))^((n-1)/2) + (1/2)*(3-sqrt(2))*(3-2*sqrt(2))^((n-1)/2). - Antonio Alberto Olivares, Apr 20 2008
a(n) = A000129(n+1) + (-1)^n*A176981(n-1), n>1. - R. J. Mathar, Jul 03 2011
a(n) = A000129(n+1) -(-1)^n*A000129(n-2), rephrasing the formula above. - Paul Curtz, Dec 07 2012
a(n) = sqrt(8*A216134(n)^2 + 8*A216134(n) + 9) = 2*A124124(n) + 1. - Raphie Frank, May 24 2013
E.g.f.: cosh(sqrt(2)*x)*(3*cosh(x) - sinh(x)) + sqrt(2)*(2*cosh(x) - sinh(x))*sinh(sqrt(2)*x) - 3. - Stefano Spezia, Nov 25 2022

Extensions

More terms from Richard Choulet, Oct 11 2007
Edited: replaced n by a(n) in the name. Moved Pell remarks to the comment section. Added cross references. - Wolfdieter Lang, Feb 05 2015

A124124 Nonnegative integers n such that 2n^2 + 2n - 3 is square.

Original entry on oeis.org

1, 2, 6, 13, 37, 78, 218, 457, 1273, 2666, 7422, 15541, 43261, 90582, 252146, 527953, 1469617, 3077138, 8565558, 17934877, 49923733, 104532126, 290976842, 609257881, 1695937321, 3551015162, 9884647086, 20696833093, 57611945197, 120629983398, 335787024098
Offset: 1

Views

Author

John W. Layman, Nov 29 2006

Keywords

Comments

First differences are apparently in A143608. [R. J. Mathar, Jul 17 2009]
Alternative definition: T_n and (T_n - 1)/2 are triangular numbers. - Raphie Frank, Sep 06 2012

Crossrefs

Programs

  • Maple
    A124124 := proc(n)
    coeftayl(x*(1+x-2*x^2+x^3+x^4)/((1-x)*(x^2-2*x-1)*(x^2+2*x-1)), x=0, n);
    end proc:
    seq(A124124(n), n=1..20); # Wesley Ivan Hurt, Aug 04 2014
    # Alternative:
    a[1]:= 1: a[2]:= 2: a[3]:= 6:
    for n from 4 to 1000 do
    a[n]:= (3 + 2*(n mod 2))*(a[n-1]-a[n-2])+a[n-3]
    od:
    seq(a[n],n=1..100); # Robert Israel, Aug 13 2014
  • Mathematica
    LinearRecurrence[{1,6,-6,-1,1},{1,2,6,13,37},40] (* Harvey P. Dale, Nov 05 2011 *)
    CoefficientList[Series[(1 + x - 2*x^2 + x^3 + x^4)/((1 - x)*(x^2 - 2*x - 1)*(x^2 + 2*x - 1)), {x, 0, 30}], x] (* Wesley Ivan Hurt, Aug 04 2014 *)
  • PARI
    for(n=1,10^10,if(issquare(2*n^2+2*n-3),print1(n,", "))) \\ Derek Orr, Aug 13 2014

Formula

It appears that a(n) = 3*a(n-1)-3*a(n-2)+a(n-3) if n is even, a(n) = 5*a(n-1)-5*a(n-2)+a(n-3) if n is odd. Can anyone confirm this?
Corrected and confirmed (using the g.f.) by Robert Israel, Aug 27 2014
2*a(n) = sqrt(7+2*A077442(n-1)^2)-1. - R. J. Mathar, Dec 03 2006
a(n) = a(n-1)+6*a(n-2)-6*a(n-3)-a(n-4)+a(n-5). G.f.: -x*(1+x-2*x^2+x^3+x^4)/((x-1)*(x^2-2*x-1)*(x^2+2*x-1)). [R. J. Mathar, Jul 17 2009]
For n>0, a(2n-1) = 2*A001653(n) - A046090(n-1) and a(2n) = 2*A001653(n) + A001652(n-1). - Charlie Marion, Jan 03 2012
From Raphie Frank, Sep 06 2012: (Start)
If y = A006452(n), then a(n) = 2y + ((sqrt(8y^2 - 7) - 1)/2 - (1 - sgn(n))).
Also see A216134 [a(n) = y + ((sqrt(8y^2 - 7) - 1)/2 - (1 - sgn(n)))].
(End)
From Hermann Stamm-Wilbrandt, Aug 27 2014: (Start)
a(2*n+2) = A098586(2*n).
a(2*n+1) = A098790(2*n).
a(n) = 7*a(n-2) - 7*a(n-4) + a(n-6), for n>6. (End)
a(2*n+1)^2 + (a(2*n+1)+1)^2 = A038761(n)^2 + 2^2. - Hermann Stamm-Wilbrandt, Aug 31 2014

Extensions

More terms from Harvey P. Dale, Feb 07 2011
More terms from Wesley Ivan Hurt, Aug 04 2014

A114697 Expansion of (1+x+x^2)/((1-x^2)*(1-2*x-x^2)); a Pellian-related sequence.

Original entry on oeis.org

1, 3, 9, 22, 55, 133, 323, 780, 1885, 4551, 10989, 26530, 64051, 154633, 373319, 901272, 2175865, 5253003, 12681873, 30616750, 73915375, 178447501, 430810379, 1040068260, 2510946901, 6061962063, 14634871029, 35331704122, 85298279275, 205928262673
Offset: 0

Views

Author

Creighton Dement, Feb 18 2006

Keywords

Comments

Generating floretion: (- .5'j + .5'k - .5j' + .5k' + 'ii' - .5'ij' - .5'ik' - .5'ji' - .5'ki')*('i + 'j + i').

Crossrefs

Programs

  • Mathematica
    Table[(3*LucasL[n, 2] +10*Fibonacci[n, 2] -3 +(-1)^n)/4, {n,0,30}] (* G. C. Greubel, May 24 2021 *)
  • PARI
    Vec((1+x+x^2)/((1-x^2)*(1-2*x-x^2)) + O(x^40)) \\ Colin Barker, Jun 24 2015
    
  • Sage
    [(4*lucas_number1(n+2,2,-1) -2*lucas_number1(n+1,2,-1) -3 +(-1)^n)/4 for n in (0..30)] # G. C. Greubel, May 24 2021

Formula

a(n+2) - 2*a(n+1) + a(n) = A111955(n+2).
G.f.: (1+x+x^2)/((1-x)*(1+x)*(1-2*x-x^2)).
From Raphie Frank, Oct 01 2012: (Start)
a(2*n) = A216134(2*n+1).
a(2*n+1) = A006452(2*n+3)-1.
Lim_{n->infinity} a(n+1)/a(n) = A014176. (End)
a(n) = (2*A078343(n+2) - A010694(n))/4. - R. J. Mathar, Oct 02 2012
From Colin Barker, May 26 2016: (Start)
a(n) = ( 2*(-3 +(-1)^n) + (6-5*sqrt(2))*(1-sqrt(2))^n + (1+sqrt(2))^n*(6+5*sqrt(2)) )/8.
a(n) = 2*a(n-1) + 2*a(n-2) - 2*a(n-3) - a(n-4) for n>3. (End)
a(n) = (3*A002203(n) + 10*A000129(n) - 3 + (-1)^n)/4. - G. C. Greubel, May 24 2021

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

A217278 Sequences A124174 and A006454 interlaced.

Original entry on oeis.org

0, 0, 1, 3, 10, 15, 45, 120, 351, 528, 1540, 4095, 11935, 17955, 52326, 139128, 405450, 609960, 1777555, 4726275, 13773376, 20720703, 60384555, 160554240, 467889345, 703893960, 2051297326, 5454117903, 15894464365, 23911673955, 69683724540, 185279454480
Offset: 0

Views

Author

Raphie Frank, Sep 29 2012

Keywords

Comments

a(2n) and 2*a(2n) + 1 are triangular.
a(2n + 1) is triangular and a(2n + 1)/2 is the harmonic mean of consecutive triangular numbers (therefore, a(2n + 1) + 1 is square).

Examples

			a(18) = 35*(52326 - 1540) + 45 = 1777555,
a(19) = 35*(139128 - 4095) + 120 = 4726275.
		

Crossrefs

Cf. (sqrt(8a(2n) + 1) - 1)/2 = A216134(n) = A216162(2n + 1).
Cf. sqrt(a(2n+1) + 1) = A006452(n + 1) = A216162(2n + 2).
Cf. (sqrt(8a(2n+1) + 1) - 1)/2 = A006451(n).

Programs

  • Mathematica
    LinearRecurrence[{0,1,0,34,0,-34,0,-1,0,1},{0,0,1,3,10,15,45,120,351,528},40] (* Harvey P. Dale, Aug 04 2019 *)
  • PARI
    concat([0,0], Vec(-x^2*(3*x^5+x^4+12*x^3+9*x^2+3*x+1)/((x-1)*(x+1)*(x^2-2*x-1)*(x^2+2*x-1)*(x^4+6*x^2+1)) + O(x^100))) \\ Colin Barker, Jun 23 2015

Formula

a(n) = 35*(a(n-4) - a(n-8)) + a(n-12).
lim n --> infinity a(2n)/a(2n - 1) = (3 + sqrt(8))/2.
From Raphie Frank, Dec 21 2015: (Start)
a(2*n + 1) = 1/64*(((4 + sqrt(2)) * (1 - (-1)^(n+1) * sqrt(2))^(2*floor((n+1)/2)) + (4 - sqrt(2)) * (1+(-1)^(n+1) * sqrt(2))^(2*floor((n+1)/2))))^2 - 1.
a(2*n + 2) = 1/2*(3*(a(2*n + 1)) + sqrt((a(2*n + 1)) + 1) * sqrt(8*(a(2*n + 1)) + 1) + 1).
(End)

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).
Showing 1-10 of 11 results. Next