Determinants of order 2
For which values of $t$ do the equations $tx+2y=1$ and $2x+ty=3$ fail to have exactly one solution — and can one number tell, without solving?
Solve two equations in two unknowns by elimination, $$ \begin{aligned} a_{11}x_{1}+a_{12}x_{2} &= b_{1}\\ a_{21}x_{1}+a_{22}x_{2} &= b_{2}\,, \end{aligned} $$ and both unknowns come out over the same denominator $a_{11}a_{22}-a_{21}a_{12}.$ That denominator is worth a name.
The product down the main diagonal, minus the product up the other one. (Order is the word of Lecture 12: a square matrix with $2$ rows and $2$ columns has order $2.$)
Three determinants of order 2
Compute $\begin{vmatrix} 3 & 0\\ 2 & 6\end{vmatrix},$ $\begin{vmatrix} a & b\\ b & a\end{vmatrix}$ and $\begin{vmatrix} 3 & 1\\ 6 & 2\end{vmatrix}.$
Try it yourself first. Then open one step at a time.
Down the main diagonal, minus up the other one: $$ \begin{aligned} \begin{vmatrix} 3 & 0\\ 2 & 6\end{vmatrix}&=18\,,\\[4pt] \begin{vmatrix} a & b\\ b & a\end{vmatrix}&=a^{2}-b^{2}\,,\\[4pt] \begin{vmatrix} 3 & 1\\ 6 & 2\end{vmatrix}&=6-6=0\,. \end{aligned} $$
The last matrix is the one from Watch out 13.5, whose product with a non-zero matrix was $\mathbf{0}$. Its determinant is $0$, and that is not a coincidence. (The product itself is worked out in Example 13.6 of Lecture 13.)
$18,$ $a^{2}-b^{2}$ and $0.$
The question below is the one in the hook. Write $|\mathbf{A}|$ as a function of $t$ before you choose; you do not need to solve the system.
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
For which values of $t$ does $$\begin{aligned} t\,x + 2y &= 1\\ 2x + t\,y &= 3\end{aligned}$$ fail to have exactly one solution?
- Why is that answer tempting? Right condition, half an answer. $|\mathbf{A}| = t^{2} - 4 = 0$ has two roots, and $t = -2$ breaks the system just as thoroughly as $t = 2.$ The commonest error on this question, and it is not a matrix error at all.
- Why is that answer tempting? Reads the determinant off the wrong entries. $|\mathbf{A}| = t\cdot t - 2\cdot 2 = t^{2} - 4,$ not $t^{2}$ or $4t;$ at $t = 0$ the determinant is $-4,$ which is perfectly non-zero, and the system has a unique solution.
- Why is that answer tempting? Two equations in two unknowns can perfectly well have none or infinitely many, as Lecture 13 showed. Squareness buys nothing on its own; the determinant is what has to be checked.
$$ \begin{aligned} |\mathbf{A}| &= \begin{vmatrix} t & 2\\ 2 & t\end{vmatrix}\\ &= t^{2} - 4 = (t-2)(t+2)\,. \end{aligned} $$ So $|\mathbf{A}| = 0$ exactly when $t = 2$ or $t = -2,$ and only then can the system fail to have a unique solution.
At $t = 2$ the rows of $\mathbf{A}$ are $(2, 2)$ and $(2, 2),$ at $t=-2$ they are $(-2, 2)$ and $(2, -2){:}$ both times they lie on one line. With the right-hand side $(1,3)$ both values end in a contradiction — $2x+2y$ cannot be both $1$ and $3,$ and $-2x+2y$ cannot be both $1$ and $-3$ — so here there is no solution at all. With another right-hand side, such as $(1,1)$ at $t=2,$ there would be infinitely many.
Both unknowns came out over the denominator $|\mathbf{A}|.$ The numerators are determinants too, and when $|\mathbf{A}|\ne0$ they give the solution as a formula — Cramer's rule.
Write $\mathbf{A}_{j}$ for the matrix $\mathbf{A}$ with its $j$th column replaced by $\mathbf{b}$. If $|\mathbf{A}|\ne0$, the system $\mathbf{A}\mathbf{x}=\mathbf{b}$ has exactly one solution, namely $$ \begin{aligned} x_{1}&=\frac{|\mathbf{A}_{1}|}{|\mathbf{A}|} =\frac{\begin{vmatrix} b_{1} & a_{12}\\ b_{2} & a_{22}\end{vmatrix}} {|\mathbf{A}|}\,, \\ x_{2}&=\frac{|\mathbf{A}_{2}|}{|\mathbf{A}|} =\frac{\begin{vmatrix} a_{11} & b_{1}\\ a_{21} & b_{2}\end{vmatrix}} {|\mathbf{A}|}\,. \end{aligned} $$
Eliminate one unknown. Multiply the first equation by $a_{22}$, the second by $a_{12}$, and subtract: the $x_{2}$ terms cancel and $$ \begin{aligned} &(a_{11}a_{22}-a_{21}a_{12})x_{1}\\ &=b_{1}a_{22}-b_{2}a_{12}\,, \end{aligned} $$ which is $|\mathbf{A}|x_{1}=|\mathbf{A}_{1}|.$ Eliminating $x_{1}$ instead gives $|\mathbf{A}|x_{2}=|\mathbf{A}_{2}|.$
Divide. If $|\mathbf{A}|\ne0$ we may divide, and the two values obtained are forced; substituting back shows they do solve the system.
Cramer's rule on two equations
Solve $2x_{1}+3x_{2}=8$, $x_{1}-x_{2}=-1$.
Try it yourself first. Then open one step at a time.
Here $|\mathbf{A}|=\begin{vmatrix} 2 & 3\\ 1 & -1\end{vmatrix}=-5\ne0,$ and $$ \begin{aligned} |\mathbf{A}_{1}|&=\begin{vmatrix} 8 & 3\\ -1 & -1\end{vmatrix}=-5\,,\\[4pt] |\mathbf{A}_{2}|&=\begin{vmatrix} 2 & 8\\ 1 & -1\end{vmatrix}=-10\,, \end{aligned} $$
so $x_{1}=-5/-5=1$ and $x_{2}=-10/-5=2.$ Substitution confirms it: $2+6=8$ and $1-2=-1.$
If $|\mathbf{A}|=0$ the two expressions are meaningless, and correctly so: the two equations then describe parallel lines, which either never meet (no solution) or coincide (infinitely many). This is Fact 13.20 again, now decided by a single number.
What the number measures. Draw the two rows of $\mathbf{A}$ as vectors in the plane. They span a parallelogram, and its area is $\bigl||\mathbf{A}|\bigr|;$ interchanging the rows reverses the sign. So $|\mathbf{A}|=0$ says the parallelogram is flat — the two rows lie along one line, and the second equation adds nothing independent of the first. That is the geometric content of degeneracy, and it is why one number can detect it.
|A| as an area — and the moment it vanishes
The two rows of $\mathbf{A}$ as arrows, the parallelogram they span, and $|\mathbf{A}|$ computed as you move them.
- Drag the arrowhead of row 2 slowly towards row 1. The number shrinks with the parallelogram, and it reads $0$ at the moment the two arrows line up.
- Press Swap the rows. The parallelogram does not move and its area does not change, but $|\mathbf{A}|$ changes sign. That is what "signed area" means.
- Press Sweep row 2 round and watch the read-out: the determinant passes through $0$ twice per turn, once in each direction. Nothing dramatic happens to the arithmetic at $0;$ what becomes impossible is a division.
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
Solve $2x_{1}+x_{2}=4,$ $3x_{1}+4x_{2}=11$ by Cramer's rule. What is $x_{2}?$
- Why is that answer tempting? That is $|\mathbf{A}_{1}|/|\mathbf{A}|=(16-11)/5,$ with the first column replaced by $\mathbf{b}{:}$ it is $x_{1}.$ For $x_{2}$ the second column is replaced.
- Why is that answer tempting? Replaces the second row by $\mathbf{b}{:}$ $\begin{vmatrix}2&1\\4&11\end{vmatrix}=18.$ In Cramer's rule $\mathbf{b}$ replaces a column, because the columns of $\mathbf{A}$ belong to the unknowns.
- Why is that answer tempting? Adds the two products: $2\cdot4+1\cdot3=11.$ The determinant is the product down the main diagonal minus the product up the other one: $|\mathbf{A}|=8-3=5.$
$|\mathbf{A}|=2\cdot4-3\cdot1=5\ne0,$ and with the second column replaced by $\mathbf{b}=(4,11),$ $$ \begin{aligned} x_{2}&=\frac{\begin{vmatrix}2&4\\3&11\end{vmatrix}}{5}\\ &=\frac{22-12}{5}=2\,. \end{aligned} $$ Check with $x_{1}=1{:}$ $2+2=4$ and $3+8=11.$
Determinants of order 3
Three equations, three unknowns, one common denominator of six terms. Who remembers six terms? Nobody — so how is it computed?
The same elimination performed on three equations in three unknowns again produces one common denominator, of six terms.
Nobody remembers that. Grouping the three terms containing each entry of the first row turns it into three determinants of order $2,$ and that is how it is computed.
The same value is obtained by expanding along any row or any column, with the sign of the $(i,j)$ term equal to $(-1)^{i+j}.$ Expanding along a row or column containing zeros is therefore much the cheapest route, and is worth looking for before starting.
The signs make a chequerboard, starting with $+$ in the top left corner: $$ \begin{matrix} + & - & + \\ - & + & - \\ + & - & + \end{matrix} $$
Expanding along the first row
Compute $\begin{vmatrix} 1 & 2 & 3\\ 4 & 5 & 6\\ 7 & 8 & 10\end{vmatrix}$ by Method 14.7.
Try it yourself first. Then open one step at a time.
- $$ \begin{aligned} &\begin{vmatrix} 1 & 2 & 3\\ 4 & 5 & 6\\ 7 & 8 & 10\end{vmatrix}\\ &= 1\begin{vmatrix} 5 & 6\\ 8 & 10\end{vmatrix} - 2\begin{vmatrix} 4 & 6\\ 7 & 10\end{vmatrix}\\ &\quad+ 3\begin{vmatrix} 4 & 5\\ 7 & 8\end{vmatrix} \end{aligned} $$
$$ \begin{aligned} &= 1\cdot 2-2\cdot(-2)+3\cdot(-3)\\ &= -3\,. \end{aligned} $$ The three order-$2$ determinants are $50-48=2,$ $40-42=-2$ and $32-35=-3.$
The determinant is $-3.$
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
Expand along the second column. What is the determinant?
- Why is that answer tempting? Right minor, wrong sign. The surviving entry $5$ sits at $(1,2),$ and $(-1)^{1+2}=-1.$ The chequerboard starts $+$ at the top left and alternates; the $(1,2)$ square is a minus.
- Why is that answer tempting? It does not — every expansion gives the same number, and that is precisely why you are free to pick the lazy one. If two routes disagree, one of them has a sign error.
- Why is that answer tempting? The order-$2$ recipe does not extend. Here it would give $2\cdot0\cdot2-3\cdot0\cdot(-1)=0,$ and the determinant is $-30.$ A determinant of order $3$ has six terms, not two.
Only the $5$ survives, at position $(1,2)$, and $(-1)^{1+2} = -1$: $$|\mathbf{A}| = -5\begin{vmatrix} 1 & 4\\ -1 & 2\end{vmatrix} = -5 \cdot 6 = -30$$
Two zeros in a column turned six terms into one. They did not make the determinant zero.
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
- Why is that answer tempting? The sign is lost. The $5$ sits at $(3,2),$ and $(-1)^{3+2}=-1,$ so the term is $-5\cdot(1\cdot1-2\cdot3)=-5\cdot(-5).$
- Why is that answer tempting? Zeros buy a shortcut, not a verdict. A determinant is zero when the rows lie in a common plane, not when some entries vanish.
- Why is that answer tempting? The sign and the order-$2$ determinant are right, but the entry $5$ itself has been dropped: each term is entry times sign times determinant.
Expand down column $2,$ where only the $5$ at $(3,2)$ survives: $$ \begin{aligned} |\mathbf{A}|&=(-1)^{3+2}\cdot5\begin{vmatrix}1&2\\3&1\end{vmatrix}\\ &=-5\cdot(1-6)=25\,. \end{aligned} $$ Along the first row, as a check: $1\cdot(0-5)-0+2\cdot(15-0)=-5+30=25.$
Cramer's rule of order 3, and the determinant of a product
Does Cramer's rule survive one dimension up — and is the determinant of a product the product of the determinants? Of a sum the sum?
With $\mathbf{A}_{j}$ again denoting $\mathbf{A}$ with column $j$ replaced by $\mathbf{b}$: if $|\mathbf{A}|\ne0$ then $\mathbf{A}\mathbf{x}=\mathbf{b}$ has exactly one solution, and $$ x_{j}=\frac{|\mathbf{A}_{j}|}{|\mathbf{A}|}\,,\qquad j=1,2,3\,. $$
Cramer's rule on three equations
Solve $$ \begin{aligned} x_{1}+ x_{2}+ x_{3} &= 6\\ x_{1}- x_{2}+2x_{3} &= 5\\ 2x_{1}+ x_{2}- x_{3} &= 1\,. \end{aligned} $$
Try it yourself first. Then open one step at a time.
Expanding each along its first row, $$ \begin{aligned} |\mathbf{A}|&=7\,,& |\mathbf{A}_{1}|&=7\,,\\ |\mathbf{A}_{2}|&=14\,,& |\mathbf{A}_{3}|&=21\,, \end{aligned} $$ so $(x_{1},x_{2},x_{3})=(1,2,3).$ For instance $$ \begin{aligned} |\mathbf{A}|&=1\cdot(1-2)-1\cdot(-1-4)\\ &\quad+1\cdot(1+2)=7\,. \end{aligned} $$
Four determinants of order $3,$ which is twelve of order $2$: for a $3\times3$ system Gaussian elimination is usually less work, and for larger systems Cramer's rule is hopeless. Its value is theoretical — it says the solution is a formula in the data, and it shows exactly where $|\mathbf{A}|=0$ breaks everything.
$(x_{1},x_{2},x_{3})=(1,2,3);$ check: $1+2+3=6,$ $1-2+6=5,$ $2+2-3=1.$
Geometrically the story repeats one dimension up: the three rows of $\mathbf{A}$ span a parallelepiped, and $\bigl||\mathbf{A}|\bigr|$ is its volume. A zero determinant means the solid is flat, i.e. the three rows lie in a common plane.
For square matrices $\mathbf{A},\mathbf{B}$ of the same order, $$ \begin{aligned} |\mathbf{A}\mathbf{B}| &= |\mathbf{A}|\cdot|\mathbf{B}|\,, \\ |\mathbf{A}^{\top}| &= |\mathbf{A}|\,, \\ |\mathbf{I}_{n}| &= 1\,. \end{aligned} $$
Here $\mathbf{A}^{\top}$ is the transpose and $\mathbf{I}_{n}$ the identity matrix of order $n,$ both from Lecture 13. The Fact is stated without proof; it is the one property of determinants beyond the definition that the rest of the lecture uses.
Determinants have further properties, but they are not part of this course, and nothing below depends on them.
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
$\mathbf{A}$ is a matrix of order $3$ with $|\mathbf{A}|=2.$ What is $|3\mathbf{A}|?$
- Why is that answer tempting? Multiplies the determinant by $3$ once. But $3\mathbf{A}$ multiplies every one of the three rows by $3,$ and each row contributes a factor $3.$
- Why is that answer tempting? That is $3^{2}\cdot2,$ the rule for order $2.$ The exponent is the order of the matrix: here $3.$
- Why is that answer tempting? Cubes the determinant instead of the scalar: $2^{3}=8.$ It is the scalar that is raised to the power $n,$ because it is the scalar that multiplies each row.
By Watch out 14.14, $$ \begin{aligned} |3\mathbf{A}|&=3^{3}|\mathbf{A}|\\ &=27\cdot2=54\,. \end{aligned} $$ The same follows from Fact 14.13: $3\mathbf{A}=(3\mathbf{I}_{3})\mathbf{A}$ and $|3\mathbf{I}_{3}|=27.$
The inverse, and when it exists
A $3\times4$ matrix: does it have an inverse if its determinant is not zero?
For a non-zero number $a$ there is a unique $a^{-1}$ with $aa^{-1}=a^{-1}a=1.$ Lecture 13 produced the matrix standing for $1$ — the identity matrix $\mathbf{I}_{n}$ — and we now ask for the reciprocal.
Guess first. Before reading on, answer the question below. Check the orders of the products $\mathbf{A}\mathbf{X}$ and $\mathbf{X}\mathbf{A}$ — that is all it takes.
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
$\mathbf{A}$ is a $3 \times 4$ matrix.
Which of these is true?
- Why is that answer tempting? Borrows the transpose's rule. The orders kill it: $\mathbf{A}\mathbf{X}$ would be $3\times3$ and $\mathbf{X}\mathbf{A}$ would be $4\times4,$ so the two products cannot both be the same $\mathbf{I},$ whatever the entries are.
- Why is that answer tempting? Then $\mathbf{A}\mathbf{A}^{-1}$ would be a $(3\times4)(3\times4)$ product — the inner orders are $4$ and $3,$ so it does not exist at all. Shape first: this one fails before any arithmetic.
- Why is that answer tempting? The condition cannot even be tested: $|\mathbf{A}|$ is not defined for a non-square matrix. Square comes first, and only then does $|\mathbf{A}|\ne0$ have anything to say.
$\mathbf{AX} = \mathbf{XA} = \mathbf{I}$ forces $\mathbf{A}$ and $\mathbf{X}$ to be square of the same order. Here $\mathbf{X}$ would have to be $4\times3$ for both products to exist, and then $$ \begin{aligned} (3 \times \underline{4})(\underline{4} \times 3) &= 3 \times 3\,,\\ (4 \times \underline{3})(\underline{3} \times 4) &= 4 \times 4\,. \end{aligned} $$ Two different identity matrices. Determinants, likewise, are defined for square matrices only.
The two products $\mathbf{A}\mathbf{X}$ and $\mathbf{X}\mathbf{A}$ are both defined and both equal to $\mathbf{I}$ only if $\mathbf{A}$ and $\mathbf{X}$ are square of the same order. Only square matrices can have inverses, and the definition is symmetric: $\mathbf{A}$ and $\mathbf{X}$ are inverses of each other.
A matrix has at most one inverse.
Suppose $\mathbf{X}\mathbf{A}=\mathbf{I}$ and $\mathbf{A}\mathbf{Y}=\mathbf{I}.$ Then $$ \begin{aligned} \mathbf{Y}&=\mathbf{I}\mathbf{Y}=(\mathbf{X}\mathbf{A})\mathbf{Y}\\ &=\mathbf{X}(\mathbf{A}\mathbf{Y})=\mathbf{X}\mathbf{I}=\mathbf{X}\,, \end{aligned} $$ using nothing but associativity.
The inverse of $\mathbf{A},$ when it exists, is written $\mathbf{A}^{-1}.$
A square matrix $\mathbf{A}$ has an inverse if and only if $|\mathbf{A}|\ne0$. A square matrix is called singular when $|\mathbf{A}|=0$ and non-singular when $|\mathbf{A}|\ne0$; so invertible and non-singular mean the same thing.
Only if. One direction is immediate from Fact 14.13: if $\mathbf{A}\mathbf{X}=\mathbf{I}$ then $|\mathbf{A}|\cdot|\mathbf{X}|=|\mathbf{I}|=1,$ so $|\mathbf{A}|$ cannot be $0.$
If. The converse — that $|\mathbf{A}|\ne0$ is enough — follows from Method 15.3 in Lecture 15, which constructs the inverse whenever the construction can be completed; for order $2$ it is Fact 14.20 below, which one can simply multiply out.
The matrix that could not be divided by
$\mathbf{A}=\begin{pmatrix} 3 & 1\\ 6 & 2\end{pmatrix}$ has $|\mathbf{A}|=0$ and therefore no inverse.
Try it yourself first. Then open one step at a time.
$|\mathbf{A}|=3\cdot2-6\cdot1=0,$ so by Fact 14.18 $\mathbf{A}$ is singular and has no inverse.
This closes Lecture 13: that matrix satisfied $\mathbf{A}\mathbf{B}=\mathbf{0}$ with $\mathbf{B}\ne\mathbf{0},$ and if $\mathbf{A}^{-1}$ had existed we could have multiplied on the left to get $\mathbf{B}=\mathbf{A}^{-1}\mathbf{0}=\mathbf{0},$ a contradiction. All three failures of Watch out 13.5 are exactly the absence of an inverse. (The pair $\mathbf{A},$ $\mathbf{B}$ is Example 13.6.)
$|\mathbf{A}|=0{:}$ $\mathbf{A}$ is singular and has no inverse.
Which values of a make the matrix singular?
This example is the app's. For which values of $a$ is $$ \mathbf{A}=\begin{pmatrix} a & 1 & 1\\ 3 & a & 1\\ 3 & 1 & a\end{pmatrix} $$ not invertible?
Try it yourself first. Then open one step at a time.
The determinant. By Fact 14.18 we need the $a$ with $|\mathbf{A}|=0.$ Expanding along the first row, $$ \begin{aligned} |\mathbf{A}|&=a(a^{2}-1)-1\cdot(3a-3)\\ &\quad+1\cdot(3-3a)\\ &=a^{3}-7a+6\,. \end{aligned} $$
All of them. $|\mathbf{A}|=0$ exactly for $a=1,$ $a=2$ and $a=-3.$ Check one more: at $a=2$ the expansion gives $2\cdot3-3+(-3)=0.$ Stopping after the visible root $a=1$ would lose two of the three answers.
$\mathbf{A}$ is not invertible exactly when $a=1,$ $a=2$ or $a=-3;$ for every other $a$ it is invertible.
The inverse of order 2, and its rules
Swap, negate, divide — and to undo $\mathbf{A}\mathbf{B},$ which do you undo first?
If $|\mathbf{A}|=ad-bc\ne0$, then $$ \begin{aligned} &\mathbf{A}=\begin{pmatrix} a & b\\ c & d\end{pmatrix} \quad\Longrightarrow\quad \\ &\mathbf{A}^{-1}=\frac{1}{ad-bc} \begin{pmatrix} d & -b\\ -c & a\end{pmatrix}\,. \end{aligned} $$ Swap the diagonal entries, change the sign of the other two, divide by the determinant.
Multiply out: the product of $\mathbf{A}$ with the matrix on the right is $$ \frac{1}{ad-bc}\begin{pmatrix} ad-bc & 0\\ 0 & ad-bc\end{pmatrix}=\mathbf{I}_{2}\,, $$ and likewise in the other order.
Inverting a matrix of order 2, and the check
This example is the app's. Find the inverse of $\mathbf{A}=\begin{pmatrix} 5 & 2\\ 4 & 2\end{pmatrix}.$
Try it yourself first. Then open one step at a time.
The determinant. $|\mathbf{A}|=5\cdot2-4\cdot2=2\ne0,$ so the inverse exists (Fact 14.18).
Swap, negate, divide. By Fact 14.20 $$ \begin{aligned} \mathbf{A}^{-1}&=\frac12\begin{pmatrix} 2 & -2\\ -4 & 5\end{pmatrix}\\ &=\begin{pmatrix} 1 & -1\\ -2 & \tfrac52\end{pmatrix}. \end{aligned} $$
The check. One product is enough (Fact 14.21 below): $$ \begin{aligned} &\begin{pmatrix} 5 & 2\\ 4 & 2\end{pmatrix} \begin{pmatrix} 1 & -1\\ -2 & \tfrac52\end{pmatrix}\\ &=\begin{pmatrix} 5-4 & -5+5\\ 4-4 & -4+5\end{pmatrix} =\mathbf{I}_{2}\,. \end{aligned} $$ The fraction $\tfrac12$ is where the marks go: when $|\mathbf{A}|\ne1$ it must be carried into every entry.
$\mathbf{A}^{-1}=\begin{pmatrix} 1 & -1\\ -2 & \tfrac52\end{pmatrix},$ and $\mathbf{A}\mathbf{A}^{-1}=\mathbf{I}_{2}.$
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
What is the inverse of $\mathbf{A}=\begin{pmatrix} 2 & 3\\ 4 & 5\end{pmatrix}?$
- Why is that answer tempting? The sign of the determinant is lost: $|\mathbf{A}|=10-12=-2,$ not $2.$ Bars are not an absolute value (Watch out 14.3); multiply out and you get $-\mathbf{I}_{2}.$
- Why is that answer tempting? The diagonal is swapped but the signs of the other two entries are not changed. Multiplying out, the off-diagonal entries of the product are not $0.$
- Why is that answer tempting? The signs are changed but the diagonal entries are not swapped. The formula swaps $a$ and $d.$
$|\mathbf{A}|=2\cdot5-3\cdot4=-2\ne0.$ Swap $2$ and $5,$ change the signs of $3$ and $4,$ divide by $-2{:}$ $$ \mathbf{A}^{-1}=\begin{pmatrix} -\tfrac52 & \tfrac32\\ 2 & -1\end{pmatrix}. $$ Check: the rows of $\mathbf{A}\mathbf{A}^{-1}$ are $$ \begin{aligned} (-5+6,\ 3-3)&=(1,0)\,,\\ (-10+10,\ 6-5)&=(0,1)\,. \end{aligned} $$
For square $\mathbf{A}$ and $\mathbf{X}$ of the same order, $$ \begin{aligned} &\mathbf{A}\mathbf{X}=\mathbf{I} \;\Longleftrightarrow\; \mathbf{X}=\mathbf{A}^{-1}\\ &\;\Longleftrightarrow\; \mathbf{X}\mathbf{A}=\mathbf{I}\,. \end{aligned} $$
If $\mathbf{A}\mathbf{X}=\mathbf{I}$ then $|\mathbf{A}|\ne0$ as above, so $\mathbf{A}^{-1}$ exists; multiplying $\mathbf{A}\mathbf{X}=\mathbf{I}$ on the left by $\mathbf{A}^{-1}$ gives $\mathbf{X}=\mathbf{A}^{-1}.$
So to verify a proposed inverse one product suffices — but only for square matrices of the same order, which is where the hypothesis does its work.
Guess first. The rules for the inverse come next. Before reading them, answer the question below; write the product out if you are unsure.
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
$\mathbf{A}$ and $\mathbf{B}$ are invertible, of the same order.
What is $(\mathbf{AB})^{-1}$?
- Why is that answer tempting? Keeps the order. Multiply it out: $(\mathbf{A}\mathbf{B})(\mathbf{A}^{-1}\mathbf{B}^{-1}) = \mathbf{A}(\mathbf{B}\mathbf{A}^{-1})\mathbf{B}^{-1},$ and nothing cancels — $\mathbf{B}$ is not next to $\mathbf{B}^{-1}.$ The same mistake as $(\mathbf{A}\mathbf{B})^{\top} = \mathbf{A}^{\top}\mathbf{B}^{\top}$ in Lecture 13, and the same cure.
- Why is that answer tempting? It always exists: $|\mathbf{A}\mathbf{B}| = |\mathbf{A}||\mathbf{B}|,$ and neither factor is $0,$ so $|\mathbf{A}\mathbf{B}| \ne 0.$ The determinant shows it in one line.
- Why is that answer tempting? Attaches a true condition to the wrong statement. The reversal $\mathbf{B}^{-1}\mathbf{A}^{-1}$ holds always, with no hypothesis; $\mathbf{A}\mathbf{B} = \mathbf{B}\mathbf{A}$ is what would be needed to rewrite it as $\mathbf{A}^{-1}\mathbf{B}^{-1}.$
$$ \begin{aligned} &(\mathbf{AB})(\mathbf{B}^{-1}\mathbf{A}^{-1})\\ &= \mathbf{A}(\mathbf{BB}^{-1})\mathbf{A}^{-1}\\ &= \mathbf{AIA}^{-1} = \mathbf{AA}^{-1} = \mathbf{I} \end{aligned} $$ and one product is enough. The order reverses — exactly as for the transpose: to undo two operations, undo the last one first.
Let $\mathbf{A},\mathbf{B}$ be invertible of order $n$ and $c\ne0$ a scalar. Then $\mathbf{A}^{-1}$, $\mathbf{A}\mathbf{B}$, $\mathbf{A}^{\top}$ and $c\mathbf{A}$ are all invertible, and $$ \begin{aligned} (\mathbf{A}^{-1})^{-1}&=\mathbf{A}\,,\\ (\mathbf{A}\mathbf{B})^{-1}&=\mathbf{B}^{-1}\mathbf{A}^{-1}\,,\\ (\mathbf{A}^{\top})^{-1}&=(\mathbf{A}^{-1})^{\top}\,,\\ (c\mathbf{A})^{-1}&=c^{-1}\mathbf{A}^{-1}\,. \end{aligned} $$
The product. Each is a one-line application of Fact 14.21. For the second, $$ \begin{aligned} &(\mathbf{A}\mathbf{B})(\mathbf{B}^{-1}\mathbf{A}^{-1})\\ &=\mathbf{A}(\mathbf{B}\mathbf{B}^{-1})\mathbf{A}^{-1}\\ &=\mathbf{A}\mathbf{I}\mathbf{A}^{-1}=\mathbf{I}\,; \end{aligned} $$
The transpose. for the third, transpose $\mathbf{A}\mathbf{A}^{-1}=\mathbf{I}$ and use $(\mathbf{A}\mathbf{B})^{\top}=\mathbf{B}^{\top}\mathbf{A}^{\top}$ to get $(\mathbf{A}^{-1})^{\top}\mathbf{A}^{\top}=\mathbf{I}.$
A symmetric invertible matrix has a symmetric inverse: if $\mathbf{A}^{\top}=\mathbf{A}$ then $(\mathbf{A}^{-1})^{\top}=(\mathbf{A}^{\top})^{-1}=\mathbf{A}^{-1}.$
Solving the system with the inverse
With $\mathbf{A}^{-1}$ in hand, what does a second, third or hundredth right-hand side cost?
Let $\mathbf{A}$ be of order $n$ with $|\mathbf{A}|\ne0$. Then $$ \begin{aligned} &\mathbf{A}\mathbf{X}=\mathbf{B} \iff \mathbf{X}=\mathbf{A}^{-1}\mathbf{B} \\ &\quad(\mathbf{B}\text{ with }n\text{ rows})\,, \\ &\mathbf{Y}\mathbf{A}=\mathbf{B} \iff \mathbf{Y}=\mathbf{B}\mathbf{A}^{-1} \\ &\quad(\mathbf{B}\text{ with }n\text{ columns})\,. \end{aligned} $$ In particular $\mathbf{A}\mathbf{x}=\mathbf{b}$ has the unique solution $\mathbf{x}=\mathbf{A}^{-1}\mathbf{b}$, for every right-hand side $\mathbf{b}$.
Multiply on the left. Multiply $\mathbf{A}\mathbf{X}=\mathbf{B}$ on the left by $\mathbf{A}^{-1}$: $$ \begin{aligned} \mathbf{X}&=\mathbf{I}\mathbf{X}=(\mathbf{A}^{-1}\mathbf{A})\mathbf{X}\\ &=\mathbf{A}^{-1}\mathbf{B}\,, \end{aligned} $$ so no other $\mathbf{X}$ can work; and substituting $\mathbf{A}^{-1}\mathbf{B}$ back shows that this one does.
On the right. The second statement is the same argument multiplying on the right — and the sides may not be exchanged.
Solving with the inverse
Solve $3x+2y=7$, $x+y=3$.
Try it yourself first. Then open one step at a time.
$\mathbf{A}=\begin{pmatrix}3&2\\1&1\end{pmatrix}$ has $|\mathbf{A}|=1\ne0,$ so by Fact 14.20 $\mathbf{A}^{-1}=\begin{pmatrix}1&-2\\-1&3\end{pmatrix}$ and $$ \begin{aligned} \begin{pmatrix}x\\ y\end{pmatrix} &=\mathbf{A}^{-1}\mathbf{b}\\ &=\begin{pmatrix}1&-2\\-1&3\end{pmatrix} \begin{pmatrix}7\\ 3\end{pmatrix}\\ &=\begin{pmatrix}1\\ 2\end{pmatrix}\,. \end{aligned} $$
The work is in $\mathbf{A}^{-1},$ and it does not depend on $\mathbf{b}$: with the inverse in hand, any number of right-hand sides cost one multiplication each. That, rather than speed on a single system, is what the inverse is for.
$(x,y)=(1,2);$ check: $3+4=7$ and $1+2=3.$
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
$\mathbf{A}$ is invertible of order $n,$ and $\mathbf{B}$ has $n$ columns. Which $\mathbf{Y}$ solves $\mathbf{Y}\mathbf{A}=\mathbf{B}?$
- Why is that answer tempting? Multiplies on the wrong side. Then $\mathbf{Y}\mathbf{A}=\mathbf{A}^{-1}\mathbf{B}\mathbf{A},$ and nothing cancels — $\mathbf{A}^{-1}$ is not next to $\mathbf{A}.$ (If $\mathbf{B}$ is not square, the product may not even exist.)
- Why is that answer tempting? Not notation: there is no division of matrices (Watch out 14.17). The question is on which side to multiply by $\mathbf{A}^{-1}.$
- Why is that answer tempting? Matrix multiplication does not commute, so in general $\mathbf{A}^{-1}\mathbf{B}\ne\mathbf{B}\mathbf{A}^{-1}.$ Only one of them solves the equation.
Multiply $\mathbf{Y}\mathbf{A}=\mathbf{B}$ on the right by $\mathbf{A}^{-1}{:}$ $$ \begin{aligned} \mathbf{Y}&=\mathbf{Y}(\mathbf{A}\mathbf{A}^{-1})\\ &=\mathbf{B}\mathbf{A}^{-1}\,. \end{aligned} $$ That is the second half of Fact 14.24. The $\mathbf{A}^{-1}$ goes on the side where $\mathbf{A}$ stands.
For order $3$ and above, solutions are computed by elimination (Lecture 13) or by Cramer's rule rather than by inverting. The inverse itself, for any order, is found by row operations in Lecture 15; a closed formula for it exists, but it is not part of the course.
Four things met separately in this block now turn out to be one thing.
For a square matrix $\mathbf{A}$ of order $n$, the following say the same thing:
- $|\mathbf{A}|\ne0$;
- $\mathbf{A}$ has an inverse;
- $\mathbf{A}\mathbf{x}=\mathbf{b}$ has exactly one solution for every $\mathbf{b}\in{\mathbb R}^{n}$;
- Gaussian elimination on $\mathbf{A}$ produces a leading entry in every column.
Guess first. Statement (1) fails exactly when $|\mathbf{A}|=0.$ Before reading the Watch out below, decide what that says about the number of solutions.
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
$\mathbf{A}$ is square and $|\mathbf{A}| = 0$.
What follows about $\mathbf{Ax} = \mathbf{b}$?
- Why is that answer tempting? $|\mathbf{A}| = 0$ kills uniqueness, not existence. Example 13.18 and Watch out 13.19 in Lecture 13 have the same singular $\mathbf{A}$ with two right-hand sides: one gives infinitely many solutions, the other none. Which one you get depends on $\mathbf{b}.$
- Why is that answer tempting? The other half of the same error. Both outcomes are possible and $\mathbf{A}$ alone cannot tell you which — you have to look at $\mathbf{b},$ or eliminate and read the last row.
- Why is that answer tempting? $\mathbf{A}^{-1}$ does not exist — that is what $|\mathbf{A}| = 0$ means. The point of the determinant is that it answers the question without computing anything else.
$|\mathbf{A}| = 0$ says exactly not exactly one — nothing more.
Whether there are none or infinitely many depends on $\mathbf{b}$: the same singular $\mathbf{A}$ gave $0 = 0$ with one right-hand side and $0 = 3$ with another.
Uniqueness is a property of $\mathbf{A}$. Existence is not.
What you should take away
- Only square matrices have determinants. For order $2$, $|\mathbf{A}|=a_{11}a_{22}-a_{21}a_{12}$; for order $3$, expand along the first row into three determinants of order $2$, with signs $+,-,+$. Sarrus' rule is an alternative for order $3$ only.
- Expansion works along any row or column, with sign $(-1)^{i+j}$; choose one with zeros in it.
- Cramer's rule: if $|\mathbf{A}|\ne0$ then $x_{j}=|\mathbf{A}_{j}|/ |\mathbf{A}|$, where $\mathbf{A}_{j}$ is $\mathbf{A}$ with column $j$ replaced by $\mathbf{b}$. Useful as a formula, not as a method.
- $|\mathbf{A}\mathbf{B}|=|\mathbf{A}||\mathbf{B}|$, $|\mathbf{A}^{\top}|= |\mathbf{A}|$, $|\mathbf{I}|=1$ and $|\alpha\mathbf{A}|=\alpha^{n}|\mathbf{A}|$; but $|\mathbf{A}+\mathbf{B}|\ne|\mathbf{A}|+|\mathbf{B}|$.
- $\mathbf{X}$ is the inverse of $\mathbf{A}$ if $\mathbf{A}\mathbf{X}=\mathbf{X}\mathbf{A}=\mathbf{I}$. It is unique, only square matrices have one, and $\mathbf{A}$ has one if and only if $|\mathbf{A}|\ne0$.
- For order $2$, $\mathbf{A}^{-1}=\frac{1}{ad-bc} \left(\begin{smallmatrix} d & -b\\ -c & a\end{smallmatrix}\right)$.
- $(\mathbf{A}^{-1})^{-1}=\mathbf{A}$, $(\mathbf{A}\mathbf{B})^{-1}= \mathbf{B}^{-1}\mathbf{A}^{-1}$ — the order reverses — $(\mathbf{A}^{\top})^{-1}=(\mathbf{A}^{-1})^{\top}$, $(c\mathbf{A})^{-1}=c^{-1} \mathbf{A}^{-1}$.
- If $|\mathbf{A}|\ne0$ then $\mathbf{A}\mathbf{x}=\mathbf{b}$ has the unique solution $\mathbf{x}=\mathbf{A}^{-1}\mathbf{b}$. There is no division by a matrix: multiply by the inverse, and say on which side.
Think further
Questions without computation. Think on your own or with a classmate before opening the thought.
Discussion question 1 — the determinant of a 2 × 3 matrix
$\mathbf{A}$ is $2\times3$. What is $|\mathbf{A}|$?
One way to think about it
There is none. A determinant is defined only for a square matrix (Watch out 14.3); for a $2\times3$ matrix $|\mathbf{A}|$ is not a number that happens to be $0,$ it is meaningless. For the same reason $\mathbf{A}$ has no inverse: $\mathbf{A}\mathbf{X}$ would be $2\times2$ and $\mathbf{X}\mathbf{A}$ would be $3\times3,$ so they cannot both be the same identity matrix. Shape first.
Discussion question 2 — four determinants, three of them known
$|\mathbf{A}|=3$ and $|\mathbf{B}|=-4$, both of order $3$. Which of $|\mathbf{A}\mathbf{B}|$, $|2\mathbf{A}|$, $|\mathbf{A}+\mathbf{B}|$, $|\mathbf{A}^{-1}|$ can you determine?
One way to think about it
Three of the four. By Fact 14.13 $|\mathbf{A}\mathbf{B}|=3\cdot(-4)=-12.$ By Watch out 14.14 $|2\mathbf{A}|=2^{3}\cdot3=24.$ And $\mathbf{A}\mathbf{A}^{-1}=\mathbf{I}$ gives $|\mathbf{A}|\cdot|\mathbf{A}^{-1}|=1,$ so $|\mathbf{A}^{-1}|=\tfrac13.$
$|\mathbf{A}+\mathbf{B}|$ cannot be determined: the determinant does not respect sums. For instance $\mathbf{A}=\operatorname{diag}(3,1,1)$ with $\mathbf{B}=\operatorname{diag}(-4,1,1)$ gives $|\mathbf{A}+\mathbf{B}|=-1\cdot2\cdot2=-4,$ while $\mathbf{B}=\operatorname{diag}(1,-4,1)$ gives $|\mathbf{A}+\mathbf{B}|=4\cdot(-3)\cdot2=-24;$ both have $|\mathbf{B}|=-4.$ (Here $\operatorname{diag}(p,q,r)$ is the matrix with $p,$ $q,$ $r$ on the diagonal and zeros elsewhere.)
Discussion question 3 — a zero determinant and the number of solutions
A square system has $|\mathbf{A}|=0$. What can be said about the number of its solutions?
One way to think about it
Only that it is not exactly one: there are either none or infinitely many (Fact 14.26 and Fact 13.20). Which of the two depends on $\mathbf{b},$ and elimination decides it: a last row $0=c$ with $c\ne0$ means none, $0=0$ means infinitely many (Watch out 14.27). One case is certain in advance: if $\mathbf{b}=\mathbf{0},$ then $\mathbf{x}=\mathbf{0}$ is a solution, so there are infinitely many.
Discussion question 4 — which rule for the inverse is true
Which of the following holds for all invertible square $\mathbf{A}$, $\mathbf{B}$ of the same order?
(A) $(\mathbf{A}\mathbf{B})^{-1}=\mathbf{A}^{-1}\mathbf{B}^{-1}$;
(B) $(\mathbf{A}+\mathbf{B})^{-1}=\mathbf{A}^{-1}+\mathbf{B}^{-1}$;
(C) $(\mathbf{A}^{\top})^{-1}=(\mathbf{A}^{-1})^{\top}$;
(D) $|\mathbf{A}^{-1}|=-|\mathbf{A}|$.
One way to think about it
(C) only; it is part of Fact 14.22.
(A) keeps the order; the inverse of a product reverses it, $\mathbf{B}^{-1}\mathbf{A}^{-1}$ (Watch out 14.23).
(B) fails already for $\mathbf{A}=\mathbf{B}=\mathbf{I}_{2}{:}$ $(2\mathbf{I}_{2})^{-1}=\tfrac12\mathbf{I}_{2},$ while $\mathbf{I}_{2}+\mathbf{I}_{2}=2\mathbf{I}_{2}.$ And $\mathbf{A}+\mathbf{B}$ need not be invertible at all: take $\mathbf{B}=-\mathbf{A}.$
(D) confuses the inverse with a negative. From $|\mathbf{A}|\cdot|\mathbf{A}^{-1}|=|\mathbf{I}|=1$ we get $|\mathbf{A}^{-1}|=1/|\mathbf{A}|.$