1 calculus 3 dr jason samuels course notessocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · ....

126
1 CALCULUS 3 DR JASON SAMUELS COURSE NOTES Table of Contents: 4 Sequences and Series 4 Sequences 8 Series 8 Intro 9 Tests for Convergence 9 The n-th term test (NTT) 10 Integral test (IT) 12 Direct Comparison test (DCT) 12 Limit comparison test (LCT) 13 Alternating Series Test (AST) 14 Ratio Test (RaT) 14 Root test (RoT) 14 Summary 15 Power Series 16 Power Series as Functions 16 find the power series of a function using algebra & calculus 18 Finding the Power Series of a Function: Taylor and Maclaurin Series 21 Taylor and Maclaurin Series, math applications 23 Other coordinate representations 23 Parametric equations 24 Calculus with Parametric equations 24 Derivative 26 Integral 26 Area 26 Arc length 27 Surface area 27 Polar coordinates 29 Calculus with polar coordinates 29 Derivative 29 Integrals 29 Area 30 Arc length 31 Surface area 32 Three Dimensions and Vectors 32 A coordinate system for 3 dimensions 33 Distance 34 What is a vector 34 Vector arithmetic- scalar multiplication and vector addition 35 Vector length 36 Vector direction (the unit vector) 36 Dot product 37 Application in math: vector components (or projections) 37 Application in physics: force & work 38 Cross product

Upload: others

Post on 24-Aug-2020

2 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

1

CALCULUS 3

DR JASON SAMUELS COURSE NOTES

Table of Contents: 4 Sequences and Series 4 Sequences 8 Series 8 Intro 9 Tests for Convergence 9 The n-th term test (NTT) 10 Integral test (IT) 12 Direct Comparison test (DCT) 12 Limit comparison test (LCT) 13 Alternating Series Test (AST) 14 Ratio Test (RaT) 14 Root test (RoT) 14 Summary 15 Power Series 16 Power Series as Functions 16 find the power series of a function using algebra & calculus 18 Finding the Power Series of a Function: Taylor and Maclaurin Series 21 Taylor and Maclaurin Series, math applications 23 Other coordinate representations

23 Parametric equations 24 Calculus with Parametric equations 24 Derivative 26 Integral 26 Area 26 Arc length 27 Surface area 27 Polar coordinates 29 Calculus with polar coordinates 29 Derivative 29 Integrals 29 Area 30 Arc length 31 Surface area

32 Three Dimensions and Vectors 32 A coordinate system for 3 dimensions 33 Distance 34 What is a vector 34 Vector arithmetic- scalar multiplication and vector addition 35 Vector length 36 Vector direction (the unit vector) 36 Dot product 37 Application in math: vector components (or projections) 37 Application in physics: force & work 38 Cross product

Page 2: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

2 39 Math applications: area and volume 40 Application in Physics: force & torque 42 Lines 43 Planes 44 Math applications with lines & planes: angle, intersection, distance 47 Vector Functions and Calculus 47 Curves in space 48 Derivatives 49 Integrals 49 Arc Length 50 Unit Tangent, Unit Normal, Binormal Vectors

50 Curvature 52 Surfaces & Functions of several variables 52 Surfaces

54 Functions of several variables 54 Level Curves 57 Derivatives for functions of several variables 57 A review of derivatives for y=f(x)

57 Intro to Partial Derivatives (numerically, graphically, algebraically) 60 Higher partial derivatives 61 Summary of intro to partial derivatives 61 Tangent Plane 62 Linear Approximation 62 Differentials 64 Chain Rule 65 Implicit Differentiation 66 The Directional Derivative and the Gradient 67 The Connection Between the Gradient and Level Curves 69 Application in Math: Maximum & Minimum 71 Application in Math: Solving Optimization with a Constraint (with Lagrange Multipliers) 73 Taylor Polynomials for Functions of Several Variables 74 Integration with Functions of Several Variables 74 Intro 75 Double Integral as a Volume 79 Double Integral as an Area 80 Applications of Multiple Integrals 80 Average value 81 Surface area

82 Density, mass, and center of mass 84 Probability 85 Double integral with polar coordinates 85 Triple integrals 86 Other coordinate systems in 3 dimensions 86 Cylindrical 86 Spherical 86 Integration 87 Vector Calculus 87 Intro to vector fields 89 Vector field operators swirl, divergence and curl

Page 3: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

3 92 Line integrals 92 For scalar functions

94 Application in Physics: Density and Mass 94 For vector field functions 96 Two ways to connect scalar line integrals and vector field line integrals

97 Fundamental Theorem of Line Integrals (FTLI) 98 Application in Physics: Conservation of Energy

99 Green’s Theorem 101 Parametric Surfaces

101 Tangent Plane for Parametric Surfaces 101 Surface Integrals

102 Application in Math: Surface Area for Parametric Surfaces 103 Application in Physics: density, total mass and center of mass 104 Surface Integral for Vector Fields 104 Application: Electrodynamics 104 Application: Thermodynamics

107 Limits for Multivariable Calculus 107 Numerical 108 Graphical 110 Algebraic 110 Limit definition of the derivative

111 Limit definition of the integral Appendix

Page 4: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

4 Sequences and Series Sequence: a list of numbers Series: a list of numbers that are added together Term: each number (or expression) in the sequence or series Sequences Ex) 2,3,4,5,6,7,8,9

that’s a sequence, just not a very interesting one What is the fifth term? Ex) 2,3,5,7,11,13,… What’s the next term? Ex) 1,1,2,3,5,8,13,21,… What’s the next term? Ex) 1,4,9,16,…

What is the next term? Notation: to represent the whole sequence, we write {an}. In this example, an=n2

To represent one term, we write a3. In this example, a3 = 9. It is a tradition to use {an} and {bn} or {ai} and {bi} for sequences (and series). That subscript is called the index. Ex) an = (.3)n … write the first five terms (starting at n=1) Note that some sequences (and series) allow you to write down a formula for a term (like the fourth example), some let you write down a formula but using the other terms (like the third example), and some do not permit any formula (like the second example). In this course we will study the easiest situation, the first one. In this class we usually will talk about infinite sequences and series. If the list was finite, you would just write the terms down (for a sequence) then add them up to find the sum (for a series). This is more difficult when there are an infinite number of terms. We will study the techniques of how to analyze that situation. Limits, or describing the target value of the sequence Ex) for the sequence {1, 1.9, 1.99, 1.999, 1.9999, 1.99999,…} is there a number the terms are heading toward? If so, what is it? Notation:

for the sequence, {an} = {2 −�

���}, limn→∞ an = 2

It is tradition to refer to the limit as L. so in this example, L=2.

Note: In this formula, n starts at 0. If we want to make n start at 1, we could write {2 −�

�����}

Rewriting the formula so n starts at a different value is called reindexing. Since we only care about what happens “at infinity”, starting at n=0 or n=1 does not change the answer. In problems about series, when we are adding terms, it does change the answer. We can graph a sequence by putting the index values on the horizontal axis. An illustration of different ways sequences can converge to a limit:

Page 5: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

5

[omit] We can use the laws of limits to make some rules to rewrite limits on complicated sequence formulas into easier formulas.

Note that the formulas basically say that you can split up addition, subtraction, multiplication, division, exponents, and (continuous) functions into separate limits to calculate them individually

Ex) lim�→ �

������

�� +

���

= lim�→ � �����

�� + lim

�→ � �

��

= cos �lim�→ � ��

��� + lim

�→ � �

��

= cos(0) +0 = 1

One useful technique for finding the limit of a sequence is called the Squeeze Theorem

Note how bn is “caught” between an and cn, and gets “squeezed” to the value L.

Ex) find the limit of an = ��� (��)

��

Page 6: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

6 Do all sequences have a limit? Of course not. Ex) find the limit of an = (-1)n The sequence is: 1, -1, 1, -1, 1, -1,… Is there a single target value? No. The limit does not exist. We say the sequence diverges. A graph of this diverging sequence:

Determine if the sequence converges or diverges. If it converges, state the limit. Ex) an = e1/n

Ex) an = 3n [omit] Two tricky limits:

Ex) find the limit of an = �!

�� [note that for the limit of a sequence we assume that n→∞ if nothing is wri�en]

How do we find the limit? If you take the limit of numerator and denominator separately, you get �

� We try to

use L’Hopitals Rule, but we cannot because we don’t know the derivative of n! So let’s explore the sequence by writing out some terms:

a1 = �

� … a2 =

�∙�

�∙� … a3 =

�∙�∙�

�∙�∙� …

in general, an = �∙�∙�…�

�∙�∙�…�

an = �

�∙�∙�…�

�∙�…� so therefore an <

so 0 < an < �

also limn→∞ (0) = 0 and limn→∞ ��

�� = 0, so limn→∞ an = 0

ex) find lim�→ � √�!�

Let lim�→ � √�!�

= �

lim�→ � ln√�!�

= ln�

lim�→ ��

�ln(�!)= ln�

Now, note that �!>�

�∙�

�+ 1� ∙… ∙(� − 1)∙� > �

��

(this is true for all even n, and that is sufficient because n! is an increasing expression)

So, lim�→ ��

�ln(�!)> lim

�→ �

�∙ln�

��

�= lim

�→ �

�∙ln�

�� → ∞

Some other terminology and definitions A sequence is increasing if it is always getting bigger: an+1 > an A sequence is decreasing if it is always getting smaller: an+1 < an A sequence is bounded above if there is a value it never goes above: an < M for all n (M for max)

Page 7: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

7 A sequence is bounded below if there is a value it never goes below: an > m for all n (m for min) A sequence is bounded if it is bounded above and below (Note that if M is a boundary above, so is M+1 or M+5. It is a different question to find the “best” boundary.) Note: one technical point. A sequence is a list of values, so it is discrete. Our familiar functions take on continuous values. Does this make a difference when taking a limit? The following picture makes clear that there is no difference.

This can be stated as a formal theorem:

[omit] There is a formal definition for limits of sequences. It is not necessary for our purposes. It is presented here, with a brief explanation, as advanced material. The intuitive idea behind the limit of a sequence is, you can make the terms as close as you want to the limit value by going as far along in the sequence as you need.

Ex) For an = 2 −�

��� (starting at n=0), suppose we want to get within .01 of the target value. You need to go to

n=2, then that term and every term after is within .01 of the target value. Suppose we want to get within .00003 of the target value. Then a5 and every term after is close enough. That “within” amount is called the error E. Thus, we can make our error as small as possible. In formal notation, this is:

limn→∞ an = L means: for every error E, there is some place in the sequence N so that if n>N then |an-L|<E

Page 8: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

8 Series What is 2+4+6+8+10+… ? Clearly the sum is getting bigger and bigger, going toward infinity Notation: sum S = ∑ 2��

��� diverges.

What is 1 +�

�+

�+

�+

��+ … ?

After 1 term, sum = 1

After 2 terms, sum =1 �

After 3 terms, sum = 1�

After 4 terms, sum = 1�

Can you make a guess what the entire sum equals?

Notation: sum S = ∑ ��

���

���� = ?

We will prove this later. For now, here is a picture that supports this result: For a series, when we take the sum of the first k terms, that is called a partial sum.

Notation: We write it Sk. In this example, S4 = 1�

�.

S1 = 1

S2 = 1 +�

S3 = 1 +�

�+

S4 = 1 +�

�+

�+

Note that the sum of the series can be determined by looking at the list of partial sums, which is a sequence, and taking the limit.

Notation: S = ∑ ������ Sk = ∑ ��

���� S = lim�→ � ��

Note: It is handy to call the series S and the partial sum Sk so you don’t have to write the summation notation repeatedly when solving a problem. Geometric Series

Let’s prove that earlier result about the sum S = 1+ �

�+

�+

�+

��+ …

Multiply both sides by ½ to get �

�S =

�+

�+

�+

��+ ⋯

Subtract equations to get �

�S = 1

So S = 2 This particular technique works on a special type of series called a geometric series. Notation: a geometric series S can be written S = a+ar+ar2+ar3+… = ∑ ����

��� . “a” is the first term and “r” is the ratio. Given one term, you multiply by r to get the next term. In our example, the first term is a=1 and

the ratio is r = �

What is the general formula for the sum of a geometric series? Let’s look at the partial sum, then use our technique.

Page 9: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

9 Sk = a + ar + ar2 + ar3+ … + ark-1 + ark

rSk = ar + ar2 + ar3 + ar4 + … + ark + ark+1

Sk - rSk = a - ark+1

(1-r)Sk = a(1-rk+1)

Sk =�(������)

���

S = lim�→ � �� = lim�→ �

�(������)

��� = ?

The result depends on rk+1 which depends on r. If r is large, rk+1 will become infinity, so the sum diverges. If r is

small, rk+1 will become 0, and the sum is S = �

���

To be precise, for -1<r<1 (or |r|<1), the sum converges. Otherwise the sum diverges.

Ex) find S = ∑ 2 ��

���

����

Ex) find S = ∑ 3��

��� Telescoping Series

Ex) find S = ∑�

�(���)����

To solve this requires some algebraic manipulation.

S = ∑�

�−

�������

Write out the terms of the partial sum: Sk = �1−�

�� + �

�−

�� + �

�−

�� + ⋯ + �

�−

����

Terms cancel! Sk = 1 - �

���

Now find the sum S = lim�→ � �� = lim�→ � 1 − �

��� = 1

This is called a telescoping series because terms cancel, knocking out the middle like a collapsing telescope. This type of series appears when we can factor the bottom and split it into fractions.

Ex) calculate S = ∑�

�����������

Page 10: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

10 Tests for Series Convergence

So far, we analyzed series where we could calculate the sum. For most series, we will only have the tools in this course to determine whether or not the series converges, not the actual sum. Nth term test (NTT) Ex) does the series 1.1+1.01+1.001+1.0001+… converge? [discuss]

This sum cannot converge, because it is always getting bigger by at least 1. (Note: do not confuse this with the sequence, which converges to 1.) The n-th term test: For the series ∑ ��

���� , if lim�→ � �� ≠ 0, then the series diverges.

Ex) does ∑�����

��������� converge?

Note that the converse is not true. If lim�→ � �� = 0 we do not know that the series converges, as we will prove using the next test. What are the indications to use the N-th term test?

- You should always use the N-th term test first (unless another test is clearly indicated) The Integral Test (IT)

Consider the sum S = ∑�

������

The graph of the sequence {an} looks like this:

We can rewrite the sum as S = ∑

������ ∙1, and depict 1 as the width of the rectangle, then the sum is an area.

Now the graph of the sum, compared with its function graphed continuously, looks like this:

Page 11: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

11

Notice that the sum is an approximation of the area under the curve, the actual area (plus the first sum term)

is bigger. So ∫�

���

��� + �� > ∑

������ . But now, let’s draw the rectangles on the other side:

Now the integral is less than the whole sum: ∫

���

��� < ∑

������

Put it together and you have: ∫�

���

��� < ∑

������ < ∫

���

��� + ��. Therefore the integral is a good

approximation for the sum. In general, we have that ∫ �(�)�

��� < ∑ ��

���� < ∫ �(�)

��� + ��. Further, if

the integral converges, then the sum converges, and if the integral diverges, then the sum diverges. Note that this only works if the terms (or function) are positive and decreasing. If not, then sometimes the rectangles are above the function, sometimes below, so the inequalities aren’t true and you cannot make a generalization.

Ex) does ∑�

����� converge?

Note that limn→∞(1/n) = 0. This shows that the converse of the NTT is not true.

Ex) for which values of p does the series converge: ∑�

������

Page 12: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

12 This is called a p-series, and will be very useful going forward, since we will often compare other series to it to determine if they converge or diverge.

Ex) does ∑�

��/����� converge?

Ex) use the integral test to check if the series converges: ∑ ����

��� What are the indications to use the integral test?

- When the formula is a function we know how to integrate What are the requirements to use the integral test?

- The terms (or function) must be positive and decreasing [omit] Estimating a Series using a partial sum, and estimating the error with an integral One way to estimate the sum of an infinite series S is to add the first k terms and then “give up”. That is easy, but is it useful? Yes – if we can show that the error (or remainder) from doing that isn’t too big. If the infinite series is S = a1+a2+a3+… and the partial sum is Sk = a1+…+ak, then Sk leaves out the remainder Rk = ak+1 + ak+2 + … = ∑ ��

������ . If {an} is a positive, decreasing sequence, we can estimate the error (the sum Rk) using an

integral from our formula earlier:

� �(�)�

���

�� < � ��

�����

< � �(�)�

��

Ex) for �= ∑�

������

a) Estimate the sum with S6 b) Estimate the maximum error for S6 c) How many terms are needed to ensure that the error is less than .001 ?

The Direct Comparison Test (DCT)

We know that S = ∑ 2 ��

���

���� converges, because it’s a geometric series with |r|<1. But what about T= ∑ 2

��

��������

That’s not a geometric series. But how does it compare to our known geometric series? It’s smaller, in that every term is smaller (because the denominator is bigger). S converges, and T is smaller; so T converges. That’s the basic idea. Here is the formal statement: For two series S=∑an and T=∑bn with all positive terms If S converges and bn ≤ an, then T converges If S diverges and bn ≥ an, then T diverges

Ex) show that S = ∑�

��/������� diverges

Note that this test does not work the other way. If a series T has terms bigger than the terms of a series S that converges, it could converge or diverge. For example, if S converges to 3 and T is bigger, it could be 5 or ∞.

Page 13: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

13 What are the indications to use the Direct Comparison Test?

- When the given series closely resembles a known series Limit Comparison Test (LCT) Let’s start with a simple idea, and extend it to a harder one. If you double every term of a series, then the sum doubles. And whether the first series converges or diverges, the second series does the same. What if you approximately double each term? Then the series should approximately double. Again, whether the first series converges or diverges, the second series does the same. Now let’s make that idea rigorous.

Suppose Σ an and Σ bn are infinite series with positive terms. If limn→∞��

�� =c, where c is a finite number (not 0),

then either both series converge or both diverge. A proof of the LCT is in the appendix.

Ex) determine whether the sum converges or diverges: S = ∑�

�����������

ex) determine whether the series converges or diverges: S =∑����

�������������

what are the indications to use the LCT?

- When the given series, in the limit, resembles a known series What are the requirements to use the LCT?

- Both series must have all positive terms (after a certain point) Alternating Series Test (AST) An alternating series is a series whose terms alternate between positive and negative.

Ex) 1−�

�+

�−

�+

�− ⋯

Notation: S = b0 – b1 + b2 – b3 + b4 - … where bn > 0 OR S =∑ (−1)���

���� (so an = (-1)nbn )

If it starts with a negative term, that could be written S =∑ (−1)���������

This type of series converges or diverges under very straightforward conditions. AST: for S =∑ (−1)���

���� , bn positive, if limn→∞ bn = 0 and bn decreasing, then the series converges. If not

then it diverges. The reason for this can be explained with a picture: For an alternating series, what if you approximate the sum S with the partial sum Sk, what is the error? From the picture, you see that it is at most the next term, bk+1. Note that this method to estimate the error only works for alternating series (think of the picture). So, for Sk, E < bk+1

Ex) for the alternating series S = ∑ (−1)��

������ (a) prove that it converges (b) use S4 to estimate the sum and

the maximum error of that estimate (c) find the sum with error less than .0001

Page 14: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

14 What are the indications to use the Alternating Series Test?

- When you have an alternating series you use the AST, and at no other times Before the next test, we need to define a few terms.

We saw that ∑�

� diverges, but ∑(−1)� ∙

� converges. When a series converges as it is, but not when you

take the absolute value of the terms, it is conditionally convergent. If it converges even when you take the absolute value, it is absolutely convergent. Note that if a series is absolutely convergent then it is convergent. That is because taking the absolute value of each term can only make the sum of a series bigger. Ratio Test (RaT)

For a series �= ∑ ������ , if lim�→ � �

����

��� < 1, then the series converges absolutely, so it converges. If the

limit >1, the series diverges. If the limit = 1, there is no conclusion.

Ex) use the ratio test to prove that ∑�

������ converges

Ex) use the ratio test to prove that ∑�!

������ diverges

Ex) what does the ratio test tell us about the two series ∑�

����� and ∑

������

The proof of the Ratio Test uses geometric series, and appears in the appendix. What are the indications to use the Ratio Test?

- This is one of the most powerful tests, it is used in many different problems - When you see a factorial or a variable exponent

The Root Test (RoT)

For a series �= ∑ ������ , if lim�→ � �|��|

� < 1 then the series converges. If the limit > 1, the series diverges.

If the limit = 1, there is no conclusion.

Ex) determine if the series S converges, S = ∑ �����

���

����

What are the indications to use the root test?

- When the entire term is raised to a power involving n.

Page 15: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

15 A Summary of the Tests for Series Convergence For two types of series, we can check convergence and also find the sum. Geometric series: A geometric series S can be written S = a+ar+ar2+ar3+… = ∑ ����

��� . “a” is the first term and “r” is the ratio.

For -1<r<1 (or |r|<1), the sum converges, S = �

���. Otherwise the sum diverges.

Telescoping series:

A telescoping series is one in which most terms cancel. It is usually written in the form ∑�(�)

�(�) for polynomials

p(n) and q(n). To find the sum, use partial fractions, find the partial sum Sk and take the limit S=limk→∞Sk

P-series:

∑�

�� converges for p>1, otherwise diverges.

The n-th term test (NTT): For the series ∑ ��

���� , if lim�→ � �� ≠ 0, then the series diverges.

Typical indications to use the N-th term test: always use the N-th term test first (unless another test is clearly indicated) The integral test (IT): for ∑ ��

���� , where f(n)=an is positive and decreasing, calculate ∫c

∞ f(x)dx. if the integral converges, then the sum converges, and if the integral diverges, then the sum diverges. Typical indications to use the integral test: when the formula is a function we know how to integrate. The Direct Comparison Test (DCT) For two series S=∑an and T=∑bn with all positive terms: if S converges and bn ≤ an, then T converges; if S diverges and bn ≥ an, then T diverges. Typical indications to use the Direct Comparison Test (DCT): when the given series closely resembles a known series The Limit Comparison Test (LCT):

Suppose Σ an and Σ bn are infinite series with positive terms. If limn→∞��

�� =c, where c is a finite number (not 0),

then either both series converge or both diverge. Typical indications to use the Limit Comparison Test (LCT): when the given series, in the limit, resembles a known series. The Alternating Series Test (AST) For S =∑ (−1)���

���� , bn positive and decreasing, if limn→∞ bn = 0, then the series converges. If not then it

diverges. Typical indications to use the Alternating Series Test (AST): When you have an alternating series you must use the AST, and at no other times. The Ratio Test (RaT)

For a series �= ∑ ������ , if lim�→ � �

����

��� < 1, then the series converges absolutely, so it converges. If the

limit >1, the series diverges. If the limit = 1, there is no conclusion. Typical indications to use the Ratio Test (RaT): When you see a factorial or a variable exponent. (This is one of the most powerful tests, it is used in many different problems.) The Root Test (RoT)

For a series �= ∑ ������ , if lim�→ � �|��|

� < 1 then the series converges. If the limit > 1, the series diverges.

If the limit = 1, there is no conclusion. Typical indications to use the Root Test (RoT): when the entire term is raised to a power involving n.

Page 16: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

16 For the following series, which test would you use to make a conclusion about convergence? (Note the abbreviated sum notation. We assume the sum is for n going to ∞, which is all we need to solve it.)

Ex) ∑�

���� (�)

Ex) ∑(−1)�√�

���

Ex) ∑�� (�)

√�

Ex) ∑��

��

Ex) ∑ 1.1(−0.4)�

Ex) ∑ ln���

��������

When you solve test a series for convergence, make sure you (a) state which test you are using (b) show that you have satisfied the test conditions (c) state your conclusion about your original series Power Series Next we will look at a very important type of series and see how it is a powerful tool to do advanced mathematics. A power series has the form S = c0 + c1x + c2x

2 + c3x3 + … = ∑ ���

����� where the cn are real number

coefficients. It may help to think of it as an infinite polynomial. Again we want to know if a given series converges. With power series, we always use the ratio test (because it always works).

Ex) test the convergence of S = ∑���

��������

Ratio test: lim�→ � �(���)����

����� �∙����

���� = lim�→ � �

(���)

�∙����

��∙

����

����� �� =

�|�|

In the RaT, when L < 1, the series converges. So S converges when |x| < 3 (or -3<x<3). But recall that there is no conclusion for L=1. So when |x|=3, we don’t know if the series converges or diverges, so we have to check.

x=3: S = ∑���

�������� = ∑

����� by the n-th term test, lim an ≠0 so the series diverges

x=-3: S = ∑�(��)�

�������� = ∑

�(��)���

�������� = ∑

�(��)�

����� by the n-th term test, lim an ≠0 so the series diverges

Therefore, the power series converges for -3<x<3. This is called the interval of convergence. The center of the interval ‘a’ is at x=0. The interval extends by 3 in each direction, so 3 is the radius of convergence R. Note that a power series is a function of x, there will always be values of x for which the series converges, we must determine which values they are. Ex) find the interval of convergence for S = ∑ �!(� − 2)��

��� RaT:

Page 17: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

17 This is always infinity and the series always diverges – unless x=2. So the interval of convergence is x=2 (a single point). The center is a=2, and the radius is R=0.

Ex) find the interval of convergence for S = ∑��

�!����

RaT: So the series converges for all real values of x. The interval of convergence is (-∞,∞) OR -∞<x<∞ and the radius of convergence is R=∞. (Since the interval is all real numbers, we don’t need a center.) Power Series are Functions A power series is clearly an expression involving x. It acts like a function in three different ways. First, consider f(x) = ∑ ���

��� Then f(0.5) = 1+0.5+0.52+0.53+… which is some value.

Second, f(x) = ∑ ������ is a geometric series with first term 1 and ratio x. Thus, f(.5) =

��.� = 2. Note that this

series has an interval of convergence -1<x<1, so that is the domain of the function.

Third, as a result, it is now clear that f(x) = ∑ ������ =

��� as long as -1<x<1. So we see that a typical function

can be written as a power series! There are different ways to rewrite a function as a power series. We will look at three. Developing the power series for a function through algebra

We know that: �

���= 1 + � + �� + �� + ⋯ �� ∑ ���

���

So what about:

Ex) what is the power series for �

���� ?

By a simple substitution,

Ex) what is the power series for �

��� ?

By multiplication, Note: it is not at all obvious that these manipulations are always allowed, since we are working with an expression with an infinite number of terms. However, theorems from higher mathematics prove that this works. Those proofs are beyond the scope of this course. The center and radius of convergence of the new series after algebraic manipulation are retained from the original series. Developing the power series for a function through calculus

Again, we know that: �

���= 1 + � + �� + �� + ⋯ �� ∑ ���

���

Ex) what is the power series for �

(���)� ?

By taking the derivative of a known series, we get:

Page 18: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

