3

Compute the number of ways to spread $k$ identical balls over $n$ different cells (where $k \geq n$) with the condition that every cell will have at least one ball.

So if $k=n$ then, we have only one option, because they're identical. otherwise, it was k! options.

If $k>n$ then, we will put one ball to every cell and will have left with $k-n$ identical balls. then it is easy. Spreading k-n balls to n different cells without any conditions is $C(k-n + n - 1, k-n - 1)$.

What do you guys think?

1 Answers1

1

This is a standard stars and bars problem.

We have $n$ cells, they can be separated by $n-1$ bars. Our $k$ balls are the "stars". However only $n-k$ can be moved freely. So we have $n-1$ bars and $k-n$ stars. They can be arranged in $\binom{k-1}{n-1}$ ways.

Final answer is $\binom{k-1}{n-1}$. You can find a more complete explanation here

Asinomás
  • 107,565