We have $n$ unlabelled balls and m labelled boxes $B_1, ..., B_m$. For each $i=1,...,m$, capacity of $B_i$ is $c_i$. In how many way we can distribute these balls in the boxes?
Asked
Active
Viewed 31 times
0
-
Welcome to math.SE. What have you tried already? Where are you struggling? The likelihood of a good answer will increase significantly if you show your efforts. – CPCH Oct 03 '21 at 19:12
-
Personally, I don't agree with the mathSE protocol. In fact, given how difficult this problem is for someone new to the pertinent topics, I regard the protocol as ridiculous. However, there isn't anything that I can do about it, other than provide you with directional guides. ...see next comment – user2661923 Oct 03 '21 at 19:24
-
Assuming that you are untrained in attacking this problem with generating functions, then the standard approach is to combine using Stars and Bars with Inclusion-Exclusion. – user2661923 Oct 03 '21 at 19:26
-
Let $R = $ the number of solutions to $x_1 + \cdots + x_m = n ~: ~x_1, \cdots, x_m \in \Bbb{Z_{\geq 0}}$ and let $S = $ the number of solutions to $x_1 + \cdots + x_m = (n - c_1 - 1) ~: x_1, \cdots, x_m \in \Bbb{Z_{\geq 0}}$. Then $R - S = $ the number of solutions to $x_1 + \cdots + x_m = n ~: ~x_1, \cdots, x_m \in \Bbb{Z_{\geq 0}}, ~x_1 \leq c_1$. – user2661923 Oct 03 '21 at 19:39
-
Let $c_1 + c_2 + \cdots + c_m=C$. Let $b_1, \cdots, b_m$ be a possible distribution of $n$ balls in the boxes. That is $b_1+ \cdots + b_m=n$ and $b_i\leq c_i$ for each $i$, $1\leq i\leq m$. Then, $$ C= (c_1-b_1) + (c_2-b_2) + \cdots + (c_m-b_m) + n. $$ Let $a_i=(b_i - c_i)$ for each $i$, $1\leq i\leq m$. Therefore, existing $b_1, \cdots, b_m$ with the above properties is equal to existing $a_1, \cdots, a_m$ such that $a_1+ \cdots +a_m= C-n$ and $a_i\geq 0$ for each $i$, $1\leq i\leq m$. The number of all possibilities to these sets of integers is $$ {C-n+m-1 \choose m-1}. $$ – Rashid Zaare Nahandi Oct 05 '21 at 19:03
-
The comment posted on October 5 by me is not a correct solution. – Rashid Zaare Nahandi Oct 10 '21 at 16:30