18 Several amazing things happened in that calculation which deserve explanation. First of all, are we allowed to take the derivative of an infinite number of terms? Yes (the theorem is given below). Second, how do we know that, after taking the derivative, the function and the power series are still equal? That’s another theorem. Part of that theorem says that the equality is only true for appropriate values of x. For example, at x=5, the original equality is invalid, so it is still invalid after you take the derivative. (The interval of convergence of the new series is almost the same as the interval for the original series. It has the same center and radius. However, the new series may diverge at the endpoints.) One tricky detail is the way the sum boundary changed in the last step from n=0 to n=1. Why did it change? Because when the derivative is taken, the n=0 term is a constant and so it disappears. It is quicker to do this calculation using the summation notation, because there is less to write down. However, that makes it easy to miss small details like this one. Now, lets do the same thing with integration. Ex) find the power series for ln|1-x| Since we want to have the function ln|1-x|, plug in x=0 to solve for C: ln(1)=C …so… C=0 (Note that specifying the result after integrating is like specifying an initial condition, so you can solve for C) Note that the center and radius of convergence are same as the original series, a=0, R=1. Theorem for the derivative and integral of power series (the proof is beyond the scope of this course) For the power series f(x):

f(x) = c0 + c1(x-a) + c2(x-a)2 + … = ∑ ��(� − �)�����

with an interval of convergence with radius R and center a, the derivative and integral are: f’(x) = c1 + 2c2(x-a) + 3c3(x-a)2 + … = ∑ � ∙��(� − �)����

���

∫ f(x) dx = C + c0(x-a) + ½ c1(x-a)2 + … = C + ∑ ��(���)���

�������

Both the integrated and differentiated series have the same center and radius of convergence.

Developing the power series of any function: Taylor and Maclaurin series In this section, we will achieve two goals for any given function - we want an expression with all the same derivatives & we want a power series equal to the function. We will accomplish both at the same time. Previously, we have approximated a function with a polynomial – specifically, a linear function. f(x) ≈L(x) = f(a) + f’(a) (x-a) Can we make a better approximation? Well, since this approximation has the same value and first derivative (or slope) at x=a, we could find an expression with the same second derivative. And same third derivative…

Page 19: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

19 The most effective way to do this is with a polynomial. You will see why this works as we develop the formula. Also, one advantage of having a polynomial is that it is much easier to calculate with than many other types of functions. (For example, we have no good way to find a value for sin(1.2). We will see several applications showing the benefits of these polynomials.) We will see that the approximation becomes exact with an infinite number of terms; that “infinite polynomial” is a power series. Here is the notation for our goals: For some function f(x), we will start with the approximation:

f(x) ≈ c0 + c1(x-a) + c2(x-a)2 + c3(x-a)3 + … + ck(x-a)k = ∑ ��(� − �)�����

Eventually, we want the equality: f(x) = c0 + c1(x-a) + c2(x-a)2 + c3(x-a)3 + … = ∑ ��(� − �)��

��� [The expression simplifies if we use a=0, since you get cnxn. We will often do that, but not always.] All we need to know is what those coefficients cn are. For the first step, we will very cleverly plug in x=a, and almost every term cancels, leaving f(a) = c0. So we can solve for the constant term. Now, we will one by one put each coefficient in the constant position. How can we do that? By taking the derivative. f’(x) = c1 + 2c2(x-a) + 3c3(x-a)2 + 4c4(x-a)3 + … Plug in x=a to get f’(a) = c1 f’’(x) = 2c2 + 6c3(x-a) + 12c4(x-a)2 + … So f’’(a) = 2c2 f’’’(x) = 6c3 + 24c4(x-a) + … So f’’’(a) = 6c3 Before we write the general formula, note that we are accomplishing two goals. One, assuming we want an expression with all the same derivatives as the function, we found out what the expression must be. Two, assuming we want a power series equal to the function, we found out what the coefficients must be.

In general, taking the nth derivative reveals that f(n)(a) = n!cn and therefore: �� =�(�)(�)

�!. Thus we have:

f(x) = P(x) = ∑�(�)(�)

�!(� − �)��

��� = �(�)+ ��(�)∙(� − �)+���(�)

�!(� − �)� +

����(�)

�!(� − �)� + ⋯

This special power series P(x) is called the Taylor Series of the function. In the special case where a=0, this is called the Maclaurin Series. If the expression stops at the kth term (which includes xk), that is called the kth Taylor Polynomial, Pk. For example, note that P1 is just the linear approximation for the function: P1(x)=f(a)+f’(a)·(x-a) Ex) find the Maclaurin series for f(x) = ex. Also find the interval of convergence. Ex) find the Taylor series for f(x) = ex at a=3

Page 20: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

20 Ex) find the Maclaurin series for f(x) = sin x

Ex) find the Maclaurin series for �(�)= √1 + �

Ex) find the Maclaurin series for �(�)= √1 + �� The hard way: start from step one and calculate derivatives, etc

The easy way: take the Maclaurin series for �(�)= √1 + � and replace x with x2 You can also integrate and differentiate. When you integrate remember to solve for C Ex) find the series for cos(x) by integrating the series for –sin(x)

sin(x) = � −��

�!+

��

�!− ⋯

-sin(x) = −� +��

�!−

��

�!+ ⋯

cos(x) = ∫-sin(x)dx =∫−� +��

�!−

��

�!+ ⋯ �� = � −

��

�+

��

�!−

��

�!+ ⋯

Then plug in x=0 … cos(0)=C … C=1 As we saw before, when you know what the function should be after you integrate, don’t forget to solve for C

In general, using a=0 makes the expression simplify a lot, so the Maclaurin series is easier to calculate and is more commonly used. A table of the most common Maclaurin series (with radius of convergence) is at the end of the section.

An example of finding a Taylor Series using clever shortcuts Ex) find the Maclaurin Series for sin2x

Page 21: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

21 sin2x = ½ (1-cos(2x))

= ½ (1 – �1 −(��)�

�!+

(��)�

�!−

(��)�

�!+ ⋯ �)

= ½ �(��)�

�!−

(��)�

�!+

(��)�

�!− ⋯ �

= ���

�!−

����

�!+

����

�!− ⋯

Or, using summation notation, ∑(��)�����������

(��)!����

The Taylor Remainder Theorem [bonus material] In most functions encountered in this course, a function is equal to its Maclaurin or Taylor series; this is the situation we will focus on. However, this is not automatically the case. You can determine if they are equal, and the error of an approximation, by the Taylor Remainder Theorem. We will state it & cover it briefly. Let Pn be the n-th Taylor polynomial, the Taylor series cut off after the term with (x-a)n . When approximating f(x) with Pn(x), let Rn(x) be the remainder (or error): f(x) = Pn(x) + Rn(x).

…then Rn = �(���)(�)

(���)!(� − �)��� for some value c with a<c<x

Also, if |f(n+1)(x)|<M, then |Rn(x)| < �

(���)!|� − �|��� and limn→∞Rn(x) = 0 and limn→∞Pn(x) = f(x)

Roughly speaking, this means that it’s a fact that |x-a| is finite and n! goes to infinity, so as long as all derivatives are finite, then the error term goes to 0. A proof is in the appendix. Applications: Some uses of Taylor (and Maclaurin) series

Finding approximate values

Ex) Approximate �

� (without a calculator) to within .01

Finding limits

Ex) find limx→0

���(�)�����

��

Since this limit is in the form 0/0, we could use l’hopitals rule. What would happen? …you would have to use it five times (the first four times getting the form 0/0) Finding integrals

Ex) find ∫ ������

� (leave answer as a series)

Finding sums

Ex) find 1 + 1 +�

�+

�+

��+ ⋯

[hint: S=∑�

�!���� ]

Page 22: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

22 An amazing application of Taylor series

Question: what is the value of eiπ ? (recall that i=√−1 ) We can find this using the Maclaurin Series:

eix = (��)�

�!+

(��)�

�!+

(��)�

�!+

(��)�

�!+

(��)�

�!+

(��)�

�!+

(��)�

�!+ ⋯

Summary A power series can be written as S = c0 + c1x + c2x

2 + c3x3 + … = ∑ ���

�����

For any function f(x), its power series is the Taylor Series P(x)

f(x) = P(x) = ∑�(�)(�)

�!(� − �)��

��� = �(�)+ ��(�)∙(� − �)+���(�)

�!(� − �)� +

����(�)

�!(� − �)� + ⋯

It has an interval of convergence with a radius and center. When a=0 this is called the Maclaurin Series. Let Pn be the nth Taylor polynomial, the Taylor series cut off after the term with (x-a)n . When approximating

f(x) with Pn(x), let Rn(x) be the remainder (or error): f(x) = Pn(x) + Rn(x). Then Rn = �(���)(�)

(���)!(� − �)��� for

some value c with a<c<x. Also, if |f(n+1)(x)|<M, then |Rn(x)| < �

(���)!|� − �|��� and limn→∞Rn(x) = 0 and

limn→∞Pn(x) = f(x). We can find the power series for a function using algebra, calculus, or the Taylor technique. A table of the most common Maclaurin Series:

Page 23: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

23 Other coordinate representations: parametric equations and polar coordinates What is the equation of a circle (radius=1, center is the origin)? … x2 + y2 = 1 It’s a simple equation for a simple graph, and yet it is not a function y=f(x). In this section, we will explore alternate ways to represent a graph which can be very useful. For example:

We will actually learn the equation of this graph. Parametric Equations

If we tried to describe to mathematically describe this graph, we could not write a function equation y=f(x). How could we describe it? In words, it looks like a path. Therefore, one way to describe it would be with a formula that gives our coordinates as we walk along the path. We could keep track of our journey using time. So at every time t, we need to describe our location. Our position has two components, x and y. therefore, x is a function of t and y is a function of t. Notation: this function relationship can be written explicitly as x = f(t), y = g(t), or it can be written implicitly as x = x(t), y = y(t). Either way, we assume that x & y are functions of t. (Note: Thinking of time as the parameter is the most common approach. Another common approach is the use of distance as the parameter. The important aspect is that a single variable changes to track our changing position on the path.) Ex) what is the graph of x=t2 & y=t+1 ? Ex) what is the graph of x = 4t2 & y = 2t+1 ?

Page 24: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

24 Important lesson: different equations can represent the same graph. What changes is the starting position (when t=0) or the velocity at which the graph is traveled relative to the parameter t. Each set of equations is called a parameterization of the graph, and changing from one to another is called a reparameterization. In this example, the graph was reparameterized by replacing t with 2t: for x, (2t)2 = 4t2; for y, (2t)+1 Ex) What is the graph of x = cos(t) & y = sin(t) ? A typical function y=f(x) can be graphed as parametric equations: x = t and y = f(t) Also, cases in which x is a function of y can be represented as parametric equations: y=t & x=g(t) Parametric equations are one way to generalize the idea of a function. Sometimes, we can rewrite the parametric equations with only x & y. This is called eliminating the parameter. Ex) eliminate the parameter for: x=t+3, y=t3 t=x-3 …so… y=(x-3)3

Ex) eliminate the parameter for: x=3+2et, y=5e2t

���

�=et …now we use the fact that e2t=(et)2 …so… y=5 �

���

���

Calculus with Parametric Equations Previously, you learned calculus for expressions in two variables, typically x & y. Everything you learned can be applied to parametric equations. Calculating Derivatives We want to find the derivative, or the slope of the curve. This is possible because, at any point, when we zoom in we see a straight line, and the slope of that line is the derivative. However, we cannot calculate it in the usual way because we start, not with y=f(x), but with x=x(t) & y=y(t). We do know that on any segment of the graph we can treat y as a function of x, which itself is a function of t. y = y(x) y is a function of x y(t) = y( x(t) ) both are functions of t �

��y =

��[y(x(t))] take the derivative, and your variable is t

��

��=

��

��∙��

�� this equation comes from the chain rule. It also makes sense if you cancel dx

So: ��

��=

��

��

��

��

(if ��

�� = 0, this may be undefined)

To find the second derivative, take the derivative again in this way. (Note that ���

���≠

���

���

���

���

)

Page 25: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

25

���

���=

�����

��� =

�� � ��

���

��

��

A proof of the derivative formula using limits is in the appendix. Ex) for the curve x=t2 & y=t3-3t a) Find the slope of the tangent when t=2 b) Find the slope of the tangent at (1,-2) c) Confirm that there are two tangent lines at the point (3,0), then find the slope of each one. d) Find the points where the tangent is horizontal and where it is vertical

e) Calculate the second derivative ���

���

Ex) the graph x = 2t – π sin(t) & y = 2 – π cos(t) is called a prolate cycloid. find the slope of the tangent at the point (0, 2-π) First, note that we want y=2-π, so cos(t)=1, so probably t=0. Confirm that this gives x=0.

Slope = ��

�� =

Page 26: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

26 Calculating Area We have previously seen that area can be calculated with an integral A = ∫ y dx When working with parametric equations, the variable is t, not x. So let’s adjust the equation. Observe that x

is a function of t, x=x(t), so dx=��

����.

A = ∫� ��

����

Note that your boundaries of integration are now t-values. They will correspond with your starting and ending x-values. Ex) x=4cos(t), y=3sin(t) defines an ellipse. Find the area enclosed by the ellipse.

for the boundaries of integration, x goes from -4 to 4 as t goes from π to 0

Calculating Arc Length

Recall the integration formula for arc length for a function y=f(x), s = ∫ �1 + ���

������

When we proved it, at a certain step we multiplied by dx in the numerator and denominator. This time, since t is our variable, we will multiply instead by dt. Arc length (distance) is represented by s. (Originally it was an abbreviation for the Latin word for distance, spatium.) (ds)2 = (dx)2 + (dy)2

(ds)2 = (��)��(��)�

(��)�(��)�

ds =�(��)��(��)�

(��)�(��)�

ds = ����

����+ �

��

������

∫ ds = ∫����

����+ �

��

������

s = ∫ ����

����+ �

��

������

where the boundaries of integration are t-values [Recall that you can convert to classical function notation y=f(x) by letting x=t. Applying that to this formula, you get the formula for arc length that you already knew. Once again, the parametric notation x=x(t) & y=y(t) is a generalization of the function notation y=f(x).] ex) find the circumference of a circle with radius r=3

Page 27: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

27 Calculating Surface Area Previously, we saw that the formula for the surface area from revolving y=f(x) around the x-axis was

SA = 2πhs = 2� ∫��1 + ���

������

For parametric curves, let’s just plug in the new formula for length s:

SA = 2πhs = 2� ∫�����

����+ �

��

������

Ex) find the surface area of a sphere with radius r=3 Finally, recall that graph from the beginning of the unit:

Its equation is: x=sin(t)+.5cos(5t)+.25sin(13t), y= cos(t)+.5sin(5t)+.25cos(13t) …use a grapher to see more Polar Coordinates [omit] In many cases, the most natural way to describe a location or a graph in the plane is by using (x,y)-coordinates. However, this is not always the case. For example, a natural way to describe a circle (centered at the origin) is to give the radius, say r=4. Notice how that completely describes the graph. Similarly, a straight

line (through the origin) could easily be described by the angle it makes with the x-axis, say =�

� . Again,

notice how this completely describes the line. We will now develop the coordinate system that relies on r and θ, and find it to be useful in a variety of situations. Any point on the plane can be defined by (r, θ), where r is the distance from the origin and θ is the angle formed with the positive x-axis by the line through the origin and the point.

Ex) plot the points: A (3,�

�) B (1,

��

�) C (-2,π)

Note that the easiest way to locate the point usually is to start at the origin, find the direction (angle), and then move by the amount of the radius. Note that if r=0, the point is the origin, and it does not matter what the angle is.

Page 28: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

28 It is possible to convert between rectangular and polar coordinates, using the definition of trig functions.

sin θ =�

� cos θ =

solve for y to get y=r sin θ solve for x to get x = r cos θ to solve for r, find an equation that involves only r,x,y: x2 + y2 = r2

� = ��� + ��

to solve for θ, find an equation that involves only θ,x,y: tan θ = �

θ=arctan�

Note that tan is a periodic function and the arctan function only provides values for θ so that −�

�≤ θ ≤

�.

You must be careful to choose θ so it is in the correct quadrant, when this matters. So to be precise,

θ=arctan��

��+kπ, for some integer k.

Given (x,y): (r, θ) = ���� + ��, arctan��

�� + kπ�

Given (r, θ): (x,y) = (r cos θ, r sin θ) Ex) for r = 2cos θ, (a) sketch the graph (b) find an equation in x&y Here are some interesting examples of graphs of polar equations

Ex) sketch r=2 cos 3θ

Page 29: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

29 Calculus in Polar Coordinates Again, everything you learned about calculus can be applied using polar coordinates. Calculating the derivative We want to find the slope of the tangent line. We borrow from the approach of parametric equations. Instead of introducing the variable t, we use the variable θ. (On a segment of the graph, r is a function of θ.)

��

��=

��

��

��

��

It is possible (but not necessary) to get a formula in r & θ. Assume that r = r(θ), and we get:

��(� ����)

��(� ����)

=��

��∙������ ����

��

��∙������ ����

Ex) for r=1-cos θ, (a) sketch the graph (b) find the horizontal and vertical tangents

Note: at θ=0, both ��

�� and

��

�� are 0. By examining the graph, we can conclude that this point is a cusp, the

derivative is undefined, and no tangent line exists. (This could also be determined by calculating handed derivatives.)

Calculating the integral Calculating Area with Polar Coordinates If we are using polar coordinates, we need a new integral formula for area; x·y is an area, but r·θ is not the same thing. To develop the new formula, we follow a familiar approach, using a sum of small areas. In polar coordinates, what is the basic unit for which we know the area? A circle, or a “slice of pie” called a sector. The

area of a circle is πr2 and the area of a sector is �

�� πr2, or

�θr2. Assume r is a function of θ, r=r(θ). In a small

slice, the “width” is Δθ and the “height” is r. The area of one small slice is ΔA ≈ �

�r2 Δθ. The total area is the

sum of all of those slices:

Approximate Area: A = ∑ ΔA ≈ ∑ �

�r2 Δθ

Exact Area: A = ∫ dA = ∫ �

� r2 dθ

Ex) find the area enclosed by a limacon, r=2+cosθ

Page 30: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

30 Arc Length with Polar Coordinates We start with the classic arc length formula and use the same technique from parametric equations to convert to polar coordinates. Instead of t, we use θ as our variable

L = ∫����

����+ �

��

������

L = ∫����

����+ �

��

�����θ

We can rewrite completely in r & θ.

= ∫����

�����θ − r sinθ�

�+ �

��

��sinθ + rcosθ�

��θ

= �����

����

cos� �−2���

��cos� sin� + �� sin� � + �

��

����

sin� � + 2���

��cos� sin� + �� cos� � ��

After some algebra, we get:

= ∫����

����+ �� �θ

Ex) for a circle radius r=3, find the circumference Ex) find the arc length of the cardioid, r=2-2cos θ, 0< θ<2π [set up, do not solve] Calculate the Surface Area with Polar Coordinates Previously, we saw that the formula for the surface area from revolving y=f(x) around the x-axis was

SA = 2πhL = 2� ∫��1 + ���

������

For polar coordinates, the horizontal axis is θ=0, and plug in the new formula for L:

SA = 2� ∫�����

����+ �

��

�����θ OR 2� ∫� sinθ��� + �

��

�����θ

To rotate around the vertical axis, θ=�

�, x replaces y as the height:

SA = 2� ∫�����

����+ �

��

�����θ OR 2� ∫� cosθ��� + �

��

�����θ

Page 31: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

31 Ex) find the surface area when revolving r=cos θ around the vertical axis – this is called the pinched torus

Page 32: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

32 Three Dimensions and Vectors Space – The Final Frontier. We live in three dimensions (spatially). We will now learn how to do mathematics in three dimensions. A Coordinate system for 3 dimensions First we need a coordinate system. In addition to the x-axis and y-axis, we introduce the z-axis. If the x & y axes are where they usually are, then the positive z-axis comes straight at you from your sheet of paper. It is impossible to actually draw a 3-dimensional object on a 2-dimensional piece of paper. We have to choose a perspective, and there are several typical ways to do this. In the first one, the x-axis is in the usual place. However, the axes are bunched together, so graphs tend to get squished. In the second one, the axes are spread out, but y is the horizontal axis, which is different from what we are used to. We will make drawings using the second option because they tend to be clearer. The third option is from the professional mathematics software, Mathematica. We will use that sometimes as well. (The software allows you to rotate your graph in any direction, so the orientation changes.) In all representations, z is on the vertical axis. (Often we will think of z as a function of x & y, z=f(x,y), so our function values are still represented by “height”.) Ex) graph all the points which satisfy z=0

This is just a copy of the standard xy plane Ex) graph y=2

(notice that from this angle its hard to see precisely where the plane lies) Ex) graph x=1

Page 33: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

33

Distance in 3 dimensions The distance between 2 points A (x1, y1, z1) and C (x2, y2, z2) is

Dist(A,C) = �(�� − ��)� + (�� − ��)

� + (�� − ��)�

That formula should seem pretty familiar and reasonable as an extension of the formula from 2 dimensions. Also, here is a picture and an explanation:

Consider the point B (x2, y2, z1). A & B are in the same plane, the distance between them is

Dist(A,B) = �(�� − ��)� + (�� − ��)

� B & C are on a vertical line, so dist(B,C) = z2 – z1 ABC is a right triangle, AC is the hypotenuse, so

Dist(A,C) = �(����(�, �))� + (����(�, �))� = �(�� − ��)� + (�� − ��)

� + (�� − ��)�

Ex) find the distance between (2,3,-1) & (4,-3,0) Note: you can extend this formula beyond 3 dimensions, to any dimension.

Page 34: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

34 What is a Vector A vector is a object with a magnitude and a direction. For example, speed is not a vector since it is always positive and does not describe the direction. Speed is a magnitude. However, velocity is a vector. In the 1-dimensional case, it has a magnitude, and the sign indicates forward or backward.

Note: in the discussion of vectors, sometimes the definition or an example will be given for 2 dimensions, sometimes for 3 dimensions. You should assume that any number of dimensions is possible, and the definition is what seems natural. (We already saw this for the distance formula.) In cases where an idea does not apply for all dimensions, this will be emphasized. A vector is determined by a starting point and an ending point. However, when just a vector is given, the starting point is not known. (We usually draw it at the origin for simplicity.)

Notation: to emphasize the endpoints: �������⃗ �� �������⃑ To emphasize the vector as one object: �⃗ �� �⃑ or v Ex) what is the vector with start point (4,7) and endpoint (5,3) ? Picture: calculation: The vector from (x1 y1) to (x2 y2) is (x2 – x1, y2 – y1).

Ex) draw the vector (-2,3) ? Each number is called a component. Note: one option to describe a vector is to state the magnitude, then give the direction as an angle. This indicates a choice to use polar coordinates (or the equivalent in higher dimensions) instead of xyz coordinates

Another notation for vectors: sometimes vectors are written as columns. �⃗ = �

������� This notation is useful to

compare the same component of different vectors. Scalar multiplication of vectors

We can multiply a vector by a constant, called a scalar. This will scale the vector in size (and reverse it if the number is negative). Ex) for �⃗ = (1,2) 3�⃗ = (3,6) 0.5�⃗ = (.5,1) -2�⃗ = (-2,-4) This also works for vectors in 3 dimensions (or any dimension) In general: ��⃗ = c(v1, v2, v3) = (cv1, cv2, cv3) Ex) for �⃗ = (-1,4,2) 3�⃗ = (-3,12,6) Vector Addition and Subtraction It can be helpful to think of a vector as a change (or displacement). Imagine making a trip starting at point A, taking the move indicated by ��⃑ (to point B), then making the move indicated by v�⃑ (to point C). Each part of the trip (��⃑ and v�⃑ ) is a vector, and the entire trip (w���⃑ ) is a vector.

For two vectors, ��⃗ = (u1, u2) & �⃗ = (v1, v2) …��⃗ + �⃗ = (u1+v1, u2+v2) OR ������ + �

����� = �

�� + ���� + ��

Page 35: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

35 Ex) find (3,-2) + (1,4) and draw a picture to represent the calculation This works for 3-dimensional vectors as well. Define two vectors in 3 dimensions, ��⃗ = (u1, u2, u3) & �⃗ = (v1, v2, v3) …��⃗ + �⃗ = (u1+v1, u2+v2, u3+v3) Ex) find (3,-2,7) + (-2,4,-4) A parallelogram helps to visualize addition and subtraction of vectors:

In the first parallelogram, starting at the dot, tracing ��⃗ then �⃗ yields ��⃗ + �⃗. Tracing �⃗ then ��⃗ yields �⃗ + ��⃗ . Observing the diagram should confirm that these are the same vectors. (You can also prove this algebraically using the definition.) In the second parallelogram, tracing ��⃗ then –�⃗ yields ��⃗ − �⃗. Alternately, the vector connecting the ends of u & v also yields ��⃗ − �⃗. This is clear from the parallelogram, or from the fact that �⃗ + (��⃗ − �⃗) = ��⃗ .

We can emphasize the x,y,z components of a vector using vector addition. �⃗ = (1,0,0) the unit vector in the x-direction [in 2-dimensions it would just be (1,0)] �⃗ = (0,1,0) the unit vector in the y-direction [in 2-dimensions it would just be (0,1)]

��⃗ = (0,0,1) the unit vector in the z-direction In 2 dimensions: : ��⃗ = (u1, u2) = u1 �⃗+ u2 �⃗ OR u1i + u2j

In 3 dimensions: �⃗ = (v1, v2, v3) = v1 �⃗+ v2 �⃗+ v3��⃗ OR v1i + v2j + v3k

�⃗, �⃗, ��⃗ are called the standard basis vectors. Ex) rewrite �⃗ = (3,-4,1) using the standard basis vectors

�⃗ = 3�⃗ -4�⃗ + ��⃗

About notation: 3�⃗ − 4�⃗ + ��⃗ = 3�100� − 4�

010� + 1�

001� = �

300� + �

0−40� + �

001� = �

3−41�

Note that sometimes there is no distinction between the notation for a point and for a vector. We can think of a vector as a point. Or, we can think of a point as a vector. (Its starting point would be the origin.) This equivalence can be useful, but it can also be confusing. We will keep this in mind as we proceed. So far, all vector properties discussed also apply to vectors in 3 dimensions. Of course, on a sheet of paper, it is easier to draw vectors in 2 dimensions, so often the examples and explanations are presented like that. Length of a vector The length (or magnitude or norm) of a vector can be calculated by taking the origin as the starting point, the coordinates as the endpoint, and using the distance formula. Notation: the magnitude of �⃗ = (v1, v2, v3) is |�⃗| or ‖�⃗‖

|�⃗| = �(��)� + (��)

� + (��)�

Ex) find |(5,-2,4)| Note that, for a vector �⃗ and a number c, |c�⃗|= |c|·|�⃗| As an obvious example, |(1,0)| = 1 and |3(1,0)|=3

Page 36: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

36 Direction of a vector: the Unit Vector We have a way to represent the magnitude of a vector. How can we represent the direction? One way is with a vector that has a magnitude of 1. This is called a unit vector. To turn a vector into a unit vector, divide by

the magnitude. The unit vector ��⃗ in the direction of �⃗ is: ��⃗ = �

|��⃗ |�⃗ or

