In Matlab/Octave
the function `lu(A)` completes the LU factorization only for
a square matrix `A`, and returns
a lower triangular matrix ,
an upper triangular matrix ,
and a (permutation) matrix .
Since it returns three matrices at once,
the returned matrices must be specified as in the following form:

> [L, U, P] = lu(A)

EXAMPLE 1. Find an LU factorization of

Department of Mathematics