# How do you solve using gaussian elimination or gauss-jordan elimination, y + 3z = 6, x + 2y + 4z = 9, 2x + y + 6z = 11?

Apr 1, 2016

Using Gaussian elimination
$\textcolor{w h i t e}{\text{XXX}} \left(x , y , z\right) = \left(\frac{1}{7} , \frac{9}{7} , \frac{11}{7}\right)$

#### Explanation:

Converting the given equations to augmented matrix (to avoid having to re-write the variable names)
$\left\{\begin{matrix}0 & 1 & 3 & 6 \\ 1 & 2 & 4 & 9 \\ 2 & 1 & 6 & 11\end{matrix}\right. \textcolor{w h i t e}{\text{XX}} \left.\begin{matrix}\left[1\right] \\ \left[2\right] \\ \left[3\right]\end{matrix}\right.$

Exchanging rows [1] and [2]
$\left\{\begin{matrix}1 & 2 & 4 & 9 \\ 0 & 1 & 3 & 6 \\ 2 & 1 & 6 & 11\end{matrix}\right. \textcolor{w h i t e}{\text{XX}} \left.\begin{matrix}\left[4\right] \\ \left[5\right] \\ \left[3\right]\end{matrix}\right.$

Note that at this point rows [4] and [5] are in Gaussian form
and all that remains is to zero out the first two columns of row [3]

Subtracting $2$ times row [4] from row [3]
$\left\{\begin{matrix}1 & 2 & 4 & 9 \\ 0 & 1 & 3 & 6 \\ 0 & - 3 & - 2 & - 7\end{matrix}\right. \textcolor{w h i t e}{\text{XX}} \left.\begin{matrix}\left[4\right] \\ \left[5\right] \\ \left[6\right]\end{matrix}\right.$

Adding $3$ times row [5] to row [6]
$\left\{\begin{matrix}1 & 2 & 4 & 9 \\ 0 & 1 & 3 & 6 \\ 0 & 0 & 7 & 11\end{matrix}\right. \textcolor{w h i t e}{\text{XX}} \left.\begin{matrix}\left[4\right] \\ \left[5\right] \\ \left[7\right]\end{matrix}\right.$

Dividing row [7] by $7$
$\left\{\begin{matrix}1 & 2 & 4 & 9 \\ 0 & 1 & 3 & 6 \\ 0 & 0 & 1 & \frac{11}{7}\end{matrix}\right. \textcolor{w h i t e}{\text{XX}} \left.\begin{matrix}\left[4\right] \\ \left[5\right] \\ \left[8\right]\end{matrix}\right.$

This gives us
$\textcolor{w h i t e}{\text{XXX}} z = \frac{11}{7}$

Substituting back into row [5]
$\textcolor{w h i t e}{\text{XXX}} y + 3 \times \frac{11}{7} = 6 \rightarrow y = \frac{9}{7}$

Substituting back into row [4]
$\textcolor{w h i t e}{\text{XXX}} x + 2 \times \frac{9}{7} + 4 \times \frac{11}{7} = 9 \rightarrow x = \frac{1}{7}$