��⃗

|��⃗ |

Ex) for �⃗=(8,6), find (a) the magnitude (b) the direction (as a unit vector) Why does a unit vector represent direction? Note that, in polar coordinates, we could give the direction with an angle. If you think back to some activities from trigonometry, an angle could also be specified with a point on the unit circle; a unit vector does exactly that. Further, note that for a unit vector ��⃗ and a positive number c, |c��⃗ |= |c|·|��⃗ | = c. This demonstrates how a unit vector only indicates a direction and does not contribute to the magnitude. The Dot Product So far we added vectors. Is it possible to multiply vectors? What would it mean? To explain the dot product of two vectors, first we show the formula, then we discuss what it means. In 2 dimensions, for ��⃗ = (u1, u2) & �⃗ = (v1, v2), we define the dot product ��⃗ ∙�⃗ = u1v1 + u2v2 In 3 dimensions the calculation is similar. For ��⃗ = (u1, u2, u3) & �⃗ = (v1, v2, v3), ��⃗ ∙�⃗ = u1v1 + u2v2 + u3v3

Using column vector notation: �

������� ∙�

������� = ���� + ���� + ����

Note that the result of a dot product of two vectors is a real number (or scalar) and not a vector. Ex) find (1,4,1)·(2,0,-3) The dot product has properties like multiplication with real numbers. If a,b,c are vectors, k is a scalar: a ∙ a = |a|2 a · b = b · a a · (b+c) = a · b + a · c (k a) ·b = k(a ·b) = a ·(kb) It is possible to prove these by writing out the components. For example, for �⃗ = (a1, a2, a3)

�⃗ ∙�⃗ = a1·a1 + a2·a2 + a3·a3 =��(��)� + (��)

� + (��)��

�= |�⃗|�

The dot product has a nice property: ��⃗ ∙�⃗ = |��⃗ |·|�⃗|cos θ where θ is the angle between the vectors This can be proven using the Law of Cosines with the vectors ��⃗ , �⃗, and ��⃗ − �⃗. |u-v|2 = |u|2 + |v|2 – 2|u|·|v|cosθ Also, |u-v|2 = (u-v)·(u-v) = u·u - u·v - v·u + v·v = |u|2 + |v|2 – 2u·v Setting them equal: |u|2 + |v|2 – 2|u|·|v|cosθ = |u|2 + |v|2 – 2u·v So: u·v = |u|·|v|cosθ

OR: cosθ = �∙�

|�|∙|�|

Page 37: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

37 Ex) find the angle between (3,0) and (0,5) cosθ =

cos θ = 0, so θ = arcos(0) = �

�. Since the vectors lie on the x-axis and y-axis, that is what we expected.

Note that these two vectors are perpendicular. So we can observe that two vectors are perpendicular (or orthogonal or normal) precisely when their dot product is 0. Notation: ��⃗ ⊥ �⃗ precisely when ��⃗ ∙�⃗ = 0 Two vectors are parallel if they point along the same line (same or opposite direction). This means that one must be a multiple of the other. ��⃗ and �⃗ are parallel precisely when ��⃗ = ��⃗ Also, note that same direction means that the angle between them is 0 (or π). Therefore: ��⃗ and �⃗ are parallel precisely when |��⃗ ∙�⃗| = |��⃗ |·|�⃗| Ex) are (3,1) & (-6,-2) parallel, perpendicular or neither? Ex) are (3,5,1) & (0,-1,5) parallel, perpendicular or neither? Dot product math application: Splitting vectors into components (or projections) Often we are interested in breaking down a vector into components. When we write down vectors in the usual way, we are giving the x-, y- and z-components. Ex) find the x-component of (4,3), also find its magnitude But we might want the component in a different direction. In the picture are two vectors, ��⃗ and �⃗. �⃗ has been split into two components, one parallel to ��⃗ , called ������⃗ one perpendicular to ��⃗ called ���������⃗ . Note that ������⃗ + ���������⃗ = �⃗

To find the component (or projection) in the ��⃗ direction, we find its magnitude and direction. Note that it is one leg of a right triangle, so its length is |�⃗|cosθ. It is parallel to ��⃗ so it is a multiple of ��⃗ . We want the vector ��⃗ to contribute direction, but not magnitude, so we divide by the magnitude of ��⃗ .

Length = |�⃗�| = |v|cos θ = ���⃗ ∙��⃗

|���⃗ | … direction (unit vector) =

���⃗

|���⃗ |

Component of �⃗ in ��⃗ direction: vector ������⃗ = |�⃗|cosθ ���⃗

|���⃗ |=

|��⃗ |����|���⃗ |

|���⃗ |∙|���⃗ |��⃗ =

���⃗ ∙��⃗

���⃗ ∙���⃗��⃗

Ex) find the component of (-1,4) in the (2,3) direction. Application in Physics of dot product and vector components: Force and Work In Physics, recall that we can measure the amount of energy expended, called work, by applying a force over a certain distance. In the basic case, in which quantities are scalar and constant, W = F·x, where W is work (in Joules), F is force (in Newtons) and x is distance (in meters). When you drag a bag of laundry along the

Page 38: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

38 ground, the only part of your pulling force doing work is the component in the direction the bag is moving, which is parallel to the ground.

Notation: W is work (in Joules), �⃗ is force (in Newtons), �⃗ is displacement (distance with a direction) (in meters)

W = |�⃗|cos θ|�⃗| = �⃗ ∙�⃗ Note that we can calculate the work with either the vectors or the magnitudes and angle. Ex) if your force vector is (9,7) and your displacement is the vector (30,35), find the work done.

W = �⃗ ∙�⃗ = (9,7)·(30,35) = 515 J

Note that the magnitude of the force doing work is |�⃗|cos θ and the magnitude of the distance is |�⃗|. Ex) suppose you are pulling a bag of laundry along with a force of 15N so that your arm makes a 40o angle with the ground. (a) Find the magnitude of your pulling force which is doing work. (b) Find the work done to move the bag 20 meters. Vector Cross Product Sometimes, if we have a vector, it will be useful to construct a perpendicular vector. How can this be done in 2 dimensions? One vector by itself determines a perpendicular vector, as can be seen in the picture. Notation: for a vector ��⃗ , a perpendicular vector is ������⃗ Here is the formula: if ��⃗ = (a,b) then ������⃗ = (b,-a) Here is the proof: (a,b)·(b,-a) = ab-ab = 0 Note that you can multiply ������⃗ by a constant since that does not change the direction. Ex) find a vector perpendicular to (3,-4)

If you are familiar with linear algebra, you can define the formula with a determinant: ������⃗ = ���⃗ �⃗�� ��

��

How can this be done in 3 dimensions? We will now define an operation between two vectors which produces a third vector that is perpendicular to both vectors. (Note: It help to see the reason that, in 3 dimensions, 2 vectors are required to specify a perpendicular vector. The object perpendicular to 1 vector is a plane – and we will discuss that situation later. For now, note that this means in three dimensions, vectors in infinitely many directions are perpendicular to one vector.)

The cross product of two vectors is: ��⃗ � �⃗ = �

���������

������� = �

���� − �������� − �������� − ����

(read it as “u cross v”) Here is a device to help remember the formula. In the x-component of the result, the input vectors’ x-components are omitted. The first component of the result starts with the 2nd component of ��⃗ times the 3rd component of �⃗. Note that the indices cycle: 1,2,3,1,2,3. So the second component starts with the 3rd component of ��⃗ and the 1st component of �⃗. The proof that the result of the cross-product is perpendicular to each original vector is accomplished by showing that each dot product is 0. If you know linear algebra, you can use determinants to define the cross-product:

Page 39: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

39 Ex) find the cross product of (3,4,-1) & (2,3,-2) The cross product has another striking property. |��⃗ x �⃗| = |��⃗ |·|�⃗|·|sinθ| Proof:

Note that the cross-product of two vectors is a vector, and we have described its magnitude and direction. Ex) for the vectors (-1,3,2) and (-4,-2,5), (a) find a vector perpendicular to both (b) find the sine of the angle between them. Here is a way to visualize the magnitude of the cross-product.

The length of the parallelogram is |�⃗|, the height is |��⃗ |sinθ, so the area is |�⃗|·|��⃗ |sinθ, which is |�⃗ X ��⃗ | Ex) find the area of the triangle with vertices P (4,2,7) & Q (-3,5,1) & R (2,0,2)

Page 40: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

40 Here are some properties of the cross-product. Each can be proven by writing each vector in terms of its components and using the definitions of cross and dot. If a, b, c, are vectors and k is a scalar,

1) a X b = -b X a 2) (ka) X b = k(a X b) = a X (kb) 3) a X (b + c) = a X b + a X c 4) (a + b) X c = a X c + b X c 5) a · (b X c) = (a X b)·c 6) a X (b X c) = (a·c)b – (a·b)c

The expression in equation 5 is related to an amazing property. Imagine the shape determined by the vectors a,b,c as in the picture below. It is called a parallelepiped, which looks like a leaning cardboard box. Its height is |a||cosθ|, where θ is the angle between a and (b X c). The area of the base is |b X c|. Therefore the volume is |a| |cosθ| ·|b X c| = |a·(b X c)|

Ex) find the volume of the parallelepiped with vector sides (5,3,1) & (3,2,3) & (4,2,0) at the same corner Application: Force and Torque Suppose you are trying to turn a bolt with a wrench. For simplicity, where the bolt is, Call that the origin. Where the wrench lies, call that the x-axis. With your hand, you push the wrench, call that the y-direction. To describe the impact on the bolt, we need to know two things: which way does it turn (or, what is the axis of rotation)? What is the force of the turning? [discuss] Torque measures the tendency of a body to rotate around the origin. �⃗ is the point where the force is applied,

�⃗ is the force vector, and ��⃗ is the torque vector. Then:

��⃗ = �⃗ X �⃗ The axis of rotation is the direction of the torque vector. The magnitude of the torque (the intensity of rotation) is the magnitude of the torque vector. Ex) a wrench is being used to turn a bolt. The bolt is at the origin, and the handle of the 0.3m wrench is on the x-axis. You apply 20N of force in the downward (negative z) direction. Find the torque vector and its magnitude.

��⃗ = �⃗ X �⃗ = (.3,0,0) X (0,0,-20) = (0, 6, 0)

|��⃗ | = |�⃗ X �⃗| = |r|·|F| sinθ = (.3)(20)(1) = 6

OR |��⃗ | = √0� + 6� + 0� = 6 Note that we can calculate the magnitude of the torque with either the vectors or the magnitudes and angle. Note that the torque axis is the y-axis, both in the calculation and the picture.

Page 41: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

41 Lines In 2 dimensions a line is determined by a point and a slope (or direction). Let’s rewrite this using parametric equations, so both x and y change as t changes. Suppose the line goes through (a,b) with slope m. The initial value for x is a, and let’s say that changes in x are the same as changes in the parameter t, so x=a+t. For y, the initial value is b, and as x (or t) changes by 1, y changes by m. so y=b+mt. The line is described by the system of parametric equations: x = a+t & y=b+mt (Notice that if you eliminate the parameter t, you get y-b = m(x-a), the point-slope form of a linear equation.) Now let’s turn that into vector notation.

���� = �

� + �� + ��

To find the general vector formula, split it into constant and variable parts

����=�

��� + �

1�� �

Using the notation: �⃗ is the position vector, �⃗� is the known point, �⃗ is the known direction of the line �⃗ = �⃗� + �⃗� Note: you can multiply �⃗ by any constant and it will still represent the same direction. As t changes, �⃗ changes, and that is the point on the line. It is the vector version of the equation of a line. But it is extremely powerful, because it now can be used in any dimension. Let’s see where �⃗ & �⃗� & �⃗ & t appear on the graph of a line.

Ex) find the equation of the line through (0,4) parallel to (1,2). Write the answer (a) as a vector equation (b)

as a system of parametric equations (c) what is the slope ��

�� (d) what is the standard equation y=f(x) ?

(Note that we think of (p,q) as a point when we want a position and as a vector when we want a direction.) Ex) find the equation of the line through (-2,4,5) parallel to (3,4,2). Write the answer (a) as a vector equation (b) as a system of parametric equations Here is a question to think about that we will ask now then answer later in the course, and it is connected to one of the key ideas of the course: what is the slope of this line? Alternate ways to express the equation of a line: Symmetric equations: in each equation, solve for t and set the expressions equal to each other

Page 42: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

42 Ex) write the symmetric equations for the previous example, the line through (-2,4,5) parallel to (3,4,2). Find the equation of a line: Given two points …Solve this by using two points to find a direction vector. Ex) find the equation of the line through (2,-3,1) and (5,2,0) Can you use either point for �⃗�? …yes Can you use the first point minus the second point for �⃗? …yes Planes Previously, we saw that, to determine a line, we need a point and a vector (or direction), or two points. What determines a plane? [discuss] A plane is determined by either (a) 3 points (b) a point and 2 vectors in the plane (c) a point and a vector perpendicular to the plane. [(c) only works in 3 dimensions. The reasons are explored in linear algebra.] Next, we will use (c) to write down the equation. Assume that the known point is P (x0, y0, z0) and the perpendicular

(also called normal) vector is ��⃗ = (a,b,c). For any point in the plane Q (x,y,z), the vector �������⃗ is perpendicular to ��⃗ so their dot product is 0.

�������⃗ ∙��⃗ = 0 (x-x0, y-y0, z-z0)·(a, b, c) = 0 a(x- x0) + b(y- y0) + c(z- z0) = 0 If you combine all the constants, the equation looks like: ax + by + cz + d = 0 Or, to write the equation using the given information:

��⃗ ∙��⃗ = ��⃗ ∙��⃗ Exploring the graph using 3D graphing technology can help understand the equation.

Ex) find the equation of a plane through the point (3,-2,4) with normal vector (2,5,-2) Using 3 points to find the equation of a plane A pair of points determines a vector, let’s get two of those. Those two vectors are in our plane, and we need a vector perpendicular to them – so take the cross product. Use that normal vector and any one of the points to make the equation Ex) find the equation of the plane through the points P (2,5,1) & Q (0,3,-2) & R (6,1,2)

Page 43: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

43 As an alternate to generating a normal vector, one could write the equation of a plane using parametric equations with two vectors in the plane and two parameters. Starting from the point P, we can get to any point Q in the plane by moving a certain amount in the a direction and another amount in the b direction. In this example, the equation is (x,y,z) = (2,5,1) + (2,2,3)r + (6,-2,4)s OR (2+2r+6s,5+2r-2s,1+3r+4s). In general, for a plane through point P with direction vectors a and b, Q = P +ra + sb. In vector notation, r = r0 + ra + sb. As a system of equations, (x,y,z) = (x0+ua1+vb1,y0+ua2+vb2,z0+ua3+vb3 ). This idea is covered more thoroughly in Linear Algebra. The proof that the last two methods are equivalent involves lots of algebra; it is in the appendix. Math Applications with Lines and Planes For points, lines and planes, we can use vector calculations to describe angles, intersections, and distances. Angles We can find the angle between two lines by calculating the angle between their direction vectors. The easiest way to describe the direction of a plane is using its normal vector, since we already know how to describe the direction of a vector. Therefore, Two planes are parallel if their normal vectors are parallel ( ������⃗ = �������⃗ ) Two planes are perpendicular if their normal vectors are perpendicular ( ������⃗ ∙������⃗ = 0 ) In general, the angle between two planes is the angle between their normal vectors. Ex) find the angle between these two planes: 4x+3y-z-5=0 & -2x+5y+z+2=0 To find the angle between a line and a plane, we find the angle between the line’s direction vector and the plane’s normal vector. However, since relative to its graph one is parallel and one is perpendicular, we need to calculate the complement (subtract from π/2) to find the actual answer. Intersections The intersection of a line and a plane, if they meet, is a point. To find it, substitute the expressions from the line’s coordinate equations into the plane equation The intersection of two planes, if they meet, is a line. There are two ways to find the formula: Method 1: With standard algebra set one variable equal to the parameter t, then solve for the other variables in terms of t. Ex) find the line of intersection between 4x+3y-z-5=0 & -2x+5y+z+2=0

L: x = t & y = ����

� & z =

�������

OR (�, �, �)= �0,�

�,���

�� + �1,

��

�,��

�� �

Page 44: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

44 Method 2: With vector operations For the vector equation of a line, we need a point and a direction vector. To find a vector: the line of intersection is in both planes, therefore it is perpendicular to both normal vectors, and therefore it is in the direction of their cross product. To find a point: take the two plane equations and set one variable equal to 0, then solve the two equations in two variables. (This works because any point will do.) Ex) find the line of intersection between 4x+3y-z-5=0 & -2x+5y+z+2=0

The normal vectors are (4,3,-1) & (-2,5,1) direction vector �⃗ = (4,3,-1) X (-2,5,1) = (3+5,2-4,20+6) = (8,-2,26)

Distances In general, to find the formula for the distance between two graphs when they are not both points, we observe that the shortest path is a vector which is perpendicular to both graphs (if the graph is a point, then the vector ends there). First, we take any points, one on each graph, and find the vector between them; second, we make a vector perpendicular to both graphs; third, we find the component of the first vector in the direction of the perpendicular vector. This component vector is the shortest path and its magnitude is the shortest distance. The distance between a point and a plane The distance between a point P1 and a plane ax+by+cz+d=0 with normal vector ��⃗ is the magnitude of the component

of ������������⃗ in the ��⃗ direction, for some point P0 in the plane. Let’s work out what the formula is:

Dist=|������������⃗ ||cosθ| =

Dist(point, plane) = |�������������|

√�������� … for the point (x1 y1 z1) & the plane ax+by+cz+d=0

Ex) find the distance between the point (5,4,1) and the plane 3x-y+2z=6 The distance between a point and a line

Page 45: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

45 To find the distance between a point P and a line L, take any point Q on the line.

The distance is the component of �������⃗ perpendicular to the line.

dist = |�������⃗ |·sinθ

= ��������⃗ �∙|��⃗ | ����

|��⃗ |

= |�������⃗ × ��⃗ |

|��⃗ |

dist(point P,line L) = |�������⃗ × ��⃗ |

|��⃗ | where �⃗ is the line’s direction vector and Q is any point on the line

ex) find the distance between the point P (8,2,-5) and the line (x,y,z)=(6,2,1)+(3,-3,4)t The distance between two lines which are intersecting, parallel, or skew Two straight lines can be in one of three relationships: intersecting, parallel (if their direction vectors are parallel), or skew (if they are neither intersecting nor parallel). If two lines intersect, the distance between them is 0. If two lines are parallel, then the distance between a point on one line and the other line is the same for any point, so simply select any point on one line (e.g. at t=0) then find the distance between that point and the other line. We now consider distance in the third case. The equation of each line includes a point on the line, so construct the vector between them. Construct a vector perpendicular to both lines by taking the cross-product of their direction vectors. Find the component by taking the dot product (then dividing by the magnitude of the direction vector). For two lines with equations: L1: r1=p1+v1 t L2: r2=p2+v2 t

Dist(L1,L2) = Note that, when finding the distance from a point, when the other object is a line, the vectors you use in the calculation meet on the line, so finding the perpendicular component requires sinθ, which involves the cross product. If the other object is a plane, the vectors you use in the calculation meet at the point, so finding the perpendicular component requires cosθ, which involves the dot product.

Page 46: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

46 Vector Functions Curves in space Previously we used parametric equations to describe a curve in 2 dimensions. We can do exactly the same in 3 dimensions. So far we have done this for the simplest graph, a line. Ex) �⃗(t) = (3+t, 1+2t, 3-4t )

OR �⃗ = �313� + � �

12−4

Ex) �⃗(t) = ( sin(t), cos(t), t ) These expressions are simple enough that we can connect them to the graph. Note that if this was just a graph in x & y, it would be a circle with radius 1. However, as we pass around the circle, the height z is increasing. That makes a corkscrew, which is called a helix. (If you look from overhead, all you see is a circle.) Note that we can draw the graph over a certain range of t-values. Here, -5<t<5. Since the domain of each component is -∞<t<∞, we could choose to graph that parameter domain. Then the graph would be … long. We are starting to see that the path in the graph can be anything you can imagine. In general, it is very difficult to plot a vector function (or space curve) by hand.

Ex) �⃗ = (3-t, t2, cos(t) ) OR �3− ���

cos (�)�

What does the curve look like from different perspectives? You can solve it on paper or see it with a 3D grapher (or your mind). From “straight ahead”, you see x on the horizontal axis and z on the vertical axis (it’s the xz-plane), and you

cannot distinguish y-values. The graph is ���� = �

3− �cos (�)

� or z = cos(3-x), so it’s a cosine curve.

Ex) what graph is seen looking at the xy-plane? At the yz-plane?

Page 47: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

47 Calculus with Vector Functions Derivative of vector functions The derivative of a vector function is exactly what you think it is – take the derivative of each component. Note that the variable is the parameter.

Ex) �⃗ = (3-t, t2, cos(t) ) Find the derivative ��⃗

��

��⃗

�� = (-1, 2t, -sin(t) )

Notation: the derivative of a vector function �⃗(t) is written ��⃗

�� or

���⃗ or �⃗’ or

��

�� or �̇ or r’(t)

The most typical application of curves in space is where they represent the movement of some object. At time t, the object is at a given point on the curve. Therefore, if �⃗ represents the position vector, then the

derivative ��⃗

�� represents the velocity vector �⃗. And the second derivative

���⃗

��� represents the acceleration

vector �⃗. What about speed? Speed is the magnitude of the velocity, |�⃗| = ���⃗

���

Ex) for the position vector �⃗(t) = (2t-1, e3t, 4t-t4), find the velocity and acceleration vectors as well as their magnitudes. Let’s describe the tangent line. In calculus in 2 dimensions, the direction of the derivative is tangent to the curve. This is also true in 3 dimensions. At a given point on the curve, the velocity vector is tangent to the curve. (To see that it is tangent, we draw it starting at the point on the curve, not starting at the origin.) Ex) 2 dimensions: for (x,y) = (3t, t2) … (a) draw the curve and a tangent vector at t=2 (b) find the equation of the tangent line at t=2

Ex) 3 dimensions: for (x,y,z) = (cos(t), sin(t), t) … (a) draw the curve and a tangent vector at t = �

� (b) find the

equation of the tangent line at t = �

We can explore the tangent line at other points using a 3D grapher.

Page 48: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

48 Here are some properties of the derivative. They can be proven by writing down the vectors by components.

Ex) prove that if a vector �⃗(t) (a position vector) has constant magnitude, it is perpendicular to its derivative �⃗′ (a velocity vector) |�⃗(t)| = c |�⃗(t)|2 = c2

�⃗ · �⃗ = c2 Take the derivative 2�⃗ · �⃗′ = 0 Therefore �⃗ and �⃗′ are perpendicular. The derivative of a vector-valued function can be defined, and its properties proven, with limits. Definition:

Theorem:

Proof:

Page 49: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

49 Integration of vector functions The integral of a vector function is exactly what you think it is – take the integral of each component. Note that the variable is the parameter. Ex) take the integral of �⃗(t) = (6t, cos(t), et)

Notation: the integral of �⃗(t) is ∫ �⃗(�)���

� OR ∫ �(�)��

The Fundamental Theorem of Calculus applies to vector functions as well. It looks almost the same as before:

∫ �⃗′(�)���

�= �⃗(�)− �⃗(�)

Ex) a particle has acceleration vector function �⃗(t) = (2,3t,et) At t=0, its velocity is (1,0,0) and its position is (2,3,1). Find the position vector function �⃗(t) Arc Length for Vector Functions In two dimensions, the formula for arc length is

s = ∫����

����+ �

��

������

In three dimensions, the formula for arc length is

s = ∫����

����+ �

��

����+ �

��

������

Since we know that �⃗�(�)= ���

��,��

��,��

��� and �⃗� ∙�⃗� = �

�′�′

�′

� ∙��′�′

�′

� = (��)� + (��)� + (��)� we can rewrite

the formula as:

s = ∫ √�⃗′ ∙�⃗′�� OR ∫|�⃗’|dt Recall that �⃗′ is the velocity, so |�⃗’| is the speed, so the formula says that total distance traveled is the integral of speed with respect to time. That makes sense! Ex) find the arc length of the helix �⃗ = (sin t,cos t, t) for 0<t<2π (one revolution)

Page 50: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

50 The Unit Tangent, Unit Normal, Binormal Vectors [omit] The x-y-z-coordinates are useful for indicating direction in 3D space. Now, given a point on a parametric curve, we are now going to determine 3 perpendicular directions which have special properties. For the graph of �⃗(t), one tangent vector is �⃗’(t). This velocity vector captures the direction of change, as well as the magnitude of change.

The unit tangent vector ��⃗ has the same direction as the tangent vector, but has length 1 … ��⃗ =�⃗’(�)

|�⃗’(�)|

There are an infinite number of vectors which are perpendicular to the curve. However, since |��⃗ |=1, we have

that ��⃗ ∙��⃗ �=0, therefore ��⃗ and ��⃗ ′ are orthogonal. Therefore ��⃗ ′ is orthogonal to the curve. We want to make it a unit vector, so divide by the magnitude.

The principal unit normal vector (or unit normal) is ���⃗ =��⃗ �

|��⃗ �|

Further, we can make a vector perpendicular to both by taking their cross-product. This is called the binormal vector.

��⃗ = ��⃗ × ���⃗ The length of B is: |B|=|T X N| = |T||N|sinθ = 1·1·1 = 1, so B is a unit vector as well. Ex) for �⃗(t) = (cos(t), sin(t), 3t) find the unit tangent, unit normal, and binormal vectors Curvature [omit] If you travel at a constant speed in a straight line, no matter how fast that speed is, you feel no forces or acceleration. Any other type of motion involves acceleration! If you travel on a straight path with varying speed, or if you travel at a constant speed on a (not straight) curve, you feel acceleration. If the path is curved, the acceleration tends to go toward the direction in which your path is bending. The more tightly curved the path is, the more acceleration there is. The measure of this is called the curvature.

The curvature is the magnitude of the change in ��⃗ relative to how far you have traveled on the curve

� = ����⃗

���

Note that:

So an equivalent formula for curvature is:

� =|��⃗ �(�)|

|�⃗�(�)|

In the special case of 3 dimensions, this reduces to a nice formula:

� =��⃗�⨯�⃗���

|�⃗�|�

(The proof of this special case is in the Appendix.) Ex) prove that the curvature of a circle in the plane with radius a is 1/a

Ex) find the curvature κ(t) of the curve �⃗ = (sin t, cos t, 1) Ex) find the curvature κ of the curve �⃗ = (ln t,1-2t,2e3t) (a) as a function of t (b) at t=1

Page 51: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

51 Summary Unit tangent vector Unit normal vector Binormal vector curvature

Page 52: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

52 Surfaces & Functions of Several Variables The next step is to look at surfaces in 3 dimensions which are more complicated than planes. Surfaces of translation We can take a known graph from 2 dimensions, then just “extend” it into 3 dimensions. Ex) graph y=x2

