0% found this document useful (0 votes)
5 views10 pages

Linear Algebra Tutorial: Basis and Transition Matrices

This document contains tutorial exercises for a linear algebra course at the National University of Singapore. It covers topics such as basis formation, transition matrices, and the relationship between row and column spaces. The solutions include detailed calculations and proofs to demonstrate the concepts discussed.

Uploaded by

ongrusselllq
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)
5 views10 pages

Linear Algebra Tutorial: Basis and Transition Matrices

This document contains tutorial exercises for a linear algebra course at the National University of Singapore. It covers topics such as basis formation, transition matrices, and the relationship between row and column spaces. The solutions include detailed calculations and proofs to demonstrate the concepts discussed.

Uploaded by

ongrusselllq
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

NATIONAL UNIVERSITY OF SINGAPORE

Department of Mathematics

MA1522 Linear Algebra for Computing Tutorial 6


     
1 0 0
1. (a) Let u1 =  2 , u2 = 2, u3 = −1. Show that S = {u1 , u2 , u3 } forms a
−1 1 3
3
basis for R .
Solution: We have
1 0 0
2 2 −1 = 7 ̸= 0.
−1 1 3
Thus S = {u1 , u2 , u3 } is a basis for R3 .
 
1
(b) Suppose w = 1. Find the coordinate vector of w relative to S.

1
Solution: We have
     
1 0 0 1 1 0 0 1 1
RREF
 2 2 −1 1  −−−−→  0 1 0 −1/7  ⇒ [w]S = −1/7 .
−1 1 3 1 0 0 1 5/7 5/7
   
1 −1
3
(c) Let T = {v1 , v2 , v3 } be another basis for R where v1 = 5 , v2 =
   3 ,
  4 7
2
v3 = 2. Find the transition matrix from T to S.

4
Solution:
   
1 0 0 1 −1 2 1 0 0 1 −1 2
RREF
 2 2 −1 5 3 2  − −−−→  0 1 0 2 3 0 
−1 1 3 4 7 4 0 0 1 1 1 2
 
1 −1 2
So, the transition matrix P from T to S is P = 2
 3 0 .
1 1 2

(d) Find the transition matrix from S to T .


Solution:  
3/4 1/2 −3/4
Q = P−1 = −1/2 0 1/2  .
−1/8 −1/4 5/8
(e) Use the vector w in Part (b). Find the coordinate vector of w relative to T .
Solution:
    
3/4 1/2 −3/4 1 1/7
[w]T = Q[w]S = −1/2 0 1/2  −1/7 = −1/7 .
−1/8 −1/4 5/8 5/7 5/14

2. Let V be a subspace of Rn and S = {u1 , u2 , u3 } be a basis for a subspace V . Define


T = {v1 , v2 , v3 } where
v1 = u1 + u2 + u3 , v2 = u2 + u3 and v3 = u2 − u3 .
(a) Show that T is a basis for V .
Solution: By construction, vi ∈ V for i = 1, 2, 3, and hence, span(T ) ⊆ V . Next,
|T | = 3 = dim(V ). Finally, suppose

0 = c1 v 1 + c2 v 2 + c3 v 3
= c1 (u1 + u2 + u3 ) + c2 (u2 + u3 ) + c3 (u2 − u3 )
= c1 u1 + (c1 + c2 + c3 )u2 + (c1 + c2 − c3 )u3

Then since S is linearly independent,



 c1 = 0
c1 + c2 + c3 = 0
c1 + c2 − c3 = 0

which has only the trivial solution c1 = c2 = c3 = 0. Hence, T is linearly indepen-


dent. Thus, T is a basis.

(b) Find the transition matrix from S to T .


Solution: Observe that by construction,
     
1 0 0
[v1 ]S = 1 , [v2 ]S = 1 , [v3 ]S =  1  .
1 1 −1
Hence, the transition matrix P from T to S is
 
 1 0 0
