You are on page 1of 166

Chapter 1 Vectors

(Reference: SHE, Chapter 12, FYA Chapter 5) We begin with a little revision of rst year vectors algebra and geometry.

1.1

Norms and Dot products

The basic point of a vector is something that has both size and direction: a scalar on the other hand, just has size. In order to keep track of what is a vector and what a scalar, we use a standard convention: Notation: A vector is always typed in bold, like x, or bold and underlined, x. When writing a vector, get into the habit of underlining it x, or putting an arrow over AB. it, In this course we will be looking at 2 or 3 dimensional real vectors, members of the vector spaces R2 or R3 . Such a vector ought to always be written as a column: x1 x1 x= or x = x2 . x2 x3 Convention: I will always use the convention that a general vector called, say, x will have components called x1 , x2 , . . . etc (or x1 , x2 . . . , the index position will not matter in this course). If I want x to have dierent components I will always say what they are. Denition 1.1 The scalar or dot product of two vectors a, b Rn is given by a b = a1 b1 + + an bn . Denition 1.2 The length or norm of a vector a Rn is given by a = a a = a2 + a2 + . . . + a2 . 1 2 n 1

math2011, 2010

We sometimes use a single line for the norm, |a|, which is of course the same symbol as the absolute value used for scalars. If you are careful to underline vectors, this shouldnt cause confusion. Denition 1.3 A unit vector is any vector of length 1. Given any vector a a unit vector in the same direction as a is write as a. a , which we often a

Denition 1.4 For two non-zero vectors a, b Rn the angle between them is given by ab cos = . a b Ive called this a denition, but in the case of R2 it is of course a theorem (or part of the denition of the dot product), see FYA chapter 5. Denition 1.5 Two non-zero vectors a, b Rn are orthogonal if a b = 0, or equiva lently the angle between them is /2. Denition 1.6 The standard basis of R3 consists of the vectors 1 0 0 i = 0 , j = 1 , and k = 0 0 0 1

which point along the coordinate axes.

These vectors are unit vectors and pairwise orthogonal they are an orthonormal basis of R3 . Example 1.1 Let A, B and C be the points with coordinates (1,2,3), (2,0,1) and (3, 3, 2) respectively. a) Find the vectors OA, AB, AC and BC. b) Find the distance of A from the origin. c) Find a unit vector in the direction of AB. d) Show that AB, AC and BC are linearly dependent. e) Find the angle between AB and AC. f) Find the component of AB in the direction of AC, and the component of AB per pendicular to AC.

Chapter 1

1.2

Cross and Triple Products

The cross (and triple) products are only dened for R3 . They do not work in any other dimensions. Denition 1.7 The cross product (or vector product) of two vectors a, b R3 is given by a2 b3 a3 b2 b1 a1 i j k i.e. a b = a1 a2 a3 ; a2 b2 = a3 b1 a1 b3 . a1 b2 a2 b1 b3 a3 b1 b2 b3 The magnitude of the cross product is given by ab = a where is the angle between the two vectors. b | sin |

Proposition 1.1 (Properties of the cross product) Let a, b R3 . Then a) a b = 0 if and only if a and b are parallel. b) a b is orthogonal to both a and b. c) a b = b a d) a b is the area of the parallelogram with sides a and b. For proofs see SHE or FYA. The cross product a b is a vector, so if we had a third vector, c, we could take either the dot or cross product of c with a b Denition 1.8 The scalar triple product of three vectors a, b, c R3 is a1 a2 a3 [a, b, c] = (a b) c = a (b c) = b1 b2 b3 c1 c2 c3 The absolute value of the scalar triple product [a, b, c] is the volume of the paral [ lelepiped with a, b and c as edges (FYA). It follows that a, b, c] = 0 if and only if a, b and c are coplanar. Denition 1.9 The vector triple product of three vectors a, b, c R3 is (a b) c. The scalar triple product of three vectors is a scalar and the vector triple product is a vector. Both triple products are alternating, that is if you swap any two vectors and you change the sign.

math2011, 2010

Proposition 1.2 For a, b, c R3 , (a b) c = (a c)b (b c)a. The most straighforward way to prove this is just to write out both sides, but it is rather tedious. Example 1.2 Let A, B and C be the points with coordinates (1, 0, 1), (2, 1, 3) and (0, 1, 2) respectively. Find b) The volume of the parallelepiped with sides OA, OB and OC. Example 1.3 Prove that a (b c) = (c a)b (b a)c. We have a (b c) = (b c) a = (b a)c + (c a)b by changing the symbols. Note howdierentthis is to the original! a) The area of the triangle OAB.

1.3

Lines

We shall now recall how to obtain equations for lines in R2 and R3 . The commonest problem you will face here is to parameterise a line between two points. Recall that parameterising is a way of labelling the points on the line by giving the two (or three) coordinates of all the points on the line in terms of functions of one variable only. Suppose we have two points A and B with position vectors a and b. Then the line through A and B has parametric vector equation x(t) = a + t(b a), y B A b < t < (1.1)

See gure 1.1.

x Figure 1.1: Line through two points What this means is that as the parameter t varies from to , the point with position vector x(t) traces out the line through A and B. If our coordinates are x, y and z, then we have three parametric equations the x = a1 + t(b1 a1 ), y = a2 + t(b2 a2 ), z = a3 + t(b3 a3 ).

Chapter 1

We see that the three coordinates are functions of the one variable (t). If we only want the line segment from A to B, then we cut down the range of the parameter: the line segment from A to B has parametric vector equation x(t) = a + t(b a), 0 < t < 1. (1.2) So as t varies from 0 to 1, the points with position vector x(t) go along the line starting at A and ending at B. Example 1.4 Let A and B be the points with coordinates (1,2,3) and (2,0,1) respectively. a) Find a parametric vector equation for the line through A and B. b) Find a parametric vector equation for the straight line path from A to B. c) Find points on the line AB that are 5 units from A. Example 1.5 Do the following two lines intersect? 0 1 2 1 r(t) = 8 + t 3 , s(t) = 8 + t 1 . 3 1 7 3

If they do, nd the point(s) of intersection and the angle at which they intersect.

1.4

Planes

Lines are one dimensional objects: we parameterise them with one parameter. Planes are two dimensional: we need two paramaters. A typical problem in parameterising planes is to nd the plane through three points A, B and C that are not collinear. A parametric vector equation of this plane is given by x(, ) = a + (b a) + (c a), , R. See gure 1.2. There are other options: you can swap b and a for example. If we restrict the parameters to [0, 1], then this gives us a parameterisation of the parallelogram with corners at A, B, C and the point D with position vector b + c a. From the parametric equation of the plane we get the Cartesian equation usingthe cross product. Suppose the plane is x(, ) = a + b + c. Then the vector n = b c is normal to the plane. The point-normal form the plane is then of n (x a) = 0 (1.3) where x is the general point on the plane. Multiplying equation (1.3) out will give the Cartesian equation.

6 D B

math2011, 2010

ba C A Figure 1.2: Plane through 3 points ca

Example 1.6 Let A, B and C be the points with coordinates (1,2,3), (2,0,1) and (3, 3, 2) respectively. For the plane through A, B and C: a) give a parametric equation; b) nd a normal direction; c) nd the Cartesian equation. Now parameterise the triangle ABC. Example 1.7 Let be the plane with Cartesian equation 2x 3y + z = 2. Find a parametric equation for and a normal to . Note that although there are innitely many dierent parametric and point-normal equations for a plane, there is really only one Cartesian equation: any others you might write down are multiples of any particular one.

Chapter 2 Curves
2.1 Vector valued functions

In general, a function is a rule that assigns to each element in the domain an element in the codomain. Denition 2.1 A vector valued function or vector function, is simply a function f : A B whose codomain, B, is a set of vectors. We have already seen example of these the parametric vector form of a line or a plane are really vector valued functions. This course is all about vector functions of real variables, and typically the domain and codomain are subsets of R, R2 or R3 . The mathematics generalises of course, but by the time youve mastered functions from or into R2 , youve done the hard part: higher dimensions just involves more notation (and unfortunately few pictures). A typical vector function, say f : R2 R2 can be written as f(u, v) = f1 (u, v) f2 (u, v) = f1 (u, v) i + f2 (u, v) j.

We call the (real valued) functions f1 and f2 the component functions of f.

2.2

Basic denitions for curves

Intuitively, we think of a curve as a one dimensional conguration, like the path of a moving particle, or as something obtained by bending and twisting a straight line. Just like a line, we parameterise a curve using one parameter. Denition 2.2 A curve in Rn is a vector valued function of one variable, c : I Rn , where I is some (possibly innite) interval in R. 1

math2011, 2010

We often think of the range of this function as the curve, although this is not strictly correct. When parameterising a curve it is not enough to just give the formulas: we need to know the domain too. Denition 2.3 For a curve c : I Rn the range c(I) is called the trace of c. Ill often give future denitions for plane curves (curves in R2 ) for convenience, but everything I say and dene will work in all other dimensions with simple modications. Example 2.1 Draw the trace of the plane curve r : I R2 dened by 2 r(t) = (2t , 1 + t), t [1, 2]. The trace of r is a set of points in the plane (x, y) : x = 2t2 , y = 1 + t, 1 t 2 which is a parabola, see gure 2.1. y t=1 t=0 t = 1 Figure 2.1: trace of a curve x t=2

If f is a function of x with domain [a, b], then the graph of f is the set of points {(x, y) : y = f (x); x [a, b]}. This is also the trace of a plane curve, which we can dene as r : [a, b] R2 given by r(x) = (x, f (x)), a x b, using x as a parameter. Note that although all graphs give you curves, there are curves that are not graphs. The example in gure 2.1 is one such. You need a unique y value for each x value before you can call (the trace of) a curve a graph. Example 2.2 Sketch the curve in R2 given by C : [0, 2] R2 dened by C(t) = 2 cos t i + sin t j and describe its trace.

Chapter 2 Example 2.3 Sketch the curve in R3 given by r : [, 3] R3 dened by r(t) = cos t i + sin t j + t k and describe its trace.

Most of the curves we will see and use in this course will be lines or circles. We expect you to be able to parameterise lines, line segments, circles and arcs of circles. We looked at line and line segments earlier. For parameterising circles and arc of circles we usually use trig functions. In general, if a circle has centre c and radius R, then it can be parameterised as r(t) = c1 + R cos t c2 + R sin t = c + R cos t i + R sin t j, 0 t 2.

(Sometimes it is more convenient to use t this gives the same trace, but is technically a dierent curve.) For arcs of circles, you merely restrict the range. Example 2.4 Sketch and parameterise the semi-circle in the upper half plane with ends at (3, 0) and (1, 0).

2.3

Properties of curves

Denition 2.4 Let r : [a, b] R2 be a curve dened by r(t) = x(t), y(t) . If both component functions, x and y, are continuous functions from [a, b] to R then we call r continuous. All the examples weve see so far are continuous. Denition 2.5 Let r : [a, b] R2 be a curve. The points r(a) and r(b) are called the end points of r. We say r is closed if r(a) = r(b). Example 2.5 The parabola in example 2.1 has endpoints (2, 0) and (8, 3) but is not closed. The curve in example 2.2 is closed, as C(0) = C(2) = (2, 0). Denition 2.6 A point P on the trace of a curve r : I R2 is a multiple point if the trace passes through P more than once, i.e. there at least two values t1 , t2 R with are r(t1 ) = r(t2 ). A curve with no multiple points (excluding any end points) is called simple. A continuous plane curve that is both simple and closed is called a Jordan curve: example 2.2 is an obvious example. There is a famous, obvious but very hard theorem called the Jordan curve theorem that says that the trace of a Jordan curve always

math2011, 2010

splits the plane into exactly two pieces, one bounded (the inside) and one unbounded (the outside). A parameterisation of a plane curve has the added bonus of giving the curve an orientation, that is a direction to the trace. Consider a curve r : [a, b] R2 . We say r (or more accurately, its trace) is oriented in one way as t varies from a to b and the otherway as t varies from b to a. If we are denoting the curve by r when oriented in one way, when oriented in the other way we denote it as r. However, in the case of a Jordan curve, we always assume the curve is oriented in such a way that the inside is always on the left as one moves along the curve in the direction given by increasing t.

2.4
2.4.1

Calculus with curves


Limits

The limit of a curve r : I R2 is dened by taking the limits of its component functions as follows. Suppose r(t) = (x(t), y(t)) and lim x(t) = and lim y(t) = exist, then ta ta lim r(t) = (, ) . ta Limits of vector functions obey the same rule as limits of real-valued functions. The formal denition is with the usual and , with a minor change of notation: limta r(t) = (, ) means that for any > 0 there is a > 0 such that if |t a| < then r(t) r(a) < . If a curve is continuous at a (i.e. the component functions are continuousat a), then we have lim r(t) = r(a). ta

2.4.2

Dierentiation

The derivative of a curve is dened in the same way as for real valued functions: Denition 2.7 If r : (a, b) R2 then its derivative r : (a, b) R2 is dened by r(t + h) r(t) r (t) = lim h0 h if the limit exists. In this case we say r is dierentiable or smooth at t. We also have to consider curves that are piecewise smooth: such a curve is made up of a nite sequence of smooth pieces. Suppose points P and Q have position vectors r(t) and r(t + h) respectively, then P Q represents the vector r(t + h) r(t), which can therefore be regarded as a secant vector. If h > 0, the scalarmultiple (1/h)(r(t+h) r(t)) has the same direction as r(t+h) r(t). As h 0, it appears that this vector approaches a vector that lies on the tangent line. This is why we have the following:

Chapter 2

r(t + h) r(t) Figure 2.2: tangent Denition 2.8 The vector r (t) is called the tangent vector or the velocity of the curve dened by r at the point P , provided that r (t) exists and is not equal to zero. The length of the velocity, r (t) is called the speed. The tangent line to C at point P is dened to be the line through P parallel to the tangent vector r (t). If we have r(t) = x(t), y(t) , then it is easy to see that r (t) = x (t), y (t) . So on a practical level the derivative of a curve is obtained by simply dierentiating its component functions. We can also dene the unit tangent vector to a curve, which is r (t) T(r(t)) r (t) = . r (t) With the unit tangent vector we can say what it means for a curve to be a line: A line is a curve whose unit tangent vector is constant. In other words, a line is a curve whose direction is constant. Example 2.6 Find the points of intersection of the two curves given by r1 (t) = t2 1, t, 1 + t , Also, nd the angles at which they intersect. r2 (t) = t, t2 1, t .

Suppose r1 and r2 are dierentiable vector functions, c is a scalar, and f is a dieren tiable real-valued function. Then a) b) c) d) d [r1 (t) + r2 (t)] = r1 (t) + r2 (t) dt d [cr1 (t)] = cr1 (t) dt d [f (t)r1 (t)] = f (t)r1 (t) + f (t)r1 (t) dt d [r1 (t) r2 (t)] = r1 (t) r2 (t) + r1 (t) r2 (t) ( is the dot product of vectors.) dt

6 e) f)

math2011, 2010 d [r1 (t) r2 (t)] = r1 (t) r2 (t) + r1 (t) r2 (t) ( is the cross product of vectors.) dt

d [r1 (f (t))] = f (t) r1 (f (t)) (chain rule) dt Note that the rules for the derivative of a dot or cross product are exactly the same as the usual product rule you learnt in High School, but applied to vector functions. The tangent vector to a curve is of course another valued function, and so is another curve. So we can dierentiate the the derivative: Denition 2.9 The second derivative of a curve, r is called the acceleration of the curve r. Example 2.7 Dene the plane curve r by r(t) = 2i + cos t j + 2 sin t k. Is r continuous at t = 0? Find the velocity and acceleration at t = . 2 Example 2.8 A particle is travelling on a circle with constant speed. Show that the velocity and acceleration are orthogonal. Since a circle is in a plane, we might as well assume that the particle is in the xy-plane, and the circle centered at the origin. Thus the path of the particle is given by r(t) = a (cos (t) i + sin (t) j) for some function (t), where a is the radius. The velocity will be r (t) = a ( sin (t) i + cos (t) j) , and the speed is hence r = a| |. As this is constant, there must be constants , 0 with = t + 0 (we could assume 0 = 0 by changing the starting point of t). The acceleration is r (t) = a 2 ( cos (t) i sin (t) j) = 2 r, and it is easy to see that r r is always zero, proving the result.

2.4.3

Integration

We will be looking more closely at using curves in integration in the second half of the session. But for the moment I will just point out that in the same way that we dierentiated the components of a curve, we can integrate them to get another vector valued function. So if r : [a, b] R2 is parameterised by r(t) = x(t), y(t) then we can dene
b b b

r dt =

x dt ,

y dt ,
a

r dt =

x dt ,
a a

y dt

as indente and denite integrals of the curve. We do not usually do this sort of integration-by-component for vector functions. But one integral that is quite common is arc length: the integral of the speed.

Chapter 2

Denition 2.10 For a curve r : [a, b] Rn , the arc length s from r(a) to r(t) is given t by s = r (u) du. a Except for lines and circles, and some special curves, arc length is very dicult to calculate explicitly. Even for a curve as simple as an ellipse we need to invent new functions for the arc length. Example 2.9 For the curve in R3 given by 15 cos 2t k, r(t) = 2 cos t i + 3 sin t j + 4 a) Find the velocity and acceleration. b) Show that the velocity and acceleration are orthogonal at t = n , n Z. 2 c) Find the length of the curve from t = 0 to t = 2. d) Write down the unit tangent vector at t = . 6 e) Sketch the curve and indicate the unit tangent vector found in part d). tR:

2.5

Plotting curves: Maple and/or matlab

Although we will seldom consider any curve more complicated than a conic section (parabola, ellipse, hyperbola) in this course, you will occasionally come across other curves. With an unfamilar curve the best way to get a picture of it is to get the computer to draw it. You will all be familar with Maple or matlab, or possibly both, and they can both plot curves for you very easily. On the Blackboard page I will put some Maple and matlab les showing or reminding you how to plot curves. As an example of a trickier curve, the curve paramaterised by r = (t tanh t, sech t) , tR

is in gure 2.3 (The tractrix has the interesting property that the distance from any point P on the curve to the point where the tangent at P intersect the x-axis is always 1.) So if you had a reluctant dog on a lead of length one placed one unit up the y-axis and walked o down the x-axis dragging it behind you so that the lead stays taught, the dogs trajectory would be the tractrix.)

math2011, 2010

1.0 0.75 0.5 0.25 0.0 2 1 0 1 2

Figure 2.3: Tractrix

Chapter 3 Surfaces
3.1 Basic denitions for surfaces

When I say surface, you should picture something like a ball or a piece of paper: something essentially two dimensional living in a three dimensional space. Denition 3.1 A surface in R3 can be described (i) explicitly as the graph of a function of two variables, say z = f (x, y) or (ii) implicitly as the set of all points satisfying (x, y, z) = 0 or (iii) parametrically by equations of the form x = x(u, v), y = y(u, v), z = z(u, v) The rst two methods are the most intuitive; the third one is the most useful mathematically, as it builds in a way of labelling the points of the surface. But any surface dened in one way can always be dened by one of the others, but usually only in patches, as we will see. Most surfaces cannot be completely described in all three ways. Example 3.1 Describe the plane through the points (1, 0, 0), (0, 1, 0) and (0, 0, 1) in the three ways listed in denition 3.1. Example 3.2 Let S be the unit sphere, the set of points satisfying x2 + y 2 + z 2 1 = 0. Explain why this cannot be described as a graph and give a parametric description of it. There are many ways of parameterising a sphere, but the one we will see most often is x = sin v cos u, y = sin v sin u, z = cos v 1 (0 u 2, 0 v )

math2011, 2010

3.2

Sketching Surfaces

In general it is dicult to sketch surfaces well. Mostly it is enough to be able to see what the underlying solid looks like when we sight along the axes, and/or look at the intersections of the surface and the various coorinate planes. This is where the computer can really help, but we expect you to be able to sketch surfaces without it. The other problem you face is that drawing in three dimensions needs some awareness of perspective: how an object actually looks. I will discuss this in more detail in the lectures.

3.2.1

Graphs of functions of two variables


y

For functions of one variable, f : R R, the graph is a subset of R2 , namely the set of points {(x, y) : y = f (x)}

f (a) a
Figure 3.1: graph
2

f (b) b x

For function of two variables, f : R R, the graph is a subset of R3 , namely the set of points {(x, y, z) : z = f (x, y)}, see gure 3.2 z

f (a, b) y

(a, b) x Figure 3.2: 2 dimensional graph

A graph automatically gives us a parameterisation we use x and y as the two parameters and simply z = f (x, y). The surfaces we will see most in this course are planes, spheres and cones, and we expect you to recognise these when you see them. But this leaves the question of what you do if you do not recognise a surface.

Chapter 3

One approach is to look at the curves formed from the intersections of the surface with the coordinate planes (planes x = 0, y = 0 and z = 0), or other planes, for example planes parallel to the coordinate planes.

Example 3.3 What sort of shape is the surface given by x2 + y 2 z 2 = 1? We note that the intersection of the surface with z = 0 is the curve x2 + y 2 = 1, which is of course the unit circle. The intersection with y = 0 is x2 z 2 = 1, which you ought to recognise as a hyperbola. In fact, the intersection of the surface and any plane of the form y = ax (which contains the z-axis) is a congruent hyperbola.

y z=0

x2 + y 2 = 1

x2 z 2 = 1

The intersection of the surface and any plane with z constant is also a circle, but of radius 1 + z 2 . This tells us the surface is formed from revolving the hyperbola x2 z 2 = 1 around the z-axis to form a surface known as a hyperboloid of one sheet, see gure 3.3.

Example 3.4 Sketch the surface given by the graph of f (x, y) = x2 + y 2 .

3.2.2

Contour Lines

A second method of graphing a surface is to use contour lines, or level curves. The values of the function f are indicated by drawing in a plane the curve with equation f (x, y) = c for indicative values of c. We actually see this representation every night on the news when we look at isobars on the weather map, which give lines of equal pressure. For example, with the hyperbloid of example 3.3 we get circles centered at the origin:

math2011, 2010

1.0 0.5 0.0 0.5 1 1.0 0 1 0 1 1

Figure 3.3: Hyperboloid of 1 sheet y Contours for z = 0, 1, 2, 3

Note that the circles get progressively further apart as z increases, and the lowest level curve is in the centre. Example 3.5 Let f : R2 R be given by f (x, y) = x2 y 2. Plot some level curves of the graph of f and sketch the surface.

Chapter 3

3.2.3

Projection

(see SHE, Section 14.2) Another useful tool for getting a picture of a surface is the projection. Those of you who have done technical or engineering drawing will be used to this idea: Denition 3.2 If S is a surface in R3 then its projection on the xy-plane is the set (x, y) R2 | for some z, (x, y, z) S i.e., the projection is what we see if we sight the surface along the z-axis. Example 3.6 Consider the surface given by x2 y 2 z 2 + 2 + 2 = 1 which is an ellipsoid. Its a2 b c

projection on the xy-plane is the (interior of) the ellipse

x2 y 2 + 2 1 a2 b

When we come to integrating over two- and three-dimensional regions, we will often want to know the intersections of curves or surfaces and the projections on these intersections onto the coordinate planes. Example 3.7 Find the projection of intersection of the surfaces z = x2 + 2y 2 and z = x + y + 1 onto the xy plane. Example 3.8 Sketch the solid bounded above by the sphere centered at the origin and with radius 2 and below by the surface z = x2 +y 2 . Find the projection of the intersection of the surfaces onto the xy-plane.

3.3

Plotting surfaces with Maple and/or matlab

There are several functions for plotting in three dimensions in Maple. The basic one is plot3d, but there is also the useful implicitplot3d. They both have options that allow

math2011, 2010

for various colouring eects and display of contours. I will try to demonstrate some of these in lectures. See also Blackboard page for example of these two functions, and others. For matlab, there are the functions surf, surfc and others. You should make an eort to play around with the 3-d plotting routines of one (or both) of these packages to help strengthen your three-dimensional visualisation powers.

Drawing in 3-d

Drawing in three dimensions


This is adapted from Tomas & Finneys Calculus and Analytic Geometry, 7th Ed, Addison Wesley, 1988.

Use a Pencil

An obvious comment, but you will need to erase lines either to move them or make them look hidden, so a pencil is a must.

Breaking or Hiding Lines

When one line passes behind another, break it to show it does not touch and that part is hidden. D B D B D B

crossing

AB behind

CD behind

A line or curve that is hidden should be drawn dashed (see examples below).

Perspective

In general you should draw an object as if it is below you and to your left. Also, note that right angles will not necessarily look like right angles (especially important with axes, see section 4), circles will look like ellipses, but a sphere will still look circular, see section 7. You should also be aware that parallel lines appear to converge.

Axes

If you actually look at three mutually orthogonal lines in space, then none of the angles they make actually appear to be right angles.

Drawing in 3-d z z

y y x Impossible Correct x

You should also make sure the (apparant) angles between the axes are reasonably large.

Planes parallel to axes

Draw planes parallel to the coordinate planes as if they were rectangles with sides parallel to the coordinate axes. To do this, the rectangles will actually be drawn as parallelograms. Do not forget to break and dash lines where appropriate. z z

A contact dot sometimes helps show where lines (axes in these cases) meet the plane. Note also that I have drawn the axes so they do not touch the parallelogram representing the plane.

Drawing in 3-d

Planes intersecting all axes