At every point, y=x2. This is true when z=1, z=2, z=5.7, etc. One way to visualize the 3 dimensional graph is to take a slice (or cross-section) at each z-value. In this example, every cross-section looks the same, it is y=x2. Typical 3 dimensional graphs are more complicated than that.

Ex) graph x2 + y2 = 4 Ex) graph z=x2 + y2 This graph is a rotation of a parabola. It is called a paraboloid. How can we connect the equation to the graph? When z is constant, we are in a plane parallel to the xy-plane. When z=0, both x & y must be 0. For z=constant, it produces the equation of a circle. Therefore, horizontal cross-sections are circles, with a larger radius for larger z-values. Visualize each cross-section by intersecting a plane with the surface. Let’s consider vertical cross-sections for constant y. This means we are in a plane parallel to the xz-plane. When y=0, it produces a standard parabola, z=x2. In fact for any y=constant, it produces a parabola (with z as a function of x). Also, x=constant produces cross-sections of parabolas (with z as a function of y). (In the graph, these lines are already drawn.) A cross-section with x=constant is called an x-trace. It lives in a plane parallel to the yz-plane. Similary, a cross-section with y constant is called a y-trace, and it lives in a plane parallel to the xz-plane. Finally, a cross-section with z=constant is a z-trace, and it lives in a plane parallel to the xy-plane. Each trace is a “slice” of the surface. Stack them together to “build” the

Page 53: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

53 whole surface. In this example, x-traces and y-traces are parabolas, and z-traces are circles.

Ex) graph ��

�+

��

�+

��

��= 1

This graph is the 3 dimensional version of an ellipse. It is called an ellipsoid. What shape are the traces? From the graph: From the equation: These are examples of quadric surfaces. These are surfaces whose equations can be made from x,y,z,x2,y2,z2 and constants. Here are some more examples.

Page 54: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

54 Functions of several variables – formulas, graphs, and more Functions as formulas Previously we saw that a function y=f(x) can be represented in 2 dimensions with xy-axes. Plugging in a value for x yields a function value y. We will now look at functions z=f(x,y). These can be represented in 3 dimensions with xyz-axes. Plugging in values for x & y yields a function value z.

Ex) for z=�� + � find f(4,5) and find the domain of the function

Functions as graphs Ex) what shape is depicted in this graph? What is the function?

It looks like a hemisphere. We can find the equation of this graph. The radius is r=3 and the center is the origin. In three dimensions, x2+y2+z2=32. We want to write it as a function so, solving for z, we get

z = �9 − �� − �� (Take the positive root to get the top half of the sphere). What is the domain of the function? Notice that the domain is a 2-dimensional region in the xy-plane, over (or under) which the graph of the surface exists. Every point (x,y) in the domain has a function value z represented by the height. Level curves (or contour lines) Before there was mathematical software which could render beautiful images indicating depth, people needed ways to visualize 3-dimensional objects in a 2-dimensional image on paper. The most common technique was developed by map makers who wanted to represent mountains and valleys. They drew a curve to show every point which was at the same height. The mountain in the picture is represented by the map on the right, called a contour map. The lines in a contour map are called level curves (or contour lines). Moving along a level curve means moving along the same height (or function value). Crossing from level curve to level curve means moving to a different height. Level curves are just z-traces. When z is a function, they have a special status.

Page 55: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

55

This technique is used to measure things other than actual height. Your function can represent any real world quantity; for example, it could measure temperature. (These contour map lines are called isothermals, ‘iso’ means same, ‘therm’ means temperature.)

The variables x,y,z can represent any quantities in any real-world application. What does the contour map look like for a given surface?

Ex) z = �64 − �� − ��

Page 56: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

56 This can also be solved algebraically. For the level curve at z=c, we have

c=�64 − �� − �� c2 = 64 – x2 – y2 x2 + y2 = 64 – c2

So the level curve is a circle centered at the origin, radius r=64-c2. Except for the simplest cases, to draw level curves by hand given the formula of a surface is very hard. Algebraically, the problem is possible, but does not give simple objects. Analysis of the graph is more direct.

Ex) for � = −���������, What are the x-traces? What are the y-traces? What are the level curves?

In general, to graph functions and contour maps, 3 dimensional graphing software is useful, almost necessary.

Page 57: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

57 Derivatives for functions of several variables A review of derivatives for y=f(x) Previously, we saw derivatives for one-variable functions y=f(x) as a rate which represented the change in y over the change in x. This could be presented graphically by taking the graph of the function (which was a curvy line) and zooming in on a point (a,b) of the graph to reveal a straight line called the tangent line; the slope of that line is the derivative at that point. Numerically, we made an estimate by taking a point and a nearby point, then calculating change in the function divided by change in x. Algebraically, we calculated that rate as the change in x goes to 0. Numerically: x -2 -1.5 -1 -0.5 0 0.5 1 1.5 2

y=x2 4 2.25 1 0.25 0 0.25 1 2.25 4

Grahpically:

Algebraically: ��(�)= ����→ ��(���)��(�)

Intro to Partial Derivatives (numerically, graphically, algebraically) We will be able to understand the derivative for the surface z=f(x,y) in a similar way. We will answer two questions. First, with the extra variables, how does it make sense to talk about derivatives in 3 dimensions? Second, once we believe that it is possible to have a derivative, how can we say what it is? Consider the plane z=1-x+2y Numerically: Here is a table of values for this function

x: y: 0 1 2 3

0 1 3 5 7

1 0 2 4 6

2 -1 1 3 5

3 -2 0 2 4

What does it mean to talk about the rate of change of the function? [discuss] How does the function change as x changes? How does the function change as y changes? Graphically: This surface was rotated to view the xz-plane. The red line represents all values on the surface for which y=2. Since y is constant, z is a function of x. What is the slope of that line (estimate visually)?

Page 58: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

58

This surface was rotated to view the yz-plane. The green line represents all values on the surface for which x=3. Since x is constant, z is a function of y. What is the slope of that line (estimate visually)?

That is what a derivative (or slope) could mean for z=f(x,y). Numerically, find the change in z over the change in x as y is constant (or the change in z over the change in y with x constant). Graphically, you draw a straight line and the slope of that line is your derivative.

Notation: the derivative of f with x as the variable (and other variables constant) is ��

�� This is called the partial

derivative of f with respect to x. That “curvy d” indicates that there are other variables we hold constant. There are many ways to say it. I suggest “partial dee zee dee ex”. Sometimes mathematicians do not say “partial”

when it is clear from the context. Other notations: ���

�� …

��f … fx … Dxf …

��

��

Ex) for f(x,y)=1-x+2y

��

�� =

��

�� =

Page 59: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

59 But how can we talk about slopes of straight lines when the surface is curvy? Consider the following example:

Ex) What is the rate of change of the function f(x,y) =4��������� at the point (1,0.5,0.57) ?

Numerically:

x: y: -2 -1.5 -1 -0.5 0 0.5 1 1.5 2

-2 0.01 0.02 0.05 0.06 0.00 -0.06 -0.05 -0.02 -0.01

-1.5 0.02 0.10 0.23 0.25 0.00 -0.25 -0.23 -0.10 -0.02

-1 0.05 0.23 0.54 0.57 0.00 -0.57 -0.54 -0.23 -0.05

-0.5 0.06 0.25 0.57 0.61 0.00 -0.61 -0.57 -0.25 -0.06

0 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00

0.5 -0.06 -0.25 -0.57 -0.61 0.00 0.61 0.57 0.25 0.06

1 -0.05 -0.23 -0.54 -0.57 0.00 0.57 0.54 0.23 0.05

1.5 -0.02 -0.10 -0.23 -0.25 0.00 0.25 0.23 0.10 0.02

2 -0.01 -0.02 -0.05 -0.06 0.00 0.06 0.05 0.02 0.01

What does it mean to talk about the rate of change at the point (1,0.5,0.57) ? [discuss]

How does the function value change as x changes? If x increases by 1, f(x,y) changes by -0.51. So ��

�� = -0.51.

We get a better approximation of the rate at that point if we change x by 0.5, now f changes by -0.32. So ��

�� =

-0.64. In each case, the approximation of the rate at that point is better if Δx (or Δy) is closer to 0. Next, at the same point, how does this function value change as y changes? If y increases by 1, f(x,y) changes

by -0.34 . So ��

�� = -0.34. We get a better approximation of the rate at that point if we change y by 0.5; and

now f changes by -0.03 So ��

�� = -0.06

Graphically:

Ex) f(x,y) =4���������

This surface was rotated to view the xz-plane. The red line represents all values on the surface for which y=0.5 (so z is a function of x). What is the slope of that line at x=1, indicated by the green line (estimate visually)?

This surface was rotated to view the yz-plane. The green line represents all values on the surface for which x=1 (so z is a function of y). What is the slope of that line at y=0.5, indicated by the red line (estimate visually)?

Page 60: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

60

The final step graphically is that, when we zoom in on a point, the surface appears as a (nearly) flat plane containing our (nearly) straight lines. The plane is called the tangent plane. The lines are called tangent lines. To explore this idea, use a 3D grapher. Symbolically: Here’s the key idea: when we determine the rate of change as the change in the function over the change in

a particular variable, the other variables are constant. For example, to find ��

�� , y does not change. When we

calculate the derivative from the formula, we use the same idea.

Ex) for f(x,y) = 0.1x2 + 0.2xy + 0.05y2 … find the derivative ��

�� and

��

��

��

�� =

��(0.1x2 + 0.2xy + 0.05y2) = 0.2x + 0.2y

y is treated as a constant, so in the second term, x is the variable and the coefficient is 0.2y

��

�� =

Note that you can no longer use f’ to indicate a derivative because it is necessary to specify the variable.

Notation: The derivative at the point (a,b) can be written fx(a,b) or ���

���(�,�)

Formal definition of the partial derivative using limits: ��

��= ����→ �

�(���,�)��(�,�)

Notice how, comparing the two terms in the numerator, the x-value is changing but the y-value is constant Higher partial derivatives: Some notations for the second derivative of the function z=f(x,y) with respect to x are:

���

���

��

���� ���

���

���

It is possible to take several derivatives with respect to different variables Take the derivative of f with respect to x and then with respect to y. the notation is: ���

����

��

����� ���

���

����

����

����

Ex) for f(x,y) = x5 + y4 + x2y2 find: (a) fx (b) fy (c) fxx (d) fyy (e) fxy (f) fyx

Page 61: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

61 Is there a difference between fxy and fyx ? In other words, if you take the derivative twice, once with respect to x and once with respect to y, does it matter which one you do first? If the derivatives of f(x,y) are continuous, then fxy = fyx This is called Clairaut’s Theorem. Summary of the introduction to partial derivatives

Numerically, we can calculate ��

�� by keeping the other variable, y,

constant. Geometrically, suppose we want to know the derivative at the point (a,b,c). We can zoom in at that point. What we will see is a flat plane called the tangent plane. Note that, in any direction (for example the x-direction), the plane has a slope. You can visualize this by intersecting the tangent plane with a vertical plane having a fixed y-value, which produces a line in an xz-plane. The slope of that line will be the derivative of the function in that direction - in this case showing how z changes as a function of x (You can do the same by taking a plane with a fixed x-value, which intersects the tangent plane in a line in a yz-plane.) Note that we could zoom in (to see the tangent plane) then make a trace (which is a straight line), or make a trace (which is a function) and then zoom in (to see a straight line). Algebraically, consider how to calculate the derivative for functions of 2 variables. If a derivative should be a rate of change, it should be the ratio between the change in the function over the change in a variable. However, there is a choice of variables. The solution to this difficulty is to consider each variable separately. Therefore, we can have two different derivatives. (In fact, we can have many, as we will see later.) The Tangent Plane Previously, for y=f(x) at the point (a,b), we used derivatives to find the equation of the tangent line: y-b = f’(a)·(x-a) Now, for z=f(x,y) at the point (a,b,c), we will reach for the equivalent goal, which is to use derivatives to find the equation of the tangent plane. Tangent Plane Equation Any plane passing through the point P=(a,b,c) has an equation A(x-a) + B(y-b) + C(z-c) = 0 where (A,B,C) is a normal vector. Let’s move the terms with z to one side to get C(z-c) = -A(x-a) - B(y-b), then divide by C to get

z-c = - �

�(x-a) –

� (y-b), now rename the constants, to get z-c = m(x-a) + n(y-b).

To figure out the values of m & n, consider the traces at this point. First consider the trace with constant y. In the surface, you get f as a function of x and in the tangent plane you get the tangent line to that function, so it

has slope ���

���(�,�)

. Algebraically, when y = b, we get z-c = m(x-a). Therefore, m = ���

���(�,�)

. It works out

similarly for the trace with constant x. In the surface, you get f as a function of y and in the tangent plane you

get the tangent line to that function, so it has slope ���

���(�,�)

. Algebraically, when x = a, we get z-c = n(y-b).

Therefore, n = ���

���(�,�)

. Therefore we know that:

The equation of the tangent plane is z-c = fx(a,b)∙(x-a) + fy(a,b)∙(y-b)

Page 62: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

62 Note: we will assume that these derivatives exist, and so the tangent plane exists. To conceive of what the surface would look like so that the partial derivatives and the tangent plane did not exist, recall the 1-variable case in 2-dimensions and extend it to 2-variables in 3-dimensions. In the former, a point is non-differentiable if you zoom in on the graph and do not see a line, for example at a corner. In the latter, a point is non-differentiable if you zoom in on the graph and do not see a plane, for example at a corner or edge. Ex) find the equation of the tangent plane for the paraboloid f(x,y) = 1 - .1x2 - .4y2 at the point (1,1,0.5) Ex) Find the equation of the tangent plane for f(x,y) = 2x2y + x4y2 at (2,3) Linear approximation using the tangent plane

For a function of 1 variable, we saw that the tangent line is an approximation to the graph. Now, for a function of 2 variables, the tangent plane is an approximation to the graph. The equation of the tangent plane for z=f(x,y) at the point (a,b,c) can be written as a linear function:

f(x,y) ≈ L(x,y) = f(a,b) + fx(a,b) ·(x-a) + fy(a,b)·(y-b) This looks a lot like the equation of the tangent line (or linear approximation) in 2 dimensions: f(x) ≈ L(x) = f(a) + f’(a)·(x-a) It has been updated because now the function changes, not from one variable changing, but from two variables changing. The equation can be described in words as: (new z-value) ≈ (initial z-value) + (change in z due to change in x) + (change in z due to change in y) … z ≈ c + Δxz + Δyz. For the linear function of the tangent plane, this calculation is exact. For the original function, this calculation is an approximation.

Ex) for f(x,y)=x3 + 2y + 3, (a) find f(3,2) (b) find f(3.2, 2.1) using the linear approximation (c) find f(3.2,2.1) exactly Ex)for f(x,y)=2x2 + 2xy, (a) find f(4,.5) (b) find f(4.1,.55) using the linear approximation (c) find f(4.1,.55) exactly Differentials What is a differential? The expressions dx, dy and dz (or df) are infinitesimals (or differentials). They are best understood as very tiny changes in the variable. We understand Δx very well as the difference between two x-values or a segment on the x-axis; dx is visible on the graph a�er zooming in “all the way”, or in a formula by taking a limit as Δx → 0.

Their ratios represent rates of change. If y is constant, then ��

�� is the rate of change of f(x,y) with respect to x.

[The full theory behind differentials and infinitesimals is beyond the scope of this course.]

Page 63: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

63 The equations for linear approximation can be written with differentials.

Equations for Linear Approximations

in 2 dimensions, y=f(x) in 3 dimensions, z=f(x,y)

Without differentials y – b = f’(a)·(x-a) z – c = fx(a,b) ·(x-a) + fy(a,b)·(y-b)

Written as an approximation

Δy ≈ ΔL(x) = f’(a)·Δx Δf or Δz ≈ ΔL(x,y) = ���

���(�,�)

·Δx + ���

���(�,�)

·Δy

Written exactly dy = f’(x)·dx OR dy = ��

�� ·dx dz = fx·dx + fy·dy OR dz =

��

�� ·dx +

��

�� ·dy

In words the change in the function is its rate of change times the change in the variable

the change in the function is its rate of change in the x-direction times the change in x plus its rate of change in the y-direction times the change in y

In single variable calculus, for y=x2, we have ��

�� = 2x, which can also be written dy=2x dx. Those represent the

same relationship between changes in x and changes in y, either written with division or with multiplication. In multivariable calculus, when z=f(x,y), changes in the function have two sources, changes in x and changes in y. Thus, df = dxf + dyf (the change in the function) = (change in the function due to changes in x) + (change due to y)

df = ��

�� ·dx +

��

�� ·dy = (rate of change in x-direction)·(change in x) + (rate of change in y-direction)·(change in y)

Notation: recall ΔL = ΔxL + ΔyL where ΔxL = fx·Δx. Now, df = dxf + dyf where dxf = ��

�� ·dx, similar for y

Ex) for f(x,y)=x2y3, find df

df = ��

�� ·dx +

��

�� ·dy = 2xy3 dx + 3x2y2 dy

ex) for f(x,y)=ln(x2+2y) (a) find df. Now, at the point (1,0,0), (b) find L (c) approximate f(1.1,0.2) (d) find f(1.1,0.2) exactly. Now, for the two points, find (e) Δf and ΔL between the two points (f) ΔxL (the amount of ΔL from the change in x) and ΔyL (the amount of ΔL from the change in y) A Geometric explanation of Δf, ΔL and df (same as dz) The surface z=f(x,y) is outlined in blue and the tangent plane at the point (a,b,c) is represented by a parallelogram in purple. Four points are marked off, the ones with (x,y)-values (a,b) & (a+Δx,b) & (a,b+Δy) & (a+Δx,b+Δy). They are represented, first, in dark green on the xy-plane below, second, in dark blue on the surface, and third, in dark purple on the tangent plane. The edges of this piece of the tangent plane are Tx, the tangent line in the x-direction (when you hold y constant and z is a function of x) and Ty. f represents a value on the surface, and Δf (or Δz) represents the change between old and new point of the function. L is a value on the tangent plane, and ΔL represents the change between old and new point of the tangent plane, which is a linear approximation of f. To find the new L, L(a+Δx,b+Δy), imagine

Page 64: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

64 climbing along Tx (z changes as x changes while y is constant), then climbing along the line parallel to Ty (z changes as y changes, x constant). The tangent plane L(x,y), or the change in the value ΔL, is a linear approximation of the function at the point (a,b). It is exact at (a,b), but an approximation at any other point. The closer the point is to (a,b), the flatter the surface is for that range of values, and the better the approximation is. The general formula dz = p(x,y)dx+q(x,y)dy involves functions. That formula is valid everywhere (at every (x,y) point in the domain). If we evaluate the functions at a point (a,b), then we get dz=m dx + n dy where m & n are constants (the slopes in the x- and y-directions at that point), and the expression is valid only at the point (a,b). Note: in higher mathematics, the coordinates are not named x,y,… but rather x1, x2, … In that case,

for f(x1, x2), then �� = ∑��

������

���� . This formula can be extended to any number of variables.

The Chain Rule

From single variable calculus, recall the Chain Rule for f(u(x)): �

�����(�)� = ����(�)� ∙��(�)=

��

��∙��

��

Suppose that z=f(x,y), but in addition, x & y are both functions of another variable, t; that is, x=x(t) and y=y(t).

The derivative ��

�� can be understood in two different ways. One, simply plug in the expressions for x & y so

z=z(t), then find z’(t). Two, use the chain rule for functions of several variables. This formula comes

immediately from the expression for the differential dz. Since dz = ��

�� ·dx +

��

�� ·dy we have that:

��

�� =

��

�� · ��

�� +

��

�� · ��

��

ex) for z=2xy+cos(y) where x=6t2 and y=ln(t), find ��

�� at t=1

method 1 (using t only): z = 2(6t2)(ln t) + cos(ln t)

��

�� = 24t(ln t) + 12t2�

�� - sin(ln t) �

��

= 12 method 2 (using the chain rule): ��

�� =

��

�� ·��

�� +

��

�� ·��

��

= (2y)(12t) + (2x-sin y)��

��

now use the fact that if t=1, then x=6 and y=0, and plug in:

= 2(0)12(1) + (2(6) - sin(0))·��

��= 12

Ex) for z = x3y + 3x2y1.7 where x=sin(2t) and y=cos(t), find ��

�� at t=0

Ex) Application from physics: In an electrical circuit, Ohm’s Law relates voltage V (the potential ability to move charge, measured in volts), current I (the speed at which charge is moving, measured in amps) and resistance R (the wire’s tendancy to resist charge moving through it, measured in ohms): V=IR. If the current I=4 amps, the rate of change of the current is -1 amp/min, The resistance R = 300 ohms, the rate of change of the resistance is -5 ohms/min, find (a) the voltage V right now (b) the rate of change of the voltage (in volts/min).

Page 65: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

65 An alternate proof of the chain rule uses the idea of linear approximation. For a differentiable function f(x,y), at (x,y)=(a,b) we have fx(a,b)=r and fy(a,b)=s and f(a,b)=c Write the linear approximation: f(x,y) ≈ r(x-a) + s(y-b) + c

Suppose x=x(t) and y=y(t). At t=0 we have x(0)=a & ��

��=m & y(0)=b &

��

��=n Write the linear approximations:

x(t) ≈ mt+a … y(t) ≈ nt+b Note how, for each function value and each first derivative, all approximations are exact at t=0 or (x,y)=(a,b):

At t=0 … for x: m·0+a=a … for y: n·0+b=b … for ��

��:

��[mt+a]=m … for

��

��:

��[nt+b]=n

At (x,y)=(a,b) … for f: r(a-a)+s(b-b)+c=c … for fx: �

�� [r(x-a) + s(y-b) + c]=r … for fy:

�� [r(x-a) + s(y-b) + c]=s

Rewrite f as a function of t: f(x,y) = f(x(t),y(t)) ≈ r(mt+a-a) + s(nt+b-b) + c ≈ rmt + snt + c ��

�� ≈ rm + sn

��

�� ≈ �

��

���(�,�)

∙���

���(�,�)

+ ���

���(�,�)

∙���

���(�,�)

This approximation only involves first derivatives, so it is exact at the point (a,b), so:

���

���(�,�)

= ���

���(�,�)

∙���

���(�,�)

+ ���

���(�,�)

∙���

���(�,�)

Every expression is evaluated at the same point (a,b), and that point can be any point. As a result we have:

The Chain Rule: ��

��=

��

��∙��

��+

��

��∙��

��

The Chain Rule can also be written as: ��

��= ∇��⃗ � ∙�⃗�(�). Since ��⃗ = �⃗�(�)��, this is the same as �� = ∇��⃗ � ∙��⃗

For a discussion of the chain rule with more variables, see the appendix. Implicit Differentiation (using partial derivatives)

Ex) find ��

�� given y2 + 3x4y3 – tan(y) + x = 0

The old way:

2y��

�� + 12x3y3 + 3x4(3y2)

��

�� – sec2y

��

�� + 1 = 0

2y��

�� + 3x4(3y2)

��

�� – sec2y

��

�� = - 1 - 12x3y3

��

�� =

� (�� ������)

��������������

New method: Call the left side F(x,y) Fx = 12x3y3 + 1 Fy = 2y + 9x4y2 – sec2y ��

�� = −

��

��= −

�� ������

��������������

That’s pretty quick and straightforward. Why does it work? F(x,y)=0 �

��F(x,y) =

��(0)

��

�� · ��

�� +

��

�� · ��

�� = 0

��

�� = −

��

��

��

��

Note the position of the variables in the fraction on the left side and on the right side of the formula.

Page 66: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

66

Ex) find ��

�� given exy – cos(y) = 4x2

This extends to several variables: For F(x,y,z)=0,

��

��= −

��

����

��

…and similarly for the other partial derivatives.

Ex) exz2 – y3 = 2xy … find ��

�� and

��

��

The Directional Derivative and the Gradient

We have seen how to find ��

�� , the derivative of f(x,y) in the x-direction, and

��

�� , the derivative of f(x,y) in the

y-direction. Now we will find the derivative of f(x,y) in any direction. Directional Derivative – understood geometrically

Previously, we described the partial derivatives ��

�� and

��

�� . They came from drawing a trace in the x-direction

or the y-direction, then finding the slope of the trace at that point. To help draw the trace, we could intersect a plane. To help find the slope of the trace, we could zoom in to see straight lines in the tangent plane and visually approximate the slope. However, we could draw a trace in any direction. The slope of the trace at that point is the derivative of the function in that direction. To better understand this, let’s illustrate this on the graph, then develop the formula. Assume we have a function of two variables f(x,y) and a point in the domain (in 2 dimensions) p=(a,b). The surface z=f(x,y) has a tangent plane at the point (in 3 dimensions) q=(a,b,c). To indicate a direction from the point, there are 4 equivalent ways: (a) slice the surface with a vertical half-plane (b) starting at (a,b) in the domain, draw a vector v=(r,s) (c) starting at (a,b,c) on the surface, draw a line in the tangent plane (d) starting at (a,b,c) on the surface, draw a trace on the surface. We are most interested in the line in the tangent plane. Its direction matches v, so call it Tv . For that line, its run is measured in the v-direction, its rise (or fall) is

measured in the z-direction, and that slope � =����

��� is the derivative of f(x,y) in the v-direction.

Page 67: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

67 Directional derivative - Developing the formula Lets determine the rate of change of f(x,y) at a point p = (a,b) in the direction indicated by a vector v = (r,s). Thus v moves r units in the x-direction and s units in the y-direction. But we know the rate of change in the x-

direction, it is ��

�� , and the rate of change in the y-direction is

��

�� . So moving r units in the x-direction

produces r·��

�� units of change, and moving s units in the y-direction produces s·

��

�� units of change. So the

function changes by r· ��

�� + s·

��

�� However, if v is not a unit vector, |v|≠1, then the func�on changes r·

��

�� + s·

��

��

per |v| units. Therefore, its rate of change in the v direction is: �∙����∙��

|�|

If the vector v is a unit vector, then the rate of change of f in the directon of v is: r∙fx + s∙fy

Notation: the derivative of the function f in the direction of the vector v is Dvf [or ��

���⃗ ]

Ex) for z=3x3 + 5y2 and v=(-2,5), find Dvf at the point (2,3) We will introduce some notation for a very important concept, which will make that expression very simple.

For a function f(x,y), its gradient vector is ���

��,��

��� The notation is ∇f or ∇��⃗ �, read as “grad f”. Always

remember that ∇f is a vector. This is the first of many times we will use the gradient vector. The numerator can now be rewritten as the vector dot product ∇f · v. So the formula is:

Dvf = ∇f · �

|�|

If v is a unit vector, call it u, this formula simply becomes Duf = ∇f · u

Ex) for f(x,y) = ��

� find (a) the gradient vector ∇f (b) Dvf the derivative in the direction of v = (3,4) at point (3,2)

Finding the maximum and minimum directional derivative Duf = ∇f · u = |∇f|·|u|cosθ = |∇f|cosθ where θ is the angle between ∇f & u. Therefore, the directional derivative Duf is largest when θ=0, meaning ∇f & u are in the same direction. Thus: The direction of the greatest rate of change is the direction of the gradient vector ∇f The magnitude of the greatest rate of change is |∇f|, the magnitude of the gradient vector. Also, Duf is minimal when θ=π, meaning ∇f & u are in opposite directions, and then the minimal value of Duf is

