Generating function to calculate number of ways of distributing $10$ or less items to $3$ people.

210 Views Asked by At

There is a container of 10 identical chocolate frogs and three students, Adam, Bob, and Charles, are to be given some of these chocolate frogs, but not necessarily all of the chocolate frogs. In how many ways can the chocolate frogs be given to the students if each student must receive at least one chocolate frog each?

First we note that this is equivalent to $x_1+x_2+x_3+x_4=10$

$x_1,x_2,x_3\geq1,x_4\geq0$

Using a genearting function this is

$(t^1+\dots+t^{8})(t^1+\dots+t^{8})(t^1+\dots+t^{8})(1+t^1+\dots+t^{7})$

Coefficient of $10$

E.g.

$\text{Coefficient}\left[\left(\sum _{i=1}^8 t^i\right) \left(\sum _{i=1}^8 t^i\right) \left(\sum _{i=1}^8 t^i\right) \sum _{i=0}^7 t^i,t,10\right]=120$

Is this the correct method?


By stars and bars $y_1=x_1-1\geq0$

$y_1+1 = x_1$ same procedure with $y_2,y_3$, and obtain $y_1+y_2+y_3+x_4=7$, this is the same as 7 stars and $3$ bars, we have ${{7+3-1} \choose {7}}=36$

2

There are 2 best solutions below

0
On BEST ANSWER

Your method is correct. But stars and bars would be easier as Andre Nicolas has suggested.

0
On

Here's a way that neither uses stars and bars nor generating functions.

Distribute one each to A, B, C, and initially assume that the remaining $7$ are distinct.

Then the first of these seven has $4$ places (uparrows) to go, $\uparrow \bullet\uparrow \bullet\uparrow \bullet\uparrow$,

the next will have $5$ places to go, and so on, thus $4\cdot5\cdot6\cdot7\cdot8\cdot9\cdot10$

Finally, divide by $7!$ since they are identical to get $\quad\dfrac{4\cdot5\cdot6\cdot7\cdot8\cdot9\cdot10}{7!} = 120$