OFFSET
4,1
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 4..1000
Index entries for linear recurrences with constant coefficients, signature (4,-6,4,-1).
FORMULA
a(n) = n(n^2 - 3n + 14)/3 (n >= 4). - Emeric Deutsch, Nov 27 2006
G.f.: x^4*(24 - 56*x + 48*x^2 - 14*x^3)/(1 - x)^4. - Colin Barker, Sep 17 2012
MAPLE
a:=n->n*(n^2-3*n+14)/3: seq(a(n), n=4..50); # Emeric Deutsch, Nov 27 2006
MATHEMATICA
Table[Range[n].RotateLeft[Range[n], 3], {n, 4, 52}] (* T. D. Noe, Nov 07 2006 *)
CoefficientList[Series[(24 - 56 x + 48 x^2 - 14 x^3)/(1 - x)^4, {x, 0, 50}], x] (* Vincenzo Librandi, Oct 17 2013 *)
LinearRecurrence[{4, -6, 4, -1}, {24, 40, 64, 98}, 60] (* Harvey P. Dale, Nov 04 2024 *)
PROG
(Magma) [n*(n^2-3*n+14)/3: n in [4..50]]; // Vincenzo Librandi, Oct 17 2013
CROSSREFS
KEYWORD
nonn,easy,changed
AUTHOR
EXTENSIONS
Corrected by T. D. Noe, Nov 07 2006
STATUS
approved