Cofactor expansion

Here we explain how to compute the determinant of a matrix using cofactor expansion. First you will find what minors and cofactors are (necessary to apply the cofactor expansion method), then what the cofactor expansion is about, and finally an example of the calculation of a 3×3 determinant by cofactor expansion.

Minor and Cofactor

Before seeing how to find the determinant of a matrix by cofactor expansion, we must first define what a minor and a cofactor are. Since these two mathematical operations are necessary to use the cofactor expansion method.

The i, j minor of the matrix, denoted by Mi,j, is the determinant that results from deleting the i-th row and the j-th column of the matrix.

For example, let A be the following 3×3 square matrix:

 \displaystyle A = \left( \begin{array}{ccc} 6 & 1 & 7 \\[1.1ex] 3 & 2 & 0 \\[1.1ex] 5 & 8 & 4 \end{array} \right)

The minor of 1 is the determinant of the matrix that we obtain by eliminating the row and the column where the 1 is. That is, removing the first row and the second column:

    \left( \begin{tabular}{ccc} \cellcolor[HTML]{F5B7B1}6 & \cellcolor[HTML]{F5B7B1}1 & \cellcolor[HTML]{F5B7B1}7 \\ & \cellcolor[HTML]{F5B7B1} & \\[-2ex] 3 & \cellcolor[HTML]{F5B7B1}2 & 0 \\ & \cellcolor[HTML]{F5B7B1} & \\[-2ex] 5 &  \cellcolor[HTML]{F5B7B1}8 & 4                    \end{tabular} \right)

\displaystyle M_{1,2}=  \begin{vmatrix} 3 & 0 \\[1.1ex] 5 & 4 \end{vmatrix} =12-0=12

On the other hand, the formula to find a cofactor of a matrix is as follows:

The i, j cofactor of the matrix is defined by:

C_{i,j}=(-1)^{i+j}\cdot M_{ij}

Where Mij is the i, j minor of the matrix.

Continuing with the previous example, the cofactor of 1 would be:

 \displaystyle A = \left( \begin{array}{ccc} 6 & 1 & 7 \\[1.1ex] 3 & 2 & 0 \\[1.1ex] 5 & 8 & 4 \end{array} \right)

\begin{aligned}C_{1,2}&=(-1)^{1+2}\cdot M_{1,2} \\[2ex]& =(-1)^3\cdot\begin{vmatrix} 3 & 0 \\[1.1ex] 5 & 4 \end{vmatrix}\\[2ex]&=-1\cdot12\\[2ex]&=-12\end{aligned}

Therefore, the sign of a cofactor depends on the location of the element of the matrix.

See also: how to find the cofactor matrix

How to compute the determinant of a matrix by cofactor expansion

The cofactor expansion theorem, also called Laplace expansion, states that any determinant can be computed by adding the products of the elements of a column or row by their respective cofactors.

Thus, let A be a K×K dimension matrix, the cofactor expansion along the i-th row is defined with the following formula:

\displaystyle det(A)=\sum_{j=1}^K A_{ij}C_{ij}

Similarly, the mathematical formula for the cofactor expansion along the j-th column is as follows:

\displaystyle det(A)=\sum_{i=1}^K A_{ij}C_{ij}

Where Aij is the entry in the i-th row and j-th column, and Cij is the i,j cofactor.

Example of cofactor expansion

Let’s see and example of how to solve the determinant of a 3×3 matrix using cofactor expansion:

\begin{vmatrix} 2 & 3 & 1 \\[1.1ex] 0 & -2 & 5 \\[1.1ex] 3 & 7 & -4 \end{vmatrix}

First of all, we must choose a column or a row of the determinant. In this case, we choose to apply the cofactor expansion method to the first column, since it has a zero and therefore it will be easier to compute. So we have to multiply the elements of the first column by their respective cofactors:

\displaystyle \begin{vmatrix} 2 & 3 & 1 \\[1.1ex] 0 & -2 & 5 \\[1.1ex] 3 & 7 & -4 \end{vmatrix}= 2\cdot C_{11} +0\cdot C_{21} + 3 \cdot C_{31}

The cofactor of 0 does not need to be calculated, because any number multiplied by 0 equals to 0:

\displaystyle \begin{vmatrix} 2 & 3 & 1 \\[1.1ex] 0 & -2 & 5 \\[1.1ex] 3 & 7 & -4 \end{vmatrix}= 2\cdot C_{11} +\cancel{0\cdot C_{21}} + 3 \cdot C_{31}

\displaystyle \begin{vmatrix} 2 & 3 & 1 \\[1.1ex] 0 & -2 & 5 \\[1.1ex] 3 & 7 & -4 \end{vmatrix}= 2\cdot C_{11}+3\cdot C_{31}

Now we calculate the cofactors:

\displaystyle \begin{vmatrix} 2 & 3 & 1 \\[1.1ex] 0 & -2 & 5 \\[1.1ex] 3 & 7 & -4 \end{vmatrix}= 2\cdot (-1)^{1+1} \cdot \begin{vmatrix} -2 & 5 \\[1.1ex] 7 & -4 \end{vmatrix} + 3 \cdot (-1)^{3+1} \cdot \begin{vmatrix} 3 & 1 \\[1.1ex] -2 & 5 \end{vmatrix}

And, finally, we compute the 2×2 determinants and all the calculations:

\begin{aligned} \begin{vmatrix} 2 & 3 & 1 \\[1.1ex] 0 & -2 & 5 \\[1.1ex] 3 & 7 & -4 \end{vmatrix} &= 2 \cdot 1 \cdot (8-35) + 3 \cdot 1 \cdot \bigl(15-(-2)\bigr) \\ & = 2 \cdot 1 \cdot (-27) + 3 \cdot 1 \cdot 17 \\[2ex] &= -54 + 51\\[2ex]&=-3\end{aligned}

However, this is not the only method to compute 3×3 determinants. See how to find the determinant of 3×3 matrix using the shortcut method.

Moreover, the cofactor expansion method is not only to evaluate determinants of 3×3 matrices, but also to solve determinants of 4×4 matrices. See how to find the determinant of a 4×4 matrix using cofactor expansion.

2 thoughts on “Cofactor expansion”

Leave a Comment

Your email address will not be published.

Scroll to Top