TITLE: What is the number of integer solutions of $2{x_{1}}+2{x_{2}}+{x_{3}}+{x_{4}}={12}$?
QUESTION [6 upvotes]: What is the number of non negative integer solutions of $2{x_{1}}+2{x_{2}}+{x_{3}}+{x_{4}}={12}$ ? 

I tried it as :
${x_{3}}+{x_{4}}={12} - 2{x_{1}}-2{x_{2}}$
Now, finding the solutions of ${x_{1}}+{x_{2}}$

${x_{1}}+{x_{2}} = 0 => 1$ Solution
${x_{1}}+{x_{2}} = 1 => 2$ Solutions
${x_{1}}+{x_{2}} = 2 => 3$ Solutions
${x_{1}}+{x_{2}} = 3 => 4$ Solutions
${x_{1}}+{x_{2}} = 4 => 5$ Solutions
${x_{1}}+{x_{2}} = 5 => 6$ Solutions
${x_{1}}+{x_{2}} = 6 => 7$ Solutions

And, now respectively finding for ${x_{3}}+{x_{4}}$

${x_{3}}+{x_{4}} = 12 => 13$ Solutions
${x_{3}}+{x_{4}} = 10 => 11$ Solutions
${x_{3}}+{x_{4}} = 8 => 9$ Solutions
${x_{3}}+{x_{4}} = 6 => 7$ Solutions
${x_{3}}+{x_{4}} = 4 => 5$ Solutions
${x_{3}}+{x_{4}} = 2 => 3$ Solutions
${x_{3}}+{x_{4}} = 0 => 1$ Solution

Then, Multiplying respective numbers
$1.13 +  2.11 + 3.9 + 4.7 + 5.5 + 6.3 + 7.1 = 140$ Solutions

I don't have answer for it. Am i right here ?

REPLY [2 votes]: Sorry for making this an answer - it's a bit too long for a comment on Elliot's answer.  As Elliot showed we only need to find the coefficient of $x^{12}$ for $(1-x^2)^{-2}(1-x)^{-2}$.  This is quite simple without computer aid with a few tricks.  First notice that $1/(1-x)^2 = 1+2x+3x^2+\cdots$.  Since we are only interested in the coefficient in front of $x^{12}$ we can truncate the series at $x^{12}$.  We have 
$$(1-x^2)^{-2}(1-x)^{-2} = (1+2x^2+3x^4+\cdots)(1+2x+3x^2+\cdots)$$
Since the first factor has only terms of even powers we can ignore the odd powers in the second factor - so we only need to compute the coefficient of $x^{12}$ in
$$(1+2x^2+3x^4+4x^6+5x^8+6x^{10}+7x^{12})(1+3x^2+5x^4+7x^6+9x^8+11x^{10}+13x^{12})$$
Now match terms so that the powers sum to 12 giving
$$
13*1+11*2+9*3+7*4+5*5+3*6+1*7=140
$$
The advantage of this manual method is that it easily generalizes to cases were 12 is replaced by another even number.