Determinants

Compute the single number that reveals whether a matrix is invertible

Every square matrix has a special number associated with it, a single value that captures an enormous amount of information about the matrix. This number is called the determinant. It tells you whether the matrix is invertible, how the matrix scales areas and volumes, and whether the columns of the matrix are linearly independent. A whole world of information compressed into one number.

The determinant might seem like just another formula to memorize, but it has deep geometric meaning. When a matrix transforms space, the determinant tells you exactly how much the transformation stretches or shrinks areas (in 2D) or volumes (in 3D). A determinant of 2 means areas double. A determinant of 0.5 means areas are cut in half. And a determinant of 0? That means the transformation collapses space down to a lower dimension, squashing areas to zero, which is precisely why such matrices cannot be inverted.

In this lesson, you will learn how to compute determinants for $2 \times 2$ and $3 \times 3$ matrices, understand what the determinant tells you geometrically, and discover the key properties that make determinants so useful throughout mathematics and its applications.

Core Concepts

What Is a Determinant?

The determinant is a function that takes a square matrix and returns a single number. We write it as $\det(A)$ or sometimes with vertical bars like $|A|$. For a matrix $A$, this number encodes several important properties:

  1. Invertibility: The matrix $A$ is invertible if and only if $\det(A) \neq 0$
  2. Area/Volume scaling: The absolute value $|\det(A)|$ tells you how much the transformation scales areas or volumes
  3. Orientation: The sign of $\det(A)$ tells you whether the transformation preserves or reverses orientation

Only square matrices have determinants. A $2 \times 2$ matrix has a determinant, a $3 \times 3$ matrix has a determinant, but a $2 \times 3$ matrix does not.

Determinant of a 2x2 Matrix

The formula for the determinant of a $2 \times 2$ matrix is beautifully simple:

$$\det\begin{pmatrix} a & b \ c & d \end{pmatrix} = ad - bc$$

You multiply the entries on the main diagonal (top-left to bottom-right) and subtract the product of the entries on the anti-diagonal (top-right to bottom-left).

For example:

$$\det\begin{pmatrix} 3 & 2 \ 1 & 4 \end{pmatrix} = (3)(4) - (2)(1) = 12 - 2 = 10$$

This formula appears throughout mathematics. It shows up in the formula for the inverse of a $2 \times 2$ matrix, in the equation of a line through two points, and in the cross product of vectors.

Geometric Interpretation: Signed Area

Here is where the determinant becomes truly meaningful. Consider a $2 \times 2$ matrix $A$ whose columns are two vectors $\vec{u}$ and $\vec{v}$:

$$A = \begin{pmatrix} u_1 & v_1 \ u_2 & v_2 \end{pmatrix}$$

The absolute value of the determinant $|\det(A)|$ equals the area of the parallelogram formed by $\vec{u}$ and $\vec{v}$.

Think about the unit square, the square with corners at $(0,0)$, $(1,0)$, $(0,1)$, and $(1,1)$. When you multiply by the matrix $A$, the unit square transforms into a parallelogram. The area of that parallelogram is exactly $|\det(A)|$.

If $\det(A) > 0$, the transformation preserves orientation (counterclockwise stays counterclockwise). If $\det(A) < 0$, the transformation reverses orientation (like a reflection). If $\det(A) = 0$, the parallelogram collapses to a line or a point, meaning the transformation squashes 2D space down to 1D or 0D.

Minors and Cofactors

Before tackling $3 \times 3$ determinants, you need two preliminary concepts.

A minor $M_{ij}$ is the determinant of the smaller matrix you get by deleting row $i$ and column $j$ from the original matrix. For a $3 \times 3$ matrix, each minor is the determinant of a $2 \times 2$ submatrix.

A cofactor $C_{ij}$ is the signed minor:

$$C_{ij} = (-1)^{i+j} M_{ij}$$

The factor $(-1)^{i+j}$ creates a checkerboard pattern of signs:

$$\begin{pmatrix} + & - & + \ - & + & - \ + & - & + \end{pmatrix}$$

Position $(1,1)$ gets a plus (since $(-1)^{1+1} = 1$), position $(1,2)$ gets a minus (since $(-1)^{1+2} = -1$), and so on.

