How to Determine the number of integer/natural solutions of:

35 Views Asked by At

How i can determine the number of integer solutions of:

$$x_1+x_2+x_3+x_4+x_5\:=\:35 $$ $$\:8\ge x_1\:\ge 3\space\:\:x_2\ge 0\space\:\:x_3\ge\:0\space\:\:\:x_4\ge \:\:0\:\:\:\:x_5\ge \:\:0$$

How i can determine the number of natural solutions of:

$$x_1+x_2+x_3+x_4+x_5\:=\:35 $$ $$\:7\ge \:x_1\:\ge \:3\space\space\:\:8\ge\:x_2\:\ge\:0\:\space\:\:x_3\ge \:0\space\:\:\:x_4\ge 0\:\:\:\:x_5\ge 0$$

1

There are 1 best solutions below

5
On BEST ANSWER

In these type of questions you can use the following techniques:

If $3 \leq x_1 \leq8$ ,then you can say that $0 \leq x_1 \leq5$ ,so the sum will be $32$ instead of $35$ because we should subtract $3$ from both sides.

Then ,the question turned out to be combination with repetition :$C(32+5-1,32)$

However , $x_1$ should not be greater that $5$ , so we should subtract the situation where $x_1$ is greater than $5$ from the total result (by principle of inclusion-exclusion ).This can be done by :

If $x_1 \geq 6$ ,then by using same technique , we should substract $6$ from the total ; so

$C(32+5-1,32)- C(26+5-1,26)=$ Desired result..

The second can be solved the same technique but there is two restriction ,so when you use inclusion-exclusion , pay attention it !

NOTE: You can use also generating functions to solve it. See https://en.wikipedia.org/wiki/Generating_function