Math Core

Lesson 9.3 · Systems and Matrices

Inverse matrices

To solve 5x=155x = 15, you multiply both sides by 15\dfrac{1}{5}, the number that undoes multiplication by 55. The matrix equation AX=BAX = B calls for the same move, but there is no such thing as dividing by a matrix. Instead, you multiply by the inverse matrix A−1A^{-1}, the matrix that undoes AA. This lesson shows when an inverse exists, how to find it and how to use it to solve systems.

What an inverse is

Definition

Inverse matrix

Let AA be an n×nn \times n square matrix. If there is an n×nn \times n matrix A−1A^{-1} with

AA−1=IandA−1A=I,AA^{-1} = I \quad\text{and}\quad A^{-1}A = I,

then A−1A^{-1} is the inverse of AA, and AA is called invertible (or nonsingular). A square matrix with no inverse is singular.

Only square matrices can have inverses, and when an inverse exists it is unique. Just as 00 has no reciprocal, some nonzero matrices have no inverse either. You will see exactly which ones below.

To verify that two matrices are inverses, multiply them and check that you get the identity.

Worked example: Checking an inverse

Show that A=[2153]A = \begin{bmatrix} 2 & 1 \\ 5 & 3 \end{bmatrix} and C=[3−1−52]C = \begin{bmatrix} 3 & -1 \\ -5 & 2 \end{bmatrix} are inverses.

AC=[2(3)+1(−5)2(−1)+1(2)5(3)+3(−5)5(−1)+3(2)]=[1001].AC = \begin{bmatrix} 2(3) + 1(-5) & 2(-1) + 1(2) \\ 5(3) + 3(-5) & 5(-1) + 3(2) \end{bmatrix} = \begin{bmatrix} 1 & 0 \\ 0 & 1 \end{bmatrix}.

Computing CACA the same way also gives II, so C=A−1C = A^{-1}. (For square matrices, it turns out that if AC=IAC = I then CA=ICA = I automatically, so one product is enough in practice.)

The 2 × 2 formula

For 2×22 \times 2 matrices there is a short formula. The number ad−bcad - bc that appears in it is called the determinant of the matrix, which you will study in depth in the next lesson.

Inverse of a 2 × 2 matrix

For A=[abcd]A = \begin{bmatrix} a & b \\ c & d \end{bmatrix},

A−1=1ad−bc[d−b−ca]provided ad−bc≠0.A^{-1} = \frac{1}{ad - bc} \begin{bmatrix} d & -b \\ -c & a \end{bmatrix} \qquad \text{provided } ad - bc \ne 0.

In words: swap the main-diagonal entries, negate the other two, and divide by ad−bcad - bc. If ad−bc=0ad - bc = 0, the matrix is singular.

You can confirm the formula by multiplying: the top-left entry of A[d−b−ca]A \begin{bmatrix} d & -b \\ -c & a \end{bmatrix} is ad−bcad - bc, the off-diagonal entries are −ab+ba=0-ab + ba = 0 and cd−dc=0cd - dc = 0, and the bottom-right entry is −cb+da-cb + da. So the product is (ad−bc)I(ad - bc)I, and dividing by ad−bcad - bc leaves II.

Worked example: Using the formula

Find the inverse of A=[4726]A = \begin{bmatrix} 4 & 7 \\ 2 & 6 \end{bmatrix}.

Here ad−bc=4(6)−7(2)=24−14=10ad - bc = 4(6) - 7(2) = 24 - 14 = 10, which is not zero, so AA is invertible.

A−1=110[6−7−24]=[0.6−0.7−0.20.4].A^{-1} = \frac{1}{10} \begin{bmatrix} 6 & -7 \\ -2 & 4 \end{bmatrix} = \begin{bmatrix} 0.6 & -0.7 \\ -0.2 & 0.4 \end{bmatrix}.

Finding larger inverses by row reduction

For 3×33 \times 3 and larger matrices, the reliable method uses the row operations from the first lesson. Write AA next to the identity to form [ A∣I ][\,A \mid I\,], then row-reduce until the left side becomes II. The right side is then A−1A^{-1}:

[ A∣I ]  ⟶  [ I∣A−1 ].[\,A \mid I\,] \;\longrightarrow\; [\,I \mid A^{-1}\,].

Why does this work? Each row operation is the same as multiplying on the left by some matrix. The combination of all of them turns AA into II, so together they equal A−1A^{-1}, and applying them to II produces A−1I=A−1A^{-1}I = A^{-1}. If you ever get a row of zeros on the left side, AA is singular and has no inverse.

Worked example: A 3 × 3 inverse

Find A−1A^{-1} for A=[110121012]A = \begin{bmatrix} 1 & 1 & 0 \\ 1 & 2 & 1 \\ 0 & 1 & 2 \end{bmatrix}.

Start with [ A∣I ][\,A \mid I\,] and apply R2−R1R_2 - R_1:

