0% found this document useful (0 votes)
4 views

Chapter 1 - Matrix Algebra1

Unit One covers the fundamentals of matrix algebra, including definitions, types of matrices, and their properties. Key types discussed include row matrices, column matrices, null matrices, square matrices, diagonal matrices, scalar matrices, and identity matrices. The unit emphasizes the systematic arrangement of numbers in matrices and their applications in solving linear equations and other mathematical processes.

Uploaded by

asmamachewm
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
4 views

Chapter 1 - Matrix Algebra1

Unit One covers the fundamentals of matrix algebra, including definitions, types of matrices, and their properties. Key types discussed include row matrices, column matrices, null matrices, square matrices, diagonal matrices, scalar matrices, and identity matrices. The unit emphasizes the systematic arrangement of numbers in matrices and their applications in solving linear equations and other mathematical processes.

Uploaded by

asmamachewm
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 37

UNIT ONE: MATRIX ALGEBRA

1.1. Introduction
Matrix is a rectangular arrangement of numbers or variables. A matrix has no numerical
value; it simply stores information in a systematic way. In this unit, you will learn the algebra
of matrix and its applications. With respect to applications, major emphasis is excreted on
solving system of linear equation, Markov process and input-output mode.

1.2. Definition
A matrix is a rectangular array (or arrangement) of numbers (or variables) arranged in such a
way that each number has a definite position allotted to it.
If a matrix has “m” rows and “n” columns, “m x n” is called the order or the dimension of the
matrix. Read “m x n” as m by n.

 a11 a12 a13 .......a1n 


 
 a 21 a 22 a 23 .......a 2 n 
  The a11, a12 … are called elements of the matrix
 
a a m3 ..... a mn 
 m1 am2

This is m x n matrix. It has m number of rows and n number of columns.

Columns

 a11 a12 a13 ...........a1n 


 
 a 21 a 22 a 23 ..........a 2 n 
Rows  
 
 a m1 am2 a m3 .........a mn 

Note that every element in the matrix has define location. For example a23 is in the second
row and third column. Where is a32 located? At the third row and 2nd column. As a
conviction, the first number represents the row and the second number represents the column.

3 5 7
Question: Given A =  
2 4  3 

1
a) What is the order of A? Answer 2 X 3
b) How much is a13 element? Answer 7
c) How much is a22 element? Answer 4
A matrix, by definition, is simply an arrangement of numbers and has no numerical value.

1.3. Types of Matrices


1.3.1 Row Matrix –A matrix which has exactly one raw is called a raw matrix or a row
vector; its dimension is 1xn.
Example 1 2 3 4
This is a raw vector of order one by four, (1 X 4). We can simply say “a row vector of order
four.”

Question: If A = (5 6 7), what is the order of A?


Answer: A row vector of order 3.

1.3.2 Column Matrix –A matrix which has exactly one column is called a column matrix or a
column vector; its dimension is m x 1.

2 
 
Example  1 is a column matrix (vector) of order three.
5 
 
5 
 
7
Question: If B =   , what is the order of B?
 2 
 
1 
Answer: B is a column matrix (vector) of order 4

1.3.3 Null or Zero Matrix –A matrix each of whose elements is zero is known as a null or
zero matrixes.
0 0 0
Example   is 2 x 3 null matrixes.
0 0 0
If 0 denotes zero matrix, then
a) A + 0 = A
b) A – 0 = A

2
c) 0 – A = - A
d) A.0 = 0.A = 0
Examples:
 2 5  0 0   2  0 5  0   2 5
1.           
  1 1   0 0    1 0 1 0    1 1 

 2 5  0 0   2  0 5  0   2 5 
2.           
  1 1   0 0    1  0 1  0    1 1

0 0  2 5 0 2 0  5   2  5
3.         
0 0    1 1  0   1 0 1   1  1 

 2 5   0 0   20  50 20  50  0 0 


4.          
  1 1   0 0    10  10  10  0   0 0 

0 0   2 5   02  0  1 05  01   0 0 


5.       
0 0    1 1  02  0 1 05  01  0 0 

The properties of matrix addition/subtraction and multiplication are discussed in section 2.4

1.3.4 Square Matrix –A matrix whose number of rows is equal to the number of columns is
called square matrix.
1 2 
Example:   is a 2 x 2 square matrix. It can simply be referred to as “a square matrix of
 0 3
order two.”
Question: which of the following is not a square matrix?
0 0 1 0 0   2 5 1 0 3 
a)        
0 0 b)  0 1 0  c)  5 3  d)  0 2  1
 0 0 1 0 1  3 2 7 
     

Answer: C is not a square matrix because it has three rows but only two columns.

3
1.3.5 Diagonal Matrix –A square matrix whose every element other than the diagonal
elements is zero is known as a diagonal matrix.

 a11 a12 a13 


 
If A =  a21 a22 a23  , elements a11, a22 and a33 are diagonal elements of matrix A.
a a 
 31 32 a33 
In order to classify a matrix as a diagonal matrix;
a) It should be a square matrix; that is its number of rows should be equal to its number
of columns, and
b) All the not-diagonal elements should be zero. Note that the diagonal elements
themselves may or may not be zero. What is required is that the non-diagonal elements
be zero.

Example
1 0 0   0 0 0
  0 0  
A =  0 2 0 , B =   , C =  0 0 0
0 0 3 0 2  0 0 0
   
A, B and C are diagonal matrices

Question: Which of the following matrices are not diagonal matrices?


2 0 0
 2 0  1   5 0 0
  3 0  0 1 0  
A = 0 1 0  B =   , C=  , D = 0 3 0
0 0 3  0 2 0 0 3  0 0 0
     
0 0 0 

Answer:
- A is not a diagonal matrix because a13, which is a not-diagonal element is not zero.
- B is a diagonal matrix because it is a square matrix and its every non-diagonal
elements are zero.
- C is not a diagonal matrix because it is not a square matrix.
- D is a diagonal matrix because it is a square matrix and its every non-diagonal
element is zero.

2
1.3.6 Scalar Matrix –A diagonal matrix whose diagonal elements are equal is called scalar
matrix.

Therefore, a scalar matrix must be a) a square matrix, b) a diagonal matrix and c) all its
diagonal elements must be equal.
Example:
0 0 0 0
 2 0 0  1 0 0   
