# How do you solve x + 3y + z = 3; x + 5y + 5z = 1; 2x + 6y + 3z = 8 using matrices?

##### 1 Answer
Apr 11, 2018

The solution is $\left(\begin{matrix}x \\ y \\ z\end{matrix}\right) = \left(\begin{matrix}16 \\ - 5 \\ 2\end{matrix}\right)$

#### Explanation:

Perform the Gauss-Jordan elimination on the augmented matrix

$A = \left(\begin{matrix}1 & 3 & 1 & | & 3 \\ 1 & 5 & 5 & | & 1 \\ 2 & 6 & 3 & | & 8\end{matrix}\right)$

Make the pivot in the first column and the first row

Eliminate the first column, perform the row operations

$R 2 \leftarrow R 2 - R 1$, and $R 3 \leftarrow R 3 - 2 R 1$

$= \left(\begin{matrix}1 & 3 & 1 & | & 3 \\ 0 & 2 & 4 & | & - 2 \\ 0 & 0 & 1 & | & 2\end{matrix}\right)$

Make the pivot in the second column by

$R 2 \leftarrow \frac{R 2}{2}$

$= \left(\begin{matrix}1 & 3 & 1 & | & 3 \\ 0 & 1 & 2 & | & - 1 \\ 0 & 0 & 1 & | & 2\end{matrix}\right)$

Eliminate the second column by

$R 1 \leftarrow R 1 - 3 R 2$

$= \left(\begin{matrix}1 & 0 & - 5 & | & 6 \\ 0 & 1 & 2 & | & - 1 \\ 0 & 0 & 1 & | & 2\end{matrix}\right)$

Make the pivot in the second column, and eliminate the third column

$R 1 \leftarrow R 1 + 5 R 3$ and $R 2 \leftarrow R 2 - 2 R 3$

$= \left(\begin{matrix}1 & 0 & 0 & | & 16 \\ 0 & 1 & 0 & | & - 5 \\ 0 & 0 & 1 & | & 2\end{matrix}\right)$

The solution is

$\left(\begin{matrix}x \\ y \\ z\end{matrix}\right) = \left(\begin{matrix}16 \\ - 5 \\ 2\end{matrix}\right)$