Matrix Inverse

Definition

Technically, we cannot divide matrices. However, the inverse operation defines a second matrix which has some of the same properties as the reciprocal of a number.

The inverse of an $n \times n$ matrix $\mathbf{A}$ is another $n\times n$ matrix, denoted by $\mathbf{A}^{-1}$, with the property that \[\mathbf{A} \mathbf{A}^{-1}=\mathbf{A}^{-1} \mathbf{A} = \mathbf{I}\] where $\mathbf{I}$ is the $n \times n$ identity matrix.

Note: In this context, $\mathbf{A}^{-1}$ does not mean $\frac{1}{\mathbf{A} }$.

Inverse of a $2 \times 2$ matrix

Definition

The inverse of a $2 \times 2$ matrix $\mathbf{A} = \begin{pmatrix} a & b \\ c & d \end{pmatrix}$ is \begin{align} \mathbf{A}^{-1} = \frac{1}{\lvert \mathbf{A} \rvert} \begin{pmatrix} d & -b\\ -c & a \end{pmatrix} = \frac{1}{ad-bc} \begin{pmatrix} d & -b\\ -c & a \end{pmatrix} \end{align}

Note: If the determinant of $\mathbf{A}$ is zero then $\mathbf{A}$ does not have an inverse.

Worked Examples
Example 1

Find the inverse of the matrix $\mathbf{A} = \begin{pmatrix} 3&1 \\ 4&2 \end{pmatrix}$.

Solution

First, find the determinant. \[\lvert \mathbf{A} \rvert = ad - bc = (3 \times 2 - 1 \times 4) = 2\]

Then input the determinant into the formula $\mathbf{A}^{-1} = \dfrac{1}{\lvert \mathbf{A} \rvert}\begin{pmatrix} d & -b \\ -c & a \end{pmatrix}$ \begin{align} \mathbf{A}^{-1} &= \dfrac{1}{2}\begin{pmatrix} 2 & -1 \\ -4 & 3 \end{pmatrix}\\\\ &= \begin{pmatrix} 1 & -\tfrac{1}{2} \\ -2 & \tfrac{3}{2} \end{pmatrix} \end{align}

Example 2

Find the inverse of the matrix $\mathbf{A} = \begin{pmatrix} 3&2 \\ 6&4 \end{pmatrix}$.

Solution

First, find the determinant. \[\lvert \mathbf{A} \rvert = ad - bc = (3 \times 4 - 2 \times 6) = 0\]

The determinant is zero and therefore no inverse exists.

Video Example

Hayley Bishop works out the inverse of the $2\times 2$ matrix $\mathbf{A} = \begin{pmatrix}-2&4\\-1&1\end{pmatrix}$.

Cofactors

Definition

The inverses of larger matrices can be computed by using cofactors.

Let $\mathbf{A}$ be a square matrix. The minor of the entry in the $i^{\text{th} }$ row and the $j^{\text{th} }$ column is the determinant of the submatrix formed by deleting the $i{^\text{th} }$ row and the $j^{\text{th} }$ column. This number is denoted $M_{i,j}$.

The $(i,j)$ cofactor is obtained by multiplying the minor $M_{i,j}$ by $(-1)^{i+j}$.

It is often easier to remember the formula for the general cofactor matrix. The signs of the cofactors alternate.

\[\mathbf{C} = \begin{pmatrix} +M_{11}&-M_{12}&+M_{13}\\-M_{21}&+M_{22}&-M_{23}\\+M_{31}&-M_{32}&+M_{33}\end{pmatrix}\]

Worked Example
Example

Consider the following matrix \[\begin{pmatrix} 1 & 4 & 7\\ 3 & 0 & 5\\ -1 & 9 & 11 \end{pmatrix}\]

Compute $M_{2,3}$ and $C_{2,3}$.

Solution

\begin{align} M_{2,3} &= \det\begin{pmatrix} 1 & 4 & \square\\ \square & \square & \square \\ -1 & 9 & \square \end{pmatrix}\\ &= \det\begin{pmatrix} 1 & 4\\ -1 & 9 \end{pmatrix}\\ &= (9-(-4)) = 13 \end{align}

So the cofactor is

