Visual Tools
Calculators
Tables
Mathematical Keyboard
Converters
Other Tools

How to Find a Determinant by Cofactor Expansion

Choose one row or column. Multiply each entry in it by its checkerboard sign and by the determinant of what is left after deleting its row and column, then add. Zeros in the chosen line cost nothing.

Recognize the task

A 3×33 \times 3 or 4×44 \times 4 determinant, especially with a row or column of mostly zeros: det⁡(201304152)\det\begin{pmatrix} 2 & 0 & 1 \\ 3 & 0 & 4 \\ 1 & 5 & 2 \end{pmatrix}, a 4×44 \times 4 with three zeros in a row, or a matrix with a variable such as det⁡(A−λI)\det(A - \lambda I). Test: count the zeros in each row and column and pick the line with the most.
Minors, cofactors and the expansion are defined in the Laplace expansion lesson section; the formula is the Laplace row expansion.

Steps

StepOn A=(201304152)A = \begin{pmatrix} 2 & 0 & 1 \\ 3 & 0 & 4 \\ 1 & 5 & 2 \end{pmatrix}
1Pick the row or column with the most zeros. Every line gives the same answer; a column expansion works exactly like a row expansion.column 2 has two zeros: only a32=5a_{32} = 5 counts
2Write the signs for that line. Position (i,j)(i, j) has sign (−1)i+j(-1)^{i+j}: a checkerboard starting with ++ at the top left.column 2 signs −,+,−-, +, -; position (3,2)(3,2) is −-
3Find the minor of each nonzero entry. Delete the row and the column of the entry and take the determinant of what remains.The ad − bc formula ↗M32=det⁡(2134)=8−3=5M_{32} = \det\begin{pmatrix} 2 & 1 \\ 3 & 4 \end{pmatrix} = 8 - 3 = 5
4Add entry times sign times minor. Sign times minor is the cofactor Cij=(−1)i+jMijC_{ij} = (-1)^{i+j}M_{ij}.det⁡(A)=5⋅(−1)⋅5=−25\det(A) = 5 \cdot (-1) \cdot 5 = -25

Worked examples

Example 1 · a row with one zero

3 × 3
(2−13102411)\begin{pmatrix} 2 & -1 & 3 \\ 1 & 0 & 2 \\ 4 & 1 & 1 \end{pmatrix}: expand along row 2, signs −,+,−-, +, -
the zero skips one minor
−1⋅det⁡(−1311)−2⋅det⁡(2−141)-1 \cdot \det\begin{pmatrix} -1 & 3 \\ 1 & 1 \end{pmatrix} - 2 \cdot \det\begin{pmatrix} 2 & -1 \\ 4 & 1 \end{pmatrix}
=−1(−4)−2(6)=4−12=−8= -1(-4) - 2(6) = 4 - 12 = -8

Example 2 · a 4×4 matrix

one nonzero entry
(1020310100402015)\begin{pmatrix} 1 & 0 & 2 & 0 \\ 3 & 1 & 0 & 1 \\ 0 & 0 & 4 & 0 \\ 2 & 0 & 1 & 5 \end{pmatrix}: row 3 has only a33=4a_{33} = 4
sign (−1)3+3=+(-1)^{3+3} = +
det⁡=4⋅det⁡(100311205)\det = 4 \cdot \det\begin{pmatrix} 1 & 0 & 0 \\ 3 & 1 & 1 \\ 2 & 0 & 5 \end{pmatrix}
delete row 3 and column 3
=4⋅1⋅det⁡(1105)=4⋅5=20= 4 \cdot 1 \cdot \det\begin{pmatrix} 1 & 1 \\ 0 & 5 \end{pmatrix} = 4 \cdot 5 = 20
expand the 3×33 \times 3 along row 1

Example 3 · a variable entry

characteristic polynomial
det⁡(2−λ1012−λ0003−λ)\det\begin{pmatrix} 2-\lambda & 1 & 0 \\ 1 & 2-\lambda & 0 \\ 0 & 0 & 3-\lambda \end{pmatrix}: expand along row 3
two zeros in row 3
=(3−λ)[(2−λ)2−1]= (3-\lambda)\big[(2-\lambda)^2 - 1\big]
sign ++ at (3,3)(3,3)
=(3−λ)(λ−1)(λ−3)= (3-\lambda)(\lambda - 1)(\lambda - 3)
factor λ2−4λ+3\lambda^2 - 4\lambda + 3
Try other rows and columns in the determinant visualizer; every choice gives the same value.

See it happen

The determinant is linear in each row. Splitting row ii into its entries, one at a time, breaks the determinant into nn pieces; in each piece one entry stands alone in its row, and its row and column fall away to leave a smaller determinant. The checkerboard sign records how many swaps it takes to move that entry to the top left corner.

Common mistakes

Reusing the first-row signs on another line

✗ column 2 expanded with signs +,−,++, -, +
✓ column 2 starts with −-: signs −,+,−-, +, -

Forgetting the sign altogether

✗ det⁡(A)=a32M32=25\det(A) = a_{32} M_{32} = 25
✓ det⁡(A)=a32C32=5⋅(−5)=−25\det(A) = a_{32} C_{32} = 5 \cdot (-5) = -25

Deleting the wrong row or column

✗ M32M_{32} found by deleting row 2 and column 3
✓ MijM_{ij}: delete row ii and column jj

Expanding along a full row

✗ four 3×33 \times 3 minors for a 4×44 \times 4 that has a row with three zeros
✓ expand along that row: one minor instead of four