Processing math: 88%
Skip to main content
Library homepage
 

Text Color

Text Size

 

Margin Size

 

Font Type

Enable Dyslexic Font
Mathematics LibreTexts

3.4: Applications of the Determinant

( \newcommand{\kernel}{\mathrm{null}\,}\)

Outcomes
  1. Use determinants to determine whether a matrix has an inverse, and evaluate the inverse using cofactors.
  2. Apply Cramer’s Rule to solve a 2×2 or a 3×3 linear system.
  3. Given data points, find an appropriate interpolating polynomial and use it to estimate points.

A Formula for the Inverse

The determinant of a matrix also provides a way to find the inverse of a matrix. Recall the definition of the inverse of a matrix in Definition 2.6.1. We say that A1, an n×n matrix, is the inverse of A, also n×n, if AA1=I and A1A=I.

We now define a new matrix called the cofactor matrix of A. The cofactor matrix of A is the matrix whose ijth entry is the ijth cofactor of A. The formal definition is as follows.

Definition 3.4.1: The Cofactor Matrix

Let A=[aij] be an n×n matrix. Then the cofactor matrix of A, denoted cof(A), is defined by cof(A)=[cof(A)ij] where cof(A)ij is the ijth cofactor of A.

Note that cof(A)ij denotes the ijth entry of the cofactor matrix.

We will use the cofactor matrix to create a formula for the inverse of A. First, we define the adjugate of A to be the transpose of the cofactor matrix. We can also call this matrix the classical adjoint of A, and we denote it by adj(A).

In the specific case where A is a 2×2 matrix given by A=[abcd] then adj(A) is given by adj(A)=[dbca]

In general, adj(A) can always be found by taking the transpose of the cofactor matrix of A. The following theorem provides a formula for A1 using the determinant and adjugate of A.

Theorem 3.4.1: The Inverse and the Determinant

Let A be an n×n matrix. Then Aadj(A)=adj(A)A=det(A)I

Moreover A is invertible if and only if det(A)0. In this case we have: A1=1det(A)adj(A)

Notice that the first formula holds for any n×n matrix A, and in the case A is invertible we actually have a formula for A1.

Consider the following example.

Example 3.4.1: Find Inverse Using the Determinant

Find the inverse of the matrix A=[123301121] using the formula in Theorem 3.4.1.

Solution

According to Theorem 3.4.1, A1=1det(A)adj(A)

First we will find the determinant of this matrix. Using Theorems 3.2.1, 3.2.2, and 3.2.4, we can first simplify the matrix through row operations. First, add 3 times the first row to the second row. Then add 1 times the first row to the third row to obtain B=[123068002] By Theorem 3.2.4, det(A)=det(B). By Theorem 3.1.2, det(B)=1×6×2=12. Hence, det(A)=12.

Now, we need to find adj(A). To do so, first we will find the cofactor matrix of A. This is given by cof(A)=[226420286] Here, the ijth entry is the ijth cofactor of the original matrix A which you can verify. Therefore, from Theorem 3.4.1, the inverse of A is given by A1=112[226420286]T=[16131616162312012]

Remember that we can always verify our answer for A1. Compute the product AA1 and A1A and make sure each product is equal to I.

Compute A1A as follows A1A=[16131616162312012][123301121]=[100010001]=I You can verify that AA1=I and hence our answer is correct.

We will look at another example of how to use this formula to find A1.

Example 3.4.2: Find the Inverse From a Formula

Find the inverse of the matrix A=[12012161312562312] using the formula given in Theorem 3.4.1.

Solution

First we need to find det(A). This step is left as an exercise and you should verify that det(A)=16. The inverse is therefore equal to A1=1(1/6)adj(A)=6adj(A)

We continue to calculate as follows. Here we show the 2×2 determinants needed to find the cofactors. A1=6[|13122312||16125612||16135623||0122312||12125612||1205623||0121312||12121612||1201613|]T

Expanding all the 2×2 determinants, this yields A1=6[161316131613161616]T=[121211121]

Again, you can always check your work by multiplying A1A and AA1 and ensuring these products equal I. A1A=[121211121][12012161312562312]=[100010001] This tells us that our calculation for A1 is correct. It is left to the reader to verify that AA1=I.

The verification step is very important, as it is a simple way to check your work! If you multiply A1A and AA1 and these products are not both equal to I, be sure to go back and double check each step. One common error is to forget to take the transpose of the cofactor matrix, so be sure to complete this step.

We will now prove Theorem 3.4.1.

Theorem 3.4.1: The Inverse and the Determinant
Proof

(of Theorem 3.4.1) Recall that the (i,j)-entry of adj(A) is equal to cof(A)ji. Thus the (i,j)-entry of B=Aadj(A) is : Bij=nk=1aikadj(A)kj=nk=1aikcof(A)jk By the cofactor expansion theorem, we see that this expression for Bij is equal to the determinant of the matrix obtained from A by replacing its jth row by ai1,ai2,ain — i.e., its ith row.