\[C_{2,3} = (-1)^{2+3} \cdot M_{2,3} = -13\]

Inverse of a $3 \times 3$ matrix

Definition

Let $\mathbf{A}$ be a non-singular $3 \times 3$ matrix, i.e. $\det(\mathbf{A}) \neq 0$.

First, we need to make a cofactor matrix containing all the cofactors of the matrix $\mathbf{A}$. We will call this cofactor matrix $\mathbf{C}$.

\[\mathbf{C} = \begin{pmatrix} C_{11}&C_{12}&C_{13}\\C_{21}&C_{22}&C_{23}\\C_{31}&C_{32}&C_{33}\end{pmatrix} = \begin{pmatrix} +M_{11}&-M_{12}&+M_{13}\\-M_{21}&+M_{22}&-M_{23}\\+M_{31}&-M_{32}&+M_{33}\end{pmatrix}\]

The formula for the inverse matrix $A^{-1}$ is \[A^{-1} = \frac{1}{\lvert A \rvert} \mathbf{C} ^\intercal\]

where $\lvert A \rvert$ is the determinant of $\mathbf{A}$ and $\mathbf{C} ^\intercal$ is the transpose of $\mathbf{C}$.

Worked Example
Example

Find the inverse of the matrix $\mathbf{A} = \begin{pmatrix} 7&2&1\\0&3&-1\\-3&4&-2\end{pmatrix}$.

Solution

First, work out the determinant. \begin{align} \lvert \mathbf{A} \rvert &= 7\begin{vmatrix} 3 & -1\\ 4 & -2 \end{vmatrix} -2 \begin{vmatrix} 0 & -1\\ -3 & -2 \end{vmatrix} +1 \begin{vmatrix} 0 & 3\\ -3 & 4 \end{vmatrix}\\\\ &=7\bigl(3\times(-2)-(-1)\times 4\bigr) -2\bigl(0\times(-2) - (-1)\times(-3)\bigr) + 1\bigl(0\times 4 - 3 \times (-3)\bigr)\\ &=7(-2) -2(-3) + 1(9)\\ &=-14 + 6 + 9\\ &= 1 \end{align}

Next, find the cofactor matrix $\mathbf{C}$. \[\mathbf{C} = \begin{pmatrix} +M_{11}&-M_{12}&+M_{13}\\-M_{21}&+M_{22}&-M_{23}\\+M_{31}&-M_{32}&+M_{33}\end{pmatrix}\]

\begin{align} M_{11} &= \begin{vmatrix} 3&-1\\4&-2\end{vmatrix} = 3\times (-2) - 4\times (-1) = -2 \\ M_{12} &= \begin{vmatrix} 0&-1\\-3&-2\end{vmatrix} = 0\times (-2) - (-3) \times (-1) = -3 \\ & \vdots \\ & \text{etc.} \end{align}

So $\mathbf{C} = \begin{pmatrix} -2&3&9\\8&-11&-34\\-5&7&21\end{pmatrix}$

Now work out the transpose of $\mathbf{C}$.

\[\mathbf{C} ^\intercal = \begin{pmatrix} -2&8&-5\\3&-11&7\\9&-34&21\end{pmatrix}\]

Finally, put $\lvert \mathbf{A} \rvert$ and $\mathbf{C} ^\intercal$ into the inverse formula $\mathbf{A}^{-1} = \dfrac{1}{\lvert \mathbf{A} \rvert} \mathbf{C} ^\intercal$.

\begin{align} \mathbf{A}^{-1} &= \dfrac{1}{1}\begin{pmatrix} -2&8&-5\\3&-11&7\\9&-34&21\end{pmatrix}\\\\ &= \begin{pmatrix} -2&8&-5\\3&-11&7\\9&-34&21\end{pmatrix} \end{align}

Video Example

Hayley Bishop finds the inverse of the $3 \times 3$ matrix $\mathbf{A} = \begin{pmatrix}1&2&1\\0&3&1\\-2&4&1 \end{pmatrix}$.

Workbook

This workbook produced by HELM is a good revision aid, containing key points for revision and many worked examples.

Test Yourself

Test yourself: Numbas test on 2x2 inverses

External Resources