# Determine the number of integer solutions to $x_1 + x_2 + x_3 + x_4 = 19$, where $−5 \le x_i \le 10$ for all $1 \le i \le 4$

What I have so far:

Goal: Using the inclusion exclusion I want to find $$|\overline A_{1}\cap \overline A_{2} \cap \overline A_{3} \cap \overline A_{4}| = |U| - S_{1} + S_{2} - S_{3} + S_{4}$$

$$S_{k} = \sum |\overline A_{i1}\cap \overline A_{i1} \cap ... \overline A_{ik}|$$

I have incremented the values of i by 5 so that the range can start from zero like this:

$$x_{1}+x_{2}+ x_{3} + x_{4} = 24$$ with $$0\leq x_{i} \leq 15$$

For $$|U|$$ I have used to "stars and bars technique":

$$|U| = \binom{r+n-1}{r} = \binom{24+4-1}{3}$$

The Answer

... I am studying for a test (this is a practice question) and my professor has provided a solution that says: $$\binom{42}{39} - \binom{4}{1} \binom{26}{23}+\binom{4}{2}\binom{10}{7}$$

So I don't think I am on the right track if the universal set $$|U| = \binom{42}{39}$$. Any tips would be great thanks in advance.

• Well, one thing if you are incrementing the four $x_i$ by $5$ then total needs to increment by $4*5$. You only incremented it by $5$. – fleablood Nov 19 '18 at 0:38

## 1 Answer

I have incremented the values of i by 5 so that the range can start from zero like this: $$x_1+x_2+x_3+x_4=24$$ with $$0≤x_i≤15$$

Are you sure this is correct? You might need to check that inequality and the equation preceding it.

• After fixing the inequality to $0≤x_i+5≤15$, you should find that $x_1+x_2+x_3+x_4 = 39$. Then using your formula for $|U|$, you should find the answer. – LeNoir Nov 19 '18 at 0:55
• Thanks leNoir that fixed it! – inventiveOak4230 Nov 19 '18 at 4:47