Find the number of integer solutions to the following inequality:
z + w + s + t \leq 30$
so that
$0 \leq z \leq 2$
$4 \leq w \leq 5$
$1 \leq s \leq 5$ and
$2 \leq t \leq 6$
Any help is most appreciated!
Find the number of integer solutions to the following inequality:
z + w + s + t \leq 30$
so that
$0 \leq z \leq 2$
$4 \leq w \leq 5$
$1 \leq s \leq 5$ and
$2 \leq t \leq 6$
Any help is most appreciated!
The sum of the upper limits is $29$. Let us calculate the number of bad cases.
all variables are maximum: $1$ case
one variable is one less than maximum: $6$ cases
one variable is two less than maximum: $5$ cases ($w$ can't be two less)
one variable is three less than maximum: $4$ cases
two variables are both one less than maximum: ${6 \choose 2} = 15$ cases
one variable is one less and another one two less than maximum: $5 + 5 \cdot 4 = 25$ cases
three variables are one less than maximum: ${6 \choose 3} = 20$ cases
In total we have $76$ bad cases, and all in all $2880$ cases, so there are $2880 - 76 = 2804$ solutions to the inequality.