Determinant of a 3x3 Matrix: Cofactor Expansion

The determinant of a $3 \times 3$ matrix is computed using cofactor expansion (also called Laplace expansion). You can expand along any row or column; the result is always the same. Expanding along the first row is most common:

$$\det\begin{pmatrix} a_{11} & a_{12} & a_{13} \ a_{21} & a_{22} & a_{23} \ a_{31} & a_{32} & a_{33} \end{pmatrix} = a_{11}C_{11} + a_{12}C_{12} + a_{13}C_{13}$$

This means: take each entry in the first row, multiply it by its cofactor, and add them up.

Expanding this:

$$\det(A) = a_{11}\det\begin{pmatrix} a_{22} & a_{23} \ a_{32} & a_{33} \end{pmatrix} - a_{12}\det\begin{pmatrix} a_{21} & a_{23} \ a_{31} & a_{33} \end{pmatrix} + a_{13}\det\begin{pmatrix} a_{21} & a_{22} \ a_{31} & a_{32} \end{pmatrix}$$

The pattern of signs (plus, minus, plus) comes from the cofactor signs.

For $3 \times 3$ matrices, you can also use the Rule of Sarrus (a shortcut involving diagonals), but cofactor expansion generalizes to larger matrices while Sarrus does not.

Geometric Interpretation in 3D: Signed Volume

Just as the $2 \times 2$ determinant gives signed area, the $3 \times 3$ determinant gives signed volume. If the columns of a $3 \times 3$ matrix $A$ are three vectors $\vec{u}$, $\vec{v}$, and $\vec{w}$, then $|\det(A)|$ equals the volume of the parallelepiped (a 3D parallelogram) spanned by these vectors.

When $\det(A) = 0$, the three vectors lie in a plane (or worse), so they span no volume. This means the vectors are linearly dependent, and the matrix is not invertible.

Determinant and Invertibility

This is one of the most important facts about determinants:

$$\text{A matrix } A \text{ is invertible} \quad \Longleftrightarrow \quad \det(A) \neq 0$$

When $\det(A) = 0$, we say the matrix is singular. Singular matrices cannot be inverted because they collapse space, mapping distinct inputs to the same output, which means you cannot reverse the process.

When $\det(A) \neq 0$, the matrix is nonsingular (or invertible). The transformation can be undone because it does not collapse any dimensions.

Effect of Row Operations on Determinants

Row operations change the determinant in predictable ways:

1. Row swap: Swapping two rows multiplies the determinant by $-1$.

$$\det\begin{pmatrix} a & b \ c & d \end{pmatrix} = -\det\begin{pmatrix} c & d \ a & b \end{pmatrix}$$

2. Row scaling: Multiplying a row by a scalar $k$ multiplies the determinant by $k$.

$$\det\begin{pmatrix} ka & kb \ c & d \end{pmatrix} = k \cdot \det\begin{pmatrix} a & b \ c & d \end{pmatrix}$$

3. Row replacement: Adding a multiple of one row to another does not change the determinant.

$$\det\begin{pmatrix} a & b \ c + ka & d + kb \end{pmatrix} = \det\begin{pmatrix} a & b \ c & d \end{pmatrix}$$

These rules let you compute determinants efficiently by reducing the matrix to a triangular form, where the determinant is simply the product of the diagonal entries.

Key Properties of Determinants

Determinants satisfy several important algebraic properties:

Multiplicative property: $$\det(AB) = \det(A) \cdot \det(B)$$

The determinant of a product is the product of the determinants. This makes sense geometrically: if $A$ scales areas by a factor of 3 and $B$ scales areas by a factor of 2, then $AB$ scales areas by a factor of 6.

Transpose property: $$\det(A^T) = \det(A)$$

Transposing a matrix does not change its determinant.

Inverse property: $$\det(A^{-1}) = \frac{1}{\det(A)}$$

If $A$ scales areas by a factor of 5, then $A^{-1}$ scales areas by a factor of $\frac{1}{5}$.

Scalar multiplication: $$\det(kA) = k^n \det(A) \quad \text{for an } n \times n \text{ matrix}$$

Scaling every entry by $k$ is like scaling each of the $n$ rows by $k$, so the determinant picks up a factor of $k^n$.

