Math Core

Lesson 3.2 · Determinants

Properties of determinants

Cofactor expansion defines the determinant, but it is slow: a 10×1010 \times 10 matrix with no zeros would need millions of multiplications. In this lesson you'll see how row operations change a determinant, which gives a fast way to compute it and leads to the central theorem of the unit: a square matrix is invertible exactly when its determinant is nonzero.

How row operations change the determinant

You know from the last lesson that a triangular matrix has an easy determinant: the product of its diagonal. Row reduction turns any square matrix into a triangular one (an echelon form is upper triangular). So the only question is how each of the three elementary row operations affects the determinant.

Row operations and determinants

Let AA be a square matrix.

  1. Replacement: if BB comes from AA by adding a multiple of one row to another row, then det⁡B=det⁡A\det B = \det A.
  2. Interchange: if BB comes from AA by swapping two rows, then det⁡B=−det⁡A\det B = -\det A.
  3. Scaling: if BB comes from AA by multiplying one row by kk, then det⁡B=kdet⁡A\det B = k \det A.

You can check each rule on a 2×22 \times 2 matrix. Swapping the rows of [abcd]\begin{bmatrix} a & b \\ c & d \end{bmatrix} gives cb−da=−(ad−bc)cb - da = -(ad - bc). Scaling the first row by kk gives (ka)d−(kb)c=k(ad−bc)(ka)d - (kb)c = k(ad - bc). Adding mm times row 1 to row 2 gives a(d+mb)−b(c+ma)=ad−bca(d + mb) - b(c + ma) = ad - bc, since the mabmab terms cancel. The general proof uses cofactor expansion and induction on nn.

In terms of geometry, these rules make sense too. A replacement is a shear, and shears slide a parallelogram without changing its area. Scaling one edge by kk scales the area by kk. A swap reverses orientation, which flips the sign.

The scaling rule is usually used in reverse: you may factor a common number out of a single row, putting it in front of the determinant.

Worked example: Row reducing a 3 × 3 matrix

Compute det⁡A\det A for A=[12−1213−304]A = \begin{bmatrix} 1 & 2 & -1 \\ 2 & 1 & 3 \\ -3 & 0 & 4 \end{bmatrix}.

Use only replacements, which don't change the determinant:

det⁡A=∣12−1213−304∣=∣12−10−35061∣(R2−2R1, R3+3R1)=∣12−10−350011∣(R3+2R2)=1(−3)(11)=−33.\begin{aligned} \det A &= \begin{vmatrix} 1 & 2 & -1 \\ 2 & 1 & 3 \\ -3 & 0 & 4 \end{vmatrix} = \begin{vmatrix} 1 & 2 & -1 \\ 0 & -3 & 5 \\ 0 & 6 & 1 \end{vmatrix} \quad (R_2 - 2R_1,\ R_3 + 3R_1) \\ &= \begin{vmatrix} 1 & 2 & -1 \\ 0 & -3 & 5 \\ 0 & 0 & 11 \end{vmatrix} \quad (R_3 + 2R_2) \\ &= 1(-3)(11) = -33. \end{aligned}

Worked example: A 4 × 4 matrix that needs a swap

Compute det⁡[1−2312−475−13−203−596]\det \begin{bmatrix} 1 & -2 & 3 & 1 \\ 2 & -4 & 7 & 5 \\ -1 & 3 & -2 & 0 \\ 3 & -5 & 9 & 6 \end{bmatrix}.

Clear column 1 with R2−2R1R_2 - 2R_1, R3+R1R_3 + R_1 and R4−3R1R_4 - 3R_1 (no change):

∣1−231001301110103∣.\begin{vmatrix} 1 & -2 & 3 & 1 \\ 0 & 0 & 1 & 3 \\ 0 & 1 & 1 & 1 \\ 0 & 1 & 0 & 3 \end{vmatrix}.

The (2,2)(2, 2) entry is 00, so swap rows 2 and 3. That flips the sign:

−∣1−231011100130103∣.-\begin{vmatrix} 1 & -2 & 3 & 1 \\ 0 & 1 & 1 & 1 \\ 0 & 0 & 1 & 3 \\ 0 & 1 & 0 & 3 \end{vmatrix}.

Now R4−R2R_4 - R_2 gives row 4 =(0,0,−1,2)= (0, 0, -1, 2), and then R4+R3R_4 + R_3 gives (0,0,0,5)(0, 0, 0, 5):

−∣1−231011100130005∣=−(1⋅1⋅1⋅5)=−5.-\begin{vmatrix} 1 & -2 & 3 & 1 \\ 0 & 1 & 1 & 1 \\ 0 & 0 & 1 & 3 \\ 0 & 0 & 0 & 5 \end{vmatrix} = -(1 \cdot 1 \cdot 1 \cdot 5) = -5.

Common mistake

When you scale a row during row reduction, the new determinant is kk times the old one, so to keep an equality you must write det⁡A=1kdet⁡B\det A = \dfrac{1}{k}\det B. It is easy to multiply when you should divide. The safest habit is to avoid scaling entirely: use only replacements and swaps, then multiply the diagonal and attach (−1)number of swaps(-1)^{\text{number of swaps}}.

Determinants and invertibility

Suppose you reduce AA to an echelon form UU using only replacements and rr row swaps. Then

det⁡A=(−1)rdet⁡U=(−1)r⋅(product of the diagonal entries of U).\det A = (-1)^r \det U = (-1)^r \cdot (\text{product of the diagonal entries of } U).

If AA is invertible, every column has a pivot, so every diagonal entry of UU is a nonzero pivot and det⁡A≠0\det A \neq 0. If AA is not invertible, UU has at least one zero on its diagonal (in the square case, a missing pivot forces a zero row at the bottom), so det⁡A=0\det A = 0.