Drawing a plane that intersects all three axes is done with the following steps. (a) Sketch the axes, mark the intercepts and connect the intercepts to form a triangle. (b) Complete the triangle into a parallelogram. There are several ways of doing this, you want to pick one so that none of its sides are parallel to your axes. If necessary, shift an intercept point. (c) Draw a second parallelogram with sides parallel to the small one: this will be you sketch of the plane. (d) Darken exposed lines, dash hidden ones and rub out the small parallelogram and triangle keep the intercept points. z z

x (a) z z (b)

(c)

(d)

Drawing in 3-d

Spheres

When drawing a sphere start with the (circular) outline of the sphere and add in the (elliptical) equator (back half dashed). If you need axes, add them next, breaking lines where needed. Note that the north pole will not be at the highest point of the outline, but just below it. z

y x

sphere rst

Axes later

Other surfaces

With other surfaces, for example cylinders, paraboloids, hyperboloids, it is also useful to draw the surface rst and then add in the axes. John Steele

Chapter 4 Partial Derivatives and Continuity


4.1 Limits and Continuity

We have already seen the idea of limits applied to curves, and the idea was exactly the same as for functions from R to R: we can make distance in the codomain arbitrarily small ( < ) by making distances in the domain small ( < ). All that changed in the formal denition was we used the length of vectors on the codomain () distance (. . . r(t) r(a) < ). For functions from R2 to R, say, the same basic idea is used, but now we need lengths of vectors on the domain distance (). So Denition 4.1 We write lim
(x,y)(a,b)

f (x, y) =

and we say that the limit of f (x, y) as (x, y) approaches (a, b) is , if we can make the values of f (x, y) as close to as we like by taking the point (x, y) suciently close to the point (a, b) but not equal to (a, b). The formal denition is lim
(x,y)(a,b)

f (x, y) =

means that for any > 0 there is a > 0

such that if (x, y) (a, b) < then |f (x, y) | < . All the limit rules we met before (uniqueness, sums, products etc) work in this case the same proofs work with minor changes of notation. NOTE: the very important dierence to the case of a one-dimensional domain is that in two dimensions we can approach the point (a, b) from innitely many directions compared to only two (left or right) for a one variable function. This makes limits of functions of several variables more subtle than functions of one variable. In particular, if f has a limit at (a, b), then however we make (x, y) approach the point (a, b), f (x, y) approaches . If dierent ways of approaching (a, b) give dierent answers, then there is no limit. Example 4.1 Investigate the function f : R2 \ {(0, 0)} R given f (x, y) = 1 xy 3 . x4 + y 4

math2011, 2010

Look at how this function behaves along lines through the origin and explain what this tells us about the behaviour of f as (x, y) tends to (0, 0) Example 4.2 Find the limit lim
(x,y)(0,0)

f (x, y), if it exits, for the function sin (x2 + y 2 ) . x2 + y 2

f (x, y) =

Denition 4.2 A function f : D R2 R of two variables is called continuous at (a, b) D if lim f (x, y) = f (a, b) .
(x,y)(a,b)

We say f is continuous on D if f is continuous at every point (a, b) D.

4.2

Partial Derivatives

(See SHE, Section 14.4) Now we wish to investigate the rate of change in each direction x or y of the function f depending on x and y. Denition 4.3 The (rst) partial derivative, fx , with respect to x, of a function f of two variables is the function of two variables obtained by holding y constant and dierentiating with respect to x. fx (x, y) = lim f (x + h, y) f (x, y) f (x, b) f (a, b) or fx (a, b) = lim . xa h0 h xa

Similarly for fy we have fy (x, y) = lim f (x, y + h) f (x, y) f (a, y) f (a, b) or fy (a, b) = lim . h0 yb h yb

There are several dierent notations for partial derivatives, for example, if z = f (x, y) we can write fx (x, y) = fx = f z = f (x, y) = = Dx f = f,1 = D1 (f ) x x x

My personal preference is for fx , f,1 or D1 (f ), but you will meet all of these in dierent texts. I will discuss the problems with these notations in lectures, as well as looking at what the partial derivatives mean geometrically.

Chapter 4 Denition 4.4 If z = f (x, y) we can write the second partial derivatives of f (fx )x = fxx = f,11 = (fx )y = fxy = f,12 x f x f x f y f y = 2f 2z = x2 x2

= y x y

2f 2z = = yx yx = = 2z 2f = xy xy 2f 2z = 2 y 2 y

(fy )x = fyx = f,21 = (fy )y = fyy = f,22 =

Example 4.3 Calculate all rst and second partial derivatives for the function f : R2 R given by f (x, y) = x4 + 2x2 y 3 + sin(xy). Ive been very careful with the order in the mixed second derivatives fxy and fyx , but the following very useful result means we do not need to be (usually): Theorem 4.1 (Clairauts) Suppose f is dened on a disc D that contains the point (a, b). If the functions fxy and fyx are both continuous on D, then fxy (a, b) = fyx (a, b) . In particular, for a function whose components are built up from polynomials, sine, cosine, the exponential etc, all derivatives of all orders are continuous and so we get equality of the mixed derivatives. Example 4.4 Calculate fxy (0, 0) and fyx (0, 0) if xy(x2 y 2 ) (x, y) = (0, 0) x2 + y 2 f (x, y) = . 0 x=y=0

Chapter 5 Chain Rule and Applications


5.1 Chain Rule

Reference: SHE, Section 15.3 Suppose you are in a large room with a heater in one corner, so that the temperature in the room varies with position. How would you calculate the rate of change of temperature as you walked around the room? Well, we have temperature T a function of coordinates in the room, x and y, and x and y will both be functions of time t. So the temperature dT . This is a case of function you feel is a function of time, T x(t), y(t) , and we want dt of a function, and so we need a chain rule. If we were to keep y constant at y0 , say, then wed have a one-variable problem. As y is being kept xed, we have d dx T T x(t), y0 = (x, y0 ) , dt x dt and similarly if x is kept xed we would have d T dy T x0 , y(t) = (x0 , y) . dt y dt What if both x and y are varying? Well, we add these two results together: Theorem 5.1 Suppose that a) f is a dierentiable function of two variables x and y, b) x and y are dierentiable functions of a single variable t. Then if F (t) = f (x(t), y(t)) we have F (t) = fx x(t), y(t) x (t) + fy x(t), y(t) y (t) 1

2 This is sometimes written as dz f dx f dy = + dt x dt y dt

math2011, 2010

where z denotes F (t). dz at t = 0. dt On the other hand, it could be that your position in the room depended on two variables, s and t. Now it makes sense to ask about the rate of change of T with respect to s or t, which are of course partial derivatives. Example 5.1 Suppose z = ex
2 +y

, x = cos t and y = sin t. Find

Theorem 5.2 Suppose that a) f is a dierentiable function of two variables x and y, b) x and y are dierentiable functions of two variables s and t. Then if F (s, t) = f (x(s, t), y(s, t)) , we have F f x f y = + s x s y s f x f y F = + t x t y t f f Example 5.2 Suppose f (x, y) = x2 y + y 3, x = r cos and y = r sin . Find and r using the chain rule. Example 5.3 Suppose that f : R R is dierentiable. Show that u(x, y) = f (x/y) is a solution to the partial dierential equation x u u +y =0 x y

One way of keeping track of chain rules is to use a diagram like gure 5.1, which corresponds to the case of theorem 5.2. We link every function to all those variables that directly determine it. Each path starting from the top most function (F in gure 5.1) gives you a product of partial derivatives, and you add up all the paths from the top variable to the appropriate bottom (independent) variable. These chain rules (and assosiated diagrams) can be extended to functions of more variables. Suppose we have f (w, x, y, z) with w, x, y and z dependent on r, s and t. Then, for example f f w f x f y f z = + + + , r w r x r y r z r with diagram in gure 5.2.

Chapter 5 F f x x x s s f y y y t t

y s

x t

Figure 5.1: chain rule f

s Figure 5.2: chain rule

5.2

Dierentiation and Integration

As you should all know, the Fundamental Theorem of Calculus tells us that dierentiating an integral with respect to its limits gives you the integrand: d dx
x 0

sin t sin x dt = . t x

The (one variable) Chain rule can be applied to tell us that, for example d dx
x2 0

sin t sin(x2 ) sin(x2 ) dt = 2x = 2 . t x2 x

With the next result and the (several variable) chain rule we can nd d dx
x2 0

sin xt dt, t

where now x occurs in the integrand too. Theorem 5.3 Let g be a real valued function of two variables x and y. Then if both g and

4 g are continuous x

math2011, 2010

d dx

g(x, y) dy =
a a

g (x, y) dy. x

We are passing the derivative through the integral sign, swapping the order of two innite processes. d Example 5.4 Find dx
1 0

sin xt d dt and t dx

x2 0

sin xt dt. t

5.2.1

Integrals with a parameter

We can use dierentiation under the integral sign to nd some interesting integrals. For example, it is easy to show that dx = 2 + a2 a x using a standard (inverse tan) integral. If we dierentiate both sides with respect to a then we get 2a dx = 2. 2 + a2 )2 a (x From this we get dx = 3, 2 2 2 2a (x + a ) which is much harder to do with standard integrals. For a rather more interesting example, consider the following (a typical exam question):

Example 5.5 Given that


cos(2x) e2a dx = calculate x2 + a2 a

cos(2x) dx. (x2 + 4)2

As an exercise, nd

cos(2x) dx. (x2 + 9)3

5.3

Implicit Functions

Theorem 5.4 Suppose that an equation of the form F (x, y) = 0 denes y implicitly as a dierentiable function of x, that is, y = f (x), where F (x, f (x)) = 0 for all x in the domain of f . If F is dierentiable then F dx F dy dy Fx + = 0 so = . x dx y dx dx Fy Example 5.6 A curve is given implicitly by F (x, y) = 3x2 + y 2 + 2xy 4x = 0. When is it vertical?

Chapter 6 Gradient and Directional Derivatives


Reference: SHE, Sections 15.1, 15.2 We claimed previously that we could interpret the rst partial derivatives of z = f (x, y) fx (x0 ) and fy (x0 ) as the rate of change of f at x0 = x0 i+ y0 j in the i and j directions respectively. Consider a unit vector u in R2 . Then the equationx = x0+ t u represents x in direction u. The vertical 2 a straight line in R through the point 0 plane through this line meets the surface z = f (x, y) in a curve z = F (t) where F (t) = f (x0 + t u). z

x0 x

Figure 6.1: Directional Derivative

Denition 6.1 We dene the directional derivative of f at x0 = x0 i+y0 j with respect to the unit vector u to be the gradient (slope) of the curve in gure 6.1 at t 0: = f 1 (x0 ) = fu (x0 ) = lim (f (x0 + t u) f (x0 )) t0 t u F (t) F (0) = lim t0 t = F (0). 1

2 If we let u = (u1, u2 ), then with F (t) = f (x(t), y(t)) = f (x0 + t u1 , y0 + t u2 ) we have f dx f dy dF = + dt x dt y dt f f fu (x0 ) = (x 0 ) u 1 + (x0 ) u2 x y =f u where f = is called the gradient of f . f f i+ j x y

math2011, 2010

by the chain rule. Therefore

Denition 6.2 Suppose f is a function of two variables and fx , fy are continuous at (a, b) then the gradient of f at (a, b) is dened as the vector fx (a, b) i + fy (a, b) j (fx (a, b), fy (a, b)) in R2 and is denoted by f (a, b) or grad f (a, b). Do not confuse the gradient vector f (which lives in the xy-plane) with a tangent vector to the surface (more on this later). Example 6.1 Find the gradient of f , where f (x, y) = cos x exp(xy 2 ) at the point (x, y) = (0, 2). Notes: a) Since u = 1 we can write u = cos i + sin j for some . b) If u = i (which corresponds to = 0) we have f f f (x0 ) cos(0) + (x0 ) sin(0) = (x0 ) f i (x 0 ) = x y x Similarly f f j (x0 ) = (x0 ) y c) For a general unit vector u f u (x0 ) = f u = f u cos = f cos

where is the angle between f and u.

Chapter 6

Denition 6.3 Suppose that u = cos i + sin j is a unit vector in R2 . The directional derivative of f at x0 in the direction of u (or ) is f (x0 ) u = fx (x0 ) cos + fy (x0 ) sin . It is denoted by f u (x0 ). The directional derivative may be described geometrically as the function in the specied direction u. rate of change of the Note: that we always use a unit vector when nding the directional derivative. Example 6.2 A mountain has height above sea level (in 1000s of metres) given by z = 1 f (x, y) = 4 4 x4 + sin(x) sin(y) + y 2 for 2 x, y 2, where the y-axis points due north. What is the slope of the mountain in the South-East direction at x = 0, y = 1/2? Theorem 6.1 For a function of two variables with f (x0 ) = 0, then a) the maximum and minimum values of f u (x0 ) are f (x0 ) and occur in the di rections given by f (x0 ), and (b) f (x0 ) is normal to the level curve passing through x0 , provided that fx and fy are continuous at x0 . Proof: Part (a) follows from note (c) above: f u (x0 ) = f cos . The max and min values for f u (x0 ) occur at the max and min of cos , namely = 0 for the max and = for themin, the max value being f (x0 ) and the min value f (x0 ) . For part (b), suppose the level curve is r(t) = x(t)i + y(t)j. Then f (x(t), y(t)) is constant. The chain rule now gives 0= proving the result. Example 6.3 In what direction is the slope of the mountain in example 6.2 greatest at (0, 0.5) and what is this slope? Example 6.4 Consider the following function of two variables given by f (x, y) = x4 3xy + 2y 2. Calculate the gradient of f at a general point. Then draw the contour through (0.5, 0.5) and add the gradient at (0.5, 0.5). The gradient is given by f = f f j = (4x3 3y) i + ( 3x + 4y) j i+ x y f dx f dy d f (x(t), y(t)) = + = f r , dt x dt y dt

4 y

math2011, 2010

1 x y

1 x

Consider the contour that goes through the point (0.5, 0.5): 1 Now we calculate the gradient vector at (0.5, 0.5) to be i + 2 j and include it in the following gure. For a variety of contours we can show that the gradient is normal to the contour, i.e., y

1 x Example 6.5 For f (x, y) = x2 + y 2 a) Find f

b) Sketch some level curves of f c) Indicate f at some points on these curves. Example 6.6 The temperature of a BBQ plate covering the region 10 x, y 10 is given by 400 T (x, y) = 1 1 2 2 + 4 x + 9 y2

Chapter 6

An ant lands on the plate at the point (1,2). In which direction should she run to move most quickly away from the heat? Finally, note the ideas of gradient, directional derivative extend to R3 where f (x, y, z) = f f f j+ i+ k x y z

and the gradient is normal to the surface f (x, y, z) = constant.

Chapter 7 Normal and Tangent Lines; Tangent Planes


Reference: Section 15.4

7.1

Tangent Planes

Suppose we have a surface in R3 dened by the equation (x, y, z) = C, C a constant, and we also have a curve r, with r(t) = f (t)i + g(t)j + h(t)k, that lies in the surface. Now the tangent vector r is r (t) = f (t)i + g (t)j + h (t)k. As the trace of r lies on the surface, we have (f (t), g(t), h(t)) = C. Dierentiating and using the chainrule we get d (f (t), g(t), h(t)) = 0 dt dg dh df + + =0 x dt y dt z dt f x y g = 0 h z

i.e.

i.e. i.e.

r = 0 So, at any particular point, P , on the surface, all curves that lie in the surface and go through P have a tangent vector orthogonal to (P ). The set of all vectors at P orthogonal to (P ) of course form a plane: the tangent plane. Denition 7.1 For a surface S dened by = constant, the tangent plane at P S is the plane through P with normal (P ). 1

math2011, 2010

From this denition, we can immediately write down the point-normal form of the tangent plane at P : (P ) (x p) = 0 (7.1) and the Cartesian (and parametric vector) forms follow easily, see earlier. Example 7.1 Find the tangent plane to the surface x2 + y 2 + z 2 = 6 at the point P = (1, 2, 1). The formula of equation (7.1) is easily modied to the case of a surface given as the graph: such a surface is z = f (x, y), and so f (x, y) z = 0 is constant, so use f (x, y) z as (x, y, z) Then we have f f i+ j k. = x y Example 7.2 Find the tangent plane to the graph of x4 + 3x2 y y 2 at (x, y) = (1, 2). We can nd a parametric form of the tangent plane at a point P directly by relying on its dimension, which is obviously 2. All we need to do is nd two independent tangent vectors at P , and they must then span the plane. We do this by nding two curves in the surface going through P whose tangent vectors at P are independent. For a graph this is easy. Suppose our point P in the graph of z = f (x, y) is (x0 , y0, f (x0 , y0 ) ). Two obvious curves in the surface both going through P (at t = 0) are r1 (t) = t + x0 , y0 , f (t + x0 , y0) r2 (t) = x0 , t + y0 , f (x0 , t + y0 ) At t = 0 these have tangents, respectively f u = r1 = i + k x f k v = r2 = j + y The tangent plane through P thus has parametric vector form p + u + v. A normal to this plane is given by i uv= 1 0 which is , for = f (x, y) z. Example 7.3 Find a parametric form of the tangent plane to the graph of f , where f (x, y) = x3 3xy 2 + 3y, at (x, y) = (2, 1). j k f = fx i fy j + k 0 x 1 fy

Chapter 7

The point-normal approach is the best one, because it generalises immediately to other dimensions, in particular, we can use it for tangent lines to curves. Example 7.4 Find the equation of the tangent line to the ellipse 3x2 + 4y 2 = 7 at the point (1, 1)

7.2

Normal lines

For curves in R2 the normal line at a point P is the line orthogonal to the tangent line at P . For surfaces in R3 the normal line at P is the line normal to the tangent plane at P Both of these are easily found using the gradient. Example 7.5 Find the normal line to the ellipse 2x2 + 5y 2 = 7 at (1, 1). Example 7.6 Find the normal line to the ellispoid 2x2 + 2y 2 + z 2 = 8 at the point (1, 1, 2) We say two curves in R2 through the one point P touch tangentially at P if they have the same tangent line at P . Similarly, two surfaces through the one point P touch tangentially at P if they have the same tangent plane at P . Of course, checking two planes are the same is not quite as straightforward as checking two lines are the same, as there are many ways of writing down a given plane. For example, its not immediately obvious that 1 1 3 1 2 1 x = 1 + s 2 + t 2 and x = 1 + 0 + 2 1 2 4 1 1 3

are the same plane. But a plane only has one normal direction, so two planes through one point are the same if and only if their normals are parallel.

Example 7.7 Show that the ellipsoid 2x2 + 2y 2 + z 2 = 8 and the sphere 2x2 + 2y 2 + 2z 2 + x + y 3z = 8 touch tangentially at (1, 1, 2).

7.3

Linear Approximation

One of the chief benets of the tangent line to the graph of a function f : R R is that it gives us a good approximation to f in fact, it is the best approximation you can do with a polynomial of degree 1. In terms of the graph of f , being dierentiable at a point really means the graph is approximately a straight line, or looks so if you magnify the graph enough. For example, if f (x) = x2 ,

math2011, 2010

1 10

1 10

But for the absolute value, no amount of magnication will make the graph look like a line at the origin:

When it comes to two variables, everything weve looked at so far would suggest that the tangent plane will give us our best linear approximation, and this is usually the case. Example 7.8 Determine the equation for the tangent plane to the surface z = f (x, y) = sin(x + y) at (1, 1, 0) and hence approximate the value of the function at x = 1.05 and y = 0.85. However, consider the following function xy + y2 (x, y) = (0, 0) (x, y) = (0, 0)

f (x, y) =

x2 0

Chapter 7 Now f is not continuous at (0, 0) since rst partial derivatives: f (x, 0) f (0, 0) f (0, 0) = lim =0 x0 x x f (0, y) f (0, 0) f (0, 0) = lim = 0. y0 y y lim

5 f (x, y) does not exist (why?) yet it has

(x,y)(0,0)

This means that the equation of our tangent plane is z = 0. But the plane z = 0 is a useless approximation to the function z = f (x, y) close to (0, 0). If y = x (x = 0) then 1 f (x, x) = 2 no matter how small x is and so f is not approximated by z = 0. So the surface does not have a tangent plane at the origin. We see that dierentiability for several variables (whatever that might mean) is rather more complicated than the one variable case. This example is really telling us that if we want dierentiability to mean locally linear, then just having partial derivatives is not good enough. With this in mind, we give our rst try at a denition of dierentiability for functions of two variables: Denition 7.2 Let f : R2 R be dened at (a, b) and assume fx and fy are also dened at (a, b). Then we say f is dierentiable at (a, b) if the plane fx (a, b) (x a) + fy (a, b) (y b) (z f (a, b)) = 0 gives a good approximation to the surface z = f (x, y) in all directions. In this case it makes sense to call the above plane the tangent plane. Im not going to say precisely what I mean by good approximation, but we can prove that if the partial derivatives fx and fy are continuous at (a, b) then the function is dierentiable. We will return to this problem later.

7.4

Dierentials

Reference: SHE, Section 15.8 Recall from one variable calculus we dened the dierential of y = f (x) as dy = f (x) dx . For a function of two variables, z = f (x, y), we dene dierentials dx and dy to be independent (since both x and y are). Then the total dierential dz is dened by dz = fx (x, y) dx + fy (x, y) dy = z z dx + dy . x y

If we return to our linear approximation formula we have f (x, y) f (a, b) + fx (a, b) (x a) + fy (a, b) (y b) = f (a, b) + dz

math2011, 2010

where dx = x = xa and dy = y = yb. This approach is very useful in estimating the change in a function if we know the change (error, increment) in the independent variables x and y. Example 7.9 The length and the width of a rectangle are measured as 30cm and 24cm, respectively, with an error in measurement of at most 0.1cm in each. Use dierentials to estimate the maximum error in the calculated area of the rectangle.

Chapter 8 Taylor Series


8.1 Revision
1 = 1 + t + t2 + = 1t
2 3 t

Recall that we can often express functions of one variable by a power series expansion, e.g., tn
n=0

|t| < 1 tn n! t2n+1 (2n + 1)! for all t for all t |t| < 1

t t e = 1 + t+ + + ... = 2! 3! sin t = t ln(1 + t) = t t3 t5 + ... = 3! 5! t t + ... 2 3


2 3

n=0

( 1)n
n=0

Such expansions are examples of Taylor series expansions about zero (Maclaurin series). Around a general point a, the Taylor series is (t) = (a) + (a) (a) (t a) + (t a)2 + . . . 1! 2! (8.1)

We recall that the linear terms (up to degree 1) give us the best linear approximation to , that is, the tangent line to the graph of , gure 8.1 (a). If we take the terms up to second order, we get the best quadratic approximation to , which gives the osculating parabola to the graph, gure 8.1 (b), which is an even better approximation. If the function we are dealing with is a polynomial of degree n, say, then the Taylor series will terminate after n + 1 terms, since all higher derivatives are zero. But generally the equality in equation (8.1) doesnt hold for all t but only for small t. If we truncate the expansion after n terms we can estimate the remainder or error term: (t) = (a) + (n1) (a) (a) (t a) + . . . + (t a)n1 + Rn (t a) 1! (n 1)! 1

2 y y

math2011, 2010

x (a) Figure 8.1: Taylor approximations where Rn (t a) = and a < t < t if t > a t < t < a if t < a (n) (t ) (t a)n n! (b)

If Rn (t a) 0 as n then we say the Taylor series expansion converges to (t). The hard part of using Taylor series for approximations is estimating the error, and this is where the remainder term comes in. Note that the remainder term follows the same pattern as the other ones except that it is evaluated at a dierent (and unknown) point. But if we knew that |(n) (t)| < M between t and a, then the error involved in truncating after n terms can be estimated using Rn to be M |t a|n . n! Example 8.1 Find the Taylor series of f (x) = x about x = 4. Use the terms up to second order to approximate 4.2 and estimate the error in this approximation using the remainder. E

8.2

Two variables

Now we wish to extend the Taylor series notion from one variable to two variables. Suppose z = f (x, y) and let x0 = (x0 , y0) and h = (h, k) be xed. Now dene by (t) = f (x0 + t h) for real t.

Chapter 8 Then by the chain rule d f dx f dy = + dt x dt y dt f f h+ k = x y and d2 d d = = 2 dt dt dt x f f = h+ x x y 2 2 f f h+ = 2 x x y


2

d dt k k

dx d dy + dt y dt dt f f dx dy + h+ k dt y x y dt 2 2 f f h+ h+ 2 k k y x y h +k x y
2

2f 2f 2f + 2hk + k2 2 = =h x2 x y y Similarly d3 d = 3 dt dt d2 dt2 = x


3

d2 dt2

dx + dt y

d2 dt2

dy dt

+k f = h x y 3f 3f 3f 3f + 3hk 2 + k3 3 . = h3 3 + 3h2 k 2 x x y x y 2 y We should note that the above partial derivatives are evaluated at the point x0 = (x0 , y0 ). We substitute this into (1) = (0) + to get f (x0 + h, y0 + k) = f (x0 , y0 ) + 1 2! 1 + 3! + 1 f f (x 0 ) h + (x 0 ) k 1! x x 2f 2f 2f (x0 ) h2 + 2 (x0 ) hk + 2 (x0 ) k 2 x2 x y y 3 3 f f (x0 ) h3 + 2 (x0 ) 3h2 k 3 x x y 3 3f f + ... (x0 ) 3hk 2 + 3 (x0 ) k 3 + xy 2 y (0) (0) 2 1+ 1 + ... 1! 2!

(8.2)

