Triangular Matrices
Definition of a Upper Triangular Matrix
A square matrix is an upper triangular matrix if and only if all its entries below the entries in the main diagonal are equal to zero.
These are examples of upper triangular matrices.
Main diagonal entries are in red and all entries below them, in blue, are equal to zero.
Definition of a Lower Triangular Matrix
A square matrix is a lower triangular matrix if and only if all its entries above the entries in the main diagonal are equal to zero.
These are examples of lower triangular matrices.
Main diagonal entries are in red and all entries above them, in blue, are equal to zero.
Properties of the triangular Matrices
Some of the most important properties of the triangular matrices are given below.
 The determinant of a triangular matrix is equal to the product of all entries in the main diagonal.
 The transpose of an upper triangular matrix is a lower triangular matrix.
 The transpose of an lower triangular matrix is an upper triangular matrix.
 The product of lower triangular matrices is a lower triangular matrix. The product of upper triangular matrices is an upper triangular matrix.
 The sum (or difference) of lower triangular matrices is a lower triangular matrix. The sum (or difference) of upper triangular matrices is an upper triangular matrix.
 A triangular matrix is invertible (has an inverse) if and only if none of its entries in the main diagonal is zero.
 The inverse of an invertible upper triangular matrix is an upper triangular matrix. The inverse of an invertible lower triangular matrix is a lower triangular matrix.
Examples with Solutions
Example 1
Which of the following matrices is an upper triangular matrix, a lower triangular matrix or none?
Solution
a) None: Matrix \( A \) is not square and therefore is not triangular.
b) Upper: Matrix \( B \) is a square matrix with the main diagonal entries \( \{ 2, 0, 1 \} \). It is an upper triangular matrix because all its entries below the main diagonal entries are equal to zero.
c) Lower: Matrix \( C \) is a square matrix with the main diagonal entries \( \{ 1, 7, 2, 3 \} \). It is a lower triangular matrix because all its entries above the main diagonal entries are equal to zero.
d) None: Matrix \( D \) is a square matrix with the main diagonal entries \( \{ 1, 1, 1, 0 \} \). It is not a triangular matrix because entries not equal to zero are above \( 9 \) and below \( 4 \) the main diagonal entries.
Example 2
Find the determinant of each of the following matrices
a) \( A =
\begin{bmatrix}
3 & 0 & 0 \\
1 & 1 & 0 \\
2 & 3 & 2
\end{bmatrix} \) b) \( B =
\begin{bmatrix}
x & 0 & 1 \\
0 & x+1 & 1 \\
0 & 0 & x
\end{bmatrix} \) c) \( C =
\begin{bmatrix}
1 & 0 & 0 & 0\\
5 & 9 & 0 & 0\\
5 & 4 & 7 & 0\\
5 & 0 & 0 & 0
\end{bmatrix} \)
Solution
a) Matrix \( A \) is a lower triangular matrix and therefore its determinant is equal to the product of its entries in the main diagonal. Hence
\( Det(A) = (3)(1)(2) = 6 \)
b) Matrix \( B \) is an upper triangular matrix and its determinant is is equal to the product of its entries in the main diagonal. Hence
\( Det(B) = x(x+1)x = x^3 + x^2\)
c) Matrix \( C \) is a lower triangular matrix and its determinant is is equal to the product of its entries in the main diagonal. Hence
\( Det(C) = (1)(9)(7)(0) = 0\)
Example 3
Find all real values of \( x \) for which the matrix \( A = \begin{bmatrix}
x1 & 0 & 0 & 0\\
5 & x+1 & 0 & 0\\
5 & 4 & x^2 + 5 & 0\\
5 & 0 & x+2 & 3
\end{bmatrix} \) is not invertible.
Solution
The given matrix is a lower triangular matrix and its determinant is is equal to the product of its entries in the main diagonal. Hence
\( Det(A) = (x1)(x+1)(x^2+5)(3) \)
Matrix \( A \) is not invertible if its determinant is equal to zero. The determinant of matrix \( A \) is equal to zero if one of the factors of \( Det(A) \) is equal to zero.
\( x  1 = 0 \) gives the solution \( x = 1 \)
\( x + 1 = 0 \) gives the solution \( x =  1 \)
\( x^2 + 5 = 0 \) has no real solutions
The values of \( x \) for which the given matrix is not invertible are \( 1 \) and \( 1 \).
Example 4
Find the inverse of matrix \( A = \begin{bmatrix}
1 & 0\\
2 & 4
\end{bmatrix} \) and verify property 6 given above.
Solution
Use the formula of the inverse of a \( 2 \times 2 \) matrix \( \begin{bmatrix}
x & y \\
z & w \\
\end{bmatrix}^{1} = \dfrac{1}{xw  yz}
\begin{bmatrix}
w &  y \\
 z & x \\
\end{bmatrix} \) to find \( A^{1} \)
\( A^{1} = \dfrac{1}{4}
\begin{bmatrix}
1 & 0 \\
2 & 1 \\
\end{bmatrix} =
\begin{bmatrix}
\dfrac{1}{4} & 0 \\
\dfrac{1}{2} & \dfrac{1}{4} \\
\end{bmatrix}
\)
Conclusion: Both \( A \) and its inverse are lower triangular matrices which verify property 6 above.
Example 5
Let \( A = \begin{bmatrix}
3 & 0 & 0\\
5 & 2 & 0 \\
9 & 2 & 4
\end{bmatrix} \), \( B = \begin{bmatrix}
2 & 0 & 0\\
0 & 2 & 0 \\
3 & 4 & 1
\end{bmatrix} \) and \( C = \begin{bmatrix}
7 & 0 & 0\\
1 & 0 & 0 \\
12 & 2 & 3
\end{bmatrix} \).
Which of the following matrices \( A , \; B ,\; C ,\; A B ,\; A C,\; A + C \) is invertible?
Solution
A matrix with a determinant not equal to zero in invertible.
\( Det(A) = (3)(2)(4) = 24 \) , hence matrix \( A \) is invertible.
\( Det(B) = (2)(2)(1) = 4 \) , hence matrix \( B \) is invertible.
\( Det(C) = (7)(0)(3) = 0 \) , hence matrix \( C \) is NOT invertible.
The determinant of the product of two matrices is equal to the product of their determinants
\( Det(A B) = Det(A) Det(B) = (24)(4) = 96 \) , hence matrix \( A B \) is invertible.
\( Det(A C) = Det(A) Det(C) = (24)(0) = 0 \) , hence matrix \( A C \) is NOT invertible.
\( Det(A+C) =
Det \left(\begin{bmatrix}
3 & 0 & 0\\
5 & 2 & 0 \\
9 & 2 & 4
\end{bmatrix} + \begin{bmatrix}
7 & 0 & 0\\
1 & 0 & 0 \\
12 & 2 & 3
\end{bmatrix} \right)
\)
\(
\quad \quad =
Det \begin{bmatrix}
10 & 0 & 0\\
4 & 2 & 0 \\
21 & 4 & 7
\end{bmatrix} = (7) (2) (7) = 98
\) , hence matrix \( A + C \) is invertible.
Questions (with solutions given below)

