Multinomial coefficients: splitting \(n\) items into many groups
The multinomial coefficient generalizes the binomial coefficient to more than two categories.
Suppose you have \(n\) distinct items and you want to split them into \(m\) labeled groups with specified sizes
\(k_1,k_2,\dots,k_m\), where each \(k_i\ge 0\) and
\[
k_1+k_2+\cdots+k_m=n.
\]
A standard interpretation is “How many different assignments are there if group 1 must receive \(k_1\) items, group 2 must receive
\(k_2\) items, and so on?” The answer is
\[
\binom{n}{k_1,k_2,\dots,k_m}=\frac{n!}{k_1!\,k_2!\cdots k_m!}.
\]
Why the factorial formula makes sense
One way to derive the formula is to count arrangements. Start by lining up all \(n\) distinct items in a row — there are \(n!\)
such permutations. Now, imagine cutting that row into consecutive blocks of sizes \(k_1,k_2,\dots,k_m\). Each cut produces an ordered
list of items for each group. But within a fixed group, order does not matter for “group membership”: swapping two items inside the
same group creates the same partition. For group \(i\), there are \(k_i!\) internal permutations that do not change the grouping, so
we must divide by \(k_1!k_2!\cdots k_m!\). This gives the multinomial coefficient.
Connection to repeated binomial choices
Another useful viewpoint is sequential selection. First choose which \(k_1\) items go into group 1: \(\binom{n}{k_1}\) ways.
From the remaining \(n-k_1\) items, choose \(k_2\) for group 2: \(\binom{n-k_1}{k_2}\) ways, and continue. The product
\[
\binom{n}{k_1}\binom{n-k_1}{k_2}\cdots
\]
simplifies exactly to \(\frac{n!}{k_1!\cdots k_m!}\). This is a practical way to compute the value without forming huge factorials.
How this tool helps
This calculator checks the key constraint \(\sum_i k_i=n\) and then evaluates the multinomial coefficient. It shows the formula with
your substituted values and explains the reasoning step by step. Because multinomial numbers can grow extremely fast, the tool
presents the exact integer (when feasible) using big-integer arithmetic and can also show a scientific-notation approximation for
quick magnitude checks.
Where multinomials appear in probability
In probability, multinomial coefficients appear in the multinomial distribution (a multi-category extension of the
binomial). If each item independently falls into category \(i\) with probability \(p_i\) and you observe counts \(k_i\), then
\[
P(\text{counts }k_1,\dots,k_m)=\binom{n}{k_1,\dots,k_m}\,p_1^{k_1}\cdots p_m^{k_m}.
\]
The coefficient counts how many sequences produce the same counts. This is the same “order within a category doesn’t matter” idea,
now weighted by probabilities.