OFFSET
0,2
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 0..1000
Index entries for linear recurrences with constant coefficients, signature (3,-3,1).
FORMULA
a(n) = 1-6*n+18*n^2.
G.f.: (1+5*x)^2/(1-x)^3.
MATHEMATICA
CoefficientList[Series[(1 + 5 x)^2 / (1 - x)^3, {x, 0, 40}], x] (* Vincenzo Librandi, Aug 09 2013 *)
PROG
(Magma) [1-6*n+18*n^2: n in [0..40]]; // Vincenzo Librandi, Aug 09 2013
(PARI) a(n)=18*n^2-6*n+1 \\ Charles R Greathouse IV, Jun 17 2017
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Paul Barry, Mar 23 2003
STATUS
approved