Learn
Lesson · Systems and Matrices · Matrices

Inverse Matrices

The inverse of A is the matrix that multiplies with it to give the identity, and it turns AX = B into X = A⁻¹B. Unlike numbers, where only zero has no reciprocal, a square matrix can fail to have an inverse without being the zero matrix — and the determinant decides which matrices do.

A A⁻¹ = A⁻¹ A = I I = [ 1 0 ; 0 1 ] [ a b ]⁻¹ 1 [ d -b ] [ c d ] = ------- · [ -c a ] swap a and d, ad - bc negate b and c
The identity, and the inverse of a 2 by 2

Core ideas

What this lesson establishes

The inverse is defined by what it does, not by the formula that finds it. The formula is a convenience for one size of matrix; the definition is the thing that transfers.

1

The inverse is defined by a product, not by a recipe

A⁻¹ is the matrix with AA⁻¹ = A⁻¹A = I. Both orders are written into the definition because matrix multiplication does not commute, as “Matrix Products” established. For square matrices one product turns out to force the other, but that is a theorem and not something to assume.

2

A matrix can fail to have an inverse without being zero

Among numbers only 0 lacks a reciprocal. Among matrices, every one with determinant 0 lacks an inverse, and [ 2 3 ; 4 6 ] has no zero entry anywhere. Such a matrix is called singular; the word for one that does have an inverse is nonsingular.

3

X = A⁻¹B is a formula for the solution, not the fastest route to it

Finding A⁻¹ costs a full row reduction, and then a multiplication. Solving one system directly costs the row reduction alone. The inverse earns its keep when the same A is used with several different Bs.

The material

The identity, the inverse, and the two ways to find one

A definition, a formula that works for 2 by 2, and a method that works for any size.

“Matrix Products” gave matrix multiplication, and with it a way to write a whole system as one equation. The system 4x + 7y = 1, 2x + 6y = 8 becomes AX = B with A = [ 4 7 ; 2 6 ], X = [ x ; y ] and B = [ 1 ; 8 ]. Written that way it looks like a single equation asking to be divided by A.

There is no division of matrices. What replaces it is multiplication by an inverse, and the first job is to say what an inverse is.

Definition · Identity matrix

Iₙ is the n by n matrix with 1 down the main diagonal and 0 everywhere else. For any matrix A of matching size, AI = IA = A. It is the matrix that behaves the way 1 behaves among numbers.

Definition · Inverse matrix

For a square matrix A, an inverse is a matrix A⁻¹ of the same size with AA⁻¹ = A⁻¹A = I. A matrix has at most one inverse. Non-square matrices are excluded outright: AA⁻¹ and A⁻¹A cannot both be defined unless A is square.

Theorem · The 2 by 2 inverse

If A = [ a b ; c d ] and ad - bc ≠ 0 then A⁻¹ = (1/(ad - bc))[ d -b ; -c a ]. If ad - bc = 0, A has no inverse. Note what moves: a and d change places, while b and c stay where they are and change sign.

Multiply the two arrays before dividing by anything: [ a b ; c d ][ d -b ; -c a ] has top-left entry ad - bc, top-right -ab + ba = 0, bottom-left cd - dc = 0 and bottom-right -cb + da = ad - bc.

So the product is (ad - bc)I. If ad - bc ≠ 0, dividing every entry of the second array by ad - bc gives a product of exactly I, and multiplying in the other order gives (ad - bc)I as well. If ad - bc = 0 the product is the zero matrix, which is never I, so no scaling of that array can help.

Nor can any other matrix. Suppose some B had AB = BA = I. Multiplying A[ d -b ; -c a ] = 0 on the left by B gives (BA)[ d -b ; -c a ] = [ d -b ; -c a ] = 0, so a = b = c = d = 0 and A is the zero matrix — but then AB = 0, not I. So no B inverts A when ad - bc = 0.

□

Example · The inverse of [ 4 7 ; 2 6 ]

ad - bc = 24 - 14 = 10. Swapping the diagonal and negating the other two entries gives [ 6 -7 ; -2 4 ], and dividing by 10 gives A⁻¹ = [ 3/5 -7/10 ; -1/5 2/5 ]. Checking one entry: the top-left of AA⁻¹ is 4(3/5) + 7(-1/5) = 12/5 - 7/5 = 1.

Any size: augment with I and row reduce

There is a 3 by 3 inverse formula. It is long, it is easy to misremember, and it is unnecessary, because the row reduction of “Gaussian Elimination” already does the work. Write A and the identity side by side as [ A | I ], reduce the left half to I, and the right half becomes A⁻¹.

The reason is that every row operation is itself a multiplication by some matrix, and the operations that carry A to I are exactly the operations that carry I to A⁻¹. Carrying them out on both halves at once records the whole sequence. If the left half cannot be reduced to I — a row of zeros appears — then A is singular, and the attempt has proved it.

Theorem · Solving a system with an inverse

If A is invertible, AX = B has the unique solution X = A⁻¹B. Multiplying both sides on the left by A⁻¹ gives A⁻¹AX = A⁻¹B, and A⁻¹A = I, so IX = X = A⁻¹B. The multiplication must be on the left on both sides: XA⁻¹ is a different product and is usually not even defined.

Example · A singular matrix, and the two systems behind it

