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

Matrices 2

The document defines and describes various types of matrices including square, triangular, diagonal, identity, zero and transpose matrices. It also covers matrix operations such as addition, subtraction and multiplication. Matrix addition and subtraction involve adding or subtracting the corresponding elements of matrices of the same size. Matrix multiplication requires the number of columns of the first matrix to equal the rows of the second matrix. Multiplying a matrix by a scalar involves multiplying each element of the matrix by the scalar value.

Uploaded by

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

Matrices 2

The document defines and describes various types of matrices including square, triangular, diagonal, identity, zero and transpose matrices. It also covers matrix operations such as addition, subtraction and multiplication. Matrix addition and subtraction involve adding or subtracting the corresponding elements of matrices of the same size. Matrix multiplication requires the number of columns of the first matrix to equal the rows of the second matrix. Multiplying a matrix by a scalar involves multiplying each element of the matrix by the scalar value.

Uploaded by

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

Algebra of matrices

 Matrices
 Types of matrices
 Operations of matrices
 Properties of matrices
 Determinants
 Inverse of a matrix
Why use it?
 Matrix algebra makes mathematical
expression and computation easier. Ex
solve systems of linear eqns.
 It allows you to get rid of cumbersome
notation, concentrate on the concepts
involved and understand where your results
come from.
Where we use matrices cont…
 In economics: input-output analysis,
 Insurance/Social protection: Pricing products
 Banking: Portfolio analysis
 In statistics: forecasting, time series
 In survival model: Application of Markov
processes
 Computer graphics: store inventory data,
transportation routing for storing connections,
etc
 Engineering, geology, etc
Definitions - Matrix
 A matrix is an array of numbers enclosed by a
pair of brackets.

A=  a11 a12 a13 


a 21 a 22 a 23
 
 Denoted with a bold Capital letter
 All matrices have an order (or dimension):
that is, the number of rows  the number of
columns. So, A is 2 by 3 or (2  3).
Definitions cont...
1 3 1 
2 3 7
A  B   2 1 4
 1 1 5   4 7 6 

Both A and B are examples of matrix.


A is of order 2 x 3 and B is order 3 x 3

Why matrix?

5
Matrices cont…..
 numbers aij are called elements. First
subscript indicates the row; second
subscript indicates the column. The matrix
consists of mn elements
 It is called “the m  n matrix A = [aij]” or
simply “the matrix A ” if number of rows
and columns are understood.
What is it?
 Matrix algebra is a means of making
calculations upon arrays of numbers (or
data).
 Most data sets are matrix-type
Types of Matrices
A square matrix is a matrix that has the
same number of rows and columns (n  n)
When m = n,  a11 a12  a1n 
a a2 n 
i.e., A   21
 
a22 


 
 an1 an 2 ann 

A is called a “square matrix of order n” or


“n-square matrix”
elements a11, a22, a33,…, ann called diagonal
elements.
n

 a
i 1
ii  a11  a22  ...  ann
is called the trace of 8
Types cont...
Row matrix

 A matrix with single row, it is called a row


matrix, i.e.,

A= 1 2 3 4 5

9
Types cont...
Column matrix

 A matrix with single column, it is called a


column matrix, i.e.,

1 
B=  2
 3
 4
5

10
Types cont...
Equal matrices

Two matrices A = [aij] and B = [bij] are said to


be equal (A = B) iff each element of A is equal
to the corresponding element of B, i.e., aij = bij
for 1  i  m, 1  j  n.
iff pronouns “if and only if”
if A = B, it implies aij = bij for 1  i  m, 1  j  n;
if aij = bij for 1  i  m, 1  j  n, it implies A = B.
11
Equal matrices cont....

 1 0 a b 
Example: A  and B 
  4 2   c d 
Given that A = B, find a, b, c and d.

if A = B, then a = 1, b = 0, c = -4 and d = 2.

12
Types cont….
Triangular matrix

 A square matrix whose elements aij = 0, for


i > j is called upper triangular, i.e., a11 a12  a1n 
0 a22 a2 n 

   
 
