MATH1231 Algebra, 2015 Chapter 7: Linear maps A/Prof. Daniel Chan School of Mathematics and Statistics University of New South Wales danielc@unsw.edu.au Daniel Chan (UNSW) MATH1231 Algebra 1 / 43
Chapter overview Consider vector spaces V, W over the same set of scalars F. Consider a function T : V W. Recall V is the domain of T & W the codomain of T. In this chapter, we consider special functions where the graph is a subspace (so in particular is not curved), e.g. T : R 2 R defined by T ( x y) = 2x 3y has graph z = 2x 3y which is a subspace of R 3 being a plane through 0. These functions will be called linear maps or linear transformations. This will allow us to generalise systems of linear equations with matrix form Ax = b to linear equations of the form T x = b where b W, x V. Daniel Chan (UNSW) 7.1 Introduction to Linear Maps 2 / 43
Addition Condition To define linear maps we first consider Addition Condition. We say T : V W satisfies the addition condition, if T (v + v ) = T (v) + T (v ) for all v, v V. E.g. T : R 2 R defined by T ( x y) = 2x 3y satisfies the addn condn since given ( ) ( x y, x ) y R 2 (( ) ( )) x x T + y y = ( ) x T ( x y ) + T y Warning The + on the two sides of the equation are different! = Daniel Chan (UNSW) 7.1 Introduction to Linear Maps 3 / 43
Scalar Multiplication Condition Scalar Multiplication Condition. We say T : V W satisfies the scalar multiplication condition, if T (λv) = λt (v) for all λ F and v V. E.g. T : R 2 R defined by T ( x y) = 2x 3y satisfies the scalar multn condn since given ( x y) R 2, λ R ( ( )) x T λ = y ( ) x λt = y Warning The scalar multn on the two sides of the eqn are different! Daniel Chan (UNSW) 7.1 Introduction to Linear Maps 4 / 43
Linear Transformation Definition Let V and W be vector spaces /F. A function T : V W is called a linear map or a linear transformation if the following two conditions are satisfied. Addition Condition. T (v + v ) = T (v) + T (v ) for all v, v V, and Scalar Multiplication Condition. T (λv) = λt (v) for all λ F and v V. E.g. We see now that T : R 2 R defined by T ( x y) = 2x 3y is linear. Daniel Chan (UNSW) 7.1 Introduction to Linear Maps 5 / 43
Sample question: showing a function is linear. Example Show that the function T : R 3 R 2 defined by ( ) x 4x2 3x 1 T (x) = 3 for x = x x 1 + 2x 2 R 3 2 x 3 is a linear map. Solution Daniel Chan (UNSW) 7.1 Introduction to Linear Maps 6 / 43
Solution (Continued) Daniel Chan (UNSW) 7.1 Introduction to Linear Maps 7 / 43
Solution (Continued) Daniel Chan (UNSW) 7.1 Introduction to Linear Maps 8 / 43
Linear maps preserve zero. Proposition. If T : V W is a linear map, then T (0) = 0. Proof. T (0) = T (00) = 0T (0) = 0. Example Show that the function T : R 2 R 3 defined by T not linear. Soln ( x1 x 2 ) x 1 + x 2 = x 2 2 is x 1 Daniel Chan (UNSW) 7.1 Introduction to Linear Maps 9 / 43
Another non-linear example Example Show that the function T : R 2 R 2 defined by ( ) ( ) x1 x1 + x T = 2 x 2 is not linear. Solution Note T (0) = 0 tells you nothing about whether T is linear or not. x 2 2 Daniel Chan (UNSW) 7.1 Introduction to Linear Maps 10 / 43
Alternate characterisation of linearity We can combine the addn condn & scalar multn condn into one! Theorem Let V, W be vector spaces /F. The function T : V W is a linear map iff for all λ F and v 1, v 2 V T (λv 1 + v 2 ) = λt (v 1 ) + T (v 2 ). Remark This means that a linear map T has the special property that it sends the line x = a + λv to the line x = T a + λt v or point T a if T v = 0. E.g. Differentation is a linear map. More precisely, we define T : P P by Tp = dp dx. Then for p, q P, λ R T (λp + q) = Daniel Chan (UNSW) 7.1 Introduction to Linear Maps 11 / 43
Theorem If T : V W is a linear map, S = {v 1,..., v n } is a subset of V and λ 1,..., λ n are scalars, then Example T (λ 1 v 1 + + λ n v n ) = λ 1 T (v 1 ) + + λ n T (v n ). If T : R 2 R 2 a function such that ( ) ( ) ( ) 2 1 1 T =, T = 1 2 1 Show that T is not linear. Solution ( ) 1, T 1 ( ) 3 = 1 ( ) 3. 2 Daniel Chan (UNSW) 7.1 Introduction to Linear Maps 12 / 43
Solution (Continued) Daniel Chan (UNSW) 7.1 Introduction to Linear Maps 13 / 43
Example Given that T is a linear map and 1 ( ) 0 ( ) T 0 1 =, T 1 2 =, T 1 1 0 0 x Find T y. z Solution 0 0 = 1 ( ) 0. 3 Daniel Chan (UNSW) 7.1 Introduction to Linear Maps 14 / 43
Linear maps are determined by the values on a spanning set The previous example illustrates the following general result. Theorem Let T : V W be a linear map and S = {v 1,..., v m } be a spanning set for V. Then T is completely determined by the m values T v 1,..., T v m. You might wish to compare with the following related result: An affine linear function f (x) = mx + b is determined by two of its values f (x 1 ), f (x 2 ), since its graph is a line which is determined by two points. Daniel Chan (UNSW) 7.1 Introduction to Linear Maps 15 / 43
Matrices define Linear Maps Theorem For each m n matrix A, the function T A : R n R m, defined by T A (x) = Ax for x R n, is a linear map called the associated linear map. Proof. Daniel Chan (UNSW) 7.2 Linear Maps and Matrices 16 / 43
Example of reflection Example ( ) 1 0 Let A =, describe the associated linear map T 0 1 A geometrically as a mapping R 2 R 2. Solution Daniel Chan (UNSW) 7.2 Linear Maps and Matrices 17 / 43
Matrix Representation Theorem Conversely, given a linear transformation T : R n R m, we can find an m n matrix A such that T (x) = Ax for all x R n.in this case, we say A is a matrix representing T. Example Given that T : R 2 R 3 defined by T the matrix A representing T. Solution ( ) x + 2y x = 2x y is linear. Find y y Daniel Chan (UNSW) 7.2 Linear Maps and Matrices 18 / 43
Formula for representing matrix Theorem Let T : R n R m be a linear map and let the vectors e j for 1 j n be the standard basis vectors for R n. Then the m n matrix has the property that A = (T e 1 T e 2... T e n ) T (x) = Ax for all x R n. E.g. In the example of the previous slide, 1 2 T e 1 = 2, T e 2 = 1 so the representing matrix is 0 1 Daniel Chan (UNSW) 7.2 Linear Maps and Matrices 19 / 43
Stretching and Compressing A 5-point star with vertices A(1, 5), B(4, 3), C(3, 1), D( 1, 1) and E( 2, 3). Daniel Chan (UNSW) 7.3 Linear maps from geometry 20 / 43
Example Find and draw the image of( the 5-point ) star under the linear map T M 0.5 0 defined by the matrix M =. 0 2 Solution Daniel Chan (UNSW) 7.3 Linear maps from geometry 21 / 43
Solution (Continued) Daniel Chan (UNSW) 7.3 Linear maps from geometry 22 / 43
Rotation about 0 is linear Consider the map R α, which rotates the R 2 plane through an angle α anticlockwise about the origin. One can show geometrically that R α is a linear map see Section 7.3. example 3. Example Find the matrix A representing R α. Solution Daniel Chan (UNSW) 7.3 Linear maps from geometry 23 / 43
Projection onto b is linear Recall given given b R n we have a projection map proj b : R n R n which sends x proj b x. Proposition proj b x = 1 b 2 bbt x Hence proj b is linear being the linear map associated to the matrix Proof. Note A = 1 b 2 bbt. Ax = 1 b 2 bbt x = 1 b x b(b x) = b 2 b 2 b = proj bx from the formula for proj b x given in MATH1131 Daniel Chan (UNSW) 7.3 Linear maps from geometry 24 / 43
Sample projection Example ( ) 1 Let b = and T = proj 0 b : R 2 R 2. i) Find the matrix A representing T. ii) Check your answer by computing the linear map associated to the matrix A you found. Solution Daniel Chan (UNSW) 7.3 Linear maps from geometry 25 / 43
Kernels of linear maps Let T : V W be a linear map. Proposition-Definition The kernel of T (written ker(t ) of ker T ) is the set, ker(t ) = {v V T (v) = 0} V. Let A M mn (R) & T A : R n R m be the assoc linear map. We define kert is a subspace of V. E.g. Is ( 1 2) in ker(2 1)? kera = kert A = {v R n : Av = 0}. E.g. Consider the differentiation map T : P P, (Tp)(x) = p (x). kert = {p P dp dx = 0} = P 0 the subspace of all constant polynomials. Daniel Chan (UNSW) 7.4 Subspaces Associated with Linear Maps 26 / 43
Proof that kernels are subspaces Let T : V W be a linear map. We prove that kert is a subspace of V by checking closure axioms. Proof. Daniel Chan (UNSW) 7.4 Subspaces Associated with Linear Maps 27 / 43
Images of linear maps Let T : V W be a linear map. Proposition-Definition The image of T is the set of all function values of T, that is, im(t ) = {w W : w = T (v) for some v V } W. Let A M mn (R) & T A : R n R m be the assoc linear map. We define im A = im T A = {b R m : b = Ax for some x R n } = col(a). imt is a subspace of W. Remark Proof omitted, but note we already know col(a) is a subspace as it is the span of the columns of A. Daniel Chan (UNSW) 7.4 Subspaces Associated with Linear Maps 28 / 43
Verifying whether or not vectors lie in the image Example 1 1 3 Let A = 0 1, b = 1. Is b im A? 1 2 3 Solution The question amounts to asking: Can we write b = Ax for some x R 2? i.e. Can we solve Ax = b. Daniel Chan (UNSW) 7.4 Subspaces Associated with Linear Maps 29 / 43
Finding Bases for Kernels & Images. Example 1 2 3 1 Let 2 4 7 1. Find bases for ker(a) and im(a) = col(a). 1 2 2 2 Solution 1 2 3 1 2 4 7 1 1 2 2 2 1 2 3 1 0 0 1 1 0 0 1 1 1 2 3 1 0 0 1 1 = U 0 0 0 0 The row echelon form U has first & third columns leading. Daniel Chan (UNSW) 7.4 Subspaces Associated with Linear Maps 30 / 43
Solution (Continued) Daniel Chan (UNSW) 7.4 Subspaces Associated with Linear Maps 31 / 43
Solution (Continued) Daniel Chan (UNSW) 7.4 Subspaces Associated with Linear Maps 32 / 43
Why study kernels & image? imt tells you about existence of solutions. T x = b has a solution iff b imt. kert tells you about uniqueness of solutions. T x = 0 has unique solution x = 0 iff kert = 0. We ll see later, that it also tells you about solutions to T x = b. Daniel Chan (UNSW) 7.4 Subspaces Associated with Linear Maps 33 / 43
Rank and Nullity Let T : V W be a linear map & A a matrix with associated linear map T A. Definition The nullity of T is nullity(t ) = dim ker(t ). The nullity of A is nullity(a) = nullity(t A ) = dim ker(a). The rank of T is rank(t ) = dim im(t ). The rank of A is rank(a) = rank(t A ) = dim im(a). Daniel Chan (UNSW) 7.4 Subspaces Associated with Linear Maps 34 / 43
Rank, Nullity example Example (Continued from the example on p.30) 1 2 3 1 Let A = 2 4 7 1. Find nullity(a) and rank(a). 1 2 2 2 Solution A basis for im A was Recall a basis for ker A had Note that the basis vectors for im A corresponded to the leading columns of the row-echelon form U whilst the basis vectors for ker A corresponded to the non-leading columns. Daniel Chan (UNSW) 7.4 Subspaces Associated with Linear Maps 35 / 43
Rank & Nullity from the row-echelon form The previous examples illustrates Key Lemma Let A be an m n matrix which reduces to a row-echelon form U. 1 nullity(a) = no. parameters in the general soln to Ax = 0 = the number of non-leading columns of U. 2 rank(a) = the maximal no. independent columns of A = the number of leading columns of U. Daniel Chan (UNSW) 7.4 Subspaces Associated with Linear Maps 36 / 43
Rank-Nullity Theorem Our key lemma gives Theorem (Rank-nullity Theorem for Matrices) If A is an m n matrix, then rank(a) + nullity(a) = n. Proof. This can be used to prove more generally, Theorem (Rank-nullity Theorem for Linear Maps) Let T : V W be a linear map with V finite dimensional. Then rank(t ) + nullity(t ) = dim(v ). Daniel Chan (UNSW) 7.4 Subspaces Associated with Linear Maps 37 / 43
Example of rank-nullity theorem Example ( ) 1 Let b = and T : R 1 2 R 2 be the projection map proj b. Verify the rank-nullity theorem in this case. Solution Daniel Chan (UNSW) 7.4 Subspaces Associated with Linear Maps 38 / 43
Nature of solutions to Ax = b Our key lemma also gives Theorem The equation Ax = b has: 1 no solution if rank(a) rank([a b]), and 2 at least one solution if rank(a) = rank([a b]). Further, i) if nullity(a) = 0 the solution is unique, whereas, ii) if nullity(a) = ν > 0, then the general solution is of the form x = x p + λ 1 k 1 + + λ ν k ν for λ 1,..., λ ν R, where x p is any solution of Ax = b, and where {k 1,..., k ν } is a basis for ker(a). Daniel Chan (UNSW) 7.4 Subspaces Associated with Linear Maps 39 / 43
A theoretical application of rank-nullity theorem Example Prove that if T : R n R n is linear, then the following are equivalent. a) For all b R n, there is at least one solution to T x = b. b) For all b R n, there is at most one solution to T x = b Solution Daniel Chan (UNSW) 7.4 Subspaces Associated with Linear Maps 40 / 43
Linear Differential Equations Q In what sense are second order linear differential equations linear? A They involve the linear map T : C 2 [R] C[R], where C 2 [R] is the vector space of all R-valued functions with continuous second derivatives and C[R] is the vector space of all continuous R-valued functions T (y) = a d 2 y dx 2 + b dy dx + cy, where a, b, c R. In this case, ker(t ) is the solution set of the ODE a d 2 y dx 2 + b dy + cy = 0, where a, b, c R. dx Hence the homogeneous solution is a vector space. Furthermore, it is of dimension 2 i.e. nullity(t ) = 2. We can also apply similar ideas for the solution to Ax = b to get the solution to a d 2 y dx 2 + b dy dx + cy = f (x), where a, b, c R. Daniel Chan (UNSW) 7.5 Further Applications and Examples 41 / 43
Example involving polynomials To study boundary value problems, it s useful to study linear maps such as the one below. Example The function T : P 2 R 2 is defined by Tp = ( p(1) ) p (1) a) Prove that T is linear. b) Find ker(t ) and Im(T ). c) Verify the rank-nullity theorem in this case. Solution Daniel Chan (UNSW) 7.5 Further Applications and Examples 42 / 43
Solution (Continued) Daniel Chan (UNSW) 7.5 Further Applications and Examples 43 / 43