You are on page 1of 9

Notes for Module 1: Determinants and Matrices

Advanced Engineering Mathematics


Engr. Neil S. Sereño, SOE, BiPSU-Naval Campus
January 2024

Lecture I
1. Matrices
2. Types of Matrices
3. Properties and Operations of Matrices
4. Determinants
5. Inverse of a Matrix
6. Alternative Methods for Matrix Operations

1. Matrices
2 3 7 1 3 1 
A= 
1 −1 5 B =  2 1 4
 4 7 6 

Both A and B are examples of matrices. Matrix is a rectangular array of numbers enclosed by a pair of
brackets.

Consider the following set of equations:

 x + y = 7, This system is easily solve algebraically, and the solution is x = 3 and y = 4.



3x − y = 5.
The following are the solutions to a system of linear equations:

1. Elimination by addition and/or subtraction.


2. Substitution Method
3. Simultaneous Substitutions
4. Determinants
5. Matrices

For the system given below, solution by elimination and substitution methods were found to be inefficient while
determinants and matrices are more practical, direct and effective.

w + 3x + y − 2 z = 7 
2w − x + 4 y − z = 2

w − x + 3 y − 4z = 1 
3w + x − y − 3z = 5 
In a matrix, the numbers aij are called elements. The first subscript i indicates the row, and the second subscript
j indicates the column. The number a31 is the element of the 3rd row and the first column.

 a11 a12 a1n 


a a22 a2 n 
A =  21
 
  m × n (matrix size)
 am1 am 2 amn 
2 Types of Matrices

Name Description Example

No. of rows is not equal to no. of


 6 2 − 1
Rectangular matrix − 2 0 5 
columns  
 2 − 1 3
No. of rows is equal to no. of − 2 0 1 
Square matrix
columns  
 1 2 4
2 0 0
Non-zero element in principal 0 4 0 
Diagonal matrix diagonal and zero in all other  
positions 0 0 7 
4 0 0
Diagonal matrix in which all the 0 4 0 
Scalar matrix elements on principal diagonal  
and same 0 0 4
Row matrix A matrix with only 1 row 3 2 1 − 4
 2
Column matrix A matrix with only I column  3
 
0 0 
Zero matrix A matrix with all zero entries 0 0 
 
2 5 3
Upper Triangular
Square matrix having all the 0 4 6 
matrix
entries zero below the principal  
diagonal 0 0 7 
2 0 0
Lower Triangular
Square matrix having all the 5 4 0 
matrix
entries zero above the principal  
diagonal 6 3 7 
Two matrices are said to be equal  a b   4 2
iff (if and only if) their  c d  = 1 6 
Equal Matrices
corresponding elements are    
equal. a = 4, b = 2, c = 1 & d = 2
a d 
a b c T 
; A = b e 
The elements of the rows are
Transpose Matrix transposed into elements of the A= 
columns. d e f   c f 
A matrix formed when all
a b  T a c   a − b
Ad-joint Matrix
elements of a transposed matrix A= ;A = ; Adj. AT =  
are replaced by its corresponding c d  b d  − c d 
signed minor element.
The elements of the ad-joint of a

Inverse Matrix
square matrix is divided by the
determinants of the given matrix.
1
A
= A−1 =
1
det . A

Adj. AT 
(Not all square matrices has an
inverse.)
1 0 
I = 
Diagonal matrix having each
Identity matrix
diagonal element equal to one (1)
0 1 
a b  −1 1  a − b
AA −1 = I ; A =   ;A =
When a matrix is multiplied by its c d  det . A − c d 
Identity matrix inverse the product is an identity
a b  1  a − b  1 0
 c d  det . A − c d   = 0 1
matrix.
     

3 Properties and Operations of Matrices


Sums of Matrices
Matrices of the same sizes are said to be conformable for addition and subtraction. Matrices of different
sizes cannot be added or subtracted, e.g., a 3 × 2 matrix cannot be added to or subtracted from a 4 × 3 matrix.

Properties of matrices A, B and C, which are conformable or of the same size:

Commutative Property A+B=B+A


Additive Identity 0+B=B+0
Associative Property A + (B +C) = (A + B) +C
Distributive Property for Scalars (p + q)A = pA + qA
Associative Property for Scalars p(qA) = pqA
Distributive Property for Matrices λ (A + B) = λ A + λ B

Example 1: Given the matrices below,

 4 2 − 1 − 3 0 2
A=  = 7 =
5   2 3
; B ; C
1 6   
find:

a) A + B
b) B – C
c) (A – C) + B

Solution:

4 2 − 1 − 3 3 − 1
a) A + B = 1 6 +  7 5  8 11
=
  
− 1 − 3 0 2 − 1 − 5
b) B – C =  −
5  2 3  5 2 
=
7
 4 2 0 2  − 1 − 3  4 0 − 1 − 3 3 − 3
c) (A – C) + B =   
 1 6  −  2 3  +  7  = − 1 3 +  7  = 6 8  ans.
     5     5   
