OFFSET
0,3
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..612
Wikipedia, Partition of a set
EXAMPLE
a(3) = 4: 123, 12|3, 13|2, 1|2|3.
a(4) = 11: 1234, 123|4, 124|3, 12|34, 12|3|4, 134|2, 13|24, 13|2|4, 14|23, 14|2|3, 1|2|3|4.
MAPLE
b:= proc(n, i) option remember; `if`(n=0, 1, add(
b(n-j, j)*binomial(n-1, j-1), j=1..min(n, i)))
end:
a:= n-> b(n$2):
seq(a(n), n=0..35);
MATHEMATICA
b[n_, i_] := b[n, i] = If[n==0, 1, Sum[b[n-j, j]*Binomial[n-1, j-1], {j, 1, Min[n, i]}]]; a[n_] := b[n, n]; Table[a[n], {n, 0, 35}] (* Jean-François Alcover, Feb 02 2017, translated from Maple *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Alois P. Heinz, Jul 22 2016
STATUS
approved