If i=j then this matrix is A itself and therefore Bii=detA. If on the other hand ij, then this matrix has its ith row equal to its jth row, and therefore Bij=0 in his case. Thus we obtain: Aadj(A)=det(A)I Similarly we can verify that: adj(A)A=det(A)I And this proves the first part of the theorem.

Further if A is invertible, then by Theorem 3.2.5 we have: 1=det(I)=det(AA1)=det(A)det(A1) and thus det(A)0. Equivalently, if det(A)=0, then A is not invertible.

Finally if det(A)0, then the above formula shows that A is invertible and that: A1=1det(A)adj(A)

This completes the proof.

This method for finding the inverse of A is useful in many contexts. In particular, it is useful with complicated matrices where the entries are functions, rather than numbers.

Consider the following example.

Example 3.4.3: Inverse for Non-Constant Matrix

Suppose A(t)=[et000costsint0sintcost] Show that A(t)1 exists and then find it.

Solution

First note det(A(t))=et(cos2t+sin2t)=et0 so A(t)1 exists.

The cofactor matrix is C(t)=[1000etcostetsint0etsintetcost] and so the inverse is 1et[1000etcostetsint0etsintetcost]T=[et000costsint0sintcost]

Cramer’s Rule

Another context in which the formula given in Theorem 3.4.1 is important is Cramer’s Rule. Recall that we can represent a system of linear equations in the form AX=B, where the solutions to this system are given by X. Cramer’s Rule gives a formula for the solutions X in the special case that A is a square invertible matrix. Note this rule does not apply if you have a system of equations in which there is a different number of equations than variables (in other words, when A is not square), or when A is not invertible.

Suppose we have a system of equations given by AX=B, and we want to find solutions X which satisfy this system. Then recall that if A1 exists, AX=BA1(AX)=A1B(A1A)X=A1BIX=A1BX=A1B Hence, the solutions X to the system are given by X=A1B. Since we assume that A1 exists, we can use the formula for A1 given above. Substituting this formula into the equation for X, we have X=A1B=1det(A)adj(A)B Let xi be the ith entry of X and bj be the jth entry of B. Then this equation becomes xi=nj=1[aij]1bj=nj=11det(A)adj(A)ijbj where adj(A)ij is the ijth entry of adj(A).

By the formula for the expansion of a determinant along a column, xi=1det(A)det[b1bn] where here the ith column of A is replaced with the column vector [b1,bn]T. The determinant of this modified matrix is taken and divided by det(A). This formula is known as Cramer’s rule.

We formally define this method now.

Procedure 3.4.1: Using Cramer’s Rule

Suppose A is an n×n invertible matrix and we wish to solve the system AX=B for X=[x1,,xn]T. Then Cramer’s rule says xi=det(Ai)det(A) where Ai is the matrix obtained by replacing the ith column of A with the column matrix B=[b1bn]

We illustrate this procedure in the following example.

Example 3.4.4: Using Cramer's Rule

Find x,y,z if [121321232][xyz]=[123]

Solution

We will use method outlined in Procedure 3.4.1 to find the values for x,y,z which give the solution to this system. Let B=[123]

In order to find x, we calculate x=det(A1)det(A) where A1 is the matrix obtained from replacing the first column of A with B.

Hence, A1 is given by A1=[121221332]

Therefore, x=det(A1)det(A)=|121221332||121321232|=12

Similarly, to find y we construct A2 by replacing the second column of A with B. Hence, A2 is given by A2=[111321232]

Therefore, y=det(A2)det(A)=|111321232||121321232|=17

Similarly, A3 is constructed by replacing the third column of A with B. Then, A3 is given by A3=[121322233]

Therefore, z is calculated as follows.

z=det(A3)det(A)=|121322233||121321232|=1114

Cramer’s Rule gives you another tool to consider when solving a system of linear equations.

We can also use Cramer’s Rule for systems of non linear equations. Consider the following system where the matrix A has functions rather than numbers for entries.

Using Cramer’s Rule

Example 3.4.5: Use Cramer's Rule for Non-Constant Matrix

Solve for z if [1000etcostetsint0etsintetcost][xyz]=[1t0.05int2]

Solution

We are asked to find the value of z in the solution. We will solve using Cramer’s rule. Thus z=.05in|1010etcostt0etsintt2||1000etcostetsint0etsintetcost|=t((cost)t+sint)et

Polynomial Interpolation

In studying a set of data that relates variables x and y, it may be the case that we can use a polynomial to “fit” to the data. If such a polynomial can be established, it can be used to estimate values of x and y which have not been provided.

Consider the following example.

Example 3.4.6: Polynomial Interpolation

Given data points (1,4),(2,9),(3,12), find an interpolating polynomial p(x) of degree at most 2 and then estimate the value corresponding to x=12.

Solution

