PRETTY_MAT_ID = printSimpleMatrix(MAT)
What is PRETTY_MAT_ID^{-1}
?
The inverse of a matrix is equal to the adjugate of the matrix divided by the determinant of the matrix.
PRETTY_MAT_ID^{-1} = \frac{1}{det(PRETTY_MAT_ID)}adj(PRETTY_MAT_ID)
Step 1: Find the adjugate
First, compute the matrix of minors of PRETTY_MAT_ID
.
MAT_MINORS_FORMAT
= printSimpleMatrix(MAT_MINORS_DET)
Next, multiply the elements of the matrix of minors by the following pattern:
printSimpleMatrix([["+","-","+"],["-","+","-"],["+","-","+"]])
This gives us what is called the matrix of cofactors:
printSimpleMatrix(MAT_MINORS_DET_SIGNS)
Next, transpose the matrix of cofactors to get the adjugate.
adj(PRETTY_MAT_ID) =
printSimpleMatrix(MAT_MINORS_DET_SIGNS)^T =
printSimpleMatrix(MAT_ADJ, KhanUtil.BLUE)
Step 2: Find the determinant
Compute the determinant of the original matrix. [Show me how]
The determinant of any 3x3 matrix can be computed the following way:
printSimpleMatrixDet(HINT_MAT)
= matrix3x3DetHint(HINT_MAT, true)
= matrix3x3DetHint(HINT_MAT)
In this specific case,
printSimpleMatrixDet(MAT)
= matrix3x3DetHint(MAT, true)
= matrix3x3DetHint(MAT)
= DET
det(PRETTY_MAT_ID) =
printSimpleMatrixDet(MAT)=
expr(["color", KhanUtil.RED, DET])
Step 3: Put it all together
Now that we have both the determinant and the adjugate, we can compute the inverse.
PRETTY_MAT_ID^{-1} =
\frac{1}{expr(["color", KhanUtil.RED, DET])}
printSimpleMatrix(MAT_ADJ, KhanUtil.BLUE)
= PRETTY_SOLN_MAT