Multivariable Calculus: Linear Algebra Basics...

25
Multivariable Calculus: Linear Algebra Basics Supplementary Notes Fall 2019 David Lyons Mathematical Sciences Lebanon Valley College last updated: 18 October 2019

Transcript of Multivariable Calculus: Linear Algebra Basics...

Page 1: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus:Linear Algebra BasicsSupplementary Notes

Fall 2019

David LyonsMathematical SciencesLebanon Valley College

last updated: 18 October 2019

Page 2: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra BasicsSupplementary Notes

Fall 2019

David LyonsMathematical SciencesLebanon Valley College

Copyright c©2019

Contents

Introduction 1

1 The vector space Rn 1

1.1 Vectors and vector operations . . . . . . . . . . . . . . . . . . . . 1

1.2 Notation for vectors . . . . . . . . . . . . . . . . . . . . . . . . . 1

1.3 Standard basis vectors . . . . . . . . . . . . . . . . . . . . . . . . 2

1.4 Inner product . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2

Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3

2 Linear Transformations 4

2.1 Definition of linear transformation . . . . . . . . . . . . . . . . . 4

2.2 Formulas for linear transformations . . . . . . . . . . . . . . . . . 4

2.3 Three operations on linear transformations . . . . . . . . . . . . 5

Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

3 Matrices 7

3.1 Matrix notation . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7

3.2 Matrices and linear transformations . . . . . . . . . . . . . . . . 7

3.3 Matrix versions of vector operations . . . . . . . . . . . . . . . . 8

Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9

4 More linear and matrix algebra 11

4.1 More matrix algebra . . . . . . . . . . . . . . . . . . . . . . . . . 11

4.2 Two by two matrices . . . . . . . . . . . . . . . . . . . . . . . . . 11

4.3 Dependence and Independence . . . . . . . . . . . . . . . . . . . 11

Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12

5 Linear algebra in Calculus 3 13

5.1 Differentiability . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13

5.2 The Chain Rule . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13

Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15

Solutions to Exercises 16

Page 3: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 1

Introduction

Vector spaces and linear transformations are the basic objects of the subjectof linear algebra. The purpose of these notes is to introduce the language andtechniques of linear algebra that are needed for introductory physics and mul-tivariable calculus courses.

1 The vector space Rn

1.1 Vectors and vector operations

An ordered list of n real numbers (x1, x2, . . . , xn) is called an n-tuple. The setof all n-tuples is called n-dimensional (real) space.

Rn = {(x1, x2, x3, . . . , xn) : xi ∈ R, 1 ≤ i ≤ n}

The operation of addition of two n-tuples is defined by

(x1, x2, . . . , xn) + (y1, y2, . . . , yn) = (x1 + y1, x2 + y2, . . . , xn + yn)

and scalar multiplication of an n-tuple (x1, x2, . . . , xn) by a real number (orscalar) k is defined by

k(x1, x2, . . . , xn) = (kx1, kx2, . . . , kxn).

With the operations of addition and scalar multiplication, the set Rn is calleda vector space1 and n-tuples are called vectors.

The numbers {xi} are called the coordinates of the vector (x1, . . . , xn). Thenumber n is called the dimension of the vector space Rn. The space R1 = Ris the real number line, R2 is the plane of high school geometry and algebra,and R3 is the mathematical abstraction for the familiar 3-space in which welive. The space R0 is defined to be the one point set R0 = {0}.

1.2 Notation for vectors

There are many notation styles used to denote vectors in multivariate calcu-lus and physics courses. Symbols for vectors are sometimes bold, Roman fontletters, and sometimes letters decorated with arrows2.

x = ~x = (x1, x2, . . . , xn)

Sometimes, instead of parentheses, angle brackets are used to delimit n-tuples.

(x1, x2, . . . , xn) = 〈x1, x2, . . . , xn〉

The vector (0, 0, . . . , 0) with all entries equal to 0 is called the zero vector andis denoted 0 or ~0.

1What all vector spaces have in common is a set of vectors, a set of scalars, and the oper-ations of vector addition and scalar multiplication. We omit the complete technical definitionof a vector space.

2In advanced mathematics, vector names usually receive no special decoration, and insteadwould be written simply “x = (x1, x2, . . . , xn)”.

