As an example, let's invert the matrix
We construct the augmented matrix,
On this augmented matrix, we perform row operations in such a way as to transform the matrix on the left side into the identity matrix, and the matrix on the right will be the inverse that we want to find.
Now we can carry out Gaussian elimination.
• Eliminate the column 1 entry in row 2.
Combine 2 times row 1 with 3 times row 2 :
2 (-3, 2, 1, 1, 0, 0) + 3 (2, 1, 1, 0, 1, 0)
= (-6, 4, 2, 2, 0, 0) + (6, 3, 3, 0, 3, 0)
= (0, 7, 5, 2, 3, 0)
which changes the augmented matrix to
• Eliminate the column 1 entry in row 3.
Using the new aug. matrix, combine row 1 and 3 times row 3 :
(-3, 2, 1, 1, 0, 0) + 3 (1, 1, 1, 0, 0, 1)
= (-3, 2, 1, 1, 0, 0) + (3, 3, 3, 0, 0, 3)
= (0, 5, 4, 1, 0, 3)
• Eliminate the column 2 entry in row 3.
Combine -5 times row 2 and 7 times row 3 :
-5 (0, 7, 5, 2, 3, 0) + 7 (0, 5, 4, 1, 0, 3)
= (0, -35, -25, -10, -15, 0) + (0, 35, 28, 7, 0, 21)
= (0, 0, 3, -3, -15, 21)
• Multiply row 3 by 1/3 :
• Eliminate the column 3 entry in row 2.
Combine row 2 and -5 times row 3 :
(0, 7, 5, 2, 3, 0) - 5 (0, 0, 1, -1, -5, 7)
= (0, 7, 5, 2, 3, 0) + (0, 0, -5, 5, 25, -35)
= (0, 7, 0, 7, 28, -35)
• Multiply row 2 by 1/7 :
• Eliminate the column 2 and 3 entries in row 1.
Combine row 1, -2 times row 2, and -1 times row 3 :
(-3, 2, 1, 1, 0, 0) - 2 (0, 1, 0, 1, 4, -5) - (0, 0, 1, -1, -5, 7)
= (-3, 2, 1, 1, 0, 0) + (0, -2, 0, -2, -8, 10) + (0, 0, -1, 1, 5, -7)
= (-3, 0, 0, 0, -3, 3)
• Multiply row 1 by -1/3 :
So, the inverse of our matrix is