Determinants and Inverses of Square Matrices
Determinants and Inverses of Square Matrices
Determinant of 2 2 matrix.
a11 a12
Let A then the determinant of A , denoted by det A or A and is given by
a 21 a 22
det A A a11a 22 a 21a12 .
Example 1
1 2
Let A , compute det A .
3 4
Solution:
1 2
det A 1 4 3 2 4 6 2
3 4
Example 2
If 0 , find .
3 2
Solution:
2 3 0
2 5 0
5 0
0 or 5
Example 3
4 2
Let A , compute det A .
3 2
Solution:
4 2
det A 4 2 3 2 8 6 2
3 2
Inverse of a 2 2 matrix
a11 a12 1
Let A , then the inverse of matrix A , denoted by A 1 and is given by A 1 Adj . A
a 21 a 22 A
a22 a12
where A a11a 22 a12 a 21 and AdjA .
21
a a11
1 a 22 a12
i.e., A 1 .
a11a 22 a12 a 21 a 21 a11
1 a11a 22 a12 a 21 0
a11a 22 a12 a 21 0 a11a 22 a12 a 21
1 0
0 1
Example 1
2 5
Let A , find A1 .
1 3
Solution
A 3 2 1 5 1
1 1 3 5 3 5
A 1 AdjA
A 1 1 2 1 2
Example 2
5 4
Let A , find A1 .
2 3
A 5 3 4 2 15 8 23
1 1 3 4 3 4
A 1 AdjA
A 23 2 5 2 5
Example 3
1 3
Let A , find A1 .
2 4
Solution
A 1 4 3 2 2
1 1 4 3 2 1.5
A 1 AdjA
A 2 1 1 0.5 0.5
Example 4
1 2
Let A , find A1 .
4 7
Solution
A 1 7 4 2 1
1 1 7 2 7 2
A 1 AdjA
A 1 4 1 4 1
a1 x b1 y c1
a 2 x b2 y c 2
a1 x b1 y c1 a1 b1 x c1
b2 y c2
or
a 2 x b2 y c2 a2
Or
AX B …………. 1
a1 b1 x c
Where A , X and B 1
a2 b2 y c2
Pre-multiplying 1 by A 1 .
x 2y 6
4x 3y 3
Solution:
Form a matrix equation
1 2 x 6
4 3 y 3
1 2 x 6
Therefore A , X and B
4 6 y 3
6 2
A 3 8 5 , Adj .A
4 1
1 6 2
A 1
5 4 1
X A1 B
x 1 3 2 6 12 5 2.4
y 5 4 1 3 215 4.2
x 2.4, y 4.2
Example 2
Solve the system using inverse matrix method
3x 6 y 5
7x 2 y 4
Solution:
Form a matrix equation
3 6 x 5
7 2 y 4
3 6 x 5
Therefore A , X and B
7 2 y 4
2 6
A 3 2 7 6 6 42 48 , Adj .A
7 3
1 1 2 6
A 1 Adj . A
A 48 7 3
X A1 B
x 1 2 6 5 1 2 5 6 4 1 10 24 1 34 34 48
y 48 7 3
4 48 7 5 3 4 48 35 12 48 23 23 48
34 17 23
x , y
48 24 48
Example 3
Solve the system using inverse matrix method
90 x 110 y 40
30 x 15 y 25
Solution:
Form a matrix equation
90 110 x 40
30 15 y 25
90 110 x 40
Therefore A , X and B
30 15 y 25
15 110
A 90 15 110 30 1350 3300 1950 , Adj .A
30 90
1 1 15 110
A 1 Adj . A
A 1950 30 90
X A1 B
x 1 15 110 40 1 15 40 110 25 1 600 2750 1 2150
y 1950 30 90 25 1950 30 40 90 25 1950 1200 2250 1950 1050
2150
1950 1.10256
1050 0.53846
1950
x 1.10256, y 0.53846
Exercise
1) Evaluate the given determinants
2 4
i. Ans. 10
3 1
3 5
ii. Ans. 29
7 2
0.75 1.32
iii. Ans. 0.687
0.15 1.18
2 a 1
iv. Ans. a2 a 2
a2 a
x y yx
v. Ans. 2 y 2 2x 2
2x 2y
2x y 7
ii. Ans. x 3, y 1
x y 2
4 x 3 y 4
iii. Ans. x 0.5, y 2
y 2x 3
r 3s 2 2
iv. Ans. r 4, s
2r 9 s 2 3
10i 27v 29 1
v. Ans. i 2, v
40i 33v 69 3
7x 2 y 6 6 36
vi. Ans. x , y
7 y 12 4 x 19 19
3R 8 5 I 7 39
vii. Ans. R , I 1
6 I 8R 11 58 58
Determinant of 3 3 matrix.
a 22 a 23 a a 23 a a 22
A a11 a12 21 a13 21
a32 a33 a31 a33 a31 a32
a11 a22 a33 a23 a32 a12 a21a33 a23 a31 a13 a21a32 a22 a31
Example 1
5 2 3
Compute 4 0 1
3 1 2
Solution:
5 2 3
0 1 4 1 4 0
4 0 1 5 2 3
1 2 3 2 3 1
3 1 2
5 10 12
27
Example 2
2 3 4
Compute 5 6 7
8 9 1
Solution:
2 3 4
6 7 5 7 5 6
5 6 7 2 3 4
9 1 8 1 8 9
8 9 1
26 63 35 56 445 48
114 153 12
27
NOTE: Determinant of a 3 3 matrix can also be obtained by using the following elementary scheme.
Then A a11a22 a33 a12 a23 a31 a13 a21a32 a13 a22 a31 a11a23 a32 a12 a21a33
Example 1
2 3 4
Find the determinant of 1 4 2 .
3 10 1
Solution:
2 3 4
Let A 1 4 2
3 10 1
8 18 40 48 40 3
35
Example 2
1 4 2
Find the determinant of 2 3 5 .
3 1 7
Solution:
1 4 2
Let A 2 3 5
3 1 7
1 4 2 1 4
2 3 5 2 3
3 1 7 3 1
6
Exercise
3 0 0
i. 2 1 4 Ans. 39
4 2 5
10 0 3
ii. 2 4 1 Ans. 116
3 0 2
3 0 0
iii. 0 10 0 Ans. 150
9 1 5
40 30 20
iv. 8 8 16 Ans. 54000
15 75 45
3 2 5
v. 2 1 4 Ans. 13
4 2 5
1 2 3
vi. 2 5 3 Ans. 6
4 7 9
1 1 2
i. 2 3x 1 2 .
2 1 x
x 1 2
ii. 0 1 3 5
2 2 1
1 2 1
iii. 2 3 x 3
1 2 2
Inverse of matrices
Adjoint of a square matrix
1) Find all the cofactors of every element of a given matrix , e.g. matrix A .
2) Form a matrix of co-factors.
3) Find the adjoint of matrix A by finding the transpose of the matrix of cofactors.
1
4) Find A 1 Adj . A
A
Example 1
1 0 3
1
Find A given that A 2 1 4 .
1 2 1
Solution:
The cofactors of A
1 4 2 4 2 1 0 3
A11 7 , A12 2 , A13 3 , A21 6,
2 1 1 1 1 2 2 1
1 3 1 0 0 3 1 3 1 0
A22 2 , A23 2 , A31 3 , A32 2 , A33 1
1 1 1 2 1 4 2 4 2 1
7 2 3
Matrix of cofactors 6 2 2
3 2 1
7 6 3
AdjA 2 2 2
3 2 1
1 4 2 4 2 1
A 3 0 3 31 8 02 4 34 1 2
2 1 1 1 1 2
7 6 3
1
A AdjA
1
1
2 2 2
A 2
3 2 1
Example 2
3 3 4
If A 2 3 4 , find A1 .
0 1 1
Solution:
3 3 4
A 2 3 4
0 1 1
3 4 2 4 2 3
A 3 3 4 3 3 4 32 0 4 2 0 1
1 1 0 1 0 1
Cofactors
3 4 2 4 2 3 3 4 3 4
A11 1 , A12 2 , A13 2 , A21 1 , A22 3,
1 1 0 1 0 1 1 1 0 1
3 3 3 4 3 4 3 3
A23 3 , A31 0 , A32 4 , A33 3
0 1 3 4 2 4 2 3
Matrix of cofactors
1 2 2 1 1 0
1 3 3 , AdjA 2 3 4
0 4 3 2 3 3
1 1 0 1 1 0
1
1 1
A AdjA 2 3 4 2 3 4
A 1
2 3 3 2 3 3
Example 3
8 1 4
1
If A 4 4 7 , prove that A1 AT .
9
1 8 4
Solution:
8 1 4 8 4 1
1 1
A 4 4 7 , A 1 4 8
T
9 9
1 8 4 4 7 4
8 1 4 8 4 1 81 0 0 1 0 0
1 1 1
AA 4 4 7 1 4 8 0 81 0 0 1 0
T
9 9 4 7 4 81 0 0 81 0 0 1
1 8 4
Hence AAT I
a1 x a 2 y a3 z d1
b1 x b2 y b3 z d 2
c1 x c 2 y c3 z d 3
a1 x a 2 y a3 z d1 a1 a2 a3 x d1
b1 x b2 y b3 z d 2 or b1 b2 b3 y d 2
c x c y c z d c c3 z d 3
1 2 3 3 1 c2
AX B …………. 1
a1 a2 a3 x d1
Where A b1 b2 b3 , X y and B d 2
c c3 z d
1 c2 3
Pre-multiplying 1 by A 1 .
x1 3 x 2 2 x3 3
2 x1 4 x 2 2 x3 8
x1 2 x 2 x3 10
Solution:
Form a matrix equation
1 3 2 x1 3
2 4 2 x 2 8
1 2 1 x 10
3
1 3 2 x1 3
Therefore A 2 4 2 , X x 2 and B 8
1 2 1 x 10
3
Cofactors of A
4 2 2 2 2 4 3 2
A11 8 , A12 4, A13 0 , A21 7,
2 1 1 1 1 2 2 1
1 2 1 3 3 2 1 2
A22 3 , A23 , A31 2 , A32 2 ,
1 1 1 2 4 2 2 2
1 3
A33 2
2 4
8 4 0
7 3 1
2 2 2
8 7 2
AdjA 4 3 2
0 1 2
4 2 2 2 2 4
A 1 3 2 1 4 4 3 2 2 24 4 4
2 1 1 1 1 2
8 7 2
11 1
A AdjA 4 3 2
A 4
0 1 2
x1 8 7 2 3 3
1 1
Therefore X x 2 A B 4 3 2 8 2
x 4
3 0 1 2 10 3
x1 3 , x 2 2 , x3 3
Example 2
Solve, with help of matrices, the simultaneous equations.
x y z 3 , x 2 y 3z 4 , x 4 y 9 z 6
Solution:
The given equations in the matrix form are written as below
1 1 1 x 3
1 2 3 y 4
1 4 9 z 6
AX B
1 1 1 x 3
where A 1 2 3 , X y and B 4
1 4 9 z 6
X A1 B
Cofactors of A
2 3 1 3 1 2 1 1
A11 6, A12 6 , A13 2, A21 5 ,
4 9 1 9 1 4 4 9
1 1 1 1 1 1 1 1
A22 8, A23 3 , A31 1, A32 2 ,
1 9 1 4 2 3 1 3
1 1
A33 1
1 2
6 6 2 6 5 1
Matrix of cofactors 5 8 3 , AdjA 6 8 2 ,
1 2 1 2 3 1
2 3 1 3 1 2
A 1 1 1 118 12 19 3 14 2 2
4 9 1 9 1 4
6 5 1
11 1
A AdjA 6 8 2
A 2
2 3 1
6 5 1 3 4 2
1
1
1
X A B 6 8 2 4 2 1
2 2 0 0
2 3 1 6
x 2, y 1, z 0
Example 3
Given the matrices
1 2 3 x 1
A 3 1 1 , X y and C 2
4 2 1 z 3
Write down the linear equations given by AX C and solve for x, y, z by the matrix method.
Solution:
AX C
1 2 3 x 1
3 1 1 y 2
4 2 1 z 3
X A 1C
Cofactors of A
1 1 3 1 3 1 2 3
A11 3 , A12 1 , A13 10 , A21 4,
2 1 4 1 4 2 2 1
1 3 1 2 2 3 1 3
A22 11 , A23 6 , A31 5 , A32 8,
4 1 4 2 1 1 3 1
1 2
A33 7
3 1
3 1 10 3 4 5
Matrix of cofactors of A 4 11 6 , AdjA 1 11 8
5 8 7 10 6 7
1 1 3 1 3 1
A 1 2 3 1 1 2 23 4 36 4 29
2 1 4 1 4 2
3 4 5
1 1
A 1 AdjA 1 11 8
A 29
10 6 7
X A 1C
x 3 4 5 1
1
y 1 11 8 2
z 29 10 6 7 3
20
20
x
1 29
y 3 3 29
z 29 1 1
29
20 3 1
x , y , z
29 29 29
Exercise
Solve the following equations by matrix inversion.
i. 3x y 2 z 3, 2x - 3y - z -3, x 2y z 4 Ans. x 1, y 2, z 1
9 1
ii. x 2 y 3z 1, 2x 3y 8z 2, x y z 3 Ans. x
, y 1, z
2 2
iii. 4 x 2 y z 9, x y 3z -4, 2x z 1 Ans. x 1, y 2, z 1
iv. 5 x 3 y 3z 48, 2x 6 y 3z 18, 8x - 3y 2z 21 Ans. x 3, y 5, z 6
v. x y z 1, x y 2z 18, 3x y z 8 Ans. x 1, y 2, z 3
7 3 1
vi. x 2 y 3z 1, 3x 2 y z 2, 4x 2 y z 3 Ans. x , y , z
10 40 20
vii. 9 x 4 y 3z 1, 5x y 2z 1, 7x 3y 4z 1 Ans. x 0, y 1, z 1
5 4
viii. x y z 8, x y 2z 6, 9x 5y 7z 44 Ans. x 5, y , z
3 3
9 9 5
ix. 3x 2 y 4 z 7, 2x y z 4, x 3y 5z 2 Ans. x , y , z
4 8 8
Crammer’s rule
Consider a system of n linear equations and n unknowns.
1
x1 , x2 2 , x3 3 , ….., xn n
Example 1
Use Crammer’s rule to solve
3x 6 y 5
7x 2 y 4
Solution:
5 6
4 2 10 24 34 17
x
3 6 6 42 48 24
7 2
3 5
7 4 12 35 23
y
3 6 6 42 48
7 2
17 23
x , y
24 48
Example 2
Use Crammer’s rule to solve
90 x 110 y 40
30 x 15 y 25
Solution:
40 110
25 15 600 2750 2150 4
x 1
90 110 1350 3300 1950 39
30 15
90 40
25 25 2250 1000 1250 25
y
90 110 1350 3300 1950 39
30 15
4 25
x 1 , y
39 39
Example 3
Use Crammer’s rule to solve
2x 3y z 1
3x 5 y 2 z 8
x 2 y 3z 1
Solution:
1 3 1
8 5 25 2 8 2 8 5
3 1 1
1 2 3
2 3 1 3 1 2 1 11 3 22 1 11 66
x 3
2 3 1 5 2 3 2 3 5 2 11 3 11 1 11 22
2 3 1
3 5 2 2 3 1 3 1 2
1 2 3
2 1 1
3 8 2 8 2 3 2 3 8
12 1
1 1 3 1 3 1 3 1 1 2 22 1 11 1 11 22
y 1
2 3 1 5 2 3 2 3 5 2 11 3 11 1 11 22
2 3 1
3 5 2 2 3 1 3 1 2
1 2 3
2 3 1
3 5 8 5 8 3 8 3 5
32 1
1 2 1 2 1 1 3 1 2 211 3 11 1 11 44
z 2
2 3 1 5 2 3 2 3 5 2 11 3 11 1 11 22
2 3 1
3 5 2 2 3 1 3 1 2
1 2 3
x 3, y 1, z 2
Example 4
Use Crammer’s rule to solve
2x y z 4
x 2y z 3
3x 3 y 2 z 1
Solution:
4 1 1
3 2 1 2 1 3 1 3 2
1 4 1
1 3 2 3 2 1 2 1 3 4 1 1 5 111 12
x 2
2 1 1 2 1 1 1 1 2 2 1 11 19 6
2 1 1
1 2 1 3 2 3 2 3 3
3 3 2
2 4 1
1 3 1 3 1 1 1 1 3
4 2 1
3 1 2 1 2 3 2 3 1 2 5 41 1 8 22 11
y
2 1 1 2 1 1 1 1 2 2 1 11 19 6 3
2 1 1
1 2 1 3 2 3 2 3 3
3 3 2
2 1 4
1 2 3 2 3 1 3 1 2
1 2 4
3 3 1 3 1 3 1 3 3 2 11 1 8 49 22 11
z
2 1 1 2 1 1 1 1 2 2 1 11 19 6 3
2 1 1
1 2 1 3 2 3 2 3 3
3 3 2
11 11
x 2, y , z
3 3
Exercise
1) Solve the following equations by determinants:
x 2y z 2
i. 3x 6 y 2 z 2
2x z 8
1
Ans. x 3, y , z 2
2
2r s 2t 8
ii. 3r 2s 4t 5
2r 3s 4t 3
4u 4v 2w 4
iii. 20u 15v 10w 10
24u 12v 9w 39
1
Ans. u , v 2, w 3
2
2) A slaughter house bought goats and bulls at Ksh. 1, 200 and Ksh.15,000 each. They paid a total
bill of Ksh. 135,000 . If they double the number of goats and three bulls less, they would have
i. By using matrix method, determine the number of goats and bulls that were bought.
ii. The slaughter house sold the animals at a profit of 25% per goat and 30% per bull.
Determine the amount of profit made.
3) The cost of 5 resistors, 4 capacitors and 1 diode is Ksh. 340 ; the cost of 10 resistors, 9
capacitors and 4 diodes is Ksh. 880 ; while the cost of 10 resistors, 13 capacitors and 15
ii. Determine the cost of each component using the inverse matrix method.
4) In a production process it takes 23 hours to produce 1 copper , 2 iron and 3 steel rods ; it takes
44 hours to produce 2 copper, 4 iron and 5 steel rods; while it takes 58 hours to produce 3
ii. Use Crammer’s rule to determine how long it would take to produce each type of rod.