Product of Matrices
Associative Property (AB)C = A(BC)
Identity Property IB = BI = B
Left Distributive Property A(B +C) = AB + AC
Right Distributive Property (A + B)C = AC + BC
Associative Property for Scalars p(qA) = pqA
Scalar Associative Property λ (A B) = (λ A) + A(λ B)

Scalar Multiplication

Let λ be any scalar and A is an m × n matrix. Then λA is a product matrix where λ is multiplied to
each of the elements of matrix A.

1 0 3 
 
Example 2: Given A = 1 2 3 2 ;  = 3 , find the scalar product A .
 
1 5 4
Solution:

1 0 3   3  1 3  0 3  3   3 0 9 
A = 32 3 2 = 3  2 3  3 3  2 = 6 9 6  ans.
1 5 4  3  1 3  5 3  4 3 15 12

Matrix Multiplication
Matrix multiplication can only be possible iff (if and only if) the matrices to be multiplied are conformable.
That is if the number columns of the first matrix (multiplicand) equals to the number of rows of the second matrix
(multiplier). A matrix of size m × n can be multiplied by matrix of size n × p, then the product matrix is expected
be of size m × p. If a 2 × 3 matrix is multiplied by a 3 × 4 matrix, the product matrix would be of size 2 × 4.

Example 3: Given the matrices

1 3 5
 4 2 − 1 − 3  2 1 4
A=  ;B =   ;C =   ; D = 0 1 2
1 6 22 7 5  22 1 4 7 23 4 1 3 33
Find the following product matrices:
a) AB
b) CD
c) B × (CD)

Solution:

4 2 − 1 − 3 e e 
a) AB =     = E =  11 12 
1 6 22  7 5  22 e21 e22  22
4 2 − 1 − 3 e11 = 4(−1) + 2(7) e12 = 4(−3) + 2(5)
AB =   =
1 6  7 5   e11 = 1(−1) + 6(7) e12 = 1(−3) + 6(5) 
10 − 2
AB = E =   ans.
41 27 

1 3 5 
 2 1 4 f f12 f13 
b) CD =    0 1 2 = F =  11 
1 4 7 23 4 1 3  f 21 f 22 f 23 
  33
 f = 2(1) + 1(0) + 4(4) f12 = 2(3) + 1(1) + 4(1) f13 = 2(5) + 1(2) + 4(3) 
CD = F =  11
 f 21 = 1(1) + 4(0) + 7(4) f 22 = 1(3) + 4(1) + 7(1) f 23 = 1(5) + 4(2) + 7(3)
18 11 24
CD = F =   ans.
29 14 34

− 1 − 3 18 11 24
B  CD = 
5  29 14 34
c)
7
− 1(18) + −3(29) − 1(11) + −3(14) − 1(24) + −3(34)
=
 7(18) + 5(29) 7(11) + 5(14) 7(24) + 5(34) 
− 105 − 53 − 126
=  ans.
 271 147 338 
4 Determinants
A square array of numbers called elements (real or complex) which are contained within two vertical
lines.
The value of the determinant is obtained by the difference of the sum of all downward cross products
minus the sum of all upward cross products.

For an order 2 determinant

a1 b1
A=
a2 b2

det . A = a1b2 − a2b1


For an order 3 determinant
(-) products
a1 b1 c1 a1 b1 c1 a1 b1
B = a2 b2 c2 ; B = a 2 b2 c2 a 2 b2
a3 b3 c3 a3 b3 c3 a3 b3
(+) products

det .B = a1b2 c3 + b1c2 a3 + c1a2b3 − a3b2 c1 − b3c2 a1 − c3 a2b1

det .B = (a1b2 c3 + b1c2 a3 + c1a2b3 ) − (a3b2 c1 + b3c2 a1 + c3 a2b1 )

Co-Factors and Minors


Co-factor element, b3
a1 b1 c1 The sign of the co-factor element depends on the sum of the row
a2 b2 c2 and column numbers; the sign is (+) if the sum is even and (-) if the
sum is odd. Here b3 is at the 3rd row and the 2nd column and so, the
a3 b3 c3
sum is odd and therefore the sign of b3 is negative.
Expanded elements (can be the elements of an entire row or column)

a1 c1
M 32 = The Minor of the third row and the second column.
a2 c2

a1 c1
C32 = −b3 The Co-factor of the 3rd row and 2nd column.
a2 c2

For an order 3 determinant expansion by co-factor method expanding from the elements of the first
row. Co-factor expansion can be performed through the elements of any particular row or column.

a1 b1 c1
a) Expanding the elements of the first row, B = a2 b2 c2
a3 b3 c3
b2 c2 a2 c2 a2 b2
det .B = a1 + (−)b1 + c1
b3 c3 a3 c3 a3 b3
det .B = a1 (b2c3 − b3c2 ) − b1 (a2c3 − a3c2 ) + c1 (a2b3 − a3b2 )
a1 b1 c1
b) Expanding the elements of the second row, B = a2 b2 c2
a3 b3 c3
b1 c1 a1 c1 a1 b1
det .B = (−)a2 + b2 + (−)b2
b3 c3 a3 c3 a3 b3
det .B = −a2 (b1c3 − b3c1 ) + b2 (a1c3 − a3c1 ) − c2 (a1b3 − a3b1 )
a1 b1 c1
c) Expanding the elements of the third row, B = a2 b2 c2
a3 b3 c3
b1 c1 a1 c1 a1 b1
det .B = a3 + (−)b3 + c3
b2 c2 a2 c2 a2 b2
det .B = a3 (b1c2 − b2c1 ) − b3 (a1c2 − a2c1 ) + c3 (a1b2 − a2b1 )