Page 4: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 2

1.3 Standard basis vectors

The vector ei = (0, . . . , 0, 1, 0, . . . , 0) with a 1 in the ith coordinate and zeroesin all other coordinates is called the ith standard basis vector in Rn. InR2, the standard basis vectors e1 = (1, 0) and e2 = (0, 1) are also called iand j, respectively. In R3, the standard basis vectors e1 = (1, 0, 0), e2 =(0, 1, 0) and e3 = (0, 0, 1) are also called i, j and k, respectively. Given a vectorx = (x1, . . . , xn), we have the following representation of x as a sum of scalarmultiples of the standard basis vectors (note that the summation sign indicatesvector addition).

(1.3.1) x =n∑

i=1

xiei

1.4 Inner product

The inner product or dot product of two vectors x = (x1, . . . , xn) and y =(y1, . . . , yn) is defined to be the real number

x · y = x1y1 + x2y2 + · · ·+ xnyn.

In terms of inner product, the ith coordinate xi of the vector x = (x1, . . . , xn)is given by

(1.4.1) xi = ei · x

and (1.3.1) becomes

(1.4.2) x =n∑

i=1

(ei · x) ei.

Page 5: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 3

Exercises for Section 1

1. Write each of the following vectors x in the form (x1, x2, . . . , xn) and∑xiei. For n = 2, 3, also write x using i, j,k notation.

Example: Given x = 3(2, 4,−1), write x = (6, 12,−3) = 6e1+12e2−3e3 =6i + 12j− 3k.

(a) x = (3, 2)− (5,−2)

(b) x = 2(−1, 2, 1) + 3(2,−2, 0)

(c) x = 2e1 − 3e2 + 4e4 − (e1 − e2 + e3)

2. Verify equation (1.3.1).

3. Show that for x = (x1, . . . , xn), we have xi = ei · x.

4. Show thatei · ej = δij

where δij , called the Kronecker delta, is given by

δij =