math2011, 2010

which is called the Taylor expansion of f about the point x0 . Notice that if we set x = x0 + h, y = y0 + k so that h = x x0 and k = y y0 then we can write: f (x, y) = f (x0 , y0) + + 1 2! f f (x0 ) (x x0 ) + (x0 ) (y y0 ) x y 2f 2f 2f 2 (x0 ) (x x0 ) + 2 (x0 ) (x x0 ) (y y0 ) + 2 (x0 ) (y y0 )2 2 x x y y 1 1!

+ ...

We expect you to know the MacLaurin series for et , sin t, cos t and (1 t)1 from rst year. They can often be used to get other series, even two variable ones, by standard manipulations. Example 8.2 Neglecting all products of x and y of order higher than 3 obtain the Taylor expansion of z = sin(x + y) about the origin, i.e., x0 = (0, 0). Example 8.3 Find the Taylor series for f (x, y) = x 3 y about the point (x, y) = (4, 8) up to and including terms of second order. Use the terms up to second order to approximate 4.2 3 7.9 Example 8.4 Given that for f : R2 R, f (1, 0) = 3 , 2f (1, 0) = 4 , x2

f (1, 0) = 3 , x 2f (1, 0) = 4 , xy

f (1, 0) = 2 y 2f and (1, 0) = 0 . y 2

(a) Write down the Taylor series for f (x, y) about the point (1, 0) up to and including terms of second order. (b) Use the constant and linear terms from the Taylor series in (a) to approximate f (1.02, 0.01). (c) Find the rate of change of f at the point (1, 0) in the direction of the vector i + 3j. Just as in the one variable case, for a polynomial the Taylor series terminates after a nite number of terms. For non-polynomials, we can truncate a Taylor series after all the terms involving an (n 1)th derivative, and what is left is an error term. Again, just as in the one variable case, it looks like a standard term, but is evaluated at a dierent (unknown) point. Denition 8.1 If the 2-variable Taylor expansion of equation (8.2) is truncated after the (n 1)th derivative terms, the remainder is given by Rn (h, k) = x0 +c(h,k) where the derivatives are all evaluated at some point x0 + c(h, k) with |c| < 1. 1 (n)! h +k x y
n

Chapter 8

Example 8.5 Find the quadratic polynomial that best approximates sin(x) sin(y) near (0, 0). Estimate the accuracy if |x| .1 and |y| < 0.1 Maple can calculate Taylor series and multivariable Taylor series for you. Use the taylor for one variable and mtaylor for several variables. See Maple help pages, my eLearning Vista and lectures for examples.

Chapter 9 Critical Points and Lagrange Multipliers


(Reference: SHE, Section 15.5, 15.6)

9.1

Critical Points for One Variable

Let us begin with a look at the following problem: How do the critical points of the function f : R R given by f (x) = Ax2 + B behave as A increases from negative to positive? y y y B B

x B A>0 A=0

x A<0

Of course, this is a High School problem. We note that the behaviour changes markedly as A varies from negative to positive, though. Now consider a function whose MacLaurin series is 1 1 f (x) = f (0) + f (0)x2 + f (0)x3 + 2 3! As f (0) = 0 we have a critical point at x = 0. For small x, x2 dominates all the higher powers: x2 > |x3 | > x4 > . . . , so close to zero we have 1 f (x) f (0) + f (0)x2 2 1

2 and so the sign of f (0) will govern the type of critical point we have: f (0) > 0 local minimum. f (0) < 0 local maximum. f (0) = 0 more work needed.

math2011, 2010

For a critical point other than the origin, we need only change x to x a and calculate derivatives at x = a instead and weve rediscovered the second derivative test. However, the advantage of our method is that we can apply it to functions of two variables.

9.2

Critical Points and Two Variables

Firstly, some denitions: Denition 9.1 Let f : R2 R be a function. A critical point of f is a point (a, b) where f is either zero or does not exist. Denition 9.2 Let f : R2 R be a function. A stationary point of f is a point (a, b) where f is zero. An equivalent way of saying this is fx (a, b) = fy (a, b) = 0 or the tangent plane to the graph z = f (x, y) is horizontal. Denition 9.3 A function f : R2 R has a local maximum (respectively minimum) at (a, b) if f (a, b) is the largest (resp. smallest) function value on some small disc centered at (a, b). Example 9.1 Consider the function z = f (x, y) = x2 + y 2 with graph in gure 9.1. We have fx = 2x, fy = 2y so there is a stationary point at (0, 0) and f (0, 0) = 0. For any point (x, y) = (0, 0), f (x, y) > 0 and so (0, 0) is a minimum. We use the word extremum to save us having to write maximum or minimum all the time. Theorem 9.1 Suppse f has a local extremum at (a, b). Then if fx (a, b) and fy (a, b) both exist, then f has a stationary point at (a, b). The converse of this result is false: Example 9.2 Consider the function z = f (x, y) = x2 y 2 with graph in gure 9.2. We have fx = 2x, fy = 2y, so we have a stationary point at (0, 0), and f (0, 0) = 0. But as f (x, 0) > f (0, 0) if x = 0 however small x is, (0, 0) is not a local max. Similarly, f (0, y) < 0 if y = 0 however small y is, so (0, 0) is not a local min. The shape of the graph in gure 9.2 prompts us to the next denition:

Chapter 9
x -1 0 1 2 4 -2

0 -2 -1 0 1 y 2

Figure 9.1: Graph of x2 + y 2


x -2 0 2

0 z

-5

-2 0 y 2

Figure 9.2: Graph of x2 y 2 Denition 9.4 A stationary point that is not an extremum is called a saddle. Example 9.3 Do the following have a local min or local max at the origin? a) f (x, y) = x2 2xy + 10y 2 b) f (x, y) = 2x2 + 12xy + 8y 2 c) f (x, y) = x2 2xy + y 2 All the examples so far are quadratics, so lets look at the general quadratic, f (x, y) = Ax + 2Bxy + Cy 2 to nd the pattern. We have f (0, 0) = 0 of course, and assuming A = 0,
2

4 we have B Ax + 2Bxy + Cy = A x + y A
2 2 2

math2011, 2010

B2 2 y + Cy 2 A A1 B 2 AC y 2 (9.1)

=A x+

B y A

Firstly, if B 2 AC = 0, then the quadratic is a perfect square, and the sign of A tells us what we want. Secondly, if B 2 AC > 0, then the two terms in equation (9.1) have opposite signs, and so we have a saddle. If B 2 AC < 0, the two terms in equation (9.1) have the same sign and we have a max or min. This leaves the special cases with A = 0, when f (x, y) = y(2Bx + Cy). If B = 0, f (x, y) can have either sign, so we have a saddle note that in this case B 2 AC > 0. If B = 0 as well, we have f (x, y) = Cy 2, once again a perfect square so the sign of C tells us what we have: C > 0 gives a min, C < 0 a max. So we have the following results, if D = B 2 AC = 0: B 2 AC positive: B 2 AC negative, B 2 AC negative, A positive: A negative: saddle minimum maximum

If B 2 AC = 0, then we have a perfect square and so we get a max or min, but it is not isolated. Now let us apply the same reasoning we used for one variable, and suppose we have a function f : R2 R whose Taylor series about (0, 0) is f (x, y) = f (0, 0) + 1 2! 2f 2f 2f (0, 0)x2 + 2 (0, 0)xy + 2 (0, 0)y 2 + x2 xy y

Just as in the one variable case, if we are close to the origin, then we can ignore all the higher order derivatives, and the analysis of the general quadratic tells us what sort of critical point we will have. Theorem 9.2 (Second Derivative Test) Suppose the second order partial derivatives of f are continuous on a disk with centre (a, b) and suppose that fx (a, b) = 0 = fy (a, b), i.e., (a, b) is a critical point. Let D = (fxy (a, b))2 fxx (a, b) fyy (a, b). Then a) If D < 0 and fxx (a, b) > 0, then f (a, b) is a local minimum

Chapter 9 b) If D < 0 and fxx (a, b) < 0, then f (a, b) is a local maximum. c) If D > 0 then f (a, b) is a saddle point

We call D the discriminant of the critical point. If D = 0 we need to do more work, just like in the one variable case. Example 9.4 Analyse the critical points of f : R2 R where f (x, y) = x3 y 3 3xy. Example 9.5 Analyse the critical points of f : R2 R where f (x, y) = sin(x) cos(y).

9.3

Extrema on bounded sets

So far, we have allowed the variables x and y to be unbounded. It is more usual in applications to have bounds on x and y. For example we might be looking at temperature in a room, and then x and y would be the dimensions of the room. So we might typically have a x b and c y d for some constants a, b, c, d. We would write the set of possible values of (x, y) as [a, b] [c, d]. This is an example of a closed, bounded region. It is not too dicult to properly dene bounded: Denition 9.5 A subset D of R2 is bounded if it is contained in some set if the form [a, b] [c, d], where a, b, c, d are all nite. A proper denition of closed is a little harder, although some of you may have met it. For this course it will be enough to say a set is closed if contains all of its edge. For example the set {(x, y) | x2 + y 2 < 1} is not closed as its edge (the set of point with x2 + y 2 = 1) is not included. But the set {(x, y) | x 1} is closed. For closed, bounded sets we have a very useful result: Theorem 9.3 Let f : D R be continuous on the closed bounded region D R2 . Then f attains a maximum and a minimum value on D. We met the one variable version of this (the max-min theorem) in rst year. To nd the extrema on closed bounded sets we do the following steps: (a) Find the values of f at critical points of f in S. (b) Find the extreme values of f on the boundary of S. (c) The largest of the values from the above steps is the absolute maximum and the smallest of these values is the absolute minimum. Example 9.6 Find the extrema of the function given by f (x, y) = x3 y 3 3xy on the region of R2 bounded by x = 0, y = 0 and y + x = 3. Example 9.7 Find the extreme values of the function given by f (x, y) = 2xy on the closed disc x2 + y 2 4.

math2011, 2010

Example 9.8 What are the dimension of the largest box in the rst octant (x 0, y 0, z 0) with one vertex at the origin and the opposite one on the plane 3x + 2y + z = 3? This last problem is an example of a constrained extremum: these are usually dealt with by the very powerful method of Lagrange Multipliers, which we turn to next.

9.4

Lagrange Multipliers

We now wish to consider the problem of maximising or minimising a function that is subject to a constraint, e.g., nd the extreme values of f (x, y) subject to g(x, y) = k. One possibility is that sometimes we can solve g(x, y) = k to obtain y = y(x) say. Then we set about nding the critical points of z = f (x, y(x)). Example 9.9 Maximise xy subject to x+y = 6. This is equivalent to maximising x (6x), which requires x = 3 obviously, and f (3, 3) = 9. Example 9.8 is a three variable version of a similar problem. However, we cannot always do this or even if we can, it may make the problem very much more complicated than it needs to be. But even if we cannot explicitly solve g(x, y) = k to obtain y = y(x) such a function is dened implicitly and we still have to nd the critical points of z = f (x, y(x)). Dierentiating the constraint g(x, y) = k gives us g dx g dy + =0 x dx y dx Now for a critical point 0= This will be the case if dz f f dy f f = + = + dx x y dx x y fx fy = gx gy (fx , fy ) = (gx , gy ) (= say) . or f = g gx gy . so dy gx = dx gy

This means where is the Lagrange multiplier. We recall that f is normal to the curve f = constant, and f = g says at the critical point(s) the two normals are proportional. So at the critical point, the curves where f is constant is tangent to the curves where g is constant. We can illustrate this is in the following example. Example 9.10 Minimise z = f (x, y) = x2 + y 2 subject to g(x, y) = x y = 16. We draw in the circle x2 + y 2 = r 2 and increase r until the corresponding circle touches the curve g(x, y) = 16. Figure 9.3 shows the curve g(x, y) = 16 with some level curves of f (x, y).

Chapter 9
10

-5

-10 -10 -5 0 5 10

Figure 9.3: Lagrange Multipliers The parallel gradients idea generalises to more that two dimensions, and even to more than two constraints (where that makes sense): Theorem 9.4 (Method of Lagrange Multipliers) To determine the maximum and minimum values of a function f (x) such that x Rn subject to constraints gi (x) = ki for all i = 1, . . . , k where k n 1 (assuming that these extreme values exist): (a) Find the values of x and i such that
k

f (x) = and

i=1

i gi (x)

gi (x) = ki i = 1, . . . , k ( n 1) . (b) Evaluate f at all points x that result from the previous step. The largest of these values is the maximum value of f ; the smallest is the minimum of f . Note that we do not need any second derivative test: if there are extrema we have found them. Example 9.11 Find the point closest to the origin on the graph of xy + 1. Unfortunately, while the method of Lagrange multipliers is very powerful, there is no algorithm for solving the equations you get. The equations are usually non-linear, so you wont be able to use Gaussian elimination for example. Sometimes it is easier to nd out the multipliers (the i ) rst, and sometimes it is best not to nd them, but to eliminate them from your equations. There are also often special cases that need to be checked out

math2011, 2010

what if one variable (or a multiplier) is zero, for example, which means you cannot divide by or cancel it. In the end, with Lagrange multiplier problems, you must use your wits and not be afraid to try something. If one approach does not work, try another. Example 9.12 Find (if they exist) the maximum and minimum values of f (x, y, z) = on the ellipsoid 9x2 + y 2 + z 2 = 3 in the rst octant. Example 9.13 Find the extrema of the function f given by f (x, y, z) = x + y + z subject to the conditions x2 + y 2 = 2 and x + z = 1. 1 xyz

Chapter 10 Jacobian Matrix and Inverse Functions


So far we have looked at functions from R to Rn (curves) and from R2 or R3 to R in other words either the domain or the codomain but not both have been vector valued. We now want to look at little at more general vector valued functions on vector domain.

10.1

Vector Valued Functions

A function f : Rp Rq (q > 1) is a vector valued function of p variables. (It is usual to use Rn and m here, but p and q have the advantage of sounding less alike.) R Example 10.1 x f y = z denes a function from R3 to R2 . When it comes to these vector valued functions, we now must write vectors as column vectors (essentially because matrices act on column vectors). In the example 10.1, the x x 1 2 real-valued functions f y = x + y + z and f y = xyz are called the co-ordinate z z or component functions of f, and we may write f= f1 f2 1 . x+y+z xyz

math2011, 2010

Generally, any f : Rp Rq is determined by q co-ordinate functions f 1 , . . . , f q and we write 1 1 p f (x , . . . , x ) 2 1 f (x , . . . , xp ) (10.1) f= . . . f q (x1 , . . . , xp )

10.2

Jacobian Matrix

All this is very obvious, but our rst problem is how we dene the derivative of a vector valued function. Recall that if f : R2 R then we can form the directional derivative, i.e., f f fu = u1 + u2 = f u x y where u = (u1 , u2 ). So that knowledge of the the gradient of f gives information about all directional derivatives. Therefore it is reasonable to assume f f (p), (p) pf = x y is the derivative of f at p. (The story is more complicated than this but if f is dieren tiable then f represents the derivative, see section 10.3.) More generally if f : Rp R we take the derivative at a to be the row vector f f f (a), (a), . . . , p (a) = a f x1 x2 x Now take f : Rp Rq where f is as in equation (10.1), then the natural candidate for the derivative f at a is of 1 f f 1 f 1 x1 x2 . . . xp f 2 f 2 f 2 ... 1 2 p Ja f = x x x . . ... . . . . . . . f q f q f q ... x1 x2 xp where the partial derivatives are evaluated at a. This q p matrix is called the Jacobian matrix of f. Writing the function f as a column helps us to get the rows and columns of matrix the right way round. Note the Jacobian is usually the determinant the Jacobian of this matrix when the matrix is square, i.e., p = q. Example 10.2 Find the Jacobian matrix of f from example 10.1 and evaluate it at the point A = (1, 2, 3).

Chapter 10

Most of the cases we will be looking at have p = q = either 2 or 3. Suppose u = u(x, y) and v = v(x, y). If we dene f : R2 R2 by x f y then the Jacobian matrix is = u(x, y) v(x, y) f1 f2

u x Jf = v x

u y v y

and the Jacobian (determinant) u x det(J f) = v x (u, v) . We often denote det(J f) by (x, y) Example 10.3 Polar to Cartesian co-ordinates, where x = r cos Then x (x, y) r = (r, ) y r x cos r sin = = r. y sin r cos and y = r sin . u u v v u y = . v x y x y y

10.3

Derivatives

We have already noted that if f : Rp Rq then the Jacobian matrix at each point a Rp is an q p matrix. Such a matrix Ja f gives us a linear map Da f : Rp Rq by (Da f) (x) = Ja f x for all x Rp Note that x is a column vector. Denition 10.1 Formally f : Rp Rq is dierentiable at a if, for small h, Da f(h) is a good approximation to f(a + h) f(a) in the sense that f(a + h) f(a) Da f(h) lim = 0 h h0

4 where

math2011, 2010

h = h2 + h2 + . . . + h2 . 1 2 p You should compare this to the one variable case: a function f : R R is dierentiable f (a + h) f (a) at a if lim exists, and we call this limit f (a). But we could equally well h0 h say this as f : R R is dierentiable at a if there is a number, written f (a), for which |f (a + h) f (a) f (a) h| = 0, h0 |h| lim because a linear map T : R R can only be multiplying by a number. Example 10.4 Write the derivative of the function in example 10.1 at (1, 2, 3) as a linear map. Suppose f and g are two dierentiable functions from Rp to Rq . It is easy to see that the derivative of f + g is the sum of the derivatives of f and g. We can take the dot product a function from Rp to R, and then dierentiate that. The result is a of f and g and get of product rule, but Ill leave you to work out what happens. Since we cannot divide sort vectors, there cannot be a quotient rule, so of the standard dierentiation rules, that leaves the chain rule.

10.4

The Chain Rule

Now suppose that g : Rp Rs and f : Rs Rq . We can now form the composition f g by mapping with grst and then following with f: g f Rp Rs Rq (10.2) x g(x) f(g(x)) (f g) (x) = f (g(x)) x Rp 2 2 2 3 Example 10.5 Let g : R R and f : R R be dened, respectively, by sin x x x+y x g = and f = x y y xy y xy Then f g is dened by x (f g) y =f g x y =f x+y xy

sin(x + y) = x + y xy . (x + y) (xy)

Chapter 10

Now if f and g in equation (10.2) above are dierentiable, then if b = g(a) Rs , the maps Ja g : Rp Rs and Jb f : Rs Rq are dened, and we have Theorem 10.1 (The Chain Rule) Suppose that g : Rp Rs and f : Rs Rq are dierentiable. Then Ja (f g) = Jg(a) f Ja g. This is again just like the one variable case, except now we are multiplying matrices (see below). Example 10.6 Consider example 10.5: x g y x+y xy x and f y sin x = x y xy

Find Ja (f g) where a =

a1 . Let a = a2 Ja g =

a1 . Then a2 1 1 a2 a1

1 1 = y x a

also cos x 0 cos(a1 + a2 ) 0 Jg(a) f = 1 = 1 1 1 y x x=a1 +a2 ,y=a1 a2 a1 a2 a1 + a2 and cos(x + y) cos(x + y) Ja (f g) = 1 y 1x 2xy + y 2 x2 + 2xy a

We nd that cos(a1 + a2 ) cos(a1 + a2 ) cos(a1 + a2 ) 0 1 a2 1 a1 = 1 1 a1 a2 a1 + a2 2a1 a2 + a2 2 a1 2 + 2a1 a2

1 1 a2 a1

I mentioned earlier that the chain rule here is very like the chain rule you met for functions of one variable. It is rather more accurate to say that the one variable chain rule is a special case of the one weve just met the same can be said for the chain rules we saw in chapter 5.

math2011, 2010

Let x : R R be a dierentiable function of t and u : R R a dierentiable function of x. Then (u x) : R R is given by (u x)(t) = u(x(t)). In the notation of this chapter Jt (u x) = Jx(t) u Jt x d du dx (u x) = dt dx x(t) dt t

i.e.

We usually write this as du dx du = dt dx dt du keeping in mind that when we write we are thinking of u as a function of t, i.e., u(x(t)) dt du we are thinking of u as a function of x. and when we write dx Now suppose we have x = x(t), y = y(t) and z = f (x, y). Then R R2 R and Jt (f x) = Jx(t) f Jt x Therefore d f (x(t), y(t)) dt so that df f dx f dy = + , dt x dt y dt which is just what we saw in chapter 5. f x f y dx dt dy dt
(x,y) f

10.5

Inverse Functions

In rst year (or earlier) you will have met the inverse function theorem, which says essentially that if f (a) is not zero, there is a dierentiable inverse function f 1 dened near f (a) with 1 d 1 (f ) = . dt f (a) f (a)

Chapter 10

What happens in the multi-variable case? Well, let us consider a case where we can write down the inverse. For polar coordinates we have x = r cos , y = r sin r= Now dierentiating we get r = x x x2 r cos = cos r + r 1 i.e., = x x r y2 = and x = cos r x2 + y 2 , = arctan y x

We see that the one variable inverse function theorem does not apply to partial derivatives. However, there is a simple generalisation if we use the multivariable derivative, that is, the Jacobean matrix. To continue with the polar coordinate example, dene r f and x g y Consider x (f g) y x =f g y r =f = x y = Id x y = r(x, y) (x, y) = x2 + y 2 y arctan x (10.4) = x(r, ) y(r, ) = r cos r sin (10.3)

Therefore f g = Id, the identity operator on R2 . Similarly g f = Id. Recall Id x y = x y so that J(Id) = 1 0 0 1 2 2 identity matrix

Thus by the chain rule J f J g = J(Id) = 1 0 0 1 = Jg Jf

math2011, 2010

so that (J f)1 = J g. Note for simplicity the points of evaluation have been left out. Therefore r r 1 x x x y r = y y . x y r r x = = cos etc. We can check this directly by substituting x x2 + y 2 The same idea works in general: Theorem 10.2 (The Inverse Function Theorem) Let f : Rp Rp be dierentiable at a. Then if Ja f is an invertible matrix, there is an inverse function f1 : Rp Rp dened in some neighbourhood of b = f(a) and (Jb f1 ) = (Ja f)1 Note that the inverse function may only exist in a small region around b = f(a). Example 10.7 We earlier saw that for polar coordinates, with the notation of equation (10.3) cos r sin , Jf = sin r cos with determinant r. So it follows from the inverse function theorem that the inverse function g is dierentiable if r = 0. Example 10.8 The function g : R2 R2 is given by g x y = u v = x2 y 2 x2 + y 2 .

Where is g invertible? Find the Jacobian matrix of g 1 where g is invertible. Now let us apply the inverse function theorem to the Jacobian determinants. We recall that r r x x (x, y) (r, ) x y r = det J g = = det J f = and . (x, y) (r, ) y y x y r Since J g and J f are inverse matrices, their determinants are inverses: 1 (r, ) = . (x, y) (x, y) (r, ) This sort of result is true for any change of variable in any number of dimensions and will prove very useful in chapter 13.

Chapter 11 Double Integrals


We now wish to turn to integrating function of several variables. We will only look at the case of real valued functions, not vector valued functions. We will also only be looking at the equivalent of denite integrals. You should recall from one variable calculus the Riemann sum denition of the integral. Let f (x) be a function with domain [a, b]. We partition the domain into n subintervals [xi1 , xi ], not necessarily of equally spaced points. In each [xi , xi+1 ] we choose an arbitrary point x : the set of these points is called a tag of the partition. The Riemann sum for this i tagged partition is
n i=1

f (x )(xi+1 xi ). i

If the limit as the length of the longest subinterval tends to zero (so n ) exists and is independent of the tag we say f is integrable on [a, b] and dene the integral
b n

f (x) dx = lim
a i=1

f (x )(xi+1 xi ) . i

We then proved theorems that tell us that if f is continuous then it is integrable, so we can use equal length subintervals and take the max (or min) on each subinterval as the tag. We now want to extend this idea to functions of several variables, two to begin with. Important: you must get into the habit of drawing the region you are integrating over when doing multiple integrals.

11.1

Double Integrals over Rectangles

(Reference: SHE, Sections 16.1, 16.2) Our rst problem is that two dimensional regions come in many more shapes than one dimensional ones the latter can only be intervals. So we begin by dening integration of the simplest type of two-dimensional regions: rectangles. 1

math2011, 2010

We consider the region R covered by a network of grid lines parallel to the x and y axes. These lines divide the region R into rectangles with areas A = x y. We next order
y

Suppose f : R R is a function of two variables (x, y) dened on the rectangular region R: R = [a, b] [c, d] = (x, y) R2 | a x b, c y d .

c x a b

these rectangles in some way and, as before, choose a sample point (x , yj ) in each of the i rectangle the set of sample points is again called a tag. We again form the Riemann sum for the tagged partition n m f (x , yj ) A , i i=1 j=1

and look at the limit of this sum as the size of largest rectangle tends to zero. If this limit exists independently of the tag, then we would say f is integrable on R. In the one variable case the integral is the area under the curve. In the two variable case it is the volume under the graph, assuming f (x, y) 0 on R, see gure 11.1 Denition 11.1 The double integral of z = f (x, y) over the rectangular region R is given by f (x, y) dA =
R R

f (x, y) dx dy
n m f (x , yj ) A i i=1 j=1 m f (x , yj ) A i i=1 j=1

= lim lim = lim

n m n

n,m

if this limit exists independently of the tag {(x , yj )}. i

Chapter 11

2 z 1 -2 -1 -1 0 y 1 22 1 0 x z

