<<

Math 32B Discussion Session Week 5 Notes February 7 and 9, 2017

We’ve changed gears this week. So far this quarter we’ve focused on integrating functions over two- and three-dimensional regions. The rest of the course will focus on the of vector fields. (By the end of the quarter, you may find yourself doing just for fun.) We’ll start this week by introducing two on vector fields. Because of the strange timing this week, we’ll also try to discuss line .

Divergence The first characteristic of a vector field we’d like to measure is the degree to which it is ex- panding or contracting at a given point. For example, consider the following vector fields on R2: It’s pretty clear to see that the vector field in (1a) is expanding at the origin and that the

(a) Outward flow. (b) Inward flow.

(c) Cross flow. (d) Confused flow. vector field in (1b) is contracting at the origin (in fact they’re expanding and contracting, respectively, everywhere). We make this idea of expanding or contracting ever-so-slightly more accessible with the orange circle. In (1a) we see the vector field pushing out of the

1 circle, and we consider this vector field to have positive . The vector field in (1b), on the other hand, is pushing into our circle, and we consider this vector field to have negative divergence.

The vector fields in (1c) and (1d) are a little different. In (1c), the vector field is flowing smoothly, neither expanding nor contracting. In particular, the vector field is pushing matter into our region in the third quadrant and at the same time pushing matter out of our region in the first quadrant at the same rate. The net change is zero, so we consider this vector field to have zero divergence. The vector field in (1d) also has zero divergence, but it’s less obvious. In this case, our vector field is pushing matter into the circle along the y-axis and out of the circle along the x-axis, and the net change is zero.

We would like to define an on vector fields, called the divergence operator, which measures the extent to which a vector field is pushing matter into or out of a particular 2 point. To define this operation, let’s consider a point (x0, y0) ∈ R and make this point the center of a box of width ∆x and height ∆y, as in Figure2. If we call our vector field F, Figure 1 1 1 1 2 shows the vectors F(x0 − 2 ∆x, y0), F(x0, y0 + 2 ∆y), F(x0 + 2 ∆x, y0), and F(x0, y0 − 2 ∆y). We want to measure the rate at which F is pushing matter out of this box. Along the right side of the box, we care about the extent to which F is pushing to the right, since this points 1 out of the box. So at (x0 + 2 ∆x, y0), we care about the value 1 F (x + ∆x, y ). 1 0 2 0 For a small box, we can assume that F is pushing out with this same along the entire right side of the box, so that the total flow out of the right side of the box is given by 1 F (x + ∆x, y )∆y. 1 0 2 0 Similarly, we approximate the flow out of the box through the top edge by 1 F (x , y + ∆y)∆x. 2 0 0 2 Along the left side of the box, we care about the extent to which F is pushing to the left. This is given by the negative of the x-component of F, or −F1. So we approximate the flow out of the left side of the box by 1 −F (x − ∆x, y )∆y, 1 0 2 0 and the flow out of the bottom of the box is approximately 1 −F (x , y − ∆y)∆x. 2 0 0 2

2 Figure 2: Some vectors near (x0, y0).

Altogether, the total flow out of the box is approximately 1 1 1 1 out ≈ (F (x + ∆x, y )−F (x − ∆x, y ))∆y+(F (x , y + ∆y)−F (x , y − ∆y))∆x. 1 0 2 0 1 0 2 0 2 0 0 2 2 0 0 2 Finally, we divide by the area of the box to obtain

flow out F (x + 1 ∆x, y ) − F (x − 1 ∆x, y ) F (x , y + 1 ∆y) − F (x , y − 1 ∆y) ≈ 1 0 2 0 1 0 2 0 + 2 0 0 2 2 0 0 2 . ∆x∆y ∆x ∆y

∂F1 ∂F2 As ∆x and ∆y tend towards zero, we see that this quantity tends towards ∂x + ∂y , and it’s with this in mind that we make the following definition.

Definition. Let F(x, y) be a vector field on R2. We define the divergence of F to be the scalar-valued ∂F ∂F div(F) := 1 + 2 , ∂x ∂y

where F1 and F2 are the component functions of F. Similarly, if F(x, y, z) is a vector field in R3, we define the divergence by