P = [v1 ]S [v2 ]S [v3 ]S = 1 1 1  .
1 1 −1
Hence, the transition matrix Q from S to T is
 
1 0 0
Q = P−1 = −1 1/2 1/2  .
0 1/2 −1/2
   
1 −1 1 2
3. (a) Let A =  1 1 −1 and b = 1. Is b in the column space of A?
 
−1 −1 1 0
If it is, express it as a linear combination of the columns of A.

Solution:    
1 −1 1 2 1 0 0 0
 1 1 −1 1  −→  0 1 −1 0  .
−1 −1 1 0 0 0 0 1
Thus b is not a linear combination of the columns of A.
 
1 9 1 
(b) Let A = −1 3 1 and b = 5, 1, −1 . Is b in the row space of A? If it is,
1 1 1
express it as a linear combination of the rows of A.

Solution: Note that b is in the row space of A if and only if bT is in the column
space of AT . Hence we are solving for
   
1 −1 1 5 1 0 0 1
 9 3 1 1  −→  0 1 0 −3  .
1 1 1 −1 0 0 1 1

We get b = (5, 1, −1) = (1, 9, 1) − 3(−1, 3, 1) + (1, 1, 1).


 
1 2 0 1
0 1 2 1 4
(c) Let A = 
1 2 1 3. Is the row space and column space of A the whole R ?

0 1 2 2
Solution:    
1 2 0 1 1 0 0 0
0 1 2 1
  0 1 0 0

1 −→  .
2 1 3 0 0 1 0
0 1 2 2 0 0 0 1
Thus the column space of A is the whole R4 . Since A is invertible if and only if
AT is, the row space must also be the whole R4 .

4. For each of the following matrices A,

(i) Find a basis for the row space of A.


(ii) Find a basis for the column space of A.
(iii) Find a basis for the nullspace of A.
(iv) Hence determine rank(A), nullity(A) and verify the dimension theorem for matri-
ces.
(v) Is A full rank?
 
1 2 5 3
 1 −4 −1 −9
 
−1 0 −3 1 
(a) A =  
2 1 7 0
0 1 1 2
Solution:  
1 0 3 −1
0 1 1 2
 
A −→ 
0 0 0 0.
0 0 0 0
0 0 0 0

(i) A basis for the row space is {(1, 0, 3, −1), (0, 1, 1, 2)}.

(ii) A basis for the column space is {(1, 1, −1, 2, 0)T , (2, −4, 0, 1, 1, )T }.

(iii) A basis for the nullspace is {(−3, −1, 1, 0)T , (1, −2, 0, 1)T }.

(iv) rank(A) = 2, nullity(A) = 2. Since rank(A) + nullity(A) = 2 + 2 = 4 which


is the number of columns of A, we have verified the dimension theorem for
matrices.

(v) rank(A) = 2 < min{4, 5}. A is not full rank.


 
1 3 7
2 1 8
 
(b) A =  3 −5 −1 .

2 −2 2 
1 1 5
Solution:  
1 0 0
0 1 0
 
A −→ 
0 0 1
.
0 0 0
0 0 0

(i) A basis for the row space is {(1, 0, 0), (0, 1, 0), (0, 0, 1)}.

(ii) A basis for the column space is {(1, 2, 3, 2, 1)T , (3, 1, −5, −2, 1)T , (7, 8, −1, 2, 5)T }.

(iii) The basis for the nullspace is the empty set.

(iv) rank(A) = 3, nullity(A) = 0. Since rank(A) + nullity(A) = 3 + 0 = 3 which


is the number of columns of A, we have verified the dimension theorem for
matrices.

(v) rank(A) = 3 = min{3, 5}. A is full rank.


5. Let W be a subspace of R5 spanned by the following vectors
       
1 2 0 2
−2 −5 5 1
       
 0  , u2 −3 , u3 = 15 , u4 = 15 .
u1 =        
0 −2 10 8
3 6 0 6

(a) Find a basis for W .