The invertibility test

A square matrix AA is invertible if and only if det⁡A≠0\det A \neq 0.

This adds a new statement to the Invertible Matrix Theorem. In particular, if the columns (or rows) of AA are linearly dependent, then det⁡A=0\det A = 0. So a matrix with two equal rows, or with one row a multiple of another, has determinant 00 without any computation.

Worked example: When is a matrix singular?

For which values of kk is A=[k101k101k]A = \begin{bmatrix} k & 1 & 0 \\ 1 & k & 1 \\ 0 & 1 & k \end{bmatrix} not invertible?

Expand across row 1:

det⁡A=k∣k11k∣−1∣110k∣=k(k2−1)−k=k3−2k=k(k2−2).\det A = k\begin{vmatrix} k & 1 \\ 1 & k \end{vmatrix} - 1\begin{vmatrix} 1 & 1 \\ 0 & k \end{vmatrix} = k(k^2 - 1) - k = k^3 - 2k = k(k^2 - 2).

This is zero when k=0k = 0 or k=±2k = \pm\sqrt{2}. For those three values AA is singular; for every other kk it is invertible.

Transposes and column operations

Transpose

For any square matrix AA, det⁡AT=det⁡A\det A^T = \det A.

The reason: cofactor expansion across row 1 of ATA^T is the same computation as expansion down column 1 of AA. The consequence is that every row rule has a column twin. Swapping two columns flips the sign, scaling a column scales the determinant, and adding a multiple of one column to another changes nothing. You may mix row and column operations freely when computing a determinant (never when solving a system, though).

Products, inverses and scalar multiples

The multiplicative property

If AA and BB are n×nn \times n matrices, then

det⁡(AB)=(det⁡A)(det⁡B).\det(AB) = (\det A)(\det B).

Geometrically this is natural: if BB scales area by a factor of det⁡B\det B and AA scales area by det⁡A\det A, then doing BB and then AA scales area by the product. Two useful consequences follow.

  • Inverses. Since AA−1=IAA^{-1} = I and det⁡I=1\det I = 1, you get (det⁡A)(det⁡A−1)=1(\det A)(\det A^{-1}) = 1, so det⁡(A−1)=1det⁡A\det(A^{-1}) = \dfrac{1}{\det A}.
  • Scalar multiples. The matrix cAcA multiplies every row of AA by cc. That's nn scalings, so det⁡(cA)=cndet⁡A\det(cA) = c^n \det A for an n×nn \times n matrix.

Worked example: Combining the properties

Let AA and BB be 3×33 \times 3 matrices with det⁡A=3\det A = 3 and det⁡B=−2\det B = -2. Find det⁡(2ABT)\det(2AB^T) and det⁡(A−1B3)\det(A^{-1}B^3).

det⁡(2ABT)=23det⁡Adet⁡BT=8(3)(−2)=−48.\det(2AB^T) = 2^3 \det A \det B^T = 8(3)(-2) = -48.det⁡(A−1B3)=1det⁡A(det⁡B)3=13(−8)=−83.\det(A^{-1}B^3) = \frac{1}{\det A}(\det B)^3 = \frac{1}{3}(-8) = -\frac{8}{3}.

Common mistake

The determinant does not respect addition: in general det⁡(A+B)≠det⁡A+det⁡B\det(A + B) \neq \det A + \det B. Try A=B=I2A = B = I_2: det⁡(2I)=4\det(2I) = 4, but det⁡I+det⁡I=2\det I + \det I = 2. The same example shows why det⁡(cA)\det(cA) is cndet⁡Ac^n\det A, not cdet⁡Ac\det A.

Tip

Before computing any determinant, scan for shortcuts: a zero row or column, two proportional rows or columns (determinant 00), or a triangular shape (multiply the diagonal).

Practice

Practice 1

Let AA be a 3×33 \times 3 matrix with det⁡A=4\det A = 4. The matrix BB is obtained from AA by these steps, in order: add −5-5 times row 1 to row 2; swap rows 1 and 2; multiply row 3 by 33. Find det⁡B\det B.

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

Practice 2

Use row operations to compute det⁡[24−2135−1−14]\det \begin{bmatrix} 2 & 4 & -2 \\ 1 & 3 & 5 \\ -1 & -1 & 4 \end{bmatrix}.

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

Practice 3

Use row operations to compute det⁡[1302−2−51−339281434]\det \begin{bmatrix} 1 & 3 & 0 & 2 \\ -2 & -5 & 1 & -3 \\ 3 & 9 & 2 & 8 \\ 1 & 4 & 3 & 4 \end{bmatrix}.

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

Practice 4

Let AA and BB be 3×33 \times 3 matrices with det⁡A=−2\det A = -2 and det⁡B=5\det B = 5. Find det⁡(A2BT)\det(A^2B^T).

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

Practice 5

Let AA be a 4×44 \times 4 matrix with det⁡A=3\det A = 3. Find det⁡(−2A)\det(-2A).

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

Practice 6

Find all values of hh for which [11112h14h2]\begin{bmatrix} 1 & 1 & 1 \\ 1 & 2 & h \\ 1 & 4 & h^2 \end{bmatrix} is singular.

Separate answers with commas, e.g. 2, -5

Practice 7

Let AA and BB be n×nn \times n matrices with n≥2n \ge 2. Which statement is always true?

Practice 8

A square matrix QQ satisfies QTQ=IQ^TQ = I. What are the possible values of det⁡Q\det Q?

Separate answers with commas, e.g. 2, -5