∂F ∂F ∂F div(F) := 1 + 2 + 3 . ∂x ∂y ∂z

A succinct way to write our definition is as a :

div(F) = ∇ · F,

where ∇ is the “vector”  ∂ ∂ ∂  ∇ = , , . ∂x ∂y ∂z

Example. Compute the divergence of the vector field on R3 given by

F(x, y, z) := hxy, yz, y2 − x3i.

3 (Solution) We have ∂F ∂F ∂F div(F) = 1 + 2 + 3 ∂x ∂y ∂z ∂ ∂ ∂ = (xy) + (yz) + (y2 − x3) ∂x ∂y ∂z = y + z + 0 = y + z.

Curl The divergence of a vector field gives us a measure of the degree to which the vector field is expanding or contracting at a point, but it surely doesn’t tell us everything about the vector field’s behavior. For example, the vector fields in (1c) and (1d) both have zero divergence, but one behaves much more interestingly near the origin than does the other. One signif- icant difference is that the vector field in (1d) spins or curls matter near the origin. We now introduce another operation on vector fields, called the , which aims to measure this.

In Figure3, we have the same vector field we had in Figure2, but now we care about the 1 extent to which this vector field is spinning. Now when we look at the point (x0 + 2 ∆x, y0) we don’t care how much the vector field is pusing to the right, but instead care how much the field is pushing up. That is, we care about the component 1 F (x + ∆x, y ). 2 0 2 0 Again we assume that this value is approximately the same along the entire right side and thus conclude that the contribution to our curl along the right side is 1 F (x + ∆x, y )∆y. 2 0 2 0 We approximate the contribution to the curl along the other sides in a similar manner, copying our from the divergence, and conclude that the total curl about (x0, y0) along the boundary of our box is approximately 1 1 1 1 total curl ≈ (F (x + ∆x, y )−F (x − ∆x, y ))∆y+(−F (x , y + ∆y)+F (x , y − ∆y))∆x. 2 0 2 0 2 0 2 0 1 0 0 2 1 0 0 2 Dividing by the area of the box yields total curl F (x + 1 ∆x, y ) − F (x − 1 ∆x, y ) F (x , y + 1 ∆y) − F (x , y − 1 ∆y) ≈ 2 0 2 0 2 0 2 0 − 1 0 0 2 1 0 0 2 . ∆x∆y ∆x ∆y As ∆x and ∆y tend towards zero, this value will approach ∂F ∂F 2 (x , y ) − 1 (x , y ). ∂x 0 0 ∂y 0 0

4 Figure 3: The same vectors near (x0, y0).

This gives the extent to which our vector field is spinning in the xy-plane. In general we care about vector fields on R3, which may have some sort of spin in each of the three standard coordinate planes. Our definition of curl makes each of these spin values the component of a vector.

Definition. Let F(x, y, z) be a vector field on R3. We define the curl of F by

∂F ∂F ∂F ∂F ∂F ∂F  curl(F) := 3 − 2 , 1 − 3 , 2 − 1 . ∂y ∂z ∂z ∂x ∂x ∂y

In practice we frequently use the more succinct notation given by

i j k ∂ ∂ ∂ curl(F) = ∇ × F = . ∂x ∂y ∂z F1 F2 F3

Notice that while divergence gave us a scalar measure of the vector field, curl gives us another vector field. This new vector field can be thought of as measuring both the magnitude and direction of the rotation in our original vector field. At a point (x, y, z), curl(F)(x, y, z) is a vector whose magnitude measures how much F is rotating at (x, y, z), and this vector is orthogonal to the plane in which the rotation is occurring.

Example. Let F be the vector field from the previous example and compute curl(F).

(Solution) We have F(x, y, z) = hxy, yz, y2 − x3i, so  ∂ ∂ ∂ ∂ ∂ ∂  curl(F) = (y2 − x3) − (yz), (xy) − (y2 − x3), (yz) − (xy) ∂y ∂z ∂z ∂x ∂x ∂y = 2y − y, 0 − (−3x2), 0 − x = y, 3x2, −x .

Note that while our vector field does depend on z, its curl does not. ♦

