OFFSET
1,2
LINKS
Colin Barker, Table of n, a(n) for n = 1..634
Index entries for linear recurrences with constant coefficients, signature (1,1442,-1442,-1,1).
FORMULA
a(n) = a(n-1)+1442*a(n-2)-1442*a(n-3)-a(n-4)+a(n-5).
G.f.: -x*(x^4+15*x^3-302*x^2+15*x+1) / ((x-1)*(x^2-38*x+1)*(x^2+38*x+1)).
EXAMPLE
16 is in the sequence because it is the 4th square number and the 3rd centered pentagonal number.
MATHEMATICA
LinearRecurrence[{1, 1442, -1442, -1, 1}, {1, 16, 1156, 22801, 1666681}, 20] (* Harvey P. Dale, Jul 26 2015 *)
PROG
(PARI) Vec(-x*(x^4+15*x^3-302*x^2+15*x+1) / ((x-1)*(x^2-38*x+1)*(x^2+38*x+1)) + O(x^100))
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Colin Barker, Jan 28 2015
STATUS
approved