You are on page 1of 17

Recursive definition of determinants Cofactor expansions

MATH 4A - Linear Algebra with Applications


Lecture 10: Determinants and cofactors

22 April 2019

Reading: §3.1-3.3 from Lay, 5th ed.


Recommended problems from §3.1: 1, 3, 5, 9, 11, 13, 15, 17, 39,
40
Recursive definition of determinants Cofactor expansions

Lecture plan

1 Recursive definition of determinants

2 Cofactor expansions
Recursive definition of determinants Cofactor expansions

Motivation

 
a11 a21
Let A = be a 2 × 2 matrix. We saw in the previous
a12 a22
lecture that the determinant

det A = a11 a22 − a12 a21

was useful for determining if A is invertible: namely, A is invertible


if and only if det(A) 6= 0.

We’d like to generalize this useful fact to larger matrices, not just
2 × 2 matrices. First, we need to define the determinant of an
arbitrary n × n matrix. (In our next lecture, we’ll also see a useful
geometric interpretation of determinants that is essential in
multivariable calculus.)
Recursive definition of determinants Cofactor expansions

Some notation

Given a n × n matrix

a11 · · · ···
 
a1j a1n
 .. .. .. 
 . . . 
 
 ai1 · · ·
A= aij ··· ain 
 . .. .. 
 .. . . 
am1 · · · amj ··· amn

we will sometimes write this more compactly as

A = (aij ).
Recursive definition of determinants Cofactor expansions

Warm-up: 3 × 3 matrices
Let A = (aij ) be a 3 × 3 matrix, and suppose it is invertible. We’re
going to “discover” the determinant of A by trying to row reduce
it.
Since A is invertible, the first column of A can’t be all zeros. Let’s
assume for simplicity that a11 6= 0 (we could always swap two
rows). Then we can perform the following row operations:
 
a11 a12 a13
R2 7→a11 R2
A −−−−−−→ a11 a21 a11 a22 a11 a23 
R3 7→a11 R3
a11 a31 a11 a32 a11 a33
 
a11 a12 a13
R 7→R −a21 R1
−−2−−−2−−− −→  0 a11 a22 − a12 a21 a11 a23 − a13 a21 
R3 7→R3 −a31 R1
0 a11 a32 − a12 a31 a11 a33 − a13 a31
Because A is invertible, so is this row equivalent matrix. In
particular, at least one of the numbers a11 a22 − a12 a21 or
a11 a32 − a12 a31 must be nonzero.
Recursive definition of determinants Cofactor expansions

Warm-up: 3 × 3 matrices

For simplicity, we’ll assume a11 a22 − a12 a21 is nonzero (we could
always swap rows). Then we can continue row reducing (this is
going to get gnarly, but determinants are gnarly!):
 
a11 a12 a13
R3 7→(a11 a22 −a12 a21 )R3
0 a11 a22 − a12 a21 a11 a23 − a13 a21  −−−−−−−−−−−−−→
0 a11 a32 − a12 a31 a11 a33 − a13 a31
 
a11 a12 a13
0 a11 a22 − a12 a21 a11 a23 − a13 a21 
0 (a11 a22 − a12 a21 )(a11 a32 − a12 a31 ) (a11 a22 − a12 a21 )(a11 a33 − a13 a31 )

Finally, if perform the row operation

R3 7→ R3 − (a11 a32 − a12 a31 )R2

on this last matrix, we see that. . .


Recursive definition of determinants Cofactor expansions

Determinant of a 3 × 3 matrix

. . . our original 3 × 3 matrix A is row equivalent to


 
a11 a12 a13
0 a11 a22 − a12 a21 a11 a23 − a13 a2 1
0 0 a11 ∆

where

∆ = a11 a22 a33 + a12 a23 a31 + a13 a21 a32 − a11 a23 a32 − a12 a21 a33 − a13 a22 a31

Since A is invertible, we know ∆ 6= 0. We call ∆ the determinant


of the 3 × 3 matrix A, and write

det(A) = a11 a22 a33 +a12 a23 a31 +a13 a21 a32 −a11 a23 a32 −a12 a21 a33 −a13 a22 a31

(Later, we’ll show the converse: if det(A) 6= 0, then A is


invertible.)
Recursive definition of determinants Cofactor expansions

Phew! Is there a better way to understand this formula?

Yes! First, some notation: for any n × n square matrix B, let Bij
denote the (n − 1) × (n − 1) square matrix gotten by deleting the
i th row and j th column of B.

Using the 3 × 3 matrix


 
a11 a12 a13
A = a21 a22 a23  ,
a31 a32 a33

here are some examples:


     
a22 a23 a21 a23 a21 a22
A11 = A12 = A13 =
a32 a33 a31 a33 a31 a32
Recursive definition of determinants Cofactor expansions

Now we can understand the 3 × 3 determinant recursively