5 One interesting thing to note about the vector field that curl gives is that it has zero divergence — it is neither contracting nor expanding at any point. We can prove this by checking it on an arbitrary vector field F, but notice that our nice notation for div and curl makes this look obvious. In our notation, the divergence of the curl vector field is given by the triple scalar product div(curl(F)) = ∇ · (∇ × F). We know that when a vector makes two appearances in a triple scalar product, the product is zero. In this case, the “vector” that appears twice, ∇, is actually an operator, so we need to carefully check that this product does indeed vanish.

We can also check that any vector field has no curl. In symbols that is ∇×∇f = 0. So we have a sequence of operators

gradient divergence functions −−−−→ vector fields −−→curl vector fields −−−−−−→ functions

with the property that applying consecutive operators gives zero1.

Conservative Vector Fields Finally, we consider ∇ as an operator not on vector fields, but on functions. Given a function f(x, y, z), the gradient vector field, which you already encountered in 32A, of f is the vector field given by ∂f ∂f ∂f  F = ∇f = , , . ∂x ∂y ∂z We label the relationship between f and F by calling F a conservative vector field and saying that f is a potential function for F when ∇f = F. Not all vector fields are conservative (in fact, most aren’t), but those which are tend to have some very nice properties. One particular property is given below.

Theorem 1. If the vector field F(x, y, z) on R3 is conservative, then curl(F) = 0.

We’ll see that the converse of this statement is not true in general: on R3 minus the z-axis, there are vector fields F such that curl(F) = 0, but which are not conservative.

Example. For the vector field

F = yz2, xz2, 2xyz

either find a potential function f(x, y, z) or show that no such function exists. 1The word consecutive is important here: the divergence of the gradient of a function gives an incredibly important (and not generally zero) function known as the Laplacian of the function.

6 (Solution) If we want to show that no potential function exists for F, we need to show that F is not conservative. At present, the only way we can do this is to show that curl(F) is nonzero. But curl(F) = h2xz − 2xz, 2yz − 2yz, z2 − z2i = h0, 0, 0i, so this approach won’t work. (At this point we can’t conclude that F is conservative from the fact that curl(F) = 0.) Perhaps F does admit a potential function. If so, f is a function so that ∂f ∂f ∂f = yz2, = xz2, = 2xyz. ∂x ∂y ∂z From the first equation we see that

f(x, y, z) = xyz2 + g(y, z),

where g is some function of y and z, independent of x. Then from the second equality, ∂f ∂g xz2 = = xz2 + , ∂y ∂y so ∂g/∂y = 0, meaning that g does not depend on y. Finally,

∂f ∂g 2xyz = = 2xyz + , ∂z ∂z meaning that ∂g/∂z = 0, and thus that g does not depend on z either. So g is constant, and we may write f(x, y, z) = xyz2 + K.

A quick check confirms that ∇f = F. ♦

Line Integrals

We’re now ready to define a new type of . For the first time, we’ll be integrating along something other than Euclidean Rn, and we’ll also integrate objects other than scalar functions. We’ll introduce the of a scalar function or vector field and explore some of its applications.

Scalar Line Integrals Suppose C is an oriented in R3, meaning that we’ve determined travel along this curve in one direction to be positive, and the opposite direction to be negative. Given a f(x, y, z), we would like to define the integral of f along C in the usual way that we define integrals: chop up our domain (in this case C) into small subdomains and for each of these subdomains approximate f by some fixed scalar. Then multiply this scalar by the measure of the subdomain (in this case, the length of the interval in C) and add up the

7 resulting products. We this process as usual to obtain an integral.

Rather than work through the details of this definition of the integral, we’ll be guided by intuition. The primary difference between each of the integrals we’ve defined so far has been this “measure of the subdomain” quantity. When we defined double integrals, we concerned ourselves a great deal with dA, and we found that this quantity depends on the chosen for R2. We had a similar excursion with dV when we considered triple integrals. Now we want a length element for a curve. But we know how to find the length of a curve! Given a regular parametrization r(t) of the curve C on an interval [a, b], the of the portion of C traced out between a and t is given by

Z t s(t) = kr0(u)kdu. a The arc length differential is then given by

ds d Z t  ds = dt = kr0(u)kdu dt = kr0(t)kdt, dt dt a where the last equality comes from the fundamental theorem of calculus. In light of this calculation, the following theorem seems very natural:

