OFFSET
0,4
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..574
Wikipedia, Partition of a set
FORMULA
EXAMPLE
a(3) = 6 = 2 + 1 + 2 + 1 + 0: 123, 12|3, 13|2, 1|23, 1|2|3.
MAPLE
b:= proc(n, m, t) option remember; `if`(n=0, [1, 0], (p->
p+[0, p[1]*(n-t)])(b(n-1, m+1, t+1))+m*b(n-1, m, t+1))
end:
a:= n-> b(n, 0, 1)[2]:
seq(a(n), n=0..23);
# second Maple program:
egf:= (z-2)*exp(2*z+exp(z)-1)+(2*z+1)*exp(z+exp(z)-1)+exp(exp(z)-1):
a:= n-> n!*coeff(series(egf, z, n+1), z, n):
seq(a(n), n=0..23);
CROSSREFS
KEYWORD
nonn
AUTHOR
Alois P. Heinz, Dec 15 2023
STATUS
approved