Cannot solve linear system of equations

It would be nice if somebody could find my mistake for the following linear system of equations:

$$\left\{\begin{array}{rcrcrcr} -2x & - & 4y & - & z & = & -21 \\ -3x & + & y & + & 2z & = & -14 \\ x & - & 2y & - & z & = & a \end{array}\right.$$

It is solvable for all $$a \in \Bbb R$$.

I know that $$y= 3- a$$ , however when I try to solve this system I get a different result. The first thing I did was to subtract the first equation from the third so that I can eliminate $$z$$. The third equation now would be $$3x+2y=a+21.$$

After that I wanted to eradicate the $$z$$ in the second equation so I multiplied the first equation by two and added it to the second equation. My second equation now is: $$-7x-7y=-56.$$

I then went on to eliminate the $$y$$ in the third equation so I multiplied the second equation by 3 and the third equation by 7 and added the second equation to the third. The third equation would now be: $$-7y=7a-33$$ which is equivalent to $$y=-a+\frac{33}{7}$$ which is unequal to the actual solution. Where is my mistake?

• Why?$-z-(-z)=0$, right? – Math Noob Aug 5 '20 at 15:37
• I found the mistake guys. When I multiplied $-56$ by 3 I miscalculated. Instead of $-168$ I calculated $-180$. Everything onwards from that is clear thank you everybody! – Math Noob Aug 5 '20 at 15:55

Adding 3 times the second and 7 times the third equation produces $$-7y = 7a - 168 + 147 = 7a - 21$$.

• Yes, I realized my mistake now, thank you very much for your time. – Math Noob Aug 5 '20 at 15:56

From what you have already done,

$$3x+2y=a+21$$
$$-7x-7y=-56$$ or $$x+y=8$$ or $$3x+3y=24$$.

Subtracting 1 from 2, $$y = 3 - a$$

• That technique is amazing. I do not really ever think about dividing the equations, will do that from now on in the future. Thanks ! – Math Noob Aug 5 '20 at 15:53
• That's almost what you did with the 3 and 7 multiplications, except that they multiplied by 1 and 3/7 ;) – cvanaret Aug 5 '20 at 17:29