# How do you solve x-6y=31 and 6x+9y=-84 using matrices?

Sep 30, 2016

$\left(x , y\right) = \textcolor{g r e e n}{- 5 , - 6}$

#### Explanation:

Given the equations:
$\textcolor{w h i t e}{\text{XXX}} x - 6 y = 31$
$\textcolor{w h i t e}{\text{XXX}} 6 x + 9 y = - 84$

We can write these in "augmented matrix form as:)
color(white)("XXX")( (1,-6,31),(6,9,-84) )

This can be solved using the normal operations we would perform on the original equations (with the variables and equal side "assumed").

$\textcolor{red}{\text{Alternately, we can use Cramer's Rule with Matrix Determinants}}$

$\textcolor{w h i t e}{\text{XXX")color(blue)("Although I demonstrate the soloution (below) using hand calculations}}$
$\textcolor{w h i t e}{\text{XXX")color(blue)("the power of the Matrix Methods lies in their compatibility with}}$
color(white)("XXX")color(blue)("computer systems. For example, the evaluation of Determinants")
$\textcolor{w h i t e}{\text{XXX")color(blue)("is a build-in function for most spreadsheets.}}$

If ${M}_{x y} = \left(\begin{matrix}1 & - 6 \\ 6 & 9\end{matrix}\right) \textcolor{w h i t e}{\text{XX")M_(cy)=((31,-6),(-84,9))color(white)("XX}} {M}_{x c} = \left(\begin{matrix}1 & 31 \\ 6 & - 84\end{matrix}\right)$

$x = \frac{| {M}_{c y} |}{| {M}_{x y} |} \text{ and } y = \frac{| {M}_{x} c |}{| {M}_{x y} |}$

Where the Determinants:
$\textcolor{w h i t e}{\text{XXX}} | {M}_{x y} | = 1 \times 9 - 6 \times \left(- 6\right) = 9 + 36 = 45$

color(white)("XXX")|M_(cy)|= 31xx9-(-84)xx(-6))=279-504=-255

$\textcolor{w h i t e}{\text{XXX}} | {M}_{x c} | = 1 \times \left(- 84\right) - 6 \times 31 = - 84 - 186 = - 270$

Giving
$\textcolor{w h i t e}{\text{XXX}} x = - \frac{255}{45} = - 6$
and
$\textcolor{w h i t e}{\text{XXX}} y = - \frac{270}{45} = - 5$