OFFSET
1,1
COMMENTS
Seventh diagonal in A144562.
2*a(n) + 39 is a square.
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 1..1000
Index entries for linear recurrences with constant coefficients, signature (3,-3,1).
FORMULA
G.f.: x*(3-x)*(7-5*x)/(1-x)^3. - Bruno Berselli, Dec 07 2011
a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3). - Vincenzo Librandi, Feb 22 2012
Sum_{n>=1} 1/a(n) = 124/1995 + tan(sqrt(39)*Pi/2)*Pi/(2*sqrt(39)). - Amiram Eldar, Feb 25 2023
MATHEMATICA
LinearRecurrence[{3, -3, 1}, {21, 41, 65}, 50] (* Vincenzo Librandi, Feb 22 2012 *)
PROG
(Magma) I:=[21, 41, 65]; [n le 3 select I[n] else 3*Self(n-1)-3*Self(n-2)+1*Self(n-3): n in [1..40]]; // Vincenzo Librandi, Feb 22 2012
(PARI) for(n=1, 40, print1(2*n^2 + 14*n + 5", ")); \\ Vincenzo Librandi, Feb 22 2012
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Vincenzo Librandi, Jan 12 2009
STATUS
approved