1 -2 -1 -1 0 y 1 22 1 0 x

0 -2

0 -2

Figure 11.1: Double Integral Just as in the one variable case, we can show that if f is continuous, then it is integrable, so we can take any partition and any tag to calculate f dA. Example 11.1 Compute [0,1][0,2] x y 2 dA assuming the integral exists. Let the partitions in the x and y directions be Px = i : i = 0, 1, . . . , n n and Py = 2j : j = 0, 1, . . . , m m

In this example we will take (x , yj ) as the lower right hand corner (vertex) for each of the i rectangles Rij , i.e., (x , yj ) = (xi , yj1). Thus i n m f (x , yj ) x y i i=1 j=1 n m

=
i=1 j=1 n m

f (xi , yj1) (xi xi1 ) (yj yj1) i n


n

=
i=1 j=1

2(j 1) m
m

1 n

2 m

8 = 2 3 nm 8 = 2 3 nm We recall from rst year


n

i=1 j=1 n

i (j 1)2
m

i
i=1 j=1

(j 1)2

i=1 m

i = 1+2+3++n =

1 n (n + 1) 2 1 (m 1) m (2m 1) 6

j=1

(j 1)2 = 12 + 22 + + (m 1)2 =

4 Hence
n m f (x , yj ) , x y i i=1 j=1

math2011, 2010

8 = 2 3 nm = = 8 n2 m3

i
i=1 j=1

(j 1)2

2 3 4 3 Thus

1 1 n (n + 1) (m 1) m (2m 1) 2 6 1 1 1 1+ 1 2 n m m as n, m 4 3

x y 2 dA =
[0,1][0,2]

In practice we do not subdivide the region R and calculate the volume of rectangular columns but rather use the Fundamental Theorem of Calculus this again is similar to the way we do one variable integration. Let us recap the idea of nding volumes by slicing. We begin with a positive function f : R R, and look at its graph, left picture of gure 11.2 Specically lets slice parallel to the xz-plane, i.e., y is a constant. The cross
x -2 0 2 4 z

0 -2 0 2 y x

Figure 11.2: Slicing the graph section in the y = yj plane looks like the graph on the right in gure 11.2. So if we assume that for a xed y, f (x, y) is integrable with respect to x,
b

A(y) =
a

f (x, y) dx

for c y d

Chapter 11

so the area of the slice is A(yj ). Thus the volume of the slice of thickness y = yj yj1 is A(yj ) y. Hence the volume under the surface is approximated by
m

A(yj ) y.
j=1

But the limit of the sum as m is


d

A(y) dy
c

(here we have assumed A is integrable with respect to y). Thus we would expect that
d b

f (x, y) dA =
R c a

f (x, y) dx dy.

In this case we integrate with respect to x rst and then y. Similarly by slicing parallel to the yz-plane we would expect
b d

f (x, y) dA =
R a c

f (x, y) dy dx.

where we integrate with respect to y rst, then x. Note that we think of these integrals from the inside outwards: y rst means dy is on the inside etc. Example 11.2 Let R = [0, 2] [0, 1]. Calculate
R

4 x y dA

rstly by slicing parallel to the xz-plane (x integral rst) and secondly slicing parallel to the yz-plane (y integral rst). The obvious question is: for what functions are these two integrals equal? Theorem 11.1 (Fubinis Theorem) If f (x, y) is continuous on the rectangular region R = [a, b] [c, d] then
b d d b

f (x, y) dA =
R a c

f (x, y) dy dx =
c a

f (x, y) dx dy .

We wont prove this as we would need a formal denition of the integral. In practice, it often doesnt matter which way you chose to do the integrals, but sometimes it is much easier to do one way rather than the other:

6 Example 11.3 Use Fubinis theorem to calculate y sin(xy) dA


R

math2011, 2010

where R = [1, 2] [0, ]. Fubinis theorem has the following simple corollary for special types of functions: Corollary 11.2 If f (x, y) = g(x) h(y) then
d b

f (x, y) dA =
R c

h(y) dy
a

g(x) dx

Proof: We have
d b

f (x, y) dA =
R c d a

g(x) h(y) dx dy
b

=
c

h(y)
a d

g(x) dx dy
b

=
c

h(y) dy
a

g(x) dx

Example 11.4 Calculate


R

x2 y 3 dx dy where R = [0, 1] [0, 1].

We are still left with the question of what to do if f becomes negative. In a sense, the mathematics does not care just integrate. The interpretation of the integral will change: rather than having a volume you will have a signed volume the volume under the xy plane is counted as negative. This is the same idea as signed area for one variable integrals. There are many standard properties of double integrals, most of which are very close to properties of one variable integrals: Theorem 11.3 (Properties of Double Integrals) a) If f (x, y) = 1 then
R

f (x, y) dA =
R R

dA is the area of R.

b) If the area of R is zero then c)


R

f (x, y) dA = 0 (even if f is unbounded on R). f (x, y) dA


R

[f (x, y) g(x, y)] dA =

g(x, y) dA.

Chapter 11 d)
R

7 f (x, y) dA if k is constant.
R

k f (x, y) dA = k

e) If f (x, y) g(x, y) on R then

f (x, y) dA

g(x, y) dA.
R

f ) Suppose R = R1 R2 and the area of R1 R2 is zero. Then f (x, y) dA =


R R1

f (x, y) dA +
R2

f (x, y) dA.

Part f) of this result tells us how to calculate integrals over a region that is a union of rectangles: break the region up into disjoint rectangles and integrate over each one separately. Since the area of the edge of a rectangle is zero, we do not need to worry about the rectangles having common edges.

11.2

Double Integrals over general bounded regions

When we come to looking at double integrals over bounded non-rectangular regions R, such as gure 11.3, then we use a standard trick. We extend the denition of the integrand to any rectangle enclosing R and decree that the integrand is zero outside R. Then we integrate our extended integrand over the rectangle.

Figure 11.3: General Region This will probably mean that the integrand has some discontinuities, but these will be over the boundary of R, which has zero area, so dont cause any problems. To calculate the integral over a general region, we do the same thing as for a rectangle, and slice with either x or y held constant. There is a generalisation of Fubinis theorem that says that as long as f is continuous (except possibly for a region of zero area), then the order of the integration does not matter. Suppose we are integrating f over R in gure 11.4 and we start with x constant, as shown. When we nd the area of this slice, the limits of the integral will depend on x, rather than be a constant. We see that R can be described as R = {(x, y) : a x b, 1 (x) y 2 (x)}

8 y

math2011, 2010

R
a x0 b x

Figure 11.4: Slicing with x constant for two functions 1 and 2 . The slice shown at x = x0 would then have area
2 (x0 )

f (x0 , y) dy
1 (x0 )

and the double integral over R would be


b 2 (x)

f dx dy =
R a 1 (x)

f (x, y) dy dx.

Example 11.5 Find the volume of the prism whose base is given by the triangle in the xy-plane bounded by the x-axis and the lines y = x and x = 1 and whose top surface lies in the plane x + y + z = 4. The solid is represented on the left in the gure 11.5.
0 x 0.25 0.5 0.75 1 4

2 z

0 0.25 0.5 y 0.75 1

Figure 11.5: Prism Next consider the region of integration R in the xy-plane, right of gure 11.5

Chapter 11

Then for any x between 0 and 1, y varies from 0 to y = x. Hence the volume is given by
1 x 0 1

V =
R

f dA =
0

(4 x y) dy dx 3 2 x 2
1

=
0

4x 1 3 x 2

dx

= 2x2 3 = . 2

On the other hand, if we tried to nd the volume of example 11.5 by integrating with respect to y rst we see that R is described as {(x, y) : 0 y 1, y x 1} and so we get integral
1 0 y 1

4 x y dx dy.

This is no harder than the previous case, but there is an very important point to be made with this example. Unlike the case of a rectangular region, we cannot just swap the two integrals around: we have to rewrite the integral completely, as the limits can change drastically. This is why you must draw a diagram. Furthermore, if we tried to slice the region in gure 11.4 holding y constant, we come to a problem. y

R
x Figure 11.6: Slicing with y constant For the part of R below the dashed line in gure 11.6, we cannot describe the x coordinate of the boundary using two functions of the y value of the slice, as such a slice cuts the boundary in four points, not two, and hence consists of two intervals, not one. So in this case we would have to either integrate with respect to y rst (that is, keep x constant rst), or split R into three parts: a part above the dashed line and two parts below. For some regions, the situation will be reversed integrating with respect to x rst involves only one integral and we have already seen that in yet others we could do the

10

math2011, 2010

integration in either order. But we could come across a situation like that in gure 11.6 where we would nevertheless do x rst, because that makes the actual integration easier (or perhaps possible): three easy integrals are better than one very hard one. Example 11.6 Let I be the integral
0 5 25 5

I=
5 y

(x + 2y) dx dy +
0

(x + 2y) dx dy.
y

Sketch the region of integration, change the order of the integration and hence calculate the value of I. We can call regions like gure 11.6 y-simple, but not x-simple. The region in example 11.5 is both x- and y-simple. In general, we nd that any region we are integrating over is either x-simple or y-simple (see gure 11.7), or both, or at least split into regions each of which is one of the two types. y 2 y b 2 R 1 a a y-simple Figure 11.7: Two types of region In gure 11.7, both 1 and 2 are continuous. It is important to note that the region of integration R determines the limits of integration NOT the integrand of the double integral. Example 11.7 Let R be the region in gure 11.8. Find xy dA.
R

b x x-simple

11.3

Double Integrals in Polar Coordinates


f (x, y) dA where R is say a region dened by circles, or
R

Suppose we wish to evaluate

some of the other curves you met in rst year that are best described by polar coordinates, such as cardioids.

Chapter 11 y = 2x y

11

y = x2 R y= x Figure 11.8: Region R = 2 = 1 r = r2 r = r1 x Figure 11.9: Polar rectangle The same basic idea we used before will work: we split the region up in rectangles and add up the volumes of prisms. The problem is that we need the area of a polar rectangle, which looks like the shape in gure 11.9. So what is the area of this shape, in terms of r = r2 r1 and = 2 1 ? Well, it is the dierence between the sectors of two circles, and a sector with angle of a circle of radius r has area 1 r 2 . So the area of the polar rectangle, A is given by 2 1 1 2 2 A = (r2 r1 ) = (r1 + r2 )r = r r, 2 2 where r is the average radius. So for double integration in polar coordinates, we would partition the region up into polar rectangles, as in gure 11.10. Then pick a point (ri , j ) in each polar rectangle (tag the partition) and form the Riemann sum
n m f (ri , j ) A , i=1 j=1 1 4

12 y

math2011, 2010

x Figure 11.10: Polar partition As the partition gets ner we expect this to approach the integral in polar coordinates f (x, y) dA =
R R

f (r cos , r sin ) r dr d.

Note: the extra r in the integrand. Example 11.8 Find the volume of the solid under the surface z = ex +y above the polar rectangle given by 1 1 r 3, 0 . 4 Just as in the case of Cartesian coordinates, we can integrate over more complicated regions dened by polar coordinates by using variable integration limits. Example 11.9 Sketch the four-leaved rose, given in polars by r = 2 sin 2 and calculate the area of one of its leaves. Example 11.10 Evaluate
R
2 2

the circle r = 1 and inside the cardioid r = 1 + cos .

y dA where R is the region in the rst quadrant outside

Most of the polar integrals you meet will be over regions where r is a function of and so we integrate with respect to r rst, but we can integrate with respect to rst if that is easier, or necessary, and there is a version of Fubinis theorem that tells us the order does not matter. Example 11.11 The centres of two spheres of radius a are 2b apart, where b a. Find the volume of their intersection.

11.4

Centroid and Centre of Mass

(Reference: SHE, Section 16.5)

Chapter 11

13

The most obvious application of double integrals is to calculating areas and volumes. The next simplest is the mass and centre of mass of a lamina (thin sheet). Suppose a lamina occupying a plane region R has density at co-ordinate (x, y) given by (x, y), having the dimension of mass per unit area. Hence the total mass m of the lamina is given by M=
R

(x, y) dA.

Denition 11.2 The co-ordinates of the centre of mass of a lamina occupying the region R and having density (x, y) are x= 1 M x(x, y) dA,
R

y=

1 M

y(x, y) dA,
R

where M is the mass of the lamina. The centre of mass is the point at which you could balance the lamina. The integrals R x(x, y) dA and R y(x, y) dA, are called the x-moment and ymoment respectively. Denition 11.3 The co-ordinates of the centroid of a region R are xc = where A is the area of R. The centroid is the geometric centre of the region R, and is the centre of mass of a lamina in the shape of R with unit density. Example 11.12 Find the centroid of the region enclosed by the three semi-circles below. y 1 A x dA,
R

yc =

1 A

y dA,
R

Example 11.13 Consider a triangular lamina R in the plane, bounded by x = 0, y = 0, x + y = 1, with density (x, y) = 2xy. Find its centre of mass.

MATH 2011 Several Variable Calculus Autumn 2010


Lecturer: Dr Bill Ellis Email: wjellis@unsw.edu.au Oce Hour: Wed 2 pm & Fri 1 pm in RC-4071 April 7, 2010

Contents
12 Triple Integrals [SHE 10 17.6 - 17.9] 12.1 The Denite Integral of a Function over a Region in Space . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12.2 Computing
T

1 1 5 10 15

f dV using Cylindrical Polar Co-ordinates . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . f dV using Spherical Polar Co-ordinates . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .


T

12.3 Computing

13 Change of Variables [SHE 10 17.10] 14 Line Integrals and Greens Theorem [SHE 10 18.1 - 18.5, 18.8] 14.1 Line Integrals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14.1.1 Hyperbolic Functions and their Inverses [SHE 10 7.8 - 7.9] . 14.2 Curl and Divergence . . . . . . . . . . . . . . . . . . . . . . . . . . . 14.3 Greens Theorem in the Plane . . . . . . . . . . . . . . . . . . . . . . 14.4 Conservative Vector Fields (revisited) . . . . . . . . . . . . . . . . . 14.4.1 Independence of Path in Line Integrals . . . . . . . . . . . . . 14.4.2 Physical Interpretation of Divergence and Curl in R3 . . . . . 15 Parameterisation of Surfaces, Surface Integrals [SHE 10 18.7] 17 Stokes Theorem [SHE 10 18.10] 18 Divergence Theorem [SHE 10 18.9] 19 Fourier Series 19.1 Orthogonal functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19.2 Fourier series of trigonometric functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . i . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

20 20 23 30 35 42 43 46 47 56 64 70 70 74

CONTENTS 19.2.1 19.2.2 19.2.3 19.2.4 Denition of a trigonometric Fourier series . . Convergence of a trigonometric Fourier series Fourier sine and cosine series . . . . . . . . . Periodic odd and even extensions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 74 76 78 80

ii

Chapter 12

Triple Integrals [SHE 10 17.6 - 17.9]


LECTURE 1
12.1 The Denite Integral of a Function over a Region in Space
and form the Riemann sum
n m p f x , yj , zk V i i=1 j=1 k=1

where V = xyz. If the Riemann sum tends to a limit (independent of partition and choice of (x , yj , zk ) we call the limit the triple integral of f over B. i Denition 12.1 The triple integral of f (x, y, z) over the parallelepiped region B is given by f (x, y, z) dV
B

The approach to dene and then evaluate a triple integral is similar to that of the double integral. Consider the parallelepiped (box) dened by B = [a1 , a2 ] [b1 , b2 ] [c1 , c2 ] . We then partition B into small boxes
z

=
B

f (x, y, z) dx dy dz
n m p f (x , yj , zk ) V i

= lim lim lim


n

n m p m

=
y

i=1 j=1 k=1 p f (x , yj , zk ) V lim i n,m,p i=1 j=1 k=1

if this limit exists.


1 1 2

Example 12.1 Evaluate the triple integral


x

x y z 2 dz dy dx.
0 0 2

CHAPTER 12. TRIPLE INTEGRALS [SHE 10 17.6 - 17.9] Solution:


1 1 2 1 1 2 1 1

x y z 2 dz dy dx =
0 0 2 0 0

1 x y z3 3

dy dx =
2

16 3
0

x y dy dx
0 1

16 3 8 3
0 0 1

1 x y2 2

dx
0

We note that z runs from z = 0 to z = 1 x y. Thus 1xy f (x, y, z) dV = f (x, y, z) dz dA .


T R 0

The region R is represented in the following diagram.

x dx 1 2 x 2
1

8 3

=
0

4 . 3

Things are not too bad when our region is a rectangular box B. What happens in a general region in R3 ? Example 12.2 Determine the limits of integration for evaluating the triple integral of a function f (x, y, z) over the tetrahedron T with vertices (0, 0, 0), (0, 0, 1), (1, 0, 0) and (0, 1, 0). Solution:
0 x 0.25 0.5 0.75 1 1

Hence
1 1x 1xy

f (x, y, z) dV =
T 0 0 0

f (x, y, z) dz dy dx .

0.8

0.6

0.4

0.2

Example 12.3 Evaluate


0 0.25 0.5 y 0.75 1

z dV over the volume T bounded by the planes x = 0,


T

y = 0, z = 0, y = 1 x and the surface z = Solution: 2

x + y.

CHAPTER 12. TRIPLE INTEGRALS [SHE 10 17.6 - 17.9]


1 0.75 0.5 0.25 0 1 x

Example 12.4 Determine the volume of the region cut from the cylinder x2 + y 2 = 4 by the planes z = 0 and x + z = 3. Solution:

0.8

0.6

z 0.4

0.2

00 0.25 0.5 0.75 y 1

Thus
1 1x x+y 1 1x

z dV =
T 0 0 0

z dz dy dx

=
0 0

1 2 z 2

x+y

dy dx
0

1 2
0

1 1x

(x + y) dy dx
0 1

1 2
0

xy +
1

1 2 y 2

1x

dy dx
0

1 2
0

x (1 x) +

1 (1 x)2 2
1

dy dx

= =

1 2 1 2

1 2 1 3 1 x x (1 x)3 2 3 6 1 1 1 + 2 3 6 = 1 . 6

dy dx
0

CHAPTER 12. TRIPLE INTEGRALS [SHE 10 17.6 - 17.9] (cont.) Example 12.5 Determine the volume of the hemisphere z = Solution: a2 x2 y 2 , z 0.

a2 x2

a2 x2 y 2

a2 x2

dV =
T a a2 x2 0

dz dy dx

=
a a2 x2

a2 x2 y 2 dy dx a2 x2 sin

substitute y =
a
2

=
a
2

(a2 x2 ) cos2 d dx

2 2

(a2 x2 ) dx 1 3 x 3
a

a2 x

=
a

2a3 . 3

LECTURE 2
4

CHAPTER 12. TRIPLE INTEGRALS [SHE 10 17.6 - 17.9]

12.2

Computing Co-ordinates
T

f dV using Cylindrical Polar

Example 12.6 Determine the volume of the region cut from the cylinder x2 + y 2 = 4 by the planes z = 0 and x + z = 3. Solution:
-2 x -1 0

z
2 5

z r y

0 -2 -1 0 y 1 2

x = y = z =

r cos r sin z

(x, y, z) R3 | 2 x 2,

4 x2 y

4 x2 , 0 z 3 x

(r, , z) R3 | 0 2, 0 r 2, 0 z 3 r cos
4x2 3x

Consider the volume element dV in cylindrical polar co-ordinates

Thus
2 2 2 3r cos

V =
T

dV =
2 4x2 0

dz dy dx =
0 0 2 2 0

r dz d dr

= dV f (x, y, z) dx dy dz
T

r dr d dz f (r cos , r sin , z) r dr d dz
T

r (3 r cos ) d dr
2

6
0

r dr = 12 .

CHAPTER 12. TRIPLE INTEGRALS [SHE 10 17.6 - 17.9] Example 12.7 Determine the volume of the solid that the cylinder r = a cos cuts out of the sphere of radius a centred at the origin. Solution:
x 0 0.5 1 1 -0.5 -1

=
T
2

dV
a cos a2 r 2

=
2
2

r dz dr d
0 a2 r 2 a cos

0.5

4
0 0
2

a2 r2 dr d
3

0 z

=
-0.5

4 3
0
2

(a2 r2 ) 2

a cos 0

=
-1 -1 -0.5 0 0.5 y 1

4 3
0
2

(a2 a2 cos2 ) 2 a3 d a3 sin3 a3 d


2

4 3

x y

4a3 3 4a 3
3

sin (1 cos2 ) 1 d 1 cos + cos3 3


2

= =

2 3 a (3 4) . 9

Example 12.8 Convert the triple integral 2


1 1y x

x2 + y 2 dz dx dy T = (r, , z) R | , 0 r a cos , 2 2
3 1 0 0

a2

r2

a2

r2 6

to an equivalent triple integral in cylindrical polar co-ordinates.

CHAPTER 12. TRIPLE INTEGRALS [SHE 10 17.6 - 17.9] Solution:


-1 -0.5 0 0.5 1 1 y

Example 12.9 Evaluate


T

x2 dV where T is the solid that lies within the cylinder

x2 + y 2 = 1, below the cone z 2 = 4 x2 + 4 y 2 and above the plane z = 0. Solution:

0.8

0.6

z 0.4

0.2

0 0.25 0.5 0.75 1 x

(x, y, z) R3 | 1 y 1, 0 x (r, , z) R3 |

, 0 r 1, 0 z r cos 2 2

1 y2, 0 z x

Hence we could evaluate the integral 2


1 1y x 1

r cos

r cos

x2 + y 2 dz dx dy =
1 0 0 0
2

r r dz d dr
0

=
0 1
2 2

r2 dz d dr
0

=
0
2 2

r3 cos d dr

1 4 1 4

cos d
2 2 sin | 2

1 . 2

CHAPTER 12. TRIPLE INTEGRALS [SHE 10 17.6 - 17.9] (cont.) Denition 12.3 The co-ordinates of the centroid of a object occupying the region T are x = y = z = 1 V 1 V 1 V
T

x dV y dV
T

z dV
T

where V =
T

dV .

This yields the geometric centre of the region T with volume V . Example 12.10 Determine the volume and centroid of the solid that is bounded by the paraboloids z = x2 + y 2 and z = 36 3x2 3y 2 . Denition 12.2 The co-ordinates of the centre of mass of an object occupying the region T and having density (x, y, z) are xm ym zm where
0

Solution:

= = =

1 m 1 m 1 m
T

x(x, y, z) dV
30

y(x, y, z) dV
T
z 20

z(x, y, z) dV
T
10

m=
T

(x, y, z) dV .

-2 0 y 2 2 0 x

-2

CHAPTER 12. TRIPLE INTEGRALS [SHE 10 17.6 - 17.9] The two paraboloids intersect when x2 +y 2 = 363x2 3y 2 . This implies the projection onto the xy-plane to be R = (x, y) R2 | x2 + y 2 9 . Thus in cylindrical polar co-ordinates T = (r, , z) R3 | 0 2, 0 r 3, r2 z 36 3r2 . = = Before we can determine the centroid of the region we need to determine the volume V of the object. Thus z =
2 3 363r 2

y =

1 V
T

y dV
2 3 363r 2

1 V

r sin r dz dr d 2
0 0 0 r2

0,

1 V 1 V

sin d

3 363r 2

r2 dz dr
0 r2

z dV
2 3 363r 2 T

V =
T

dV

=
0 0 3 r2

r dz dr d =

1 V 2 V

z r dz dr d
0 0 3 r2

= = = = Hence x = 1 V
T

2
0

r 36 4r2 dr 18 r
2 3 r4 0

r
0 3

1 2 z 2

363r 2

dr
r2

2 (162 81) 162 .

V
0

r (36 3r2 )2 r4 dr
3

= x dV =
2

V
0

r 64 63 r2 + 8r4 dr 64 2 63 4 8 6 r r + r 2 4 6 64 9 81 8 6 63 + 3 2 4 6
3 0

V V

1 V

2 3 363r

r cos r dz dr d 2
0 0 0 r2

= 15 .

= 0,

1 V

cos d

3 363r 2

r2 dz dr
0 r2

LECTURE 3
9

CHAPTER 12. TRIPLE INTEGRALS [SHE 10 17.6 - 17.9]

12.3

Computing ordinates
T

f dV using Spherical Polar Co-

Example 12.11 Determine the volume of the hemisphere z = Solution:

a2 x2 y 2 , z 0.

r
z

y
x

x y z

= r cos sin = r sin sin = r cos Thus

(x, y, z) R3 | a x a, 0z a2 x2 y 2

a2 x2 y 2

a2 x2 ,

(r, , ) R3 | 0 r a, 0 2, 0

Consider the volume element dV in spherical polar co-ordinates

a2 x2 a2 x2

a2 x2 y 2

V =
T

dV =
a 0

dz dy dx

=
0 0 0

r2 sin dr d d 2
0

dV = r sin dr d d

f (x, y, z) dx dy dz
T

=
T

f (r cos sin , r sin sin , r cos ) r2 sin dr d d

= (2) (1)

0 3

a 3

sin d = 2a . 3
3

r2 dr

10

CHAPTER 12. TRIPLE INTEGRALS [SHE 10 17.6 - 17.9] Example 12.12 Determine the volume enclosed by the torus r = sin . Solution:
x -1 -0.5 0 0.5 1
1 0.75 1 x 0.5 0.25 0

Example 12.13 Evaluate


T

y 2 dV where T is the solid bounded by the unit sphere

centred at the origin and in the rst octant. Solution:

0.5

0.25

0.75

0 z -0.25

0.5 z

0.25

-0.5 -1 -0.5

0 0.25 0.5 0.75 y

0 0.5 y 1

T Thus

(r, , ) R3 | 0
2 2

,0 ,0 r 1 2 2

y dV T Thus
2 sin

=
0
2

(r sin sin )2 r2 sin dr d d


0
2

(r, , ) R | 0 2, 0 , 0 r sin

0 1

= V =
T

r4 sin2 sin3 dr d d
0 0 0
2

dV

=
0 0 0

r2 sin dr d d = 1 sin4 d 3
0

4
2

1 5
0

sin3 d

= = =

2
0

1 1 2 3 sin 2 + sin 4 3 8 4 16 1 2 . 4

20
0

1 cos2 sin d cos + 1 cos3 3


2

20

=
0

. 30

11

CHAPTER 12. TRIPLE INTEGRALS [SHE 10 17.6 - 17.9] Example 12.14 A spherical planet of radius R has an atmosphere whose density varies as = 0 e ch where h is the altitude above the surface of the planet, 0 is the density at the planets surface and c is a positive constant. Determine the mass of the planets atmosphere. Solution: (cont.)

Example 12.15 Determine the mass and centre of mass of the solid that lies beneath the sphere x2 + y 2 + z 2 = z and above the cone z 2 = x2 + y 2 if its density varies proportional to the distance from the vertex of the cone. Solution:

12

CHAPTER 12. TRIPLE INTEGRALS [SHE 10 17.6 - 17.9] (cont.) (cont.)

13

CHAPTER 12. TRIPLE INTEGRALS [SHE 10 17.6 - 17.9] (cont.) (cont.)

14

Chapter 13

Change of Variables [SHE 10 17.10]


LECTURE 4
The previously studied polar, cylindrical polar and spherical polar co-ordinate substitutions are specic examples of the general substitution method for multiple integrals. Our attention will be focused in developing this general method for double integrals but is easily extended to triple and/or higher multiple integrals. Suppose that the region R in the uv-plane is transformed one-to-one into the region R in the xy-plane by equations of the form x = x(u, v), y = y(u, v) a function f (x(u, v), y(u, v)) dened on R . The next question is how the integral of f (x, y) over the region R is related to the integral of f (x(u, v), y(u, v)) over R ? f (x, y) dx dy =
R R (x,y) (u,v)

f (x(u, v), y(u, v))

(x, y) du dv (u, v)

where

is the Jacobian determinant (x, y) = (u, v)


x u y u x v y v

Example 13.1 For polar co-ordinates (x = r cos , y = r sin in R2 ) we have (x, y) = (r, ) Thus f (x, y) dx dy
R x r y r x y

cos sin

r sin = r. r cos

=
R

f (r cos , r sin ) |r| dr d f (r cos , r sin ) r dr d


R

= We call the region R the image of R under the transformation and the region R is the preimage of R. Hence any function f (x, y) dened on R can be thought of as 15

(if r 0) .

Note that the integral on the right hand side can be considered as the integral of f (r cos , r sin ) r over a region R in the cartesian r-plane.

CHAPTER 13. CHANGE OF VARIABLES [SHE 10 17.10] Example 13.2 Evaluate


R

(3x + 4y) dx dy where region R is bounded by y = x 2, y = 2x, y = 3 2x .

y = x,

R = (u, v) R2 | 0 u 2, 0 v 3 . The Jacobian determinant is given by (u, v) = (x, y)


u x v x u y v y

Solution: Consider the region R which is represented in the following diagram


y 2

1 2

1 =3 1

(x, y) 1 = . (u, v) 3

Thus we next wish to calculate the integral. Before doing so we need to rewrite the integrand 3x + 4y in terms of u and v. Thus u = x y, Hence
3 2

v = 2x + y

x -0.5 0.5 1 1.5 2 2.5 3 3.5

x=

1 (u + v), 3

y=

1 (v 2u) . 3

-1

(3x + 4y) dx dy
R
-2

=
0 0 3

1 1 (7v 5u) du dv 3 3 7vu 5 2 u 2


2

= The equations of the boundary suggest the following transformation u = x y, v = 2x + y . = = = =


2

1 9
0

dv
0

1 9
0

(14v 10) dv
3 0

Hence the region R is represented in the following diagram


v 3

2.5

1 7v 2 10v 9 1 (63 30) 9 11 . 3

1.5

Example 13.3 Evaluate lelogram bounded by


0.25 0.5 0.75 1 1.25 1.5 1.75 2 u

sin(x y) cos(x + 2y) dx dy where region R is the paralR

0.5

x y = 0, 16

x y = ,

x + 2y = 0,

x + 2y =

. 2

CHAPTER 13. CHANGE OF VARIABLES [SHE 10 17.10] Solution: Let u = x y and v = x + 2y. Thus the region R in the xy-plane
y 1

Thus

sin(x y) cos(x + 2y) dx dy


R
0.5 1 1.5 2 2.5 3 3.5 x

=
0 0

sin u cos v

-0.5

=
-1

=
-2

2 . 3

1 3

sin u du

1 dv du 3
2

cos v dv

-3

Example 13.4 Evaluate


e (xy) dx dy by integrating over the square re1 + (x + y)2

is the image of the region R in the uv-plane


v p 2

gion R = (x, y) R2 | a x a, a y a and then taking the limit as a . HINT : Set u = x y and v = x + y. Solution: If u = x y and v = x + y then the region R in the xy-plane
y

u p 2 p

R = (u, v) R2 | 0 u , 0 v The Jacobian determinant is given by

x -a a

-a

(u, v) = (x, y)

u x v x

u y v y

1 1

1 =3 2

1 (x, y) = . (u, v) 3 17

CHAPTER 13. CHANGE OF VARIABLES [SHE 10 17.10] is the image of the region R in the uv-plane
v 2a

Example 13.5 Calculate the area of the region R bounded by the curves x2 2xy + y 2 + x + y = 0 and x + y + 4 = 0. Solution: The rst curve can be rewritten as x2 2xy + y 2 + x + y = 0 (x y)2 + x + y = 0 . This suggests the transformation
u

-2a

2a

-2a

The Jacobian determinant is given by (u, v) = (x, y) Thus


a a u x v x u y v y

1 1

1 =2 1

1 (x, y) = . (u, v) 2

a aa

lim

e (xy) dx dy 1 + (x + y)2

2a u+2a

= 2 lim

a 0 u2a
2

e u 1 dv du 1 + v2 2

=
0

= = =

arctan v| 2 1 3 2 . 2

e u du

e u dv du 1 + v2
2

1 dv 1 + v2

18

CHAPTER 13. CHANGE OF VARIABLES [SHE 10 17.10] (cont.)

The generalisation to triple integrals is as follows f (x, y, z) dx dy dz =


T T

f (x(u, v, w), y(u, v, w), z(u, v, w))

(x, y, z) du dv dw . (u, v, w)

19

Chapter 14

Line Integrals and Greens Theorem [SHE 10 18.1 - 18.5, 18.8]


LECTURE 5
14.1 Line Integrals
The linear mass density (mass per unit length) is a function of position in space f (r(t)) = f (x(t), y(t), z(t)). Suppose we calculate the mass of the wire from t = a to t = b. To do this we partition the parameter interval [a, b] into n sub-intervals [ti1 , ti ], 1 i n, of length t such that t0 = a and tn = b and ti = ti1 + t. This divides the curve into n sub-curves. Consider one of these sub-curves. Then

We begin by considering a wire of variable density (mass/unit length). The problem of calculating the mass is easy if the wire has the form of a straight line along say the x-axis from a to b. Let the linear mass density be f (x). We partition the wire along [a, b] into n sub-intervals [xi1 , xi ], 1 i n, of length x such that x0 = a and xn = b and xi = xi1 + x. Then
n

Mass (m)

f (xi )x .
i=1

As the number of sub-intervals approaches , this Riemann sum approaches the integral of f , thus
b

m=
a

f (x) dx.

Suppose now that the wire is bent into a 3dimensional curve. To obtain the mass we must rst dene the curve. This is usually done parametrically by giving the components x, y, z as functions of parameter t. The curve is then given in a vector form as r(t) = x(t) i + y(t) j + z(t) k. 20

length of sub curve = =

Mass

f (r(ti )) (length of sub curve) [x(ti ) x(ti1 )]2 + [y(ti ) y(ti1 )]2 + [z(ti ) z(ti1 )]2 [x (ti )t]2 + [y (ti )t]2 + [z (ti )t]2 (x (ti ))2 + (y (ti ))2 + (z (ti ))2 t r (ti ) t .

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] Hence and so Mass f (r(ti )) r (ti ) t Mass of wire f (r(ti )) r (ti ) t