Triangular matrices:

For a triangular matrix (upper or lower), the determinant is the product of the diagonal entries:

$$\det\begin{pmatrix} a & b & c \ 0 & d & e \ 0 & 0 & f \end{pmatrix} = adf$$

This is particularly useful because row reduction produces triangular matrices.

Cramer’s Rule

For small systems of linear equations, Cramer’s Rule provides an explicit formula for each variable in terms of determinants.

Consider the system $A\vec{x} = \vec{b}$ where $A$ is an $n \times n$ invertible matrix. Cramer’s Rule says:

$$x_i = \frac{\det(A_i)}{\det(A)}$$

where $A_i$ is the matrix obtained by replacing the $i$-th column of $A$ with the vector $\vec{b}$.

For a $2 \times 2$ system:

$$\begin{cases} ax + by = e \ cx + dy = f \end{cases}$$

Cramer’s Rule gives:

$$x = \frac{\det\begin{pmatrix} e & b \ f & d \end{pmatrix}}{\det\begin{pmatrix} a & b \ c & d \end{pmatrix}} = \frac{ed - bf}{ad - bc}$$

$$y = \frac{\det\begin{pmatrix} a & e \ c & f \end{pmatrix}}{\det\begin{pmatrix} a & b \ c & d \end{pmatrix}} = \frac{af - ec}{ad - bc}$$

Cramer’s Rule is elegant but computationally inefficient for large systems. It is most useful for theoretical purposes and for solving small systems by hand.

Notation and Terminology

Term Meaning Example
$\det(A)$ or $|A|$ Determinant of matrix $A$ $\det\begin{pmatrix} 3 & 1 \ 2 & 4 \end{pmatrix} = 10$
Minor $M_{ij}$ Determinant of submatrix after deleting row $i$, column $j$
Cofactor $C_{ij}$ Signed minor: $C_{ij} = (-1)^{i+j}M_{ij}$
Singular Matrix with $\det(A) = 0$; not invertible
Nonsingular Matrix with $\det(A) \neq 0$; invertible
Cofactor expansion Computing determinant by expanding along a row or column

Examples

Example 1: Finding a 2x2 Determinant

Find $\det\begin{pmatrix} 3 & 1 \ 2 & 4 \end{pmatrix}$.

Solution:

Using the formula $\det\begin{pmatrix} a & b \ c & d \end{pmatrix} = ad - bc$:

$$\det\begin{pmatrix} 3 & 1 \ 2 & 4 \end{pmatrix} = (3)(4) - (1)(2) = 12 - 2 = 10$$

Interpretation: Since $\det(A) = 10 \neq 0$, this matrix is invertible. Also, the matrix scales areas by a factor of 10.

Answer: $\det(A) = 10$

Example 2: Finding Values That Make a Matrix Singular

For what value of $x$ is $\begin{pmatrix} x & 2 \ 3 & x \end{pmatrix}$ singular?

Solution:

A matrix is singular when its determinant equals zero.

Step 1: Compute the determinant.

$$\det\begin{pmatrix} x & 2 \ 3 & x \end{pmatrix} = (x)(x) - (2)(3) = x^2 - 6$$

Step 2: Set the determinant equal to zero and solve.

$$x^2 - 6 = 0$$ $$x^2 = 6$$ $$x = \pm\sqrt{6}$$

Verification: When $x = \sqrt{6}$: $$\det\begin{pmatrix} \sqrt{6} & 2 \ 3 & \sqrt{6} \end{pmatrix} = 6 - 6 = 0$$

Answer: The matrix is singular when $x = \sqrt{6}$ or $x = -\sqrt{6}$.

Example 3: Finding a 3x3 Determinant

Find $\det\begin{pmatrix} 1 & 2 & 3 \ 0 & 1 & 4 \ 5 & 6 & 0 \end{pmatrix}$.

Solution:

We will use cofactor expansion along the first row.

$$\det(A) = a_{11}C_{11} + a_{12}C_{12} + a_{13}C_{13}$$

Step 1: Find each cofactor.

For $C_{11}$ (sign is $+$ since $(-1)^{1+1} = 1$): $$C_{11} = +\det\begin{pmatrix} 1 & 4 \ 6 & 0 \end{pmatrix} = (1)(0) - (4)(6) = 0 - 24 = -24$$