-|∇f|. In addition, note that when the gradient vector and the direction vector are perpendicular, θ = �

� or

��

and the directional derivative is 0. ex) for f(x,y) = x ln(y) at the point (2,1) (a) find ∇f (b) what is the unit vector in the direction of the greatest rate of change? (c) What is the greatest rate of change? (d) What is the directional derivative in the direction �

� from the gradient direction?

Page 68: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

68 The Connection Between the Gradient and Level Curves We know that z=f(x,y) generates a surface in 3 dimensions. Also, f(x,y)=c for different values of c are level curves which are graphs in 2 dimensions. Note that in the direction along (or parallel to) a level curve, the function is not changing. For the unit vector u along (tangent to) a level curve of f(x,y),

Duf = 0 & Duf = ∇f · u → ∇f · u = 0 → ∇f & u are perpendicular The gradient vector (and the direction of greatest rate of change) is perpendicular to the level curves

Ex) for the surface f(x,y) = y – ex (a) graph the level curve at f=0 (b) find the gradient ∇f (c) find each normal vector on this level curve for x=0,1,2 (d) bonus: find a parallel (tangent) vector to the level curve at x=1 For a 3-dimensional surface defined by g(x,y,z)=0, its gradient is a 3-dimensional vector, and it will be perpendicular to the surface. (The reason is that the equation is a level curve for w=g(x,y,z). Note that this formula has 4 variables so it exists in 4 dimensions! We will not attempt to visualize that.)

Ex) for the surface xyz=12, find the equation of the normal line at the point (2,-2,-3) First, let f(x,y,z) = xyz ∇f = (fx, fy, fz) = (yz, xz, xy) ∇f(2,-2,-3) = ((-2)(-3), (2)(-3), (2)(-2)) = (6, -6, -4) Thus the normal line goes through the point (2,-2,-3) with direction (6,-6,-4)

The equation is (x,y,z) = (2,-2,-3) + t(6,-6,-4) OR ���

�=

���

��=

���

��

(Note: Since we have a point and a normal vector, we could now easily write down the equation of the tangent plane; this is an alternate method to do that.)

Page 69: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

69

Ex) find a vector perpendicular to the surface 0 = 4-x2-y2-z2 at the point (0.5,0.5,√3.5) When you are given z=f(x,y), the graph is a surface. Treat it as a function of two variables *unless* you need a vector perpendicular to the surface. In that case, rewrite it as g(x,y,z) = f(x,y)-z = 0 to convert it to a level curve of a function of 3 variables. At this point, it is useful to review some aspects of the gradient. For example, z=x+y is written as a function. It has 2 inputs and 1 output, so it will be graphed in 3 dimensions, and the gradient with 2 components will be in the domain. On the other hand, 0=x+y is written as a level curve. It has a total of 2 variables, so it is graphed in 2 dimensions, and the gradient (with 2 components) will be perpendicular to the graph. Similarly, w=3x-2y+z is written as a function. It has 3 inputs and 1 output, so it will be graphed in 4 dimensions, and the gradient (with 3 components) will be in the domain. On the other hand, 0=3x-2y+z is written as a level curve. It has a total of 3 variables, so it is graphed in 3 dimensions, and the gradient (with 3 components) will be perpendicular to the graph. The first and last case can be confused for each other. Consider the equation 0=x2+4y-z and its graph. It contains 3 variables and can be graphed in 3 dimensions. Is the gradient tangent or perpendicular to the graph? It depends on which “gradient” one takes. Suppose the equation is treated as z=x2+4y, a function of 2 variables. Then its gradient (with 2 components) is in the domain. On the other hand, suppose it is treated as the level curve of w=x2+4y-z, which is a function of 3 variables. Then the gradient (with 3 components) is perpendicular to the original graph. To understand the properties of the gradient, its important to keep in mind whether your original equation is a function or a level curve. Application: Maximum & Minimum For functions of 1 variable, to find the maxima and minima, we saw the need to identify critical points (f’(x) = 0 or undefined). Now let’s investigate the process for functions of 2 variables, first to find local max/min, then to find absolute max/min.

How can we identify all extreme points (local max & min)? In terms of calculations, all derivatives are 0. In terms of the geometry, the tangent plane is completely horizontal. Any such points are critical points of the function. But once we have the critical points, how can we tell which are maxima and which are minima? Also, just like in 1-variable calculus, there may be some points like that which are neither a max nor a min. And in 3 dimensions there are new ways for this to happen - what would that look like? How do we classify critical points as max, min, or neither?

This graph shows a saddle point. At (0,0,0), ��

�� = 0 and

��

�� = 0, but the point is neither a

local max nor local min

Page 70: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

70 To find critical points:

��

�� = 0 and

��

�� = 0 [or undefined, but we will skip that case due to the complexity of the calculations]

To classify critical points as local max, local min, neither, use the concavity (or second derivative) test: Calculate the discriminant d=(fxx)(fyy) – (fxy)

2 If d<0, then the point is a saddle point, neither max nor min If d>0, then it is an extreme point and:

if fxx>0 then the graph is concave up and the point is a relative min if fxx<0 then the graph is concave down and the point is a relative max

If d=0, then there is no conclusion Ex) find the critical points of f(x,y) = x4 + y4 – 4xy +1 and classify each as a max, min, or saddle Absolute Maximum & Minimum Recall from 2-dimensional calculus, to find the absolute max & min for a function on a closed interval, you had to check the critical points and the boundary values. In 3-dimensional calculus, you do the same thing. Note that, for the curve y=f(x), the boundary is two points. For a surface z=f(x,y), the boundary is a curve! (The mathematical theorem says that the absolute maximum and minimum of a function on a closed domain each occur either at a critical point or a boundary point.) We cannot check every boundary point. In the next problem, we will see how to identify which boundary points we need to check for absolute max/min. Ex) find the absolute max & min for f(x,y)=x2-2xy+2y on the region defined by 0≤x≤3, 0≤y≤2.

fx = 2x-2y = 0 → x=y classify as local max/min/neither: fy = -2x+2 = 0 → x=1 → y=1 fxx = 2 … fyy = 0 … fxy = -2 So the critical point is (1,1) d(1,1) = (2)(0) – (-2)2 = -4 saddle point

Now, check the boundary values. We need to identify which points on the boundary are possible extrema. But the boundary is a curve in 3 dimensions, so how do we do that? We can first break it into 4 straight lines. Since each boundary has x or y constant, finding the max & min on it is now a one-variable calculus problem. Test the critical points and the endpoints. The endpoints on each boundary are the corners of the region. Corners: (0,0), (0,2), (3,0), (3,2) On the boundary x=0, the function is f(0,y) = 2y Find boundary c.p.: (2y)’ = 2 That is 0 never, so no c.p.

Page 71: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

71 On the boundary x=3, the function is f(3,y) = 9-6y+2y = 9-4y Find boundary c.p.: (9-4y)’ = -4 That is 0 never, so no c.p. On the boundary y=0, the function is f(x,0) = x2 Find boundary c.p.: (x2)’ = 2x = 0 → x=0 is the critical point → boundary c.p. (0,0) On the boundary y=2, the function is f(x,2) = x2-4x+4 Find boundary c.p.: (x2-4x+4)’ = 2x-4 = 0 → x=2 → boundary c.p. (2,2) Note that we have three types of points to check: interior critical points, boundary critical points, and corners. Check values: (x,y) (0,0) (0,2) (3,0) (3,2) (2,2) (1,1) f(x,y) 0 4 9 3 0 1 Max point: (3,0,9) Min point: (0,0,0) & (2,2,0) …confirm this solution by looking at the graph… (A proof of the formula for the second derivative test is in the appendix.) In this problem, you have to find possible max/min on the boundary; that can be thought of as its own problem. So far, we only looked at the case where the boundary is a rectangle consisting of straight lines with x=constant or y=constant. But what if it was something different, like a circle? Or any curve? That problem can be solved with the techniques of the next section. Math Application: Solving Optimization with a Constraint (using Lagrange Multipliers)

It is a typical problem that you want to optimize something (such as maximizing profit) subject to some constraint (such as costs). In single variable calculus, this optimization problem starts with a function f(x,y) to optimize, and a constraint g(x,y)=k. It can be completed by solving for one variable in the constraint, substituting to eliminate one variable in the function, then taking the derivative and setting it to 0. This problem can be solved in general for several variables by the technique of Lagrange Multipliers.

Geometric Discussion Start with a contour map of the function to be optimized, f(x,y). Also draw the constraint g(x,y)=k. At the point where the constraint overlaps with the level curve with the largest value, they meet at only that one point, you can see they are tangent. (If the constraint crossed the level curve, then it would be headed for higher level curves.) Note that the constraint is actually a level curve. The gradient vector of the constraint function is perpendicular to the constraint graph, and the gradient vector of the function for optimizing is perpendicular to its level curve. Therefore, the two gradient vectors are parallel to (or in the same direction as) each other. In other words, ∇f = λ·∇g for some constant λ. That creates one equation for each component. Note that the gradient is a vector, so the number of equations is the same as the number of dimensions. λ is another variable, and the constraint is another equation. So there are n+1 variables and n+1 equations. While it is easiest to draw the picture of this discussion for functions of two variables, this is true for any number of variables. Notation: that constant λ is called a Lagrange multiplier. Most textbooks use λ, “lambda”, a lower case Greek L (in honor of Lagrange, for whom this method is named). Use any letter you like. (A letter like c is easier to type.)

Page 72: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

72 Ex) minimize the surface area of a cylinder with volume 100cm3 Set up: Function to optimize: surface area S = 2πr2 + 2πrh Constraint: V = πr2h = 100

Old method – eliminate one variable from the function and set the derivative to 0:

h = ���

�r-2

S = 2πr2 + 2πr���

�r-2 = 2πr2 + 200r-1

S’ = 4πr – 200r-2 = 0

r3 = ��

r = ���

� ≈ 2.52cm

h ≈ 5.03cm Surface area ≈ 119.34cm2 New Method – Lagrange Multipliers:

∇��⃗ �= �4�� + 2�ℎ

2��� , ∇��⃗ � = �

2��ℎ���

∇��⃗ S = c·∇��⃗ V x-equation: Sr = c Vr → 4πr + 2πh = c(2πrh) → 4r+2h = 2crh y-equation: Sh = c Vh → 2πr = cπr2 → 2=cr Constraint equation: πr2h = 100

Now do algebra. Eliminate variables one by one. In the y-equation, solve for c to get: c = �

� In the constraint,

solve for h to get: h = ���

�r-2 Plug those expressions for c & h into the x-equation to get:

4r + 2 ���

�r-2 = (2)

�r���

�r-2 → r3 =

��

� → r = �

��

� ≈ 2.52cm then h ≈ 5.03cm and surface area ≈ 119.34cm2

With 2 variables, both methods work with about the same level of difficulty. What about 3 variables?

Ex) A rectangular box without a lid will be made from 12m2 of cardboard. Find the maximum volume. Setup: Function to optimize: volume V = xyz Constraint: surface area S = xy + 2xz + 2yz = 12

Old method – eliminate a variable from the function and set the derivatives to 0:

� =�����

�����

� = �������

�����=

���������

�����

��

��=

����������(�����)������������(�)

(�����)�= 0

��

��=

����������(�����)������������(�)

(�����)�= 0

Let’s stop right there, because solving those two equations in two variables will be an algebraic mess.

Lagrange multiplier method:

∇��⃗ � = �

������� , ∇��⃗ �= �

2� + �2� + �2� + 2�

x-equation: Vx = c Sx → yz = c(2z+y) y-equation: Vy = c Sy → xz = c(2z+x) z-equaiton: Vz = c Sz → xy = c(2x+2y) Constraint equation: 2xz+2yz+xy=12

Page 73: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

73 There are several ways to solve this system of equations. The typical first step is to eliminate c the Lagrange multiplier.

Solving the x-equation for c: c = ��

����

Plug into the y-equation, then simplify: xz = ��(����)

���� → 2xz+xy = 2xz+2yz → x = 2z

Plug into the z-equation, then simplify: xy = ��(�����)

���� → 2xz+xy = 2yz+xy → x = y

Plug last two results into the constraint equation to get: 4z2 + 4z2 + 4z2 = 12 12z2 = 12 z=±1 (we need a length so take the positive value) Plug in to find that x=2 and y=2 z=1, x=2, y=2 and the maximum volume is V = (2)(2)(1) = 4m3. Ex) Math application: minimize the distance between the point (-3,0) and a point on the parabola y=x2

Function: distance = �(� + 3)� + (�)� A helpful trick: minimizing (distance) is the same as minimizing (distance)2, and the math is much easier Minimize f(x,y) = (x+3)2+y2 Constraint: y=x2 … g(x,y) = y-x2 = 0

∇��⃗ f = c·∇��⃗ g x-equation: fx = c(gx) … 2x+6 = c(-2x) y-equation: fy = c(gy) … 2y = c(1) constraint: y=x2 So 2x+6=(2y)(-2x) 2x+6=2(x2)(-2x) 4x3 + 2x + 6 = 0 (x+1)(4x2-4x+6) = 0 x=-1 (only one solution) so y=1

and the minimum distance is �(−1+ 3)� + (1)� = √5 Previously, we saw that, for a function defining a graph, the gradient vector is in the domain, in the direction of greatest rate of change for the function. Further, it is perpendicular to the level curve of the graph. In Lagrange multiplier problems, the gradient is perpendicular to the constraint graph. Why is that? This is because the constraint equation is a level curve for some function. Extra Credit material: Taylor Polynomials for Functions of Several Variables For 1-variable functions, we have seen the linear approximation of f(x) at x=a, which is the equation of the tangent line at that point, L(x)=f(a)+f’(a)·(x-a). Then we extended that to the Taylor Polynomial

approximation, Pn(x) = f(a) + f’(a)·(x-a) + �

�!f’’(a)·(x-a)2 +

�!f’’’(a)·(x-a)3 + … + +

�!f(n)(a)·(x-a)n

For 2-variable functions, we have seen the linear approximation of f(x,y) at (x,y)=(a,b), which is the equation of the tangent plane at that point, L(x,y)=f(a,b)+fx(a,b)·(x-a) + fy(a,b)·(y-b). Now, we expand the approximation to higher powers.

P2(x,y) = f(a,b)+fx(a,b)·(x-a) + fy(a,b)·(y-b) + �

�!fxx(a,b)·(x-a)2 + fxy(a,b)·(x-a)·(y-b) +

�!fyy(a,b)·(y-b)2

Note that the expression is more complicated because of the presence of mixed partial derivatives. You can check that every second partial derivative of f(x,y) agrees with P2(x,y) at the point (a,b).

Ex) for f(x,y) = �������, find P1 (which is the same as linear approximation L) and P2.

Page 74: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

74 Integration with Functions of Several Variables The simplest interpretation of the integral is that it is the opposite of the derivative. In 1-variable calculus: Ex) f’(x) = 2x, find f(x) f(x) = ∫ f’(x) dx

= ∫ 2x dx = x2 + C if you know an initial condition, you can solve for the constant … suppose that f(0)=1 f(0) = 02+C=1 → C=1 f(x) = x2+1 Now let’s apply this to 2-variable calculus. Ex) fxy(x,y) = x2y-4xy3 … find f(x,y) [assume all constants of integration are 0] First, undo the derivative with respect to y by integrating with respect to y fx(x,y) = ∫ fxy dy = ∫ x2y-4xy3 dy = ½ x2y2 – xy4

Now undo the derivative with respect to x by integrating with respect to x f(x,y) = ∫ ½ x2y2 – xy4 dx = 1/6 x

3y2 – ½ x2y4 [Note: dealing with constants of integration is trickier in multivariable calculus than in single-variable calculus. We will return to it in chapter X.] Since we will integrate twice, we can write that in the formula initially. We can also include boundary values.

Ex) calculate ∫ ∫ 6��� �� ���

Interpret it like this: ∫ �∫ 6��� ���

�� ��

� … first do the inner integral, where x is the variable and it has

boundary values 1 & 3

= ∫ [3����]��������

= ∫ (27��)− (3��)���

= ∫ 24�����

= [8��]������

= 512 – 64 = 448 So what we found is that f(x,y) = ∫∫ fxy(x,y) dy dx. Since we can take derivatives in either order and the result is the same (as long as the derivatives are continuous), we can also integrate in either order and the result is the same. We could also calculate these double integrals with boundary values. Note that when we integrate with respect to one variable, we assume all other variables are constant – just as with partial derivatives. Now let’s apply this to functions of 3 variables. Ex) if fxyz = x2y + excos(z) + yz3/2, find f(x,y,z) [assume all constants of integration are 0] fxy = ∫ fxyz dz

= ∫ x2y + excos(z) + yz3/2 dz = x2yz + exsin(z) + �

�yz5/2

fx = ∫ fxy dy

= ∫ x2yz + exsin(z) + �

�yz5/2dy =

�x2y2z + exysin(z) +

�y2z5/2

f = ∫ fx dx

= ∫ �

�x2y2z + exysin(z) +

�y2z5/2 dx =

�x3y2z + exysin(z) +

�xy2z5/2

Page 75: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

75 Since we will integratre thrice, we can write that in the formula initially. We can also include boundary values.

Ex) calculate ∫ ∫ ∫ �√� + 1 �� �� ����

��

That was a brief introduction of the multiple integral with several variables as an extension of the single integral with one variable. Now let’s look at possible meanings and uses. Math Application: Double Integral as a 3-Dimensional Volume Let’s review using integration to find area for functions of 1 variable. To find the area under y=f(x) over an interval, the interval is broken up into short intervals with length Δx. We take a point xi on each interval and make a rectangle with height f(xi). The approximate area over each interval is f(xi)·Δx, and the approximate

total area is ∑ f(xi)·Δx. The exact total area is found by taking Δx→0. Thus, area � = ∫ �(�)���

For a function of 2 variables in 3 dimensions, the space below the graph is a volume. It seems that we should be able to find it using the integral. There are two ways to think about this. The first way:

For 2-variable functions, there is a large region R which is broken up into small regions, each with area ΔA. Each one is the base of a rectangular solid, (xi, yj) is a point in the base and the height is f(xi, yj). The volume over that small region is f(xi, yj)·ΔA, the total volume is ∑i∑j f(xi, yj)·ΔA, and the exact volume comes from

Page 76: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

76 taking ΔA→0. Just as in the 1-variable case, that limit is hard to calculate directly. We define the volume as a double integral: V = ∫∫R f(x,y) dA The second way:

Think of the volume as a stack of slices. Let’s say each slice is at a different y-value. For each slice, the area is A(yj) and the width is Δy, so the approximate volume of each slice is A(yj)·Δy, and the approximate total volume is the sum ∑j A(yj)·Δy Next, any single slice area A(y) for y=constant can be split into rectangles, each at a different x-value. For each one, the height is f(x,y) and the width is Δx, so the approximate area of one rectangle is f(x,y)·Δx, and the approximate total area is the sum ∑ f(x,y)·Δx. Therefore the approximate volume is ∑ A(y)·Δy = ∑ (∑ f(x,y)·Δx)·Δy. This can be made exact by converting to an integral. So the volume is: V = ∫ A(y) dy = ∫ [ ∫ f(x,y)dx ] dy As a tradition, we do not write the brackets, but we calculate the inner integral first. Also, note that we could have sliced the other way, which would switch the order of x & y. Therefore, the volume is: V = ∫∫ f(x,y) dx dy OR ∫∫ f(x,y) dy dx What are the boundaries of integration? They are determined by the boundaries on the values for x & y, which are the boundaries of the region in the xy-plane. If the region is a rectangle, with a ≤ x ≤ b and c ≤ y ≤ d, then the volume is: ∫c

d ∫ab f(x,y) dx dy

Note: be careful to match the correct boundaries with the correct variable Ex) find the volume under f(x,y) = 2xy over the region enclosed by x=1, x=3, y=2, y=5

Page 77: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

77 What if the region is not a rectangle? In that case, the boundaries of the inner integral change depending on the outer variable. Ex) find the volume under f(x,y)= 4x2 + y3 + 4xy2 and over the region R enclosed by y=x2, y=0, x=2

Note that you can NOT say the boundaries are 0≤x≤2 & 0≤y≤4, because that would be the whole rectangle. First step: draw the region R in the xy-plane and make slices. There are two ways to draw the slices. In the first picture with vertical slices, notice that the slices range from x=0 to x=2. Further, on each slice, x is constant and y ranges in value from 0 to x2. Thus the boundaries are 0 ≤ x ≤ 2 & 0 ≤ y ≤ x2

and the volume is V = ∫ ∫ 4�� + �� + 4�����

���

���

Note that x has constant boundaries, so the outer integral is dx. Note that y has a variable boundary so the inner integral is dy. Next, consider the second picture with horizontal slices, where the slices range from y=0 to y=4. Further, on each slice, y is constant and x ranges from y1/2 to 2. Thus the boundaries are 0 ≤ y ≤ 4 and y1/2 ≤ x ≤ 2 and the

volume is V = ∫ ∫ 4�� + �� + 4����

��/� ��

���. Here x has a variable boundary and the inner integral is dx.

Vertical slice choice:

V = ∫ ∫ 4�� + �� + 4�����

���

���

= ∫ [4��� +�

��� +

����]���

������

= ∫ 4�� +�

��� +

�����

= ��

��� +

���� +

����

���

���

= ����

�� ≈ 82.49

Horizontal slice choice:

V = ∫ ∫ 4�� + �� + 4����

��/� ��

���

= ∫ ��

��� + ��� + 2�����

����/�

����

���

= ∫��

�+ 2�� + 8�� − �

���/� + ��/� + 2�����

= ���

�� +

��� −

����/� −

���/��

���

���

= ����

�� ≈ 82.49

When we calculate volume using double integrals of f(x,y), it often helps to have two pictures in mind: the graph of the solid in 3 dimensions, and the graph of the region R in 2 dimensions. The fact that you can switch the order of integration is a deep mathematical theorem.

Page 78: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

78 Fubini’s Theorem: if f(x,y) is a continuous function on the rectangle R = [a,b] x [c,d], then: ∫∫R f(x,y) dA = ∫c

d ∫ab f(x,y) dx dy = ∫a

b ∫cd f(x,y) dy dx

The theorem can be extended to more general regions, such as those defined by differentiable functions (like the problem above). The proof of these theorems is difficult and beyond the scope of this course. Ex) find ∫∫R x+2y dA, where R is the region bounded by y=2x2 & y=x2+1 First step: Note that it only makes sense to make vertical slices, not horizontal slices Ex) find the volume under z=xy over the region enclosed by y=x+1 & y2=2x+10 First step: Region R ⇒ vertical slices OR horizontal slices :

Note that one way of drawing slices will make a much easier calculation than the other. With vertical slices, sometimes the bottom function is the straight line, sometimes it’s the negative branch of the parabola – this will require a set-up with two integrals, which we would hope to avoid. With horizontal slices, the larger function is always the straight line and the smaller function is always the parabola. We previously encountered this idea of needing to choose a slice direction when calculating areas enclosed by curves (as well as volumes of solids of revolution).

Find x-boundary values (not constant): x=y-1 & x=�

�y2-5

Find y boundary values (constant) with points of intersection: y-1=�

�y2-5 → y2 -2y-8=0 → (y-4)(y+2)=0 → y=-2,4

V = ∫∫R f(x,y) dA = ∫ ∫ �� ������

�����

���

��

= ∫ ��

�����

���

�����

�������

��

Page 79: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

79

= ∫�

�(� − 1)�� −

�(�

��� − 5)����

��

= ∫ ��

��� − �� +

��� − �

��� −

��� +

��

��� ��

��

= ∫ −�

��� + 3�� − �� −

��

�� ��

��

= �−�

����+

��� −

��� −

��

����

����

���

= �−�

��(4)�+

�(4)� −

�(4)� −

��

�(4)�� − �−

��(−2)�+

�(−2)� −

�(−2)� −

��

�(−2)��

= 0

How can the volume be 0? We are calculating signed volume, just like signed area from 1-variable calculus. The volume counts positively for positive z-values, and negatively for negative z-values, so the net volume might be 0, as it is here. If you want to count all volume positively, take the absolute value of the function. This is typically very difficult to calculate by hand, but can be done numerically with technology. Ex) find ∫∫R sin(y2) dA, where R is the region bounded by y=x & y=1 & x=0 First, sketch R and make slices With the first slice choice, ∫∫R sin(y2) dA = ∫0

1 ∫x1 sin(y2) dy dx

= ?? That inside integral is impossible. So try the other slice choice, which changes the order of integration. ∫∫R sin(y2) dA = ∫0

1 ∫0y sin(y2) dx dy

Area as a double integral Note that, in single variable calculus, an integral with no function for height would give the length of the interval of x-values: ∫a

b dx = b – a In its approximate form, it is the sum of lengths ∑ Δx. In the same way, double integrals can be used to find area, by including only width and length (with no function for height). For a region R, to find its area, break it up into small rectangles. Each rectangle has height Δy, width Δx, and area ΔA. The total area of R is: Approximately, Area ≈ ∑∑ ΔA = ∑∑ Δx Δy (The sum is a double sum, once over the widths and once over the lengths.) Exactly, Area = ∫∫R dA = ∫∫R dx dy What are the boundaries of integration? They are determined by the boundaries on the values for x & y, which are the boundaries of the region in the xy-plane. Ex) find the area of the rectangle with -2 ≤ x ≤ 3 & 0 ≤ y ≤ 4

Area = ∫∫R dA = ∫ ∫ �� ���

��= ∫ [�]���

�����

��= ∫ 4��

��= [4�]��

� = 20

As an easier way to find the area, since this is just the area under the function y=f(x) for y=4, we could have

calculated Area=∫ 4���

��= [4�]��

� = 20

Page 80: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

80 An even easier way to find the area, since the region is a rectangle, is (4)(5) = 20. The double integral method to find the area is useful when the region is not a rectangle, or not defined by a function.

Ex) find the area enclosed by x+9=2y2 and x=y2 and above y=0 Find the intersections: x+9=2x -> 9=x -> y=3 … also y=0 Choose to slice horizontally, which is dy. On each slice, 2y2 - 9 ≤ x ≤ y2

Area = ∬R dA = ∫ ∫ �� ����

�����

= ∫ [�]�����������

�� = ∫ 9 − �����

�= �9� −

����

�= 18

ex) find the area enclosed by the ellipse ��

��+

��

��= 1

Area = ∫∫R dA

Here is another way to see why both a single integral and a double integral can calculate a 2-dimensional area. If the region can be sliced vertically, then the height is y=f(x) (or the difference between two functions), and the area reduces to

Area = ∫ ∫ �� ���(�)

�= ∫ [�]���

���(�)��

�= ∫ �(�)��

Similarly, if the region can be sliced horizontally, then the height (measured horizontally) is x=f(y) (or the difference between two functions), and the area reduces to

Area = ∫ ∫ �� ���(�)

