A383734 Numbers k such that 2+k and 2*k are squares.
2, 98, 3362, 114242, 3880898, 131836322, 4478554082, 152139002498, 5168247530882, 175568277047522, 5964153172084898, 202605639573839042, 6882627592338442562, 233806732499933208098, 7942546277405390632802, 269812766699283348307202, 9165691521498228451812098
Offset: 1
Examples
98 is a term becouse 98+2=100 is a square and 98*2=196 is a square.
Links
- Eric Weisstein's World of Mathematics, NSW numbers.
- Index entries for linear recurrences with constant coefficients, signature (35,-35,1).
Crossrefs
Programs
-
Mathematica
LinearRecurrence[{35, -35, 1}, {2, 98, 3362}, 20] (* Amiram Eldar, May 07 2025 *)
-
Python
from itertools import islice def A383734_gen(): # generator of terms x, y = 1, 7 while True: yield 2*x**2 x, y = y, 6*y - x A383734_list = list(islice(A383734_gen(), 100))
Formula
a(n) = (1/2) * ((3+2*sqrt(2))^(2*n-1) + (3-2*sqrt(2))^(1-2*n)) - 1.
a(n) = -2*sqrt(2)*sinh(n*log(17+12*sqrt(2))) + 3*cosh(n*log(17+12*sqrt(2))) - 1.
a(n) = 2*A002315(n-1)^2.
a(n) = A075870(n)^2 - 2.
a(n) = 34*a(n-1) - a(n-2) + 32.
G.f.: 2 * (1 + 14*x + x^2) / ((1 - x)*(1 - 34*x + x^2)). - Stefano Spezia, May 08 2025
Comments