Given the system of equations:
x + y - z = 4 eq.(1)
3x + 2y + 4z = 17 eq.(2)
-x + 5y + z = 8 eq.(3)
Add the equations 1 and 3
so,
x + y - z + ( -x + 5y + z ) = 4 + 8
x + y - z - x + 5y + z = 12
6y = 12
y = 12/6 = 2
Substitute with y at eq. (1)
So,
x + 2 - z = 4
x - z = 4 - 2
x - z = 2 eq. (4)
Substitute with y at eq.(2)
3x + 2 * 2 + 4z = 17
3x + 4 + 4z = 17
3x + 4z = 17 - 4
3x + 4z = 13 eq.(5)
solve the equations (4) and (5) together
x - z = 2
3x + 4z = 13
Multiply [ x - z = 2 ] by 4
4x - 4z = 8
3x + 4z = 13
Add the last two equations
4x - 4z + 3x + 4z = 8 + 13
7x = 21
Divide both sides by 7
x = 21/7 = 3
So, x = 3 and y = 2
Substitute with the values of x and y at the equation [ -x + 5y + z = 8 ]
So,
-3 + 5 * 2 + z = 8
solve for z
-3 + 10 + z = 8
z = 8 + 3 - 10
z = 11 - 10 = 1
So,
x = 3 , y = 2 and z = 1