Pm15 - Determinants and inverses by hand

Pm15 - Determinants and inverses by hand

A numerical matrix can be inverted by calculator, but an unknown entry calls for algebra. Pm15 develops the hand methods for determinants and inverses of order 33, including matrices containing parameters. Minors, signed cofactors and one transpose turn a large calculation into a sequence of small ones.

Expanding a determinant with cofactors

Can a matrix containing a freely changing real number tt still have an inverse for every value of tt? Consider

H=(1t0−t10001)\mathbf{H}=\begin{pmatrix}1&t&0\\-t&1&0\\0&0&1\end{pmatrix}

At t=0t=0 it is the identity, but what happens when tt becomes large or negative? A calculator cannot check every real value. We will calculate its determinant algebraically and settle the whole question at once.

You already know

A determinant of order 22 is ad−bcad-bc. A square matrix has an inverse exactly when its determinant is non-zero. Numerical determinants of order 33 can be checked with a calculator, but a hand method is needed for algebraic entries.

First take a concrete matrix:

A=(120011201)\mathbf{A}=\begin{pmatrix}1&2&0\\0&1&1\\2&0&1\end{pmatrix}

Delete its first row and second column. The remaining matrix is (0121)\begin{pmatrix}0&1\\2&1\end{pmatrix}, whose determinant is −2-2. This smaller determinant is a minor. Its position also supplies a sign.

Minor and cofactor

For an entry in row ii, column jj, the minor MijM_{ij} is the determinant left after deleting row ii and column jj. Its cofactor is Cij=(−1)i+jMijC_{ij}=(-1)^{i+j}M_{ij}. The signs form the pattern

(+−+−+−+−+)\begin{pmatrix}+&-&+\\-&+&-\\+&-&+\end{pmatrix}

For the displayed matrix, M12=−2M_{12}=-2, but C12=−(−2)=2C_{12}=-(-2)=2. The minor and the cofactor are not always equal.

To obtain the full determinant, choose one row and add each entry times its own cofactor. A row containing a zero is useful: that entry contributes nothing, so its minor need not be calculated.

Cofactor expansion in order 3

For A=(abcdefghi)\mathbf{A}=\begin{pmatrix}a&b&c\\d&e&f\\g&h&i\end{pmatrix}, expansion along the first row gives

det⁡A=a(ei−fh)−b(di−fg)+c(dh−eg)\det\mathbf{A}=a(ei-fh)-b(di-fg)+c(dh-eg)

Equivalently, det⁡A=aC11+bC12+cC13\det\mathbf{A}=aC_{11}+bC_{12}+cC_{13}. You may expand along any one row or column, using the cofactors belonging to that row or column. Keep the alternating signs attached to positions.

Not in the formula booklet: learn it.

In a determinant expansion, a minor receives its cofactor sign once. Subtracting a negative minor produces a positive contribution; do not change that sign again.

Worked example 1: a zero makes the expansion shorter

Question. Without using a calculator, find det⁡A\det\mathbf{A}, where A=(120011201)\mathbf{A}=\begin{pmatrix}1&2&0\\0&1&1\\2&0&1\end{pmatrix}.

Plan. Expand along the first row, where the zero removes one term.

det⁡A=1∣1101∣−2∣0121∣+0∣0120∣first-row expansion=1(1×1−1×0)−2(0×1−1×2)evaluate the minors=1−2(−2)=5subtract a negative\begin{aligned} \det\mathbf{A} &=1\begin{vmatrix}1&1\\0&1\end{vmatrix} -2\begin{vmatrix}0&1\\2&1\end{vmatrix} +0\begin{vmatrix}0&1\\2&0\end{vmatrix} && \text{first-row expansion} \\ &=1(1\times1-1\times0)-2(0\times1-1\times2) && \text{evaluate the minors} \\ &=1-2(-2)=5 && \text{subtract a negative} \end{aligned}

Why this step? The first row contains a zero, and only two minors need to be evaluated.

Answer. det⁡A=5\det\mathbf{A}=5, so A\mathbf{A} is non-singular.

