If $A=\left[\begin{array}{rrr}1 & -1 & 0 \\ 2 & 3 & 4 \\ 0 & 1 & 2\end{array}\right]$ and $B=\left[\begin{array}{rrr}2 & 2 & -4 \\ -4 & 2 & -4 \\ 2 & -1 & 5\end{array}\right]$ are two square matrices, find $A B$ and hence solve the system of linear equations:
$x-y=3,2 x+3 y+4 z=17, y+2 z=7$
Here,
$A=\left[\begin{array}{ccc}1 & -1 & 0 \\ 2 & 3 & 4 \\ 0 & 1 & 2\end{array}\right]$ and $B=\left[\begin{array}{ccc}2 & 2 & -4 \\ -4 & 2 & -4 \\ 2 & -1 & 5\end{array}\right]$
Now,
$A B=\left[\begin{array}{ccc}1 & -1 & 0 \\ 2 & 3 & 4 \\ 0 & 1 & 2\end{array}\right]\left[\begin{array}{ccc}2 & 2 & -4 \\ -4 & 2 & -4 \\ 2 & -1 & 5\end{array}\right]$
$\Rightarrow A B=\left[\begin{array}{ccc}6 & 0 & 0 \\ 0 & 6 & 0 \\ 0 & 0 & 6\end{array}\right]$
$\Rightarrow A B=6\left[\begin{array}{lll}1 & 0 & 0 \\ 0 & 1 & 0 \\ 0 & 0 & 1\end{array}\right]$
$\Rightarrow A B=6 I_{3}$
$\Rightarrow \frac{1}{6} A B=I_{3}$
$\Rightarrow\left(\frac{1}{6} B\right) A=I_{3} \quad(\because A B=B A)$
$\Rightarrow A^{-1}=\frac{1}{6} B$
$\Rightarrow A^{-1}=\frac{1}{6}\left[\begin{array}{ccc}2 & 2 & -4 \\ -4 & 2 & -4 \\ 2 & -1 & 5\end{array}\right]$
$X=A^{-1} B$
$X=\frac{1}{6}\left[\begin{array}{ccc}2 & 2 & -4 \\ -4 & 2 & -4 \\ 2 & -1 & 5\end{array}\right]\left[\begin{array}{c}3 \\ 17 \\ 7\end{array}\right]$
$\left[\begin{array}{l}x \\ y \\ z\end{array}\right]=\frac{1}{6}\left[\begin{array}{c}6+34-28 \\ -12+34-28 \\ 6-17+35\end{array}\right]$
$\left[\begin{array}{l}x \\ y \\ z\end{array}\right]=\frac{1}{6}\left[\begin{array}{c}12 \\ -6 \\ 24\end{array}\right]$
$\therefore x=2, y=-1$ and $z=4$