For $C_{12}$ (sign is $-$ since $(-1)^{1+2} = -1$): $$C_{12} = -\det\begin{pmatrix} 0 & 4 \ 5 & 0 \end{pmatrix} = -[(0)(0) - (4)(5)] = -[0 - 20] = 20$$

For $C_{13}$ (sign is $+$ since $(-1)^{1+3} = 1$): $$C_{13} = +\det\begin{pmatrix} 0 & 1 \ 5 & 6 \end{pmatrix} = (0)(6) - (1)(5) = 0 - 5 = -5$$

Step 2: Compute the determinant.

$$\det(A) = (1)(-24) + (2)(20) + (3)(-5)$$ $$= -24 + 40 - 15$$ $$= 1$$

Answer: $\det(A) = 1$

Since the determinant is 1 (not zero), this matrix is invertible. The matrix preserves volume exactly (neither stretching nor shrinking it) and preserves orientation.

Example 4: Using Determinant Properties

If $A$ is a $3 \times 3$ matrix with $\det(A) = 5$, find $\det(2A)$.

Solution:

We use the scalar multiplication property: $\det(kA) = k^n \det(A)$ for an $n \times n$ matrix.

Here, $k = 2$ and $n = 3$, so:

$$\det(2A) = 2^3 \cdot \det(A) = 8 \cdot 5 = 40$$

Why does this make sense geometrically?

Multiplying every entry of $A$ by 2 is equivalent to scaling every row by 2. Each row scaling multiplies the determinant by 2. With 3 rows, we get $2 \times 2 \times 2 = 8$ as the scaling factor for the determinant.

Alternatively, think in terms of volume: scaling every coordinate by 2 means lengths double in all three directions, so volume increases by $2^3 = 8$.

Answer: $\det(2A) = 40$

Example 5: Solving a System Using Cramer's Rule

Use Cramer’s Rule to solve the system: $$2x + y = 5$$ $$x - 3y = -8$$

Solution:

First, write the system in matrix form $A\vec{x} = \vec{b}$:

$$A = \begin{pmatrix} 2 & 1 \ 1 & -3 \end{pmatrix}, \quad \vec{b} = \begin{pmatrix} 5 \ -8 \end{pmatrix}$$

Step 1: Compute $\det(A)$.

$$\det(A) = (2)(-3) - (1)(1) = -6 - 1 = -7$$

Since $\det(A) \neq 0$, the system has a unique solution and Cramer’s Rule applies.

Step 2: Compute $\det(A_1)$ where $A_1$ has the first column replaced by $\vec{b}$.

$$A_1 = \begin{pmatrix} 5 & 1 \ -8 & -3 \end{pmatrix}$$

$$\det(A_1) = (5)(-3) - (1)(-8) = -15 + 8 = -7$$

Step 3: Compute $\det(A_2)$ where $A_2$ has the second column replaced by $\vec{b}$.

$$A_2 = \begin{pmatrix} 2 & 5 \ 1 & -8 \end{pmatrix}$$

$$\det(A_2) = (2)(-8) - (5)(1) = -16 - 5 = -21$$

Step 4: Apply Cramer’s Rule.

$$x = \frac{\det(A_1)}{\det(A)} = \frac{-7}{-7} = 1$$

$$y = \frac{\det(A_2)}{\det(A)} = \frac{-21}{-7} = 3$$

Verification: Substitute back into the original equations.

  • $2(1) + (3) = 2 + 3 = 5$ (checks)
  • $(1) - 3(3) = 1 - 9 = -8$ (checks)

Answer: $x = 1$, $y = 3$

Key Properties and Rules

Summary of Determinant Properties

Property Formula Notes
Product rule $\det(AB) = \det(A)\det(B)$ Determinants multiply
Transpose $\det(A^T) = \det(A)$ Transposing preserves determinant
Inverse $\det(A^{-1}) = 1/\det(A)$ Inverse has reciprocal determinant
Scalar multiple $\det(kA) = k^n\det(A)$ For $n \times n$ matrix
Row swap Multiplies $\det$ by $-1$ Sign changes
Row scaling Multiplies $\det$ by $k$ One row scaled by $k$
Row replacement Does not change $\det$ Adding multiple of one row to another
Triangular matrix $\det = $ product of diagonal entries Very efficient
Singular $\det(A) = 0$ Not invertible
Nonsingular $\det(A) \neq 0$ Invertible