0 0 ann 

A square matrix whose elements aij = 0, for i


< j is called lower triangular, i.e.,  a11 0  0 
a a22 0 
 21
   
 
 an1 an 2 ann 
13
Types cont...
Diagonal matrix

Both upper and lower triangular, i.e., aij = 0, for


i  j , i.e.,  a11 0  0 
0 a22 0 
D
   
 
0 0 ann 

is called a diagonal matrix, simply


D  diag[a11 , a22 ,..., ann ]

14
Types cont...
Scalar matrix

Is a diagonal matrix with equal diagonal


entries.

 3 0 0
 0 3 
A  0 
 0 0  3

15
Types cont...
Identity matrix

Is diagonal matrix with ones on the diagonal


In particular, a11 = a22 = … = ann = 1, the
matrix is called identity matrix.
Properties: AI = IA = A

Examples of identity matrices:


1 0 0
1 0 0
0 1 0 
 1  
I2 = I3 =  0 0 1 
16
Types cont...
Zero matrices

Every element of a matrix is zero, it is called a


zero matrix, i.e.,
0 0  0 
0 0 0 
A 
  
 
 0 0 0 

17
Types cont..
The transpose of a matrix -Not really type!!

The matrix obtained by interchanging the


rows and columns of a matrix A is called the
transpose of A (write AT).

1 2 3
A 
Example:  4 5 6  1 4
The transpose of A is AT   2 5 
 3 6 

For a matrix A = [aij], its transpose AT = [aji], for


all i and j
18
Types cont...
Symmetric matrix and Skew – symmetric matrix

A matrix A such that AT = A is called symmetric,


i.e., aji = aij for all i and j.
A + AT must be symmetric. Why?
1 2 3 
Example: A   2 4 5 is symmetric.
 3 5 6 

A matrix A such that AT = -A is called skew-


symmetric, i.e., aji = -aij for all i and j.
A - AT must be skew-symmetric. Why? 19
Powers of matrices

 Matrix multiplication can also be written in


exponent form.
 This requires that we have a square matrix.
Like real number multiplication and
exponents.

2 3 2 n 1 n
A  A. A, A  A A.......... A  A A
Submatrix
 A matrix obtained by deleting some of the
rows and/or columns of a matrix is said to
be a submatrix of the given matrix.

1 4 5 
 For example , if A   
0 1 2
 Then
1 
1 , 2,  , 1 5, 0 2
0
 Are few submatrices of A.
Submatrices cont…..
1 4  1 4 
A    and A   
1 0  0 2 

 Are not submatrices of A. (Students


advised to give reasons)
Example : Application

Three friends Asha, Benjamin & Chacha write


to each other from time to time. Last year Asha
received a letter from Benjamin and 5 letters
from Chacha. Benjamin received 2 letter from
Asha and 3 from Chacha, and Chacha received a
letter from Asha and 6 from Benjamin.
Task: (a) Summarize the information in matrix
form.
(b) Who wrote the most letters last year??.
Matrix Operations
 Addition and Subtraction
 Multiplication
 Inversion
Addition and Subtraction
 Two matrices may be added (or subtracted)
iff they are of the same order.

 Simply add (or subtract) the corresponding


elements. So, A + B = C yields
Addition and Subtraction (cont.)
a11 a12   b11 b12  c11 c12 
a a   b b   c c 
 21 22   21 22   21 22 

a31 a32  b31 b32  c31 c32 

Where a11  b11  c11


a12  b12  c12
a21  b21  c 21
a22  b22  c 22
a31  b31  c31
a32  b32  c32
Matrix Multiplication
 To multiply a scalar times a matrix, simply
multiply each element of the matrix by the
scalar quantity

 a11 a12   ka11 ka12 


k 
a21 a22  ka21 ka22 

Matrix Multiplication (cont.)
 To multiply a matrix times a matrix, we
write
• AB (A times B)
 This is pre-multiplying B by A, or post-
multiplying A by B.
Matrix Multiplication (cont.)
 In order to multiply matrices, they must be