Solution:    
1 −2 0 0 3 1 0 6 0 3
2 −5 −3 −2 6 RREF 0 1 3 0 0
  −−−−→  
0 5 15 10 0 0 0 0 1 0
2 1 15 8 6 0 0 0 0 0
      

 1 0 0 
0 1 0

      


6 , 3 , 0 forms a basis for W .
     


 0 0 1 
 
3 0 0
 

(b) What is dim(W )?

Solution: From (a), dim(W ) = 3

(c) Extend the basis W found in (a) to a basis for R5 .


          

 1 0 0 0 0 

0 1 0 0 0

          

 5
Solution: From (a),  6 , 3 , 0 , 1 , 0 form a basis for R .
        


 0 0 1 0 0 
 
3 0 0 0 1
 

          

 1 2 −1 0 3 
          
0 −1  3  1 −1

6. Let S =   ,   ,   ,   ,   and V = span(S). Find a subset

 1
 0 5 2 1 

3 1 12 5 4
 
S ′ ⊆ S such that S ′ forms a basis for V .

Solution:    
1 2 −1 0 3 1 0 5 2 1
0 −1 3 1 −1 RREF 0
  1 −3 −1 1

1 0 −−−−→  
5 2 1 0 0 0 0 0
3 1 12 5 4 0 0 0 0 0
    

 1 2 
    
0 −1

Let S ′ =  ,  .
1  0 

 
3 1
 
Extra problems
1. Suppose A and B are two matrices such that AB = 0. Show that the column space of
B is contained in the nullspace of A.

Solution: Write B = b1 b2 · · · bn , where bi is the i-th column of B. Then
 
0 = AB = A b1 b2 · · · bn = Ab1 Ab2 · · · Abn

By comparing the columns, we conclude that Abi = 0 for all i = 1, ..., n. Hence,
bi ∈ Null(A) for all i = 1, ..., n, that is, {b1 , ..., bn } ⊆ Null(A). Since the nullspace
of A is a subspace space and is thus closed under linear combinations, this shows that
Col(B) = span{b1 , ..., bn } ⊆ Null(A).

2. Let A be a n × m matrix and P an n × n matrix.


(a) If P is invertible, show that rank(PA) = rank(A).
Solution: Since P is invertible, we can write P = Ek · · · E1 , for some elementary
matrices E1 , ..., Ek . This means that PA = Ek · · · E1 A, which shows that PA is row
equivalent to A, and therefore they have the same row space, Row(PA) = Row(A).
Thus,
rank(PA) = dim(Row(PA)) = dim(Row(A)) = rank(A)
Alternative Solution. It is a fact that for an a by b matrix X and a b by c matrix Y,
we have
rank(XY) ≤ rank(Y). (*)
Let B = PA. Since P is invertible, we have P−1 B = A. Using the above fact (*),
we get
rank(A) = rank(P−1 B) ≤ rank(B) = rank(PA) ≤ rank(A).
Hence all the inequalities are equalities and we get rank(PA) ≤ rank(A).

(b) Given an example such that rank(PA) < rank(A).


Solution: Let A = In the n × n identity matrix and P = 0n the n × n zero matrix,
for some n ≥ 1. Then

rank(PA) = 0 < rank(A) = n.

(c) If rank(PA) = rank(A). Can we conclude that P is invertible? Justify your answer.
 
1 0 0
Solution: No. For example, let P = A = 0 1 0. Then PA = A and so
0 0 0
rank(PA) = rank(A).
 
3. Let A = a1 a2 · · · an and B = b1 b2 · · · bn be row equivalent m×n matrices,
where ai and bi are the i-th column of A and B, respectively, for i = 1, ..., n. Show that
for any c1 , c2 , ..., cn ∈ R,
c1 a1 + c2 a2 + · · · + cn an = 0
if and only if
c1 b1 + c2 b2 + · · · + cn bn = 0.

Solution: Since A and B are row equivalent, we can write B = Ek · · · E1 A = PA,


