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 - 16*n + 32*n^2.
G.f.: (1+7*x)^2/(1-x)^3.
From Elmo R. Oliveira, Jun 09 2025: (Start)
E.g.f.: exp(x)*(1 + 16*x + 32*x^2).
a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3). (End)
MATHEMATICA
CoefficientList[Series[(1 + 7 x)^2 / (1 - x)^3, {x, 0, 40}], x] (* Vincenzo Librandi, Aug 09 2013 *)
LinearRecurrence[{3, -3, 1}, {1, 17, 97}, 50] (* Harvey P. Dale, Aug 30 2025 *)
PROG
(Magma) [1-16*n+32*n^2: n in [0..40]]; // Vincenzo Librandi, Aug 09 2013
(PARI) a(n)=32*n^2-16*n+1 \\ Charles R Greathouse IV, Jun 17 2017
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Paul Barry, Mar 23 2003
STATUS
approved