CONFORMABLE
 that is, the number of columns in A must
equal the number of rows in B
 So,
A  B = C
(m  n)  (n  p) = (m  p)
Matrix Multiplication (cont.)
 (m  n)  (p  n) = cannot be done
 (1  n)  (n  1) = a scalar (1x1)
Matrix Multiplication (cont.)
 Thus
a11 a12 a13   b11 b12  c11 c12 
a a a  x b b   c c 
 21 22 23   21 22   21 22 
a31 a32 a33  b31 b32  c31 c32 
 where
c11  a11b11  a12 b21  a13b31
c12  a11b12  a12 b22  a13b32
c 21  a21b11  a22 b21  a23b31
c 22  a21b12  a22 b22  a23b32
c31  a31b11  a32 b21  a33b31
c32  a31b12  a32 b22  a33b32
Matrix Multiplication- an
example
 Thus
1 4 7 1 4 c11 c12  30 66
2 5 8 x 2 5  c c   36 81
     21 22   
3 6 9 3 6 c31 c32  42 96
 where
c11  1 * 1  4 * 2  7 * 3  30
c12  1 * 4  4 * 5  7 * 6  66
c 21  2 * 1  5 * 2  8 * 3  36
c 22  2 * 4  5 * 5  8 * 6  81
c31  3 * 1  6 * 2  9 * 3  42
c32  3 * 4  6 * 5  9 * 6  96
The Determinant of a Matrix
 Each n–square matrix A = [aij] is assigned a
special scalar called the determinant of A,
denoted by | A | (or det (A)).
 Determinants exist only for square matrices.
 They have a matrix characteristics.
 A matrix A is said to be a singular matrix if
det(A ) = 0. It is called non-singular if
det(A ) ≠ 0.
Why determinants???

 We use determinants in solving equations, to


find an inverse of a matrix etc.
The Determinant for a 1x1, 2x2, 3x3
and n x n matrices
Properties of Determinates
 Determinants have several mathematical
properties which are useful in matrix
manipulations.
1 |A|=|A'|.
2. If a row or column of A = 0, then |A|= 0.
3. If every value in a row or column is multiplied by k,
then |A| = k|A|.
4. If two rows (or columns) are interchanged the sign,
but not value, of |A| changes.
5. If two rows or columns are identical, |A| = 0.
6. If two rows or columns are linear combination of
each other, |A| = 0
Properties of Determinants
7. |A| remains unchanged if each element of a row
or each element multiplied by a constant, is
added to any other row.
8. |AB| = |A| |B|
9. Det of a diagonal matrix = product of the
diagonal elements
Minors
th
 The (n 1) order determinant formed by
deleting i th row and j th column.
 This determinant of order (n 1) is known as
the minor of and is denoted by M ij

 Example a a a 
11 12 13
 
A  a21 a22 a23 
a31 a32 a33 
 

a 22 a 23
M 11 
a32 a33
Minors cont…
 4 7 8
If A = -9 0 0  , then
 2 3 4

M11 = Minor of a11 0 0


= =0
3 4

4 7
Similarly, M23 = Minor of a23 = = 12 -14 = -2
2 3

4 8
M32 = Minor of a32 = = 0+72 = 72 etc.
-9 0
cij   M ij Cofactors
Cofactor of an element cij is a signed minor,
mathematically obtained as:
i+ j
Cij = Cofactor of aij in A = -1 Mij ,

where Mij is minor of aij in A

Note: If i+j is even then, cij  M ij

If i+j is odd then, cij   M ij


Cofactors (Con.)
 4 7 8
A = -9 0 0 
 2 3 4 
0 0
C11 = Cofactor of a11 = (–1)1 + 1 M11 = (–1)1 +1 =0
3 4

4 7
C23 = Cofactor of a23 = (–1)2 + 3 M23 =  2
2 3

4 8
C32 = Cofactor of a32 = (–1)3 + 2M32 =- = - 72 etc.
-9 0
Cofactors (Con.)
 4 7 8
