Matrix Addition and Scalar Multiplicaion: 0, All of Whose Entries Are 0 and The Negative

Download as pdf or txt
Download as pdf or txt
You are on page 1of 26

Operations on matrices

Set of all matrices of size m × n is denoted by Mm,n


As before, for A = (aij ), B = (bij ) ∈ Mm,n and α ∈ R,
A + B := (aij + bij ); αA := (αaij )
Matrix addition and scalar multiplicaion satisfies the
“usual properties”. The zero element is the zero
matrix 0, all of whose entries are 0 and the negative
of a matrix A = (aij ) is the matrix −A = (−aij ).
‘ Transpose’ operation introduced earlier can be
extended to all matrices
AT := (bij ) ∈ Mn,m where bij := aji
Note that (αA + βB)T = αAT + βB T for any α, β ∈ R.
Products of linear maps is not linear (in fact not even
defined), in general. But composites of linear maps
are linear. How does this relate to matrices?
16/45
Composition of Linear Maps and Matrix Multiplication

Question: Let f : Rn → Rm , g : Rp → Rn be linear maps. If


A := Mf and B := Mg then Mf ◦g =?

17/45
Composition of Linear Maps and Matrix Multiplication

Question: Let f : Rn → Rm , g : Rp → Rn be linear maps. If


A := Mf and B := Mg then Mf ◦g =?
f ◦ g is a map of Rp to Rm . For 1 ≤ j ≤ p,
n
!
X
(f ◦ g)(ej ) = f (g(ej )) = f bkj ek
k =1
n n m
!
X X X
= bkj f (ek ) = bkj aik ei
k =1 k =1 i=1
m n
!
X X
= aik bkj ei
i=1 k =1

Thus Mf ◦g = C, where C = P(c ij ) is the m × p matrix


th n
whose (i, j) entry is cij = k =1 aik bkj . We call C the
product of the m × n matrix A and the n × p matrix B,
and write C = AB.
17/45
Basic Properties of Matrix Multiplication
The following properties are readily derived from the
corresponding properties of linear maps and the one-to
-one correspondence between linear maps and matrices.
Assume that the matrices A, B, C are of appropriate sizes
so that all relevant products are defined.
1. Associativity: A(BC) = (AB)C.

18/45
Basic Properties of Matrix Multiplication
The following properties are readily derived from the
corresponding properties of linear maps and the one-to
-one correspondence between linear maps and matrices.
Assume that the matrices A, B, C are of appropriate sizes
so that all relevant products are defined.
1. Associativity: A(BC) = (AB)C.
2. Right and Left Distributivity:
A(B + C) = AB + AC, (B + C)A = BA + CA

18/45
Basic Properties of Matrix Multiplication
The following properties are readily derived from the
corresponding properties of linear maps and the one-to
-one correspondence between linear maps and matrices.
Assume that the matrices A, B, C are of appropriate sizes
so that all relevant products are defined.
1. Associativity: A(BC) = (AB)C.
2. Right and Left Distributivity:
A(B + C) = AB + AC, (B + C)A = BA + CA
3. Multiplicative identity: For any A ∈ Mm,n ,
AIn = A and Im A = A
In particular, if A is a n × n matrix, then AIn = A = In A.

Remark: Matrix multiplication is not commutative in


general, i.e., AB need not equal BA even when both the
products are defined. Exercise: Find examples!
18/45
Basic Properties of Matrix Multiplication
The following properties are readily derived from the
corresponding properties of linear maps and the one-to
-one correspondence between linear maps and matrices.
Assume that the matrices A, B, C are of appropriate sizes
so that all relevant products are defined.
1. Associativity: A(BC) = (AB)C.
2. Right and Left Distributivity:
A(B + C) = AB + AC, (B + C)A = BA + CA
3. Multiplicative identity: For any A ∈ Mm,n ,
AIn = A and Im A = A
In particular, if A is a n × n matrix, then AIn = A = In A.
4. Transpose of Product: (AB)T = B T AT .
Remark: Matrix multiplication is not commutative in
general, i.e., AB need not equal BA even when both the
products are defined. Exercise: Find examples!
18/45
Invertible Maps
Recall the set-theoretic definition of invertible functions.
Let X , Y be sets. A function f : X → Y is said to be
invertible if there exists g : Y → X satisfying
g ◦ f = idX and f ◦ g = idY .
In this case the function g is unique (check!) and it is
called the inverse of f and denoted by f −1 .