3 0     0 0 0 0
   0 2 0   0 1 0 0
 0 3  0 0  2  0 0 1 0 0 0
     
0 0 0 0 

All the above matrices are scalar matrix. Question: Which of the followings is not a scalar
matrix?
 2 0 0 5 0 0
 0 0 0    
A =   B = 0 2 1  C = 0 5 0
 0 0 0  0 0 2  0 0 5
   
Answer: Both A and B are not scalar matrices because A is not a square matrix and a23
element of B is not zero. Matrix C is a scalar matrix.

1.3.7 Identify (unit) Matrix –A scalar matrix whose every diagonal element is equal to one is
called Identity or Unit matrix. Identity matrix is a) square matrix, b) diagonal matrix, c) scalar
matrix, and d) all its diagonal elements equal to 1. Therefore, there is only one unit matrix for
each square order; thus it is unique.
Example:
1 0 0 0
1 0 0   
1 0    0 1 0 0
A =   , B = 0 1 0 , C= 
 0 1  0 0 1 0 0 1 0
   
0 0 0 1

A is called identity matrix of order 2
B is called identity matrix of order 3
C is called identity matrix of order 4

3
Identity matrix has some similar characteristics as the number 1 in common algebra. If A is a
non-Zero (null) matrix and I is an identity matrix and if A and I are conformable for
multiplication, then
AxI=IxA=A
Example
 2 3 1 0 
If A =   and I =   , then
5 1   0 1

 2 3 1 0   21  3 0 20  31  2 3


A.I =     =  =  
5 1   0 1  51  10 50  11  5 1 

1 0   2 3 12  05 13  01  2 3


I.A =     =  =  
 0 1 5 1   02  15 03  11 5 1 

Therefore AI = IA = A
Reminder: The rule of matrix multiplication is discussed in 2.4.5 below.

1.3.8 Triangular Matrix –A matrix whose every element above (or below) the diagonal is
equal to zero is called triangular matrix. Specifically, a square matrix whose aij = 0 wherever
i<j is called lower triangular matrix. Analogously, a square matrix whose aij = 0 whenever i>j
is called upper triangular matrix.
Example (1)
1 0 0 0
 5 0 0    0 0 0 1 0 0 
  2 3 0 0  2 0    
A=  3 1 0 B= 0 C=   D =  0 0 0 E = 0 1 0
  2 5 9 5 0 0 1 2   0 0 0  0 0 1
       
2 0 3 1 

All the above matrices are lower triangular matrixes because their elements above the
diagonal are equal to zero. Note that their a12, a13, a14 … a23, a24, a25 … a34, a35, a36 … are zero.
That is, every element whose row number is less than its column number (aij, where i<j) is
equal to zero.

4
Example 2
 7 11 2 3 
3 1 2     0 0 0 1 0 0 
  0 1 5 2  1 2     
A = 0 2 5  B =   C =   D =  0 0 0 E =  0 1 0
0 0  2 0 0  3 4  0 1   0 0 0  0 0 1
       
0 0 0 1 
 

All the above matrices are upper triangular matrices because their every element below the
diagonal is zero. Note that in each case a21, a31, a32, a41, a42, a43 … are equal to zero. That is aij
= 0 whenever i>j.
Note that a square zero matrix (D) and identity matrix (E) can be classified as both upper and
lower triangular matrices because they fulfill both conditions.
Question: Which of the following matrices are not triangular and why?
 2 0 0 2 3 2 5  1 2 3 
  1 2     
A = 3 1 0  B =   C = 0 1 1 2  D = 0 5 6
5 1 2 0 3  0 0 2  3  2 0 0
     
Answer: A is a lower triangular matrix
B is an upper triangular matrix
C is not a triangular matrix because it is not a square matrix
D is not a triangular matrix because a31 element is not zero.
Therefore, the answer is C and D.

1.4. Algebra of Matrices


1.4.1 Equality of Matrices –Two matrices A and B are said to be equal if and only if:
a) A and B are of the same order, and
b) Every corresponding elements in A and B are same.
Therefore, a matrix is equal to itself only.
Examples:
1 2 0  1 2 0 
   
a) I f A =  5 3 4  and B =  5 3 4  , then
0 1 2  0 1 2 
   
A = B because every element of A is equal to the corresponding element of B.

5
1 3  1  1 3  1 
   
b) If M =  0 1 2  and N =  0 2 1  , then
2 1 5  2 4 5
   
M  N because the a22 element of M is l while the corresponding a22 element of N is 2 and the
a23 element of M is 2 while the corresponding a23 element of N is 1.

Note that although every element of M is also element of N the two are not equal because of
the differences in the locations of the elements.

1.4.2 Addition of Matrices –Two or more matrices can be added if and only if they are of the
same order; otherwise, they are said to be non-conformable for addition. If they are
conformable for addition, their sum will be the matrices formed by adding each corresponding
element. If they are non-conformable for addition, the sum of the matrices does not exist.
Generally, if
 a11 a12 a13   b11 b12 b13 
   
A =  a 21 a 22 a 23  and B =  b21 b22 b23 
a a33  b b33 
 31 a32  31 b32

Then
 a11  b11 a12  b12 a13  b13 
 
A + B =  a 21  b21 a 22  b22 a 23  b23 
a b a32  b32 a33  b33 
 31 31
Examples:
 2 5 2 1 3 
1. If M =   and N =  
 1 0 3  4 5
M + N does not exist because M is 2 x 3 while N is 2 x 2. They are said to be non-
conformable for addition.
 2 5 2 1 3 0 
2. If A =   and B =   , A and B are conformable for addition
 1 0 3 4 5 2 
because both are of the same order, 2 x 3.

 2 1 53 2  0 3 8 2
A + B =  =  
  1 4 05 3  2  3 5 5

6
If two or more matrices, say A, B and C, are conformable for addition (that is if they are
of the same order), then:
i) Matrix addition is commutative
A+B=B+A
ii) Matrix addition is associative
(A + B) + C = A + (B + C) = A + B + C
iii) If 0 denotes a null matrix of the same order as that of A, then
A+0=0+A=A
Examples:
 2 3  1 4  0 1 0 0 
Let A =   , B =   , C =   , and O =  
5 1   2 3   1 1 0 0

 2   1 3 4 1 7 
