OFFSET
0,4
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..250
FORMULA
G.f.: Sum_{k>=0} (3*k)! * x^(3*k) / (1 - x)^(3*k + 1).
a(0) = a(1) = a(2) = 1; a(n) = n * (n - 1) * (n - 2) * a(n - 3) + 1.
a(n) = Sum_{k=0..floor(n/3)} n! / (n - 3*k)!.
a(n) ~ n! * (exp(1)/3 + 2*cos(sqrt(3)/2 - 2*Pi*n/3) / (3*exp(1/2))). - Vaclav Kotesovec, Apr 18 2020
a(n) = A158757(n, 2*n). - G. C. Greubel, Dec 05 2021
MATHEMATICA
nmax = 22; CoefficientList[Series[Exp[x]/(1 - x^3), {x, 0, nmax}], x] Range[0, nmax]!
Table[Sum[n!/(n - 3 k)!, {k, 0, Floor[n/3]}], {n, 0, 22}]
PROG
(Magma) [n le 3 select 1 else 1 + 6*Binomial(n-1, 3)*Self(n-3): n in [1..41]]; // G. C. Greubel, Dec 05 2021
(Sage) [sum(factorial(3*k)*binomial(n, 3*k) for k in (0..n//3)) for n in (0..40)] # G. C. Greubel, Dec 05 2021
CROSSREFS
KEYWORD
nonn
AUTHOR
Ilya Gutkovskiy, Nov 28 2019
STATUS
approved