Note: Co-factor expansion is very effective when expanding the elements of any row or column that
has the most 0’s.

Example 4: Find the value of the determinant of the following:

3 1
a) A= (order 2)
4 4
1 3 5
b) E = 0 1 0 (order 3)
4 1 3

Solution:

3 1
a) A=
4 4
det .A = (3  4) − (4 1)

= 12 − 4
det . A = 8 ans.

1 3 51 3
b) E = 0 1 0 0 1 ; by the cross products or Kramer’s Rule
4 1 34 1
det .E = (11 3) + (3 0  4) + (5  0 1) − (4 1 5) − (1 0 1) − (3 0  3)
det .E = 3 − 20 = −17 ans.
1 3 5
c) E = 0 1 0 ; alternate solution/co-factor expansion
4 1 3
Expanding the elements of the 2nd row
1 3 5
3 5 1 5 1 3
E = 0 1 0 ; det .E = (−)(0) + (1) + (−)(0)
1 3 4 3 4 1
4 1 3
1 5
det .E = (1) = 3 − 20 = −17 ans.
4 3
Expanding the elements of the 1st row
1 3 5
1 0 3 5 3 5
E = 0 1 0 ; det .E = (1) + (−)(0) + (4)
1 3 1 3 1 0
4 1 3
1 0 3 5
det .E = (1) + (4) = (1)(3 − 0) + (4)(0 − 5) = 3 − 20 = −17 ans.
1 3 1 0
5 Inverse of a Matrix
If the determinant of an n × n matrix is not equal to zero then, the square matrix is nonsingular and its
inverse exist.

Example 5: Evaluate the inverse of the following matrices if they exist.

3 1
A=
4
a)
4
1 3 5

b) D = 0 1 2

4 1 3

Solution:

3 1 −1 −1 1 0 −1  x1 y1 
A= ; find A . From A  A = I , let I =  and A = 
  y2 
a)
7 4  0 1   x2
3 1  x1 y1  1 0
7 4  x y  = 0 1 , using product of matrices
  2 2  
 3x1 + x2 3 y1 + y2  1 0
7 x + 4 x 7 y + 4 y  = 0 1 , by the property of equal matrices
 1 2 1 2  
3x1 + x2 = 1  3 y1 + y2 = 0 
 → (1) and  → (2)
7 x1 + 4 x2 = 0 7 y1 + 4 y2 = 1

Solving for the elements x1 , x2 , y1 & y2 from the systems of linear equations above gives,

4 7 1 3
x1 = , x2 = − , y1 = − & y2 = . Then,
5 5 5 5
 4 − 1

A−1 =  5 5  = 1 4 − 1 ans.
−7 3  5 −7 3
 
 5 5

Another solution, by the formula A−1 =


1

det . A

Adj. AT .

3 1 3 7  4 − 1
A= ; det . A = 12 − 7 = 5 , A =  , Adj. A = 
T T
  
7 4  1 4 − 7 3 
1  4 − 1
A−1 = 
5 − 7 3 
ans.

1 3 5 
  −1
b) D = 0 1 2 ; find D .
 
4 1 3
1 0 4
−1
D =
1
det .D

T

Adj.D ; det .D = −17 + 22 = 5 ; D = 3 1 1
T

5 2 3
 1 1 3 1 3 1 
 ( −) 
 2 3 5 3 5 2 
1 0 4 1 4 1 0
D −1 = (−) ( −) 
5 2 3 5 3 5 2
 0 4 1 4 1 0 
 1 1 ( −)
 3 1 3 1 
1 −4 1 
D −1 =  8 − 17 − 2 ans.
1
5
− 4 11 1 

6. Alternative Methods for Matrix Operations


For other alternate means to verify the products and inverse of matrices, you can use the MINVERSE and
MMULT functions and the Ctrl+Shift+Enter keys in Microsoft Excel.

1) Open Microsoft Excel


2) Input the elements of the matrix

3) Call the MINVERSE function at the formula bar and highlight the cells which you assigned for the
inverse matrix elements.

4) Press the keys Ctrl+Shift+Enter at the same time

5) In this result, each element of the inverse of matrix A is already divided by the value of its determinant
whose value is 1/5 or 0.2. Factoring out the determinant value gives
For the product of matrix using the MMULT function and the Ctrl+Shift+Enter keys in Microsoft Excel

1) Open Microsoft Excel


2) Input the elements of the matrices to be multiplied

3) Call the MMULT function and obtain the product matrix AB

4) For the product matrix CD

5) For the product matrix CD

Note: For an easy and convenient validation of results regarding matrices and determinants please
download the CalKit App at Play Store for your android gadgets.

You might also like