a) A + B =   =  
5 2 1  3   7 4 
  1  0 4  1   1 5 
b) B + C =     
 2   1 3  1   1 4 

1 7   0 1  1 0 7 1 1 8 
c) (A + B) + C =   +   =   =  
7 4   1 1  7   1 4  1  6 5

 2 3   1 5  2   1 3  5  1 8 
d) A + (B + C) =   +   =   =  
5 1   1 4  5 1 1  4   6 5

 2 3  1 4  0 1
e) A + B + C =   +   +  
5 1   2 3  1 1 

 2   1  0 3  4  1 1 8 
=    
 5  2   1 1  3  1   6 5 

1 8 
Therefore, (A + B) + C = A + (B + C) = A + B + C =  
 6 5
 2 3 0 0  20 3 0  2 3
f) A + O =   +   =   =  
5 1  0 0 5  0 1 0  5 1 

7
0 0   2 3 0 2 0  3  2 3
g) O + A =   +   =   =  
0 0 5 1  05 0 1  5 1 
Therefore, A + 0 = 0 + A = A

If A + B = B + A = 0, then A is the additive inverses of B that of A.


Example:
1  3  1 3
Let A =   and B =   , then
 4 5   4  5
1   1  3  3 0 0 
A + B =   =  
 4 4 5   5 0 0
  11 3   3 0 0 
B + A =   =  
 4   4  5  5  0 0
A is additive inverse of B and B is additive inverse of A.

1.4.3 Subtraction of Matrices –A matrix can be subtracted from another matrix if both are of
the same order; otherwise, they are said to be non-conformable for subtraction. If they are
conformable for subtraction, the difference between the two matrices will be the matrix
obtained by subtracting each corresponding element.
Generally, if
 b11 b12 b13 
 a11 a12 a13   
  b b22 b23 
A =  a 21 a 22 a 23  and B =  21
a b b32 b33 
 31 a32 a33   31



 
Then
 a11  b11 a12  b12 a13  b13 
 
 a 21  b21 a 22  b22 a 23  b23 
A–B= 
a b a32  b32 a33  b33 
 31 31 
 
 
 b11  a11 b12  a12 b13  a13 
 
 b21  a 21 b22  a 22 b23  a 23 
B–A= 
b a b32  a32 b33  a33 
 31 31 
 
 

8
Example:
1 9    2 4
Let A =   and B =   , then
 0 3  5 8

1   2 9  4  3 5
A – B =   =  
05 3  8    5  5

 2 1 4  9  3  5
B – A =   =  
 50 8  3   5 5 

If 0 denotes a null matrix of the same order as the matrix A, then A – 0 = A and 0 – A = -A
(See the examples under 2.3.3 above.)

1.4.4 Multiplication of a Matrix by a Constant


It is possible to multiply a matrix by a constant number. In doing so, the constant multiplies
every element of the matrix.
If K is a constant number, then:
 a11 a12   Ka11 Ka12 
K =   =  
 a 21 a 22   Ka 21 Ka 22 

Example:
3 5   23 25   6 10 
2   =   =  
 2 1  22 21  4  2
Prove yourself that the following statements are correct.
i) K (A+ B) = KA + KB
ii) (K1 + K2) A = K1 A + K2 A
iii) (K1.K2) A = K1 (K2.A)

1.4.5 Multiplication of Matrices


The product of two matrices, A and B, is defined only if the number columns of A is the same
as the number of rows of B. That is, in order to multiply two matrices, the first matrix must
have as many columns as the second matrix has rows. Matrices that fulfill this condition are

9
said to be conformable for multiplication. Otherwise, multiplication is impossible and the two
matrices are said to be non-conformable for multiplication.

If A is a matrix of order (m x n) and B is another matrix of order (n x p), then multiplying A


to B is possible because the number of columns of A is “n” which is the same as the number
of rows of B. The product matrix, AB, will be of (m x p) order. That is, the product matrix
will have the same number of rows as the first matrix and the same number of columns as the
second matrix.

Matrices A  B  AB
Orders m  n n  p m  p
That n, the number of columns of A is the same to n, the number of rows of B confirms is AB
exists and therefore A and B are conformable for multiplications. AB will be a matrix of order
m x p.

Question:
If A is a 3 x 4 matrix and B is a 4 x 5 matrix, then what will be the order of a) AB, and b) that
of BA?

Answer:
a) AB exists because the number of columns of A is 4, which is the same as the number
of rows of B. Therefore, AB will have same number of rows as A (3) and the same
number of columns as B (5), which means the order of AB is 3 x 5.

Matrices A  B  AB
Orders 3  4 4  5 3  5
b) BA does not exist because the number of columns of B is 5, which is different from
the number of rows of B(3). Thus, B and A are not conformable for multiplication
Matrix B x A = 
Order 4x5 3x4

1.4.5.1 Rules of Matrix Multiplication: In multiplying two matrices (that are conformable
for multiplication), you have to employ the strict rule of adding the products of elements of

10
the rows of the first matrix and elements of the columns of the second matrix. That is, you
“go” along the rows of the first matrix and down the columns of the second matrix, column of
the product matrix.
The sum of products of elements of the 1st row of the 1st matrix and elements of the 1st column
of the 2nd matrix forms the 1st row 1st column of the product matrix. Likewise, the sum of
products of elements of 1st row of the 1st matrix and elements of 2nd columns of the 2nd matrix
forms the 1st row-2nd column of the product matrix and so on. The crucial point here is matrix
multiplication is row by column.

 b11 b12 
 a11 a12 a13     c11 c12 
If   x  b21 b22  =   , then
 a 21 a 22 a 23  b b   c 21 c 22 
 31 32 
2x3 2x2 2x2
C11 = a11 (b11) + a12 (b21) + a13 (b31)
C12 = a11 (b12) + a12 (b22) + a13 (b32)
C21 = a21 (b11) + a22 (b21) + a23 (b31)
C22= a21 (b12) + a22 (b22) + a23 (b32)

Note that since the first matrix is of 2 x 3 order and the second of 3 x 2 order, their
product matrix is a 2 x 2 matrix.
Examples:
1 5   2 1
1. Given A =   and B =   , find AB and BA
3 2   4 3
Solutions:
1 5   2 1  12  5 4 11  53    18 16 
AB =     =  =  
 3 2    4 3  32  2 4 31  23  2 9 
