Is there a difference in solving problems with generating functions and combinatorics?

60 Views Asked by At

I am preparing for an exam and I saw the following question in last year's test:

Suppose we want to donate in total 160 Euros to 3 student associations R1, R2 and R3, such that each gets at least 40 Euros, but at most 60 Euros. How many possibilities are there to do that? Use a generating function to compute your answer

Would the answer be smaller, the same, or larger when asking for the number of possibilities to divide 160 Euros into three parts, with the same restrictions on minimal and maximal amounts?

In this course we have studied generating functions. I can solve the first part, what confuses me is the last question. To me it seems like the answer would be the same, but I feel like they would not ask the question if it were like that. Can anyone help me understand this?

Edit: Does it have anything to do with polynomials VS power series?

2

There are 2 best solutions below

2
On

I think the difference in the two questions is whether order matters. In the first question, R1=45, R2=55, R3=60 is different from R1=60, R2=55, R3=45. But in the second question, division in to three parts 45,55,60 is the same as division into three parts 60,55,45.

1
On

Using generating functions, what R1 (respectively R2, R3) gets, respecting the limits, is represented by:

$\begin{align*} z^{40} + z^{41} + \dotsb + z^{60} &= z^{40} \cdot \frac{1 - z^{21}}{1 - z} \end{align*}$

All possibilities to distribute monies is then represented by:

$\begin{align*} \left( z^{40} + z^{41} + \dotsb + z^{60} \right)^3 &= z^{120} \cdot \frac{(1 - z^{21})^3}{(1 - z)^3} \end{align*}$

You want to distribute 160€, so you are interested in:

$\begin{align*} [z^{160}] z^{120} \cdot \frac{(1 - z^{21})^3}{(1 - z)^3} &= [z^{40}] \frac{(1 - z^{21})^3}{(1 - z)^3} \\ &= [z^{40}] \left( \sum_k (-1)^k \binom{3}{k} z^{21 k} \right) \cdot \left( \sum_j (-1)^k \binom{-3}{j} z^j \right) \\ &= [z^{40}] \sum_{k, j} (-1)^k \binom{3}{k} (-1)^j \binom{j + 3 - 1}{3 - 1} z^{21 k + j} \\ &= \sum_{21 k + j = 40} (-1)^{k + j} \binom{3}{k} (-1)^j \binom{j + 2}{2} \\ &= (-1)^{0 + 40} \binom{3}{0} \binom{40 + 2}{2} + (-1)^{1 + 19} \binom{3}{1} \binom{19 + 2}{2} \\ &= 1 \cdot \frac{42 \cdot 41}{2} - 3 \cdot \frac{21 \cdot 20}{2} \\ &= 231 \end{align*}$

If order doesn't matter, you get less solutions (R1 gets 45, R2 gets 55, R3 gets 60 is not the same as 60, 55, 45).