<<

(c)2015 UM Math Dept licensed under a Creative Commons By-NC-SA 4.0 International License.

Math 217: §2.3 Composition of Linear Transformations Professor Karen Smith1

Inquiry: Is the composition of linear transformations a linear transformation? If so, what is its ?

2 T 3 3 S 2 A. Let −→ R and R −→ R be two linear transformations. 1. Prove that the composition S ◦ T is a linear transformation (using the definition!). What is its source ? What is its target vector space?

2 2 Solution note: The source of S◦T is R and the target is also R . The proof that S◦T is linear: We need to check that S ◦ T respect and also . 2 First, note for any ~x,~y ∈ R , we have

S ◦ T (~x + ~y) = S(T (~x + ~y)) = S(T (~x)) + S(T (~y)) = S ◦ T (~x) + S ◦ T (~y).

Here, the second and third equal signs come from the linearity of T and S, respectively. 2 Next, note that for any ~x ∈ R and any scalar k, we have

S ◦ T (k~x) = S(T (k~x)) = S(kT (~x)) = kS(T (~x)) = kS ◦ T (~x),

so S ◦ T also respects . The second and third equal signs again are justified by the linearity of T and S, respectively. So S ◦ T respects both addition and scalar multiplication, so it is linear.

 1 2  1 0 1 2. Suppose that the matrix of T is A = 0 −1 and the matrix of S is B = .   0 −1 0 −1 3 x Compute explicitly a formula for S(T ( )). y

 x + 2y  x x + 2y + (−x + 3y) 5y Solution note: S ◦ T ( ) = S( −y ) = = y   y y −x + 3y

3. What is S ◦ T (~e1)? S ◦ T (~e2)? 0 5 Solution note: S ◦ T (~e ) = and S ◦ T (~e ) = . 1 0 2 1

4. Find the matrix of the composition S ◦ T . Compare to (2).

0 5 Solution note: . Note that the columns are the vectors we computed in (2). 0 1

1Thanks to Anthony Zheng, Section 5 Winter 2016, for finding numerous errors in the solutions. 5. Compute the matrix BA. Compare to (4). What do you notice?

0 5 Solution note: BA = . The same! 0 1

6. What about T ◦ S? What is its matrix in terms of A and B. Solution note: This is AB.

7. What is the general principle here? Say we have a composition of linear transformations

n TA m TB p R −→ R −→ R given by by matrices A and B respectively. State and prove a precise theorem about the matrix of the composition. Be very careful about the order of multiplication!

n TA m TB p Solution note: Theorem: If R −→ R −→ R are linear transformations given by matrix multiplication by matrices A and B (on the left) respectively, then the composition TB ◦ TA has matrix BA. n Proof: For any ~x ∈ R , we have

TB ◦ TA(~x) = TB(TA(~x)) = TB(A~x) = BA~x = (BA)~x.

Here, every equality uses a definition or property of matrix multiplication (the first is definition of composition, the second is definition of TA, the third is definition of TB, the fourth is the association property of matrix multiplication).

1 a 1 c B. Let A = , and C = . 0 1 d 1 1. Compute AC. Compute CA. What do you notice?

2. Does matrix multiplication satisfy the commutative law?

n n 3. TRUE or FALSE: If we have two linear transformations, S and T , both from R → R , then S ◦ T = T ◦ S.

ad + 1 a + c 1 a + c  Solution note: AC = ,CA = . These are not equal in d 1 d ad + 1 general, so matrix multiplication does not satisfy the commutative law! In particular, linear transformations do not satisfy the commutative law either, so (3) is FALSE. 1 1 An explicit countexample is to let S be left multiplication by , and T be mul- 0 1 1 0 1 1 tiplication by . Then TS is multiplication by , but ST is multiplication 1 1 1 2 2 1 by . These are not the same maps, since for example, they take different values 1 1 on ~e1. n T n C. The identity transformation is the map R −→ R doing nothing: it sends every vector ~x to ~x.A linear transformation T is invertible if there exists a linear transformation S such that T ◦ S is the identity map (on the source of S) and S ◦ T is the identity map (on the source of T ). 1. What is the matrix of the identity transformation? Prove it!

n T m 2. If R −→ R is invertible, what can we say about its matrix?

Solution note: The matrix of the identity transformation is In. To prove it, note that the identity transformation takes ~ei to ~ei, and that these are the columns of the . So the identity matrix is the unique matrix of the identity map. If T is invertible, then the matrix of T is invertible.