Orders 2 x 2 2x2 2x2

 2 1 1 5   21  13 25  12  5 12 


BA =     =   =  
  4 3 3 2   41  33  45  32 5 14 
Order 2x2 2x2 2x2

11
2 3 X   4
2. Given     =   , Solve for X and Y.
5 2  Y  1 
2x2 2x1 2x1
Solution:
2 3 X   4 2( x)  3 y    4
If     =   ,
5 2  Y  1  5x   2 y  1
2x2 2x1 2x1

2x  3y   4
By solving simultaneously, we get x = 1 and y = -2
5 x  2 y 1
Check:
2 3 1   21  3 2   4
    =   =  
5 2    2  51  2 2 1 
2x2 2x1 2x1

3. Convert the following system of linear equations into extended matrix form.

5X1 – 2X2 + X3 = 10
-3X1 + 7X2 – 2X3 = 15

Solution
 X1 
 5 2 1   10 
  X2    
 3 7  2    15 
 X3 

1.4.5.2 Properties of Matrix Multiplication


i) Matrix multiplication is associative. That is, if matrices A, B and C are conformable
for multiplication, then A (B C) = (AB) C

Example:
 2 3 1 0  5  2
Let A =   , B =   and C =  
 5 1 2 3 1 0 

12
 2 3 5  2  49  16 
A (BC) =     =  
 5 1 13  4   38  14 
8 9  5  2  49  16 
(AB) C =     =  
 7 3 1 0   38  14 
Therefore, A (BC) = (AB) C

ii) Matrix multiplication is distributive. That is, if matrices A,B and C are conformable for
addition and multiplication, then
A (B + C) = AB + AC, and
(A + B) C = AC + BC
Examples:
  2 5 1 2   8 2
Let A =   , B =   , and C=  
 4 3   5 7    3 1 

  2 5 9 4  8 32 
a) A (B + C) =     =  
 4 3  2 8  42 40 

 23 31    31 1   8 32 
AB + AC =   +   =  
19 29   23 11  42 40 
Therefore, A (B + C) = AB + AC

iii) Matrix multiplication is not always commutative. That is, AB is not necessarily equal to
BA. There are three possible cases.
Case I. Under certain conditions, AB may be equal to BA
2 3 1 0 
Example: Let A =   and B =   , then
1 4   0 1
 21  30 20  31 2 3
AB =  =  
11  40 10  41  1 4 

12  01 13  04  2 3


BA =   =  
 02  11 03  14 1 4 

13
Thus, in this case AB = BA. Note that in this example AB =BA = A because B is an identity
matrix of the same order as A. (See the properties of identity matrix under 2.3.7 above).
Specifically, if either or both matrices are scalar matrix, then AB = BA (for more explanations
and examples, see section 2.4.6)

Case II. It is possible that AB is defined (conformable for multiplication) while BA does not
exist (not conformable for multiplication)
Example:
 1 5  2 5 1
Let A =   and B=  
  2 3  0 1 3
AB exists because the orders 2 x 2 and 2 x 3 are conformable for multiplication, AB will
be of order 2 x 3. Therefore,
 1 5  2 5 1  2 10 16 
AB =     =  
  2 3  0 1 3  4  7 7 
BA does not exist because the orders 2 x 3 and 2 x 2 are not conformable for
multiplications. Therefore
 2 5 1  1 5
BA =     does not exist
 0 1 3   2 3
Case III. It is possible that both AB and BA exist but they are different matrices. That is both
AB and BA are defined but AB is not equal to BA (AB  BA)
Example 1.
1 3  4 6
Let A =   and B =   , then
 2 1  2 1
1 3  4 6 16 9 
AB =     =  
 2 1  2 1  6 11
4 6 1 3  16 6 
BA =     =  
 2 1  2 1  4 5
Both AB and BA exist, but AB  BA
Example 2.
5 
Let A = (2 4) and B =   , find AB and BA.
  3

14
5 
Solution: AB = 2 4   = 25  4 3 = (-2) = -2
  3
1x2 2x1 1x1
If A is a row vector and B is a column vector and if AB exist, then the product matrix will be
a constant number,
5   52 54  10 20 
BA =   2 4 =   =  
  3   32  34    6  12 
2x1 1x2 2x2
When a column vector is multiplied to row vector the product will be matrix.
Therefore, if A and B are vectors and one is a row vector while the other is column vector,
then AB  BA.

Reminder: Matrix multiplication is associative and distributive but not necessarily


commutative.
1.4.6 Multiplication of a Matrix by a scalar
A scalar is a square and diagonal matrix whose every diagonal elements are equal (See 2.3.6
above). When multiplication is possible, multiplying a matrix by a scalar produces the same
result as multiplying the matrix by the constant diagonal element of the scalar.

Let K be a scalar and A be a square matrix of the same order as K, then KA = AK


K O  a11 a12 
Let K =   and A =  
O K   a 21 a 22 

 K a11   0a 21  K a12   0a 22   Ka Ka12 


KA =   =  11 
 0a11   K a 21  0a12   K a 22   21
Ka Ka 22 

 a11 a12  K O  a11 K   a12 0 a11 0  a12 K   Ka Ka12 


AK =     =   =  11 
 a 21 a 22  O K   a 21 K   a 22 0 a 21 0  a 22 K   Ka 21 Ka 22 

Therefore, KA = AK. Note that multiplying matrix A by the constant number K produces the
same result.
 a11 a12   Ka11 Ka12 
KX  =  
 a 21 a 22   Ka 21 Ka 22 

15
3 0  5 2
Example (1) Given A =   and B =   , evaluate AB and BA.
 0 3  3 4
Solution:
3 0  5 2   35  0 3 32  04   15 6 
AB =     =   =  
 0 3   3 4   05  3  3 02  3 4   9 12 

 5 2 3 0  53  20 50  23   15 6 


BA =     =   =  
  3 4   0 3   33  4 0  30  4 3   9 12 

Note that the result is the same as multiplying A by 3


 5 2  35 32  15 6 
3   =   =  
 3 4  3 3 34    9 12 
however, KA may not be equal to AK if A is not a square matrix
K O a a a 
Let K =   and A   11 12 13  , then
O K  a 21 a 22 a 23 

 Ka11 Ka12 Ka13 