A = -9 0 0 
 2 3 4 
0 0
C11 = Cofactor of a11 = (–1)1 + 1 M11 = (–1)1 +1 =0
3 4

4 7
C23 = Cofactor of a23 = (–1)2 + 3 M23 =  2
2 3

C32 = Cofactor of a32 = (–1)3 + 2 M32 = - 4 8 = - 72


-9 0
Adjoint
 Then the adjoint of A , denoted by Adj(A) is
defined as the transposed cofactor matrix.
 Adj(A)= C t
 Example find Adj(A)
1 2 3
A 
 2 3 2 


3 3 4 
Laplace expansion
 For example, arbitrarily selecting row i and
column j respectively, the determinant can
be computed by:
n
A   (
j 1
1) i j
aij M ij
n
A   ( 1)
i 1
i j
aij M ij
The Inverse of a Matrix (A-1)
 Is a square matrix that satisfies the equations
BA  AB  I n
 IOWs: For an n  n matrix A, there may be a B
such that BA = I = AB. where B is A-1
 The inverse is analogous to a reciprocal
 A matrix which has an inverse is nonsingular.
 A matrix which does not have an inverse is
singular.
 An inverse exists only if A  0
Inverse of matrix cont…
 Generally inverse of a square matrix is
given by 1 Adj( A)
A  , for all A  0
A
 That is for inverse to exist determinant of a
matrix must be non zero.
Inverse cont….
For any 2x2 or order 2 matrix  a11 a12 
A
 a21 a22 

1  a22 a12 
Its inverse can be written as 1
A   a
A  21 a11 

 1 0 
Example: Find the inverse of A 
 1 2 

The determinant of A is -2
 1 0 
Hence, the inverse of A is 1
A 
1/ 2 1/ 2 
 
47
Inverse of order 3
1 2 3
Consider an example: A   4 5 6 
 7 8 9 
Its determinant can be obtained by:
1 2 3
4 5 1 2 1 2
A  4 5 6 3 6 9
7 8 7 8 4 5
7 8 9
 3  3  6  6   9  3  0

48
Inverse cont…
1 2 3 
Cofactor matrix of A  0 4 5 
1 0 6 
The cofactor for each element of matrix A:
4 5 0 5 0 4
A11   24 A12   5 A13   4
0 6 1 6 1 0

2 3 1 3 1 2
A21   12 A22  3 A23   2
0 6 1 6 1 0

2 3 1 3 1 2
A31   2 A32    5 A33  4
4 5 0 5 0 4
49
Inverse cont….
1 2 3 
Cofactor matrix of A  0 4 5  is then given by:
1 0 6 

 24 5 4 
 12 3 2 
 
 2 5 4 
50
Inverse cont….
1 2 3 
Inverse matrix of A  0 4 5  is given by:
1 0 6 

T
 24 5 4   24 12 2 
1 1   1  
A   12 3 2  5 3  5
A  22  
 2 5 4   4 2 4 

 12 11  6 11 1 11 
  5 22 3 22 5 22 
  2 11 1 11 2 11 
51
Properties of inverse matrices
 AB  1
 B A-1 -1

'

A' 
1
 A -1

 A 
-1 1
 A
For example,
 a = [1 21 12] and b = [1/3 7 4] are
linearly dependent

 A matrix A of dimension n  p (p < n) is of


rank p. Then A has maximum possible rank
and is said to be of full rank.
 In general, the maximum possible rank of an n
 p matrix A is min(n,p).
Reference
 Olver, P.J. and Shakiban, C. (2005)  Applied Linear
Algebra, Prentice Hall.
 Strang, G. (2005) Linear Algebra and its Applications, 4th
Edition, Thomson Publishing.
 Lay, D. C. Lay, S. R. and McDonald, J.J (2015) Linear
Algebra and its Applications, 5th Edition. Addison Wesley.
 Kolman, B. and Hill, D.R. (1993) Introductory Linear
Algebra with Applications, 6th Edition. MacMillan Publishing
Company.
 

You might also like