�= ∫ [�]���

���(�)��

�= ∫ �(�)��

More Applications of Multiple Integrals Math Appliction: Average Value Previously, we saw that the average value of f(x) over

the interval [a,b] is favg = �

���∫ �(�)���

Page 81: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

81 The average value for multivariable functions works in a similar way.

The average value of f(x,y) on the region R is favg = �

����(�)∫∫� �(�, �)��

Ex) find the average value of the function f(x,y) = 4x+2x2y3 on the region R: 0≤x≤3, 1≤y≤5

favg = 1/12 ∫03 ∫1

5 4x+2x2y3 dy dx

= �

��∫ �4�� +

������

���

�����

= �

��∫ 16� + 312�����

= �

��[8�� + 104��]���

���

=�

��·2880

= 240 One way to interpret the answer is that the volume under the function and over this region is the same as a solid over the region with constant height 240. This still holds if the region is not a rectangle.

Math Application: Surface Area

For a function f(x,y) over a region R, the surface area is S = ∫ ∫��(��)� + (��)

� + 1 ��

Ex) find the surface area of f(x,y) = cos(x)+sin(y) over the region R: 0<x<4, 1<y<4 [set up, do not solve] fx = -sin(x) … fy = cos(y)

S = ∫ ∫��(−sin�)� + (cos�)� + 1 �� = ∫ ∫ ������ + ����� + 1 �� ���

One way to see why this is true is to recall that the area of a parallelogram with sides a and b is Area = |a X b|. At each point, the graph is approximated by a tangent plane. In the domain, each rectangle of area ΔA has sides Δx and Δy. Over that rectangle is a piece of the surface with area ΔS and piece of the tangent plane which is a parallelogram. One parallelogram side has constant x and one side has constant y. For the side with constant y, z is a function of x, it’s a piece of the tangent line which has slope fx. The change in x is Δx, the

change in y is 0, the change in z is ��

��∙∆�. As a vector, this is (1,0,fx)·Δx. Similarly, for

constant x, z is a function of y, the tangent line has slope fy. As a vector, this is (0,1,fy)·Δy. So the area of this parallelogram is:

|(1,0,fx)Δx X (0,1,fy)Δy| = |(-fx, -fy, 1)| Δx Δy= �(��)� + (��)

� + 1 Δx Δy. So, the total surface area is:

Approximately: surface area = ∑∑ ΔS ≈ ∑ ∑ �(��)� + (��)

� + 1 Δx Δy

Exactly: surface area = ∫∫R dS = ∫ ∫��(��)� + (��)

� + 1 �� �� or ∬�(��)� + (��)

� + 1 ��

Physics Application: Density, Mass, and Center of Mass Center of mass, introduction The center of mass is the balancing point. (Think of people sitting on a seesaw.) To find this point, we must consider mass, but we also must consider position. (Think of a lighter person balancing a heavier person on the seesaw by sitting further out.) A system of two weights is in balance when: m1d1 = m2d2 …where m1, m2 are masses of each object and d1, d2 are the distances from the balance point �̅. If we refer to position r instead of distance d, since one mass is on the positive side and one is on the negative side, d1=r1 but d2=-r2, so: m1r1 = -m2r2 or m1r1 + m2r2 = 0 Position can be described relative to the balancing point, so r1 = x1-�̅ and we get: m1 (x1 - �̅) + m2 (x2 - �̅) = 0

Page 82: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

82 solve for �̅… m1x1 – m1�̅ = m2�̅ – m2x2 m1x1 + m2x2 = m1�̅ + m2�̅

�̅ = ���������

�����

What if you have many objects? It is easy to generalize the formula.

�̅ = ∑����

∑��

Notation and names: �̅ is called the center of mass M = Σ mixi is called the moment of the system m = Σ mi is called the mass of the system (total mass)

center of mass �̅ = ������

����

note: the moment and the center of mass need to be calculated for each variable Ex) where is the center of mass of a standard 1-meter stick?

At the half-meter mark. This is just obvious, by symmetry. Ex) if a 3kg mass sits at 4cm and a 6kg mass sits at 10cm, where is the center of mass? mass m = 3+6 = 9kg Moment M = (3)(4)+(6)(10) = 72 kg·cm

Center of mass �̅ = ���� ��

��� = 8cm

Center of mass, one variable calculus Where is the center of mass of a meter stick that gets denser the closer you get to the 1m end? Ex) find the center of mass for a 1m stick which has density 0.1x kg/m at the x-distance To find �̅, we need find the moment and the mass.

mass = �����

������� (�����ℎ) = (density)(length)

In a little piece of the stick at xi, Δm ≈ r(xi)·Δx, where r(x) = density

At a point on the stick, ��

��= �(�) or dm = r(x)dx

To find the total mass, add up all the little masses: approximately, m = ∑ Δm ≈ ∑ r(xi)·Δx

exactly, m = ∫dm = ∫ r(x) dx For our stick, mass = ∫0

1 0.1x dx = 0.05x2 |0

1 = 0.05 kg moment = (position)(mass) =(position)(density)(length) The total moment is

Approximately: M ≈ Σ x·r(xi) ∆x Exactly: M = ∫ x·r(x) dx For our stick, moment M = ∫ x(0.1x)dx = ∫0

1 0.1x2 dx = 0.033x3|0

1 = 0.033 kg·m

Center of mass �̅ = ������

����=

�.�����∙�

�.���� = 0.66 m

To summarize the general formulas:

mass m = ∫ r(x) dx … Moment M = ∫ x·r(x) dx … center of mass �̅ = �

r(x)=density, x=position

Page 83: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

83

Center of mass, several variable calculus The size of a 2-dimensional object is measured as area instead of length. Then we have:

mass = �����

����� (����) = (density)(area)

Now, density is a function of two variables, r(x,y) mass m = ∫∫R r(x,y) dA x-moment Mx = ∫∫R x·r(x,y) dA y-moment My = ∫∫R y·r(x,y) dA

x-center of mass �̅ = ��

y-center of mass �� = ��

ex) find the total mass and center of mass of a sheet with density r(x,y)=x+y2 kg/m2 over the region R: 0<x<2, 0<y<3 m = ∫∫R r(x,y) dA

= ∫ ∫ � + ���� ���

= ∫ [0.5�� + ���]��������

= ∫ 2 + 2�� ���

= �2� +�

����

���

���

= 24 kg Mx = ∫∫R x·r(x,y) dA

= ∫ ∫ �� + ����� ���

= ∫ ��

��� +

������

���

�����

= ∫�

�+ 2�� ��

= ��

�� +

����

���

���

= 26 kg·m My = ∫∫R y·r(x,y) dA

= ∫ ∫ �� + ���� ���

= ∫ [0.5��� + ���]��������

= ∫ 2� + 2�� ���

= ��� +�

����

���

���

= 49.5 kg·m

x-center of mass �̅ = ��

�� ≈ 1.08 m

y-center of mass �� = ��.�

�� ≈ 2.06 m

the center of mass is (1.08, 2.06)

Math Application: Probability

A brief introduction

The probability of an event is its frequency out of the total number of possibilities, Prob = �

Ex) if you roll a regular die, what is Prob(3)? 1/6 Ex) what is Prob(roll larger than a 4)? 2/6

Page 84: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

84 Suppose you have the following probability distribution for family size:

# children Probability

0 .11

1 .24

2 .34

3 .23

4+ .08

Ex) find Prob(2 children) Ex) find Prob(from 1 to 3 children) Ex) find the average number of children Notice that: Prob(a≤x≤b) = Prob(a) + …+ Prob(b) = ∑ a≤x≤b Prob(x) Probability with calculus, one variable The previous method assumes you can list all of the outcomes with their probabilities. But what if there is a continuum of possibilities? (For example, the temperature can be any real number.)

For an interval of a certain length, ���� =����

������∙�����ℎ. The function for

����

������ is called the probability

density function, written p(x). For a short interval of length Δx, Prob(x is on the interval)≈p(xi)·Δx. For a long interval, the probability is the sum of the little probabilities: Approximately: Prob(a≤x≤b)≈∑ p(xi)·Δx [by definition, Prob(x) = p(x)·Δx] Exactly: Prob(a≤x≤b) = ∫a

b p(x) dx [the same as the formula for mass!]

Note that the total probability is always 1, so the integral over all possibilities is 1: ∫ �(�)���

�� = 1.

If there is a continuum of possibilities, the mean is: Approximately: μ ≈ x1·Prob(x1) + … + xn·Prob(xn) = ∑ x·Prob(x) where this includes all possible x-values

Exactly: μ = ∫ � ∙�(�)���

�� [the same as the formula for moment]

Note that when we calculuate the mean, typically we divide by the total number of values. Here, however, that total number is represented by the total probability, which is 1, so to divide by 1 is redundant. Ex) for the probability density function p(x)=0.5x for 0<x<2 (p=0 elsewhere), (a) confirm that this is a probability density function (b) find the probability P(x>1) (c) find the mean

(a) ∫ �(�)���

��= ∫ 0.5� �� = [0.25��]�

��

� = 0.25(2)2 – 0.25(0)2 = 1

(b) Prob(x>1) = ∫12 0.5x dx

= [0.25x2 ]12 = 0.75

(c) Mean μ = ∫ x·p(x) dx = ∫0

2 x(0.5x)dx = ∫0

2 0.5x2 dx

= [�

�x3 ]0

2

= �

� ≈ 1.33

Probability with calculus, several variables Now, we consider the probability of two events. In general, the probability that the point (x,y) is within the region R can be written ∫∫R p(x,y) dA, where p(x,y) is called the joint probability density function. Note that, since the total probability is 1, ∫∫D p(x,y) dA=1, where D is the entire plane, representing all possibilities. The probability that x is between a & b and y is between c & d is: Prob(a<x<b, c<y<d) = ∫a

b ∫cd p(x,y) dy dx.

The mean (or expected value) for x is μx = ∫∫D x·p(x,y) dA. The mean for y is μy = ∫∫D y·p(x,y) dA. Ex) When you go to a movie, you have to wait on the ticket line and then wait for concessions. At one cinema, we have a model for total wait times For x=minutes waiting for tickets and y=minutes waiting for

Page 85: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

85

concessions, p(x,y) = �

�����/�����/� for x,y>0. Set up (do not solve) (a) the probability that both wait times

are less than 5 minutes (b) the probability that the total wait time is less than 20 minutes (c) the mean ticket wait time

(a) Prob(x<5,y<5)=∫ ∫�

�����/�����/��� ��

(b) Prob(x+y<20) = ∫ ∫�

�����/�����/��� ��

����

��

(c) mean μx = ∫ ∫ � ∙�

�����/�����/��� ��

Double integrals with polar coordinates [omit] Previously, we found that Area = ∫∫R dA = ∫∫R dx dy in rectangular coordinates, and

Area = ∫ �

� r2 dθ in polar coordinates. We can turn this into a double integral. Using

formulas, note that �

� r2 = ∫ r dr. So the area expression can be wri�en as a double

integral, Area = ∫∫R r dr dθ. Using a graph, note that in polar coordinates, a tiny sector from small changes in r & θ is nearly a rectangle, with side lengths dr and r dθ, so dA = r dr dθ. Ex) find the area enclosed by a circle radius 2 (centered at the origin).

Area = ∫∫R dA = ∫ ∫ � �� ���

��

�= ∫ �

����

���

��

�= ∫ 2 ��

��

�= [2�]�

�� = 4�

This equivalence also tells us how to change integrals between rectangular and polar coordinates. ∫∫R f dx dy = ∫∫R f r dr dθ On the left side the function is expressed in x & y, f=f(x,y), and on the right side the function is expressed in r & θ, f=f(r,θ). Ex) calculate ∫∫R x2 dx dy where R is the top half of the circle radius 1 centered at the origin With rectangular coordinates:

∫∫R x2 dx dy = ∫ ∫ �� �� �� = ∫ [���]�√������

��

√����

��= ∫ ��√1− ����

�� …and this is possible but hard

With polar coordinates:

∫∫R x2 dx dy = ∫ ∫ (� ����)�� �� ���

�= ∫ ∫ ������� �� ��

�= ∫ �

�����������

���

����

�= ∫

��������

= �

�∫ 1 + cos2� ���

�=

��� +

�sin2��

�=

Ex) find the area of a three-quarter-annulus, part of the region between two circles, radii 2 & 3 Notice that, if you try to set up the integral using dx dy, there is no good way to describe R or

slice R. But if you use polar coordinates, then R is 2 ≤ � ≤ 3, 0 ≤ � ≤��

� and:

Area = ∫ ∫��� = ∫ ∫ � �� ���

��/�

�= ∫ �

����

���

��/�

�= ∫

��/�

��� = �

���

��/�=

��

��

This region is made from elementary shapes, so you could find its area using basic area formulas:

Area = �

�(π(3)2 – π(2)2) =

��

�π

For alternate proofs of the formula to convert integrals between rectangular and polar coordinates, see the appendix.

Page 86: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

86 Triple Integrals Previously, we integrated over a line segment in R using dx, and over a region in R2 using dA (which could be dxdy or rdrdθ). Now we will integrate over a solid region in R3. Break the solid region R into little boxes. Each one has width Δx, length Δy, height Δz, and volume ΔV. First, note that adding up the volume of the little boxes yields the total volume. Ex) find the volume of the region R, a cylinder centered around the z-axis, radius=3, from z=0 to z=2

V = ∫∫∫R dV, or ∫ ∫ ∫ �������

��������

��

���

= ∫ ∫ [�]���������������

���

��

���

= ∫02 ∫-3

3 2�9 − �� dy dz (note that this dy integral is the area of a circle with radius 3) = ∫0

2 9π dz = [9πz]0

2 = 18π Of course, we could also find the volume with the formula, V = πr2h = π(3)2(2) = 18π Next we consider the case of integrating a function f(x,y,z) on that 3-dimensional region. We form the sum ∑i∑j∑k f(xi, yj, zk) ΔV, or ∑i∑j∑k f(xi, yj, zk) Δx Δy Δz. This is an approximation of the integral, ∫∫∫R f(x,y,z) dV, or ∫∫∫R f(x,y,z) dx dy dz. Suppose the region R is a solid rectangle, a ≤ x ≤ b, c ≤ y ≤ d, p ≤ z ≤ q. Then the integral of f(x,y,z) over R is ∫p

q ∫cd ∫a

b f(x,y,z) dx dy dz Note: the integral of a 2-variable function can represent a volume in 3 dimensions. So the integral of a 3-variable function can represent a volume in 4 dimensions. This is impossible to draw! So we must be satisfied with understanding the idea as an extension from lower dimensions. Other interpretations are easier to draw, and we will look at some of those. In fact, all of the applications from 2-variable functions generalize to 3-variable functions. The best way to keep track of what is being calculated is to note the units of each component. For example, for ∫∫∫R dx dy dz, if x & y & z are lengths, then the result is (length)3, or 3D volume. Also, for ∫∫R f dx dy, if f & x & y are lengths, then the result is (length)3, or 3D volume. Math Application: Density, mass, moment, center of mass for 3-variable functions For a solid object, if its density at a point (x,y,z) in a region R is r(x,y,z), measured in kg/m3, then the mass is: m = ∫∫∫R r(x,y,z) dV, or ∫∫∫R r(x,y,z) dx dy dz The moment is: For the x-direction, Mx = ∫∫∫R x·r(x,y,z) dx dy dz For the y-direction, My = ∫∫∫R y·r(x,y,z) dx dy dz For the z-direction, Mz = ∫∫∫R z·r(x,y,z) dx dy dz

The center of mass is (�̅, ��, �̅)= ���

�,��

�,��

��

Other Coordinate Systems in 3 dimensions Cylindrical coordinates Spherical coordinates Integration [see the appendix]

Page 87: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

87 Vector Fields

How would you mathematically represent wind patterns? How would you represent water currents? How about the force on an electron in the presence of a magnet?

For wind and water, we would measure the velocity of the particles at any point. This is a velocity field. For the magnet, we would measure the force exerted on a charged particle at any point. This is a force field. In either case, at every point in space, there is a magnitude and direction, so we have a vector field. A vector field is a function which takes a point in Rn (or a region of it) and assigns a vector in Rn. (We will usually work in R2 or R3.) In each of these pictures, vectors at various points have been drawn.

Notation: We can write the formula for an arbitrary vector field. In R3, F = P(x,y,z)i + Q(x,y,z)j + R(x,y,z)k or �����

Ex) for the vector field F = (y/x)i + (x2y+sin(πx))j, find the vector at the point (4,-2)

Page 88: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

88 We have already calculated one type of vector field before, the gradient vector field. For a function f(x,y), at every point (x,y), you get the vector ∇f=(fx, fy). At any point, we know the vector direction is the direction of the greatest rate of change of the function and the vector magnitude is that maximum rate of change. Ex) find the gradient vector field for f(x,y) = 2exy+y2

Vector fields are one of the most important objects of study in physics. Here are some examples. Fluid velocity field

The velocity vector of a fluid at any point is described by the vector field �⃗. Gravitational force field

Newton’s law of gravitational attraction says that the force between two masses is F = ���

��, where G is a

known constant, m & M are the two masses (in kg) and r is the distance between them (in m). The force also has a direction. If mass M is fixed at the origin (0,0) and mass m is at the point �⃗ = (x,y), then the force on mass m is from �⃗ to the origin. That direction vector is (0,0)-(x,y) = (-x,-y), or -�⃗. Using the notation r=|�⃗|, the unit

direction vector is ��⃗

� Now we have the magnitude and the direction. Therefore the gravitational force is

described by a vector field called the gravitational force field, �⃗ = −���

���⃗. Note that ��⃗� = �−

���

���⃗�=

���

��=F

Electric force field

Coulomb’s law of attraction for charged objects says that the force between two charges is F = ���

��, where k is

a known constant, q & Q are the two charges (in Coulombs), and r is the distance between them (in m). The force has a direction. Assume charge Q is fixed at the origin (0,0) and charge q is at the point �⃗ = (x,y). If the charges have the same sign (so qQ>0), the force on charge q is away from the origin. If the charges have

opposite signs (so qQ<0), the force on q is toward the origin. The unit direction vector is ±�⃗

|�⃗| (positive in the

first case, negative in the second case). Now we have the magnitude and the direction. Therefore the electric

force is described by a vector field called the electric force field, �⃗ =���

���⃗. And ��⃗� = �

���

���⃗�=

���

�� = F

The gravitational field �⃗ is actually a gradient vector field. For the function f(x,y) = ���

�, the following

calculation shows that ∇��⃗ � = �⃗ (recall that r =|�⃗|= ��� + �� ).

� =���

(�����)�/�= ���(�� + ��)��/�

∇��⃗ � = ����(−0.5)(�� + ��)��/�(2�)

���(−0.5)(�� + ��)��/�(2�)� = −

���

������ �� −

���

���⃗

In general, where ∇��⃗ � = �⃗, f is called the potential function of the vector field �⃗, and the vector field �⃗ is

called conservative. In Physics, the convention is that P=-f is the potential function. Thus, −∇��⃗ � = ∇��⃗ � = �⃗.

When necessary, we will specify if we seek f or P. Also, note that f, F, and �⃗ are different objects.

Page 89: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

89 Vector Field Operators

Now we will introduce some important operators on vector fields. We will learn some amazing general properties. Further, in physics applications, the mathematical results tell us about the physical properties of systems such as fluid flow and electromagnetic fields. An operator is a type of function. For this topic, we don’t need the formal definition; just think of it as a function which takes an input and gives an output.

Swirl

The swirl of a vector field F(x,y)=(P,Q) in two variables is: swirl(F) = ��

��−

��

��

Ex) for F = (y,-x), find the swirl

Q=-x, so ��

�� = -1 & P = y so

��

�� = 1

swirl(F) = -1 – 1 = -2 Ex) for F = (3x,2y), find the swirl. swirl(F) = 0 – 0 = 0

The reason for the name swirl can be understood in the context of fluid flow. Fluid particles near (x,y) tend to go straight or spin in circles (or some combination), and the speed of their spinning is determined by the magnitude of swirl. The vector field in the first example has some circular movement at every point in the plane. If swirl(F) = 0, the fluid flow is called non-swirling. The vector field in the second example has no circular movement at any point. Note that, for the swirl operator, the input is a 2-variable vector field and the output is a scalar which involves derivatives of the components.

Divergence

The divergence of a vector field F is defined as: div(F) = ��

��+

��

��+

��

�� (Note that div can be calculated for a

vector field with any number of variables.)

There is a shorthand notation for the divergence formula related to the gradient. Recall that ∇��⃗ � =

⎜⎛

���

���

���⎠

⎟⎞

Page 90: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

90

Rewrite this as

⎜⎛

���

��

��⎠

⎟⎞�, and think of ∇��⃗ as a vector of derivative operators, ∇��⃗ =

⎜⎛

���

��

��⎠

⎟⎞

or ��

��+ �

��+ �

��

Now div(�⃗) can be written as ∇��⃗ ∙�⃗ because

⎜⎛

���

��

��⎠

⎟⎞∙����� =

��

��+

��

��+

��

�� Therefore we have:

div(�⃗) = ∇��⃗ ∙�⃗ = ��

��+

��

��+

��

��

Note that the divergence of a vector field can be defined using the dot product, and the result is a scalar. Note that, for the div operator, the input is a vector field and the output is a scalar whose formula involves derivatives of the components.

Ex) for F = (3x2y, xy), find div(F) Ex) for F = xyzi + xcos(y)j + tan(x2+xy3)k, find div(F) The reason for the name divergence can be understood in the context of fluid flow. If F(x,y,z) represents the flow, or velocity, of a fluid, then div(F) is the net flow of the mass of fluid at the point (x,y,z). If div(F) = 0, then the same amount of fluid always comes in as is going out, and the fluid (and its flow F) is called incompressible. If the divergence at a point is positive, more fluid is leaving than entering, so in a sense fluid is “gained” and the point is called a source. If the divergence at a point is negative, more fluid is entering than leaving, so in a sense fluid is “lost” and the point is called a sink.

Curl

The curl of a vector field in 3 variables is defined as: curl(F) = ���

��−

��

��� � + �

��

��−

��

��� � + �

��

��−

��

���� OR

⎜⎛

��

��−

��

��

��

��−

��

����

��−

��

��⎠

⎟⎞

Again, there is a shorthand notation for the formula related to the gradient. A calculation confirms that:

curl(�⃗) = ∇��⃗ � �⃗ =

⎜⎛

���

��

��⎠

⎟⎞��

���� =

⎜⎛

��� −

���

��� −

���

��� −

���⎠

⎟⎞ OR �

��

��−

��

��� � + �

��

��−

��

��� � + �

��

��−

��

����

Note that the curl of a vector field can be defined using the cross product, and the result is a vector field. Note that, for the curl operator, the input is a 3-variable vector field and the output is a 3-variable vector field (whose formula involves derivatives of the components).

Ex) for F= 3xze2yi + xyz2j + (2x+3yz)k, calculate curl(F)

Page 91: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

91 Ex) F = yi – xj +1k, calculate curl F curl F = (0-0)i + (0-0)j + (-1-1)k = -2k Ex) F = xi + yj + zk, calculate curl F curl F = (0-0)i + (0-0)j + (0-0)k = 0

The reason for the name curl can again be understood in the context of fluid flow. Fluid particles near (x,y,z) tend to rotate around the axis determined by the curl vector, and the speed of their rotations is determined

by the magnitude of the curl vector. If curl(F) = 0�⃗ , the fluid is rotation-free. The vector field from the first example is plotted on the left, and it is easy to see the rotation; the axis of rotation is straight up and down, which is the z-axis. The vector field from the second example is plotted on the right, and it is easy to see there is no rotation. Curl seems like a 3-dimensional version of swirl, and that’s not a coincidence. For F = (P,Q,R), we can make a

2-dimensional version by setting R=0. Then curl(P,Q,0) = (0-0)i + (0-0)j + ���

��−

��

���k = swirl(P,Q)k. The

magnitude of the z-component of the curl formula is the swirl formula. This can be written as curl(P,Q,R)·k = swirl(P,Q). For this reason, another name for swirl is scalar curl.

Theorem: If f(x,y) has continuous second partial derivatives, then swirl(∇f) = 0 Proof: by a direct calculation,

swirl(∇f) = swirl������ = fyx - fxy = 0

Recall that a vector field F is conservative when ∇f=F. Therefore, if F(x,y) is conservative then swirl(F) = 0. As long as the domain is connected (you can make a path between any two points), the converse is also true: If swirl(F)=0 then F(x,y) is conservative. Ex) show that F = (2xcos(y), -x2sin(y) ) is conservative

Theorem: If f(x,y,z) has continuous second partial derivatives, then curl(∇f) = 0�⃗ Proof: by a direct calculation, curl(∇f) = ∇ X (∇f) = (fzy – fyz)i + (fxz - fzx )j + (fyx - fxy )k = 0i + 0j + 0k

Recall that a vector field F is conservative when ∇f=F. Therefore, if F(x,y,z) is conservative then curl(F) = 0�⃗

Page 92: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

92 As long as F is defined in all of R3, the converse is also true. For a vector field F, if F is defined everywhere in

R3 and the component functions P,Q,R have continuous partial derivatives and curl(F) =0�⃗ then F is a conservative vector field. (The proof of this requires Stokes Theorem, which is covered later in the chapter.) Ex) determine if F = (y-ezsinx, x, ezcosx) is a conservative vector field F is defined everywhere on R3 and its component derivatives are continuous

curl(F) = ���

��−

��

��� � + �

��

��−

��

��� � + �

��

��−

��

���� = (0 - 0)i + (-ezsinx - -ezsinx)j + (1 – 1)k = 0i + 0j + 0k OR 0�⃗

Therefore, F is conservative (in other words, for some function f, ∇f=F) Further, we can find the potential function f:

fx = y-ezsinx … f = xy + ezcosx + ? where ? looks like a constant when you take �

�� so it is a function of y&z

fy = x … f = xy + ?? where ?? is a function of x&z fz = ezcosx … f = ezcosx + ??? where ??? is a function of x&y Therefore, f = xy + ezcosx + C Theorem: for a 3-dimensional vector field F, if the components P,Q,R have continuous second partial derivatives, then div(curl(F)) = 0 Proof: by a direct calculation, div (curl(F))

= div���

��−

��

��,��

��−

��

��,��

��−

��

���

= �

�����

��−

��

��� +

�����

��−

��

��� +

�����

��−

��

���

= ���

����−

���

����+

���

����−

���

����+

���

����−

���

���� = 0

since terms cancel because you can switch the order of the derivatives ex) show that F = (2xy, yz, xez) is not the curl of another vector field. F certainly has continuous derivatives. So if F = curl(G), then div(F) = div(curl(G)) = 0. But div(F) = 2y+z+xez ≠ 0

curl(∇f) = 0�⃗

Examples of conservative force fields are gravitation, �⃗ = −���

���⃗, and electromagnetism, �⃗ =

���

���⃗.

Line Integral

Previously, we had a function y=f(x) and we could integrate it over an interval of x-values [a,b]. Now, we will integrate a function f over a parametric curve C, with the interval determined by t-values (a scalar line integral).