where P = Ek · · · E1 , for some elementary matrices E1 , ..., Ek . Then P is invertible.
Moreover,
  
b1 b2 · · · bn = B = PA = P a1 a2 · · · an = Pa1 Pa2 · · · Pan ,
−1
which shows that bi = Pai for i =1, 2, ..., n. Since P is invertible, we have ai = P bi
c1
 c2 
for i = 1, 2, ..., n. We set c =  .. . Then
 
.
cn
 
c1
  c2 

c1 a1 + c2 a2 + · · · + cn an = a1 a2 · · · an  ..  = Ac,

.
cn
 
c1
  c2 

c1 b1 + c2 b2 + · · · + cn bn = b1 b2 · · · bn  ..  = Bc = PAc.

.
cn

We have

c1 a1 + c2 a2 + · · · + cn an = 0
⇔ Ac = 0
⇔ PAc = P0 (because P is invertible.)
⇔ Bc = 0
⇔ c1 b1 + c2 b2 + · · · + cn bn = 0.

4. Let S = {v1 , v2 , . . . , vn } be a basis for a vector space V . Let u be a vector in V and let
c be a scalar. Prove the following:

(a) [u + v]S = [u]S + [v]S .


Solution: We first write u and v in terms of the basis vectors, say

u = c1 v1 + c2 v2 + . . . + cn vn and v = d1 v1 + d2 v2 + . . . + dn vn .

Then
u + v = (c1 + d1 )v1 + (c2 + d2 )v2 + . . . + (cn + dn )vn
which implies
     
c1 + d 1 c1 d1
 c2 + d 2   c2   d 2 
[u + v]S =  ..  =  ..  +  ..  = [u]S + [v]S .
     
 .  . .
cn + d n cn dn

(b) [cu]S = c [u]S .

Solution: Similarly,
  
cc1 c1
 cc2   c2 
cu = (cc1 )v1 + (cc2 )v2 + . . . + (ccn )vn ⇒ [cu]S =  ..  = c  ..  = c [u]S .
   
 .  .
ccn cn

(c) Suppose u1 , u2 , . . . , uk are vectors in V . Note that for each i = 1, 2, . . . , k, [ui ]S is a


vector in Rn . By induction and using (a) and (b), it follows that if c1 , c2 , . . . , ck ∈ R,
then
[c1 u1 + c2 u2 + . . . + ck uk ]S = c1 [u1 ]S + c2 [u2 ]S + . . . + ck [uk ]S .
Prove that {u1 , u2 , . . . , uk } is linearly independent in V if and only if {[u1 ]S ,
[u2 ]S , . . . , [uk ]S } is linearly independent in Rn .

Solution: Assume that {u1 , u2 , . . . , uk } is linearly independent in V . Consider the


equation c1 [u1 ]S + . . . + ck [uk ]S = 0 which is a vector equation in Rn . By part
(c), the equation above can be rewritten as [c1 u1 + c2 u2 + . . . + ck uk ]S = 0. So the
coordinates of c1 u1 + . . . + ck uk with respect to the basis S are all zero, that is,
c1 u1 +. . .+ck uk = 0v1 +0v2 +. . .+0vn = 0. As {u1 , . . . uk } is linearly independent,
the equation above implies c1 = c2 = . . . = ck = 0, so {(u1 )S , . . . , (uk )S } is linearly
independent in Rn .
Conversely, assume {[u1 ]S , . . . , [uk ]S } is a linearly independent set in Rn . Consider
the equation
c1 u1 + c2 u2 + . . . + ck uk = 0
which implies
[c1 u1 + c2 u2 + . . . + ck uk ]S = [0]S = 0,
Using the result in part (c), we have

c1 [u1 ]S + . . . + ck [uk ]S = 0

and this implies that c1 = c2 = . . . = ck = 0 because {[u1 ]S , . . . , [uk ]S } is linearly


independent. Thus we have shown that {u1 , . . . , uk } is a linearly independent set
in V .

You might also like