Theorem 2. Given a curve C ⊂ R3 and a continuous function f(x, y, z),

Z Z b f(x, y, z)ds = f(r(t))kr0(t)kdt C a

where r(t) is a parametrization of C on [a, b] so that r0(t) is continuous. R Example. (Section 17.2, Exercise 10) Compute C f(x, y)ds, where y3 f(x, y) = x7

1 4 and C is the curve traced out by y = 4 x for 1 ≤ x ≤ 2. (Solution) To use our theorem we need a parametrization of C; thankfully the description of C gives us a very natural parametrization: 1 r(t) := ( t4, t) for t ∈ [1, 2]. 4 Then r0(t) = (t3, 1) and we have

Z Z 2 Z 2 1 f(x, y)ds = f(r(t))kr0(t)kdt = f( t4, t)k(t3, 1)kdt C 1 1 4

8 Z 2 ( 1 t4)3 √ Z 2 √ 4 6 1 5 6 = 7 t + 1dt = t t + 1dt. 1 t 64 1 We can now make the substitution u = t6 + 1. Then du = 6t5dt and when t = 1, u = 2, while when t = 2, u = 65. So we have

Z 1 Z 2 √ 1 Z 65 √ f(x, y)ds = t6 + 1 · 6t5dt = udu C 384 1 384 2 1 2 65 2 = u3/2 = 653/2 − 23/2 . 384 3 2 1152

Scalar integrals have a variety of applications, including computing the mass of a wire with varying density or calculating electric potential, but for the most part we’ll focus our attention on vector line integrals, discussed next.

Vector Line Integrals Suppose we have a bead on a wire, and this wire lives in some ambient space on which a vector field is defined. For instance, the wire might be in a stream of flowing water. In Figure4, our wire is red and the bead is represented by the green dot on this wire.

Figure 4: A bead on a wire.

Figure4 can be thought of as an initial state for the bead. The vector field will act on the bead, pushing it along the wire. But how much will the vector field push the bead along the wire? This will depend on where the bead is. For example, when the bead is at the point indicated by the dashed green lines (roughly (1.3,1.1)), the vector field seems to be almost

9 perpendicular to the wire, so the flow of the vector field won’t push the bead along the wire at all. At the green dot, on the other hand, the vector field is very nearly to the wire, and the flow of the vector field will push the bead along the wire.

We saw in 32A that an oriented curve admits a unit tangent vector at every point. Our intuition seems to indicate that when the vector field points in the same direction as this tangent vector, the bead will be moved in the positive direction, when the vector field points against the unit tangent vector, the movement is in the negative direction, and when the vector field is perpendicular to the curve, there is no movement at all. This is reminiscent of the dot product, which is positive when two vectors point in the same direction, negative when the point in opposite directions, and zero when they’re orthogonal. It’s unsurprising, then, that effect of F on the bead at (x, y) ≈ F(x, y) · T(x, y), for every point (x, y) on our curve. It stands to reason that integrating this dot product will give the net effect of F on the bead along the entire curve, as the following definition indicates.

Definition. Let r(t) be a regular parametrization of the oriented curve C ⊂ R3 which is positively oriented. The line integral of a vector field F along C is given by Z Z F · dr := (F · T)ds, C C

where T is the unit tangent vector to C with positive orientation.

The dr in the above expression is purely symbolic; its main purpose is to remind us that C is oriented, and that we must respect this orientation when determining T. It’s also important to note that the integral on the right is a scalar line integral, which we defined above. Now if we have a parametrization r(t) on the interval [a, b] which is positively oriented, we saw above that ds = kr0(t)kdt. We also recall from 32A that r0(t) T(t) = . kr0(t)k Then the quanity on the right in our above definition can be rewritten as

 r0(t)  (F · T)ds = F(r(t)) · kr0(t)kdt = F(r(t)) · r0(t)dt. kr0(t)k

This is still a dot product of two vectors (and thus still a scalar quantity), but we have now made this a single-variable scalar function, making our integral much more tractable. We summarize this work with the following theorem.

10 Theorem 3. If r(t) is a regular parametrization of the oriented curve C on [a, b], then

