I've been given the matrix $B$ = $\begin{bmatrix} 1 & 0 & 1 \\ 0 & 1 & -1 \\ 2 & 3 & 1 \end{bmatrix}$ and I would like to find the $LU$ decomposition of $B$. I use row operations to obtain the matrix
$U$ =$\begin{bmatrix} 1 & 0 & 1 \\ 0 & 1 & -1 \\ 0 & 0 & 4 \end{bmatrix}$.
I apply these same operations to the matrix
$Z$ =$\begin{bmatrix} 1 & 0 & 0 \\ & 1 & 0 \\ & & 1 \end{bmatrix}$ to get the matrix $L$ =$\begin{bmatrix} 1 & 0 & 0 \\ 0& 1 & 0 \\ -2&-3 & 1 \end{bmatrix}$.
I'd like to know if my $L$ and $U$ in this given decomposition problem are correct?