Mathwords logoMathwords

Upper Triangular Matrix — Definition, Formula & Examples

An upper triangular matrix is a square matrix where every entry below the main diagonal is zero. The nonzero entries can only appear on or above the diagonal.

A square matrix A=[aij]A = [a_{ij}] of order nn is upper triangular if aij=0a_{ij} = 0 for all i>ji > j, meaning each entry in row ii and column jj vanishes whenever the row index exceeds the column index.

Key Formula

A=[a11a12a1n0a22a2n00ann]A = \begin{bmatrix} a_{11} & a_{12} & \cdots & a_{1n} \\ 0 & a_{22} & \cdots & a_{2n} \\ \vdots & \ddots & \ddots & \vdots \\ 0 & 0 & \cdots & a_{nn} \end{bmatrix}
Where:
  • aija_{ij} = Entry in row i, column j; equals 0 whenever i > j
  • nn = Number of rows (and columns) of the square matrix

Worked Example

Problem: Find the determinant of the upper triangular matrix A=[351024006]A = \begin{bmatrix} 3 & 5 & -1 \\ 0 & 2 & 4 \\ 0 & 0 & 6 \end{bmatrix}.
Verify structure: All entries below the main diagonal are zero, so A is upper triangular.
a21=0,  a31=0,  a32=0a_{21}=0,\; a_{31}=0,\; a_{32}=0
Apply the diagonal-product rule: The determinant of any triangular matrix equals the product of its diagonal entries.
det(A)=a11a22a33=326\det(A) = a_{11} \cdot a_{22} \cdot a_{33} = 3 \cdot 2 \cdot 6
Compute: Multiply the diagonal entries together.
det(A)=36\det(A) = 36
Answer: The determinant of A is 36.

Why It Matters

Gaussian elimination reduces any square matrix to an upper triangular form (row echelon form), which makes computing determinants and solving linear systems far more efficient. Upper triangular matrices also appear in LU decomposition, QR factorization, and the Schur decomposition, all core tools in numerical linear algebra and engineering computations.

Common Mistakes

Mistake: Assuming the diagonal entries of an upper triangular matrix must be nonzero.
Correction: Diagonal entries can be any value, including zero. The only requirement is that all entries below the diagonal are zero. An upper triangular matrix with a zero on the diagonal is singular (non-invertible).