Part 1
Matrices \( A \) and \( B \) are such that \( A B = B A = I \) where \( I \) is the identity matrix . Use any of the properties above to explain that if one of the matrices is a lower triangular, then the other one is also a lower triangular matrix.

Part 2
Given the \( 2 \times 2\) matrices \( A = \begin{bmatrix} x^2  1 & & 5 \\ \\ 0 & & x \end{bmatrix} \) and \( B = \begin{bmatrix} y & & 0 \\ \\ 2 & & y^24 \end{bmatrix} \).
Find all values of \( x \) and \( y \) such that the matrix \( A B \) is not invertible.

Part 3
Let matrix \( A = \begin{bmatrix}  1 & 3 & 7\\ 0 & c  1 & 3 \\ 0 & 0 & c^2  7 \end{bmatrix} \). Find all real numbers \( c \) so that matrix \( A \) is singular.
Solutions to the Above Questions

Part 1
According to the definition of the inverse matrix, if \( A B = B A = I \) where \( I \) is the identity matrix, then matrices \( A \) and \( B \) are inverses of each other.
According to property 6 above, if \( A \) is a lower triangular matrix then its inverse \( B \) is also a lower triangular matrix and if \( B \) is a lower triangular its inverse \( A \) is also a lower triangular.

Part 2
A matrix is invertible if its determinant is not equal to zero.
\( Det(AB) = Det (A) Det (B) = (x^21)(x)(y)(y^24) \)
Matrix \( A B \) is not invertible if any of the factors of \( Det(AB) \) is equal to zero.
\( x^2  1 = 0 \) gives the solutions \( x = 1 \) and \( x =  1 \)
\( y^2  4 = 0 \) gives the solutions \( y = 2 \) and \( y =  2\)
Hence matrix \( A B \) is not invertible for any of these values of \( x\) or \( y \): \( x = 0, x =  1 , x = 1 , y = 0 , y =  2 , y = 2 \)

Part 3
A square matrix is singular if and only if its determinant is equal to zero.
\( Det(A) = (1)(c1)(c^27) \)
\( Det(A) = 0 \) if
\( c  1 = 0 \) which gives \( c = 1 \)
or
\( c^27 = 0 \) which gives \( c = \sqrt 7 \) , \( c =  \sqrt 7 \)
Matrix \( A \) is singular for: \( c = 1 \), \( c = \sqrt 7 \) or \( c =  \sqrt 7 \)
More References and links
 Matrices with Examples and Questions with Solutions.
 Determinant of a Square Matrix.
 Inverse Matrix Questions with Solutions.
 Elementary Linear Algebra  7 th Edition  Howard Anton and Chris Rorres
 Introduction to Linear Algebra  Fifth Edition (2016)  Gilbert Strang
 Linear Algebra Done Right  third edition, 2015  Sheldon Axler
 Linear Algebra with Applications  2012  Gareth Williams