Solution

Partitioning a Set

Show the problem again

In how many ways can a set of 5 distinct elements be partitioned into any number of nonempty unlabeled blocks?

Worked solution

The answer is 52, the Bell number B₅. Sum Stirling numbers S(5, k) over block counts k: S(5,1) + S(5,2) + S(5,3) + S(5,4) + S(5,5) = 1 + 15 + 25 + 10 + 1 = 52. Bell numbers also satisfy B_{n+1} = Σ C(n, k) B_k, which gives the same result recursively.

Source: Set partitions and Bell numbers, standard material in enumerative combinatorics. Statement written for AxiomIQ.