[110100011−110012001]\left[\begin{array}{ccc|ccc} 1 & 1 & 0 & 1 & 0 & 0 \\ 0 & 1 & 1 & -1 & 1 & 0 \\ 0 & 1 & 2 & 0 & 0 & 1 \end{array}\right]

Now R3−R2R_3 - R_2:

[110100011−1100011−11]\left[\begin{array}{ccc|ccc} 1 & 1 & 0 & 1 & 0 & 0 \\ 0 & 1 & 1 & -1 & 1 & 0 \\ 0 & 0 & 1 & 1 & -1 & 1 \end{array}\right]

Clear upward: R2−R3R_2 - R_3, then R1−R2R_1 - R_2:

[1003−21010−22−10011−11]\left[\begin{array}{ccc|ccc} 1 & 0 & 0 & 3 & -2 & 1 \\ 0 & 1 & 0 & -2 & 2 & -1 \\ 0 & 0 & 1 & 1 & -1 & 1 \end{array}\right]

So A−1=[3−21−22−11−11]A^{-1} = \begin{bmatrix} 3 & -2 & 1 \\ -2 & 2 & -1 \\ 1 & -1 & 1 \end{bmatrix}. Spot-check one entry of AA−1AA^{-1}: row 1 of AA times column 1 of A−1A^{-1} is 1(3)+1(−2)+0(1)=11(3) + 1(-2) + 0(1) = 1. ✓

Solving systems with inverses

If AA is invertible, multiply both sides of AX=BAX = B on the left by A−1A^{-1}:

A−1AX=A−1B⟹IX=A−1B⟹X=A−1B.A^{-1}AX = A^{-1}B \quad\Longrightarrow\quad IX = A^{-1}B \quad\Longrightarrow\quad X = A^{-1}B.

This is especially efficient when you must solve several systems with the same coefficients and different constants: find A−1A^{-1} once and reuse it.

Worked example: Solving a system with an inverse

Solve 2x+y=42x + y = 4 and 5x+3y=75x + 3y = 7.

The coefficient matrix is A=[2153]A = \begin{bmatrix} 2 & 1 \\ 5 & 3 \end{bmatrix}, whose inverse from the first example is [3−1−52]\begin{bmatrix} 3 & -1 \\ -5 & 2 \end{bmatrix}. So

[xy]=[3−1−52][47]=[12−7−20+14]=[5−6].\begin{bmatrix} x \\ y \end{bmatrix} = \begin{bmatrix} 3 & -1 \\ -5 & 2 \end{bmatrix} \begin{bmatrix} 4 \\ 7 \end{bmatrix} = \begin{bmatrix} 12 - 7 \\ -20 + 14 \end{bmatrix} = \begin{bmatrix} 5 \\ -6 \end{bmatrix}.

The solution is (5,−6)(5, -6). Check: 2(5)+(−6)=42(5) + (-6) = 4 and 5(5)+3(−6)=75(5) + 3(-6) = 7. ✓

Common mistake

The solution is X=A−1BX = A^{-1}B, not X=BA−1X = BA^{-1}. Because matrix multiplication is not commutative, the side matters. Here BB is a column, so BA−1BA^{-1} is not even defined. The same care applies to products: (AB)−1=B−1A−1(AB)^{-1} = B^{-1}A^{-1}, with the order reversed, because (AB)(B−1A−1)=A(BB−1)A−1=AA−1=I(AB)(B^{-1}A^{-1}) = A(BB^{-1})A^{-1} = AA^{-1} = I.

Tip

If AA is singular, AX=BAX = B has either no solution or infinitely many. The inverse method cannot tell you which, so fall back on Gaussian elimination.

Practice

Practice 1

Is [2412]\begin{bmatrix} 2 & 4 \\ 1 & 2 \end{bmatrix} invertible?

Practice 2

Let A=[3512]A = \begin{bmatrix} 3 & 5 \\ 1 & 2 \end{bmatrix}. What is the entry in row 1, column 2 of A−1A^{-1}?

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 3

Let A=[4232]A = \begin{bmatrix} 4 & 2 \\ 3 & 2 \end{bmatrix}. What is the entry in row 2, column 1 of A−1A^{-1}?

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 4

Which matrix is the inverse of [2312]\begin{bmatrix} 2 & 3 \\ 1 & 2 \end{bmatrix}?

Practice 5

Use an inverse matrix to solve 3x+5y=13x + 5y = 1 and x+2y=0x + 2y = 0.

Enter a point like (2, -3)

Practice 6

For what value of kk is [k623]\begin{bmatrix} k & 6 \\ 2 & 3 \end{bmatrix} singular?

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 7

Let A=[121011122]A = \begin{bmatrix} 1 & 2 & 1 \\ 0 & 1 & 1 \\ 1 & 2 & 2 \end{bmatrix}. Use row reduction on [ A∣I ][\,A \mid I\,] to find A−1A^{-1}. What is the entry in row 1, column 2 of A−1A^{-1}?

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 8

AA and BB are invertible 2×22 \times 2 matrices. Which expression equals (AB)−1(AB)^{-1}?