KA =   ; K is of 2 x 2 order, A is 2 x 3 and therefore KA is a 2 x 3
 Ka 21 Ka 22 Ka 23 

matrix.

AK does not exist because a 2 x 3 matrix (A) cannot be multiplied by a 2 X 2 matrix since
they are not conformable for multiplication
Therefore, in this case KA  AK.

1.4.7 Power of a Matrix


If A is square matrix, the A2, A3, A4 ….are defined.
 a11 a12 
If A =   , then
 a 21 a 22 

 a11 a12   a11 a12   a11 a11   a12 a 21  a11 a12   a12 a 22  
A2 =     =  
 a 21 a 22   a 21 a 22   a 21 a11   a 22 a 21  a 21 a12   a 22 a 22 

Example
2 3
Given A =   , find A2 and A3
 1  2 

16
Solution
2 3 2 3  22  31 23  3 2  7 0 
A2 =     =   =  
1  2  1  2  12   21  13  (2)  2 0 7

7 0  2 3  72  01 73  0 2 14 21


A3 =     =   =  
0 7 1  2   02  71 03  7 2   7 14 
1.4.8 Transpose of a Matrix
Let A be a matrix. The matrix obtained from A by interchanging its rows and columns is
called the transpose of A. Transpose of A is denoted by A or AT
Only square matrices can be powered
1 2 3 
Example: Given B    , find B
2

 4 5 6
Solution B2 does not exist because a 2 x 3 and a 2 x 3 matrices are not conformable for
Multiplications
 a11 a21 
 a11 a12 a13   
If A =   , then A   a12 a22 
 a21 a22 a23  a a23 
 13
Example:
2 5  2 4
1. If A =   , A =  
 4 6  5 6 

1 
 
2. If B = (1 2 3) , B =  2 
3
 
4 0  4 0 
3. If C =   , C =  
0 4 0 4
3 2  3 2 
4. If D =   , D =  
 2 3  2 3
Any matrix A for which A = A1 is called a symmetric matrix. Examples 3 and 4 are
symmetric matrices.

17
1.5. Elementary Operation
The following types of row or column operations are called elementary operations.
i) Interchanging any two rows (or columns);
ii) Multiplying any row (or column) by a non-zero constant number; and
iii) Adding a multiple of one row (column) to a multiple of another row (column).
An elementary operation should be either row or column operation, not both at the same time.
If an elementary operation is conducted, it should involve every element of the row (or
column). It is prohibited to operate on some elements of a row (or column) and ignore some
elements of the same row (or column).
A new matrix formed by elementary operation can easily be restored back to its original
matrix by “undoing” the operations. Therefore, although the new matrix is not equivalent to
the old one, the information stored is the old matrix are retrievable from the new one, this is
why the system remains intact.
Notations: “” denotes interchanging. For example, R1  R2 reads as row 1 and row 2 are
interchanged.
“” denotes replacement. For example, 2R1 – R2  R2 reads as 2 times row one
minus row 2 replaces row 2. That is the old R1 minus the old R2
Although elementary operation can be conducted either on rows or columns, we focus on row
operations only because they are appropriate for our purposes. However, the principle is the
same for both operations.
Example:
 3 5
1. Given   , change a12 element to zero. Using elementary row operation.
 2 1
Solution: To make a12 element, 5, become 0, we can multiply the 2nd row by 5 and subtract
the product (5 x 1 = 5) from 5; and the same operation should involve the whole row.
R1 – 5R2  R1 3 – 5 (2) 5 – 5 (1) = -7 0
R2  R1 2 1 2 1

2. Given  27 10 Change a


21 element to zero

18
Solution:
R1  R1
-7 0 –7 0
2 R1  7 R2  R2
2 (-7) + 7 (2) 2 (0) + 7 (1) = 0 7

 2 5 1
 
3. Given 1 6 2  , change the matrix to an upper triangular matrix, using elementary
3 5 6 
 
row operation.
Solution: We need the a21, a31, and a32 elements be equal to zero. Let’s first make a21 and a31
elements are equal to zero.
R1  R1 2 5 1  2 5 1  2 5 1
     
R1  2 R2  R2 1 6 2    2  2(1) 5  2(6) 1  2(2)    0  7  3 
3R2  R3  R3 3 5 6   3(1)  3 3(6)  5 3(2)  6   0 13 0 
 
Now, we have make a32 element, 13, zero.
R1  R1
R2  R2
13R2  7 R3  R3
2 5 1 2 5 1  2 5 1
     
0 7  3   0 7 3   0 7 3 
0 0  13(0)  7(0) 13(7)  7(13) 13( 3)  7(0)   0 0  39 
 13 

Solving system of Linear Equations


As explained above, information stored in matrix will not be distorted by elementary
operations; hence, the original setting is retrievable. This can easily be demonstrated by
system of linear equations.

For example:
2 x  3 y  3z  8

3x  2 y  2 z  10 Can be written in extended matrix form as
 x  y  2z  1

19
2  3 3  X   8
     
3 2 2   Y  =  10 
1  1  2  Z   1
     

By writing the coefficient matrix and the constant vector side-by side, we get.

 2 3 3 8 
 
 3 2 2 10 
 1 1 1 1 
 
Now, let’s change the coefficient matrix to an upper triangular matrix using elementary
operations. That is, we need to make a21, a22 and a31 elements equal to zero.

R1  R1 2  3 3  8 R1  R1  2 3 3 8 
   
R2  3R3  R2 3 2 2 10  => R2  R2  0 5 8 7
R1 _ 2 R3  R3 1  1  2 1  R2  5R3  0 1 7  10 

2 3 3 8 
 
 0 5 8 7  , Then convert this into algebraic form of system of linear equation
0  43 
 0 43

2x-3y+3z = -8

 5y + 8z = 7

 43z = -43

2x-3y+3z = -8 2x-3y+3z = -8
 
Note that: 3x+2y+2z = 10 and  5y + 8z = 7 have the same solutions, because the
 x - y - 2z = 1 
  43z = -43

second system is obtained by elementary row operation. Thus, solving the second system
solves the first system and solving the second one is by far easier than solving the first
system.
From the third equations 43z = -43, we get z = -1. We substitute z = -1 into the second
equation.
5y + 8(-1) = 7
5y = 15
y=3