We want to find a polynomial given by p(x)=r0+r1x1+r2x22 such that p(1)=4,p(2)=9 and p(3)=12. To find this polynomial, substitute the known values in for x and solve for r0,r1, and r2. p(1)=r0+r1+r2=4p(2)=r0+2r1+4r2=9p(3)=r0+3r1+9r2=12

Writing the augmented matrix, we have [1114124913912]

After row operations, the resulting matrix is [100301080011]

Therefore the solution to the system is r0=3,r1=8,r2=1 and the required interpolating polynomial is p(x)=3+8xx2

To estimate the value for x = \frac{1}{2}, we calculate p(\frac{1}{2}): \begin{aligned} p(\frac{1}{2}) &= -3 + 8(\frac{1}{2}) - (\frac{1}{2})^2\\ &= -3 + 4 - \frac{1}{4} \\ &= \frac{3}{4}\end{aligned}

This procedure can be used for any number of data points, and any degree of polynomial. The steps are outlined below.

Procedure \PageIndex{2}: Finding an Interpolation Polynomial

Suppose that values of x and corresponding values of y are given, such that the actual relationship between x and y is unknown. Then, values of y can be estimated using an interpolating polynomial p(x). If given x_1, ..., x_n and the corresponding y_1, ..., y_n, the procedure to find p(x) is as follows:

  1. The desired polynomial p(x) is given by p(x) = r_0 + r_1 x + r_2 x^2 + ... + r_{n-1}x^{n-1}\nonumber
  2. p(x_i) = y_i for all i = 1, 2, ...,n so that \begin{array}{c} r_0 + r_1x_1 + r_2 x_1^2 + ... + r_{n-1}x_1^{n-1} = y_1 \\ r_0 + r_1x_2 + r_2 x_2^2 + ... + r_{n-1}x_2^{n-1} = y_2 \\ \vdots \\ r_0 + r_1x_n + r_2 x_n^2 + ... + r_{n-1}x_n^{n-1} = y_n \end{array}\nonumber
  3. Set up the augmented matrix of this system of equations \left[ \begin{array}{rrrrr|r} 1 & x_1 & x_1^2 & \cdots & x_1^{n-1} & y_1 \\ 1 & x_2 & x_2^2 & \cdots & x_2^{n-1} & y_2 \\ \vdots & \vdots & \vdots & &\vdots & \vdots \\ 1 & x_n & x_n^2 & \cdots & x_n^{n-1} & y_n \\ \end{array} \right]\nonumber
  4. Solving this system will result in a unique solution r_0, r_1, \cdots, r_{n-1}. Use these values to construct p(x), and estimate the value of p(a) for any x=a.

This procedure motivates the following theorem.

Theorem \PageIndex{2}: Polynomial Interpolation

Given n data points (x_1, y_1), (x_2, y_2), \cdots, (x_n, y_n) with the x_i distinct, there is a unique polynomial p(x) = r_0 + r_1x + r_2x^2 + \cdots + r_{n-1}x^{n-1} such that p(x_i) = y_i for i=1,2,\cdots, n. The resulting polynomial p(x) is called the interpolating polynomial for the data points.

We conclude this section with another example.

Example \PageIndex{7}: Polynomial Interpolation

Consider the data points (0,1), (1,2), (3,22), (5,66). Find an interpolating polynomial p(x) of degree at most three, and estimate the value of p(2).

Solution

The desired polynomial p(x) is given by: p(x) = r_0 + r_1 x + r_2x^2 + r_3x^3\nonumber

Using the given points, the system of equations is \begin{aligned} p(0) &= r_0 = 1 \\ p(1) &= r_0 + r_1 + r_2 + r_3 = 2 \\ p(3) &= r_0 + 3r_1 + 9r_2 + 27r_3 = 22 \\ p(5) &= r_0 + 5r_1 + 25r_2 + 125r_3 = 66\end{aligned}

The augmented matrix is given by: \left[ \begin{array}{rrrr|r} 1 & 0 & 0 & 0 & 1 \\ 1 & 1 & 1 & 1 & 2 \\ 1 & 3 & 9 & 27 & 22 \\ 1 & 5 & 25 & 125 & 66 \end{array} \right]\nonumber

The resulting matrix is \left[ \begin{array}{rrrr|r} 1 & 0 & 0 & 0 & 1 \\ 0 & 1 & 0 & 0 & -2 \\ 0 & 0 & 1 & 0 & 3 \\ 0 & 0 & 0 & 1 & 0 \end{array} \right]\nonumber

Therefore, r_0 = 1, r_1 = -2, r_2 = 3, r_3 = 0 and p(x) = 1 -2x + 3x^2. To estimate the value of p(2), we compute p(2) = 1 -2(2) + 3(2^2) = 1 - 4 + 12 = 9.


This page titled 3.4: Applications of the Determinant is shared under a CC BY 4.0 license and was authored, remixed, and/or curated by Ken Kuttler (Lyryx) via source content that was edited to the style and standards of the LibreTexts platform.

Support Center

How can we help?