Check. Expanding along the third column instead gives −1∣1220∣+1∣1201∣=−(−4)+1=5-1\begin{vmatrix}1&2\\2&0\end{vmatrix}+1\begin{vmatrix}1&2\\0&1\end{vmatrix}=-(-4)+1=5.

Worked example 2 changes only the bottom-left entry from 22 to 33. In the chosen expansion, only one of the two useful minors changes.

Worked example 2: tracking a changed entry

Question. Without using a calculator, find det⁡B\det\mathbf{B}, where B=(120011301)\mathbf{B}=\begin{pmatrix}1&2&0\\0&1&1\\3&0&1\end{pmatrix}.

Plan. Use the same first-row expansion and recalculate the affected minor.

det⁡B=1∣1101∣−2∣0131∣zero term omitted=1(1)−2(0−3)two minor determinants=1+6=7apply the cofactor sign\begin{aligned} \det\mathbf{B} &=1\begin{vmatrix}1&1\\0&1\end{vmatrix} -2\begin{vmatrix}0&1\\3&1\end{vmatrix} && \text{zero term omitted} \\ &=1(1)-2(0-3) && \text{two minor determinants} \\ &=1+6=7 && \text{apply the cofactor sign} \end{aligned}

Why this step? The entry 33 is inside the minor for the first-row entry 22; it does not become a separate term of the expansion.

Answer. det⁡B=7\det\mathbf{B}=7, so B\mathbf{B} is non-singular.

Check. Expanding down the first column gives 1(1)+3∣2011∣=1+3(2)=71(1)+3\begin{vmatrix}2&0\\1&1\end{vmatrix}=1+3(2)=7.

The sign pattern belongs to the positions, whatever signs the entries or minors already have.

Watch out

Wrong: 1(1)+2(−2)=−31(1)+2(-2)=-3 for Worked example 1. That omits the negative cofactor sign in position (1,2)(1,2). Right: 1(1)−2(−2)=51(1)-2(-2)=5. A negative minor at a negative-sign position contributes positively.

The next matrix changes that bottom-left entry again. Show the expansion, not just a determinant copied from a calculator.

From cofactors to the inverse

An inverse of order 33 uses all nine cofactors, followed by a transpose and division by the determinant.

The cofactor matrix puts CijC_{ij} in position (i,j)(i,j). Its transpose exchanges rows and columns: the entry in position (i,j)(i,j) moves to position (j,i)(j,i). This transpose is the step that makes the matrix multiplication work.

Adjugate

The adjugate of a square matrix is the transpose of its cofactor matrix. For a cofactor matrix C\mathbf{C}, the adjugate is adj⁡A=CT\operatorname{adj}\mathbf{A}=\mathbf{C}^{\mathsf T}. For example, the first row of C\mathbf{C} becomes the first column of adj⁡A\operatorname{adj}\mathbf{A}.

Multiplying the original matrix by its adjugate gives the determinant on each main-diagonal entry and zero elsewhere: Aadj⁡A=(det⁡A)I\mathbf{A}\operatorname{adj}\mathbf{A}=(\det\mathbf{A})\mathbf{I}. Dividing the whole product by a non-zero determinant therefore gives the identity.

Inverse by cofactors

For a non-singular matrix A\mathbf{A} of order 33,

A−1=1det⁡Aadj⁡A=1det⁡ACT\mathbf{A}^{-1}=\frac{1}{\det\mathbf{A}}\operatorname{adj}\mathbf{A} =\frac{1}{\det\mathbf{A}}\mathbf{C}^{\mathsf T}

Calculate the determinant, find all cofactors, transpose their matrix and divide by the determinant. If the determinant is zero, stop: there is no inverse.

Not in the formula booklet: learn it.

Use a consistent layout. Nine unlabelled numbers are hard to audit; a labelled cofactor matrix and a separate adjugate make a missed sign or transpose easier to catch.

Worked example 3: the full cofactor method

Question. Without using a calculator, find the inverse of A=(120011201)\mathbf{A}=\begin{pmatrix}1&2&0\\0&1&1\\2&0&1\end{pmatrix}.

Plan. Use det⁡A=5\det\mathbf{A}=5 from Worked example 1, calculate the nine signed minors, then transpose and divide.