Computing Determinants Efficiently

For hand calculations:

  1. 2x2 matrices: Use the formula $ad - bc$ directly.

  2. 3x3 matrices: Use cofactor expansion. Expand along a row or column with zeros if possible (this reduces computation).

  3. Larger matrices: Use row reduction to get a triangular matrix, then multiply the diagonal entries. Keep track of row swaps (each changes the sign) and row scalings (each multiplies by the scalar).

  4. Special matrices: The determinant of a diagonal or triangular matrix is the product of the diagonal entries.

Real-World Applications

Testing if a Matrix Transformation Preserves Area or Volume

In computer graphics and physics simulations, you often need to know whether a transformation preserves, enlarges, or shrinks objects. The determinant gives you this information immediately:

  • $|\det(A)| = 1$: The transformation preserves area/volume (like a rotation)
  • $|\det(A)| > 1$: The transformation enlarges
  • $|\det(A)| < 1$: The transformation shrinks
  • $\det(A) < 0$: The transformation includes a reflection

Checking Linear Independence

To determine whether a set of vectors is linearly independent, form a matrix with those vectors as columns. If the determinant is nonzero, the vectors are linearly independent. If the determinant is zero, the vectors are linearly dependent (one can be written as a combination of the others).

Cross Product in 3D

The cross product of two 3D vectors can be computed using a determinant:

$$\vec{u} \times \vec{v} = \det\begin{pmatrix} \vec{i} & \vec{j} & \vec{k} \ u_1 & u_2 & u_3 \ v_1 & v_2 & v_3 \end{pmatrix}$$

Expanding this symbolic determinant gives you the cross product formula. The magnitude of the cross product equals the area of the parallelogram formed by $\vec{u}$ and $\vec{v}$, which connects back to the geometric interpretation of determinants.

Eigenvalue Calculations

Eigenvalues are found by solving $\det(A - \lambda I) = 0$. This equation, called the characteristic equation, is a polynomial in $\lambda$ whose roots are the eigenvalues of $A$. Determinants are thus essential to the entire theory of eigenvalues, which has applications in:

  • Stability analysis of systems
  • Principal component analysis in data science
  • Quantum mechanics
  • Vibration analysis in engineering

Self-Test Problems

Problem 1: Compute $\det\begin{pmatrix} 5 & 2 \ 3 & 7 \end{pmatrix}$.

Show Answer

Using the formula $\det\begin{pmatrix} a & b \ c & d \end{pmatrix} = ad - bc$:

$$\det\begin{pmatrix} 5 & 2 \ 3 & 7 \end{pmatrix} = (5)(7) - (2)(3) = 35 - 6 = 29$$

Answer: 29

Problem 2: For what values of $k$ is $\begin{pmatrix} k & 4 \ 1 & k \end{pmatrix}$ singular?

Show Answer

A matrix is singular when its determinant is zero.

$$\det\begin{pmatrix} k & 4 \ 1 & k \end{pmatrix} = k^2 - 4 = 0$$

$$k^2 = 4$$

$$k = \pm 2$$

Answer: $k = 2$ or $k = -2$

Problem 3: Compute $\det\begin{pmatrix} 2 & 1 & 3 \ 0 & 4 & 1 \ 0 & 0 & 5 \end{pmatrix}$.

Show Answer

This is an upper triangular matrix. The determinant is the product of the diagonal entries:

$$\det(A) = (2)(4)(5) = 40$$

Answer: 40

Problem 4: If $\det(A) = 3$ and $\det(B) = -2$, find $\det(AB)$ and $\det(A^2B)$.

Show Answer

Using the multiplicative property $\det(AB) = \det(A)\det(B)$:

$$\det(AB) = \det(A) \cdot \det(B) = (3)(-2) = -6$$

For $\det(A^2B)$:

$$\det(A^2B) = \det(A^2) \cdot \det(B) = \det(A)^2 \cdot \det(B) = (3)^2 \cdot (-2) = 9 \cdot (-2) = -18$$

