login
A241976
Values of k such that k^2 + (k+3)^2 is a square.
3
0, 9, 60, 357, 2088, 12177, 70980, 413709, 2411280, 14053977, 81912588, 477421557, 2782616760, 16218279009, 94527057300, 550944064797, 3211137331488, 18715879924137, 109084142213340, 635788973355909, 3705649697922120, 21598109214176817, 125883005587138788
OFFSET
1,2
COMMENTS
A075841 gives the corresponding values of sqrt(n^2 + (n+3)^2).
FORMULA
G.f.: 3*x^2*(x-3) / ((x-1)*(x^2-6*x+1)).
a(n) = 7*a(n-1) - 7*a(n-2) + a(n-3).
a(n) = 3*A001652(n-1).
a(n) = -3*(2 + (3-2*sqrt(2))^n*(1+sqrt(2)) - (-1+sqrt(2))*(3+2*sqrt(2))^n) / 4. - Colin Barker, Apr 13 2017
EXAMPLE
9 is in the sequence because 9^2 + 12^2 = 225 = 15^2.
MATHEMATICA
CoefficientList[Series[3 x (x - 3)/((x - 1) (x^2 - 6 x + 1)), {x, 0, 30}], x] (* Vincenzo Librandi, Aug 11 2014 *)
PROG
(PARI) concat(0, Vec(3*x^2*(x-3)/((x-1)*(x^2-6*x+1)) + O(x^100)))
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Colin Barker, Aug 10 2014
STATUS
approved