Page 93: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

93 Then we will integrate a vector field F over a curve C (a vector field line integral). Then we will see connections between scalar line integrals and vector field line integrals. Line integral of a scalar function with respect to arc length First, let’s look at what it means to integrate a function over an interval. We previously saw integrals of y=f(x) over an interval of x-values. Now lets look at integrals of f(x,y) where x=x(t), y=y(t) so the interval is for t-values. Before: Now:

In the previous case, as x changes our position on the horizontal axis changes. In the new case, as t changes our position on the curve changes. (C is defined parametrically by r(t)=(x(t), y(t) )

Expression Classic: y=f(x) Parametrized: f=f(t) = f(x(t), y(t) ) = f(r(t))

variable x t

Rectangle height f f

Rectangle width Δx Δs = �(∆�)� + (∆�)�

Area, approximate ∑ f Δx ∑ f Δs

Area, exact � �(�)�����

���

∫��(�, �)�� = � �( ��(�), �(�)�)∙��

��

����

+ ���

����

�����

���

Ex) find the area under f=x3y-1 over the curve C defined by y=x2 for 2≤x≤3. The first step is to convert all expressions so that the variable is the parameter t. For the curve: x=t, y=t2 and 2≤t≤3. Also, dx/dt=1 & dy/dt=2t. For the function, f=(t3)(t2)-1 = t. Now:

∫���� = ∫ (�)√1 + 4�������

��� …u=1+4t2 du=8t dt

=∫�

�(�)�/��� =

����/� = �

��(1 + 4��)�/��

���

���=

��37�/� −

��17�/� ≈ 12.9

It seems like we didn’t really need to use t, we could just have replaced y with x2 and then done the calculation. That’s because y is a function of x. But parametric curves include cases more general than that.

Ex) find the area under f=3x-4y over C defined by the left half of the circle centered at the origin with radius 1.

Rewrite in terms of the parameter t. For the curve, x=cos t, y=sin t for �

� ≤ t ≤

��

�. For the function,

f=3cost – 4sint. Now,

∫�� �� = ∫ (3cos� − 4sin�)�(−sin�)� + (cos�)� ������/�

���/�

= ∫ 3cos� − 4sin� ������/�

���/�

= [3sin� + 4cos�]�/���/�

= (-3+0) - (3+0) = -6

Note that we chose to start at the top of the curve and go to the bottom. We could also have started at the bottom. That would switch the boundaries of integration, which would switch the sign of the result. A

Page 94: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

94 selected direction for a curve is called an orientation. So changing the orientation changes the sign but not the magnitude of the result. In single-variable calculus, this is equivalent to switching the boundaries of integration. (Note how changing “from a to b” into “from b to a” changes the direction along C.) We have seen that the same graph can have more than one formula by taking a reparametrization. Fortunately, a theorem tells us that a reparametrization does not affect the line integral, so we can use whichever parametrization we want. Note that the classic form is a special case of the parametrized form. For the classic integral, the parametrized curve is the straight line from (a,0) to (b,0), the parametrization is x=t, y=0. Algebraically,

∫�� �� = ∫ �(�, �)∙����

����+ �

��

������

���

���= ∫ �(�, 0)∙1��

���

��� = ∫ �(�)��

���

���.

Note: there are many equivalent notations for f, which can be confusing. The variable t is plugged into functions x(t) & y(t) to get values for x & y, which together form the vector r. Those values are plugged into f and generate a scalar. If you write f(t), it is simpler but you omit the role of the vector r or coordinates x & y. If you write f(r(t)) or f( x(t), y(t) ) , it is more complete but also more complicated. Line integral of a scalar function in 3 dimensions The line integral formula extends from 2 dimensions to 3 dimensions in the natural way. To integrate a function f over a curve C (with respect to arc length):

∫��(�, �, �)�� = ∫ �(�(�), �(�), �(�))∙����

����+ �

��

����+ �

��

������

���

���

Ex) find the area under the function f=y sin(z) along the curve C defined by r = (cos t, sin t, t) for 0≤t≤2π

∫C y sinz ds = ∫02π sin(t) sin(t)�[��(�)]� + [��(�)]� + [�′(�)]���

= ∫02π sin2(t)√����� + ����� + 1�� = √2∫

�(1− cos(2�))��

��

= √�

��� −

�sin (2�)�

��= √2�

Note: this could represent the area under the function along the curve. However, since for functions of 2 variables you need 3 dimensions to see the area, then for functions of 3 variables you need 4 dimensions to see the area, and we cannot draw that. Application in Physics: Density and Mass

Recall that if a linear object covers the line segment a<x<b and has a linear density p(x) (in units kg/m), then

the mass is � = ∫ �(�)���

� Also, its moment is M = ∫ � ∙�(�)��

Now, let’s extend this to parametric equations. If a linear object’s shape is the curve C defined by r=(x(t), y(t) )

for a<t<b, with linear density p(x,y), then the mass is m = ∫� � �� Further, its moments are Mx = ∫�� ∙� ��

and My = ∫�� ∙� �� Finally, its center of mass is (�̅, ��)= ���

�,��

��

Ex) Find the center of mass of the wire with density p=x+2y which forms a quarter-circle, center (0,0) radius 1, in the first quadrant. First make the parametrizations: For C, x=cos t, y=sin t, 0 ≤ t ≤ π/2 For p, p=cos(t) + 2sin(t)

For the differentials, x’=-sin(t) & y’=cos(t) & ds = �(−sin(�))� + (cos(�))��� = dt Mass m = ∫C p ds = ∫0

π/2 cos(t) + 2sin(t) dt = [sin(t)-2cos(t)]0π/2 = 1 - -2 = 3kg

x-moment Mx = ∫C x p ds = ∫0π/2 cos(t) (cos(t) + 2sin(t)) dt = ∫0

π/2 cos2t + 2sin(t)cos(t) dt

Page 95: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

95

= ∫0π/2 0.5+0.5cos(2t) + sin(2t) dt = [0.5t + 0.25sin(2t) – 0.5cos(2t)]0

π/2 = (0.25π + 0 + 0.5) – (-0.5) = 1+0.25π ≈ 1.79

y-moment = My = ∫C y p ds = ∫0π/2 sin(t) (cos(t) + 2sin(t)) dt = ∫0

π/2 2sin2t + sin(t)cos(t) dt = ∫0

π/2 1 - cos(2t) + 0.5sin(2t) dt = [t - 0.5sin(2t) – 0.25cos(2t)]0π/2 = (0.5π - 0 + 0.25) – (-0.25)

= 0.5 + 0.5π ≈ 2.07 Center of mass = (1.79/3, 2.07/3) ≈ (0.6, 0.69) Line integral in a vector field The idea behind a line integral in a vector field can be seen from the physics application of work. Recall the basic case, in which quantities are scalar and constant, W = F·x, where W is work (in Joules), F is force (in Newtons) and x is distance (in meters). Where the quantities are scalar but varying, W = ∫a

b F dx. Where the

quantities are vectors but constant, � = �⃗ ∙�⃗. Now we look at the final case where the quantities are vector

and varying. The answer, in one form, is � = ∫ �⃗ ∙��⃗��⃗

��⃗. For the position function, we can write �⃗ instead of

�⃗, so the integral is ∫ �⃗ ∙��⃗��⃗

��⃗ This formula also makes sense if you construct an approximation. A short piece

of the path including �⃗� has approximate length Δ�⃗, the value of the vector field on that segment is

approximately �⃗(�⃗�), and the work done over that short piece of the path is approximately �⃗(�⃗�)∙��⃗. The

total work is approximately � ≈ ∑ �⃗(�⃗�)∙��⃗. The total work is exactly � = ∫ �⃗ ∙��⃗��⃗

��⃗

To actually calculate this, we will rewrite using the parameter t. Recall that �⃗(�) describes a path in space C,

so �⃗ = (�, �, �)= (�(�), �(�), �(�)). For the boundaries of integration, let �⃗(��)= �⃗ and �⃗(��)= ��⃗ . For the

force vector function, �⃗ = �⃗(�, �, �)= �⃗��(�), �(�), �(�)� = �⃗(�⃗(�)). The following formulas for ��⃗ are all

equivalent:

��⃗ =��⃗

���� = ���(�), ��(�), ��(�)��� … also, ��⃗ = �

������

� =

⎜⎛

��

����

��

����

��

����⎠

⎟⎞=

⎜⎛

��

����

����

��⎠

⎟⎞��

There are so many equivalent notations because the expression may involve r⃗ or x/y/z or t. Thus,

� = ∫��⃗ ∙��⃗ = ∫ �⃗��⃗(�)� ∙��⃗

����

����

= ∫ �⃗��(�), �(�), �(�)� ∙���(�), ��(�), ��(�)�������

.

This is the formula to find Work. Further, it is the general definition of the line integral of a vector field F over a curve C defined by �⃗(�). There are several forms of the equation; use whichever works best for you. Geometrically, what is ��⃗ ? Well, ��⃗ is the short vector between two nearby points, so ��⃗ is the vector of

infinitesimal length between two points on the curve. (Note that it is tangent to the curve, just like ��⃗

��.)

Ex) Find the work done by the force vector field �⃗ = (x+y, x-2z, 2x-y) over the straight line C defined by r = (1+3t,3-4t,-2+4t), for 0≤t≤1 First, rewite using the parameter. �⃗ (the formula for C) is already parametrized. d�⃗=(3,-4,4)dt.

For the vector field, �⃗ = ((1+3t)+(3-4t), (1+3t)-2(-2+4t), 2(1+3t)-(3-4t) ) = (4-t,5-5t,-1+10t). So,

W = ∫ �⃗��⃗(�)� ∙��⃗

����

����

= ∫ (4 − �, 5 − 5�, −1 + 10�)∙(3,−4,4)�� = ∫ 12− 3� − 20 + 20� − 4 + 40��� �

= ∫ −12 + 57� �� = �−12� +��

����

��

�= 16.5 joules

Ex) find the line integral of F=(xy,2-yz, xz) over the curve C which is the straight line from (2,1,2) to (5,2,-3) First rewrite parametrically. C is a straight line, the direction vector is (5,2,-3) – (2,1,2) = (3,1,-5), so its parametrization is: r = (2,1,2) + t(3,1,-5) = (2+3t, 1+t, 2-5t) with 0<t<1.

Page 96: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

96 dr = (3,1,-5)dt F = ( (2+3t)(1+t), 2-(1+t)(2-5t), (2+3t)(2-5t) ) = (2+5t+t2, 3t+5t2, 4-4t-15t2) The line integral is

∫��⃗ ∙��⃗ = ∫01 (2+5t+t2, 3t+5t2, 4-4t-15t2)·(3,1,-5) dt

= ∫01 6+15t+3t2 + 3t+5t2 -20 + 20t + 75t2 dt = ∫0

1 -14 + 38t + 83t2 dt = [-14t + 19t2 + 27.67t3]01 = 32.67

Two ways to connect scalar line integrals and vector field line integrals Line integral of scalar functions in coordinate form In the last problem, one could perform the steps of the calculation in a different order:

∫��⃗ ∙��⃗ = ∫C (xy,2-yz, xz)·(dx, dy, dz) = ∫C xydx + (2-yz)dy + xzdz …and now execute the parametrization

This form is called a scalar line integral in coordinate form. The general formula is:

∫C �⃗ ∙��⃗ = ∫C (P,Q,R) · (dx, dy, dz) = ∫C P dx + Q dy + R dz

Thus, ∫C �⃗ ∙��⃗ = ∫C P dx + Q dy + R dz …so we see that a vector field line integral has an equivalent scalar line integral. This makes sense because the vector field line integral is an integral (or sum) of magnitudes (or scalars), as you can see from the dot product. Ex) calculate ∫C xy2 dx + y dy where C is the curve x-2=y2 from (3,-1) to (6,2) First, write the parametrizations. On the curve C, y=t, x=t2+2, and -1 ≤ t ≤ 2. Also, dx=2t dt, dy=dt. Now,

∫C xy2 dx + y dy = ∫ (t� + 2)t�2t dt + t dt�

��= ∫ 2�� + 4�� + � ��

��

= ���

�+ �� +

��

����

= ���

�+ 16 + 2� − �

�+ 1 +

��

= 37.5

To calculate a coordinate scalar line integral in 3 variables, ∫C P dx + Q dy + R dz, for the curve C where x=x(t), y=y(t), z=z(t), we use the same approach to rewrite everything in terms of the parameter t.

Ex) calculate ∫C �

� dx + xy dy + z dz where C is defined by �⃗=(t3,2t,sin t) for 0<t<2

There is yet another way to write a vector field line integral. Since ��⃗ =�⃗�

|�⃗�| and �� = |�⃗′|��,

�⃗ ∙��⃗ = �⃗ ∙�⃗��� = �⃗ ∙�⃗�

|�⃗�|∙|�⃗′|�� = �⃗ ∙��⃗ ��

This provides an alternate way to write a line integral in a vector field with respect to ds. What this tells you is

that you only want to count the tangential (in the direction of the curve) component of �⃗.

Also note that |��⃗| = |(��, ��, ��)| = �(��)� + (��)� + (��)� = ��, which demonstrates multiple ways to describe a short length on a curve. Summary There are several forms of line integral:

∫�� �� (a scalar line integral)

(if f is a height, this represents area; if f is a probability density, this represents probability)

∫��⃗ ∙��⃗ (a vector line integral)

Page 97: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

97

(if �⃗ is a force, this represents Work) ∫C P dx + Q dy + R dz (a coordinate scalar line integral)

∫��⃗ ∙��⃗ �� (an alternate form of the vector line integral)

We know that (formulas are presented assuming 3 variables): C is a curve defined by the parametric formula �⃗ = (x(t), y(t), z(t) )

�⃗ is a vector field defined by the formula �⃗ = (P(x,y,z), Q(x,y,z), R(x,y,z) )

ds =����

����+ �

��

����+ �

��

������

��⃗ = �⃗�(�)�� = ���(�), ��(�), ��(�)��� … also, ��⃗ = �������

� =

⎜⎛

��

����

��

����

��

����⎠

⎟⎞=

⎜⎛

��

����

����

��⎠

⎟⎞��

To calculate a line integral, we can use a parametrization in terms of t to rewrite the expression as an integral of one variable.

Fundamental theorem of line integrals (FTLI)

Previously, we saw the Fundamental Theorem of Calculus (FTC) for one variable, ∫ ��(�)���

� = f(b) – f(a).

Roughly speaking, the integral of the derivative is the original function evaluated on the endpoints. Now, we will see a verision called the Fundamental Theorem for Line Integrals (FTLI). It looks nearly the same; the key step is to identify the appropriate expression which is both a derivative and a vector – it is the gradient.

∫�∇��⃗ � ∙��⃗ = ���⃗(�)� − �(�⃗(�))

where the curve C is defined by �⃗(�) for a ≤ t ≤ b, also f and �⃗(�) have continuous derivatives. Proof:

∫�∇��⃗ � ∙��⃗ = ∫ ∇��⃗ � ∙

��⃗

����

= ∫ ���

��∙��

��+

��

��∙��

��+

��

��∙��

��� ��

� …note that the expression, by the chain rule, is

��

��, so…

= ∫�

�����⃗(�)���

� …now we apply the FTC from single variable calculus, to get…

= ���⃗(�)� − �(�⃗(�))

Ex) calculate ∫C �⃗ ∙��⃗ where �⃗=(y-ezsinx, x, ezcosx) and C is defined by �⃗ = (t,5t-t2,2t) for 0 ≤ t ≤ 2π In a previous example, we found that this vector field has potential function f= xy + ezcosx. Write f in tems of t: f = (t)(5t-t2)+e2tcos(t). So the integral is:

∫�∇��⃗ � ∙��⃗ = f(�⃗(2π)) – f(�⃗(0)) = (2π)(10π-4π2)+e4π – (0·0+e0cos0)

= 20π2 -8π3 + e4π – 1 [An alternate method: find the endpoints, �⃗(0)=(0,0,0) & �⃗(2π)=(2π,10π-4π2,4π), then plug those into f.]

Note that typically, a line integral calculation begins with parametrizing the vector field �⃗ and the curve C, then an expression is integrated. By the Fundamental Theorem of Line Integrals, we do not have to do all that work;

once we have �⃗ = ∇��⃗ � we can just use the potential function and the endpoints. Further, this implies something remarkable: in calculating this line integral, the path does not matter, only the endpoints. This property is called path independence. This property could be incredibly useful in calculating a line integral. For example, if the path is very twisted or has a very complicated expression, it doesn’t matter, you only need the two endpoints to complete the calculation. Now we need to know which line integrals have this property. We have just shown that if the vector field is

conservative, then the line integral is path independent. It turns out that if the line integral ∫C �⃗ ∙��⃗ is path

independent, then the vector field �⃗ is conservative. (The proof is in the appendix.)

Ex) calculate ∫C �⃗ ∙��⃗ where C is �⃗ =(t,t2,t3) for 1<t<2 and �⃗ = (4xyz3, 2x2z3, 6x2yz2)

Page 98: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

98

This will be a much simpler calculation if �⃗ is conservative, with potential function f. fx = 4xyz3 … f = 2x2yz3 + ? fy = 2x2z3 … f = 2x2yz3 + ?? fz = 6x2yz2 … f = 2x2yz3 + ??? therefore f = 2x2yz3 (note that since this is a definite integral, we don’t need the constant +C)

so ∫C �⃗ ∙��⃗ = ∫�∇��⃗ � ∙��⃗ = ���⃗(�)� − �(�⃗(�)) = f(2,4,8) - f(1,1,1) = 16384 – 2 = 16382

Notation: For a 2-variable function, df = fxdx + fydy = ∇��⃗ f·d�⃗. (Similarly, for a 3-variable function,

df = fxdx + fydy + fzdz = ∇��⃗ f·d�⃗.) So written this way, the Fundamental Theorem of Line Integrals becomes

∫C df = f(��⃗ ) – f(�⃗), where �⃗ and ��⃗ are the endpoints of the curve.

Let’s find another property of path independent line integrals. Let �⃗ be a path-independent vector field. Let C be a path which begins and ends at a point A (C is called a closed path). Let B be another point on the path, and C1 and C2 are the two paths from A to B.

∫���⃗ ∙��⃗ = ∫��

�⃗ ∙��⃗ by the definition of path independence

∫���⃗ ∙��⃗ − ∫��

�⃗ ∙��⃗ = 0 by getting one side to be 0

∫ �⃗ ∙��⃗ −�

� ∫ �⃗ ∙��⃗�

�= 0 by rewriting with the curve endpoints

∫ �⃗ ∙��⃗�

�+ ∫ �⃗ ∙��⃗

�= 0 because switching endpoints switches the sign

∫��⃗ ∙��⃗ = 0 because the combined paths of the two integrals form the closed path

The line integral ∫C �⃗ ∙��⃗ is path independent in a domain D precisely when ∫C �⃗ ∙��⃗ = 0 for every closed path. This will be useful for any conservative force, and there are many important conservative forces in physics. We have already seen the two most important, the gravitational force and the electromagnetic force.

Ex) How much work is done by the gravitational field �⃗ =���

���⃗ to move a 5 kg mass along the triangle from

(2,3) to (4,-3) to (-6,1) back to (2,3)?

�⃗ is conservative, and the path is closed, so W = ∫C �⃗ ∙��⃗ = 0. Ex) How much work does the earth’s gravitational field do to bring a 70000kg satellite from an elevation of 100,000m to 40,000m ? (earth mass = 5.97 X 1024 kg, G = 6.67 x 10-11 Nm2/kg2)

The gravitational field has potential function f = ���

�, so

W = ∫C �⃗ ∙��⃗ = ∫�∇��⃗ � ∙��⃗ = f(40000) – f(100000) = 6.97 x 1014 – 2.78 x 1014 = 4.19 x 1014 joules.

Alternately, P = −���

� and W = P(A) – P(B) = - 2.78 x 1014 + 6.97 x 1014 = 4.19 x 1014 joules.

Application in Physics: Conservation of Energy

Let’s apply these formulas to motion. Suppose �⃗ is a force field which moves an object. (This could be through gravitation, electromagnetism, etc.) The object will move from point A to point B along a path C with the formula �⃗(�) where �⃗(a)=A and �⃗(b)=B. Newton’s Second Law of Motion says that (force) =

(mass)(acceleration), so we have F=ma (in scalar form) and �⃗ = ��⃗ (in vector form). Acceleration is the

second derivative of position, so �⃗ = ��⃗��(�). Lets calculate how much work the force field does to move the object from A to B.

W = ∫C �⃗ ∙��⃗ = ∫ ��⃗��(�)∙�⃗�(�)���

�= �∫

��

�[�⃗�(�)∙�⃗�(�)]��

�=

�∫

��|�⃗�(�)|���

= ��

�|�⃗�(�)|��

�=

��|�⃗�(�)|� −

��|�⃗�(�)|�

Page 99: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

99

Note that |�⃗�| = |�⃗| = � which is the speed. The expression �

���� is called the kinetic energy K. So the work

done by the field on the object represents the object’s change in kinetic energy: W = K(B) – K(A). If �⃗ is a

conservative field (such as gravity or electromagnetic), then �⃗ = ∇��⃗ �. The potential energy of an object in a

conservative field is defined as P=-f, so �⃗ = −∇��⃗ P. The total energy is the kinetic energy and potential energy combined, E = K + P. (For this situation, we assume other forms of energy don’t change and ignore them.)

W = ∫C �⃗ ∙��⃗ = ∫C -∇��⃗ P·d�⃗ = -P(�⃗(b)) + P(�⃗(a)) = P(A) – P(B) Using the two equations for W: K(B) – K(A) = P(A) – P(B) K(A) + P(A) = K(B) + P(B) E(A) = E(B) Therefore, the total energy E is constant, or conserved. This is the Law of Conservation of Energy, and it is an important example of why gradient fields are called conservative. Summary

Fundamental Theorem of Line Integals (FTLI): ∫�∇��⃗ � ∙��⃗ = ���⃗(�)� − �(�⃗(�))

�⃗ = ∇��⃗ � ⇔ �⃗ is conservative ⇔ ∫C �⃗ ∙��⃗ is path independent ⇔ ∫C �⃗ ∙��⃗ = 0 for all closed paths Green’s Theorem

Previously, the Fundamental Theorem of Calculus – and its vector version, the Fundamental Theorem of Line Integrals – gave an equation between the integral of a derivative expression over a line (which is 1-dimensional) and the evaluation of the original expression at the line’s boundary endpoints (which are 0-dimensional).

FTC: ∫ ��(�)���

� = f(b) – f(a) FTLI: ∫�∇

��⃗ � ∙��⃗ = ����⃗ � − �(�⃗)

Next, we find a relationship for two-variable functions between an integral over a 2-dimensional graph (a surface) and an integral over a 1-dimensional graph (a line). Amazingly, it’s a similar relationship, as long as we properly use the idea of boundary, and carefully define the proper derivative expression – the one we want is swirl(F). For a smooth 2-dimensional vector field F(x,y), when the curve C is the boundary of the region R:

∫∫R swirl(F) dA = ∫C F·dr

Written out in coordinates, using F=(P,Q) and dr=(dx,dy), this is the same as: ∬� ���

��−

��

��� �� = ∫���� + ���

Note that, in order for C to be the boundary of a region R, it must be a closed path. Typically the line integral is hard to calculate but the surface integral is easy; sometimes it’s the other way.

ex) calculate ∫C (x-y)dx+(x+y)dy where C is the circle centered at the origin with radius 2 Method 1: calculate directly as a line integral Parametrize: x=2cos(t) & y=2sin(t) … dx = -2sin(t)dt … dy = 2cos(t)dt … 0<t<2π ∫C (x-y)dx+(x+y)dy = ∫0

2π (2cos(t)-2sin(t))(-2sin(t))dt + (2cos(t)+2sin(t))2cos(t)dt = ∫0

2π -4cos(t)sin(t) + 4sin2t + 4cos2t + 4cos(t)sin(t) dt = ∫0

2π 4 dt = [4t]02π = 8π

Method 2: since C is a closed path we can use Green’s Theorem F = (P,Q) = (x-y, x+y). Now use either form:

In coordinate form: ∫C Pdx + Qdy = ∬� ���

��−

��

��� ��

In vector form: ∫C F·dr = ∬R swirl(F) dA calculate swirl(F) = Qx – Py = 1 - -1 = 2 so ∫C (x-y)dx+(x+y)dy = ∬R 2 dA = 2·Area(R) = 8π

In that example, both methods will solve the problem. That is not always the case.

Ex) calculate ∫C x2cosx dx + ey cos ydy where C is the circle radius 1 centered at the origin.

If we calculated this as a line integral, we would parametrize: x=cos(t), y=sin(t) and dx=-sin(t)dt,dy=cos(t)dt

Page 100: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

100 ∫C x

2cosx dx + ey cos ydy = ∫02π

cos2t cos(cos(t))dt + esin(t)cos(sin(t))cos(t)dt It is not clear how to do that integral. Fortunately, with Green’s Theorem, we don’t have to. ∫C x

2cosx dx + ey cos ydy = ∫∫R swirl(F)dA for F=(x2cosx, ey cos y) swirl(F) = Qx - Py = 0 – 0 = 0 … so the integral = 0

Notice what Green’s Theorem tells us about a conservative field F = ∇f. Recall that swirl(F) = swirl(∇f) = 0. Therefore, ∫C F·dr = ∫∫R swirl(F) dA = 0. The line integral of a conservative vector field over closed loop is 0. We already knew that from the FTLI, so now we know it a different way. Application in Physics: Work Ex) find the work done by the force F = (cosy-y,- xsiny) to move a particle once counterclockwise around the rectangle with corners at (2,1) (5,1) (5,7) (2,7) W = ∫C F·dr Method 1: calculate directly as a line integral W = ∫C cos(y)-y dx + -xsin(y)dy To parametrize, break up C into 4 line segments. On the first, x=t, y=1, t goes from 2 to 5, dx=dt, dy=0. On the second, x=5, y=t, t goes from 1 to 7, dx=0, dy=dt. On the third, x=t, y=7, t goes from 5 to 2, dx=dt, dy=0. On the fourth, x=2, y=t, t goes from 7 to 1, dx=0, dy=dt.

= ∫25 cos(1)-1 dt + ∫1

7 -5sin(t)dt + ∫52 cos(7)-7dt + ∫7

1 -2sin(t)dt [note that when dx=0 or dy=0 on a given segment, then the corresponding integral is 0] = 3cos(1)-3 + 5cos(7)-5cos(1) + 2cos(7)-5cos(7)+21 + 2cos(1)-2cos(7) = 18

Method 2: since C is a closed path, we can use Green’s Theorem W = ∫C F·dr = ∬R swirl(F) dA [where curve C is the boundary of region R] Now calculate: swirl(F) = (-xsiny)x – (cosy-y)y = -siny + 1 + siny = 1 = ∬R 1 dA = 1·Area(R) = 18 Note that if swirl(F) is a function (not a constant), it still may be easier to calculate the integral that way. Application in Math: using Green’s Theorem to calculate the area