Therefore r (t) = i + 2j + 2k and r (t) = 3. Hence


1

Mass =
i C

f ds

=
0 1

f (r(t)) r (t) dt (t + (2t)2 + (2t)2 ) 3 dt

Finally taking the limits as number of sub-intervals approaches (or as t 0) the Riemann sum then approaches the integral and so
b

=
0

= 3

Mass of the wire =


a

f (r(t)) r (t) dt. Example 14.2 Calculate the line integral

8t3 t2 + 2 3

1 0

1 =9 . 2

This integral is called the line integral of the scalar eld or scalar function f along the curve C and is denoted by f ds.
C

xy ds z
C

Thus by denition
b

where C is the curve f ds =


C a

f (r(t)) r (t) dt .

r(t) = t i + t2 j + t2 k Solution:

from t = 0 to t = 1.

Example 14.1 A wire joins the points (0, 0, 0) to (1, 2, 2) in a straight line and has linear mass density f (x, y, z) = x + y 2 + z 2 . Calculate the mass. Solution: Our rst task is to determine the parametric equation for the curve. Since the curve is a straight line we can use the vector parameterisation of a curve. r(t) = r(0) + t v where r(0) =< 0, 0, 0 > and v =< 1 0, 2 0, 2 0 >=< 1, 2, 2 > with t : 0 1. Thus r(t) = t < 1, 2, 2 >= t i + 2t j + 2t k . 21

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] Notes: If we let f be the constant function 1 then the line integral rst gives the length of the curve, i.e., length =
C 2

The centre of mass of a wire shaped like a curve C, with linear density function (x, y, z) and mass m is located at the point (xm , ym , zm ), where xm ym zm where = = = 1 m 1 m 1 m
C

x(x, y, z) ds y(x, y, z) ds
C

ds.

For a curve in R we have the curve parametrised by x so we can write x = t, Then length =
C b

y = f (t).

z(x, y, z) ds
C

ds dx dt
2

m= dy dt
2 C

(x, y, z) ds .

=
a b

dt

Example 14.3 Determine the area of that portion of the surface x2 + y 2 = 9 that lies above the rst quadrant of the xy-plane and below the plane z = 3 x. Solution:
x 1 2 0

=
a

1 + (f (t))2 dt .

The distance along a curve from some given point on it is usually denoted by s and then we say that for the curve r(t) the line segment (or element of length) is given by ds = r (t) dt. If t represents time as a particle moves along the curve r(t) then it can be shown that r (t) is the velocity of the particle at r(t). We have r(t + h) r(t) , r (t) = lim h0 h i.e., a limit of position/time. Then r (t) is tangent to the curve and the magnitude of the velocity is r (t) . The lineelement ds = r (t) dt then says in rough intuitive terms distance travelled = speed time. 22
z

3 3

0 0 1 2 y 3

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] (cont.)

14.1.1

Hyperbolic Functions and their Inverses [SHE 10 7.8 7.9]


ex + ex 2 ex ex sinh x 2 sinh x tanh x cosh x

Denition 14.1 Let x be a real number. The hyperbolic functions are given by cosh x hyperbolic cosine, hyperbolic sine, hyperbolic tangent.

Example 14.4 Show that cosh2 x sinh2 x = 1. Solution:

Example 14.5 Determine the derivatives of cosh x and sinh x. Solution: d cosh x = dx d sinh x = dx d dx d dx ex + ex 2 ex ex 2 ex ex = sinh x, 2 ex + ex = = cosh x . 2 =

23

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] Denition 14.2 Eulers Formula is given by e where = 1. Example 14.6 Using the denition of the hyperbolic cosine and hyperbolic sine respectively we have cosh sinh = = cos + sin + cos sin e + e = = cos , 2 2 cos + sin cos + sin e e = = sin . 2 2

LECTURE 6
There is a second type of line integral which is important. Consider the problem of computing the work done by a position dependent (varies with position) force F(r) as it acts on a particle that moves along a curve. Again we have the curve specied parametrically by a vector function r(t) = x(t) i + y(t) j + z(t) k. The force however is now a vector function of position and so F(r) is a function of x, y, z which we write as F(x, y, z) or F(r) . Such a function is called a vector eld or vector function. For example, if F(x, y, z) = yz i + xz j + xy k

= cos + sin

Example 14.7 Find the length of the catenary r(t) = t i + cosh t j from t = 0 to t = 1.
2 1.8 1.6

1.4

1.2

0.8

0.6 0.2 0.4 0.6 0.8 1

Solution: Thus Hence


1

r (t) = i + sinh t j .
1 1

then cosh2 t dt F(1, 2, 2) = 4 i + 2 j + 2 k and F(1, 0, 2) = 2 j . In eect each point in space has a vector representing force assigned to it. Other examples are of vector elds are the electric eld, gravitational eld and the velocity eld in a uid. Our problem now is as follows. A particle moves along the curve r(t) in a force eld F(r). What is the work done by the force on the particle? Suppose we calculate the work done from t = a to t = b. To do this we divide the interval [a, b] into n sub-intervals [ti1 , ti ], 1 i n, of length t such that t0 = a and tn = b and ti = ti1 + t. 24

=
0

r (t) dt =

1 + sinh2 t dt
0

=
0 1

=
0

cosh t dt sinh 1 .

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] This divides the curve into n sub-curves. This is a Riemann sum of the function F(r(ti )) r (ti ) and so as number of sub-intervals , this approaches the integral
b

W =
a

F(r(t)) r (t) dt.

This integral is called the line integral of the vector eld F along the curve C and is denoted by
C

F dr.

Thus by denition
b

F dr =

F(r(t)) r (t) dt .

Example 14.8 Find the work done when the particle is moved along the curve r(t) = t i + t2 j + t2 k from (0, 0, 0) to (2, 4, 4) under the force F(x, y, z) = yz i + xz j + xy k . Solution: Now r (t) = i + 2t j + 2t k , t F(r(t)) = 4 i + 3 j + t3 k , t F(r(t)) r (t) = t4 + 2t4 2t4 = 5t4 . + Also (0, 0, 0) is t = 0 and (2, 4, 4) is t = 2. Thus
2

Consider the ith sub-curve, then work done, Wi , as the particle moves along the ith sub-curve is approximately F(r(ti )) (r(ti ) r(ti1 )) F(r(ti )) r (ti ) t . Summing over all sub-curves yields W F(r(ti )) r (ti ) t . Wi

Work =
C

F dr = =

0 2

F(r(t)) r (t) dt 5t4 dt

t5

2 0

= 32 .

25

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] There are several alternative ways of writing the line integral of a vector eld. First it can be written as the line integral of a scalar function, that is, a line integral of the rst type. This uses the fact that r (t) is a tangent to the curve and so if we denote the unit tangent vector by T(r(t)) then r (t) T(r(t)) r (t) = . r (t) Thus
b

In the previous example this gives


2

Fx dx =
C 0

t4 1 dt =

32 . 5

Example 14.9 Calculate xy = 1, 1 x 3.


C

F dr where F = xy i + (y x2 ) j and C is the curve

F dr = =

a b

F(r(t)) r (t) dt r (t) F(r(t)) r (t) r (t) dt

Solution:

a b

=
a

F(r(t)) T(r(t)) r (t) dt F T ds Ft ds.

=
C

=
C

where Ft F T is the tangential component of F along curve C. This notation however makes no contribution to calculating the integral. Let F(r(t)) = Fx i+Fy j+Fz k, then the second form of line integral is to write formally dr = dx i + dy j + dz k so that F dr = (Fx dx + Fy dy + Fz dz) .
C C

These integrals can be calculated separately using the parametric form. For example
b

Fx dx =
C a

Fx (r(t)) x (t) dt . 26

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] Example 14.10 Let F be the vector eld shown in the gure below. If C is quarter circle from (1, 0) to (0, 1) determine if F dr is positive, negative or zero.
C

There is an important relationship between line integrals and gradients. Let f be a scalar valued function of three variables. Then the gradient of f , f grad f , is a vector valued function of three variables, i.e., a vector eld. For example, f (x, y, z) = xyz

then f (x, y, z) =
0.8

f f f j+ i+ k = yz i + xz j + xy k. x y z

Now consider the line integral

f dr where C is the curve r(t) from t = a to t = b. C Let g(t) = f (x(t), y(t), z(t)). Then by the chain rule

0.6

0.4

0.2

0.2

0.4

0.6

0.8

Solution:

27

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] Thus,
b

then + r = q 3 r q = r. r 2 Thus, E = . Thus the electric eld is conservative and work done in moving a charge around in an electric eld is independent of path. In fact it is simply the dierence in potential evaluated at the nal and initial points. Thus if we move charge e from A to B in the electric eld of charge q then Work = f (x) dx = f (b) f (a) .
C

f dr = =

a b

f (r(t)) r (t) dt d (f (r(t))) dt dt

(x2

y2

y z x i+ 2 j+ 2 k 2 )3/2 2 + z 2 )3/2 2 + z 2 )3/2 +z (x + y (x + y

= =

f (r(t))|b a f (r(b)) f (r(a)).

This result is the vector analogue of the fundamental theorem of calculus


b

F dr = = = =

e E dr dr

e
C

LECTURE 7
Notes: There is a very important consequence of this result. The value of the integral depends only on the value of f at the end-points of the curve. It is independent of the actual shape of the curve between the two endpoints! From a physical viewpoint this means that if a force is given by a gradient of a scalar function, then the work done in going from one point to another is independent of the path. A force eld which is the gradient of a scalar function is called a conservative eld or gradient eld and the scalar function is called a potential for the eld. Many force elds are conservative. For example, the electric eld of a charge q is given by q E(r) = r Let q = (r) = r q x2 + y 2 + z 2 28 (where is the unit vector in the direction of r) . r, r

e ((rB ) (rA )) e ((rA (rB . ) ))

The - sign in E = means that the potential is larger the nearer we are to a positive charge. Thus if rA < rB means that the eld does work on the charge e if the charge e is positive. Another way of stating the fact that work done is independent of path for a conservative force eld is that for such a vector eld the integral around a closed path is zero. If the curve is closed then r(a) = r(b) and so f dr = f (r(b)) f (r(a)) = 0.

For simple closed curves we use the notation notation in complex variables.
C

. This is an especially common

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] Given a vector eld F(r) there are various criteria which tell us whether it is conservative, i.e., whether it can be written as f , and various methods for nding the function f , the potential, if it is conservative. We defer the most expedient method till later when we have discuss the concept of curl. We have proved that if F is conservative, i.e., F = f , then Fdr is independent C of path and depends only on end points. It can be shown that the converse is also true: If
C

(cont.)

F dr is independent of path, then F is conservative.

Example 14.11 Find a potential function f for the conservative vector eld F(x, y) = (6xy y 3 ) i + (4y + 3x2 3xy 2 ) j . Solution: Because we are given that F is a conservative eld, the line integral F T ds is independent of path. Let C be the straight-line path from A(0, 0) to C B(x1 , y1 ) parametrised by x = x1 t, y = y1 t with 0 t 1.

29

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] Example 14.12 Calculate the work done by the force F = 3x i + y j along the straight line segment from (2, 2) to (2, 2). Solution: ways We need to parametrise the curve. Let us parametrise the curve in two t i + 2 j t : 2 2 , t i + j t : 2 2 . 2 using the rst parameterisation is
2

We now wish to further investigate the importance of the concept that the parametrised curve is an oriented curve. The curve is a succession of points traversed in a certain order. Consider the following curves r = r(t) t : a b , R(s) = r(a + b s) s : a b . Both vector functions trace out the same set of points but the rst curve starts at r(a) and nishes at r(b) whereas the second curve starts at r(b) and ends at r(a): R(a) = r(a + b a) = r(b) , R(b) = r(a + b b) = r(a) . Example 14.13 The vector function r(t) = cos t i + sin t j t : 0 2 is a parameterisation of the unit circle traversed counter-clockwise when viewed from above whereas = cos(2 s) i + sin(2 s) j s : 0 2 cos s i sin j s : 0 2 s is a parameterisation of the unit circle traversed clockwise when view from above. R(s)

r1 (t) = r2 (t) = Thus the work done along the curve F dr1 =

(3t i + 2 j) (i + 0 j) dt
2

3t dt .

Similarly the work done along the curve for the second parameterisation is
2

F dr2

=
2 2

(3t i + 2 j) (i + 0 j) dt 3t dt .

=
2

14.2

Curl and Divergence

Note that the integrals are opposite but the work done should be independent of the parameterisation of the curve. This is not a paradox since the answer to both integrals is zero. What we should note is that dierent parameterisation can lead to a dierent integral but the value of the line integral should be the same independent of parameterisation.

In physical applications such as particle mechanics, uid mechanics and electromagnetic theory, other notions of the derivative of a vector eld besides the total derivative are useful. In particular, for a given vector eld F on a subset of R2 (or later R3 ), we can calculate the divergence and curl of F. Imagine a bath tub full of water and the plug has just been pulled. Water is now draining through the sink which has a certain cross sectional area. We would expect that there must be some relationship between the rate at which water crosses the area of the sink and the change in volume of the water in the bath. Also after a while the uid starts to rotate around the sink and eventually forms a twister. Is there a relationship between the rotation of the uid and the ow across the sink? To simplify our discussion we rst consider vector elds in R2 . Later we will extend the ideas developed in R2 to R3 . Consider the motion of uid in a planar region. This can be represented by a velocity eld of the uid motion. We wish to investigate the relationship of the movement of 30

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] uid around or across the boundary of the region with the motion inside the region. We rst dene two quantities. Denition 14.3 If C is a smooth curve in R2 (parametrised by r(t)) in the domain of the vector eld F then the ow along the curve C is the line integral of F T: ow =
C

(x, y + y)

(x + x, y + y)

F T ds .
(x, y) (x + x, y)

The integral in this case is called a ow integral. If the curve is closed then the ow is called the circulation around the closed curve. Denition 14.4 If C is a smooth curve in R2 (parametrised by r(t)) in the domain of the vector eld F and if n is the outward pointing unit normal vector to C then the ux of F across curve C is line integral of F n: the ux of F across C = Notes: The outward pointing unit normal vector to the curve C can be derived by taking the cross product of T and the unit vector in the z direction k. The choice of T k or k T depends on the orientation of the curve C as viewed from above: Tk counter clockwise, kT clockwise. The word ux is latin for ow. We should note however that many ux calculations do not involve motion, e.g., electric or magnetic eld. Though it is useful for visualisation of these and upcoming concepts to consider the velocity eld of a uid ow. Let F(x, y) = P (x, y) i + Q(x, y) j be the velocity eld of a uid ow in the plane and let the rst order partial derivatives of P and Q be continuous at each point in the region R. Let (x, y) be a point in the region R and A be a small rectangular region with the bottom left hand corner at (x, y). The rectangular region has sides of length x and y. 31 F n ds .

We wish to consider the net ux of uid across (through) this rectangular region A, i.e., F n ds. The rate which uid leaves the rectangular region across the bottom C edge is approximately given by x x F(x + , y) (j) x = Q(x + , y) x . 2 2 This is the component of the uid velocity at (x, y) in the direction of the outward normal times the length of the side (compare with F n ds). Note over the side (x, y) C to (x + x, y) the vector eld F in general would vary. We have taken the value of F at the position (x + x , y) as the value of F for all positions between (x, y) and 2 + x, y). (x

LECTURE 8
Thus for all four sides we have Top Bottom Left Right x x , y + y) j x = Q(x + , y + y) x F(x + 2 2 x x F(x + , y) (j) x = Q(x + , y) x 2 2 y y ) (i) y = P (x, y + ) y F(x, y + 2 2 y y ) i y = P (x + x, y + ) y F(x + x, y + 2 2

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] Considering opposite sides we have Top & Bottom Q(x + x x , y + y) Q(x + , y) x 2 2 Q y x y y y P (x + x, y + ) P (x, y + ) y 2 2 P x y x Example 14.14 Determine if the following vector elds are ux free by considering
C

F n ds for an arbitrary closed path C.


1

Right & Left

0.5

Adding yields the total ux across the rectangular region A boundary, i.e., ux (
C

-1

-0.5

0.5

F n ds)

Q P + x y

x y .
-0.5

If we divide by the area of the rectangular region A, x y, we obtain the ux per unit area, i.e., P Q ux + . area x y If we let both x 0 and y 0 this yields the ux density or divergence of F at (x, y). Denition 14.5 The ux density or divergence of a vector eld F = Fx (x, y) i + Fy (x, y) j at the point (x, y) is given by Fx Fy div F F = + . x y In the context of uid ow the divergence represents the instantaneous rate of uid ow outward at each point in the uid.
-0.5 0.5

-1

-1

-0.5

0.5

-1

32

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8]
1

Next we wish to consider the net circulation of uid counter clockwise around the boundary of the rectangular region A, i.e., F T ds.
C

0.5

(x, y + y)

(x + x, y + y)

-1

-0.5

0.5

-0.5

-1

(x, y)

(x + x, y)

The rate which uid ows along the bottom edge (left to right) of the rectangular region is approximately given by
1