C11=1(1)−1(0)=1C12=−[0(1)−1(2)]=2C13=0(0)−1(2)=−2C21=−[2(1)−0(0)]=−2C22=1(1)−0(2)=1C23=−[1(0)−2(2)]=4C31=2(1)−0(1)=2C32=−[1(1)−0(0)]=−1C33=1(1)−2(0)=1\begin{aligned} C_{11}&=1(1)-1(0)=1 \\ C_{12}&=-[0(1)-1(2)]=2 \\ C_{13}&=0(0)-1(2)=-2 \\ C_{21}&=-[2(1)-0(0)]=-2 \\ C_{22}&=1(1)-0(2)=1 \\ C_{23}&=-[1(0)-2(2)]=4 \\ C_{31}&=2(1)-0(1)=2 \\ C_{32}&=-[1(1)-0(0)]=-1 \\ C_{33}&=1(1)-2(0)=1 \end{aligned}

Each line deletes the row and column named by the subscripts, then applies that position's sign. Therefore

C=(12−2−2142−11)cofactor matrixadj⁡A=(1−2221−1−241)transposeA−1=15(1−2221−1−241)divide by the determinant\begin{aligned} \mathbf{C}&=\begin{pmatrix}1&2&-2\\-2&1&4\\2&-1&1\end{pmatrix} && \text{cofactor matrix} \\ \operatorname{adj}\mathbf{A}&=\begin{pmatrix}1&-2&2\\2&1&-1\\-2&4&1\end{pmatrix} && \text{transpose} \\ \mathbf{A}^{-1}&=\frac15\begin{pmatrix}1&-2&2\\2&1&-1\\-2&4&1\end{pmatrix} && \text{divide by the determinant} \end{aligned}

Why this step? The cofactors must be transposed before division. Dividing the cofactor matrix itself generally does not produce an inverse.

Answer. A−1=15(1−2221−1−241)\mathbf{A}^{-1}=\frac15\begin{pmatrix}1&-2&2\\2&1&-1\\-2&4&1\end{pmatrix}.

Check. Before division,

(120011201)(1−2221−1−241)=(500050005)\begin{pmatrix}1&2&0\\0&1&1\\2&0&1\end{pmatrix} \begin{pmatrix}1&-2&2\\2&1&-1\\-2&4&1\end{pmatrix} =\begin{pmatrix}5&0&0\\0&5&0\\0&0&5\end{pmatrix}

Dividing by 55 gives I\mathbf{I}.

Worked example 4 changes only the bottom-left entry from 22 to 33, as in the determinant examples. Reusing the unaffected cofactors is efficient, provided you identify which minors actually contain the changed entry.

Worked example 4: updating the affected cofactors

Question. Without using a calculator, find the inverse of B=(120011301)\mathbf{B}=\begin{pmatrix}1&2&0\\0&1&1\\3&0&1\end{pmatrix}.

Plan. Use det⁡B=7\det\mathbf{B}=7, recalculate the cofactors affected by the 33, then transpose the complete cofactor matrix.

The changed entry occurs in four minors. The minor for C22C_{22} also contains it, but its coefficient is zero, so that cofactor remains 11. The three changed cofactors are

C12=−[0(1)−1(3)]=3negative positionC13=0(0)−1(3)=−3positive positionC23=−[1(0)−2(3)]=6negative position\begin{aligned} C_{12}&=-[0(1)-1(3)]=3 && \text{negative position} \\ C_{13}&=0(0)-1(3)=-3 && \text{positive position} \\ C_{23}&=-[1(0)-2(3)]=6 && \text{negative position} \end{aligned}

The remaining cofactors retain their values from Worked example 3. Thus

C=(13−3−2162−11)all signed minorsadj⁡B=(1−2231−1−361)transposeB−1=17(1−2231−1−361)divide by 7\begin{aligned} \mathbf{C}&=\begin{pmatrix}1&3&-3\\-2&1&6\\2&-1&1\end{pmatrix} && \text{all signed minors} \\ \operatorname{adj}\mathbf{B}&=\begin{pmatrix}1&-2&2\\3&1&-1\\-3&6&1\end{pmatrix} && \text{transpose} \\ \mathbf{B}^{-1}&=\frac17\begin{pmatrix}1&-2&2\\3&1&-1\\-3&6&1\end{pmatrix} && \text{divide by }7 \end{aligned}

