The cofactor formula is used widely in mathematics to find the inverse of matrix problems. In a matrix, there are different rows and columns in a rectangular or square numerical grid. Therefore cofactor is that number which is obtained after removing all the numbers of columns and rows from the matrix.
The Formula for Calculating Cofactor
To calculate the cofactor we need a matrix which is usually in the form of m*n. Let’s suppose that the matrix has n rows and n columns. If we delete the ith row and jth column of the matrix, we get a new matrix Mij which has (n-1) rows and columns. In this case, the cofactor will be denoted by Aij
The formula for calculating cofactor is Aij. = (-1)i+j det Mij.
Aij represents the cofactor. Det Mij represents the determinant of the matrix which is obtained by multiplying the diagonals, that is AD minus BC. Remember that the cofactor can be anything positive, negative, or even zero.
Example no. 1: If the given matrix is 2, 5, 1 in the first row, 0, 3, 4 in the 2nd row and 1, -2, and -5 in the third row, find the cofactor of the given matrix.
Solution: Here the number of rows and no. of columns is 3. So we will reduce 1 row and 1 column and therefore we’ll have i and j as 2 and 2.
So, mij= 2, -1 in the first row and 0 &4 in the second row.
Now we’ll find the determinant of this 2*2 matrix which is the product of the diagonals.
Hence det Mij= 2*4 = 8.
Putting in the formula, Aij. = (-1)i+j det Mij.
Aij= (-1) (8)= -8
Solved example no. 2: If a matrix consists of 1, 0 -, 2 in the first row, 3 -, 1, 2 in the second row and four, five and six in the last row. What will be the cofactor of zero in this matrix?
Ans: To find out the cofactor, we first need to find the minor of the given number that is zero. In this case, a minor can be obtained by multiplying the numbers in the row and column excluding 0.
So the row consists of 3 2
Therefore, ad- bc = 3*6 – 2*4 = 18-8= 10.
To obtain a cofactor, we need to see the row and the column in which zero is located. In this case, 0 is in the first row and the column is the second column.
Therefore i= 1 and j= 2.
Putting in the formula, Aij. = (-1)i+j det Mij.,
Cofactor of zero will be -1*10 which is equal to -10.