20
We substitute = -1 and y = 3 into the first equation, we get
2x – 3(3) + 3(-1) = -8
2x – 9 – 3 = -8
2x = 4
x=2
Therefore, the solution set is  2, 3,  1 

Question- Solve the following system of linear equations by reducing the coefficient matrix to
upper diagonal matrix.
X+y+z=7
X + 2y + 3z = 16
X + 3y + 4z = 22

1 1 1 7  1 1 1 7 
   
1 2 3 16  After few row elementary operation we may get 0 1 2 9
1 3 4 22  0 0 1 3
  
x+y+z=7
y + 2z = 9
z=3

y + 2(3) = 9 => y = 3
x + 3 + 3 = 7 => x = 1
Therefore, the solution set is {1, 3, 3}
Note that the upper or lower triangular matrices obtained through elementary operations are
not unique. Depending on the type of operations used one can produce many different
triangular matrices from a single original matrix. However, if the system has a unique
solution, then all of them will lead to that unique solution.

21
1.6. The Multiplicative Inverse of a Matrix
Two matrices are multiplicative inverse of each other if their product is identify matrix.
Inverse of A is denoted as A-1
A.A-1 = A-1.A = I

1 2  1  3 2
If A    , then A    because
 2 3  2  1

1 2   3 2  1 3  2  2  1 2   2  1   1 0 


A, A-1 =     =    , and
 2 3  2  1  2  3  3  2  2  2   3  1   0 1 

 3 2  1 2    3 1  2  2   3  2   2  3  1 0 
A-1, A =     =   
 2  1  2 3   2 1   1 2  2  2   1 3   0 1

Important points:
i) Only square matrices can have a multiplicative inverse. Non square matrices do
not have inverse.
ii) Not all square matrices do have inverse. Matrixes will no inverse is called singular.
iii) If an inverse exists, it is unique. That is, a matrix cannot have more than one
inverse.

Gauss-Jordan Inversion Method


Write side by side the matrix you want to inverse and an identity matrix of the same order.
Applying necessary row operations on both matrices to convert the matrix you want to inverse
into identity matrix. The former identity matrix will become the inverse of your initial matrix.
Thus, you start as (A/I) and end up with (I/A-1)

22
1  3 
Example 1: Find the inverse of  
 2 4
Solution
1 R R
4 R1  3R2  R1 1  3 1 0 10 1 1 10 0 4 3
   
2 R1  R2  R 2 4 0 1 1 R  R  0  10 2  1
10 2 2

1 0 2 3 
 5 10 
 
0 1  2 1 10 
 10 
2 3 
1  3   5 10 
Therefore, inverse of   i s
 2 4  2 1 
 10 10 
Check

1  3 
2
 5
3
10 

    
1 2   3 2
5 10     
1 3 3 1
10 10 1 0 
  = =  
 2 4  2
 10
1 
10 
 2
2
    
5
 4 2
10     
2 3 4 1
10 10
 0 1

2
 5
3
10 

1  3   5  
 2 1  3  2 
10
2 3  3  4   1 0 
5 10  =
  =
 2  
 2 1  2  3  1  4    0 1
 10   10  
 2 4 1 1 2
 10 10  10 10 

 2 2
Example 2. Find the inverse of  
3 3 

2 2 1 0
3R1 – 2R2  R1  
3 3 0 1

0 0 3  2
  No further row operation can provide an identity matrix because every
3 3 0 1 
element of the first row equals zero.

 2 2
Therefore,   has no inverse. It is singular. Note that a square zero matrix has no inverse
3 3 
because O.A = O  I

23
1.7. Application of Gauss-Jordan Inversion Method
One important application of Gauss-Jordan inversion method is that it helps to easily solve
systems of linear equation of any number of rows and columns.

1.7.1 Solving n x n system of linear equations. That is, when the number of equations equal
to the number of variables. For example,
a11 X1 + a12 X2 + a13 X3 = b1
a21 X1 + a22 X2 + a23 X3 = b2
a31 X1 + a31 X2 + a33 X3 = b3
Can be converted into expanded matrix form as:
 a11 a12 a13   X1   b1 
     
 a 21 a 22 a 23  X2   b2 
a a32 a33  X  b 
 31  3 =  3

Or equivalently, it can be written as


Ai = b, where A represents the coefficient matrix, X –the variable vector and b-the constant
vector.
(A-1) Ax = b (A-1) by multiplying both sides by A-1 (inverse of A), we get X = A-1b
Recall the Gauss-Jordan inversion method discussed under 2.6 above. We start as (A/I) and
end with (I/A-1). If we start with (A/b), will end with I/A-1.b and this gives the solution for the
system since X = A-1.b.Therefore, in order to solve an n x n system of linear equations, write
the coefficient matrix and constant vector side by side as:
 a11 a12 a13 b1 
 
 a21 a22 a23 b2  And then convert the coefficient matrix into an identity matrix using
a b3 
 31 a32 a33
row elementary operation involving the constant vector.
In doing so, one of the following outcomes will occur.
a) An n x n identity matrix with a unique solution, like

 1 0 0 b1' 
 0 1 0 b '  Indicating that the system has a unique solution and X = b1 ,
 0 0 1 b2'  1

 3 

X2 = b2 and X3 = b3 . The solution set is { b1 , b2 , b3 }

24
1 0 0 3
 
For example if you get  0 1 0 4
0 0 1 2 

Then X1 = 3, X2 = 4, X3 = 2. The solution set is {3, 4, 2}
b) A row whose every element in the coefficient matrix equal to zero, while non-zero in
the constant vector. This indicates that the system has no solution.

 1 0 0 b1' 
0 1 0 b ' 
 0 0 1 b2' 
 3 

This first row can be interpreted as X1 = b1 , the second as

X2 = b2 , and the third as 0 = b3 . The statement

0 = b3 is absurd. This indicates that the system is inconsistent. The solution set

therefore is 
For example, if you get
1 0 0 3
 
0 1 0 4  , then solution set is  .
0 0 0 2 

c) A matrix in a form different from (a) and (b) indicates that there is unlimited number
of solutions. In such cases a row (rows) with all zeros including the constant column
appears.
1 0 0 b  
 1


 0 1 1 b  There is no way to make a23 equal to zero. This indicates that a22 and a23 are
 2

0 0 0 0 
 
