OFFSET
0,3
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..1000
FORMULA
G.f.: Product_{j>=1} (1+x^j)^A027306(j).
EXAMPLE
a(3) = 7: {aaa}, {aab}, {aba}, {baa}, {aa,a}, {ab,a}, {ba,a}.
MAPLE
b:= proc(n, i, t) option remember; `if`(t=1, 1/n!,
add(b(n-j, j, t-1)/j!, j=i..n/t))
end:
g:= (n, k)-> `if`(k=0, `if`(n=0, 1, 0), n!*b(n, 0, k)):
h:= proc(n, i, k) option remember; `if`(n=0, 1, `if`(i<1, 0,
add(h(n-i*j, i-1, k)*binomial(g(i, k), j), j=0..n/i)))
end:
a:= n-> h(n$2, min(n, 2)):
seq(a(n), n=0..32);
CROSSREFS
KEYWORD
nonn
AUTHOR
Alois P. Heinz, Jan 06 2021
STATUS
approved