OFFSET
0,4
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..450
FORMULA
a(n) = n! * [x^n] exp(Sum_{d|n, d>1} x^d/d).
MAPLE
with(numtheory):
A:= proc(n, k) option remember; `if`(n<0, 0, `if`(n=0, 1,
add(mul(n-i, i=1..j-1)*A(n-j, k), j=divisors(k) minus {1})))
end:
a:= n-> A(n$2):
seq(a(n), n=0..25);
MATHEMATICA
A[n_, k_] := A[n, k] = If[n < 0, 0, If[n == 0, 1, Sum[Product[n - i, {i, 1, j - 1}] A[n - j, k], {j, Divisors[k] ~Complement~ {1}}]]];
a[n_] := A[n, n];
Table[a[n], {n, 0, 25}] (* Jean-François Alcover, Mar 23 2017, translated from Maple *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Alois P. Heinz, Aug 18 2015
STATUS
approved