{1 if i = j0 if i 6= j

5. The length or norm of vector x = (x1, x2, . . . , xn), denoted |x|, is definedby

|x|2 = x · x = x21 + x22 + · · ·+ x2n.

A vector x is said be be normalized or have norm 1 if |x| = 1.

(a) Show that, for any vector x and any k > 0, we have

|kx| = k|x|.

(b) Show that, for any nonzero vector x, the vector x|x| has norm 1.

Page 6: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 4

2 Linear Transformations

2.1 Definition of linear transformation

A function L : Rn → Rm is called a linear transformation (or “linear map”)if

(i) L(kx) = kL(x) , and

(ii) L(x + y) = L(x) + L(y)

for all vectors x,y in Rn and real numbers k. Properties (i) and (ii) are calledlinearity properties. We say that L preserves or respects vector operationsof scaling and addition. Instead of L(x), it is common practice to drop theparentheses and write Lx when L is a linear transformation.

2.2 Formulas for linear transformations

Given a vector x = (x1, . . . , xn) and a linear map L : Rn → Rm, we have

Lx = L(x1, x2, . . . , xn)(2.2.1)

= L

n∑

j=1

xjej

=n∑

j=1

L(xjej)

=n∑

j=1

xjLej

A consequence of this equation is that a linear map is determined by its valueson the standard basis vectors e1, e2, . . . , en. We can write an explicit formulafor the coordinates (y1, y2, . . . , ym) of the value y = Lx. Let f1, f2, . . . , fm denotethe standard basis vectors for Rm. Then we have

yi = fi · Lx(2.2.2)

= fi ·

n∑

j=1

xjLej

=

n∑

j=1

(fi · Lej)xj .

This last expression shows that the values of a linear function are completelydetermined by the numbers

(2.2.3) aij = fi · Lej

Page 7: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5

where i is in the range 1 ≤ i ≤ m and j is in the range 1 ≤ j ≤ n. Written outfully, the equations for the value y = Lx are the following.(2.2.4)

y1 = a11x1 + a12x2 + · · · a1jxj + · · · + a1nxny2 = a21x1 + a22x2 + · · · a2jxj + · · · + a2nxn

...yi = ai1x1 + ai2x2 + · · · aijxj + · · · + ainxn

...ym = am1x1 + am2x2 + · · · amjxj + · · · + amnxn

The expressions on the right side of each equation are inner products.

(2.2.5) yi = (ai1, ai2, . . . , ain) · x

2.3 Three operations on linear transformations

Let L,L′ : Rn → Rm, let M : Rp → Rn, and let k be a real number. Lineartransformations kL : Rn → Rm, L + L′ : Rn → Rm, and LM : Rp → Rm aredefined as follows3.

(kL)x = k(Lx) (scalar multiplication)(2.3.1)

(L+ L′)x = Lx + L′x (addition)(2.3.2)

(LM)x = L(Mx) (composition)(2.3.3)

Note that LM is the same thing as L ◦M , the ordinary composition of func-tions. It is conventional to omit the composition symbol in the context of lineartransformations.

3With the operations of scalar multiplication and addition, the space of linear transforma-tions Rn → Rm is another example of a vector space.

Page 8: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 6

Exercises for Section 2

1. Let L : R2 → R2 be a linear map such that Le1 = (2, 3) and Le2 =(−1,−2). Find L(1, 2).

2. Let L : R3 → R be a linear map. Find Lk if Li = 2, Lj = −1, andL(1, 2, 3) = 0.

3. Show that the two linearity properties in the definition of linear transfor-mation given in §2.1 are equivalent to the single property

(2.3.4) L(ax + by) = aLx + bLy

for all vectors x,y and scalars a, b.

4. Justify each equality in (2.2.1).

5. In formulas (2.2.2) and (2.2.3), what is the difference between ei and fi?Aren’t both of these vectors with 1 in the ith coordinate and 0 elsewhere?

6. The dot product has the following properties that look like the propertiesin the definition of linear map.

u · (αv) = αu · vu · (v + w) = u · v + u ·w

for all u,v,w in Rn and scalars α. Show that these properties hold.

7. Justify the steps of the derivation (2.2.2).

8. Prove that the composition of two linear maps is a linear map.

Page 9: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 7

3 Matrices

3.1 Matrix notation

A matrix is a rectangular array of numbers. Entries of a matrix are indexedby a pair of integers i, j that indicate the row and column, respectively, of theentry. Rows are counted from top to bottom and columns are counted from leftto right. A matrix with m rows and n columns is called an m by n matrix.We write [aij ] to denote4 the matrix with entries aij .

[aij ] =

a11 a12 · · · a1j · · · a1na21 a22 · · · a2j · · · a2n...

......

...ai1 ai2 · · · aij · · · ain...

......

...am1 am2 · · · amj · · · amn

A matrix with only 1 row is called a row matrix and a matrix with only 1column is a column matrix. Entries of row and column matrices are usuallygiven with just one index. Here are examples of 1 × m and n × 1 matrices,respectively.

[a1 a2 · · · am

]

b1b2...bn

It is nearly universal practice to identify n-tuples in Rn with n × 1 matrices.We think of a column matrix as just another way to write a vector. Here isexample notation.

x = (x1, x2, . . . , xn) =

x1x2...xn

.

3.2 Matrices and linear transformations

Using (2.2.3), linear transformations Rn → Rm are in one-to-one correspon-dence with m×n matrices. We write [L] for the matrix associated to the lineartransformation L.

(3.2.1) L←→ [L] = [fi · Lej ]

Using the one-to-one correspondence L ↔ [L], we can impose on matrices thethree operations of scalar multiplication (2.3.1), addition (2.3.2), and composi-tion (2.3.3). Given a scalar k, two m×n matrices A,A′, and an n×p matrix B,let L,L′ be the associated linear maps for A,A′ (that is, A = [L] and A′ = [L′])

4Sometimes, instead of square brackets, parentheses are used to delimit matrices.

Page 10: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 8

and let M be the associated linear map for B (so B = [M ]). We define newmatrices kA, A+A′, and AB in terms of the associated linear maps as follows5.

kA = [kL] (scalar multiplication)(3.2.2)

A+A′ = [L+ L′] (addition)(3.2.3)

AB = [LM ] (matrix multiplication)(3.2.4)

Here are formulas for these three basic matrix operations in terms of matrixentries of A, A′ and B.

i, j entry of kA = k(i, j entry of A)(3.2.5)

i, j entry of A+A′ = (i, j entry of A) + (i, j entry of A′)(3.2.6)

i, j entry of AB = (ith row of A) · (jth column of B)(3.2.7)

In most texts, the above formulas are given as definitions. In these notes,these formulas are consequences of the definitions (3.2.2), (3.2.3), and (3.2.4).We make this choice to emphasize that matrix algebra operations are naturalbecause they come from the corresponding natural operations on linear maps.There is a fourth basic operation, called transposition, whose correspondingoperation on linear maps is less easy to describe. We define the transpose ofmatrix A, denoted AT , by

(3.2.8) i, j entry of AT = j, i entry of A.

3.3 Matrix versions of vector operations

Let x,y be vectors in Rn and let L : Rn → Rm be a linear transformation.matrix. We have the following.

x · y = xTy(3.3.1)

Lx = [L]x(3.3.2)

Let e1, e2, . . . , en be the standard basis vectors for Rn, and let f1, f2, . . . , fm bethe standard basis vectors for Rm. Given an m × n matrix A, we have thefollowing.

Aej = jth column of A(3.3.3)

fTi A = ith row of A(3.3.4)

fTi Aej = i, j entry of A(3.3.5)

5With the operations of scalar multiplication and addition, the space of m× n matrices isyet another example of a vector space.

Page 11: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 9

Exercises for Section 3

1. Perform the matrix multiplications below.

(a) [1 −2−1 3

] [0 21 −1

]

(b)[

1 −2 0−1 3 1

]

0 21 −12 0

2. Let L : R3 → R2 be a linear map with Le1 = (1, 2), Le2 = (−1, 1), andLe3 = (0, 1).

(a) Write the matrix for L.

(b) Evaluate L(2, 1, 3).

(c) Evaluate L(0, 1, 1).

3. Let L : R2 → R3 be a linear map with the following matrix.

1 23 −10 1

(a) Evaluate L(1, 2).

(b) Evaluate L(−2, 1).

4. Equation (3.2.7) is a fundamental formula for matrix calculations. Thisexercise outlines a proof. Let L,M be linear transformations so that thecomposition LM is defined (the domain of L is the codomain of M).Justify each equality in the derivation below.

(a) Use (2.2.4) to get

M(jth standard basis vector) = jth column of [M ]

(b) Equation (2.2.5) can be interpreted as saying

the ith coordinate of Lx = (ith row of [L]) · x

(c) String those results together to interpret as

ij entry of [LM ] = (ith standard basis vector) · LM(jth standard basis vector)

= ith coordinate of LM(jth standard basis vector)

= ith coordinate of L(M(jth standard basis vector))

= ith coordinate of L(jth column of [M ])

= (ith row of [L]) · (jth column of [M ])

5. (a) Prove (3.3.2).

(b) Prove (3.3.3).

(c) Prove (3.3.4).

Page 12: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 10

(d) Use parts (a) and (b) to deduce (3.3.5)

6. Let L : R2 → R and K : R → R3 be linear maps such that Li = 1,Lj = −2 and K(1) = (2, 1, 3).

(a) Write the matrices for L and K.

(b) Find the matrix for KL.

(c) Find KL(2,−1).

7. Let e1, e2, . . . , en denote the standard basis vectors in Rn.

(a) Show that ekeTk is an n × n matrix with a 1 in the k, k entry and

zeroes elsewhere.

(b) Show thatn∑

k=1

ekeTk is the n× n identity matrix.

(c) Given an m× n matrix A and an n× p matrix B, show that

AB =n∑

k=1

(column k of A)(row k of B).

Hint: Use (3.3.3) and (3.3.4).

Page 13: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 11

4 More linear and matrix algebra

4.1 More matrix algebra

The identity map I : Rn → Rn, given by Ix = x, is a linear transformation.Its matrix is called the n × n identity matrix, and is also denoted I. Othercommon notations for the identity map or the identity matrix are Id and 1.

A linear transformation L : Rn → Rn is called invertible if there is anotherlinear map M : Rn → Rn such that L ◦M = M ◦ L = I. If M exists, M iscalled the inverse of L, and we write M = L−1.

An n×n matrix is called invertible if its corresponding linear transformation isinvertible. We write A−1 for the matrix [L−1] for A = [L].

4.2 Two by two matrices

A 2 × 2 matrix A =

[a bc d

]is invertible if and only if its determinant

det(A) = ad− bc is nonzero. In this case, we have

A−1 =1

ad− bc

[d −b−c a

].

4.3 Dependence and Independence

A linear combination of vectors v1,v2, . . . ,vr in Rn is a vector of the form

c1v1 + c2v2 + · · ·+ crvr

where c1, . . . , cr are scalars. The set of all possible linear combinations of vectorsv1,v2, . . . ,vr is called their span, denoted Span(v1, . . . ,vr).

(4.3.1) Span(v1, . . . ,vr) = {c1v1 + c2v2 + · · ·+ crvr : ci ∈ R, 1 ≤ i ≤ r} .

A set of vectors in Rn is said to be dependent if one or more of them can bewritten as a linear combination of the others. Otherwise, the set of vectors issaid to be independent.

A set B of vectors in Rn is called a basis (plural bases) if the vectors in B areindependent and span all of Rn. Here is a key fact about bases.

(4.3.2) Basis fact. Let B = {b1, · · ·bn} be a basis for Rn, and let x be anyvector in Rn. Then there exist a unique set of constants c1, c2, . . . , cn such thatx =

∑ni=1 cibi.

Page 14: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 12

Exercises for Section 4

1. Find the matrix for the identity map I : Rn → Rn.

2. Verify the 2 by 2 matrix facts in §4.2.

3. Here is an alternative definition for independence of vectors.

Vectors v1, . . . ,vr are dependent if there exists real numbersc1, c2, . . . , cr, not all of which are zero, such that

c1v1 + c2v2 + · · ·+ crvr = 0.

The vectors v1, . . . ,vr are independent if they are not depen-dent.

Show that this definition is equivalent to the definition given in §4.3.

4. Verify that the standard basis on Rn is indeed a basis according to thedefinition in §4.3.

5. Verify (4.3.2).

Page 15: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 13

5 Linear algebra in Calculus 3

5.1 Differentiability

A function f : Rn → Rm is differentiable at the point x0 if there exists alinear transformation L : Rn → Rm such that

(5.1.1) limh→0

f(x0 + h)− f(x0)− Lh|h| = 0.

If L exists, it is called the derivative of f at x0, denoted Df(x0).

To understand the definition of the derivative, start with the case n = m = 1.The derivative of f at x0 is a number f ′(x0) such that

f(x0 + h)− f(x0) ≈ f ′(x0)h

for h near 0. The meaning of “approximately equals. . . for h near 0” is madeprecise by using a limit. To generalize to higher dimensions, interpret f ′(x0)has the value of a linear transformation that sends h to f ′(x0)h. The derivativeDf(x0) of f at x0 is a linear transformation such that

f(x0 + h)− f(x0) ≈ Df(x0)h

for h near 0. Putting h = tej , this reads

f(x0 + tej)− f(x0) ≈ Df(x0)tej

for t near 0. Dividing both sides by t and taking a limit, we get an expressionfor Df(x0)ej .

Df(x0)ej = limt→0

f(x0 + tej)− f(x0)

t

=

(∂y1∂xj

,∂y2∂xj

, . . . ,∂ym∂xj

)(5.1.2)

where y = (y1, y2, . . . , ym) = f(x1, x2, . . . , xn) = f(x). From this it follows that

Df(x0), if it exists, is represented by the matrix

[∂yi∂xj

].

(5.1.3) [Df(x0)] =

[∂yi∂xj

]

5.2 The Chain Rule

Let

Rp g−→ Rn f−→ Rm

and suppose g is differentiable at t0 and f is differentiable at x0 = g(t0). Thechain rule says that f ◦ g is differentiable at t0, and that the derivative of thecomposition is the composition of the derivatives.

(5.2.1) D(f ◦ g)(t0) = Df(x0)Dg(t0)

Page 16: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 14

This explains the “tree diagram rule” given in most multivariate calculus texts.The partial derivative ∂yi

∂tjis just the i, j entry of the product of the derivative

matrices for f and g.

(5.2.2)∂yi∂tj

=n∑

k=1

∂yi∂xk

∂xk∂tj

Page 17: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 15

Exercises for Section 5

1. Verify the definition of differentiable function (5.1.1) given in is equivalentto the usual definition for n = m = 1 from Calculus 1.

2. Explain equation (5.1.2). Why does the limit on the left equal the vectoron the right?

limt→0

f(x0 + tej)− f(x0)

t=

(∂y1∂xj

,∂y2∂xj

, . . . ,∂ym∂xj

)

3. Explain equation (5.1.3). How does this equation follow from the previous?

4. Explain equation (5.2.2). How is it the same as the chain rule (5.2.1)?

Page 18: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 16

Solutions to Exercises

Note: Most of the “solutions” posted here are not solutions at all, but are merelyfinal answer keys, although some are complete. These are posted so that youcan check your work; reading the answer keys is not a substitute for workingthe problems yourself. For homework, quizzes and exams, you need to show thesteps of whatever procedure you are using—not just the final result. Sometimesyou will be asked to explain your thinking in complete sentences.

Exercises for Section 1 Solutions

1. (a) x = (−2, 4) = −2e1 + 4e2 = −2i + 4j

(b) x = (4,−2, 2) = 4e1 − 2e2 + 2e3 = 4i− 2j + 2k

(c) x = (1,−2,−1, 4) = e1 − 2e2 − e3 + 4e4

2. We have

n∑

i=1

xiei

= x1e1 + x2e2 + · · ·+ xnen

= x1(1, 0, 0, . . . , 0) + x2(0, 1, 0, . . . , 0) + · · ·xn(0, 0, . . . , 0, 1) (defn. of standard basis vects.)

= (x1, 0, 0, . . . , 0) + (0, x2, 0, . . . , 0) + · · · (0, 0, . . . , 0, xn) (scalar mult.)

= (x1, x2, . . . , xn) (vector addition)

= x.

3. We have

ei · x = (0, 0, . . . , 0, 1, 0, . . . , 0) · (x1, x2, . . . , xn) (defn. of standard basis vect.)

= 0x1 + 0x2 + · · · 0xi−1 + 1xi + 0xi+1 + · · ·+ 0xn (defn. of dot product)

= xi.

4. If i 6= j, each summand in the dot product has a factor of 0. If i = j, allthe terms in the dot projuct are 0 except for the i-th, which is 1 · 1 = 1.

5. (a) |kx| =√k2x21 + k2x22 + · · ·+ k2x2n = k

√x21 + x22 + · · ·+ x2n = k|x|

(b) Using the previous problem for the first equality that follows, we have∣∣∣∣x

|x|

∣∣∣∣ =1

|x| |x| = 1. QED

Page 19: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 17

Exercises for Section 2 Solutions

1. l(1, 2) = (0,−1)

2. Lk = 0

3. Let L : Rn → Rm be a linear transformation and let x,y be vectors inRn. Suppose that the two linearity properties given in the notes hold,and let a, b be scalars. We have

L(ax + by) = L(ax) + L(by) (by linearity property (ii))

= aLx + bLy (by linearity property (i)).

Conversely, suppose that (2.3.4) holds. Choosing b = 0, we have (i)

L(ax) = L(ax + by) = aLx + bLy = aLx.

Choosing a = b = 1, we have (ii)

L(x + y) = L(ax + by) = aLx + bLy = Lx + Ly.

4. 1st equality: substitution2nd equality: equation (1.3.1)3rd equality: linearity property (ii)4th equality: linearity property (i)

5. The vectors ei and fi are members of different vector spaces unless n = m,in which case ei = fi.

6. Let u = (u1, . . . , un), v = (v1, . . . , vn), and w = (w1, . . . , wn). We have

u · (αv) = (u1, . . . , un) · (αv1, . . . , αvn) (definition of scalar mult.)

=

n∑

i=1

ui(αvi) (definition of dot prod.)

=

n∑

i=1

(uiα)vi (mult. is associative)

=n∑

i=1

(αui)vi (mult. is commutative)

= (αu1, . . . , αun) · (v1, . . . , vn) (definition of dot prod.)

= (αu) · v (definition of scalar mult.).

The proof of the other property involves similar manipulations.

7. 1st equality: by (1.4.1)2nd equality: by (2.2.1)3rd equality: by linearity of the dot product (2nd property in the previousproblem)

8. Let L : Rn → Rm and let M : Rp → Rn be linear transformations. Firstwe check linearity property (i) for the composition LM . Let t, s be ele-

Page 20: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 18

ments of Rp and let k be a real number. We have

LM(kt) = L(Mkt) (definition)

= L(kMt) (linearity (i) for M)

= kL(Mt) (linearity (i) for L)

= kLMt (definition).

For property (ii), we have

LM(t + s) = L(M(t + s)) (definition)

= L(Mt +Ms) (linearity (ii) for M)

= L(Mt) + L(Ms) (linearity (ii) for L)

= LMt + LMs (definition).

Page 21: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 19

Exercises for Section 3 Solutions

1. (a)

[−2 43 −5

]

(b)

[−2 45 −5

]

2. (a)

[1 −1 02 1 1

]

(b) (1, 8)

(c) (−1, 2)

3. (a) (5, 1, 2)

(b) (0,−7, 1)

4. (a) From (2.2.4), we see that Lej = (a1j , a2j , . . . , amj). By definition,this is the jth column of [L].

(b) This is what (2.2.5) says.

(c) 1st equality: definition (3.2.1) of the i, j entry of the matrix for alinear transformation2nd equality: by (1.4.1)3rd equality: definition of composition of functions4th equality: by part (a)5th equality: by part (b), with x = (jth column of [M ])

5. (a)

the ith coordinate of Lx = (ith row of [L]) · x (by (2.2.5))

= [L]x (by (3.2.7))

(b) This follows immediately from (3.2.7).

(c) This follows immediately from (3.2.7).

(d) This follows immediately from parts (b) and (c).

6. (a) L =[

1 −2]

K =

213

(b)

2 −41 −23 −6

(c) (8, 4, 12)

7. (a) Just do the matrix multiplication.

(b) This follows immediately from part (a).

Page 22: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 20

(c)

AB = AIB

= A

(n∑

k=1

ekeTk

)B (by part (b))

=n∑

k=1

(Aek)(eTkB) (by linearity)

=

n∑

k=1

(column k of A)(row k of B) (by (3.3.3) and (3.3.4))

Page 23: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 21

Exercises for Section 4 Solutions

1. By definition (3.2.1), the i, j entry of the matrix for the identity map is

ei · Iej = ei · ej= δij (by Exercise 4 in Section 1).

Thus the identity matrix is the n × n matrix with 1’s on the diagonalentries (that is, entries indexed i, i) and 0’s in off-diagonal entries (thatis, entries indexed i, j with i 6= j).

Another way to find the matrix for the identity map is to see that its rowsare the vectors

a1,a2, . . . ,an

given by

x = (x1, x2, . . . , xn) = I(x1, x2, . . . , xn)

= (a1 · x,a1 · x, . . . ,a1 · x).

From this we can see that ai = ei.

A further alternative is to use the fact that the j-th column of a matrixfor a linear transformation L is Lej .

2. There are two statements to prove. The first says that if det(A) 6= 0, thenA−1 exists and is given by the formula in the notes. To establish that thisclaim is true, simply check that AA−1 = A−1A = I.

The second statement says that if det(A) = 0, then A is not invertible.Here is an outline of how to argue that this claim is true.

• One way to show that a function is not invertible is to show that itis not one-to-one, that is, that there exist two different inputs thatare sent by the function to the same output.

• A linear map always sends the zero vector in the input space to thezero vector in the output space. So to establish that a linear map isnot one-to-one (and therefore not invertible), it suffices to find somenonzero input vector that is sent by the linear map to the zero vector.

• Assuming that 0 = det(A) = ad− bc, one can show that A sends thevector (−b, a) to the zero vector. If (−b, a) is not the zero vector, wehave shown that A is not invertible.

• If (−b, a) is the zero vector, then one can show that A sends (−d, c)to zero. If (−d, c) is not zero, then A is non invertible.

• If (−b, a) and (−d, c) are both the zero vector, then A is the zeromatrix, so A sends every input vector to zero, so A is not invertible.This takes care of all possible cases, so we conclude that A is notinvertible.

3. We will prove the equivalence of the two definitions of dependence, fromwhich the equivalence of the two definitions of independence follows.

Suppose that vectors {vi} are dependent in the sense defined in this ex-ercise. That is, suppose that there is a linear combination

c1v1 + c2v2 + · · ·+ crvr = 0

Page 24: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 22

for which at least one of the coefficients, say ci, is not zero. Then we cansolve for vi as a linear combination of the other vj ’s.

vi = −c1civ1 +−c2

civ2 + · · ·+ v̂i + · · ·+−cr

civr

(The symbol v̂i means that the term with vi is omitted from the sum.)This shows that the vectors {vi} are dependent by the definition in §4.3.

Conversely, suppose that the vectors {vi} are dependent by the defini-tion in §4.3. Then one of the vectors, say vi, can be written as a linearcombination of the others.

vi = c1v1 + c2v2 + · · ·+ v̂i + · · ·+ crvr

Thus we have a linear combination

c1v1 + c2v2 + · · ·+ (−1)vi + · · ·+ crvr = 0

so the {vi} are dependent in the sense defined in this exercise.

4. First we verify that the standard basis vectors are independent. We willuse the definition from exercise 3 above. Suppose there is a linear combi-nation

c1e1 + c2e2 + · · ·+ cnen = 0

But the vector on the left is (c1, c2, . . . , cn), so it must be the case thatc1 = c2 = · · · = cn = 0.

Next, we verify spanning. This is clear, because given any vector x =(x1, x2, . . . , xn), we can write x as a linear combination x =

∑ni=1 xiei.

5. Because B is a basis, the vectors in B span all of Rn, so there existconstants c1, . . . , cn such that x =

∑ni=1 cibi. Now suppose that x =∑n

i=1 dibi for some constants d1, . . . , dn. Subtracting, we have∑n

i=1(ci−di)bi = 0. Using the definition of independence from the exercise 3 above,we conclude that 0 = (c1 − d1) = (c2 − d2) = · · · = (cn − dn). This provesthe desired uniqueness.

Page 25: Multivariable Calculus: Linear Algebra Basics …quantum.lvc.edu/lyons/courses/2019.09/mas261/notes_to...Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 5 where

Multivariable Calculus: Linear Algebra Basics, Supplementary Notes 23

Exercises for Section 5 Solutions

1. A linear map R1 → R1 has the form x 7→ mx for some constant m, so theassumption that f : R1 → R1 is differentiable at x0 in the sense of (5.1.1)means that there is some constant m such that

limh→0

f(x0 + h)− f(x0)−mh|h| = 0.

It follows that

limh→0+

f(x0 + h)− f(x0)−mhh

= 0.

Because the limit limh→0+mhh = m exists, the addition property of limits

implies that

limh→0+

f(x0 + h)− f(x0)

h= m.

A similar argument establishes that

limh→0−

f(x0 + h)− f(x0)

h= m.

The agreement of both the left and right hand limits implies that thetwo-sided limit exists.

limh→0

f(x0 + h)− f(x0)

h= m

This is the calculus 1 definition of the differentiability of f at x0, andfurther, we have f ′(x0) = m.

Conversely, if we assume that f : R1 → R1 is differentiable in the usualcalculus 1 sense, we can reverse the steps of the argument above to con-clude that

limh→0

f(x0 + h)− f(x0)−mh|h| = 0,

i.e., that f is differentiable at x0 by definition (5.1.1).

2. The function f : Rn → Rm has m output components y1, y2, . . . , ym. Wecan read the limit component wise

limt→0

(y1(x0 + tej)− y1(x0), y2(x0 + tej)− y2(x0), . . . , yn(x0 + tej)− yn(x0))

t

and then we recognize that the ith component

limt→0

(yi(x0 + tej)− yi(x0))

t

is the partial derivative ∂yi/∂xj .

3. The jth column of the matrix for a linear transformation L is Lej .

4. The given formula is just the summation notation version of (3.2.7) appliedto (5.2.2).

i, j entry of [D(f ◦ g)(t0)] = (ith row of [Df(x0)])·(jth column of [Dg(t0)]).