OFFSET
0,1
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
G.f.: (4+157*x+81*x^2)/(1-x)^3. - Vincenzo Librandi, Jul 07 2012
a(n) = 3*a(n-1) -3*a(n-2) +a(n-3). - Vincenzo Librandi, Jul 07 2012
MATHEMATICA
CoefficientList[Series[(4+157*x+81*x^2)/(1-x)^3, {x, 0, 50}], x] (* Vincenzo Librandi, Jul 07 2012 *)
PROG
(Magma) I:=[4, 169, 576]; [n le 3 select I[n] else 3*Self(n-1)-3*Self(n-2)+Self(n-3): n in [1..50]]; // Vincenzo Librandi, Jul 07 2012
(PARI) a(n)=(11*n+2)^2 \\ Charles R Greathouse IV, Jun 17 2017
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
STATUS
approved