4 Matrices
Definition 4.1. Matrix: A matrix (whose plural is matrices) is a rectangular array of numbers,
symbols, or expressions, arranged in rows and columns.
• A matrix with m rows and n columns is called an m × n matrix or m-by-n matrix, where m
and n are called the matrix dimensions.
• The individual items/values in a matrix are called elements of the matrix.
• Consider the following example regarding the number of male and female workers in two
shops I and II.
Male Workers Female Workers
1 10 18
2 25 28
The above information can be represented in the form of a 2 × 2 matrix as follows:
10 18
(1)
25 28
Key terminologies
• Square matrix: A matrix which has the same number of rows and colums. The following
are examples of square matrices:
a11 a12 a13 2 3 4
a11 a12
X1 = X2 = a21 a22 a23 X3 = 4 8 9
a21 a22
a31 a32 a33 0 1 5
• Diagonal matrix: A square matrix A = (aij )n×n is called a diagonal matrix if each of its
non-diagonal element is zero, i.e, aij = 0 if i 6= j and at least one element aii 6= 0.
Example 4.0.1.
a11 0 0 2 0 0
A = 0 a22 0 B = 0 8 0
0 0 a33 0 0 5
• Identity Matrix: A diagonal matrix whose diagonal elements are equal to 1 is called identity
matrix and denoted by In . That is,
1 0 0
1 0
I2 = I3 = 0 1 0
0 1
0 0 1
- For any square matrix A, AI = IA = A.
37
• Zero Matrix: A matrix whose elements are zero is called Zero matrix denoted by 0m×n .
Example 4.0.2.
0 0
03×2 = 0 0
0 0
4.1 Matrix operation
• Addition and Subtraction of two matrices: -Addition and subtraction require that the
matrices be the same dimensions. The resultant matrix is also of the same dimension.
-Add/subtract each element in the first matrix to the corresponding element in the second
matrix.
Example 4.1.1. Let
10 20 30 1 2 3
A= B=
40 50 60 4 5 6
Then
10 20 30 1 2 3 10 + 1 20 + 2 30 + 3 11 22 33
A+B = + = =
40 50 60 4 5 6 40 + 4 50 + 5 60 + 6 44 55 66
• Scalar Multiplication: Generally, scalar multiplication of a matrix entail multiplying each
element in the matrix by the scalar quantity. For example, 3B is given as
1 2 3 3×1 3×2 3×3 3 6 9
3B = 3. = =
4 5 6 3×4 3×5 3×6 12 15 18
• Multiplication of two matrices: If A is an n × m matrix and B is an m × p matrix, the
result AB of their multiplication is an n × p matrix defined only if the number of columns m
in A is equal to the number of rows m in B.
Example 4.1.2. Let
1 2
1 5 7
A= B = 3 7
9 6 9
8 4
Find (i) AB (ii) BA (iii) Is AB = BA?
• Transpose: The transpose of matrix A written as At ot AT is the matrix obtained by writing
the rows of A in order as columns.
Example 4.1.3. Example. Given the matrix M where
a11 a12 T a11 a21
M= then M =
a21 a22 a12 a22
38
• A square matrix A is said to be symmetric if A = AT .
Example 4.1.4. Given
1 −1 1
A = −1 −4 −2
1 −2 −3
then
1 −1 1
AT = −1 −4 −2
1 −2 −3
Since A = AT , the matrix A is symmetric by definition.
4.2 Determinants of matrices
Definition 4.2. Let A be a square matrix of order n, then the number |A| is called determinant
of the matrix A.
Example 4.2.1. We look at the following matrix sizes.
(i) Determinant of 2 × 2 matrix. Let
a11 a12 a11 a12
A= then |A| = = a11 a22 − a12 a21
a21 a22 a21 a22
(ii) Determinant of 3 × 3 matrix. Let
a11 a12 a13
B = a21 a22 a23 then
a31 a32 a33
a22 a23 a a a a
|B| = a11 − a12 21 23 + a13 21 22
a32 a33 a31 a33 a32 a32
= a11 (a22 a33 − a23 a32 ) − a12 (a21 a33 − a23 a31 ) + a13 (a21 a32 − a31 a22 ).
Exercise: Calculate the determinants of the following matrices
1 3 4 2 −3 4
1 2
(i) A = (ii) B = 0 1 4 (iii) C = 5 6 7
3 4
5 6 0 8 9 1
4.2.1 Singular matrix
A square matrix A of order n, is called singular matrix if its determinant is zero. That is |A| = 0
and non-singular otherwise.
39
4.3 Inverse of a matrix
Definition 4.3. If A and B are two matrices such that AB = BA = I, then each is said to be
inverse of the other. The inverse of matrix A is generally denoted as A−1 .
Example 4.3.1. Find the inverse of the following matrices:
a b
i) A =
c d
Solution:
Step 1: Get det(A) = |A| = ad − bc
Step 2: Swap the elements in the main diagonal; followed by a sign change on the elements
in the other diagonal.
d −b
−c a
step 3: pre-Multiple the matrix in step 2 by the reciprocal of the determinant of matric A to
obtain the inverse. That is,
−1 1 d −b
A =
det(A) −c a
4 7
ii) B =
2 6
Solution:
det(B) = |B| = (4)(6) − (2)(7) = 10.
Therefore,
−1 1 6 −7 1 6 −7 0.6 −0.7
B = = =
det(B) −2 4 10 −2 4 −0.5 0.4
Always confirm that BB −1 = I.
5 4
ii) C =
2 3
** End of Topic Four **
40