The determinant of a square matrix
The determinant is a single number we extract from a square matrix, written det(A) or |A|. For a 2 × 2 matrix it is wonderfully simple: multiply the main diagonal, multiply the other diagonal, and subtract. That one number tells us whether the matrix can be inverted.
[ a b ]
A = [ c d ] det(A) = a*d - b*c
Example:
[ 4 3 ]
A = [ 2 5 ] det(A) = 4*5 - 3*2 = 20 - 6 = 14For a 3 × 3 matrix we expand along the first row: each top entry is multiplied by the 2 × 2 determinant of what remains when you delete its row and column, and the signs alternate +, −, +.
[ 1 2 3 ]
A = [ 0 4 5 ]
[ 1 0 6 ]
det = 1*det[4 5; 0 6] - 2*det[0 5; 1 6] + 3*det[0 4; 1 0]
= 1*(4*6 - 5*0) - 2*(0*6 - 5*1) + 3*(0*0 - 4*1)
= 1*(24) - 2*(-5) + 3*(-4)
= 24 + 10 - 12
= 22When the determinant is zero
If det(A) = 0, the matrix is called a singular matrix and it has no inverse — much like the number 0 has no reciprocal. A non-zero determinant means the matrix is invertible (also called non-singular). So the determinant is a one-number test: zero blocks the inverse, non-zero permits it.
Building the inverse
The inverse of A, written A^(-1), is the matrix that satisfies A · A^(-1) = A^(-1) · A = I, the identity. It is the matrix analogue of a reciprocal. For a 2 × 2 matrix there is a tidy formula: swap the diagonal entries, negate the off-diagonal entries, and divide everything by the determinant.
[ a b ] 1 [ d -b ]
A = [ c d ] A^(-1) = --------- [ -c a ]
(ad - bc)
Example: A = [ 4 3 ], det = 14
[ 2 5 ]
1 [ 5 -3 ] [ 5/14 -3/14 ]
A^(-1) = ---- [ -2 4 ] = [ -2/14 4/14 ]
14
Check: A * A^(-1) should give the 2x2 identity I.