ex) find the area enclosed by the ellipse ��

��+

��

��= 1

Recall that the area of the region R is ∫∫R 1 dA Here, R is the interior of the ellipse. We can convert that to a

line integral using Green’s Theorem, as long as we can find F=(P,Q) so that swirl(F) = ��

��−

��

��= 1. There are

many possibilities, let’s use F=(-0.5y,0.5x) [In this problem that choice simplifies the calculations.] Area = ∫∫R 1 dA = ∫C -0.5y dx + 0.5x dy …where C is the ellipse, the boundary of the enclosed area. The ellipse can be parametrized with x = a·cos(t), y=b·sin(t) for 0≤t≤2π, and then dx=-a sin(t)dt, dy=b cos(t)dt Area = ∫0

2π -0.5(bsin t)(-a sin t)dt + 0.5 (a cos t)(b cos t)dt = ∫0

2π 0.5ab sin2t + 0.5ab cos2t dt = ∫0

2π 0.5ab dt = 0.5abt|0

2π = πab

What does Green’s Theorem mean? Why is it true? Previously, for the fundamental theorem of calculus, we saw that the way to prove the FTC was to divide the line from a to b into segments. Then, the sum of the little changes is the same as the total change between

the endpoints. So ∑∆�

∆�∙∆� = ∑ ∆� = �(�)− �(�) and in the limit ∫ �′(�)��

�= �(�)− �(�).

We want to translate this result to a function of 2 variables whose domain is a 2-dimensional region. For simplicity, consider the case where the region is a rectangle. Start with an oriented closed path C which is the boundary of the region. Then divide the region up, for example into four pieces, with each one enclosed by an oriented closed path.

Page 101: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

101 Notice that, because of the orientation, the interior path segments cancel – think of adding a forward and backward vector – so C equals the sum of the four (oriented) loops. So the line integrals are equal as well:

∫��⃗ ∙��⃗ = ∫���⃗ ∙��⃗ + ∫��

�⃗ ∙��⃗ + ∫���⃗ ∙��⃗ + ∫��

�⃗ ∙��⃗

When you divide the region futher and further, you get a sum of many integrals over tiny loops. It turns out

that, in the limit, this expression becomes ��

��−

��

�� and the integral is over the entire region since the paths

now cover the entire region. To understand why the expression is actually ��

��−

��

�� , and for a more complete

proof, see the appendix. Summary Greens Theorem: For a smooth 2-dimensional vector field F(x,y), when the closed path C is the boundary of the region R:

∫∫R swirl(F) dA = ∫C F·dr

Written out in coordinates, using F=(P,Q) and dr=(dx,dy), this is the same as: ∬� ���

��−

��

��� �� = ∫���� + ���

Parametric Surfaces Previously, we described a curve using parametric equations. The formula for the curve C was f = f(t) = f(x(t),y(t),z(t)) = f(r(t)). Note that for a curve in 2 dimensions or 3 dimensions (or any number of dimensions), no matter the number of coordinates, the function could be expressed as a function of one variable, the parameter t. If you zoom in on the graph, you see a straight line. This resembles the real number line, which can be described with one variable, and we have typically used x for that. Now, we will describe surfaces using parametric equations. When we zoom in on a surface, it looks like a plane. This resembles the R2 plane, which requires two variables to describe it; we have typically used x & y. To describe our surface, we will use the parameters u & v. This allows us to describe the coordinates of the surface in R3 using x/y/z. So the formula for a surface S is �⃗(u,v)=(x(u,v),y(u,v),z(u,v)). For the function �⃗, the input is a 2-dimensional point and the output is a 3-dimensional point. As a result, the surface is 2-dimensional and it exists in 3 dimensions.

Ex) graph the surface r = (2cos(u),2sin(u),v)

Page 102: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

102 Previously, for the surface z=f(x,y), traces were lines contained in the surface which represented z as a function of one variable (the other variable was constant) and created a sort of coordinate grid on the surface itself. Now, we make a coordinate grid for parametrized surfaces. We must use our variables u & v. Note that slicing the surface with a plane for a constant x or y does not work, since z is not a function of x & y. For fixed v the height is fixed, and as u varies it traces out a circle of radius 2. For fixed u, a place on the circle is fixed, and as v varies it traces out a vertical line. The graph of the surface was redrawn to include these lines, called grid lines. As before, parametric equations are more general and versatile than a function, and allow for varied graphs.

Ex) This is a picture of fusilli bucati. It’s the shape of a corkscrew, but hollow on the inside. With parametric equations, we can write the formula for this tasty pasta. �⃗(u,v) = (u+cosv,(2+sinv)cosu, (2+sinv)sinu+3)

In the above fusili graph, notice that as u increases, for constant v, the x-value increases linearly while y and z values oscillate. As v increases, for constant u, y & z will oscillate like a sin curve, while x will oscillate like a cos curve, making loops. The graph of the surface can be redrawn to include grid lines.

Parametric equation for surfaces of revolution Previously, we formed a surface of revolution by taking the graph y=f(x) and rotating around the x-axis (or y-axis). Cross-sections of the resulting surface are circles. Thus, when x is constant, the circle is in the y-z plane, the radius comes from the initial height of f(x), and the center is the x-axis, where (y,z)=(0,0). Thus in the y-z plane, the parametric equation of the circle is (y,z) = (rcosθ, rsinθ) = (f(x)cosθ, f(x)sinθ). We reintroduce the x variable to get the equation for the entire surface of revolution: r = (x,y,z) = (x, f(x)cosθ, f(x)sinθ) ). Note that, written this way, we have used x and θ as our two parameters. Ex) find the equation of the surface of revolution when y=4-x2 with y positive is rotated around the x-axis. Note that if y is positive, then -2<x<2. r = (x, (4-x2)cosθ, (4-x2)sinθ)

Page 103: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

103 Tangent Plane for Parametric Surfaces Previously, we saw that for the surface z=f(x,y), the tangent plane at the point (x0,y0,z0) was z – z0 = fx(x0,y0,z0)·(x-x0) + fy(x0,y0,z0)·(y-y0). Now we will write the equation of the tangent plane for a parametric surface r=r(u,v)=(x(u,v),y(u,v),z(u,v)) at the point r(u0,v0)=(x0,y0,z0). First, we need two direction vectors in the tangent plane. Once again, we form those tangent vectors by taking the partial derivative with respect to each variable; in this case those are u & v. The two tangent vectors are ru = (xu,yu,zu) & rv = (xv,yv,zv). We can either take the cross-product to get a normal vector, n = ru X rv, and write the standard equation, or write the parametric equation of the plane. The tangent plane exists precisely when n = ru X rv ≠ 0. The surface is called regular at points where that is true. The surface is called regular if it is regular at all points. Where the surface is regular, the equation of the tangent plane at (a,b,c) is: (x-a,y-b,z-c)·n=0 Ex) find the equation of the tangent plane to r = (ucosv,usinv,u2+v2) at the point r(1,0)=(1,0,1). Also find all non-regular points for the surface for 0≤u≤2π, 0≤v≤2π. ru = (cosv, sinv, 2u) …at (1,0), ru = (1,0,2) rv = (-usinv, ucosv, 2v) …at (1,0), rv = (0,1,0) Method 1 (normal vector): Normal vector n = ru X rv = (-2u2cosv+2vsinv, -2u2sinv-2vcosv, u) …at (1,0), n = (-2,0,1) Tangent plane: (x-1, y-0, z-1)·(-2,0,1) = 0 … -2(x-1)+0(y-0)+1(z-1)=0 or -2x+z=-1 The surface is not regular when (-2u2cosv+2vsinv, -2u2sinv-2vcosv, u)=(0,0,0), so u=v=0. Method 2 (parametric): (x,y,z) = (x0,y0,z0) + s·ru + t·rv (x,y,z) = (1,0,1) + s(1,0,2) + t(0,1,0) (Note that we already used u & v as parameters for the surface, so we use different parameters, s & t, for the plane.) It is possible to show that the two different forms are equivalent by eliminating the parameters. x=1+s, y=t, z=1+2s Thus z=1+2(x-1)=2x-1, and y can take any value. Suppose the surface can be written as a function of two variables, z=f(x,y). Then it can be written parametrically as (x,y,z)=(u, v, f(u,v)) ru = (1,0,fu) rv = (0,1,fv) n = ru X rv = (-fu, -fv, 1) The equation of the tangent plane is: (x-a,y-b,z-c)· (-fu, -fv, 1)=0 …since x=u and y=v, we get… z-c = fx(a,b)·(x-a)+ fy(a,b)·(y-b) Once again, the classic formula is a special case of the parametric formula. Surface Integrals

Page 104: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

104 Previously, we saw how to take the integral over a parametrized curve. First we learned how to rewrite in terms of the parameter in order to convert from ds to dt. The basic line integral is first, and the result is the arc length L. Further, this conversion allowed us to calculate any path integral, as in the second equation.

Now we use the same idea to calculate the integral over a parametrized surface. First we must learn how to rewrite in terms of the parameters in order to convert from dS to dA (or du dv). Doing this will allow us to calculate surface area. Then that conversion will allow us to calculate any surface integral. We will develop the formula as we investigate the first application. Application in Math: Surface Area for Parametric Surfaces

Previously we saw that the surface area for a surface z=f(x,y) was Area = ∫∫� �(��)� + (��)

� + 1 ��

The expression to be integrated came from |a X b|, the norm of the cross-product of the two tangent vectors. Now, we develop the formula for surface area for parametric surfaces using the same idea. Over each rectangle Aij including (ui, vj) of area ΔA with sides Δu and Δv in the domain is a piece of the surface of area ΔSij, and a parallelogram in the tangent plane of area ∆Pij. For each parallelogram, two sides are the

tangent vectors ruΔu = ���

��∆�,

��

��∆�,

��

��∆�� and rvΔv = �

��

��∆�,

��

��∆�,

��

��∆��, and the area is |ruΔu X rvΔv| =

|ru X rv|Δu Δv. So the total area of the surface is: Approximately: Area = ∑∑ ΔSij ≈ ∑∑ |ru X rv|Δu Δv Exactly: Area = ∫∫ dS = ∫∫ |ru X rv|du dv OR ∫∫ |ru X rv| dA Note: |ru X rv| = |(xu, yu, zu) X (xv, yv, zv)| = |(yuzv-zuyv, zuxv-xuzv, xuyv-yuxv)| = [(yuzv-zuyv)

2 + (zuxv-xuzv)2 + (xuyv-yuxv)

2]1/2

Ex) find the surface area of r(u,v)=(ucos(v),usin(v),u) for 0≤u≤2 0≤v≤2π Note that this describes a cone of height 2 (u plays the role of r, v plays the role of θ). Area = ∫0

2π∫01 |ru X rv| dA

= ∫02π∫0

1 |(cosv,sinv,1) X (-usinv, ucosv,0)|dudv = ∫0

2π∫01 |(-ucosv, usinv, u)| dudv= ∫0

2π∫01 ((ucosv)2 + (usinv)2 + u2)1/2 dudv

= ∫02π∫0

1 u√2 dudv = ∫0

2π[0.5 u2√2]01 dv

= ∫02π 0.5√2 dv

= [0.5√2v]02π

= π√2

Page 105: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

105 Now we know the formula for conversion for integrals over parametric surfaces. Where r(D)=S:

Application to Physics: Density (per area), mass and center of mass

Surface Integral in a Vector Field

Application in Physics: Electrodynamics

Application in Physics: Thermodynamics

Page 106: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

106

Page 107: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

107 Limits If a function is continuous and well-defined at a point, finding the limit at that point is as easy as plugging the point into the function. That was true for one-variable functions, and it’s true for two-variable functions.

Ex) find lim(�,�)→ (�,�)����

= ����

� = 1.5

In general, however, limits for functions of two variables are much more challenging to calculate than with functions of one variable. Instead of one variable approaching one value, two variables are each approaching their own value. To think of this graphically, one variable point is approaching a fixed point. But it is not specified how that approach is made. Perhaps x stays the same and y is changing. Perhaps y stays the same and x is changing. Perhaps they are both changing. It turns out, this choice may affect the limit value. We will explore limits in the same 3 ways as before – numerically, graphically, and algebraically.

Numerical limits

Previously, to find the limit of a function of one variable, we made a list of function values. We need a way to represent function values of two variables. A table does this nicely.

Ex) find lim(�,�)→ (�,�)��� (�����)

�����

�(�, �)=sin (�� + ��)

�� + ��

Notice that, no matter how the values of x & y approach 0 & 0, the function value approaches 1.

Ex) find lim(�,�)→ (�,�)�����

�����

Page 108: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

108 For this function, it matters very much how the values for x & y approach 0 & 0. If y is fixed at 0 and x approaches 0, the limit is 1. If x is fixed at 0 and y approaches 0, the limit is -1. If x=y and they approach 0 together, the limit is 0. Clearly, the limit does not exist. For one variable functions, we need to take a two-sided limit. For more variables, we need an “every-sided” limit. In general, formally proving that a limit exists from any direction is hard.

Ex) �(�, �)=�����

������� is undefined at (0,1). Using the table below, find various limits for f(x,y) as (x,y)→(0,1)

Graphical limits As with one-variable limits, another way to investigate the limit is with the graph of the function.

Ex) find lim(�,�)→ (�,�)��� (�����)

�����

Based on the graph, it seems that any way to approach (x,y) = (0,0) causes the function to approach 1.

Ex) find lim (�,�)→ (�,�)�����

�����

Multiple views:

Page 109: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

109

The graph allows us to see that different approaches by (x,y) to (0,0) produce different function values, ranging anywhere from 1 to -1. It would help if we could identify a path along which all function values are 1 (or another constant). The representation which allows us to do that is the contour plot.

Now it is obvious how the path to (0,0) determines the limit. Next we see the contour plot of the earlier

function with a well-defined limit at (0,0), f(x,y) = ��� (�����)

�����

Note that every path to (0,0) crosses level curves while approaching 1.

Page 110: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

110 Algebraic limits

Ex) show the limit is not well-defined: lim(�,�)→ (�,�)�����

�����

if you approach (0,0) along the line x=y, this limit is: if you approach (0,0) along the line x=0, this limit is: In this problem, we knew to choose the paths x=y and x=0 using numerical and graphical information. To find a limit algebraically, there are two options. One, show it is not well-defined by choosing paths; or two, prove that a limit is well-defined for all paths. In general, knowing which to do and also doing it is very hard.

The limit definition of the derivative for a function of several variables

Previously, for a one-variable y=f(x), we defined the derivaitive using limits ��

��= lim�→ �

�(���)��(�)

Now we will form the limit definition for a derivative of f(x,y). Recall how we discovered partial derivatives. We held one variable constant while the other variable changed. Relative to a given point, for the partial

derivative ��

�� we would hold y constant and vary x to approach the given value. We use this idea to modify

the limit definition of the derivative from the one-variable case. ��

��= lim

�→ �

�(� + ℎ, �)− �(�, �)

��

��= lim

�→ �

�(�, � + ℎ)− �(�, �)

These can be rewritten using vector notation.

��

��= lim�→ �

��������

�������

���

Now let r = (x,y). Recall that i = (1,0), the unit vector in the x-direction. So the definition in vector notation is: ��

��= lim

�→ �

�(� + ℎ�)− �(�)

Geometrically, what does it mean to let h go to 0? From the point r = (x,y), move in the direction indicated by the unit vector i, but head in that direction a smaller and smaller magnitude.

Recall that ��

��= ��⃗� (since i is the unit vector in the x-direction). This leads to a way to define the directional

derivative with limits. If u=(r,s) is a unit vector, then:

��� = lim�→ �

�(� + ℎ�)− �(�)

Let’s rewrite this without vector notation, by reversing the steps we just followed.

��� = lim�→ �

���������

�������

���

So the limit definition of the directional derivative (without vector notation) is:

��� = lim�→ �

�(� + ℎ�, � + ℎ�)− �(�, �)

Note: if the direction vector is not a unit vector, then divide by its magnitude, as we have seen before. Note: although r & u are combined in the calculation, do not confuse their meaning. The coordinates of our location are represented by r, and the direction in which we find the derivative is represented by u. It may help to think of the location as a point and the direction as a vector.

Ex) For f(x,y) = ���

���� and ��⃗ = (0.6, 0.8), write down

��

�� and Duf at the point (a,b) as a limit

��

�� = Duf =

Page 111: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

111 The Limit Definition of the Integral for a function of several variables The basic form of the limit definition of the integral, if we make some simplifying assumptions, is: ∫∫R f(x,y) dA = limm,n→∞∑ ∑ ��

������� (xi, yj)ΔA

Notation: R is the region over which we integrate. Constants m (and n) are the number of subintervals for the interval of x (and y). xi is the x-value on the i-th subinterval, yj is the y-value on the j-th subinterval, and ΔA is the area of rectangle formed by Δx and Δy. Note that we have made some simplifications from the general case; we chose Δx and Δy to be constant (so ΔA is also constant); we chose xi and yj to be endpoints on the subinterval. In the general case: ∫∫R f(x,y) dA = ���‖∆�‖→ � ∑ ∑ ��

������� (xij

*, yij*)ΔAij

Aij is the rectangle formed by the i-th subinterval of x-values and the j-th subinterval of y-values and ΔAij is its area;‖∆�‖ is the maximum value of all ΔAij; xij

* (and yij*) is the x-value (and y-value) of the point chosen in Aij.

In general, calculating the limit directly (without converting it into an integral and using integration techniques) is very hard. Ex) write down ∫∫R x2 – tan(xy) dA as a limit

Page 112: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

112 Appendix

A proof of the Ratio Test

Page 113: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

113

A proof of the Taylor Remainder Theorem Theorem:

Proof:

Page 114: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

114

Here is a proof of the curvature formula in 3 dimensions:

Page 115: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

115

Here is a proof of the second derivative test for the minimum. (The proof for the maximum is similar.)

Page 116: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

116

For a parametric equation, ��

��=

�����

�����

Proof: Let x=f(t) and y=g(t)

Page 117: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

117

A proof of the equivalence of the parametric form and the normal vector form of the equation of a plane. (using Mathematica to do some calculations)

In particular, a proof that the two ways to derive the equation of the tangent plane at a point on z=f(x,y), using the slopes in the x- and y-directions, are the same:

Page 118: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

118

Discussion of the chain rule for a function of several variables, each of which is a function of several variables. Let F be a function of two variables, call them x & y, so F = F(x,y). Let x & y each be functions of two variables, call them t & u, so x=x(t,u) and y=y(t,u). the chain rule says:

��

��=��

��∙��

��+��

��∙��

��

��

��=��

��∙��

��+��

��∙��

��

The following diagram illustrates how to keep track of all the terms. The top row includes F, the function. The middle row includes x & y, called the intermediate variables. The

bottom row includes t & u, the independent variables. Note that a change in t causes a change in x ���

���, that

change in x causes a change in F ���

���, which contributes the term

��

��∙��

��. A change in F comes from changes

in both t & u, etc. Each path in the diagram (from independent to intermediate to function) represents a possible change. Note that every connection between independent and intermediate is possible, so there are

2·2=4 terms total (each is a product of two rates). There are 2 paths from F to t, so ��

�� has two terms.

For F(x,y,z), a function with 3 intermediate variables, which has 3 independent variables, the diagram and equations are below.

��

��=��

��∙��

��+��

��∙��

��+��

��∙��

��

Page 119: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

119

��

��=��

��∙��

��+��

��∙��

��+��

��∙��

��

��

��=��

��∙��

��+��

��∙��

��+��

��∙��

��

Alternate proofs of the conversion of integrals between rectangular and polar coordinates. Using differentials:

Using Riemann sums:

Page 120: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

120

Changing from one coordinate system to another From x = (x1,x2,x3) to y (y1,y2,y3) x1=f1(y1,y2,y3); x2=f2(y1,y2,y3); x3=f3(y1,y2,y3) dx1 = df1/dy1 dy1 + df1/df2 dy2 + df1/dy3 dy3 dx2 = df2/dy1 dy1 + df2/df2 dy2 + df2/dy3 dy3 dx3 = df3/dy1 dy1 + df3/df2 dy2 + df3/dy3 dy3 dV = dx1 dx2 dx3 = (df1/dy1 dy1 + df1/df2 dy2 + df1/dy3 dy3)(df2/dy1 dy1 + df2/df2 dy2 + df2/dy3 dy3)(df3/dy1 dy1 + df3/df2 dy2 + df3/dy3 dy3) We need two facts to properly write down dV. First, when expanding the product, note that terms whose differential is not dy1 dy2 dy3, but has repeats such as dy1 dy1 dy2, are not 3-dimensional and do not contribute to the volume. Second, we can commute differentials, but that changes the sign (e.g. dy1 dy2 = -dy2 dy1). (You may wonder why we can switch the order of integration with no sign change. That is because changing the order of the boundries also changes the sign, so these two changes cancel.) The justifications for these facts are beyond the scope of this course. dV = (df1/dy1 dy1)(df2/df2 dy2)(df3/dy3 dy3) + (df1/dy1 dy1)(df2/dy3 dy3)(df3/df2 dy2) + (df1/df2 dy2)(df2/dy1 dy1) (df3/dy3 dy3) + (df1/df2 dy2)(df2/dy3 dy3)(df3/dy1 dy1) + (df1/dy3 dy3)(df2/dy1 dy1)(df3/df2 dy2) + (df1/dy3 dy3) (df2/df2 dy2)(df3/dy1 dy1) = ( (df1/dy1)(df2/df2)(df3/dy3) - (df1/dy1)(df2/dy3)(df3/df2) - (df1/df2)(df2/dy1)(df3/dy3) + (df1/df2)(df2/dy3)(df3/dy1) + (df1/dy3)(df2/dy1)(df3/df2) + (df1/dy3) (df2/df2)(df3/dy1) ) dy1 dy2 dy3 If you are familiar with linear algebra, these formulas and calculations can be expressed using matrices. The matrix of partial derivatives of the change of coordinate functions is (…) and it is called the Jacobian J. The scalar in front of the new differentials is the determinant of the Jacobian, |J|. Ex) from rectangular to polar in 2D x = r cos t; y = r sin t dx/dr = cos t; dx/dt = -rsin t; dy/dr = sin t; dy/dt = rcos t

Page 121: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

121 J = [cos t, -rsin t; sin t, rcos t] |J| = (cost)(r cost) – (-rsint)(sint) = rcos2t + rsin2t = r So dxdy = rdrdt Ex) from rectangular to spherical in 3D: x = r sint cosp; y = r sint sinp; z = r cost J = [sint cosp, r cost cosp, -r sint sinp Sint sinp, r cost sinp, r sint cosp Cost, -rsint 0] |J| = r2sint So dx dy dz = r2sint dr dt dp We can consider the coordinate transformation in the opposite direction and ask what the Jacobian and its determinant will be. Let Jx,y be the Jacobian for the transformation from x coordinates to y coordinates. Then Jy,x = (Jx,y)

-1 and det(Jy,x) = 1/det(Jx,y) Ex) from polar to rectangular in 2D Recall that Jr,p = [cos t, -rsin t; sin t, rcos t] and |Jr,p| = r Jp,r = [ x/sqrt(x2+y2), y/ sqrt(x2+y2); -y/(x2+y2) , x/(x2+y2) ] After substitution: Jp,r = [ rcost/r, rsint/r; -rsint/r2, rcost/r2] = [ cost, sint; -sint/r, cost/r ] | Jp,r| = (cost)(cost/r) – (sint)(-sint/r) = 1/r Proof that: path independent ⇒ conservative

Page 122: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

122

A similar argument, using a line segment for C2 for which y varies and x is constant, shows that:

Page 123: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

123 Proof of Greens Theorem for a region S which is a rectangle, a ≤ x ≤ b & c ≤ y ≤ d For the curve C which is the boundary of S, consider the pieces Bottom, Top, Left, Right so C = B+R+T+L (all with the appropriate orientation) ∫C P dx + Q dy = ∫B P dx + ∫R P dx + ∫T P dx + ∫L P dx + ∫B Q dy + ∫R Q dy + ∫T Q dy + ∫L Q dy = ∫B P dx + ∫T P dx + ∫R Q dy + ∫L Q dy = ∫a

b P(x,c)dx + ∫ba P(x,d)dx + ∫c

d Q(b,y)dy + ∫dc Q(a,y)dy

= ∫ab P(x,c)dx - ∫a

b P(x,d)dx + ∫cd Q(b,y)dy - ∫c

d Q(a,y)dy = ∫a

b P(x,c) - P(x,d) dx + ∫cd Q(b,y) - Q(a,y) dy

= ∫ab [∫d

c Py(x,y)dy ] dx + ∫cd [∫a

b Qx(x,y) dx] dy = ∫a

b [∫cd -Py(x,y)dy ] dx + ∫c

d [∫ab Qx(x,y) dx] dy

= ∫ab ∫c

d Qx - Py dy dx = ∫∫S Qx - Py dA

To understand why the expression is ��

��−

��

�� , consider ∫C P dx and ∫C Q dy separately, and assume the region

is a rectangle with a ≤ x ≤ b & c ≤ y ≤ d. For ∫C Q dy, on the horizontal edges B&T, dy=0 so the integral is 0. On the right edge R where x=b, the line integral goes from y=c to y=d, making a positive contribution. On the left edge L where x=a, the line integral goes from y=d to y=c, and switching the boundary values means the integral makes a negative contribution. The “plugged-in endpoints” are x=a & x=b, so this comes from

integrating ��

�� from x=a to x=b. For ∫C P dx, the argument is similar, with one extra step. On B where y=c, the

path orientation goes from x=a to x=b, so that will make a positive contribution, and on T where y=d, the path orientation goes from x=b to x=a, so when we switch the boundaries of integration it makes a negative

contribution. Thus, it is the equivalent of integrating ��

�� from y=d to y=c. Then, since we want the integral for

y from c to d, we need to switch those boundary values, so we must change the sign. Proof of FTC using discrete approximation and canceling

Proof of Greens Theorem using discrete approximation and canceling

Page 124: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

124

Now,

Page 125: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

125

Physics, center of mass (alternate intro) Previously we saw that a 1-dimensional object on an interval [a,b] with a density r(x) [measured in kg/m] had total mass [measured in kg] of m = ∫a

b r(x) dx. Now, a 2-dimensional object covering a region R with density r(x,y) [measured in kg/m2] has a total mass of: ∫∫R r(x,y) dA

Page 126: 1 CALCULUS 3 DR JASON SAMUELS COURSE NOTESsocrates.bmcc.cuny.edu/.../303lecturenotes-2016s.pdf · . “a” is the first term and “r” is the ratio. Given one term, you multiply

126 Scalar line integral in coordinate form (alternate intro) So far we only looked at a specific type of line integral, integrals which can be written with respect to ds. Since these parametric curves live in the xy-plane, a line integral could involve integrating with respect to x (with dx) or with respect to y (with dy). The coordinate form for a line integral is ∫C P dx + Q dy To calculate it,

we can make the conversion to using t as the variable: x=x(t), dx = ��

���� or y=y(t), dy =

��

����.