interrelated.
Therefore, the solution of the system is

X1 = b1

X2 + X3 = b2

25
By assuming values for either X2 or X3, we can have many different solutions.
For example if:
1 0 0 3
 
0 1 2 4
0 0 0 0 

X1 = 3
X2 + 2X3 = 4
If X2 = 1, then the solution set is 3 1 3/ 2

If X 2  2  3 2 1

X 2  3  3 3 1/ 2... etc.

Exercise 1: Solve the following system of linear equation using Gauss-Jordan method.
2x + 3y – 5z = 17
3x – 4y + 2z = -2
4x – 2y + 3z = 0

2 R1  3R3  R1  2 3  5 17 
 
3R1  2 R2  R2  3  4 2  2  Our objective is to convert the coefficient matrix into an
2 R1  R3  R3  4  2 3 0 

identity matrix of order 3, using row operations only.

R1  R1 16 0  1 34 
 
13R2 19 R3  R2  0 17  19 55 
8R 17 R3  R3  0 8  13 34 

69 R1  R3  R1 16 0 1 34 
 
R2  R2 0 69 0 69 
R3  R3 0 69  138 
 0

26
1
R1  R1
1104 1104 0 0 2208 
1  
R2  R2  0 69 0 69 
69  0
 0 69  138 
1
R3  R3
69
1 0 0 2
 
0 1 0 1
0  2 
 0 1

Therefore, X = 2, Y = 1 and Z = -2 2 1 2

Check:
2(2) + 3(1) – 5(-2) = 17
3(2) – 4(1) + 2(-2) = -2
4(2) – 2(1) + 3(-2) = 0

Exercise 2: Solve:
3x – 2y + 4z = 29
2x + 3y – z = -4
-5x – 5y + 3z = 7
Solution:
 3 2 4 29 
 
Start with  2 3  1  4  after appropriate row operations you will end with
 5  5 3 7 

1 0 0 3 
 
0 1 0  2  Indicating that the solution is X = 3, Y = -2 and Z = 4, that is 3, -2, 4
0 0 1 4 

1.7.2 Solving m x n system of linear equations, where m >n. That is, when the number of
equations is greater than the number of variables. In this case as well unique, multiple, or no
solution are possible.

27
a) If the system has unique solution, you will get an identity matrix of n x n with
unique solution and the remaining m – n rows will be equal to zero both in the
coefficient matrix and the constant vector.
If, for example, the system consists of 5 equation and three variables, and of you get
1 0 0 b1 
 
0 1 0 
b2 
 
0 0 1 
b3 
 
0 0 0 0 
0 0 0 0 
 
 

This indicates that there is unique solution X1  b1 , X 2  b2 and X 3  b3

b) If the system has no solution, then you will get an absurd row –a row with zeros in
the coefficient matrix and non-zero number in the constant vector.
1 0 0 b1 
 
0 1 0 
b2 
 
0 0 0 
b3 
 
0 0 0 0 
0 0 0 0 
 
 
The third row is absurd and it indicates that the system has no solution.
c) A matrix different from (a) and (b) indicates that there are unlimited number of
solutions, since some of the variables are interrelated.
1 0 0 b1 
 
0 1 1 
b2 
  X 1  b1
0 0 0 0  Here
  X 2  b2
0 0 0 0 
0 0 0 0 
 
 
Either X2 or X3 is a free variable that can be assigned a value and therefore there will be
unlimited number of solutions.

28
1.7.3 Solving m x n system of linear equations where m < n. That is, when the number of
equations is less than the number of variables. In such cases either the system will have
infinitive solutions or no solution at all; unique solution is impossible under such conditions.
a) A row whose every element other than the one in the constant vector indicates that
there is no solution.
1 0 0 0 b1 
 
0 1 0 0 b2 
  Indicates that the system has no solution, because the fourth row is
0 0 1 0 
b3 
 
0 
b4 
 0 0 0

absurd.
1 0 0 0 2
 
0 1 0 0 3
For example; if your final outcome is  then, the solution set is  because
0 0 1 0 2
 
0 0 0 0 4
of the 4th row.
b) A matrix, which is of different form than (1) indicates that there are unlimited
number of solutions. For example:
1 0 0 0 b1 
 
0 1 0 0 b2    
  Indicate that X1  b1 , X 2  b2 , X 3  2 X 4  b3
0 0 1 2 b3 
 
0 0 0 0 0 
Thus, either X3 or X4 should be free.

1.8. Markov Chain


Markov was a mathematician whose name has been given to a process in which the future
state is completely determined by the present state and not at all by the way the present state
arose.
Assume that there are two companies X and Y that produce and sell the same type of
commodities. They compete for customers and the following change occur due to the
promotional companies.

29
After one period

one
X Y
X 0.4 0.6

Before
period
Y 0.7 0.3

The interpretation of the numbers in the table is very important.


0.4 indicates that 40% of X’s customers before one period remain loyal to X after one period
as well. 0.6 indicates to that 60% of X’s previous customers have now shifted to Y. 0.7
indicates that 70% of Y’s previous customers shifted to X, while 0.3 indicates that 30% Y’s
previous customers remain loyal to Y. Thus, the table represents “transition” of customers
 0.4 0.6 
from one firm to another. The matrix   is called transition matrix
 0.7 0.3 
Note that the rows add to one. (0.4 + 0.6 = 1 and 0.7 + 0.3 = 1)
Let’s assume that the initial market share between X and Y is 0.2 and 0.8. That is, 20% of the
total market is served by X, while 80% of the market is controlled by Y. Given the above
transition matrix their relative market share after one period, two periods, three periods, etc.
will be:
Initial state (0.2 0.8)
 0.4 0.6 
After one period (0.2 0.8)     0.64 0.36 
 0.7 0.3 

 0.4 0.6 
After two periods (0.64 0.36)   = (0.508 0.492)
 0.7 0.3 

 0.4 0.6 
After three periods (0.508 0.492)   = (0.5476 0.4428)
 0.7 0.3 

 0.4 0.6 
After four periods (0.5476 0.4428)   = (0.60236 0.39852)
 0.7 0.3 
This process is called Markov Process. Note our transition matrix in this example has been
constant as we moved from a state to state. Such a process is called stationary Markov
process.
If this process is repeated for infinite number of times, will the relative share of the two
companies change from state to state or will they maintain an equilibrium after which no

