# Determine number of non-negative integer solutions for both equalities

$$x_1 + x_2 + x_3 = 6$$

$$\dbinom{3+6-1}{6} = \dbinom{8}{6} = 28 \text{ possible integer solutions}$$

$$x_1 + x_2 + x_3 + x_4 + x_5 = 15$$

$\dbinom{5+15-1}{15} = \dbinom{19}{15} = 3876 \text{ possible integer solutions}$

I solved those individually, but the question asks for the number of solutions that solve BOTH. How would I solve for the union of the two?

-

Hint: $$x_1 + x_2 + x_3 = 6,\quad x_4 + x_5 = 9$$

-
Wait, so it isn't $\dbinom{3+6-1}{6} \dbinom{2+9-1}{9}$? – JiminP May 7 '13 at 15:20
Tim Lee is looking for the number of integer solutions for both equations. – NasuSama May 7 '13 at 15:21
Should I have added "Hint:"? – JiminP May 7 '13 at 15:23
I don't see what's wrong with this. ($+1)$ – Inceptio May 7 '13 at 15:24

Hint:

$x_1+x_2+x_3=6$ and is a constant in the second equation.

You get $x_4+x_5 =9 \implies$Number of solutions is $9+2-1 \choose 9$

You can continue from here.

-

This doesn't answer your question directly, but I can't help mentioning that Generating functions are helpful with these kinds of problems. For the first problem, note that $x_i$ can be either $0, 1, 2, 3, 4, 5$, or $6$.

Thus, you are after the coefficient of $x^6$ in the product

$$(x^0 + x^1 + x^2 + x^3 + x^4+x^5+x^6)^3,$$ which is easily computed as $28$.

For the second problem, you would need to compute the coefficient of $x^{15}$ in the product

$$\left( \sum_{k=0}^{15} x^k \right)^5$$

You can easily use generating functions to solve the problem about which you posted by using the other answerer's observation that you are really counting solutions to $x_4 + x_5 = 9$, where $0 \leq x_i \leq 9$.

-