Answers: $\det(AB) = -6$ and $\det(A^2B) = -18$

Problem 5: If $A$ is a $4 \times 4$ matrix with $\det(A) = 2$, find $\det(3A)$.

Show Answer

Using $\det(kA) = k^n \det(A)$ for an $n \times n$ matrix:

$$\det(3A) = 3^4 \cdot \det(A) = 81 \cdot 2 = 162$$

Answer: 162

Problem 6: Compute $\det\begin{pmatrix} 1 & 0 & 2 \ 3 & 1 & 0 \ 2 & 4 & 1 \end{pmatrix}$ using cofactor expansion along the first row.

Show Answer

Expanding along the first row:

$$\det(A) = (1) \cdot C_{11} + (0) \cdot C_{12} + (2) \cdot C_{13}$$

Since the middle term has a factor of 0, we only need $C_{11}$ and $C_{13}$.

$$C_{11} = (+1)\det\begin{pmatrix} 1 & 0 \ 4 & 1 \end{pmatrix} = (1)(1) - (0)(4) = 1$$

$$C_{13} = (+1)\det\begin{pmatrix} 3 & 1 \ 2 & 4 \end{pmatrix} = (3)(4) - (1)(2) = 12 - 2 = 10$$

$$\det(A) = (1)(1) + (0)(\text{anything}) + (2)(10) = 1 + 0 + 20 = 21$$

Answer: 21

Problem 7: Use Cramer’s Rule to solve: $3x + 2y = 7$, $x - y = 1$.

Show Answer

The coefficient matrix is $A = \begin{pmatrix} 3 & 2 \ 1 & -1 \end{pmatrix}$ and $\vec{b} = \begin{pmatrix} 7 \ 1 \end{pmatrix}$.

Step 1: $\det(A) = (3)(-1) - (2)(1) = -3 - 2 = -5$

Step 2: $\det(A_1) = \det\begin{pmatrix} 7 & 2 \ 1 & -1 \end{pmatrix} = (7)(-1) - (2)(1) = -7 - 2 = -9$

Step 3: $\det(A_2) = \det\begin{pmatrix} 3 & 7 \ 1 & 1 \end{pmatrix} = (3)(1) - (7)(1) = 3 - 7 = -4$

Step 4: Apply Cramer’s Rule.

$$x = \frac{-9}{-5} = \frac{9}{5}$$

$$y = \frac{-4}{-5} = \frac{4}{5}$$

Verification:

  • $3(\frac{9}{5}) + 2(\frac{4}{5}) = \frac{27}{5} + \frac{8}{5} = \frac{35}{5} = 7$ (checks)
  • $\frac{9}{5} - \frac{4}{5} = \frac{5}{5} = 1$ (checks)

Answer: $x = \frac{9}{5}$, $y = \frac{4}{5}$

Summary

  • The determinant of a square matrix is a single number that encodes key information about the matrix.

  • For a $2 \times 2$ matrix: $\det\begin{pmatrix} a & b \ c & d \end{pmatrix} = ad - bc$

  • For a $3 \times 3$ matrix, use cofactor expansion: multiply each entry in a row by its cofactor and sum.

  • Geometric interpretation: $|\det(A)|$ gives the scaling factor for areas (2D) or volumes (3D). The sign indicates whether orientation is preserved ($+$) or reversed ($-$).

  • Invertibility criterion: A matrix is invertible if and only if $\det(A) \neq 0$. When $\det(A) = 0$, the matrix is singular.

  • Key properties:

    • $\det(AB) = \det(A)\det(B)$ (multiplicative)
    • $\det(A^T) = \det(A)$ (transpose preserves determinant)
    • $\det(kA) = k^n\det(A)$ for an $n \times n$ matrix
    • $\det(A^{-1}) = 1/\det(A)$
  • Row operations affect determinants: Row swaps change the sign, row scaling multiplies by the scalar, and row replacement leaves the determinant unchanged.

  • Triangular matrices have determinants equal to the product of their diagonal entries.

  • Cramer’s Rule expresses each variable as a ratio of determinants, useful for small systems and theoretical analysis.

  • Applications include testing invertibility, checking linear independence, computing cross products, finding eigenvalues, and understanding how transformations scale areas and volumes.