Why this step? A changed entry does not alter every minor. Deleting its row or column removes it entirely, which saves unnecessary recalculation.

Answer. B−1=17(1−2231−1−361)\mathbf{B}^{-1}=\frac17\begin{pmatrix}1&-2&2\\3&1&-1\\-3&6&1\end{pmatrix}.

Check. The first row of Badj⁡B\mathbf{B}\operatorname{adj}\mathbf{B} is (1+6,−2+2,2−2)=(7,0,0)(1+6,-2+2,2-2)=(7,0,0); the second is (3−3,1+6,−1+1)=(0,7,0)(3-3,1+6,-1+1)=(0,7,0); the third is (3−3,−6+6,6+1)=(0,0,7)(3-3,-6+6,6+1)=(0,0,7).

The transpose is often the last place a correct cofactor calculation goes wrong.

Watch out

Wrong: A−1=15(12−2−2142−11)\mathbf{A}^{-1}=\frac15\begin{pmatrix}1&2&-2\\-2&1&4\\2&-1&1\end{pmatrix}. This divides the cofactor matrix without transposing it. Right: its first row (1,2,−2)(1,2,-2) becomes the first column of the inverse's numerator matrix.

The next inverse uses a different first row. Calculate its cofactors afresh rather than copying the previous pattern.

Inverses with algebraic entries

An algebraic entry changes the arithmetic into polynomial work, but it does not change the cofactor method.

Keep brackets around a minor until its sign has been applied. Factor the determinant where possible, because its zeros give precisely the excluded parameter values. State those exclusions before presenting a formula that divides by the determinant.

You already know

For a non-singular matrix, A−1=(det⁡A)−1adj⁡A\mathbf{A}^{-1}=(\det\mathbf{A})^{-1}\operatorname{adj}\mathbf{A}. A parameter value giving determinant zero makes the inverse undefined; it is not a case in which the inverse is the zero matrix.

The following two examples differ only in one numerical entry. This keeps the algebra focused on the parameter rather than hiding the method in a long expansion.

Worked example 5: a parameter in the determinant

Question. Find the values of tt for which A=(1100t1101)\mathbf{A}=\begin{pmatrix}1&1&0\\0&t&1\\1&0&1\end{pmatrix} is invertible. Find its inverse for those values without using a calculator.

Plan. Expand the determinant, state the non-zero condition, then build the signed minors and transpose them.

det⁡A=1(t×1−1×0)−1(0×1−1×1)=t+1first-row expansion\begin{aligned} \det\mathbf{A}&=1(t\times1-1\times0)-1(0\times1-1\times1) \\ &=t+1 && \text{first-row expansion} \end{aligned}

Thus an inverse exists exactly when t≠−1t\ne-1. The cofactors are

C=(t1−t−1111−1t)signed minorsadj⁡A=(t−1111−1−t1t)transposeA−1=1t+1(t−1111−1−t1t)t≠−1\begin{aligned} \mathbf{C}&=\begin{pmatrix}t&1&-t\\-1&1&1\\1&-1&t\end{pmatrix} && \text{signed minors} \\ \operatorname{adj}\mathbf{A}&=\begin{pmatrix}t&-1&1\\1&1&-1\\-t&1&t\end{pmatrix} && \text{transpose} \\ \mathbf{A}^{-1}&=\frac{1}{t+1}\begin{pmatrix}t&-1&1\\1&1&-1\\-t&1&t\end{pmatrix} && t\ne-1 \end{aligned}

For example, C13=0(0)−t(1)=−tC_{13}=0(0)-t(1)=-t, while C23=−[1(0)−1(1)]=1C_{23}=-[1(0)-1(1)]=1.

Why this step? The restriction belongs to the whole inverse formula: at t=−1t=-1, the determinant factor cannot be divided out.

Answer. A\mathbf{A} is invertible for all real t≠−1t\ne-1, with inverse as displayed.

Check. The product with the adjugate is