A = [ 2 3 ; 4 6 ] has ad - bc = 12 - 12 = 0, so there is no A⁻¹. Reducing [ A | I ] produces a zero row on the left, which is the same failure. And the systems agree: 2x + 3y = 1 with 4x + 6y = 2 has infinitely many solutions, while 2x + 3y = 1 with 4x + 6y = 5 has none. No single matrix A⁻¹ could deliver both answers.

Theorem · The inverse of a product reverses the order

If A and B are invertible and the same size, (AB)⁻¹ = B⁻¹A⁻¹. Check it: (AB)(B⁻¹A⁻¹) = A(BB⁻¹)A⁻¹ = AIA⁻¹ = AA⁻¹ = I. The order reverses for the same reason socks come off after shoes.

Interactive

The inverse by row reduction

Reduce [A | I], then multiply A by what came out and watch I come back

Matrix
[A | I] reducedA times the result

Method

Inverting a 2 by 2 and using it

The determinant comes first, because it decides whether the rest happens.

1

Compute ad - bc

If it is 0, stop: there is no inverse, and the system it came from does not have a unique solution either. Everything below assumes it is not zero.

2

Swap the diagonal, negate the other two

a and d trade places. b and c stay where they are and change sign. Only one of those two things is a swap, and mixing them up is the commonest error in the formula.

3

Divide every entry by the determinant

All four entries, not just the first. Keep exact fractions: -7/10 is the entry, and -0.7 will be wrong by the time it has been multiplied twice.

4

Multiply back, then solve

AA⁻¹ must come out as [ 1 0 ; 0 1 ] exactly. Then X = A⁻¹B, with A⁻¹ written on the left of B.

Inverses

Score 0 / 0

Inverting [ 4 7 ; 2 6 ] by row reduction

The formula already gave the answer for this matrix. Doing it again by reduction is the point: this is the method that still works at 3 by 3, where there is no formula worth carrying.

[ 4 7 | 1 0 ] A on the left, the identity on the right [ 2 6 | 0 1 ] R1 → R1/4 [ 1 7/4 | 1/4 0 ] [ 2 6 | 0 1 ] R2 → R2 - 2R1 6 - 2(7/4) = 6 - 7/2 = 5/2 [ 1 7/4 | 1/4 0 ] [ 0 5/2 | -1/2 1 ] R2 → (2/5)R2 [ 1 7/4 | 1/4 0 ] [ 0 1 | -1/5 2/5 ] R1 → R1 - (7/4)R2 1/4 + 7/20 = 3/5, -(7/4)(2/5) = -7/10 [ 1 0 | 3/5 -7/10 ] [ 0 1 | -1/5 2/5 ] [ 3/5 -7/10 ] A⁻¹ = [ -1/5 2/5 ] solving 4x + 7y = 1, 2x + 6y = 8: x = (3/5)(1) + (-7/10)(8) = 3/5 - 28/5 = -5 y = (-1/5)(1) + (2/5)(8) = -1/5 + 16/5 = 3 check 4(-5) + 7(3) = -20 + 21 = 1 ✓ 2(-5) + 6(3) = -10 + 18 = 8 ✓

The two methods agree entry for entry, which is the only kind of agreement worth having. The reduction produced quarters at the first step and never left the fractions, and that is normal: a matrix of whole numbers has an inverse of fractions unless its determinant happens to be 1 or -1.

One B was solved here, so the inverse was not the cheap route. Solve AX = B for five different right-hand sides and it is.

Faded rehearsal: invert [ 2 1 ; 5 3 ]. The first decision is supplied: its determinant is nonzero, so an inverse exists. Apply the swap-and-negate pattern, divide every entry by the determinant, and multiply in both orders to verify the identity before using the result on any system.

Common mistakes

1
Writing B/A or 1/AThere is no matrix division and no reciprocal of a matrix. There is multiplication by A⁻¹, and it has a side: A⁻¹B and BA⁻¹ are different products, and for a column B only the first is defined.
2
Negating the diagonal instead of the off-diagonalIn the 2 by 2 formula, a and d swap places and keep their signs; b and c keep their places and lose theirs. Doing it the other way round gives a matrix whose product with A is not I, which is why the check in step 4 exists.
3
Forgetting to divide all four entries by the determinant[ 6 -7 ; -2 4 ] is not the inverse of [ 4 7 ; 2 6 ]; it is ten times the inverse. The product comes out as 10I rather than I, and every solution is then ten times too large.

Check your understanding

✓
Finish when the determinant is the first thing you compute, not the last.

You should be able to invert a 2 by 2 from the formula, invert a 3 by 3 by reducing [ A | I ], and say in one sentence why [ 2 3 ; 4 6 ] has no inverse. The check AA⁻¹ = I should be automatic; it costs four multiplications and catches every sign error.

Note: Three conditions have now collapsed into one. det A ≠ 0, A has an inverse, and AX = B has exactly one solution for every B are the same statement about the same matrix. “Systems of Inequalities and Linear Programming” leaves exact equations behind for inequalities, where the answer is a region rather than a point — and where finding the corners of that region is a 2 by 2 system all over again.

Kept in this browser only, for you. Nothing is sent anywhere and nothing checks it. Carry it to another device.

Feedback and recommendations

Something to change about this lesson? Write it down, tick it off when it is handled, and export the list when you want to act on it. Kept in this browser only: nothing is sent anywhere, and nobody is notified.

No recommendations yet for this lesson.