OFFSET
1,1
COMMENTS
The equation "(k^2 + 4)/2 is a square" is a version of the generalized Pell Equation x^2 - D*y^2 = C where x^2 - 2*y^2 = -4.
Sequence of all positive integers k such that continued fraction [k,k,k,k,k,k,...] belongs to Q(sqrt(2)). - Thomas Baruchel, Sep 15 2003
Equivalently, 2*n^2 + 8 is a square.
Numbers n such that (ceiling(sqrt(n*n/2)))^2 = 2 + n^2/2. - Ctibor O. Zizka, Nov 09 2009
The continued fraction [a(n);a(n),a(n),...] = (1 + sqrt(2))^(2*n-1). - Thomas Ordowski, Jun 07 2013
a((p+1)/2) == 2 (mod p) where p is an odd prime. - Altug Alkan, Mar 17 2016
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.
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..1306
Sergio Falcon, Relationships between Some k-Fibonacci Sequences, Applied Mathematics, 2014, 5, 2226-2234.
Tanya Khovanova, Recursive Sequences
Prabha Sivaraman Nair and Rejikumar Karunakaran, On k-Fibonacci Brousseau Sums, J. Int. Seq. (2024) Art. No. 24.6.4. See p. 3.
J. J. O'Connor and E. F. Robertson, Pell's Equation. [Broken link]
Eric Weisstein's World of Mathematics, Pell Equation.
Eric Weisstein's World of Mathematics, NSW Number.
Index entries for linear recurrences with constant coefficients, signature (6,-1).
FORMULA
a(n) = (((3 + 2*sqrt(2))^n - (3 - 2*sqrt(2))^n) + ((3 + 2*sqrt(2))^(n-1) - 3 - 2*sqrt(2))^(n-1))) / (2*sqrt(2)).
a(n) = 2*A002315(n-1).
Recurrence: a(n) = 6*a(n-1) - a(n-2), starting 2, 14.
Offset 0, with a=3+2*sqrt(2), b=3-2*sqrt(2): a(n) = a^((2n+1)/2) - b^((2n+1)/2). a(n) = 2*(A001109(n+1) + A001109(n)) = (A003499(n+1) - A003499(n))/2 = 2*sqrt(A001108(2n+1)) = sqrt(A003499(2n+1)-2). - Mario Catalani (mario.catalani(AT)unito.it), Mar 31 2003
Limit_{n->oo} a(n)/a(n-1) = 5.82842712474619009760... = 3 + 2*sqrt(2). See A156035.
From R. J. Mathar, Nov 16 2007: (Start)
G.f.: 2*x*(1+x)/(1-6*x+x^2).
a(n) = (1+sqrt(2))^(2*n-1) - (1+sqrt(2))^(1-2*n). - Gerson Washiski Barbosa, Sep 19 2010
a(n) = floor((1 + sqrt(2))^(2*n-1)). - Thomas Ordowski, Jun 07 2013
a(n) = 2*sqrt((2*A001653(n)^2)-1). - César Aguilera, Jul 13 2023
E.g.f.: 2*(1 + exp(3*x)*(sqrt(2)*sinh(2*sqrt(2)*x) - cosh(2*sqrt(2)*x))). - Stefano Spezia, Aug 27 2024
MATHEMATICA
LinearRecurrence[{6, -1}, {2, 14}, 30] (* Harvey P. Dale, Jul 25 2018 *)
PROG
(PARI) for(n=1, 20, q=(1+sqrt(2))^(2*n-1); print1(contfrac(q)[1], ", ")) \\ Derek Orr, Jun 18 2015
(PARI) Vec(2*x*(1+x)/(1-6*x+x^2) + O(x^100)) \\ Altug Alkan, Mar 17 2016
(Magma) [n: n in [0..10^8] | IsSquare((n^2 + 4) div 2)]; // Vincenzo Librandi, Jun 20 2015
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Gregory V. Richardson, Nov 09 2002
STATUS
approved