OFFSET
0,2
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 0..200
FORMULA
a(n) = sum(A013999(k), k=0..n).
a(n) = sum(sum(C(j-k+1,k)*(-1)^k*(j-k+1)!, k=0..floor((j+1)/2)), j=0..n).
Recurrence: a(n+4) -(n+8)*a(n+3) +(3*n+16)*a(n+2) -(3*n+13)*a(n+1) +(n+4)*a(n) = 0.
G.f.: Sum_{k>=0} (k+1)!*(x-x^2)^k.
a(n) = (n+3)*a(n-1)-2*(n+1)*a(n-2)+(n+1)*a(n-3) for n>2, a(n) = 2^n for n<=2. - Alois P. Heinz, Jul 01 2013
a(n) ~ n!*n/exp(1). - Vaclav Kotesovec, Jul 06 2013
MAPLE
a:= proc(n) option remember; `if`(n<3, 2^n,
(n+3)*a(n-1) -2*(n+1)*a(n-2) +(n+1)*a(n-3))
end:
seq(a(n), n=0..30); # Alois P. Heinz, Jul 01 2013
MATHEMATICA
Table[Sum[Sum[Binomial[j-k+1, k]*(-1)^k*(j-k+1)!, {k, 0, Floor[(j+1)/2]}], {j, 0, n}], {n, 0, 20}] (* Vaclav Kotesovec, Jul 06 2013 *)
PROG
(Maxima) makelist(sum(sum(binomial(j-k+1, k)*(-1)^k*(j-k+1)!, k, 0, floor((j+1)/2)), j, 0, n), n, 0, 20);
CROSSREFS
KEYWORD
nonn
AUTHOR
Emanuele Munarini, Jul 01 2013
STATUS
approved