Math 217: §2.3 Block Multiplication Professor Karen Smith D. In the book’s Theorem 2.3.9, we see that we can think about matrices in “blocks” (for example, a 4×4 matrix may be thought of as being composed of four 2×2 blocks), and then we can multiply as though the blocks were scalars using Theorem 2.3.4. This is a surprisingly useful result! 1 1 1 1   0 1 0 1 C11 C12 1. Consider the matrix C =  . If we write this as a , C = , 0 0 1 0 C21 C22 0 0 0 1 where all the blocks are the same size, what are the blocks Cij? 1 1 Solution note: One way is: C = C = , C = 0 (the 2 × 2 ), 11 12 0 1 21 2×2 and C22 = I2 (the 2 × 2 identity matrix).

D  2. Suppose we want to calculate the product CD, where D is the block matrix D = 1 , with D2 D1 and D2 each being a 2×2 block. Write the product in terms of Cij and Dk by multiplying the blocks as if they were scalars, as suggested by Theorem 2.3.9. Solution note: We have C C  D  C D + C D  CD = 11 12 1 = 11 1 12 2 . C21 C22 D2 C21D1 + C21D2

Calculate

3. Compute the product AB where 1 0 0 1 0 0 1 0 0  a p x 0 0 0 1 0 0 0 1 0 0 1 0 0 1 0  b q y 0 0 0 0 1 0     0 0 1 0 0 1 0 0 1  c r z 0 0 0 0 0 1     1 0 0 1 0 0 1 0 0  1 2 3 1 0 0 1 0 0     A = 0 1 0 0 1 0 0 1 0 and B =  1 2 3 0 1 0 0 1 0 .     0 0 1 0 0 1 0 0 1  1 2 3 0 0 1 0 0 1     1 0 0 1 0 0 1 0 0 −a −p −x 0 0 0 1 0 0     0 1 0 0 1 0 0 1 0 −b −q −y 0 0 0 0 1 0 0 0 1 0 0 1 0 0 1 −c −r −z 0 0 0 0 0 1 [Hint: Be clever, take advantage of lurking identity matrices and block multiplication.] Solution note: Break this up, sudoku-like, into nine 3 × 3 blocks. Note, in A, almost all these are identity matrices or zero matrices, so the multiplication is especially easy.

C C  4. With C as in (1), find another way to break C up as = 11 12 , but where the blocks are C21 C22 not the same size.

Solution note: You could take C11 to be 1 × 1 and C22 to be 3 × 3. So C11 = 1, 0 1 0 1   C12 = 1 1 1 ,C21 = 0 , and C22 = 0 1 0. It’s easiest to see what I mean 0 0 0 1 by drawing in two lines cutting the matrix up into blocks.

AB F. Consider a matrix M = where A is 3 × 5 and D is 7 × 1 (so M is in block form). CD 1. What are the sizes of B and C? What is the size of M? Solution note: M is 10 × 6, B is 3 × 1 and C is 7 × 5.

A0 B0 2. Suppose N = ? What are the possible of N so that the product MN is C0 D0 defined? In this case, what are the dimensions of the smaller blocks A0,B0,C0 and D0 so that the product can be computed using a block-product?

Solution note: The only restrictions are as follows: A0 and B0 must have 5 rows, and C0 and D0 must have one row. Also, A0 and C0 must have the same of columns, as must B0 and D0. So A0 is 5 × n, B0 is 5 × m, C0 is 1 × n and D0 is 1 × m.

3. What are the possible dimensions of N so that the product NM is defined? In this case, what are the dimensions of the smaller blocks A0,B0,C0 and D0 that would allow us to compute this as a block product? Solution note: For this, the number of columns of N must equal the number of rows of M, so N must by p × 10. For the block multiplication to work, we must have A0 is a × 3, B0 is a × 7, C0 is b × 3 and D0 is b × 7. Here a + b = p.

4. If A is m×d and B is d×n, how can we think of the product AB as a column (of row vectors) times a row (of column vectors)?   R1 R2 Solution note: Write A as a column of row vectors: A =   where each R is a  .  i  .  Rn   C1 C2 1 × m matrix (row vector). Write B as a row of columns vectors: B =  ...  Cm where each Cj is a n × 1 matrix (columns vector). Then   R1 R2 AB =   C C ...C  ,  .  1 2 m  .  Rn which is the n × m matrix with Ri · Cj in the ij-spot.