19/45
Invertible Maps
Recall the set-theoretic definition of invertible functions.
Let X , Y be sets. A function f : X → Y is said to be
invertible if there exists g : Y → X satisfying
g ◦ f = idX and f ◦ g = idY .
In this case the function g is unique (check!) and it is
called the inverse of f and denoted by f −1 .
For any function f : X → Y ,
f is invertible ⇐⇒ f is one-one and onto.
If f : Rn → Rn is an invertible linear map, then f −1 is
linear. [To see this, let y1 , y2 ∈ Rn . Then there are
x1 , x2 ∈ Rn such that f (xi ) = yi , i.e., xi = f −1 (yi ) for
i = 1, 2. Thus f −1 (y1 + y2 ) = f −1 (f (x1 ) + f (x2 )) and
using the linearity of f , we find that this is equal to
f −1 (f (x1 + x2 )) = x1 + x2 = f −1 (y1 ) + f −1 (y2 ).
Similarly f −1 preserves scalar multiplication. 19/45
Invertible Matrices
A square matrix A of size n × n is said to be invertible if
there exists an n × n matrix B such that AB = BA = In .
If such a matrix B exists, then it is unique.

20/45
Invertible Matrices
A square matrix A of size n × n is said to be invertible if
there exists an n × n matrix B such that AB = BA = In .
If such a matrix B exists, then it is unique. Indeed, if C is
another matrix such that CA = AC = In , then
C = CIn = C(AB) = (CA)B = In B = B.
We thus call B to be the inverse of A and denote it by A−1 .
Note that if fA , fB : Rn → Rn are the linear maps associated
with A, B resp., then B = A−1 implies that fB = fA−1 .

20/45
Invertible Matrices
A square matrix A of size n × n is said to be invertible if
there exists an n × n matrix B such that AB = BA = In .
If such a matrix B exists, then it is unique. Indeed, if C is
another matrix such that CA = AC = In , then
C = CIn = C(AB) = (CA)B = In B = B.
We thus call B to be the inverse of A and denote it by A−1 .
Note that if fA , fB : Rn → Rn are the linear maps associated
with A, B resp., then B = A−1 implies that fB = fA−1 .
Basic Properties/Examples:
If A1 , A2 are invertible, then so is A1 A2 .

20/45
Invertible Matrices
A square matrix A of size n × n is said to be invertible if
there exists an n × n matrix B such that AB = BA = In .
If such a matrix B exists, then it is unique. Indeed, if C is
another matrix such that CA = AC = In , then
C = CIn = C(AB) = (CA)B = In B = B.
We thus call B to be the inverse of A and denote it by A−1 .
Note that if fA , fB : Rn → Rn are the linear maps associated
with A, B resp., then B = A−1 implies that fB = fA−1 .
Basic Properties/Examples:
If A1 , A2 are invertible, then so is A1 A2 . What is its
inverse?

20/45
Invertible Matrices
A square matrix A of size n × n is said to be invertible if
there exists an n × n matrix B such that AB = BA = In .
If such a matrix B exists, then it is unique. Indeed, if C is
another matrix such that CA = AC = In , then
C = CIn = C(AB) = (CA)B = In B = B.
We thus call B to be the inverse of A and denote it by A−1 .
Note that if fA , fB : Rn → Rn are the linear maps associated
with A, B resp., then B = A−1 implies that fB = fA−1 .
Basic Properties/Examples:
If A1 , A2 are invertible, then so is A1 A2 . What is its
inverse? Ans: (A1 A2 )−1 = A−1 −1
2 A1 .

20/45
Invertible Matrices
A square matrix A of size n × n is said to be invertible if
there exists an n × n matrix B such that AB = BA = In .
If such a matrix B exists, then it is unique. Indeed, if C is
another matrix such that CA = AC = In , then
C = CIn = C(AB) = (CA)B = In B = B.
We thus call B to be the inverse of A and denote it by A−1 .
Note that if fA , fB : Rn → Rn are the linear maps associated
with A, B resp., then B = A−1 implies that fB = fA−1 .
Basic Properties/Examples:
If A1 , A2 are invertible, then so is A1 A2 . What is its
inverse? Ans: (A1 A2 )−1 = A−1 −1
2 A1 .
Clearly In and more generally, any diagonal matrix
diag(a1 , a2 , . . . , an ) with ai 6= 0 for all i
is invertible; diag(a1 , . . . , an )−1 = diag(1/a1 , . . . , 1/an ).
20/45
Elementary Matrices
Consider a m × m matrix Eij whose (i, j)th entry is 1
and all other entries are 0.

21/45
Elementary Matrices
Consider a m × m matrix Eij whose (i, j)th entry is 1
and all other entries are 0.
If we multiply a m × n matrix A by Eij on the left, then
what we get is a m × n matrix whose i th row is equal
to the j th row of A and all other rows are zero.

21/45
Elementary Matrices
Consider a m × m matrix Eij whose (i, j)th entry is 1
and all other entries are 0.
If we multiply a m × n matrix A by Eij on the left, then
what we get is a m × n matrix whose i th row is equal
to the j th row of A and all other rows are zero.
In particular, if i 6= j, then Eij Eij = 0 and so for any α,
(I + αEij )(I − αEij ) = I + αEij − αEij − α2 Eij Eij = I.

21/45
Elementary Matrices
Consider a m × m matrix Eij whose (i, j)th entry is 1
and all other entries are 0.
If we multiply a m × n matrix A by Eij on the left, then
what we get is a m × n matrix whose i th row is equal
to the j th row of A and all other rows are zero.
In particular, if i 6= j, then Eij Eij = 0 and so for any α,
(I + αEij )(I − αEij ) = I + αEij − αEij − α2 Eij Eij = I.
On the other hand, if i = j, then
(I + αEii ) = diag(1, . . . , 1, 1 + α, 1, . . . , 1)
and this is invertible if α 6= −1.

21/45
Elementary Matrices
Consider a m × m matrix Eij whose (i, j)th entry is 1
and all other entries are 0.
If we multiply a m × n matrix A by Eij on the left, then
what we get is a m × n matrix whose i th row is equal
to the j th row of A and all other rows are zero.
In particular, if i 6= j, then Eij Eij = 0 and so for any α,
(I + αEij )(I − αEij ) = I + αEij − αEij − α2 Eij Eij = I.
On the other hand, if i = j, then
(I + αEii ) = diag(1, . . . , 1, 1 + α, 1, . . . , 1)
and this is invertible if α 6= −1.
Matrices of the type I + αEij , with α ∈ R and i 6= j or
of the type I + αEii with α 6= −1 provide simple
examples of invertible matrices whose inverse is of a
similar type. These are two among 3 possible types
of elementary matrices. 21/45
The third remaining type of elementary matrix and its
basic propery is described in the following easy exercise.
Exercise: Given any i 6= j, show that the square matrix
Tij := I + Eij + Eji − Eii − Ejj
is precisely the matrix obtained from the identity matrix by
interchanging the i th and j th rows. Also show that Tij Tij = I
and deduce that Tij is invertible and Tij−1 = Tij .
A square matrix is said to be elementary if it of the type
Tij (i 6= j) or I + αEii (α 6= −1) or I + αEij (i 6= j).
Thanks to the discussion in the last slide and the exercise
above, we have the following result.

22/45
The third remaining type of elementary matrix and its
basic propery is described in the following easy exercise.
Exercise: Given any i 6= j, show that the square matrix
Tij := I + Eij + Eji − Eii − Ejj
is precisely the matrix obtained from the identity matrix by
interchanging the i th and j th rows. Also show that Tij Tij = I
and deduce that Tij is invertible and Tij−1 = Tij .
A square matrix is said to be elementary if it of the type
Tij (i 6= j) or I + αEii (α 6= −1) or I + αEij (i 6= j).
Thanks to the discussion in the last slide and the exercise
above, we have the following result.
Theorem
Every elementary matrix is invertible and its inverse is an
elementary matrix of the same type.
22/45
Permutation Matrices
Let n be a positive integer. A permutation of
1, 2, . . . , n is a one-one and onto mapping of the set
{1, 2, . . . , n} onto itself.

23/45
Permutation Matrices
Let n be a positive integer. A permutation of
1, 2, . . . , n is a one-one and onto mapping of the set
{1, 2, . . . , n} onto itself.
Associated to a permutation σ of {1, 2, . . . , n}, we
define a n × n matrix Pσ = (pij ) as follows.

0 if i 6= σ(j)
pij =
1 if i = σ(j)
This is called a permutation matrix assoicated to σ.

23/45
Permutation Matrices
Let n be a positive integer. A permutation of
1, 2, . . . , n is a one-one and onto mapping of the set
{1, 2, . . . , n} onto itself.
Associated to a permutation σ of {1, 2, . . . , n}, we
define a n × n matrix Pσ = (pij ) as follows.

0 if i 6= σ(j)
pij =
1 if i = σ(j)
This is called a permutation matrix assoicated to σ.
A permutation matrix is obtained by shuffling the rows
of the identity matrix (or by shuffling the columns).

23/45
Permutation Matrices
Let n be a positive integer. A permutation of
1, 2, . . . , n is a one-one and onto mapping of the set
{1, 2, . . . , n} onto itself.
Associated to a permutation σ of {1, 2, . . . , n}, we
define a n × n matrix Pσ = (pij ) as follows.

0 if i 6= σ(j)
pij =
1 if i = σ(j)
This is called a permutation matrix assoicated to σ.
A permutation matrix is obtained by shuffling the rows
of the identity matrix (or by shuffling the columns).
If A is a permutation matrix, then
AAT = AT A = In .
In particular, permutation matrices are invertible.
23/45

You might also like