Skip to content

Diagonal Matrix

Definition

A diagonal matrix is a square matrix whose off-diagonal entries are all zero.


Interpretation

A diagonal matrix acts on each coordinate separately: Dx\boldsymbol{D}\boldsymbol{x} multiplies the ii-th coordinate of x\boldsymbol{x} by the ii-th diagonal entry and never mixes coordinates.

The unit square mapped by a diagonal matrix onto a rectangle twice as wide and half as tall, with e1 stretched by 2 and e2 shrunk by 1/2.

The matrix D=(20012)\boldsymbol{D}=\begin{pmatrix}2&0\\0&\tfrac{1}{2}\end{pmatrix} stretches e1\boldsymbol{e}_1 to 2e12\boldsymbol{e}_1 and shrinks e2\boldsymbol{e}_2 to 12e2\tfrac{1}{2}\boldsymbol{e}_2, so the unit square becomes a rectangle twice as wide and half as tall. The axes keep their directions, and the area 2⋅12=12\cdot\tfrac{1}{2}=1 is the product of the diagonal entries, the determinant.

A diagonal matrix scales each axis on its own: Ae1=a11e1\boldsymbol{A}\boldsymbol{e}_1=a_{11}\boldsymbol{e}_1 and Ae2=a22e2\boldsymbol{A}\boldsymbol{e}_2=a_{22}\boldsymbol{e}_2. Allow off-diagonal entries to see the axes turn.

Calculations reduce to calculations with numbers: products and powers are taken entry by entry on the diagonal, here Dk=diag⁡(2k,2−k)\boldsymbol{D}^k=\operatorname{diag}(2^k,2^{-k}), and a diagonal matrix is invertible if and only if no diagonal entry is 00, with the reciprocals as inverse. Zeros on the diagonal are allowed, so the zero matrix is diagonal too. Later in the course this simplicity is the reason to bring a matrix into diagonal form where possible.


Key Results

  • The determinant of a diagonal matrix is the product of its diagonal entries.
  • The product and sum of diagonal matrices of the same size are diagonal.

Examples

  • (200−1)\begin{pmatrix}2&0\\0&-1\end{pmatrix} is diagonal.
  • In\boldsymbol{I}_n and 0n\boldsymbol{0}_n are diagonal.

Prerequisites

Sources

Last updated: 20 October 2026 03:02