30
change in relative share occurs despite the transition matrix? The answer is, there is an
equilibrium state known as a steady state, where no change takes place in relative share
despite or transition in customers.
At the steady state:
 0.4 0.6 
(X , Y)   = (X , Y)
 0.2 0.3 
Where; X and Y are the market shares of X and Y at the steady state. Thus, solving

X+Y=1 , by definition
0.4x + 0.2y = X by matrix multiplication
0.6x + 0.3y = Y by matrix multiplication

Will give us the value of X and Y.


X+Y=1
-0.6x + 0.7y = 0
0.6x – 0.7y = 0

R1  R1  1 1 1
 
10 R2  R2  0.6 0.7 0
 0.6  0.7 0 
R2  R3  R3 

7 R1  R2  R1  1 1 1 
 
6 R1  R2  R2  6 7 0 
R3  R3  0 0 0 

1 R R
3 1 1
13 0 7 
1 R R  
3 2 2  0 13 6 
0 0 0
R3  R3  

31
1 0 7 
 13 
0 1 6 
 13 
 0 0 0 
 
Therefore X = 7/13 = 0.538
Y = 6/13 = 0.462
If the two companies are at this ratio, the given transition matrix will not produce any change.
Example
10% of the population own an automobile and 90% do not. Based on past experience 5
percent of non- owners become owners and 1% of owners become non-owners each year.
a) What will be the percent of owners and non-owners next year?
b) What is the steady state?
Solution:
The transition table will be

O N
O 0.99 0.01
N 0.05 0.95

 0.99 0.01 
Wherefore, the transition matrix is  
 0.05 0.95 
a) Initial state 0.1 0.9
 0.99 0.01 
After one year (0.1 0.9)   = (0.144 0.864)
 0.05 0.95 
That is, next year 14.4% of the population will own an automobile while 86.4% will not have
any.
b) To calculate the steady state
 0.99 0.01 
(X1 X2)   = (X1 X2),
 0.05 0.95 
where X1 is the percent that own and X2 that do not.

32
X1 + X2 = 1 X1 = 1/6 = 0.17
0.99X1 + 0.05X2 = X1 X2 = 5/6 = 0.83
0.01X1 + 0.95X2 = X2
A chain in which one totally absolves the other is called Absorbing Markov chain.
Example:
Assume that, in a year, 0.01% of the non-drug-abusers become abusers but all the abusers
remain abusers.
What will be the steady state?
Answer:
 1 0
X Y   X Y .
 0.01 0.99 
Where: X-Drug abusers, Y- Non- abusers.
The outcome will be (1 0), all will be drug abusers at the steady state.

1.9. Input-Output Analysis (Introductory)


The input-output analysis, initially developed by professor W. Leontief (an American
economist of Russian origin), is another import application of matrix algebra. Input-output
analysis describes the economy as flow of goods and services between the different sectors of
the economy plus the final consumption. Thus, by adjusting the transition matrix (here it is
called the technical coefficient matrix) the planner can achieved the required proportion
between the different sectors of the economy.
Consider, for example, the following input-output model for a closed economy which consists
of three sectors only –agriculture, industry and services.

Input
Agriculture Industry Service Final Consumption
Agriculture 0.2 0.2 0.3 0.3
Out put

Industry 0.3 0.2 0.2 0.3


Service 0.1 0.1 0.2 0.6
Labor 0.7 0.1 0.2

33
Meanings of the numbers:
Of the total agricultural output 20% is used as input for the agriculture itself (like in the form
of seed, manure, etc.), 20% is used as input for the industry (like cotton to textile, skin to the
tannery, etc) and 30% is used as input for the service (like for Hotels and Restaurants etc.) and
the remained 30% is directly consumed.
Of the total industrial output 30% is used as input for agriculture (like tractors, fertilizers,
tools, etc), 20% as industrial inputs (like spare parts, energy…etc) 20% for the service (like
machines and tools needed in the service sector, and 30% the industrial out put is directly
consumed.
Likewise, 10% of the service output goes to agriculture in the form of input (like training for
farmers, health service…etc.) 10% to the industry and 20% for the service sector itself. 60%
the service output is consumed directly.
Lastly, 70% of the total labor force is engaged in agriculture, while 10 and 20 percent of it is
engaged in the industry and service respectively.
Now, we can actually run the Markov process to determine the share of each sector in the
national economy.
Then, the task of the planner will be to achieve the required proportion between the three
sectors by adjusting a) the final consumption, b) the labor supply, and c) the technology
matrix.
Example: A hypothetical and simple input-output model of a closed economy is given by the
table below. Calculate the share of agriculture, industry and service at a steady state. Here
final consumption is taken as input as well.
Input
Agriculture Industry Service
Agriculture 0.6 0.2 0.2
Industry 0.3 0.4 0.3
Output

Service 0.2 0.3 0.5

Solution: Let X1 be the share of agriculture


X2 be the share of industry, and
X3 be the share of service

34
 0.6 0.2 0.2 
 
 X1 X2 X3   0.3 0.4 0.3    X 1 X 2 X 3 
 0.2 0.5 
 0.3

X1 + X2 +X3 = 1
0.6X1 + 0.3X2 + 0.2X3 = X1
0.2X1 + 0.4X2 + 0.3X3 = X2
0.2X1 + 0.3X2 + 0.5X3 = X3

X1 + X2 +X3 = 1
-0.4X1 + 0.3X2 + 0.2X3 = 0
0.2X1 - 0.6X2 + 0.3X3 = 0
0.2X1 + 0.3X2 – 0.5X3 = 0

R1  R1  1 1 1 1
4 R1  R2  R2  
 4 3 2 0
2 R1  R3  R3  2 6 3 0
 
2 R1  R4  R4  2 6 3 0

R1  R3  R1  1 1 1 1
R2  6 R3  R2  
 0 7 6 4
R3  8R4  R3  0 8 1 2
 
R2  7 R4  R4  0 1 7 2

55 R1  9 R2  R1  1 9 0 3
R2  R2  
 0 55 0 16 
R3  R3  0 0 55 18 
 
R3  R4  R4  0 0 55 18 

X1 = 21/55 = 0.38
X2 = 16/55 = 0.29
X3 = 18/55 = 0.33

35

You might also like