in terms of the 2 × 2 determinant
You can check the following now:
det(A) = a11 a22 a33 + a12 a23 a31 + a13 a21 a32 − a11 a23 a32 − a12 a21 a33 − a13 a22 a31
= (a11 a22 a33 − a11 a23 a32 ) − (a12 a21 a33 − a12 a23 a31 ) + (a13 a21 a32 − a13 a22 a31 )
= a11 (a22 a33 − a23 a32 ) − a12 (a21 a33 − a23 a31 ) + a13 (a21 a32 − a13 a22 a31 )
     
a22 a23 a21 a23 a21 a22
= a11 det − a12 det + a13 det
a32 a33 a31 a33 a31 a32
= a11 det A11 − a12 det A12 + a13 det A13 .

That’s a lot of algebra, but the important point is the last line: the
determinant of the 3 × 3 matrix A can be expressed in terms of the
2 × 2 submatrices A11 , A12 and A13 .

The things we observe in this formula motivate the following


general definition.
Recursive definition of determinants Cofactor expansions

Definition of determinant for arbitrary square matrices

For n ≥ 2, the determinant of an n × n matrix A = (aij ) is the


alternating sum

det A = a11 det A11 − a12 det A12 + · · · + (−1)1+n a1n det A1n
Xn
= (−1)1+j a1j det A1j .
j=1

(Notice that this definition of determinant of an n × n matrix depends on


the definition of determinant of an (n − 1) × (n − 1) matrix, which in
turn depends on the definition of determinant of a (n − 2) × (n − 2)
matrix, and so. . . . But, ultimately, we know what the determinant of a
2 × 2 matrix, so there is a precise (but long!) way to compute a
determinant of a n × n matrix implicit in this definition.)
Recursive definition of determinants Cofactor expansions

Example

Let’s compute the determinant of


 
3 2 0
A = 3 1 0 
1 1 1

from the definition:


     
1 0 3 0 3 1
det A = 3 det − 2 det + 0 det
1 1 1 1 1 1
= 3(1 · 1 − 1 · 0) − 2(3 · 1 − 1 · 0) + 0(3 · 1 − 1 · 1)
= 3(1) − 2(3) − 0
= −3
Recursive definition of determinants Cofactor expansions

iClicker 1

Compute the determinant of


 
0 −2 0
1 1 1
1 1 −1

using the definition.


(a) π
(b) 4
(c) 0
(d) -4
(e) -6
Recursive definition of determinants Cofactor expansions

Definition: cofactor

Given A = (aij ) the (i, j)-cofactor of A is the number

Cij = (−1)i+j det Aij .

Thus,
det A = a11 C11 + a12 C12 + · · · + a1n C1n .
We call this formula for det A the cofactor expansion of A across
the first row.
Recursive definition of determinants Cofactor expansions

A checkerboard of signs

It may be helpful to note that the signs of (−1)i+j used in the


definition of Cij = (−1)i+j det Aij form a checkerboard pattern for
varying i and j:
+ − + − ···
 
− + − + · · · 
 
+ − + − · · ·
 
− + − + · · · 
 
.. .. .. .. . .
. . . . .
Recursive definition of determinants Cofactor expansions

Cofactor expansion formulae

It turns out, there is a cofactor formula for the determinant given


by expansion along any row or column. More precisely:
Theorem
The determinant of a n × n matrix A can be computed by a
cofactor expansion across any row or down any column. The
expansion across the i th row is

det A = ai1 Ci1 + ai2 Ci2 + · · · + ain Cin

and the cofactor expansion down the j th column is

det A = a1j C1j + a2j C2j + · · · + anj Cnj .


Recursive definition of determinants Cofactor expansions

Example

Sometimes we can speed up the calculation of a determinant by


being clever about which column or row expand on. Consider:
 
4 2 0 1
3 1 0 3
B= 9 1 −1 3 

2 −5 0 −1

To be efficient, we want to expand down the column or row with


the most zeros. In this case, we should cofactor expand down the
third column of B:
det B = 0C13 + 0C23 + (−1)C33 + 0C44
= −C33 = −(−1)3+3 det B33 = − det B33 .

I’ll leave it as an exercise to compute det B33 .


Recursive definition of determinants Cofactor expansions

Upper triangular matrices


A triangular matrix is any square matrix that has only 0’s below its
diagonal, for example
   
  1 1 1 321 4231 −54
2 3 0 1 0   0 1 2 
0 4
0 0 32 0 0 0

Using the cofactor expansion formulae and being clever about


which columns or rows we expand down recursively, we can show
Theorem
If A is a triangular matrix, then det A is the product of the entries
on the main diagonal of A. That is,

det A = a11 a22 · · · ann .

Thus, in the examples above, the matrices have determinants


8, 32, and 0, respectively.

You might also like