Answer
$\begin{bmatrix}1&0&0&0&|&1&0&0&0\\0&1&0&0&|&0&-1&0&0\\0&0&1&0&|&0&0&\dfrac{1}{3}&0\\0&0&0&1&|&-1&0&0&1\end{bmatrix}$
Work Step by Step
We are given the matrix:
$A=\begin{bmatrix}1&0&0&0\\0&-1&0&0\\0&0&3&0\\1&0&0&1\end{bmatrix}$
We start with the matrix:
$\begin{bmatrix}1&0&0&0&|&1&0&0&0\\0&-1&0&0&|&0&1&0&0\\0&0&3&0&|&0&0&1&0\\1&0&0&1&|&0&0&0&1\end{bmatrix}$
Add $-R_1$ to $R_4$:
$\begin{bmatrix}1&0&0&0&|&1&0&0&0\\0&-1&0&0&|&0&1&0&0\\0&0&3&0&|&0&0&1&0\\0&0&0&1&|&-1&0&0&1\end{bmatrix}$
Multiply $R_2$ by -1:
$\begin{bmatrix}1&0&0&0&|&1&0&0&0\\0&1&0&0&|&0&-1&0&0\\0&0&3&0&|&0&0&1&0\\0&0&0&1&|&-1&0&0&1\end{bmatrix}$
Multiply $R_3$ by $\dfrac{1}{3}$:
$\begin{bmatrix}1&0&0&0&|&1&0&0&0\\0&1&0&0&|&0&-1&0&0\\0&0&1&0&|&0&0&\dfrac{1}{3}&0\\0&0&0&1&|&-1&0&0&1\end{bmatrix}$