x x F(x + , y) i x = P (x + , y) x . 2 2
0.5

-1

-0.5

0.5

This is the component of the uid velocity at (x, y) in the direction of the tangent to the boundary times the length of the side (compare with F T ds). Thus for all four C sides we have x x , y + y) (i) x = P (x + , y + y) x F(x + 2 2 x x F(x + , y) i x = P (x + , y) x 2 2 y y ) (j) y = Q(x, y + ) y F(x, y + 2 2 y y ) j y = Q(x + x, y + ) y F(x + x, y + 2 2

-0.5

Top Bottom

-1

Left Right 33

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] Considering opposite sides we have Top & Bottom x x , y + y) P (x + , y) x 2 2 P y x y y y Q(x + x, y + ) Q(x, y + ) y 2 2 Q x y x P (x + Example 14.15 Determine if the following vector elds are circulation free by considering
C

F T ds for an arbitrary closed path C.


1

Right & Left

0.5

Adding yields the total circulation around the rectangular region A boundary. circulation (
C

-1

-0.5

0.5

F T ds)

Q P x y

x y .
-0.5

If we divide by the area of the rectangular region A, x y, we obtain the circulation per unit area, i.e., Q P circulation . area x y If we let both x 0 and y 0 this yields the circulation density or curl of F at (x, y). Denition 14.6 The circulation density or curl of a vector eld F = Fx (x, y) i + Fy (x, y) j at the point (x, y) is given by Fy Fx curl F F = k. x y In the context of uid ow the curl measures the amount of rotation undergone by microscopic parts of the uid.
-0.5 0.5

-1

-1

-0.5

0.5

LECTURE 9
-1

34

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8]

14.3
1

Greens Theorem in the Plane

0.5

Theorem 14.1 (Greens Theorem in the Plane) Let R be a closed bounded region in the x, y plane whose boundary C consists of a nite number of smooth curves. Let P (x, y) and Q(x, y) be functions that are continuous and have continuous rst order partial derivatives P and Q everywhere in some domain containing R. Then y x Q P x y dA
R

Q P x y

dx dy
C

(P dx + Q dy)

-1

-0.5

0.5

where C is the entire boundary of R taken in the sense that R is on the left of C.
-0.5

Notes: Writing F =< P, Q > then

-1

curl F k dx dy

( F) k dx dy =

F T ds

F dr .

This is known as the circulation-curl or tangential form of Greens Theorem in the Plane.
1

Writing F =< Q, P > then


R

div F dx dy

0.5

F dx dy =

F n ds

where n is the outward pointing unit normal to C. This is known as the ux divergence or normal form of Greens Theorem in the Plane.
-1 -0.5 0.5 1

For a formal proof of Greens Theorem in the Plane see SHE.

-0.5

-1

35

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] How can two dierent vector elds give the same result for the line integral Example 14.16 Verify the circulation-curl and ux-divergence forms of Greens Theorem in the Plane for the vector eld F(x, y) = (x y) i + x j and the region R bounded by the unit circle C Solution: Thus r(t) = cos t i + sin t j 0 t 2 .

div F F = Heuristic argument for circulation-curl form Also F (r(t)) r (t) r (t) r (t) T = r (t) n=Tk Heuristic argument for ux-divergence form curl F F =

Fx Fy + = 1+0 = 1, x y Fx Fy k = (1 ( 1)) k = 2 k . x y

= (cos t sin t) i + cos t j , = sin t i + cos t j , = , = sin t i + cos t j , i j k = sin t cos t 0 0 0 1 T (t) = cos t i + sin t j . T (t)

Thus
2

F T ds

=
0 2

((cos t sin t) i + cos t j) ( sin t i + cos t j) r (t) dt (1 sin t cos t) dt

=
0

= 2 36

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] and ( F) k dx dy =
R

LECTURE 10
R

2 k k dx dy dx dy
R

Example 14.17 Verify Greens Theorem in the Plane for


C

(xy +y 2 ) dx+x2 dy where

= 2

C is the positively oriented boundary of the region bounded by the curves y = x and y = x2 . Solution:

= 2 . Hence we have veried ( F) k dx dy =

= 2 (area of unit circle)

F T ds .

Also
2

F n ds

=
0 2

((cos t sin t) i + cos t j) (cos t i + sin t j) r (t) dt cos2 t dt

=
0

= and

F dx dy

= = =
R

dx dy area of unit circle .

Hence we have also veried F dx dy = F n ds .

37

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] (cont.) Example 14.18 Evaluate
C

(x2 2xy) dx + (x2 y + 3) dy where C is the positively

oriented boundary of the region contained by y 2 = 8x and x = 2 using Greens Theorem in the Plane. Solution:

38

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] Example 14.19 Show that Greens Theorem in the Plane leads to the following for1 mula for the plane area A = x dy y dx (x dy y dx). 2
C C C

Example 14.21 Show that the area formula A = A=


C

1 2
C

(x dy y dx) leads to

Solution: Greens Theorem in the Plane states Q P x y


R

1 2 r d in polar co-ordinates. 2

[Hint: x(r, ) = r cos , y(r, ) = r sin ] (P dx + Q dy) .


C

dA
R

Q P x y

dx dy =

Solution: Convert Cartesian expression to one in plane polar co-ordinates: x = dx = y dy = = r cos dr cos r sin d

Set Q = x and P 0 then Q P x y


R

dx dy

= = =
C

1 dx dy A
R

r sin dr sin + r cos d

Substituting into the Cartesian form for the area yields x dy . A = = = 1 2 1 2


C

(x dy y dx) r cos (dr sin + r cos d) r sin (dr cos r sin d)


C

Similarly for the second version set Q 0 and P = y. By adding the two results and dividing by two we obtain the third version.

Example 14.20 Use A =


C

x dy to nd the area of an ellipse

x2 y2 + 2 = 1. a2 b

1 2 r d . 2

Solution: We parametrise the positively oriented curve C, which is the boundary of the ellipse, such that x y = a cos t = b sin t

Example 14.22 Evaluate the line integral y 2 dx + 3xy dy


C

where 0 t 2. Thus the area A of an ellipse is given by


2 2

where C is the positively oriented boundary of the semi-annular region R in the upper half plane between the circles x2 + y 2 = 1 and x2 + y 2 = 9. Solution:

A=
C

x dy =
0

(a cos t) (b cos t dt) = a b


0

cos2 t dt = a b .

39

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] (cont.)

LECTURE 11
Theorem 14.2 (Greens Theorem in the Plane (2 curve case)) Let R be a closed bounded region in the x, y plane which is bounded by the curves C1 and C2 which consist of a nite number of smooth curves. Let P (x, y) and Q(x, y) be funcP and tions that are continuous and have continuous rst order partial derivatives y Q everywhere in some domain containing R. Then x Q P x y
R

dA =
C1

(P dx + Q dy) +
C2

(P dx + Q dy)

where C1 and C2 are positively oriented, i.e., taken in the sense that R is on the left of C1 and C2 . Notes: Writing F =< P, Q > then
R

curl F k dA =

C1

F T ds +

C2

F T ds .

This is the circulation-curl or tangential form of Greens Theorem in the Plane (2 curve case).

40

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] Writing F =< Q, P > then
R

div F dA =

C1

F n ds +

C2

F n ds

x y i+ j, show that F dr = 2 for every Example 14.23 If F = 2 x + y 2 x2 + y 2 C simple positively oriented closed path C that encloses the origin. Solution:

where n is the outward pointing unit normal to R. This is the ux-divergence or normal form of Greens Theorem in the Plane (2 curve case).

41

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] (cont.)

14.4

Conservative Vector Fields (revisited)

Denition 14.7 The ux density or divergence of a vector eld F = Fx (x, y, z) i+ Fy (x, y, z) j + Fz (x, y, z) k at the point (x, y, z) is given by Fx Fy Fz div F F = Fx , Fy , Fz = , , + + . x y z x y z Denition 14.8 The circulation density or curl of a vector eld F = Fx (x, y, z) i+ Fy (x, y, z) j + Fz (x, y, z) k at the point (x, y, z) is given by curl F F i j k = x y z Fx = Fy Fz i+ Fx Fz z x Fy Fx x y k.

j+ r . Example 14.24 Determine the divergence of F(r) = r Solution: F(r) = =


2

Fz Fy y z

x x2 + y 2 + z 2 y +z
2
3 2

y x2 + y 2 + z 2 z +x
2 2
3 2

z x2 + y 2 + z 2 x2 + y 2 (x2 + y 2 + z 2 ) 2
3

-2

-1

=
-1

(x2 + y 2 + z 2 ) 2

(x2 + y 2 + z 2 ) 2 = . 2 + y2 + z 2 r x

-2

42

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] Example 14.25 Find a formula for div (f (r) F(r)). Solution: We expect a formula that is similar to the product formula. A reasonable guess is div (f F) (f F) = f F + f F . To check this we set F =< Fx , Fy , Fz >. Hence (f Fx ) (f Fy ) (f Fz ) (f F) = + + x y z Fx f Fy f Fz f Fx + f + Fy + f + Fz + f = x x y y z z Fx Fy Fz f f f < Fx , Fy , Fz > +f , , + + = x y z x y z = f F + f F . Denition 14.10 The rst order dierential form F dr = Fx dx + Fy dy + Fz dz is exact, or is an exact dierential in a domain D, if it isthe dierential of a dierentiable function f (x, y, z) in D, i.e., if F = f , i.e., if F is conservative. Denition 14.11 A domain D is simply connected if every closed curve in D can be continuously shrunk to a point in D without leaving D.

LECTURE 12
14.4.1 Independence of Path in Line Integrals
F dr is independent of path in a domain D then for any two F dr = F dr where C1 , C2 are any two paths in D from A Denition 14.9 If
C

points A and B in D, to B.
C1

C2

F dr, with F with continuous rst order partial C derivatives in domain D, is independent of path in D if and only if F = f for some function f in D. That is, a potential f exists for F. Theorem 14.4 F dr is independent of path in D if and only if it is zero on every simple closed path in D.
C

Theorem 14.3 The line integral

Theorem 14.5 (Test for Independence of Path) If F has continuous rst order partial derivatives in a simply connected domain D then F dr is independent of C path if and only if curl F = 0 in D, i.e., F = f in D if and only if curl F = 0 in D. 43

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] Example 14.26 Show that the vector eld F = (ex cos y) i(ex sin y) j+z k is conser vative in R3 , i.e., curl F = 0. Hence determine a scalar potential for F, i.e., F = f . Solution: i x ex cos y j y ex sin y k z z Example 14.27 Find a potential function for the conservative vector eld F(x, y) = (6xy y 3 ) i + (4y + 3x2 3xy 2 ) j. in a simply connected domain of R2 . Solution:

curl F =

= (0 0) i + (0 0) j + ( ex sin y + ex sin y) k = 0. Thus the vector eld is conservative in R3 . A potential f for a conservative vector eld F satises F = f which can be written in component form: f Fx = ex cos y = f (x, y, z) = ex cos y + g(y, z) x Fy = ex sin y = Fz = z = f y f z

44

y x Example 14.28 Show that the vector eld F = 2 i+ j is conservative x + y 2 x2 + y 2 2 in a simply connected domain excluding the origin in R . Hence determine a scalar x 1 dx = arctan ] potential for F, i.e., F = f . [Hint: x2 + a2 a a Solution: i x = = y x2 + y 2 j y x x2 + y 2 k z 0 x2 + y 2 2x2 x2 + y 2 2y 2 + 2 + y 2 )2 (x (x2 + y 2 )2 k

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8] (cont.)

curl F =

(0 0) i + (0 0) j + 0 ((x, y) = (0, 0)) .

Thus conservative in a simply connected domain excluding the origin in R2 . A potential f for a conservative vector eld F satises F = f which can be written in component form: Fx Fy = = f y = x2 + y 2 x

x f = x2 + y 2 y

45

CHAPTER 14. LINE INTEGRALS AND GREENS THEOREM [SHE 10 18.1 - 18.5, 18.8]

14.4.2

Physical Interpretation of Divergence and Curl in R3

Example 14.29 Consider a cloud of dust particles is moving so that the velocity of a particle passing through the point (x, y, z) is given by v(x, y, z) dx dy dz , , dt dt dt =< ax, by, cz >

clockwise as viewed from the positive z-axis. The position of a dust particle at time t initially at (x, y, z) is given by P(t) =< x cos t y sin t, x sin t + y cos t, z > . Hence the velocity eld at (x, y, z) is v = P (0) =< y, x, 0 > . Now notice that curl v = (0, 0, 2) which is a vector parallel to the z-axis with magni tude twice the angular speed . Since the z-axis is also along the axis of rotation we see that the curl in this case is twice the angular velocity. In general, if F on R3 is the velocity eld of a uid, then curl F evaluated at the point x provides a measure of the angular velocity of a microscopic portion of the uid centred at x; its direction is along the axis of this rotation. For this reason, a vector eld whose curl is zero is called irrotational. Given a twice dierentiable scalar function on a subset U R3 we can calculate grad to obtain a vector eld and then we can calculate div () to obtain a scalar function again. This last function is the Laplacian of . We note Laplacian 2 = 2 2 2 + 2 + 2. x2 y z

and a, b, c R are constants. We wish to measure the time rate of change in the volume of a region about the origin occupied by a portion of the dust cloud. For convenience we will take the portion to be a small cube centred at the origin. A particle initially at (x, y, z) will be at position P(t) = xeat , yebt , zect after t time units. In particular consider all the dust particles that initially occupied a cube of side length s that is centred at the origin. Since the transformation P is linear, after t units of time, the dust will occupy a rectangular solid with side of lengths seat , sebt , sect . The volume of this solid is thus s3 e(a+b+c) t . Hence the average rate of change in the volume occupied by the dust over time 0 to t is s3 e(a+b+c) t s3 . t The instantaneous rate of change of this volume will be the limit as t 0 of the above expression: s3 e(a+b+c) t s3 = s3 (a + b + c) . t0 t lim Hence the instantaneous rate of change in the volume, per unit volume, is a + b + c = div v. When a+b+c > 0 the volume is expanding and so, on average, the dust particles are moving outward or diverging from the origin. In general, if F on R3 is the velocity eld of a uid, then div F evaluated at the point x measures the instantaneous rate of expansion (or compression) per unit volume in a microscopic portion of the uid centred at x. For this reason, if F satises div F = 0, then F is called incompressible. Example 14.30 Consider again a cloud of dust particles each of which follows a circular path centred on the z-axis and lying in a plane perpendicular to the z-axis. Suppose the angular velocity is a constant positive value of so that the rotation is counter 46

A scalar function whose Laplacian is zero is called harmonic. For example, the temperature distribution through a solid that is in thermal equilibrium is a harmonic function.

Chapter 15

Parameterisation of Surfaces, Surface Integrals [SHE 10 18.7]


LECTURE 13
Previously we have dened curves in the plane in three possible ways: Explicit form Implicit form Parametric vector form y = f (x), e.g., y = x F (x, y) = 0, e.g., x2 + y 2 a2 = 0 atb
2

Example 15.1 Determine a vector parametric representation of the plane x + y + z = 1. Solution: The form of the plane x + y + z = 1 means that we can independently pick x and y and the equation of the plane determines z. Hence x = y = z Thus
2 2

r(t) = x(t) i + y(t) j, In an analogous way we have for surfaces in space Explicit form Implicit form z = f (x, y), e.g., z = x + y
2 2

u v 1uv.

F (x, y, z) = 0, e.g., x + y + z a = 0

