Determine the number of integer solutions of the equation $ x_{1}+x_{2}+x_{3}+x_{4}=20 $ Determine the number of integer solutions of the equation
$$
x_{1}+x_{2}+x_{3}+x_{4}=20
$$
under the restrictions:
$$
\begin{array}{l}
2 \leq x_{1} \leq 6 \\
0 \leq x_{2} \leq 5 \\
2 \leq x_{3} \leq 8 \\
2 \leq x_{4} \leq 6
\end{array}
$$
I did $x_1=y_1+2$ then $0\leq y_1 \leq4$
$x_2=y_2$ then $0\leq y_2 \leq5$
$x_3=y_3+2$ then $0\leq y_3 \leq6$
$x_4=y_4+2$ then $0\leq y_4 \leq4$
So $y_1+y_2+y_3+y_4 \leq 19$
So the number of solutions is
$\sum_{k=0}^{19}\left(\begin{array}{c}
k+3 \\
k
\end{array}\right)=\sum_{k=0}^{19}\left(\begin{array}{c}
k+3 \\
3
\end{array}\right)$
is right?

The combined values of the maximum value for the $x$'s is 25. We can then take four part ordered partitions of $5$ (including zeros) and subtract each of those from the maximum.
The first set of partitions is $(5,0,0,0)$ with the $5$ being in four potential locations.
You cannot subtract $5$ from $x_1$ or $x_4$ so there are $2$ ways of doing this.
The second set of partitions is
$(4,1,0,0)$. There are $12$ ways of ordering these numbers.
The third set of partitions is $(3,2,0,0)$.There are $12$ ways of ordering these numbers.
The fourth set is $(3,1,1,0)$.There are $12$ ways of ordering these numbers.
The fifth set is $(2,2,1,0)$.There are $12$ ways of ordering these numbers.
Finally the sixth and last set is $(2,1,1,1)$. There are four locations for the $2$. Therefore there are $4$ ways of ordering these numbers.
$2+12+12+12+12+4=54$
There are $54$ solutions to the equation $x_1+x_2+x_3+x_4=20$.