Z Z b F · dr = F(r(t)) · r0(t)dt. C a

Example. (Section 17.2, Exercise 20) Let F(x, y) = h4, yi, and let C be the quarter circle given by x2 + y2 = 1, where x ≤ 0 and y ≤ 0, with counterclockwise orientation, as in Figure R 5. Compute C F · dr.

Figure 5: The vector field F(x, y) = h4, yi with the curve C.

(Solution) First we need a parametrization of C. One parametrization we can use is

r(t) = (cos(t), sin(t)),

where t ∈ [π, 3π/2]. Then for each t we have

F(r(t)) = F(cos(t), sin(t)) = h4, sin(t)i.

We also see that r0(t) = h− sin(t), cos(t)i, so F(r(t)) · r0(t) = −4 sin(t) + sin(t) cos(t) = sin(t)(cos(t) − 4). We then have Z Z 3π/2 F · dr = sin(t)(cos(t) − 4)dt. C π Let’s make the substitution u = cos(t)−4, so that du = − sin(t)dt and our bounds transform from t = π and t = 3π/2 into u = −5 and −4. Then

Z Z −4 u2 −4 16 25 9 F · dr = − udu = − = − − = . C −5 2 −5 2 2 2

11 Before moving on to some applications of line integrals, we should point out some prop- erties of our new machinery. Line integrals have the nice linearity property that all integrals enjoy. Additionally, they behave predictably when we reverse the orientation of our curve: Z Z F · dr = − F · dr −C C or when we concatenate : Z Z Z F · dr = F · dr + F · dr. C1+C2 C1 C2

Applications In introducing vector line integrals, we started with a vector field moving a bead along a wire. This setup — where a vector field has some effect on particles along a curve — is very common in applications, and we call the net effect of the vector field along the curve the work done by the vector field.

Definition. We define the work done by a vector field F along an oriented curve C ⊂ R3 to be Z W := F · dr. C

For a curve in the plane R2 we can also use line integrals to measure the flux of a vector field along this curve. We could imagine that the curve in Figure4 were not a wire but were instead some permeable membrane through which liquid might pass. In this case, we’d like to measure the amount of liquid passing through the membrance. Now the vector field will have largest contribution when it is perpendicular to the curve and smallest contribution when it is tangent, opposite the relationship from before. By letting n be the unit vector to our curve in the positive direction (whatever direction we’ve chosen to be positive), we see that the contribution of F to our flux at a point (x, y) along the curve is represented by F(x, y) · n(x, y). Notice that this dot product is zero when F is tangent to our curve (and thus not contributing to the flow of liquid through our curve). The total flux through our membrane is then obtained by integrating this quantity, as in the definition below.

Definition. We define the flux of a vector field F across an oriented curve C ⊂ R2 to be

Z Z b := (F · n)ds = F(r(t)) · N(t)dt. C a

12 Figure 6: The vector field F(x, y) = hx2, y2i with the curve C.

In the latter integral, r(t) is a regular parametrization of C on [a, b] which is positively oriented, and N(t) is the outward-pointing normal vector2 to r(t): N(t) := hy0(t), −x0(t)i = n(t)kr0(t)k. As usual, n(t) is the unit-length outward-pointing normal vector. Example. (Section 17.2, Exercise 65) Let F(x, y) = hx2, y2i and let C be the line segment between (3, 0) and (0, 3), oriented upward, as in Figure6. Calculate the flux of F across C.

(Solution) First we need a parametrization for C. We have one given by r(t) = (3 − 3t, 3t) for t ∈ [0, 1]. Notice that r(t) varies from (3, 0) to (0, 3), as desired. Then our outward- pointing normal vector is given by N(t) = h3, −(−3)i = h3, 3i and we also have F(r(t)) = F(3 − 3t, 3t) = h(3 − 3t)2, (3t)2i. So F(r(t)) · N(t) = 3(3 − 3t)2 + 3(3t)2 = 27(1 − 2t + 2t2). Finally, Z 1  2 1  2 Flux = 27 (1 − 2t + 2t2)dt = 27 t − t2 + t2 = 27 1 − 1 + = 18. 0 3 0 3 ♦

2Because we’re often interested in the flow out of a region, we typically call the positive direction outward- pointing.

13