There is also a vector parametric form that locates the position on a surface as a vector function of two variables. Given a function r : R R2 R3 , we dene the surface parametrised by r to be the set of points S = r(u, v) | (u, v) R}. The equation { r(u, v) = x(u, v) i + y(u, v) j + z(u, v) k where (u, v) R is a parameterisation of S. This means given a point (u, v) you obtain a vector r(u, v) or if we write r(u, v) as OP , given parameters (u, v), we obtain a point P in 3D space. As (u, v) runs over R, P moves about to yield a surface S. A surface is simple if it has a parameterisation given by a one-to-one function. It is possible for a surface to be both smooth and simple. Note that a given surface does not necessarily have a unique parameterisation. 47

r(u, v) = u i + v j + (1 u v) k,

u, v R .

For surfaces given explicitly by z = f (x, y), i.e., as the graph of a function f with continuous partial derivatives in R of the xy-plane, a parameterisation of such surfaces is given by r(x, y) = x i + y j + f (x, y) k such that (x, y) R R2 . Example 15.2 Determine two distinct parameterisation of the upper half unit sphere centred at the origin.

CHAPTER 15. PARAMETERISATION OF SURFACES, SURFACE INTEGRALS [SHE 10 18.7] Solution: By taking x, y as parameters, the surface can be parametrised by r(x, y) = x i + y j + 1 x2 y 2 k 2 y 2 , 1 x 1. 1x such that 1 x Another possible way to parametrise the surface is to use spherical polar co-ordinates:
z

S r (t 1 ) r (t2 ) r (t 3 )

r
y

x(, ) y(, ) z(, ) Thus

= = =

1 cos sin 1 sin sin 1 cos

Theorem 15.1 (Tangent Plane and Surface Normal) If a surface S has the parametric specication r(u, v) = x(u, v) i + y(u, v) j + z(u, v) k with continuous ru , rv which satisfy ru rv = 0 at every point S, then has at every point P : of S (a) a unique tangent plane passing through P and spanned by ru and rv , and (b) a normal direction N = (ru rv ) whose direction depends continuously on the points of S. Such a surface S is called a smooth surface. S is called piecewise smooth if it consists of a nite number of smooth sections. Example 15.3 Determine a normal to the plane in Ex 15.1.

r(, ) = cos sin i + sin sin j + cos k ,

0 2, 0

. 2

Solution: From Ex 15.1 we have r(u, v) = u i + v j + (1 u v) k, u, v R .

Thus Denition 15.1 For surface S given by r(u, v) where u = u(t) and v = v(t) are continuous functions of t, we can dene a curve C with r(u, v) = r(u(t), v(t)) = r(t) say, with tangent d r du r dv = r(t) + = ru u + rv v dt u dt v dt and a local normal to surface S is N = ru rv , provided N = 0. 48

Therefore

ru = i k , rv = j k . i N = ru rv = 1 0 j 0 1 k 1 = i+j+k. 1

CHAPTER 15. PARAMETERISATION OF SURFACES, SURFACE INTEGRALS [SHE 10 18.7] Example 15.4 Determine a normal to the sphere in Ex 15.2.

Solution: From Ex 15.2 we have r(, ) = cos sin i + sin sin j + cos k , To determine N we must rst determine r and r : r r Hence N = r r i cos cos = This patch on the surface (grey patch) is approximately the parallelogram with sides given by j sin cos k sin 0 r OP OP = r(u + u, v) r(u, v) u = ru u u and r OP OP = r(u, v + v) r(u, v) v = rv v v since for small u and v the grey patch Suv is at and well approximated by the dashed rectangle. We recall that the area of a parallelogram is given by Suv ru u rv v = ru rv u v . Thus if we partition the region R in the uv-plane into rectangular regions Auv this creates a partition for the surface S into surface area elements Suv . Denition 15.2 The area of the piecewise smooth surface S with parameterisation r(u, v) = x(u, v) i + y(u, v) j + z(u, v) k is given by dS = ru rv du dv N(u, v) du dv .
S R R

0 2, 0 . 2

= sin sin i + cos sin j + 0 k , = cos cos i + sin cos j sin k .

P 1111111111111111111111111 0000000000000000000000000 111111111111111111111111 000000000000000000000000 1111111111111111111111111 0000000000000000000000000 111111111111111111111111 000000000000000000000000 1111111111111111111111111 0000000000000000000000000 111111111111111111111111 000000000000000000000000 1111111111111111111111111 0000000000000000000000000 111111111111111111111111 000000000000000000000000 1111111111111111111111111 0000000000000000000000000u ru 111111111111111111111111 000000000000000000000000 1111111 0000000 1111111111111111111111111 0000000000000000000000000 111111111111111111111111 000000000000000000000000 1111111 0000000 11111111 00000000 111111111111111111111111 000000000000000000000000 v rv 1111111 0000000 11111111 00000000 111111111111111111111111 000000000000000000000000 111111111111111111 000000000000000000 1111111 0000000 1111111 0000000 11111111 00000000 111111111111111111111111 000000000000000000000000 111111111111111111 000000000000000000 1111111 0000000 111111111111111111111111 000000000000000000000000 111111111111111111 000000000000000000 1111111 0000000 P 111111111111111111111111 000000000000000000000000 111111111111111111 000000000000000000 1111111 0000000 111111111111111111111111 000000000000000000000000 111111111111111111 000000000000000000 1111111 0000000 111111111111111111111111 000000000000000000000000 P" 111111111111111111 000000000000000000 1111111 0000000 111111111111111111111111 000000000000000000000000 111111111111111111 000000000000000000 1111111 0000000 111111111111111111111111 000000000000000000000000 111111111111111111 000000000000000000 111111111111111111111111 000000000000000000000000 111111111111111111111111 000000000000000000000000 111111111111111111111111 000000000000000000000000 111111111111111111111111 000000000000000000000000 P*

cos sin i + sin sin j + cos sin k .

sin sin cos sin


2 2

Consider a small rectangle Auv in R with corners (u, v), (u + u, v), (u + u, v + v) and (u, v + v) is mapped under r(u, v) to the small patch Suv = P P P P on the surface S such that OP = r(u, v) ; OP = r(u + u, v) OP = r(u, v + v) ; OP = r(u + u, v + v) 49

CHAPTER 15. PARAMETERISATION OF SURFACES, SURFACE INTEGRALS [SHE 10 18.7] Example 15.5 Find the surface area of a sphere centred at the origin and radius a. Solution: From Ex 15.4 we found the normal to a unit sphere. The normal to a sphere of radius a is given by cos sin i + sin sin j + cos sin k . To determine the surface area by using the formula N(, ) d d we must de R termine N(, ) . Now N(, ) = a2 (cos sin2 )2 + (sin sin2 )2 + (cos sin )2 = a2 sin4 + cos2 sin2 = a2 sin . N = a Hence
=2 = 2 2 2

Denition 15.3 The area of the piecewise smooth surface S dened by the graph z = f (x, y) is given by dS =
S R 2 2 fx + fy + 1 dx dy

where R is the projection of S onto the xy-plane. Example 15.6 Determine the area of that part of the plane 2x + 7y + z = 10 lying over the region R = (x, y) R2 | 0 x 1, 0 y 1 . Solution:

10

N(, ) d d

=
=0 =0

a2 sin d d
z

= 2a2
=0

sin d = 4a2 .

0.25 2 0.5 0 0 0.25 0.5 0.75 y 1 1 0.75 x

If z = f (x, y) explicitly denes the surface S and thus r(x, y) = x i + y j + f (x, y) k such that (x, y) R R2 then it is easy to verify that N(x, y) = In fact N(x, y) = (fx i + fy j k) . We should also note that if z = f (x, y) then we can rewrite this as the implicit function (x, y, z) = (f (x, y) z) = 0. This is also the equation for a level surface and hence the normal to the level surface is given by , i.e., N(x, y) = = (fx i + fy j k) . 50
2 2 fx + fy + 1 .

The equation of the plane can be rewritten as z = f (x, y) = 10 2x 7y. Thus fx = 2 and fy = 7 which yields dS = and hence dS =
S R 2 2 fx + fy + 1 dx dy = R 2 2 fx + fy + 1 dx dy =

4 + 49 + 1 dx dy = 3 6 dx dy

3 6 dx dy

= 3 6
R

dx dy

= 3 6 area of R = 3 6.

CHAPTER 15. PARAMETERISATION OF SURFACES, SURFACE INTEGRALS [SHE 10 18.7]

LECTURE 14
Example 15.7 Determine the surface area for that part of the sphere x2 + y 2 + z 2 = 4 contained within the cylinder x2 + y 2 = 1. Solution:
x -1 0 1 2 2 -2

Since the projection R is a circular region it is wise to convert to polar co-ordinates: 2


R

2 4 x2 y2

=2 r=1

dx dy

2
=0 r=0 r=1

2 r dr d 4 r2 let u = 4 r2

r=0 u=3

2 r dr 4 r2 1 du u

=
1

4 4

u=4 u=4

z 0

= =
-2 -1 0 1 y 2

1 du u
4 3

-1

-2

4 2 u

u=3

= 8 2

3 .

In the previous two examples we wrote down the relationship Let S be the top half of the surface required and hence is dened by the graph z = 4 x2 y 2 . Thus the required area is 2 times the area of S or 2
R 2 2 fx + fy + 1 dx dy

dS =

2 2 fx + fy + 1 dA

which we determined from the parametric form for a surface. We can derived this relationship from a geometric point of view. For small dA we may assume that dS is at, i.e., without curvature. Note at does not mean necessarily horizontal. y

where R is the projection of S onto the xy-plane, i.e., x2 + y 2 1. Now fx = and hence dS =
2 2 fx + fy + 1 dx dy =

x2

y2

; fy =

4 x2 y 2

2 4 x2 y 2

dx dy .

Thus the required surface area is given by 2


R

2 4 x2 y 2

dx dy .

51

CHAPTER 15. PARAMETERISATION OF SURFACES, SURFACE INTEGRALS [SHE 10 18.7] In general dS will be greater than dA. The relationship between dS and dA depends on the inclination of dS. Since dA is the projection of dS onto the xy-plane the relationship is given by dA = cos dS where is the acute angle between the plane determined by dS and the xy-plane. Also if we choose a unit normal n to the plane of dS then is the angle between k and n also. Note if we had chosen in the opposite direction then the angle between n and n k = cos . Hence k would be and then n cos =| n k | and therefore 1 dA . |nk| For the implicit surface dened by (x, y, z) = (f (x, y) z) = 0 we have dA = cos dS dS = fx i + fy j k = n= 2 2 fx + fy + 1 and thus | n k |= Finally we have the desired result dS = 1 dA = |nk |
2 2 fx + fy + 1 dA .

A special case occurs when the surface S is given by z = f (x, y), whence G(r) dS = G(x, y, f (x, y))
R 2 2 fx + fy + 1 dx dy

where R is the projection of S onto the xy-plane. In the case G(r) = 1, the area is given by dS =
S R 2 2 fx + fy + 1 dx dy .

Example 15.8 A thin sheet of metal is in the shape of a half cylinder x2 + z 2 = 1, z 0, 0 y 4. Determine the mass of this metal sheet if its density (mass per unit area) at any point (x, y, z) is 2y + z + 3. Solution:

1
2 2 fx + fy + 1

Denition 15.4 The surface integral of a scalar quantity G dened at points r(u, v) on piecewise smooth surface S is given by G(r) dS = G(r(u, v)) N(u, v) du dv The surface S is parametrised by r(, y) = cos i + y j + sin k 52 0 , 0 y 4 .

Note if G(r) = 1 then the integral gives the surface area of S.

CHAPTER 15. PARAMETERISATION OF SURFACES, SURFACE INTEGRALS [SHE 10 18.7] Thus r = sin i + 0 j + cos k , ry = 0 i + j + 0 k , r N(, = r y y) i j k = sin 0 cos 0 1 0 = cos i + 0 j sin k , N(, y) = 1. Hence the mass of the metal sheet is given by mass =
S

Example 15.9 The dome of a cathedral, in the shape of the paraboloid z = 1 x2 y 2 is to be retiled. The cost of tiling is $(z + 15) per square metre (the higher you go up the more expensive it is). What is the total cost? Solution:

(x, y, z) dS

=
R

(r(, y)) N(, y) d dy (2y + sin + 3) dy d

= y=4

=
=0 y=0 =

=
=0 =

y 2 + y sin + 3y

4 0

=
=0

(28 + 4 sin ) d
=

= =

28 + 4
=0

sin d

28 + 8 .

The projection of paraboloid S onto the xy-plane is R = (x, y) R2 | x2 + y 2 1 . Since the surface has equation z = f (x, y) = 1 x2 y 2 we have dS =
2 2 fx + fy + 1 dx dy =

4x2 + 4y 2 + 1 dx dy .

Therefore the total cost is given by the integral cost =


R

(1 x2 y 2 + 15)

4x2 + 4y 2 + 1 dx dy .

53

CHAPTER 15. PARAMETERISATION OF SURFACES, SURFACE INTEGRALS [SHE 10 18.7] Since the projection R is circular it is wise to convert to polar co-ordinates: cost =
R

(1 x2 y 2 + 15)
=2 r=1

4x2 + 4y 2 + 1 dx dy

Example 15.10 Let S be the half hemisphere x2 + y 2 + z 2 = 1, y 0, z 0. Determine the ux of F = i + 2 j + k across S in the outwards direction.

=
=0 r=0 r=1

(16 r2 )

4r2 + 1 r dr d

2
r=0

(16 r2 ) 16

4r2 + 1 r dr u du

(let u = 4r2 + 1)

2 8 16 16 16

u=5

u1 4

u=1 u=5

Solution: The vector parametric form for the surface is given by r(, ) = cos sin i + sin sin j + cos k , Thus r r N(, ) = = sin sin i + cos sin j + 0 k , cos cos i + sin cos j sin k , = r r i j k 0 = sin sin cos sin cos cos sin cos
2 2

u=1

(65 u) u du
5 1

0 , 0

. 2

= =

130 3 2 5 u2 u2 3 5

2 130 (5 5 1) (25 5 1) 3 5

LECTURE 15
Denition 15.5 A ux integral of F over the piecewise smooth surface S dened by the parameterisation r(u, v) is givenby
S

F n dS

=
R

F(r(u, v)) N(u, v) N(u, v) du dv F(r(u, v)) N(u, v) du dv

cos sin i sin sin j cos sin k . We note from the problem that we want the outward ux, i.e., with a non-negative component in the z direction. Thus we should take the negative of the above result for the normal. Hence F(r(, )) N(, ) = = ( i + 2 j + k) (cos sin2 i + sin sin2 j + cos sin k) + 2 sin sin2 cos sin cos sin2 .

sin

=
R

where n = N = (ru rv ).

is the unit normal to S such that = (f (x, y) z) = 0 and

54

CHAPTER 15. PARAMETERISATION OF SURFACES, SURFACE INTEGRALS [SHE 10 18.7] Thus the ux integral is given by F n dS =
R

F(r(, )) N(, ) d d 2 sin sin2 + cos sin cos sin2 d d

= = 2

The surface S is implicitly dened by the function (x, y, z) = x2 + y 2 1 = 0. A normal to surface S is thus = 2x i + 2y j + 0 k and hence a unit normal is 2x i + 2y j + 0 k = n= 2 2 = xi + y j + 0k. 4x + 4y We should check that we have found the outward normal by evaluating n at some point on S. For example at (1, 0, 0), n = i + 0 j + 0 k = i, which is an outward pointing normal to the surface. So F n = ( i + 2 j + k) (x i + y j + 0 k) = x + 2y. Hence the ux integral is given by F n dS = ( x + 2y) dS .
S

=
=0 =0 = 2

=
=0

4 sin2 + cos sin d


= 2

4 + 4
=0 1

cos sin d

(let t = sin )

+
0

t dt = +

3 = . 2 2

Using cylindrical polar co-ordinates we have x = cos , y = sin , z = t, 0 , 0 t 1 and dS = 1 d dt. Hence
t=1 =

( x + 2y) dS
S

=
t=0 =0

( cos + 2 sin ) d dt ( sin 2 cos |0 ) 4.

Example 15.11 Let S be the half cylinder x2 + y 2 = 1, y 0 and 0 z 1. Determine the ux of F = i + 2 j + k across S in the outwards direction. Solution:

= =

55

Chapter 17

Stokes Theorem [SHE 10 18.10]


Denition 17.1 The circulation density or curl of a vector eld F = Fx (x, y, z) i+ Fy (x, y, z) j + Fz (x, y, z) k at the point (x, y, z) is given by curl F F i j k = x y z Fx = Fy Fz i+ Fz Fx z x j+ Fy Fx x y k.

Fy Fz y z

Before we state the theorem we discuss one bit of terminology. Let S be an orientable surface bounded by a smooth curve C (i.e., a curve that forms the edge of the surface). Then the orientation of S induces an orientation or direction along C as follows. If we imagine a person walking along C on the positive side of S, then the person is walking in the positive direction of C if the surface S is on his or her left and in the negative direction if S is on his or her right.

Theorem 17.1 (Stokes Theorem) S is a piecewise smooth orientable surface in space whose boundary is a piecewise smooth simple closed curve C. If F(x, y, z)s rst order partial derivatives exist and are continuous in a domain in space containing S then curl F n dS = F dr

where n is the outward pointing unit normal to the surface S and C is positively ori entated.

56

CHAPTER 17. STOKES THEOREM [SHE 10 18.10] Notes: If the surface S lies entirely in a plane then Stokes Theorem reduces to Greens Theorem in the Plane. Interpretation of Stokes Theorem is the ux integral of curl F across any (suitable) surface S spanning the given simple closed curve C equals (has the same value as)
C

F dr.

Can write
C

F dr as

F T ds where s is an arc length on C.

57

CHAPTER 17. STOKES THEOREM [SHE 10 18.10] Example 17.1 Verify Stokes Theorem for the hemisphere S : x2 + y 2 + z 2 = 9, z 0, its bounding circle C : x2 + y 2 = 9, z = 0 and the vector eld F = y i x j. Solution: Next we calculate the curl of F: curl F F = i x y j y x k z 0

= (0 0) i + (0 0) j + ( 1 1) k = 2k. We parametrise the surface S by r(, ) = 3 cos sin i + 3 sin sin j + 3 cos k , Thus r r N(, ) N(, ) curl F N(, ) Hence We use the parameterisation r(t) = 3 cos t i + 3 sin t j, for the curve C. Hence F = d = r Thus
2

0 2, 0

. 2

= 3 sin sin i + 3 cos sin j + 0 k , = 3 cos cos i + 3 sin cos j 3 sin k , = r r = 9 cos sin2 i + sin sin2 j + sin cos k , = 9 sin , = 2 k 9 cos sin2 i + sin sin2 j + sin cos k = 18 sin cos .

0 t 2

curl F n dS

curl F(r(, )) N(, ) d d


=2 = 2

18
=0 =0 = 2

sin cos d d

y i x j = 3 sin t i 3 cos t j , 3 sin dt i + 3 cos t dt j . t


2

36
=0 1

sin cos d

(let t = sin )

F dr =

9 sin2 t dt 9 cos2 t dt = 9

dt = 18 .

36
0

t dt = 18 .

58

CHAPTER 17. STOKES THEOREM [SHE 10 18.10] What went wrong? We need to be careful when applying Stokes Theorem to remember that the direction of the normal N(, ) (could be either r r or r r = (r r )) is determined by the direction we take around C. Since are going around the curve we counter clockwise as viewed from above we should take the outward (upward in this case, i.e., has a + k component) pointing normal to the surface. Hence curl F n dS
R

curl F(r(, )) N(, ) d d


=2 = 2

18
=0 =0 = 2

sin cos d d

36
=0 1

sin cos d

= =

36

t dt
0

18 .

Consider N(, ) N(, ) = = = [cos sin i + sin sin j + cos k] r(, ) r(, ) r(, ) . 3

This is the inward (downward) pointing normal. You can convince yourself by 1 N(, ) to obtain k. Thus we should take N(, ) = setting = 0 in N(, ) 3 r r = 9 cos sin2 i + sin sin2 j + sin cos k and therefore curl F N(, ) = 18 cos . sin 59

CHAPTER 17. STOKES THEOREM [SHE 10 18.10]

LECTURE 16
Example 17.2 Determine the circulation of the vector eld F = (x2 y) i+4z j+x2 k around the curve C in which the plane z = 2 meets the cone z = x2 + y 2 , counter clockwise as viewed from above. Solution:

Thus rr = cos i + sin j + k , = r sin i + r j . r cos Looking at the surface of the cone we should take the normal N(r, ) that has a positive z component. Thus N(r, ) = rr r = r cos i r sin j + r k . Next we calculate the curl F: i j k curl F F = x y z = = Then curl F N(r, ) x2 y 4z x2 4 i 2x j + k 4 i 2r cos j + k .

= ( 4 i 2r cos j + k) ( r cos i r sin j + r k) = 4r cos + 2r2 sin cos + r .

Hence using Stokes Theorem the circulation is given by F dr = curl F n dS


R

curl F(r(r, )) N(r, ) dr d (4r cos + 2r2 sin cos + r) dr d

=2 r=2

=
=0 r=0 =2

= We parametrise the cone by r(r, ) = r cos i + r sin j + r k , 0 r 2, 0 2 .


=0

(8 cos +

16 sin cos + 2) d 3

= 4 .

60

CHAPTER 17. STOKES THEOREM [SHE 10 18.10] Example 17.3 Let C be the rectangle in the plane z = y orientated as indicated
z
C

Thus F dr = =
R

curl F n dS 1 (2xy i y 2 j + 4y 3 k) (0 i + j k) 2 dxdy 2

C 3 1 n y

where R is the projection of S onto the xy-plane, i.e., R = (x, y) R2 |0 x 1, 0 y 3 . Thus F dr = 1 (2xy i y 2 j + 4y 3 k) (0 i + j k) 2 dxdy 2
x=1 y=3

= F dr.

4y 3 + y 2 dy dx
x=0 y=0

and F = x2 i + 4xy 3 j + xy 2 k. Hence determine

= 90 .

Solution: To evaluate the integral directly would require four separate line integral calculations, one for each side of the rectangle. Instead we shall apply Stokes Theorem so we need only evaluate a single surface integral over any surface with C as its boundary. One such surface is the rectangular surface S bounded by C. For the direction shown for C the surface S must be orientated by a downward normal. The surface S has implicit representation given by (x, y, z) = y z = 0. Hence the downward unit normal is given by 1 = (0 i + j k) . n= 2 Note the k component in the i curl F = x x2 normal. Next we calculate curl F: j k = 2xy i y 2 j + 4y 3 k . y z xy 2 61

Example 17.4 Calculate

F dr where F = (ex yz) i + (sin y + xz + 4x) j + C (arctan z + 1) k and C is the positively orientated curve of intersection of the surfaces x2 + y 2 + z 2 = 25 and z = 4. Solution:

4xy 3

CHAPTER 17. STOKES THEOREM [SHE 10 18.10] (cont.) (cont.)

62

CHAPTER 17. STOKES THEOREM [SHE 10 18.10] Example 17.5 Calculate


C

Fdr where F = (4z+x2 ) i+(2x+3y 5 ) j+(2x2 +5 sin z) k

(cont.)

and C is the positively orientated curve of intersection of the surfaces x2 + y 2 = 1 and z = y + 1. Solution:

63

Chapter 18

Divergence Theorem [SHE 10 18.9]


LECTURE 17
Denition 18.1 The ux density or divergence of a vector eld F = Fx (x, y, z) i+ Fy (x, y, z) j + Fz (x, y, z) k at the point (x, y, z) is given by Fy Fz Fx + + . div F F = x y z Theorem 18.1 (Divergence Theorem) If T is a closed bounded region whose boundary is a piecewise smooth orientable surface S and if F(x, y, z) is continuous and has continuous rst order partial derivatives in some domain containing T then div F dV = F n dS

The ux across the side at x is approximately given by z y z y ,z + ) (i) yz = Fx (x, y + ,z + ) yz . F(x, y + 2 2 2 2 Similarly the ux across the side at x + x is approximately given by y z y z F(x + x, y + ,z + ) i y z = Fx (x + x, y + ,z + ) y z . 2 2 2 2 Hence the total ux across the two sides at x and x + x is given by Fx (x + x, y + Fx x x y z y z ,z + ) Fx (x, y + ,z + ) 2 2 2 2 y z

where n is the outward unit normal to S. Proof: We wish to consider the net ux of the vector eld F = Fx i + Fy j + Fz k < Fx , Fy , Fz > across the surface of a box of volume V = xyz and surface S, i.e, F n S.

y z .

64

CHAPTER 18. DIVERGENCE THEOREM [SHE 10 18.9] Similarly the total ux across the two sides at y and y + y is given by Fy (x + x z x z , y + y, z + ) Fy (x + , y, z + ) 2 2 2 2 x z x z Example 18.1 Verify the Divergence Theorem for the sphere S : x2 + y 2 + z 2 = a2 and the vector eld F = x i + y j + z k.

Fy y y

and the two sides at z and z + z is given by Fz (x + x y x y ,y + , z + z) Fz (x + ,y + , z) 2 2 2 2 Fz z x y . z x y

Hence the total ux across all six sides is given by F n S = = = Fy Fx x y z + y x z + x y Fx Fy Fz x y z + + x y z F V . Fz z z x y Solution: The divergence of F is given by x y z div F F = + + = 3. x y z Hence div F dV = 3 dV
T

= 3 volume of sphere of radius a = 3 4 3 a = 4a3 . 3

We parametrise the surface S by spherical polar co-ordinates r(, ) = a cos sin i + a sin sin j + a cos k , Thus F r r N(, ) 65 0 2, 0 .

= r(, ) , = a sin sin i + a cos sin j + 0 k , = a cos cos i + a sin cos j a sin k , = r r = 2 cos sin2 i + sin sin2 j + cos sin k . a

CHAPTER 18. DIVERGENCE THEOREM [SHE 10 18.9] Hence F n dS


R

F(r(, )) N(, ) d d
=2 =

F = x i + y j + z k F = 3. Thus
T

F dxdydz

=
T

3 dxdydz
=2 r=1 z=1r 2

a3
=0 =0 =2 = 3 =0 =0 =

cos2 sin3 + sin2 sin3 + sin cos2 d d

= 3
=0 r=0 z=0 r=1 z=1r 2

r dz dr d

sin3 + sin (1 sin2 ) d d sin d = 4a3 .


=0

= 6
r=0 z=0 r=1

r dz dr

2a3

= 6
r=0

r(1 r2 ) dr
1 0

Example 18.2 Let T be the region in R3 bounded by the paraboloid z = 1 (x2 + y 2 ) and the xy-plane, and let its bounding surface be denoted by S. Let F = x i + y j + z k. (a) Evaluate F dx dy dz directly.
T

1 = 6 (1 r2 )2 4 = (b) ST op SBottom r(r, ) r(r, ) = = r cos i + r sin j + (1 r2 )k 3 . 2

(b) Give a parameterisation for each of the two separate surfaces of S, the top and bottom. (c) Use (b) to compute the ux of F out of S, directly. Solution: (a) Sketch of the region
x -0.5 0 0.5 1 1 -1

r : 0 1, : 0 2

r cos i + r sin j + 0k r : 0 1, : 0 2

(c) To calculate the ux directly we need to calculate F n dS = F n dS + F n dS .

SBottom

ST op

We consider the two surfaces separately. Bottom Since the bottom surface is at the outward unit normal is k. Hence F n = z. But at the bottom z = 0. Thus F n dS = 0 .
1

0.75 z 0.5

0.25

0 -1 -0.5 0 0.5 y

SBottom

66

CHAPTER 18. DIVERGENCE THEOREM [SHE 10 18.9] Top We need to determine the normal to the curved top surface. Hence rr r N(r, ) = cos i + sin j 2rk r sin i + rcos j + 0k rr r i j k cos sin 2r = 2r2 cos i + 2r2 sin j + rk . r sin +r cos 0

LECTURE 18
Example 18.3 Consider the surface integral
S

= =

( F) n dS, where S is an open

cylinder, consisting of a base and side such that x2 + y 2 = 1, 0 z 2, F = xz i + x j + 1 y 2 k and n is the outward unit normal. Determine at least 3 dierent 2 ways in which to evaluate the integral. Try all of these ways of evaluating the integral. Solution:

= Hence F n dS

ST op

=
ST op

r cos i + r sin j + (1 r2 )k 2r2 cos i + 2r2 sin j + rk drd r + r3 dr d

=2 r=1

=
=0 r=0

= 2 = 3 . 2

1 2 1 4 r + r 2 4

1 0

Thus overall F n dS =
SBottom

F n dS +

= =

3 0+ 2 3 . 2

ST op

F n dS

67

CHAPTER 18. DIVERGENCE THEOREM [SHE 10 18.9] (cont.) (cont.)

68

CHAPTER 18. DIVERGENCE THEOREM [SHE 10 18.9] Example 18.4 Prove


T

f dV =
S

f n dS where f is a scalar function.

Solution:

69

Chapter 19

Fourier Series
LECTURE 19
In MATH 1231, we discovered how a basis set of vectors (linearly independent and spanning) for a vector space in Rn could be used to uniquely create any vector in Rn . x1 . Example 19.1 Every vector x = . Rn can be written as x = x1 e1 + +xn en . . xn This expresses x as a linear combination of the orthonormal basis set {e1 , . . . , en }, where 0 0 1 . 1 0 . e1 = . , e2 = . , . . . , en = . . 0 . . . . 0 1 0

19.1

Orthogonal functions

The real-valued functions on the interval [a, b] form a vector space in the usual sense: Addition of two functions and multiplication of a function with a scalar are dened pointwise: (f + g)(x) = f (x) + g(x), ( f )(x) = f (x), where f, g are real-valued functions on [a, b] and R is a scalar. Denition 19.1 Let w be a positive function on [a, b]. For functions f, g dened on [a, b] we dene the inner product (associated) with the weight function w by
b

NOTE. The components of x, i.e., xi , i = 1, 2, . . ., are unique and in this example can be determined using xi = x ei , i = 1, 2, . . . We also saw in MATH 1231 that the innite set {1, x, x2 , x3 , . . .} could be used to create a Maclaurin series for an appropriate function f , i.e., f (x) = where f
(n)

f, g

=
a

f (x) g(x) w(x) dx.

Denition 19.2 For the weight function w(x) = 1 for all x [a, b] we call the associated inner product just the inner product and write
b

f (n) (0) n x n! n=0

f, g =
a

f (x) g(x) dx.

(0) is the nth derivative of f evaluated at x = 0. 70

CHAPTER 19. FOURIER SERIES Denition 19.3 The inner product with the weight function w induces a norm via =
b

f, f

The norm associated with the inner product (with the weight function w 1) is denoted simply by f = f w1. The inner product associated with the weight function w and the corresponding norm have the usual properties of any other inner product and norm (think of the Euclidean scalar product and length on vectors in Rn .): Theorem 19.1 For any real-valued functions f, g, h on [a, b] and any constant (a) f, g
w

|f (x)|2 w(x) dx

1/2

Denition 19.5 Let {1 , 2 , 3 , . . .} denote a (nite or innite) set of functions dened on [a, b]. The set of functions is called an orthogonal set (with respect to the weight function w) on the interval [a, b] if and only if n , m
w

. =

0 n > 0

if if

m = n, m = n.

Denition 19.6 An orthogonal set {1 , 2 , 3 , . . .} (with respect to a weight function w) on [a, b] is called an orthonormal set if m
w

=1

for all m = 1, 2, 3, . . . .

= g, f
w w

w. w w

Denition 19.7 An orthogonal set {1 , 2 , 3 , . . .} (with respect to a weight function w) on [a, b] is called a complete orthogonal set in a space V of functions on [a, b] if for any f V the conditions f, m imply that f 0.
w

(b) f + g, h (c) h, f + g (d) f, g (e) f, f (f ) | f, g


w

= f, h = h, f
w

+ g, h + h, g

w. w. w. w

=0

for all m = 1, 2, 3, . . .

= f, g

= f, g

0 for all f , and f, f f


w

= f

2 w

= 0 only if f 0 (positive deniteness),

Example 19.2 Show that the functions m = sin(mx), m = 1, 2, 3, . . . form an orthogonal set (with respect to the unit weight function, i.e., w(x) = 1) on the interval [, ]. Solution:

w|

(Cauchy-Schwarz inequality).

NOTE. For purposes of integration we are always allowed to change a function at a nite number of points; this will not inuence/change the values of any integrals involving the function. Thus a function being zero except at a nite number of points is for integration purposes identical to the zero function. This observation implies that a weight function w can be zero at a nite number of points (instead of being positive everywhere on [a, b]). Denition 19.4 We say that f and g are orthogonal on the interval [a, b] with respect to the weight function w if
b

f, g

=
a

f (x) g(x) w(x) dx = 0.

Again we say that they are just orthogonal if the weight function is w 1. 71

CHAPTER 19. FOURIER SERIES (cont.) Example 19.3 Show that the trigonometric functions {0 , 1 , 1 , 2 , 2 , . . .}, given by n (x) = cos(nx), m (x) = sin(mx), n = 0, 1, 2, . . . , m = 1, 2, 3, . . . ,

i.e., {1, cos x, sin x, cos 2x, sin 2x, cos 3x, sin 3x, . . .} form an orthogonal set (with respect to the unit weight function, i.e., w(x) = 1) on the interval [, ]. Solution: This means that n , m = 0 n , m = 0 n , m = 0 for all n = 0, 1, 2, . . . , m = 1, 2, 3, . . . , whenever n = m, whenever n = m.

0.5

0.5

0.5

0.5

1 3 2 1 0 x 1 2 3

1 3 2 1 0 x 1 2 3

Figure 19.1: The trigonometric function n (x) = cos(nx), n = 0, 1, 2 in the left picture and the trigonometric functions m (x) = sin(mx), m = 1, 2, 3 in the right picture.

72

CHAPTER 19. FOURIER SERIES We indicate now how to show the orthogonality relations. The functions cos and sin satisfy the following half angle formulas: sin + sin = 2 sin cos + cos = 2 cos cos cos = 2 sin sin sin = 2 sin
1 2 ( + ) 1 2 ( ) 1 2 ( + ) 1 2 ( + )

For n , n = 1, 2, 3, . . ., we use (19.3) with nx = 1 ( + ) and nx = 1 ( ), that is 2 2 = 2nx and = 0.


cos cos cos sin

1 2 ( ) 1 2 ( + ) 1 2 ( ) 1 2 ( )

, , , .

(19.1) (19.2) (19.3) (19.4)

cos (nx) dx =

cos(nx) cos(nx) dx

1 = 2 1 = 2 = = 1 2

cos(2nx) + cos(0) dx

To show n , m = 0 for all n = 0, 1, 2, . . . and all m = 1, 2, 3, . . ., we use (19.2): set in (19.2)


1 2 ( ) = mx 1 2 ( + ) = nx

= (m + n)x = (n m)x

1 cos(2nx) dx + 2 1 sin(2n x) 2n

1 dx

Then

n , m =

cos(nx) sin(mx) dx

1 sin(2n) sin(2n) + = 0 + = . 4n

1 sin (n + m)x sin (n m)x dx 2 1 sin (n m)x dx = 0. = sin (n + m)x dx 2


1 1 For n , n N, we use (19.4) with nx = 2 ( + ) and nx = 2 ( ), that is = 0 and = 2nx, and obtain n 2 = .

Clearly, the set {0 , 1 , 1 , 2 , 2 , . . .} is not orthonormal, but by dividing each of the functions through by its norm we obtain an orthonormal set: The set {0 , 1 , 1 , 2 , 2 , . . .}, given by 0 (x) 1 1 cos(0x) = , = 0 2 2 1 n (x) = cos(nx), n = 1, 2, 3, . . . n (x) = n 1 n (x) = sin(nx), n = 1, 2, 3, . . . n (x) = n 0 (x) = is an orthonormal set. The orthogonal set {0 , 1 , 1 , 2 , 2 , . . .} of trigonometric functions is complete in the space of continuous functions on [, ] and in the space of those functions on

The other orthogonality relations are veried in a similar way. Are the trigonometric functions also orthonormal?

The last statement follows from the fact that for all Z 0 if = 0, sin(x)dx = 1 cos(x) = 0 if = 0.

cos (0 x) dx =

1 dx = 2.

[, ] for which the integral f

|f (x)|2 dx is nite, i.e., < .

73

CHAPTER 19. FOURIER SERIES

LECTURE 20
19.2
19.2.1

are an orthogonal set on [L, L]. This follows easily from the orthogonality in the special case L = 1: For example, for m, n N
L

Fourier series of trigonometric functions


Denition of a trigonometric Fourier series

n , m =
L

cos

m n x cos x dx L L

Denition 19.8 A function f , dened on R, is said to be periodic, if there is a number T > 0 such that f (x + T ) = f (x) for all x R. (19.5)

L =

cos(ny) cos(my) dy

The smallest positive number T for which (19.5) is satised is called the period of the function f , and we also say that f is T -periodic. Geometrically, periodicity of a function f (with period T ) means that the function is completely described through its values on any interval [a, a + T ], where a R arbitrary, and that f (a) = f (a + T ). NOTE. We choose the smallest number T for which (19.5) is satised. It is clear that (19.5) is then also satised for any nT , n Z, that is, if T is the period of f then also for all n Z f (x + nT ) = f (x) for all x R. Example 19.4 We know that cos(x) and sin(x) have the period 2. Therefore the trigonometric functions n (x) = cos(nx), n (x) = sin(nx), n = 1, 2, 3, . . . , n = 1, 2, 3, . . . , n .
2

0 if n = m,

where we have made the substitution y = (/L)x. Analogously, we can prove the other orthogonality relations and also compute the norms; we obtain
L

L = L if n = m,

=
L L

cos2

0 x L

dx =

1 dx = 2L,

=
L L

cos2

n x dx = L, L

n = 1, 2, 3, . . .

(19.7)

have the period Tn = 2/n. To see this, write for example n (x) = cos(nx) = cos 2 n x 2

=
L

sin2

n x dx = L, L

n = 1, 2, 3, . . . .

The trigonometric functions 0 , 1 , 1 , 2 , 2 , . . . on [L, L], given by n x , L n n (x) = sin x , L n (x) = cos n = 0, 1, 2, . . . , (19.6) n = 1, 2, 3, . . . , 74

The set of trigonometric functions on the interval [L, L] is also complete in the sense that (f, n ) = 0 for all n = 0, 1, 2, . . . and (f, n ) = 0 for all n = 1, 2, 3, . . . implies that f 0. (This is true for continuous f and more generally if f only satises
L

|f (x)|2 dx < .)
L

CHAPTER 19. FOURIER SERIES Denition 19.9 The Fourier series F of a function f on [L, L] (with f < ) with respect to the complete orthogonal set of trigonometric functions on [L, L] is given by F (x) = n n a0 an cos + x + bn sin x 2 L L n=1
L

(19.8)

Example 19.5 (Square Wave) Determine the Fourier Series for the function f , dened by K if < x < 0, f (x) = K if 0 x , where K > 0, and f (x + 2) = f (x) i.e., f is 2-periodic. for all x R,

with the Fourier coecients an and bn given by an = 1 L f (x) cos


L L

n x dx, L n x dx, L

n = 0, 1, 2, . . . ,

(19.9)

1 bn = L NOTE.

f (x) sin
L

n = 1, 2, 3, . . . .

(19.10)

0.5

The rst term a0 /2 is the coecient of the constant function 0 (x) = cos(0x/L) = 1. Therefore the function 0 does not appear explicitly because its value is 1. Note too that we have to scale the coecient a0 by the factor 1/2. The formulas (19.9) and (19.10) are obtained by demanding that for all m f, m = f, m = a0 n n an cos + x + bn sin x 2 L L n=1 n n a0 + an cos x + bn sin x 2 L L n=1

4 x

0.5

, m , m

, .

(19.11) (19.12)

Computing (19.11) explicitly yields f, m = = a0 0 + {an n + bn n } , m 2 n=1

Figure 19.2: The square wave with K = 1. Solution: We compute the Fourier coecients of f ,

a0 0 , m + {an n , m + bn n , m } 2 n=1 a0 a0 0 2 = 2L if m = 0 = = am L, 2 2 2 am m = am L if m = 0 where in the last step we have used the orthogonality and (19.7). Thus we obtain (19.9), and a similar computation for (19.12) yields (19.10). 75

a0 =

f (x) cos(0x) dx =

f (x) dx

1 =

(K) dx +
0

1 K dx = (K + K) = 0.

CHAPTER 19. FOURIER SERIES For n 1 we have an = 1 NOTE. The square wave at the point x = 0 has the value f (0) = K. However, for the Fourier series we obtain the value zero, as all the sine functions in the sum vanish in the point zero. Clearly the function and corresponding Fourier series need not have the same value at all points x.

f (x) cos(nx) dx
0

1 = 1 = and bn = 1

(K) cos(nx) dx +
0 x=0

K cos(nx) dx
x=

19.2.2
L

Convergence of a trigonometric Fourier series

As the trigonometric functions form a complete orthogonal set, for any f with f = (
L

K sin(nx) n

K sin(nx) + n x=

=0
x=0

|f (x)|2 dx)1/2 < we have lim f n n a0 an cos + x + bn sin x 2 L L n=1


2 N 2

= 0,

(19.14)

f (x) sin(nx) dx
0

1 = = = = 1

(K) sin(nx) dx +
0 x=0 x=

K sin(nx) dx
x= x=0

or equivalently a0 n n f + an cos x + bn sin x 2 L L n=1


L

=
L

K cos(nx) n

K cos(nx) n

f (x)

a0 n n + an cos x + bn sin x 2 L L n=1

(19.15) dx = 0.

1 K cos(0) cos(n) cos(n) + cos(0) n 2K 1 cos(n) n

In words we say the Fourier series of f converges in the mean to f if (19.14) and (19.15) are satised. However, (19.14) and (19.15) do not tell us anything about pointwise convergence of the series toward f . The identity (19.15) implies that (use the denition g 2 = g, g , take the inner product, and make use of the orthogonality and (19.7)) f
2

0 if n is even, 4K if n is odd. n Thus we obtain the Fourier series of f , given by 2K 1 (1)n = = n 4K F (x) = 4K = 1 1 sin(x) + sin(3x) + sin(5x) + 3 5
k=0

= =

a0 2 a2 0 4

n=1

a 2 n n

+ b2 n n

2L + L

n=1

a2 + b 2 , n n

or equivalently (19.13) 1 f L
2

1 sin (2k + 1)x . 2k + 1

1 = L

|f (x)|2 dx =
L

a2 0 a2 + b 2 . + n n 2 n=1

(19.16)

The identity (19.16) is known as Parsevals identity. 76

CHAPTER 19. FOURIER SERIES Example 19.6 From Ex 19.5 for the square wave we compute the norm of f and express it as a sum of the Fourier coecients of f with the help of Parsevals identity 1/2 1/2 f = |f (x)|2 dx (19.17) = K 2 1 dx = 2 K
2

is thus a sequence of trigonometric polynomials of increasing degree. That SN minimises the norm f PN among all trigonometric polynomials of the form (19.19) means that PN = SN is the best approximation among all trigonometric polynomials PN of degree at most N .

LECTURE 21
Denition 19.10 A function f dened on [a, b] is piecewise continuous if it is continuous on [a, b] except at a nite number of points xi , i = 1, 2, . . . , k,

From Parsevals identity we obtain f = 4K


2

1 1 1 + 2 + 2 + ... 3 5

16K 2 =

k=0

1 . (2k + 1)2

(19.18)

From (19.17) and (19.18) together we learn that 16K


2 k=0

and if both the right-hand and left-hand limits


k=0

1 = 2K 2 (2k + 1)2

2 1 = . 2 (2k + 1) 8

f (x+ ) = i f (x ) = i

0, >0 0, >0

lim

f (xi + ), f (xi )

lim

Theorem 19.2 (Uniqueness of the Fourier series) If f with f < has a series expansion in the trigonometric functions that converges in the mean toward the function, then this series expansion is the trigonometric Fourier series. Among all functions of the form a0 PN (x) = + {an n (x) + bn n (x)} , 2 n=0 1/2
N

exist (and are nite) at each point of discontinuity xi , i = 1, . . . , k.


20

1
1

(19.19)
0.5
0.5

15

with arbitrary real coecients a0 , . . . , aN and b1 , . . . , bN , the one that minimises


L 2
4 2 2 x 4
3 2 1 1 x 2 3

10

f PN

(for a given function f with f < ) is the one, where the coecients an and bn are the Fourier coecients of f . In that case PN is the N -th partial sum of the Fourier series of f . We call any function of the form (19.19) a trigonometric polynomial. The sequence {SN } of partial sums SN of the Fourier series of f , SN (x) = a0 {an n (x) + bn n (x)} , + 2 n=0 77
N

|f (x) PN (x)| dx

0.5

0.5

1 x

Figure 19.3: The left picture shows the signum function (see below) on [5, 5]. The middle picture shows a piecewise continuous function, whereas the function in the right picture is not piecewise continuous as f (0+ ) = .

CHAPTER 19. FOURIER SERIES Example 19.7 The signum (or sign) function, dened by +1 if x > 0, 0 if x = 0, f (x) = sgn(x) = 1 if x < 0, f (0+ ) =
0, >0

0.5

is continuous everywhere except at the point x = 0, but lim f (0 + ) = 1, f (0 ) =

0, >0

lim

f (0 ) = 1

1 x

exist. Therefore, the signum function is piecewise continuous. Denition 19.11 A sequence of functions {fn }nN is said to converge pointwise toward a function f , if for all x
n

0.5

lim fn (x) = f (x). Figure 19.4: The square wave and the rst three partial sums of the square wave, with K = 1: the square wave f (solid), S0 (dashed), S1 (dotted), and S2 (bold).

Theorem 19.3 Let f be a function on [L, L], which is piecewise continuous and whose rst derivative f is also piecewise continuous. Then the Fourier series of f converges pointwise to if f is continuous at x (L, L), f (x) 1 f (x+ ) + f (x ) if f is discontinuous at x (L, L), 2 1 + if x = L. 2 f (L ) + f (+L )

Due to the Theorem, the Fourier series (19.13) of the square wave converges pointwise to f (x) if x (, 0) or if x (0, ), 0 if x {, 0, }. In Figure 19.4 we show the rst partial sums S0 , S1 , and S2 of the square wave, dened by N 1 4K sin (2k + 1)x . SN (x) = 2k + 1
k=0

NOTE. The Fourier series of any function f fullling the assumptions always converges to a function periodic on [L, L], as at the end points x = L the Fourier series converges toward the value 1 f (L+ ) + f (+L ) . 2

Example 19.8 (Square Wave) The square wave f (x) = K K if if < x < 0, 0 x ,

19.2.3

Fourier sine and cosine series

is obviously piecewise continuous, as at the point of discontinuity x = 0 we have f (0+ ) = K and f (0 ) = K. Its derivative is given by f (x) = 0 for all x [, ] \ {, 0, }. Clearly f ( + ) = 0, f (0 ) = 0, f (0+ ) = 0, and f (+ ) = 0. Thus the square wave has a derivative that is piecewise continuous. 78

Denition 19.12 A function f dened on [L, L] (on R) is called an even function if f (x) = f (x) for all x [L, L] (for all x R). Denition 19.13 A function f dened on [L, L] (on R) is called an odd function if f (x) = f (x) for all x [L, L] (for all x R).

CHAPTER 19. FOURIER SERIES Example 19.9 (odd and even functions) (a) cos(nx) is an even function on R, because cos(nx) = cos(nx). (b) sin(nx) is an odd function on R, because sin(nx) = sin(nx). (c) The signum function is an odd function on R because sgn(x) = sgn(x) for all x R. (d) The polynomial xn satises (x)n = (1)n xn for all x R and thus is an even function on R if n is even and an odd function if n is odd. NOTE. Geometric interpretation of even and odd. For an even function f , the reection of the graph of f (x), x 0, on the y-axis yields just the graph of f (x), x 0. For an odd function f the image of the graph of f (x), x 0, under the rotation with 180 around the origin is just the graph of f (x), x 0. Denition 19.14 For a function f on [L, L], with f < , the Fourier cosine series is dened by n a0 + an cos x , 2 L n=1 with the Fourier coecients given by an = 1 L
L

In general we cannot expect that for a function f (satisfying the assumptions in Theorem 19.3) the Fourier sine series or the Fourier cosine series converges to the function, but the following to statements hold: Theorem 19.4 Suppose f , with f < , is an even function. Then f the trigonometric Fourier series of f is the Fourier cosine series of f . Theorem 19.5 Suppose f , with f < , is an odd function. Then f the trigonometric Fourier series of f is the Fourier sine series of f . Proof of the theorems: We know that cos(nx/L) is even and sin(nx/L) is odd. The Fourier coecients are dened by 1 an = L 1 bn = L
L

f (x) cos
L L

n x dx, L n x dx L

n = 0, 1, 2, . . . ,

(19.20)

f (x) sin
L

n = 1, 2, 3, . . . ,

(19.21)

f (x) cos
L

n x dx, L

n = 0, 1, 2, . . . .

and the integrands in (19.20) and (19.21) are the product of two functions of which each is either even or odd. Now let for example f be an even and g be an odd function. Then the product f g of the two functions is odd, because f (x) g(x) = f (x) (g(x)) = f (x) g(x).

Denition 19.15 For a function f on [L, L], with f series is dened by n bn sin x , L n=1 with the Fourier coecients given by 1 bn = L
L

< , the Fourier sine

With analogous arguments we can prove all the following relations: EVEN EVEN = EVEN, ODD ODD = EVEN, EVEN ODD = ODD.
L L

(19.22)

Now if we consider the integral of an even and an odd function over [L, L]: n x dx, f (x) sin L n = 1, 2, 3, . . . . for even f
L L

f (x) dx = 2
0 0

f (x) dx,
L

The Fourier cosine series and the Fourier sine series are the Fourier series with respect to the orthogonal set {0 , 1 , . . .} and {1 , 2 , . . .}, respectively. The sum of the Fourier cosine series and the Fourier sine series of a function f is the trigonometric Fourier series of the function. 79

(19.23) f (x) dx = 0.

for odd f
L

f (x) dx =
L

f (x) dx +
0

CHAPTER 19. FOURIER SERIES Applying (19.22) and (19.23) to the integrals in the Fourier coecients (19.20) and (19.21) we see that in case of even f all the coecients bn vanish and that in case of odd f all the coecients an vanish. NOTE. For an even function (an odd function) satisfying the assumptions in Theorem 19.3, Theorem 19.4 (Theorem 19.5) guarantees that the statement in Theorem 19.3 about pointwise convergence is true for the Fourier cosine series (Fourier sine series). where Denition 19.19 Let f be a function dened on [0, L] and let fe denote its even (periodic) extension. Then the Fourier series of fe is a Fourier cosine series, and if we restrict it to [0, L], we obtain the half-range cosine series for f f (x) n a0 + an cos x , 2 L n=1

0 x L,

19.2.4

Periodic odd and even extensions


1 an = L

In many applications a function f given on an interval [0, L] needs to be expanded into a Fourier series. One way to do that is to take [0, L] as the interval of periodicity and L as the period. In this case we would generally get a trigonometric Fourier series with both sine and cosine contributions. However, we can do better by rst extending f to an even or odd function on [L, L] and then represent it by a Fourier cosine or Fourier sine series, respectively. This is advantageous because we have only to determine half as many coecients. Denition 19.16 Let f be a function on [0, L]. The even extension of f to the interval [L, L] is given by fe (x) = f (x) f (x) if if 0 x L, L x < 0.

2 n x dx = fe (x) cos L L

f (x) cos
0

n x dx, L

n = 0, 1, 2, . . . (19.24)

Denition 19.20 Let f be a function dened on [0, L] and let fo denote its odd (periodic) extension. Then the Fourier series of fo is a Fourier sine series, and if we restrict it to [0, L], we obtain the half-range sine series for f f (x) where 1 bn = L
L n=1

bn sin

n x , L

0 x L,

NOTE. In the denition of the odd extension we have to redene f at x = 0 because f (0) = f (0) is violated if f (0) = 0. The values f (L) are dened to be zero in the odd extension, because we want to have a periodic odd (and even) extension. Having extended f to [L, L] with f (L) = f (L) we now can extend it periodically to R. Denition 19.18 For a function f on [L, L), or on [L, L], f (L) = f (L), we can dene the periodic extension f to R by f (x) = f (x) f (x 2jL) if if L x < L, (2j 1)L x < (2j + 1)L, j Z. satisfying

Denition 19.17 Let f be a function on [0, L]. The odd extension of f to the interval [L, L] is given by if 0 < x < L, f (x) 0 if x {L, 0, +L}, fo (x) = f (x) if L < x < 0.

2 n x dx = fo (x) sin L L

f (x) sin
0

n x dx, L

n = 1, 2, 3, . . . (19.25)

NOTE. The second formula for the coecients in (19.24) and (19.25) makes use of the fact that our integrand is even (see (19.23)). Of course this second formula is easier to compute, and it also does not make explicit use of the even or odd (periodic) extension of f .

LECTURE 22
Example 19.10 Find the half-range cosine and sine expansions of the function f (x) =
2k L 2k L

x (L x)

if if

0x<
L 2

L 2,

x < L.

80

CHAPTER 19. FOURIER SERIES Solution: Half-range cosine expansion: First we determine the (periodic) even extension of f . fe (x) = f (x) f (x) if if x [0, L], x [L, 0), and for n 1 2 an = L
L

f (x) cos
0 L/2

n x dx L n 2k x dx + L L
L

and for all x R we demand fe (x) = fe (x + 2L).


1 0.8 0.6 0.4 0.2 1 0.8 0.6 0.4 0.2

2 2k L L

x cos
0

(L x) cos
L/2

n 4k L sin x = 2 x L n L
1 2 x 3

integration by parts needed here


L/2 0

u dv = uv sin n x dx L
L

n x dx L v du

L/2

L n

1 0.2 0.4 0.6 0.8 1

1 x

1 0.2 0.4 0.6 0.8 1

+ (L x) = 4k L2
2

n L sin x n L
2

+
L/2

L n

sin
L/2

n n L L sin x + 2 2 cos 2n 2 n L 0 2 2 L L n n 2 2 cos sin x 2n 2 n L 4k n cos(n) 1 . = 2 2 2 cos n 2 We compute the rst few coecients an a1 = 0, a6 = a2 = 16k , 62 2 16k , 22 2 a3 = 0, a8 = 0,

L/2

n x dx L

L L/2

Figure 19.5: The triangular-shaped function f in the example, with k = 1 and L = , in the left picture and its even extension fe to [L, L] in the right picture. Next we compute the coecients of the Fourier cosine series of fe : from (19.24) 2 a0 = L =
L L/2 0

a4 = 0, ...,

a5 = 0,

4k L2

2 2k f (x) dx = L L 1 2 x 2
L/2 0

2k x dx + L
L

a7 = 0,

L/2

1 (L x)2 2

=
L/2

4k L2

(L x) dx L2 L2 + 8 8

and see that an = 0 if n {2, 6, 10, 14, 18, . . .}. For n = 2(21) = 42, = 1, 2, 3, . . ., / we can see that a42 = 81 16k , (4 2)2 2 = 1, 2, 3, . . . .

= k,

CHAPTER 19. FOURIER SERIES Thus, the half-range cosine series of f reads k 16k Fe (x) 2 2 k 16k = 2 2 1 cos 22
=1

Next we compute the coecients of the Fourier sine series of fo : from (19.25) for n 1 6 x + ... L 2 bn = L =
L

1 2 x + 2 cos L 6

f (x) sin
0

n x dx L

1 cos (4 2)2

(4 2) x , x [0, L]. L

Half-range sine expansion: First we determine the (periodic) odd extension of f . f (x) f (x) if if x [0, L], x [L, 0],

fo (x) =

and for all x R we demand fo (x) = fo (x + 2L).


1 0.8 0.6 0.5 0.4 0.2 1

1 0.2 0.4

1 x

1 x

0.5 0.6 0.8 1 1

For odd n we can represent the coecients bn with the formula b21 = 8k 1 , 2 (2 1)2 = 1, 2, 3, . . .

Figure 19.6: The triangular-shaped function f in the example with k = 1 and L = , in the left picture and its odd extension fo to [L, L] in the right picture.

82

CHAPTER 19. FOURIER SERIES Thus, the half-range sine series of f reads Fo (x) = 8k 2 8k 2 1 1 sin x + 2 sin 12 L 3
=1

(cont.) 1 3 x + 2 sin L 5 5 x + ... L

1 sin (2 1)2

(2 1) x , L

x [0, L].

From Theorem 19.3 and Theorems 19.4 and 19.5 we know that both half-range series expansions converge at every point x [0, L] to f (x). Example 19.11 Consider the periodic function f of period 4 given by f (x) = 1 0 3 x 1 . 1 < x < 1

(a) Sketch the function f (b) Determine the Fourier series F of f . (c) Plot the Fourier series F on your sketch. Are there any points of discrepancy between F and f ? Why? If so, mark these on the graph. Solution:

1 2 F (x) = + 2

=1

(1) cos 2 1

(2 1)x 2

83

CHAPTER 19. FOURIER SERIES Example 19.12 Find the Fourier series for f (x) = 5, 3, < x < 0 0x< Hence overall we have F (x) = F (x) + 4 = 4 4
=1

1 sin ((2 1)x) . 2 1

assuming that f has period 2. [ Hint: Make a vertical shift to simplify the calculations.] Solution: We rst shift the function down by 4 units to make it an odd function, i.e., we create a new function f (x) = f (x) 4 and compute the Fourier series F (x) (x). Once we have computed F (x), we then transform back to obtain our desired for f result of F (x) = F (x) + 4. Thus f (x) = f (x) 4 = 1, < x < 0 . 1, 0 x < Example 19.13 Consider the function f (x) = x2 + x, (a) Sketch the function f . (b) Write down the odd extension fo of f to the interval [, ]. Sketch the odd extension fo on [, ]. (c) Why are all the Fourier coecients an of fo on [, ] zero? (d) Compute all the Fourier coecients bn as a function of n. Evaluate the rst three non-zero coecients bn explicitly. (e) What are the values of the coecients bn for even n? (f ) Write down the Fourier series of fo . f (x) sin (nx) dx
0

x [0, ].

Since f (x) is an odd function then both a0 and an are equal to zero. Our work is now reduced to calculating bn . bn = 1 L
L

f (x) sin
L

nx L

dx

1 2

f (x) sin

nx

dx

(g) Does the Fourier series of fo coincide with the original function f for x [0, ]? Why? (h) Hence show that
=0

2 =

sin (nx) dx
0

3 (1) = . 3 (2 + 1) 32

1 2 cos (nx) = n 0 2 = [cos (n) 1] n Only for odd values of n do we obtain a non-zero result for bn , i.e., b21 = Thus 4 F (x) = 4 , (2 1)
=1

Solution:

= 1, 2, 3, . . .

1 sin ((2 1)x) . 2 1 84

CHAPTER 19. FOURIER SERIES (cont.) (cont.)

85

The story so far . . .


We introduced the inner product for functions f and g on the interval [a, b]:
b

f, g =
a

f (x) g(x) dx.

(This is analogous to the scalar product for vectors.) We also said that f and g are orthogonal on the interval [a, b]
b

f, g =
a

f (x) g(x) dx = 0.

Also dened the norm f of a function f on the interval [a, b]: b 1/2 f = We then showed the set of trigonometric functions {0 , 1 , 1 , 2 , 2 , . . .} on [L, L], given by n x , n = 0, 1, 2, . . . , n (x) = cos L n x , n = 1, 2, 3, . . . , n (x) = sin L are an orthogonal set on [L, L].
289

f, f =

|f (x)|2 dx

We then said we could write a function f in terms of this orthogonal set. The Fourier series F of a function f on [L, L] (with f < ) with respect to the complete orthogonal set of trigonometric functions on [L, L] is given by n a0 n F (x) = + x + bn sin x an cos 2 L L n=1 with the Fourier coecients an and bn given by an = 1 L 1 L
L

f (x) cos
L L

n x dx, L n x dx, L

n = 0, 1, 2, . . . ,

bn =

f (x) sin
L

n = 1, 2, 3, . . . .

NOTE. The function f and corresponding Fourier series F are the same except may be at a nite number of x values. In Section 19.4 we discuss if our function f is odd on the interval [L, L] then F would be a Fourier sine series, i.e., an = 0 for n = 0, 1, 2, . . .. Similarly if our function f is even on the interval [L, L] then F would be a Fourier cosine series, i.e., bn = 0 for n = 1, 2, 3, . . .. Let us continue by starting Section 19.5.
290

You might also like