(t+1000t+1000t+1)\begin{pmatrix}t+1&0&0\\0&t+1&0\\0&0&t+1\end{pmatrix}

At t=0t=0, the determinant is 11, so that particular matrix remains invertible even though its central entry is zero.

Worked example 6 changes only the bottom-left entry from 11 to 22. The forbidden parameter value moves, and several cofactors change with it.

Worked example 6: a different excluded value

Question. Find the values of tt for which B=(1100t1201)\mathbf{B}=\begin{pmatrix}1&1&0\\0&t&1\\2&0&1\end{pmatrix} is invertible. Find its inverse for those values without using a calculator.

Plan. Recalculate the determinant and the affected cofactors, then retain the condition on the denominator.

det⁡B=1(t)−1(−2)=t+2first-row expansionC=(t2−2t−1121−1t)signed minorsadj⁡B=(t−1121−1−2t2t)transposeB−1=1t+2(t−1121−1−2t2t)t≠−2\begin{aligned} \det\mathbf{B}&=1(t)-1(-2)=t+2 && \text{first-row expansion} \\ \mathbf{C}&=\begin{pmatrix}t&2&-2t\\-1&1&2\\1&-1&t\end{pmatrix} && \text{signed minors} \\ \operatorname{adj}\mathbf{B}&=\begin{pmatrix}t&-1&1\\2&1&-1\\-2t&2&t\end{pmatrix} && \text{transpose} \\ \mathbf{B}^{-1}&=\frac{1}{t+2}\begin{pmatrix}t&-1&1\\2&1&-1\\-2t&2&t\end{pmatrix} && t\ne-2 \end{aligned}

For example, C12=−[0(1)−1(2)]=2C_{12}=-[0(1)-1(2)]=2 and C13=0(0)−t(2)=−2tC_{13}=0(0)-t(2)=-2t.

Why this step? A formula obtained by division is valid only where its denominator is non-zero. State the excluded value even when the numerator matrix has perfectly ordinary entries there.

Answer. B\mathbf{B} is invertible for all real t≠−2t\ne-2, with the displayed inverse.

Check. Multiplying gives Badj⁡B=(t+2)I\mathbf{B}\operatorname{adj}\mathbf{B}=(t+2)\mathbf{I}. For example, its first row is (t+2,0,0)(t+2,0,0), and its second row is (2t−2t,t+2,−t+t)(2t-2t,t+2,-t+t).

These particular determinant and inverse expressions are not in the formula booklet: derive them from the given matrices. A calculator check at one allowed value can catch a slip, but cannot prove an algebraic expression valid for all allowed values.

Watch out

Wrong: “At t=−2t=-2, B−1=0\mathbf{B}^{-1}=\mathbf{0}.” Right: no inverse exists there. The expression contains division by zero, and a zero matrix could never multiply B\mathbf{B} to give I\mathbf{I}.

The opening matrix has a happier outcome. Its determinant is

det⁡H=1(1)−t(−t)=1+t2\det\mathbf{H}=1(1)-t(-t)=1+t^2

For real tt, t2≥0t^2\ge0, so 1+t2>01+t^2>0. It is invertible for every real value of tt, however large, small or negative. Its hand-calculated inverse is

H−1=11+t2(1−t0t10001+t2)\mathbf{H}^{-1}=\frac{1}{1+t^2}\begin{pmatrix}1&-t&0\\t&1&0\\0&0&1+t^2\end{pmatrix}

Multiplication gives I\mathbf{I}; the third coordinate remains unchanged. A variable entry does not automatically create a singular case: only an actual zero of the determinant does.

The last check changes the bottom-left entry of Worked example 6 from 22 to 33. Keep the parameter restriction and the transpose visible.

Quick Recap

  • Delete an entry's row and column to form its minor; apply the alternating position sign to obtain its cofactor.
  • Expand a determinant along one row or column. A row or column containing zeros usually saves work.
  • Form the cofactor matrix, transpose it to obtain the adjugate, then divide by the non-zero determinant.
  • For algebraic entries, find the determinant's zeros and state the excluded parameter values. Check an inverse by multiplying back to the identity.

The opening matrix has determinant 1+t2>01+t^2>0, so it has an inverse for every real tt.