OFFSET
0,2
COMMENTS
A083362 is the square table of least distinct positive integers such that the sum of any two consecutive terms in any row form a square.
LINKS
Index entries for linear recurrences with constant coefficients, signature (1,2,-2,-1,1).
FORMULA
a(0) = 1; a(2n-1) = 8n^2 - n (n>0); a(2n) = 8n^2 + 3n (n>0).
a(n) = a(n-1)+2*a(n-2)-2*a(n-3)-a(n-4)+a(n-5). - Colin Barker, Sep 26 2014
G.f.: (x^5-x^4-7*x^3-2*x^2-6*x-1) / ((x-1)^3*(x+1)^2). - Colin Barker, Sep 26 2014
a(n) = (4n+3)*(2n+1-(-1)^n)/4+0^n. - Wesley Ivan Hurt, Sep 26 2014
MAPLE
MATHEMATICA
Join[{1}, Table[(4 n + 3) (2 n + 1 - (-1)^n)/4, {n, 30}]] (* Wesley Ivan Hurt, Sep 26 2014 *)
LinearRecurrence[{1, 2, -2, -1, 1}, {1, 7, 11, 30, 38, 69}, 50] (* Harvey P. Dale, Oct 04 2023 *)
PROG
(PARI) Vec((x^5-x^4-7*x^3-2*x^2-6*x-1)/((x-1)^3*(x+1)^2) + O(x^100)) \\ Colin Barker, Sep 26 2014
(Magma) [(4*n+3)*(2*n+1-(-1)^n)/4+0^n : n in [0..50]]; // Wesley Ivan Hurt, Sep 26 2014
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Paul D. Hanna, Apr 27 2003
STATUS
approved