3
$begingroup$
Say we have a multiset $S(mathbf{d}$) where $mathbf{d}$ is a list of $l$ numbers and the multiplicity of the $i$th element of $S$ is $d_i$. The cardinality $N$ of $S$ is $sum d_i$. We want to partition $S$ into $m$ multisets of size $k_i$ respectively, so that $sum k_i = sum d_i = N$. How many ways can we do this? In my mind this is a generalization of the multinomial coefficient $binom{n}{k_1,k_2,ldots,k_m}$ representing the number of ways to partition a set of $n=sum k_i$ objects into $m$ bins of sizes $k_i$, to a sort of number like $binom{mathbf{d}}{k_1,k_2,ldots,k_m}$ or $binom{mathbf{d}}{mathbf{k}}$ representing the number of ways to partition a multiset of $n=sum k_i = sum d_i$ into $m$ bins of sizes $k_i$. There are a few special cases that are simpler to calculate: If $m=1$, then cl...