Lecture 06
Lecture 06
Matrices
E. Mujuni
Notation
Definition
Two matrices A and B are equal if they are the same order and
aij = bij for all i and j.
Introduction Matrix Operations Special Matrices
Notation
Definition
Two matrices A and B are equal if they are the same order and
aij = bij for all i and j.
Introduction Matrix Operations Special Matrices
Then
8 11 3
A+B =
7 6 10
and
−6 −7 3
A−B =
1 4 2
but A + C and A − C do not exist.
Introduction Matrix Operations Special Matrices
Then
8 11 3
A+B =
7 6 10
and
−6 −7 3
A−B =
1 4 2
but A + C and A − C do not exist.
Introduction Matrix Operations Special Matrices
Then
8 11 3
A+B =
7 6 10
and
−6 −7 3
A−B =
1 4 2
but A + C and A − C do not exist.
Introduction Matrix Operations Special Matrices
Then
8 11 3
A+B =
7 6 10
and
−6 −7 3
A−B =
1 4 2
but A + C and A − C do not exist.
Introduction Matrix Operations Special Matrices
Then
8 11 3
A+B =
7 6 10
and
−6 −7 3
A−B =
1 4 2
but A + C and A − C do not exist.
Introduction Matrix Operations Special Matrices
Scalar Multiplication
Scalar Multiplication
Scalar Multiplication
Definition
The product C = AB of an m × n matrix A = [aij ] and an r × p matrix
B = [bjk ] is defined only if and only if r = n and then C = [cik ] is
defined as the m × p with the entries
n
X
cik = aij bjk = ai1 b1k + ai2 b2k + . . . + ain bnk
j=1
Introduction Matrix Operations Special Matrices
Definition
The product C = AB of an m × n matrix A = [aij ] and an r × p matrix
B = [bjk ] is defined only if and only if r = n and then C = [cik ] is
defined as the m × p with the entries
n
X
cik = aij bjk = ai1 b1k + ai2 b2k + . . . + ain bnk
j=1
Introduction Matrix Operations Special Matrices
Definition
The product C = AB of an m × n matrix A = [aij ] and an r × p matrix
B = [bjk ] is defined only if and only if r = n and then C = [cik ] is
defined as the m × p with the entries
n
X
cik = aij bjk = ai1 b1k + ai2 b2k + . . . + ain bnk
j=1
Introduction Matrix Operations Special Matrices
Definition
The product C = AB of an m × n matrix A = [aij ] and an r × p matrix
B = [bjk ] is defined only if and only if r = n and then C = [cik ] is
defined as the m × p with the entries
n
X
cik = aij bjk = ai1 b1k + ai2 b2k + . . . + ain bnk
j=1
Introduction Matrix Operations Special Matrices
Example
0 1
1 3 4
Given A = and B = 3 8
6 2 5
9 2
Find AB and BA.
Solution
0 1
1 3 4 3 45 33
AB = 8 =
6 2 5 51 32
9 2
0 1 6 2 5
1 3 4
BA = 3 8 = 51 25 52
6 2 5
9 2 21 31 46
Introduction Matrix Operations Special Matrices
Example
0 1
1 3 4
Given A = and B = 3 8
6 2 5
9 2
Find AB and BA.
Solution
0 1
1 3 4 3 45 33
AB = 8 =
6 2 5 51 32
9 2
0 1 6 2 5
1 3 4
BA = 3 8 = 51 25 52
6 2 5
9 2 21 31 46
Introduction Matrix Operations Special Matrices
Example
0 1
1 3 4
Given A = and B = 3 8
6 2 5
9 2
Find AB and BA.
Solution
0 1
1 3 4 3 45 33
AB = 8 =
6 2 5 51 32
9 2
0 1 6 2 5
1 3 4
BA = 3 8 = 51 25 52
6 2 5
9 2 21 31 46
Introduction Matrix Operations Special Matrices
(a) AB 6= BA in general
(e) A(B + C) = AB + AC
(f) (A + B)C = AC + BC
Introduction Matrix Operations Special Matrices
(a) AB 6= BA in general
(e) A(B + C) = AB + AC
(f) (A + B)C = AC + BC
Introduction Matrix Operations Special Matrices
(a) AB 6= BA in general
(e) A(B + C) = AB + AC
(f) (A + B)C = AC + BC
Introduction Matrix Operations Special Matrices
(a) AB 6= BA in general
(e) A(B + C) = AB + AC
(f) (A + B)C = AC + BC
Introduction Matrix Operations Special Matrices
(a) AB 6= BA in general
(e) A(B + C) = AB + AC
(f) (A + B)C = AC + BC
Introduction Matrix Operations Special Matrices
(a) AB 6= BA in general
(e) A(B + C) = AB + AC
(f) (A + B)C = AC + BC
Introduction Matrix Operations Special Matrices
Power of a Matrix
Integer powers of a matrix, e.g. A2 , A3 etc, are obtained by
multiplying A by itself the required number of times.
That is, A2 = AA and A3 = AAA = AA2 or A3 = A2 A
Transpose of a Matrix
The transpose of a matrix A, denoted AT is the matrix obtained
when the rows and columns
of A are interchanged.
6 3 5
For example, if A =
4 7 2
6 4
then AT = 3 7
5 2
Clearly (A ) = A and (AB)T = B T AT
T T
Introduction Matrix Operations Special Matrices
Power of a Matrix
Integer powers of a matrix, e.g. A2 , A3 etc, are obtained by
multiplying A by itself the required number of times.
That is, A2 = AA and A3 = AAA = AA2 or A3 = A2 A
Transpose of a Matrix
The transpose of a matrix A, denoted AT is the matrix obtained
when the rows and columns
of A are interchanged.
6 3 5
For example, if A =
4 7 2
6 4
then AT = 3 7
5 2
Clearly (A ) = A and (AB)T = B T AT
T T
Introduction Matrix Operations Special Matrices
Power of a Matrix
Integer powers of a matrix, e.g. A2 , A3 etc, are obtained by
multiplying A by itself the required number of times.
That is, A2 = AA and A3 = AAA = AA2 or A3 = A2 A
Transpose of a Matrix
The transpose of a matrix A, denoted AT is the matrix obtained
when the rows and columns
of A are interchanged.
6 3 5
For example, if A =
4 7 2
6 4
then AT = 3 7
5 2
Clearly (A ) = A and (AB)T = B T AT
T T
Introduction Matrix Operations Special Matrices
Power of a Matrix
Integer powers of a matrix, e.g. A2 , A3 etc, are obtained by
multiplying A by itself the required number of times.
That is, A2 = AA and A3 = AAA = AA2 or A3 = A2 A
Transpose of a Matrix
The transpose of a matrix A, denoted AT is the matrix obtained
when the rows and columns
of A are interchanged.
6 3 5
For example, if A =
4 7 2
6 4
then AT = 3 7
5 2
Clearly (A ) = A and (AB)T = B T AT
T T
Introduction Matrix Operations Special Matrices
Power of a Matrix
Integer powers of a matrix, e.g. A2 , A3 etc, are obtained by
multiplying A by itself the required number of times.
That is, A2 = AA and A3 = AAA = AA2 or A3 = A2 A
Transpose of a Matrix
The transpose of a matrix A, denoted AT is the matrix obtained
when the rows and columns
of A are interchanged.
6 3 5
For example, if A =
4 7 2
6 4
then AT = 3 7
5 2
Clearly (A ) = A and (AB)T = B T AT
T T
Introduction Matrix Operations Special Matrices
Power of a Matrix
Integer powers of a matrix, e.g. A2 , A3 etc, are obtained by
multiplying A by itself the required number of times.
That is, A2 = AA and A3 = AAA = AA2 or A3 = A2 A
Transpose of a Matrix
The transpose of a matrix A, denoted AT is the matrix obtained
when the rows and columns
of A are interchanged.
6 3 5
For example, if A =
4 7 2
6 4
then AT = 3 7
5 2
Clearly (A ) = A and (AB)T = B T AT
T T
Introduction Matrix Operations Special Matrices
Power of a Matrix
Integer powers of a matrix, e.g. A2 , A3 etc, are obtained by
multiplying A by itself the required number of times.
That is, A2 = AA and A3 = AAA = AA2 or A3 = A2 A
Transpose of a Matrix
The transpose of a matrix A, denoted AT is the matrix obtained
when the rows and columns
of A are interchanged.
6 3 5
For example, if A =
4 7 2
6 4
then AT = 3 7
5 2
Clearly (A ) = A and (AB)T = B T AT
T T
Introduction Matrix Operations Special Matrices
Special Matrices
Zero Matrix
A zero matrix is a matrix of any size in which every element is
zero.
Identity Matrix
An identity matrix is a square matrix with zeros everywhere
except along the leading diagonal where every element is a 1.
Example,
1 0 0
1 0
and 0 1 0
0 1
0 0 1
For any matrix A there is an identity matrix I such that AI = A.
There is also an identity matrix I such that IA = A. The identity
matrix functions like the number 1 in real arithmetic.
Introduction Matrix Operations Special Matrices
Special Matrices
Zero Matrix
A zero matrix is a matrix of any size in which every element is
zero.
Identity Matrix
An identity matrix is a square matrix with zeros everywhere
except along the leading diagonal where every element is a 1.
Example,
1 0 0
1 0
and 0 1 0
0 1
0 0 1
For any matrix A there is an identity matrix I such that AI = A.
There is also an identity matrix I such that IA = A. The identity
matrix functions like the number 1 in real arithmetic.
Introduction Matrix Operations Special Matrices
Special Matrices
Zero Matrix
A zero matrix is a matrix of any size in which every element is
zero.
Identity Matrix
An identity matrix is a square matrix with zeros everywhere
except along the leading diagonal where every element is a 1.
Example,
1 0 0
1 0
and 0 1 0
0 1
0 0 1
For any matrix A there is an identity matrix I such that AI = A.
There is also an identity matrix I such that IA = A. The identity
matrix functions like the number 1 in real arithmetic.
Introduction Matrix Operations Special Matrices
Special Matrices
Zero Matrix
A zero matrix is a matrix of any size in which every element is
zero.
Identity Matrix
An identity matrix is a square matrix with zeros everywhere
except along the leading diagonal where every element is a 1.
Example,
1 0 0
1 0
and 0 1 0
0 1
0 0 1
For any matrix A there is an identity matrix I such that AI = A.
There is also an identity matrix I such that IA = A. The identity
matrix functions like the number 1 in real arithmetic.
Introduction Matrix Operations Special Matrices
Special Matrices
Diagonal Matrix
A diagonal matrix is a square matrix with zeros everywhere
except along the leading diagonal where there are some
non-zero elements, e.g.
4 0 0
5 0
and 0 6 0
0 2
0 0 0
Special Matrices
Diagonal Matrix
A diagonal matrix is a square matrix with zeros everywhere
except along the leading diagonal where there are some
non-zero elements, e.g.
4 0 0
5 0
and 0 6 0
0 2
0 0 0
Special Matrices
Diagonal Matrix
A diagonal matrix is a square matrix with zeros everywhere
except along the leading diagonal where there are some
non-zero elements, e.g.
4 0 0
5 0
and 0 6 0
0 2
0 0 0
Special Matrices
Symetric Matrix
A symmetric matrix A is a square matrix with the property that
AT = A.
Skew-Symmetrix Matrix
A skew-symmetric matrix A is a square matrix with the property
that AT = −A.
Inverse of a Matrix
The inverse of a matrix A, if it exists, is denoted by A−1. The
inverse A−1 has the property that
AA−1 = A−1 A = I