18.01 Single Variable Calculus, All Notes

Download as pdf or txt
Download as pdf or txt
You are on page 1of 193
At a glance
Powered by AI
The document discusses lecture notes for a calculus course covering topics like derivatives, integrals, techniques of integration, and series expansions.

The lecture notes cover topics related to derivatives, integrals, techniques of integration, and series expansions across various sessions.

Applications of derivatives like linear and quadratic approximations, curve sketching, max-min problems, related rates, and differential equations are discussed.

SES #

TOPICS

LECTURE NOTES

Derivatives 1

Derivatives, slope, velocity, rate of change Limits, continuity, Trigonometric limits

(PDF - 1.1 MB)

(PDF - 2.6 MB)

Derivatives of products, quotients, sine, cosine Chain rule, Higher derivatives

(PDF)

(PDF) Ses #1-7 complete (PDF - 5.2 MB)

Implicit differentiation, inverses Exponential and Log, hyperbola func

(PDF)

(PDF)

Hyperbolic functions and exam 1 review Exam 1 covering Ses #1-7

(PDF) (No Lecture Notes)

Applications of Differentiation
9

Linear and quadratic approximations Curve sketching Max-min problems Related rates Newton's method and other applications Mean value theorem, Inequalities

(PDF)

10

(PDF - 1.8 MB)

11

(PDF - 1.1 MB)

12

(PDF - 1.0 MB)

13

(PDF - 1.2 MB) Ses #9-16 complete (PDF - 6.9 MB)

14

(PDF)

15

Differentials, antiderivatives Differential equations, separation of variables Exam 2 covering Ses #8-16

(PDF)

16

(PDF) (No Lecture Notes)

17

Integration
18

Definite integrals First fundamental theorem of calculus Second fundamental theorem

(PDF)

19

(PDF)

Ses #18-25 complete (PDF - 8.6 MB)

20

(PDF)

SES # 21

TOPICS

LECTURE NOTES (PDF - 1.4 MB)

Applications to logarithms and geometry Volumes by disks and shells Work, average value, probability Numerical integration Exam 3 review

22

(PDF - 1.7 MB)

23

(PDF - 2.2 MB)

24

(PDF - 1.1 MB)

25

(PDF)

Techniques of Integration
26

Trigonometric integrals and substitution Exam 3 covering Ses #18-24 Integration by inverse substitution; completing the square Partial fractions Integration by parts, reduction formulae Parametric equations, arclength, surface area Polar coordinates Exam 4 review

(PDF) (No Lecture Notes)

27

28

(PDF)

29

(PDF)

30

(PDF - 1.4 MB)

31

(PDF)

32

(PDF - 2.0 MB) (PDF)

Ses #26-38 complete (PDF - 8.6 MB)

33

Exam 4 covering Ses #26-32 Indeterminate forms - L'Hspital's rule Improper integrals Infinite series and convergence tests Taylor's series Final review

(No Lecture Notes) (PDF)

34

35

(PDF)

36

(PDF - 1.4 MB)

37

(PDF)

38

(PDF)

MIT OpenCourseWare http://ocw.mit.edu

18.01 Single Variable Calculus


Fall 2006

For information about citing these materials or our Terms of Use, visit: http://ocw.mit.edu/terms.

Lecture 1

18.01 Fall 2006

Unit 1: Derivatives
A. What is a derivative?
Geometric interpretation Physical interpretation Important for any measurement (economics, political science, nance, physics, etc.)

B. How to dierentiate any function you know.


d x arctan x For example: e . We will discuss what a derivative is today. Figuring out how to dx dierentiate any function is the subject of the rst two weeks of this course.

Lecture 1: Derivatives, Slope, Velocity, and Rate of Change


Geometric Viewpoint on Derivatives

Q Secant line P f(x) x0 x0+x Tangent line

Figure 1: A function with secant and tangent lines The derivative is the slope of the line tangent to the graph of f (x). But what is a tangent line, exactly? 1

Lecture 1

18.01 Fall 2006

It is NOT just a line that meets the graph at one point. It is the limit of the secant line (a line drawn between two points on the graph) as the distance between the two points goes to zero.

Geometric denition of the derivative:


Limit of slopes of secant lines P Q as Q P (P xed). The slope of P Q:

(x0+x, f(x0+x))

Secant Line

(x0, f(x0))

x
Figure 2: Geometric denition of the derivative

x0

lim

f x

= lim

x0

dierence quotient

f (x0 + x) f (x0 ) x

f (x0 ) derivative of f at x0

Example 1. f (x) =

1 x

One thing to keep in mind when working with derivatives: it may be tempting to plug in x = 0 f 0 right away. If you do this, however, you will always end up with = . You will always need to x 0 do some cancellation to get at the answer. f = x
1 x0 +x

1 x0

1 1 x0 (x0 + x) 1 x = = = x (x0 + x)x0 x (x0 + x)x0 (x0 + x)x0 1 1 = 2 (x0 + x)x0 x0

Taking the limit as x 0,


x0

lim

Lecture 1

18.01 Fall 2006

x0
Figure 3: Graph of Hence, f (x0 ) =
1 x

1 x2 0

Notice that f (x0 ) is negative as is the slope of the tangent line on the graph above. Finding the tangent line. Write the equation for the tangent line at the point (x0 , y0 ) using the equation for a line, which you all learned in high school algebra: y y0 = f (x0 )(x x0 ) Plug in y0 = f (x0 ) = 1 1 and f (x0 ) = 2 to get: x0 x0 y 1 1 = 2 (x x0 ) x0 x0

Lecture 1

18.01 Fall 2006

x0
Figure 4: Graph of
1 x

Just for fun, lets compute the area of the triangle that the tangent line forms with the x- and y-axes (see the shaded region in Fig. 4). First calculate the x-intercept of this tangent line. The x-intercept is where y = 0. Plug y = 0 into the equation for this tangent line to get: 0 1 x0 1 x0 1 x x2 0 x = = = = 1 (x x0 ) x2 0 1 1 x+ x2 x 0 0 2 x0 2 x2 ) = 2x0 0( x0

So, the x-intercept of this tangent line is at x = 2x0 . 1 1 and x = are identical equations, x y the graph is symmetric when x and y are exchanged. By symmetry, then, the y-intercept is at y = 2y0 . If you dont trust reasoning with symmetry, you may follow the same chain of algebraic reasoning that we used in nding the x-intercept. (Remember, the y-intercept is where x = 0.) Next we claim that the y-intercept is at y = 2y0 . Since y = Finally, Area = 1 1 (2y0 )(2x0 ) = 2x0 y0 = 2x0 ( ) = 2 (see Fig. 5) 2 x0

Curiously, the area of the triangle is always 2, no matter where on the graph we draw the tangent line.

Lecture 1

18.01 Fall 2006

y x-1

2y0 y0

x0

2x0
1 x

Figure 5: Graph of

Notations
Calculus, rather like English or any other language, was developed by several people. As a result, just as there are many ways to express the same thing, there are many notations for the derivative. Since y = f (x), its natural to write y = f = f (x) f (x0 ) = f (x0 + x) f (x0 ) We say Delta y or Delta f or the change in y . If we divide both sides by x = x x0 , we get two expressions for the dierence quotient: y f = x x Taking the limit as x 0, we get y x f x dy (Leibniz notation) dx f (x0 ) (Newtons notation)

When you use Leibniz notation, you have to remember where youre evaluating the derivative in the example above, at x = x0 . Other, equally valid notations for the derivative of a function f include df , f , and Df dx

Lecture 1

18.01 Fall 2006

Example 2. f (x) = xn where n = 1, 2, 3...


What is d n x ? dx To nd it, plug y = f (x) into the denition of the dierence quotient. y (x0 + x)n xn (x + x)n xn 0 = = x x x (From here on, we replace x0 with x, so as to have less writing to do.) Since (x + x)n = (x + x)(x + x)...(x + x) We can rewrite this as xn + n(x)xn1 + O (x)2 O(x)2 is shorthand for all of the terms with (x)2 , (x)3 , and so on up to (x)n . (This is part of what is known as the binomial theorem; see your textbook for details.) y (x + x)n xn xn + n(x)(xn1 ) + O(x)2 xn = = = nxn1 + O(x) x x x Take the limit:
x0

n times

lim

y = nxn1 x

Therefore,

d n x = nxn1 dx This result extends to polynomials. For example, d 2 (x + 3x10 ) = 2x + 30x9 dx

Physical Interpretation of Derivatives


You can think of the derivative as representing a rate of change (speed is one example of this). On Halloween, MIT students have a tradition of dropping pumpkins from the roof of this building, which is about 400 feet high. The equation of motion for objects near the earths surface (which we will just accept for now) implies that the height above the ground y of the pumpkin is: y = 400 16t2 The average speed of the pumpkin (dierence quotient) = When the pumpkin hits the ground, y = 0, 400 16t2 = 0 6 y distance travelled = t time elapsed

Lecture 1

18.01 Fall 2006

Solve to nd t = 5. Thus it takes 5 seconds for the pumpkin to reach the ground. Average speed = 400 ft = 80 ft/s 5 sec

A spectator is probably more interested in how fast the pumpkin is going when it slams into the ground. To nd the instantaneous velocity at t = 5, lets evaluate y : y = 32t = (32)(5) = 160 ft/s (about 110 mph)

y is negative because the pumpkins y-coordinate is decreasing: it is moving downward.

Lecture 2

18.01 Fall 2006

Lecture 2: Limits, Continuity, and Trigonometric Limits

More about the rate of change interpretation of the derivative

y = f(x)
y

x
Figure 1: Graph of a generic function, with x and y marked on the graph

y x Average rate of change

dy as x 0 dx Instantaneous rate of change

Examples
1. q = charge 2. s = distance 3. T = temperature dq = electrical current dt ds = speed dt dT = temperature gradient dx

Lecture 2

18.01 Fall 2006

4. Sensitivity of measurements: An example is carried out on Problem Set 1. In GPS, radio signals give us h up to a certain measurement error (See Fig. 2 and Fig. 3). The question is L how accurately can we measure L. To decide, we nd . In other words, these variables are h related to each other. We want to nd how a change in one variable aects the other variable.

satellite

you

Figure 2: The Global Positioning System Problem (GPS)

s L

Figure 3: On problem set 1, you will look at this simplied at earth model

Lecture 2

18.01 Fall 2006

Limits and Continuity


Easy Limits
x2 + x 32 + 3 12 = = =3 x 3 x + 1 3+1 4 With an easy limit, you can get a meaningful answer just by plugging in the limiting value. lim Remember,
xx0

lim

f f (x0 + x) f (x0 ) = lim x xx0 x

is never an easy limit, because the denominator x = 0 is not allowed. (The limit x x0 is computed under the implicit assumption that x = x0 .)

Continuity
We say f (x) is continuous at x0 when
xx0

lim f (x) = f (x0 )

Pictures

x
Figure 4: Graph of the discontinuous function listed below

f (x) =

x+1 x

x>0 x0

Lecture 2

18.01 Fall 2006

This discontinuous function is seen in Fig. 4. For x > 0,


x 0

lim f (x) = 1

but f (0) = 0. (One can also say, f is continuous from the left at 0, not the right.) 1.

Removable Discontinuity

Figure 5: A removable discontinuity: function is continuous everywhere, except for one point

Denition of removable discontinuity Right-hand limit: lim+ f (x) means lim f (x) for x > x0 .
xx0 xx0

Left-hand limit:
xx0 xx0

xx 0

lim f (x) means lim f (x) for x < x0 .


xx0

If lim+ f (x) = lim f (x) but this is not f (x0 ), or if f (x0 ) is undened, we say the discontinuity is removable. For example, sin(x) is dened for x = 0. We will see later how to evaluate the limit as x 0. x

Lecture 2

18.01 Fall 2006

2.

Jump Discontinuity

x0
Figure 6: An example of a jump discontinuity
xx+ 0

lim for (x < x0 ) exists, and lim for (x > x0 ) also exists, but they are NOT equal.
xx0

3.

Innite Discontinuity

Figure 7: An example of an innite discontinuity: Right-hand limit: lim 1 = ; x Left-hand limit: lim

1 x

x0+

x0

1 = x

Lecture 2

18.01 Fall 2006

4.

Other (ugly) discontinuities

Figure 8: An example of an ugly discontinuity: a function that oscillates a lot as it approaches the origin This function doesnt even go to it doesnt make sense to say it goes to anything. For something like this, we say the limit does not exist.

Lecture 2

18.01 Fall 2006

Picturing the derivative

y x

Figure 9: Top: graph of f (x) =

1 1 and Bottom: graph of f (x) = 2 x x

Notice that the graph of f (x) does NOT look like the graph of f (x)! (You might also notice that f (x) is an odd function, while f (x) is an even function. The derivative of an odd function is always even, and vice versa.)

Lecture 2

18.01 Fall 2006

Pumpkin Drop, Part II This time, someone throws a pumpkin over the tallest building on campus.

Figure 10: y = 400 16t2 , 5 t 5

Figure 11: Top: graph of y(t) = 400 16t2 . Bottom: the derivative, y (t)

Lecture 2

18.01 Fall 2006

Two Trig Limits


Note: In the expressions below, is in radians NOT degrees! sin = 1; 1 cos =0

lim

lim

Here is a geometric proof for the rst limit:

sin

arc length =

Figure 12: A circle of radius 1 with an arc of angle

sin

arc length =

Figure 13: The sector in Fig. 12 as becomes very small Imagine what happens to the picture as gets very small (see Fig. 13). As 0, we see that sin 1. 9

Lecture 2

18.01 Fall 2006

What about the second limit involving cosine?

arc length =

cos

1 - cos

Figure 14: Same picture as Fig. 12 except that the horizontal distance between the edge of the triangle and the
perimeter of the circle is marked

From Fig. 15 we can see that as 0, the length 1 cos of the short segment gets much 1 cos smaller than the vertical distance along the arc. Hence, 0.

1
cos

arc length =

1 - cos

Figure 15: The sector in Fig. 14 as becomes very small

10

Lecture 2

18.01 Fall 2006

We end this lecture with a theorem that will help us to compute more derivatives next time. Theorem: Dierentiable Implies Continuous. If f is dierentiable at x0 , then f is continuous at x0 . Proof: lim (f (x) f (x0 )) = lim
xx0 xx0

f (x) f (x0 ) (x x0 ) = f (x0 ) 0 = 0. x x0 x x0 . It looks as x x0

Remember: you can never divide by zero! The rst step was to multiply by

0 if this is illegal because when x = x0 , we are multiplying by . But when computing the limit as 0 x x0 we always assume x = x0 . In other words x x0 = 0. So the proof is valid.

11

Lecture 3

18.01 Fall 2006

Lecture 3 Derivatives of Products, Quotients, Sine, and Cosine

Derivative Formulas
There are two kinds of derivative formulas: d n d 1 1. Specic Examples: x or dx dx x 2. General Examples: (u + v ) = u + v and (cu) = cu (where c is a constant) A notational convention we will use today is: (u + v )(x) = u(x) + v (x); uv (x) = u(x)v (x)

Proof of (u + v ) = u + v . (General)
Start by using the denition of the derivative. (u + v ) (x) = = = (u + v ) (x) = (u + v )(x + x) (u + v )(x) x0 x u(x + x) + v (x + x) u(x) v (x) lim x0 x u(x + x) u(x) v (x + x) v (x) lim + x0 x x u (x) + v (x) lim

Follow the same procedure to prove that (cu) = cu .

Derivatives of sin x and cos x. (Specic)


Last time, we computed lim sin x x = = = 1 sin(0 + x) sin(0) sin(x) = lim = 1 x 0 x x cos(0 + x) cos(0) cos(x) 1 lim = lim = 0 x0 x0 x x
x0

x0

d (sin x)|x=0 dx d (cos x)|x=0 dx

lim

So, we know the value of

d d sin x and of cos x at x = 0. Let us nd these for arbitrary x. dx dx d sin(x + x) sin(x) sin x = lim x0 dx x 1

Lecture 3

18.01 Fall 2006

Recall: sin(a + b) = sin(a) cos(b) + sin(b) cos(a) So, d sin x dx = = = sin x cos x + cos x sin x sin(x) x sin x(cos x 1) cos x sin x lim + x0 x x cos x 1 sin x lim sin x + lim cos x x0 x0 x x
x0

lim

Since

cos x 1 sin x 0 and that 1, the equation above simplies to x x d sin x = cos x dx

A similar calculation gives d cos x = sin x dx

Product formula (General)


(uv ) = u v + uv Proof: (uv ) = lim Now obviously, u(x + x)v (x) u(x + x)v (x) = 0 so adding that to the numerator wont change anything. (uv ) = lim u(x + x)v (x) u(x)v (x) + u(x + x)v (x + x) u(x + x)v (x) x0 x
x0

(uv )(x + x) (uv )(x) u(x + x)v (x + x) u(x)v (x) = lim x 0 x x

We can re-arrange that expression to get u(x + x) u(x) v (x + x) v (x) (uv ) = lim v (x) + u(x + x) x0 x x Remember, the limit of a sum is the sum of the limits. u(x + x) u(x) v (x + x) v (x) lim v (x) + lim u(x + x) x0 x0 x x (uv ) = u (x)v (x) + u(x)v (x) Note: we also used the fact that
x0

lim u(x + x) = u(x)

(true because u is continuous)

This proof of the product rule assumes that u and v have derivatives, which implies both functions are continuous. 2

Lecture 3

18.01 Fall 2006

v v

Figure 1: A graphical proof of the product rule An intuitive justication: We want to nd the dierence in area between the large rectangle and the smaller, inner rectangle. The inner (orange) rectangle has area uv . Dene u, the change in u, by u = u(x + x) u(x) We also abbreviate u = u(x), so that u(x + x) = u + u, and, similarly, v (x + x) = v + v . Therefore the area of the largest rectangle is (u + u)(v + v ). If you let v increase and keep u constant, you add the area shaded in red. If you let u increase and keep v constant, you add the area shaded in yellow. The sum of areas of the red and yellow rectangles is: [u(v + v ) uv ] + [v (u + u) uv ] = uv + v u If u and v are small, then (u)(v ) 0, that is, the area of the white rectangle is very small. Therefore the dierence in area between the largest rectangle and the orange rectangle is approximately the same as the sum of areas of the red and yellow rectangles. Thus we have: [(u + u)(v + v ) uv ] uv + v u (Divide by x and let x 0 to nish the argument.)

Lecture 3

18.01 Fall 2006

Quotient formula (General)


To calculate the derivative of u/v , we use the notations u and v above. Thus, u(x + x) u(x) v (x + x) v (x) = = = Hence, 1 x Therefore, u + u u v v + v = ( v u ) )v u( x x (v + v )v v( dv du ) u( ) dx dx v2 u + u u v + v v (u + u)v u(v + v ) (common denominator) (v + v )v (u)v u(v ) (cancel uv uv ) (v + v )v

as x 0

u u v uv ( ) = v v2

Lecture 4

Sept. 14, 2006

18.01 Fall 2006

Lecture 4 Chain Rule, and Higher Derivatives

Chain Rule
Weve got general procedures for dierentiating expressions with addition, subtraction, and multiplication. What about composition? Example 1. y = f (x) = sin x, x = g (t) = t2 . dy , write So, y = f (g (t)) = sin(t2 ). To nd dt t0 = t0 x0 = g (t0 ) y0 = f (x0 ) t = t0 + t x = x0 + x y = y0 + y

y y x = t x t As t 0, x 0 too, because of continuity. So we get: dy dy dx The Chain Rule! = dt dx dt In the example, dx dy = 2t and = cos x. dt dx

So,

d sin(t2 ) dt

= = =

dy dx )( ) dx dt (cos x)(2t) (2t) cos(t2 ) (

Another notation for the chain rule


d f (g (t)) = f (g (t))g (t) dt Example 1. (continued) or d f (g (x)) = f (g (x))g (x) dx

Composition of functions f (x) = sin x and g (x) = x2 = = = f (g (x)) g (f (x)) g f. = = sin(x2 ) sin2 (x)

(f g )(x) (g f )(x) Note: f g

Not Commutative!

Lecture 4

Sept. 14, 2006

18.01 Fall 2006

g(x)

f(g(x))

Figure 1: Composition of functions: f g(x) = f (g(x)) d cos dx 1 =? x

Example 2. Let u = 1 x

dy dx dy du dy dx Example 3. d n x =? dx

= =

dy du du dx sin(u); du 1 = 2 dx x

1 sin sin(u) 1 x = ( sin u) = x2 x2 x2

There are two ways to proceed. xn =

n 1 1 , or xn = n x x

n n1 1 1 1 = n = nx(n1) x2 = nxn1 x x x2 d n d 1 1 n1 2. x = = nx = nxn1 (Think of xn as u) dx dx xn x2n d n d 1. x = dx dx

Lecture 4

Sept. 14, 2006

18.01 Fall 2006

Higher Derivatives
Higher derivatives are derivatives of derivatives. For instance, if g = f , then h = g is the second derivative of f . We write h = (f ) = f .

Notations
f (x) f (x) f (x) f (n) (x) Df D2 f D3 f Dn f df dx d2 f dx2 d3 f dx3 dn f dxn

Higher derivatives are pretty straightforward - just keep taking the derivative! Example. Dn xn = ? Start small and look for a pattern. Dx D x D x D x
2 2

= = = = =

1 D(2x) = 2
3 3

( = 1 2) ( = 1 2 3) ( = 1 2 3 4)
2 2

D 3 x3
4 4 n n

D2 (3x2 ) = D(6x) = 6

D (4x ) = D (12x ) = D(24x) = 24

n! we guess, based on the pattern were seeing here.

The notation n! is called n factorial and dened by n! = n(n 1) 2 1 Proof by Induction: Weve already checked the base case (n = 1). Induction step: Suppose we know Dn xn = n! (nth case). Show it holds for the (n + 1)st case. Dn+1 xn+1 = Dn Dxn+1 = Dn ((n + 1)xn ) = (n + 1)Dn xn = (n + 1)(n!) Dn+1 xn+1 Proved! = (n + 1)!

Lecture 5

18.01 Fall 2006

Lecture 5 Implicit Dierentiation and Inverses

Implicit Dierentiation
d a Example 1. (x ) = axa1 . dx We proved this by an explicit computation for a = 0, 1, 2, .... From this, we also got the formula for a = 1, 2, .... Let us try to extend this formula to cover rational numbers, as well: m a= ; n We want to compute m y=xn where m and n are integers. so ny n1 dy dy = mxm1 . Solve for : dx dx

dy . We can say y n = xm dx

dy m xm1 = dx n y n1
m We know that y = x( n ) is a function of x.

dy dx

= = = = = = =

So,

dy dx

m xm1 n y n1 m xm1 n (xm/n )n1 m xm1 n xm(n1)/n m (m1) m(n1) n x n m n(m1)m(n1) n x n m nmnnm+m n x n m mn n xn n m m 1 xn n

This is the same answer as we were hoping to get!


2 2 2 2 Example 2. Equation of a circle with a radius of 1: x + y = 1 which we can write as y = 1 x . 2 So y = 1 x . Let us look at the positive case:

y dy dx

= =

1 + 1 x2 = (1 x2 ) 2 1 1 x x (1 x2 ) 2 (2x) = = 2 2 y 1x 1

Lecture 5

18.01 Fall 2006

Now, lets do the same thing, using implicit dierentiation. x2 + y 2 d 2 x + y2 dx d 2 d 2 (x ) + (y ) dx dx Applying chain rule in the second term, dy dx dy 2y dx dy dx Same answer! 2x + 2y Example 3. = = = 0 2x x y = = = 1 d (1) = 0 dx 0

y 3 + xy 2 + 1 = 0. In this case, its not easy to solve for y as a function of x. Instead, dy we use implicit dierentiation to nd . dx 3y 2 We can now solve for dy dy + y 2 + 2xy = 0 dx dx

dy in terms of y and x. dx dy (3y 2 + 2xy ) dx dy dx = = y 2 3y 2 y 2 + 2xy

Inverse Functions
If y = f (x) and g (y ) = x, we call g the inverse function of f , f 1 : x = g (y ) = f 1 (y ) Now, let us use implicit dierentiation to nd the derivative of the inverse function. y f (y ) d 1 (f (y )) dx By the chain rule: d 1 dy (f (y )) = dy dx and d 1 (f (y )) = dy 1 1 dy dx
1

= = =

f (x) x d (x) = 1 dx

Lecture 5

18.01 Fall 2006

So, implicit dierentiation makes it possible to nd the derivative of the inverse function. Example. y = arctan(x) tan y d [tan(y )] dx d dy [tan(y )] dy dx 1 dy 2 cos (y ) dx dy dx = = = = = x dx = 1 dx 1 1 cos2 (y ) = cos2 (arctan(x))

This form is messy. Let us use some geometry to simplify it.

y 1

(1+x2)1/2

x
Figure 1: Triangle with angles and lengths corresponding to those in the example illustrating dierentiation using
the inverse function arctan

In this triangle, tan(y ) = x so arctan(x) = y The Pythagorian theorem tells us the length of the hypotenuse: h = 1 + x2 From this, we can nd cos(y ) = From this, we get cos (y ) =
2

1 1 + x2 2 = 1 1 + x2

1 1 + x2 3

Lecture 5

18.01 Fall 2006

So, dy 1 = dx 1 + x2 In other words, d 1 arctan(x) = dx 1 + x2

Graphing an Inverse Function.


Suppose y = f (x) and g (y ) = f 1 (y ) = x. To graph g and f together we need to write g as a function of the variable x. If g (x) = y , then x = f (y ), and what we have done is to trade the variables x and y . This is illustrated in Fig. 2 f 1 (f (x)) = x f (f 1 (x)) = x f 1 f (x) = x f f 1 (x) = x

f(x)

y=x g(x)

b=f(a)

a=f-1(b)

Figure 2: You can think about f 1 as the graph of f reected about the line y = x

Lecture 6

18.01 Fall 2006

Lecture 6: Exponential and Log, Logarithmic Dierentiation, Hyperbolic Functions

Taking the derivatives of exponentials and logarithms


Background
We always assume the base, a, is greater than 1. a0 = 1; ax1 +x2 (ax1 )
x2
p q

a1 = a; ax1 ax2

a2 = a a;

...

= = =

a x1 x2 q ap (where p and q are integers)

To dene ar for real numbers r, ll in by continuity.

Todays main task: nd


We can write

d x a dx
d x ax+x ax a = lim x0 dx x

We can factor out the ax : ax+x ax ax 1 a x 1 = lim ax = ax lim x0 x0 x0 x x x lim Lets call ax 1 x0 x We dont yet know what M (a) is, but we can say M (a) lim d x a = M (a)ax dx Here are two ways to describe M (a): 1. Analytically M (a) = d x a at x = 0. dx

a0+x a0 d x Indeed, M (a) = lim = a x0 x dx x=0

Lecture 6

18.01 Fall 2006

ax

M(a) (slope of ax at x=0)

Figure 1: Geometric denition of M (a) 2. Geometrically, M (a) is the slope of the graph y = ax at x = 0. The trick to guring out what M (a) is is to beg the question and dene e as the number such that M (e) = 1. Now can we be sure there is such a number e? First notice that as the base a increases, the graph ax gets steeper. Next, we will estimate the slope M (a) for a = 2 and a = 4 geometrically. Look at the graph of 2x in Fig. 2. The secant line from (0, 1) to (1, 2) of the graph y = 2x has slope 1. Therefore, the slope of y = 2x at x = 0 is less: M (2) < 1 (see Fig. 2). 1 1 Next, look at the graph of 4x in Fig. 3. The secant line from ( , ) to (1, 0) on the graph of 2 2 y = 4x has slope 1. Therefore, the slope of y = 4x at x = 0 is greater than M (4) > 1 (see Fig. 3). Somewhere in between 2 and 4 there is a base whose slope at x = 0 is 1.

Lecture 6

18.01 Fall 2006

y=2x
slope = 1 (1,2) e lin t n eca slope M(2)

Figure 2: Slope M (2) < 1

y=4x
(4)

(-1/2, 1/2)

(1,0)

t lin secan

eM p o l s

Figure 3: Slope M (4) > 1

Lecture 6

18.01 Fall 2006

Thus we can dene e to be the unique number such that M (e) = 1 or, to put it another way, eh 1 =1 h0 h lim or, to put it still another way, d x (e ) = 1 dx What is d x (e )? dx We just dened M (e) = 1, and at x = 0 d x (e ) = M (e)ex . So dx

d x (e ) = ex dx

Natural log (inverse function of ex )


To understand M (a) better, we study the natural log function ln(x). This function is dened as follows: If y = ex , then ln(y ) = x (or) If w = ln(x), then ex = w Note that ex is always positive, even if x is negative. Recall that ln(1) = 0; ln(x) < 0 for 0 < x < 1; ln(x) > 0 for x > 1. Recall also that

ln(x1 x2 ) = ln x1 + ln x2 Let us use implicit dierentiation to nd d ln(x). dx = = = = = w = ln(x). We want to nd dw . dx

ew d w (e ) dx d w dw (e ) dw dx w dw e dx dw dx

x d (x) dx 1 1 1 1 = ew x

d 1 (ln(x)) = dx x 4

Lecture 6

18.01 Fall 2006

Finally, what about

d x (a )? dx

There are two methods we can use: Method 1: Write base e and use chain rule. Rewrite a as eln(a) . Then, x ax = eln(a) = ex ln(a)

That looks like it might be tricky to dierentiate. Lets work up to it: d x e dx d 3x e dx = and by the chain rule, = 3e3x ex

Remember, ln(a) is just a constant number not a variable! Therefore, d (ln a)x e dx = or (ln a)e(ln a)x

d x (a ) = ln(a) ax dx Recall that d x (a ) = M (a) ax dx M (a) = ln(a).

So now we know the value of M (a):

Even if we insist on starting with another base, like 10, the natural logarithm appears: d x 10 = (ln 10)10x dx The base e may seem strange at rst. But, it comes up everywhere. After a while, youll learn to appreciate just how natural it is. Method 2: Logarithmic Dierentiation. The idea is to nd u = f (x). d d f (x) by nding ln(f (x)) instead. Sometimes this approach is easier. Let dx dx d d ln(u) du 1 du ln(u) = = dx du dx u dx

Since u = f and

du = f , we can also write dx (ln f ) = f f or f = f (ln f )

Lecture 6

18.01 Fall 2006

Apply this to f (x) = ax . ln f (x) = x ln a = d d d ln(f ) = ln(ax ) = (x ln(a)) = ln(a). dx dx dx

(Remember, ln(a) is a constant, not a variable.) Hence, d f d x (ln f ) = ln(a) = = ln(a) = f = ln(a)f = a = (ln a)ax dx f dx

Example 1.

d x (x ) = ? dx

With variable (moving) exponents, you should use either base e or logarithmic dierentiation. In this example, we will use the latter. f ln f (ln f )

= = = =

xx x ln x 1 1 (ln x) + x = ln(x) + 1 x f f

(ln f ) Therefore,

f = f (ln f ) = xx (ln(x) + 1) If you wanted to solve this using the base e approach, you would say f = ex ln x and dierentiate it using the chain rule. It gets you the same answer, but requires a little more writing. k 1 1+ . k k

Example 2. Use logs to evaluate lim

Because the exponent k changes, it is better to nd the limit of the logarithm.


k

lim ln

1 1+ k

We know that ln

1 1+ k

1 = k ln 1 + k

1 0. This expression has two competing parts, which balance: k while ln 1 + k k 1 ln 1 + k 1 1 ln(1 + h) 1 ln 1 + = k ln 1 + = = (with h = ) 1 k k h k k Next, because ln 1 = 0 k 1 ln(1 + h) ln(1) ln 1 + = k h 6

Lecture 6

18.01 Fall 2006

Take the limit: h =

1 0 as k , so that k ln(1 + h) ln(1) d = ln(x) =1 h0 h dx x=1 lim

In all, k 1 lim ln 1 + = 1. k k k 1 We have just found that ak = ln[ 1 + ] 1 as k . k k 1 If bk = 1 + , then bk = eak e1 as k . In other words, we have evaluated the limit we k wanted: k 1 lim 1 + =e k k Remark 1. We never gured out what the exact numerical value of e was. Now we can use this limit formula; k = 10 gives a pretty good approximation to the actual value of e. Remark 2. Logs are used in all sciences and even in nance. Think about the stock market. If I say the market fell 50 points today, youd need to know whether the market average before the drop was 300 points or 10, 000. In other words, you care about the percent change, or the ratio of the change to the starting value: f (t) d = ln(f (t)) f (t) dt

Lecture 7

18.01 Fall 2006

Lecture 7: Continuation and Exam Review


Hyperbolic Sine and Cosine
Hyperbolic sine (pronounced sinsh): sinh(x) = Hyperbolic cosine (pronounced cosh): ex + ex 2 x d d e ex ex (ex ) sinh(x) = = = cosh(x) dx dx 2 2 cosh(x) = Likewise, d cosh(x) = sinh(x) dx (Note that this is dierent from Important identity: cosh2 (x) sinh2 (x) = 1 Proof: cosh2 (x) sinh2 (x) cosh2 (x) sinh2 (x) = = 2 x 2 e x + e x e e x 2 2 1 2x 1 2x 1 e + 2ex ex + e2x e 2 + e2x = (2 + 2) = 1 4 4 4 d cos(x).) dx e x e x 2

Why are these functions called hyperbolic? Let u = cosh(x) and v = sinh(x), then u2 v 2 = 1 which is the equation of a hyperbola. Regular trig functions are circular functions. If u = cos(x) and v = sin(x), then u2 + v 2 = 1 which is the equation of a circle.

Lecture 7

18.01 Fall 2006

Exam 1 Review
General Dierentiation Formulas
(u + v ) (cu) (uv ) u v d f (u(x)) dx = = = = = u + v cu u v + uv (product rule) u v uv (quotient rule) v2 f (u(x)) u (x) (chain rule)

You can remember the quotient rule by rewriting u = (uv 1 ) v and applying the product rule and chain rule.

Implicit dierentiation
Lets say you want to nd y from an equation like y 3 + 3xy 2 = 8 d Instead of solving for y and then taking its derivative, just take of the whole thing. In this dx example, 3y 2 y + 6xyy + 3y 2 (3y 2 + 6xy )y y = = = 0 3y 2 3y 2 3y 2 + 6xy

Note that this formula for y involves both x and y . Implicit dierentiation can be very useful for taking the derivatives of inverse functions. For instance, y = sin1 x sin y = x Implicit dierentiation yields (cos y )y = 1 and y = 1 1 = cos y 1 x2

Lecture 7

18.01 Fall 2006

Specic dierentiation formulas


You will be responsible for knowing formulas for the derivatives and how to deduce these formulas from previous information: xn , sin1 x, tan1 x, sin x, cos x, tan x, sec x, ex , ln x . For example, lets calculate d sec x: dx

d d 1 ( sin x) sec x = = = tan x sec x dx dx cos x cos2 x You may be asked to nd d d sin x or cos x, using the following information: dx dx sin(h) h cos(h) 1 lim h0 h
h0

lim

= =

1 0

Remember the denition of the derivative: d f (x + x) f (x) f (x) = lim x0 dx x

Tying up a loose end


d r How to nd x , where r is a real (but not necessarily rational) number? All we have done so far dx is the case of rational numbers, using implicit dierentiation. We can do this two ways: 1st method: base e eln x ln x r e = er ln x d r ln x d r e = er ln x (r ln x) = er ln x dx dx x r r r 1 x = rx x

x xr d r x dx d r x dx

= = = =

2nd method: logarithmic dierentiation f f xr r ln x r x r xr = rxr1 x 3

(ln f ) f ln f (ln f ) f = f (ln f )

= = = = =

Lecture 7

18.01 Fall 2006

Finally, in the rst lecture I promised you that youd learn to dierentiate anything even something as complicated as d x tan1 x e dx So lets do it! d uv e dx Substituting, d x tan1 x e dx = euv d (uv ) = euv (u v + uv ) dx
1

ex tan

tan1 x + x

1 1 + x2

MIT OpenCourseWare http://ocw.mit.edu

18.01 Single Variable Calculus


Fall 2006

For information about citing these materials or our Terms of Use, visit: http://ocw.mit.edu/terms.

Lecture 9

18.01 Fall 2006

Lecture 9: Linear and Quadratic Approximations

Unit 2: Applications of Dierentiation


Today, well be using dierentiation to make approximations.

Linear Approximation

y = b+a(x-x0) b = f(x0) ; a = f(x0 )

y=f(x)

(x0 ,f(x0 ))

Figure 1: Tangent as a linear approximation to a curve The tangent line approximates f (x). It gives a good approximation near the tangent point x0 . As you move away from x0 , however, the approximation grows less accurate. f (x) f (x0 ) + f (x0 )(x x0 )

Example 1. f (x) = ln x,

x0 = 1 (basepoint) f (1) = 1 =1 x x=1

f (1) ln x Change the basepoint:

ln 1 = 0;

f (1) + f (1)(x 1) = 0 + 1 (x 1) = x 1 x=1+u = u=x1 u

ln(1 + u) Basepoint u0 = x0 1 = 0. 1

Lecture 9

18.01 Fall 2006

Basic list of linear approximations In this list, we always use base point x0 = 0 and assume that |x| << 1. 1. sin x x 2. cos x 1
x

(if x 0) (if x 0)

(see part a of Fig. 2) (see part b of Fig. 2)

3. e 1 + x (if x 0) 4. ln(1 + x) x (if x 0) 5. (1 + x)r 1 + rx (if x 0) Proofs Proof of 1: Take f (x) = sin x, then f (x) = cos x and f (0) = 0 f (0) = 1, f (x) f (0) + f (0)(x 0) = 0 + 1.x So using basepoint x0 = 0, f (x) = x. (The proofs of 2, 3 are similar. We already proved 4 above.) Proof of 5: f (0) = 1 (1 + x)r ; d (1 + x)r |x=0 = r(1 + x)r1 |x=0 = r f (0) = dx f (x) = f (0) + f (0)x = 1 + rx f (x) =

y=x sin(x)

y=1

cos(x)

(a)
f (x0 )(x x0 ) (x0 = 0)

(b)

Figure 2: Linear approximation to (a) sin x (on left) and (b) cos x (on right). To nd them, apply f (x) f (x0 ) + e2x Example 2. Find the linear approximation of f (x) = near x = 0. 1+x We could calculate f (x) and nd f (0). But instead, we will do this by combining basic approximations algebraically. e2x 1 + (2x) (eu 1 + u, where u = 2x) 2

Lecture 9

18.01 Fall 2006

1 1 + x = (1 + x)1/2 1 + x 2 Put these two approximations together to get e2x 1 2x 1 (1 2x)(1 + x)1 2 x 1+ 1 1+x 2
1 1 Moreover (1 + 1 1 2 x (using (1 + u)1 1 u with u = x/2). Thus 2 x) 1

e2x 1 1 1 (1 2x)(1 x) = 1 2x x + 2( )x2 2 2 2 1+x Now, we discard that last x2 term, because weve already thrown out a number of other x2 (and higher order) terms in making these approximations. Remember, were assuming that | x |<< 1. This means that x2 is very small, x3 is even smaller, etc. We can ignore these higher-order terms, because they are very, very small. This yields 1 5 e2x 1 2x x = 1 x 2 2 1+x 5 5 Because f (x) 1 x, we can deduce f (0) = 1 and f (0) = directly from our linear approxi2 2 mation, which is quicker in this case than calculating f (x). Example 3. f (x) = (1 + 2x)10 . On the rst exam, you were asked to calculate lim the tools of Unit 1 is as follows. lim (1 + 2x)10 1 . The quickest way to do this with x0 x

(1 + 2x)10 1 f (x) f (0) = lim = f (0) = 20 x 0 x 0 x x (since f (x) = 10(1 + 2x)9 2 = 20 at x = 0) Now we can do the same problem a dierent way, namely, using linear approximation. (1 + 2x)10 1 + 10(2x) (Use (1 + u)r 1 + ru where u = 2x and r = 10.) Hence, (1 + 2x)10 1 1 + 20x 1 = 20 x x Example 4: Planet Quirk Lets say I am on Planet Quirk, and that a satellite is whizzing overhead with a velocity v . We want to nd the time dilation (a concept from special relativity) that the clock onboard the satellite experiences relative to my wristwatch. We borrow the following equation from special relativity: T T = 2 1 v c2
1A

shortcut to the two-step process

1 1 1+ 1+x

x 2

1 x is to write 2

1 1 = (1 + x)1/2 1 x 2 1+x

Lecture 9

18.01 Fall 2006

satellite (with velocity v)

me
Figure 3: Illustration of Example 4: a satellite with velocity v speeding past me on planet Quirk. Here, T is the time I measure on my wristwatch, and T is the time measured onboard the satellite. 1/2 v2 1 v2 v2 1 4 T = T 1 2 1+ (1 + u ) 1 + ru, where u = , r = 2 c2 c c2 2 v2 If v = 4 km/s, and the speed of light (c) is 3 105 km/s, 2 1010 . Theres hardly any dierence c between the times measured on the ground and in the satellite. Nevertheless, engineers used this very approximation (along with several other such approximations) to calibrate the radio transmitters on GPS satellites. (The satellites transmit at a slightly oset frequency.)

Quadratic Approximations
These are more complicated. They are only used when higher accuracy is needed. f (x) f (x0 ) + f (x0 )(x x0 ) + f (x0 ) (x x0 )2 2 (x x0 )

Geometric picture: A quadratic approximation gives a best-t parabola to a function. For example, lets consider f (x) = cos(x) (see Figure 4). If x0 = 0, then f (0) = cos(0) = 1, and f (x) f (x) cos(x) = = sin(x) cos(x) = f (0) = sin(0) = 0 = f (0) = cos(0) = 1 1 1 1 + 0 x x2 = 1 x2 2 2

1 You are probably wondering where that in front of the x2 term comes from. The reason its 2 there is so that this approximation is exact for quadratic functions. For instance, consider f (x) = a + bx + cx2 ; Set the base point x0 = 0. Then, = a = f (0) f (0) = a + b 0 + c 02 f (0) = b + 2c 0 = b = b = f (0) f (0) f (0) = 2c = c= 2 4 f (x) = b + 2cx; f (x) = 2c.

Lecture 9

18.01 Fall 2006

x cos(x) 1- x2/2
Figure 4: Quadratic approximation to cos(x). 0.0.1 : f (x) f (0) + f (0)x + 1. sin x x 2. cos x 1 (if x 0) x2 2 (if x 0) (if x 0) (if x 0) r(r 1) 2 x 2 (if x 0) f (0) 2 x 2 (x 0) Basic Quadratic Approximations

1 3. ex 1 + x + x2 2 1 4. ln(1 + x) x x2 2 5. (1 + x)r 1 + rx +

Proofs: The proof of these is to evaluate f (0), f (0), f (0) in each case. We carry out Case 4 f (x) f (x) f (x) = = = ln(1 + x) f (0) = ln 1 = 0 1 [ln(1 + x)] = = f (0) = 1 1+x 1 1 = = f (0) = 1 1+x (1 + x)2 =

Let us apply a quadratic approximation to our Planet Quirk example and see where it gives. 1/2 2 2 1 1 ( )( 1) v2 1 v2 v v 2 1 2 2 1 2 1+ + Case 5 with x = ,r = c 2 c2 2 c2 c2 2

Lecture 9

18.01 Fall 2006

2 2 v2 v 10 10 , that last term will be of the order 1020 . Not even the best atomic 2 c c2 clocks can measure time with this level of precision. Since the quadratic term is so small, we might as well ignore it and stick to the linear approximation in this case. Since e2x Example 5. f (x) = 1+x Let us nd the quadratic approximation of this expression. We can rewrite it as f (x) = e2x (1 + x)1/2 . Using the approximation of each factor gives 1 ( 2 )( 1 1 1 2 2 1) f (x) 1 2x + (2x) 1 x+ x2 2 2 2 1 1 3 5 27 f (x) 1 2x x + (2)( )x2 + 2x2 + x2 = 1 x + x2 8 8 2 2 2 (Note: we drop the x3 and higher order terms. This is a quadratic approximation, so we dont care about anything higher than x2 .)

Lecture 9

18.01 Fall 2006

Lecture 10: Curve Sketching


Goal: To draw the graph of f using the behavior of f and f . We want the graph to be qualitatively correct, but not necessarily to scale. Typical Picture: Here, y0 is the minimum value, and x0 is the point where that minimum occurs.

y0

x0= critical point


Figure 1: The critical point of a function Notice that for x < x0 , f (x) < 0. In other words, f is decreasing to the left of the critical point. For x > x0 , f (x) > 0: f is increasing to the right of the critical point.

Another typical picture: Here, y0 is the critical (maximum) value, and x0 is the critical point. f is decreasing on the right side of the critical point, and increasing to the left of x0 .

y0

f(x) < 0 x > x0 x0= critical point


Figure 2: A concave-down graph

Lecture 9

18.01 Fall 2006

Rubric for curve-sketching


1. (Precalc skill) Plot the discontinuities of f especially the innite ones! 2. Find the critical points. These are the points at which f (x) = 0 (usually where the slope changes from positive to negative, or vice versa.) 3. (a) Plot the critical points (and critical values), but only if its relatively easy to do so. (b) Decide the sign of f (x) in between the critical points (if its not already obvious). 4. (Precalc skill) Find and plot the zeros of f . These are the values of x for which f (x) = 0. Only do this if its relatively easy. 5. (Precalc skill) Determine the behavior at the endpoints (or at ). Example 1. y = 3x x3 1. No discontinuities. 2. y = 3 3x2 = 3(1 x2 ) so, y = 0 at x = 1. 3. (a) At x = 1, y = 3 1 = 2. (b) At x = 1, y = 3 + 1 = 2. Mark these two points on the graph. 4. Find the zeros: y = 3x x3 = x(3 x2 ) = 0 so the zeros lie at x = 0, 3. 5. Behavior of the function as x . As x , the x3 term of y dominates, so y . Likewise, as x , y . Putting all of this information together gives us the graph as illustrated in Fig. 3)

(1,2)

-2

(-3,0 )

-1

1
(3,0)

(-1,-2)

Figure 3: Sketch of the function y = 3x x3 . Note the labeled zeros and critical points Let us do step 3b (the sign of f ) to double-check for consistency. y = 3 3x2 = 3(1 x2 ) y > 0 when |x| < 1; y < 0 when |x| > 1. Sure enough, y is increasing between x = 1 and x = 1, and is decreasing everywhere else. 2

Lecture 10

18.01 Fall 2006

1 Example 2. y = . x This example illustrates why its important to nd a functions discontinuities before looking at the properties of its derivative. We calculate y = 1 <0 x2

Warning: The derivative is never positive, so you might think that y is always decreasing, and its graph looks something like that in Fig. 4.

Figure 4: A monotonically decreasing function 1 But as you probably know, the graph of looks nothing like this! It actually looks like Fig. 5. In x 1 fact, y = is decreasing except at x = 0, where it jumps from to +. This is why we must x watch out for discontinuities.

Figure 5: Graph of y = .

1 x

Lecture 10

18.01 Fall 2006

Example 3. y = x3 3x2 + 3x.

y = 3x2 6x + 3 = 3(x2 2x + 1) = 3(x 1)2 There is a critical point at x = 1. y > 0 on both sides of x = 1, so y is increasing everywhere. In this case, the sign of y doesnt change at the critical point, but the graph does level out (see Fig. 6.

(1,1) horizontal slope 1

Figure 6: Graph of y = y = x3 3x2 + 3x ln x (Note: this function is only dened for x > 0) x

Example 4. y =

What happens as x decreases towards zero? Let x = 2n . Then, y= ln 2n = (n ln 2)2n as n 2n

In other words, y decreases to as x approaches zero. Next, we want to nd the critical points. x( 1 ) 1(ln x) ln x 1 ln x y = = x = 2 x x x2 y = 0 = 1 ln x = 0 = ln x = 1 = x = e In other words, the critical point is x = e (from previous page). The critical value is y (x) |x=e = ln e 1 = e e

Lecture 10

18.01 Fall 2006

Next, nd the zeros of this function: y = 0 ln x = 0 So y = 0 when x = 1. What happens as x ? This time, consider x = 2+n . y= ln 2n n ln 2 n(0.7) = 2n 2n 2n

So, y 0 as n . Putting all of this together gets us the graph in Fig. 7.

1/e 1

(e,1/e) e

Figure 7: Graph of y =

ln x x

Finally, lets double-check this picture against the information we get from step 3b: y = 1 ln x >0 x2 for 0 < x < e

Sure enough, the function is increasing between 0 and the critical point.

Lecture 10

18.01 Fall 2006

2nd Derivative Information


When f > 0, f is increasing. When f < 0, f is decreasing. (See Fig. 8 and Fig. 9)

slope < 0 slope = 0

slope > 0

Figure 8: f is convex (concave-up). The slope increases from negative to positive as x increases.

Figure 9: f is concave-down. The slope decreases from positive to negative as x increases. Therefore, the sign of the second derivative tells us about concavity/convexity of the graph. Thus the second derivative is good for two purposes.

1. Deciding whether a critical point is a maximum or a minimum. This is known as the second derivative test. f (x0 ) f (x0 ) Critical point is a: 0 negative maximum 0 positive minimum 2. Concave/convex decoration.

Lecture 10

18.01 Fall 2006

The points where f = 0 are called inection points. Usually, at these points the graph changes from concave up to down, or vice versa. Refer to Fig. 10 to see how this looks on Example 1.

Inflection point (where f = 0)

Figure 10: Inection point: y = 3x x3 , y = 6x = 0, at x = 0.

Lecture 11

18.01 Fall 2006

Lecture 11: Max/Min Problems


Example 1. y = ln x (same function as in last lecture) x

1/e x0=e

Figure 1: Graph of y =

ln x . x

What is the maximum value? Answer: y =

1 . e

Where (or at what point) is the maximum achieved? Answer: x = e. (See Fig. 1).) Beware: Some people will ask What is the maximum?. The answer is not e. You will get so used to nding the critical point x = e, the main calculus step, that you will forget to nd the maximum 1 1 value y = . Both the critical point x = e and critical value y = are important. Together, they e e 1 form the point of the graph (e, ) where it turns around. e Example 2. Find the max and the min of the function in Fig. 2 Answer: If youve already graphed the function, its obvious where the maximum and minimum values are. The point is to nd the maximum and minimum without sketching the whole graph. Idea: Look for the max and min among the critical points and endpoints.You can see from Fig. 2 that we only need to compare the heights or y -values corresponding to endpoints and critical points. (Watch out for discontinuities!)

Lecture 11

18.01 Fall 2006

max

min
Figure 2: Search for max and min among critical points and endpoints Example 3. Find the open-topped can with the least surface area enclosing a xed volume, V.

Figure 3: Open-topped can. 1. Draw the picture. 2. Figure out what variables to use. (In this case, r, h, V and surface area, S .) 3. Figure out what the constraints are in the problem, and express them using a formula. In this example, the constraint is V = r2 h = constant Were also looking for the surface area. So we need the formula for that, too: S = r2 + (2r)h Now, in symbols, the problem is to minimize S with V constant. 2

Lecture 11

18.01 Fall 2006

4. Use the constraint equation to express everything in terms of r (and the constant V ). V V 2 h= ; S = r + (2r) 2r r2 5. Find the critical points (solve dS/dr = 0), as well as the endpoints. S will achieve its max and min at one of these places. dS 2V V = 2r 2 = 0 = r3 V = 0 = r3 = = r = dr r 2V , r V 1/3

Were not done yet. Weve still got to evaluate S at the endpoints: r = 0 and r = . S = r2 + 0r<

2 As r 0, the second term, , goes to innity, so S . As r , the rst term r2 goes r to innity, so S . Since S = + at each end, the minimum is achieved at the critical point r = (V / )1/3 , not at either endpoint.

s to to

r
Figure 4: Graph of S Were still not done. We want to nd the minimum value of the surface area, S , and the values of h. 2/3 1/3 1/3 V V V V V V r= ; h = 2 = 2/3 = = r V

S = r2 + 2

V = r

2/3 + 2V

1/3

= 3 1/3 V 2/3

Finally, another, often better, way of answering that question is to nd the proportions of the h h (V / )1/3 can. In other words, what is ? Answer: = = 1. r r (V / )1/3 3

Lecture 11

18.01 Fall 2006

Example 4. Consider a wire of length 1, cut into two pieces. Bend each piece into a square. We want to gure out where to cut the wire in order to enclose as much area in the two squares as possible.

(1/4)x

(1/4)(1-x)
Figure 5: Illustration for Example 5.

x The rst square will have sides of length x 4 . Its area will be 16 . The second square will have 2 x 1x sides of length 1 . The total area is then 4 . Its area will be 4

A A

= =

x 2

2 1x 4 4 2x 2(1 x) x 1 x 1 + (1) = + = 0 = 2x 1 = 0 = x = 16 16 8 8 8 2 +

So, one extreme value of the area is 1 2 A=


2

1 2 +
2

1 32

Were not done yet, though. We still need to check the endpoints! At x = 0, A = 02 + At x = 1, 2 1 1 A= + 02 = 4 16 10 4 2 = 1 16

Lecture 11

18.01 Fall 2006

By checking the endpoints in Fig. 6, we see that the minimum area was achieved at x = 1 2. The maximum area is not achieved in 0 < x < 1, but it is achieved at x = 0 or 1. The maximum corresponds to using the whole length of wire for one square.

Area 1/16

1/32

x 1/2
Figure 6: Graph of the area function. Moral: Dont forget endpoints. If you only look at critical points you may nd the worst answer, rather than the best one.

Lecture 12

18.01 Fall 2006

Lecture 12: Related Rates


Example 1. Police are 30 feet from the side of the road. Their radar sees your car approaching at 80 feet per second when your car is 50 feet away from the radar gun. The speed limit is 65 miles per hour (which translates to 95 feet per second). Are you speeding? First, draw a diagram of the setup (as in Fig. 1):

Police

30

D=50

Road x

Car

Figure 1: Illustration of example 1: triangle with the police, the car, the road, D and x labelled. Next, give the variables names. The important thing to gure out is which variables are changing. dD = D = dt 80. D is negative because the car is moving in the x direction. Dont plug in the value for D yet! D is changing, and it depends on x. At D = 50, x = 40. (We know this because its a 3-4-5 right triangle.) In addition, The Pythagorean theorem says 302 + x2 = D2 Dierentiate this equation with respect to time (implicit dierentiation: d 2 2DD 30 + x2 = D2 = 2xx = 2DD = x = dt 2x Now, plug in the instantaneous numerical values: x = 50 feet (80) = 100 40 s

This exceeds the speed limit of 95 feet per second; you are, in fact, speeding.

Lecture 12

18.01 Fall 2006

There is another, longer, way of solving this problem. Start with D = 302 + x2 = (302 + x2 )1/2 d 1 dx D = (302 + x2 )1/2 (2x ) dt 2 dt Plug in the values: 80 = and solve to nd 1 dx (302 + 402 )1/2 (2)(40) 2 dt

dx feet = 100 dt s 2 2 (A third strategy is to dierentiate x = D 30 ). It is easiest to dierentiate the equation in its simplest algebraic form 302 + x2 = D2 , our rst approach. The general strategy for these types of problems is: 1. Draw a picture. Set up variables and equations. 2. Take derivatives. 3. Plug in the given values. Dont plug the values in until after taking the derivatives.

Example 2. Consider a conical tank. Its radius at the top is 4 feet, and its 10 feet high. Its being lled with water at the rate of 2 cubic feet per minute. How fast is the water level rising when it is 5 feet high?

Figure 2: Illustration of example 2: inverted cone water tank. From Fig. 2), the volume of the tank is given by V = 1 2 r h 3 2

Lecture 12

18.01 Fall 2006

The key here is to draw the two-dimensional cross-section. We use the letters r and h to represent the variable radius and height of the water at any level. We can nd the relationship between r and h from Fig. 3) using similar triangles.

10

Figure 3: Relating r and h. From Fig. 3), we see that r 4 = h 10 or, in other words, r= 2 h 5

Plug this expression for r back into V to get 2 1 2 4 V = h h= h3 3 5 3(25) dV 4 =V = h2 h dt 25 Now, plug in the numbers ( dV = 2, h = 5): dt 2= 4 25 (5)2 h

h =

1 2

Related rates also arise on Problem Set 3 (Fig. 4). Theres a part II margin of error problem L involving a satellite, where youre asked to nd . h 3

Lecture 12

18.01 Fall 2006

satellite

L
Figure 4: Illustration of the satellite problem.

L2 + c2 Hence, 2LL L L h h

= = =

h2 2hh h L

There is also a parabolic mirror problem based on similar ideas (Fig. 5).

Figure 5: Illustration of the parabolic mirror problem. a Here, you want to nd either or . This type of sensitivity of measurement problem a matters in every measurement problem, for instance predicting whether asteroids will hit Earth. 4

Lecture 13

18.01 Fall 2006

Lecture 13: Newtons Method and Other Applications

Newtons Method
Newtons method is a powerful tool for solving equations of the form f (x) = 0. Example 1. f (x) = x2 3. In other words, solve x2 3 = 0. We already know that the solution to this is x = 3. Newtons method, gives a good numerical approximation to the answer. The method uses tangent lines (see Fig. 1).

y = x2 -3

x0=1

x1

(1,-2)

Figure 1: Illustration of Newtons Method, Example 1. The goal is to nd where the graph crosses the x-axis. We start with a guess of x0 = 1. Plugging that back into the equation for y , we get y0 = 12 3 = 2, which isnt very close to 0. Our next guess is x1 , where the tangent line to the function at x0 crosses the x-axis. The equation for the tangent line is: y y0 = m(x x0 ) When the tangent line intercepts the x-axis, y = 0, so y0 y0 m x1 = = = m(x1 x0 ) x1 x0 x0 y0 m

Remember: m is the slope of the tangent line to y = f (x) at the point (x0 , y0 ).

Lecture 13

18.01 Fall 2006

In terms of f : y0 = m = f (x0 ) f (x0 )

Therefore, x1 = x0 f (x0 ) f (x0 )

x0

x2

x1

Figure 2: Illustration of Newtons Method, Example 1. In our example, f (x) = x2 3, f (x) = 2x. Thus, x1 x1 = = x0 (x2 1 3 0 3) = x0 x0 + 2 2x0 2x 1 3 x0 + 2 2x0

The main idea is to repeat (iterate) this process: x2 x3 and so on. The procedure approximates = = 1 x1 + 2 1 x2 + 2 3 2x1 3 2x2

3 extremely well.

Lecture 13, Version 3.0 3|

18.01 Fall 2006

x x0 x1 x2 x3 x4

y 1 2
7 4 7 8

accuracy: |y 3 101 2 102 +


6 7

104 3 109

18,817 10,864

Notice that the number of digits of accuracy doubles with each iteration.

Summary
Newtons Method is illustrated in Fig. 3 and can be summarized as follows: xk+1 = xk f (xk ) f (xk )

y=f(x) (xk, yk) xk+1 xk = kth iterate

Figure 3: Illustration of Newtons Method. Example 1 considered the particular case of f (x) xk+1 Now, we dene x = lim xk
k

= =

x2 3 f (xk ) 1 3 xk = ... = xk + f (xk ) 2 2xk (xk x as k )

To evaluate x in Example 1, take the limit as k in the equation xk+1 = 1 3 xk + 2 2xk 3

Lecture 13, Version 3.0

18.01 Fall 2006

This yields 1 3 1 3 1 3 x + = x x = = x = = x2 = 3 2 2 x 2x 2x 2 2 which is just what we hoped: x = 3. x = Warning 1. Newtons Method can nd an unexpected root. Example: if you take x0 = 1, then xk 3 instead of + 3. This convergence to an unexpected root is illustrated in Fig. 4

y = x2-3

x1

x0
tangent to curve at x = x0

Figure 4: Newtons method converging to an unexpected root. Warning 2. Newtons Method can fail completely. This failure is illustrated in Fig. 5. In this case, x2 = x0 , x3 = x1 , and so forth. It repeats in a cycle, and never converges to a single value.

x0

(x1, y1) x1

(x0, y0)

Figure 5: Newtons method converging to an unexpected root.

Lecture 13

18.01 Fall 2006

Ring on a String
Consider a ring on a string 1 held xed at two ends at (0, 0) and (a, b) (see Fig. 6). The ring is free to slide to any point. Find the position (x, y ) of the string.

a-x (0, 0)

(a, b)

x
[(a-x)2 +(b-y2)]

(x2 +y2)

(x, y)

Figure 6: Illustration of the Ring on a String problem. Physical Principle The ring settles at the lowest height (lowest potential energy), so the problem is to minimize y subject to the constraint that (x, y ) is on the string. Constraint The length L of the string is xed: x2 + y 2 + (x a)2 + (y b)2 = L The function y = y (x) is determined implicitly by the constraint equation above. We traced the constraint curve (possible positions of the ring) on the blackboard. This curve is an ellipse with foci at (0, 0) and (a, b), but knowing that the curve is an ellipse does not help us nd the lowest point. Experiments with the hanging ring show that the lowest point is somewhere in the middle. Since the ends of the constraint curve are higher than the middle, the lowest point is a critical point (a point where y (x) = 0). In class we also gave a physical demonstration of this by drawing the horizontal tangent at the lowest point. To nd the critical point, dierentiate the constraint equation implicitly with respect to x, x + yy x a + (y b)y + =0 (x a)2 + (y b)2 x2 + y 2 Since y = 0 a the critical point, the equation can be rewritten as x
1 c 1999

x2

y2

ax (x a)2 + (y b)2

c 2007 David Jerison and

Lecture 13

18.01 Fall 2006

From Fig. 6, we see that the last equation can be interpreted geometrically as saying that sin = sin where and are the angles the left and right portions of the string make with the vertical.

Physical and geometric conclusions


The angles and are equal. Using vectors to compute the force exerted by gravity on the two halves of the string, one nds that there is equal tension in the two halves of the string - a physical equilibrium. (From another point of view, the equal angle property expresses a geometric property of ellipses: Suppose that the ellipse is a mirror. A ray of light from the focus (0, 0) reects o the mirror according to the rule angle of incidence equals angle of reection, and therefore the ray goes directly to the other focus at (a, b).)

Formulae for x and y


We did not yet nd the location of (x, y ). We will now show that a b 1 1 b L2 a 2 x= , y= 2 2 L2 a2 Because = , x = x2 + y 2 sin ; a x = (x a)2 + (y b)2 sin Adding these two equations, a a= x2 + y 2 + (x a)2 + (y b)2 sin = L sin = sin = L The equations for the vertical legs of the right triangles are (note that y < 0): y = x2 + y 2 cos ; b y = (x a)2 + (y b)2 cos Adding these two equations, and using = , 1 b 2y = x2 + y 2 + (x a)2 + (y b)2 cos = L cos = y = (b L cos ) 2 a 2 2 2 Use the relation sin = to write L cos = L 1 sin = L a . Then the formula for y is L 1 y= b L2 a2 2 Finally, to nd the formula for x, use the similar right triangles x ax tan = = = x(b y ) = (y )(a x) = (b 2y )x = ay y by Therefore, ay a b = 1 b 2y 2 L2 a2 Thus we have formulae for x and y in terms of a, b and L. x= I omitted the derivation of the formulae for x and y in lecture because it is long and because we got all of our physical intuition and understanding out of the problem from the balance condition that was the immediate consequence of the critical point computation. Final Remark. In 18.02, you will learn to treat constrained max/min problems in any number of variables using a method called Lagrange multipliers. 6

Lecture 14

18.01 Fall 2006

Lecture 14: Mean Value Theorem and Inequalities

Mean-Value Theorem
The Mean-Value Theorem (MVT) is the underpinning of calculus. It says: If f is dierentiable on a < x < b, and continuous on a x b, then f (b) f (a) = f (c) (for some c, a < c < b) ba Here, f (b) f (a) is the slope of a secant line, while f (c) is the slope of a tangent line. ba

secant line slope f(c)

b a c

Figure 1: Illustration of the Mean Value Theorem. Geometric Proof: Take (dotted) lines parallel to the secant line, as in Fig. 1 and shift them up from below the graph until one of them rst touches the graph. Alternatively, one may have to start with a dotted line above the graph and move it down until it touches. If the function isnt dierentiable, this approach goes wrong. For instance, it breaks down for the function f (x) = |x|. The dotted line always touches the graph rst at x = 0, no matter what its slope is, and f (0) is undened (see Fig. 2).

Lecture 14

18.01 Fall 2006

Figure 2: Graph of y = |x|, with secant line. (MVT goes wrong.)

Interpretation of the Mean Value Theorem


You travel from Boston to Chicago (which well assume is a 1,000 mile trip) in exactly 3 hours. At 1000 some time in between the two cities, you must have been going at exactly mph. 3 f (t) = position, measured as the distance from Boston. f (3) = 1000, f (0) = 0, a = 0, and b = 3.

1000 f (b) f (a) = = f (c) 3 3 where f (c) is your speed at some time, c.

Versions of the Mean Value Theorem


There is a second way of writing the MVT: f (b) f (a) = f (b) = f (c)(b a) f (a) + f (c)(b a)

(for some c, a < c < b)

There is also a third way of writing the MVT: change the name of b to x. f (x) = f (a) + f (c)(x a) for some c, a < c < x

The theorem does not say what c is. It depends on f , a, and x. This version of the MVT should be compared with linear approximation (see Fig. 3). f (x) f (a) + f (a)(x a) x near a 2

Lecture 14

18.01 Fall 2006

The tangent line in the linear approximation has a denite slope f (a). by contrast formula is an exact formula. It conceals its lack of specicity in the slope f (c), which could be the slope of f at any point between a and x.

(x,f(x))

error

(a,f(a))

y=f(a) + f(a)(x-a)

Figure 3: MVT vs. Linear Approximation.

Uses of the Mean Value Theorem.


Key conclusions: (The conclusions from the MVT are theoretical) 1. If f (x) > 0, then f is increasing. 2. If f (x) < 0, then f is decreasing. 3. If f (x) = 0 all x, then f is constant. Denition of increasing/decreasing: Increasing means a < b f (a) < f (b). Decreasing means a < b = f (a) < f (b). Proofs: Proof of 1: a f (b) < = b f (a) + f (c)(b a)

Because f (c) and (b a) are both positive, f (b) = f (a) + f (c)(b a) > f (a) (The proof of 2 is omitted because it is similar to the proof of 1) Proof of 3: f (b) = f (a) + f (c)(b a) = f (a) + 0(b a) = f (a) Conclusions 1,2, and 3 seem obvious, but let me persuade you that they are not. Think back to the denition of the derivative. It involves innitesimals. Its not a sure thing that these innitesimals have anything to do with the non-innitesimal behavior of the function. 3

Lecture 14

18.01 Fall 2006

Inequalities
The fundamental property f > 0 = f is increasing can be used to deduce many other inequalities. Example. ex 1. ex > 0 2. ex > 1 for x > 0 3. ex > 1 + x

Proofs. We will take property 1 (ex > 0) for granted. Proofs of the other two properties follow:
Proof of 2: Dene f1 (x) = ex 1. Then, f1 (0) = e0 1 = 0, and f1 (x) = ex > 0. (This last assertion is from step 1). Hence, f1 (x) is increasing, so f (x) > f (0) for x > 0. That is:

ex > 1 for x > 0 . Proof of 3: Let f2 (x) = ex (1 + x).


(x) = ex 1 = f1 (x) > 0 f2

(if x > 0).

Hence, f2 (x) > 0 for x > 0. In other words, ex > 1 + x Similarly, ex > 1 + x + ex > 1 + x + x2 x2 (proved using f3 (x) = ex (1 + x + )). One can keep on going: 2 2

x2 x3 + for x > 0. Eventually, it turns out that 2 3! ex = 1 + x + x2 x3 + + 2 3!

(an innite sum)

We will be discussing this when we get to Taylor series near the end of the course.

Lecture 15

18.01 Fall 2006

Lecture 15: Dierentials and Antiderivatives


Dierentials
New notation: dy = f (x)dx (y = f (x)) Both dy and f (x)dx are called dierentials. You can think of dy = f (x) dx as a quotient of dierentials. One way this is used is for linear approximations. y dy x dx Example 1. Approximate 651/3 Method 1 (review of linear approximation method) x1/3 1 2/3 f (x) = x 3 f (x) f (a) + f (a)(x a) 1 x1/3 a1/3 + a2/3 (x a) 3 f (x) = A good base point is a = 64, because 641/3 = 4. Let x = 65. 65 Similarly, (64.1)1/3 4 + 1 480
1/3

= 64

1/3

1 1 + 642/3 (65 64) = 4 + 3 3

1 16

(1) = 4 +

1 4.02 48

Method 2 (review) 651/3 = (64 + 1)1/3 = [64(1 + 1/3 1 1/3 1 1 )] = 641/3 [1 + ]1/3 = 4 1 + 64 64 64 1 1 and x = . 3 64

Next, use the approximation (1 + x)r 1 + rx with r =

1 1 1 651/3 4(1 + ( )) = 4 + 3 64 48 This is the same result that we got from Method 1. 1

Lecture 15

18.01 Fall 2006

Method 3 (with dierential notation) y dy = x1/3 |x=64 = 4 1 2/3 1 1 1 = x dx|x=64 = dx = dx 3 3 16 48 1 when dx = 1. 48 1 (65)1/3 = 4 + 48

We want dx = 1, since (x + dx) = 65. dy =

What underlies all three of these methods is y dy dx = = x1/3 1 2/3 x |x=64 3

Anti-derivatives
F (x) = f (x)dx means that F is the antiderivative of f . Other ways of saying this are: F (x) = f (x) or, dF = f (x)dx

Examples:
1. 2. 3. 4. 5. 6. sin xdx = cos x + c where c is any constant. xn dx = xn+1 + c for n = 1. n+1 (This takes care of the exceptional case n = 1 in 2.)

dx = ln |x| + c x

sec2 xdx = tan x + c dx 1 = sin1 x + c (where sin1 x denotes inverse sin or arcsin, and not ) sin x 1 x2

dx = tan1 (x) + c 1 + x2

Proof of Property 2: The absolute value |x| gives the correct answer for both positive and negative x. We will double check this now for the case x < 0: ln |x| = d ln(x) = dx d ln(x) = dx ln(x) du d ln(u) where u = x. dx du 1 1 1 (1) = (1) = x x u 2

Lecture 15

18.01 Fall 2006

Uniqueness of the antiderivative up to an additive constant.


If F (x) = f (x), and G (x) = f (x), then G(x) = F (x) + c for some constant factor c. Proof: (G F ) = f f = 0 Recall that we proved as a corollary of the Mean Value Theorem that if a function has a derivative zero then it is constant. Hence G(x) F (x) = c (for some constant c). That is, G(x) = F (x) + c.

Method of substitution.
Example 1. Substitution: u = x4 + 2, Hence, 1 x (x + 2) dx = 4
3 4 5

x3 (x4 + 2)5 dx

du = 4x3 dx,

(x4 + 2)5 = u5 ,

x3 dx =

1 du 4

u5 du =

u6 u6 1 4 = +c= (x + 2)6 + c 4(6) 24 24

Example 2.

x dx 1 + x2

Another way to nd an anti-derivative is advanced guessing. First write x dx = x(1 + x2 )1/2 dx 1 + x2 Guess: (1 + x2 )1/2 . Check this. d 1 (1 + x2 )1/2 = (1 + x2 )1/2 (2x) = x(1 + x2 )1/2 dx 2 Therefore, x(1 + x2 )1/2 dx = (1 + x2 )1/2 + c

Example 3.

e6x dx

Guess: e6x . Check this:

d 6x e = 6e6x dx e6x dx = 1 6x e +c 6

Therefore,

Lecture 15

18.01 Fall 2006

Example 4.
2

xex dx

Guess: ex Again, take the derivative to check:


2 d x2 e = (2x)(ex ) dx

Therefore,
2 2 1 xex dx = ex + c 2

Example 5. sin x cos xdx =

1 sin2 x + c 2

Another, equally acceptable answer is 1 sin x cos xdx = cos2 x + c 2 This seems like a contradiction, so lets check our answers: d sin2 x = (2 sin x)(cos x) dx and d cos2 x = (2 cos x)( sin x) dx So both of these are correct. Heres how we resolve this apparent paradox: the dierence between the two answers is a constant. 1 1 1 1 sin2 x ( cos2 x) = (sin2 x + cos2 x) = 2 2 2 2 So, 1 1 1 1 1 sin2 x = (sin2 x 1) = ( cos2 x) = cos2 x 2 2 2 2 2 The two answers are, in fact, equivalent. The constant c is shifted by 1 2 from one answer to the other. dx Example 6. (We will assume x > 0.) x ln x 1 Let u = ln x. This means du = dx. Substitute these into the integral to get x dx 1 = du = ln u + c = ln(ln(x)) + c x ln x u

Lecture 16

18.01Fall 2006

Lecture 16: Dierential Equations and Separation of Variables

Ordinary Dierential Equations (ODEs)


Example 1. dy = f (x) dx Solution: y = f (x)dx. We consider these types of equations as solved.

d dy Example 2. +x y =0 or + xy = 0 dx dx d ( + x is known in quantum mechanics as the annihilation operator.) dx Besides integration, we have only one method of solving this so far, namely, substitution. Solving dy for gives: dx dy = xy dx The key step is to separate variables. dy = xdx y Note that all y -dependence is on the left and all x-dependence is on the right. Next, take the antiderivative of both sides: dy = xdx y x2 ln |y | = + c (only need one constant c) 2 c x2 /2 |y | = e e (exponentiate) y = aex
2

/2

(a = ec )

Despite the fact that ec = 0, a = 0 is possible along with all a = 0, depending on the initial 2 2 conditions. For instance, if y (0) = 1, then y = ex /2 . If y (0) = a, then y = aex /2 (See Fig. 1).

Lecture 16

18.01Fall 2006

0.8

0.6

0.4

0.2

0 6

Figure 1: Graph of y = e In general: dy dx dy g (y ) h(y )dy = = = f (x)g (y ) f (x)dx

x2 2

which we can write as 1 . g (y )

f (x)dx where h(y ) =

Now, we get an implicit formula for y : H (y ) = F (x) + c where H = h, F = f , and y = H 1 (F (x) + c) (H 1 is the inverse function.) In the previous example: f (x) g (y ) = = x; y; x 2 ; 2 1 1 h(y ) = = , g (y ) y F (x) = (H (y ) = h(y )dy ; F (x) = f (x)dx)

H (y ) = ln |y |

Lecture 16

18.01Fall 2006

y dy =2 . dx x Find a graph such that the slope of the tangent line is twice the slope of the ray from (0, 0) to (x, y ) seen in Fig. 2. Example 3 (Geometric Example).

(x,y)

Figure 2: The slope of the tangent line (red) is twice the slope of the ray from the origin to the point (x, y).

dy 2dx = (separate variables) y x ln |y | = 2 ln |x| + c (antiderivative) |y | = ec x2 (exponentiate; remember, e2 ln |x| = x2 ) Thus, y = ax2 Again, a < 0, a > 0 and a = 0 are all acceptable. Possible solutions include, for example, y y y y y y = = = = = x2 (a = 1) 2x2 (a = 2)

x2 (a = 1) = 0x2 = 0 (a = 0) 2y 2 100x2 (a = 2) (a = 100)

Lecture 16

18.01Fall 2006

Example 4. Find the curves that are perpendicular to the parabolas in Example 3. We know that their slopes, dy 1 x = = dx slope of parabola 2y Separate variables: x ydy = dx 2 Take the antiderivative: y2 x2 x2 y2 = +c = + =c 2 4 4 2 which is an equation for a family of ellipses. For these ellipses, the ratio of the x-semi-major axis to the y-semi-minor axis is 2 (see Fig. 3).

Figure 3: The ellipses are perpendicular to the parabolas. Separation of variables leads to implicit formulas for y , but in this case you can solve for y . x2 y = 2 c 4

Exam Review
Exam 2 will be harder than exam 1 be warned! Heres a list of topics that exam 2 will cover: 1. Linear and/or quadratic approximations 2. Sketches of y = f (x) 3. Maximum/minimum problems. 4. Related rates. 5. Antiderivatives. Separation of variables. 6. Mean value theorem. More detailed notes on all of these topics are provided in the Exam 2 review sheet. 4

18.01 UNIT 2 REVIEW; Fall 2007 The central theme of Unit 2 is that knowledge of f (and sometimes f ) tells us something about f itself. This is even true of our rst topic, approximation. For instance, knowing that f (x) = e x satises f (0) = 1 and f (0) = 1, we can say ex 1 + x provided x 0 The linear function 1 + x is much simpler than e x , so f (0) and f (0) give us a (very) simplied picture of our function, useful only near near 0. For more detail, use the quadratic approximation, ex 1 + x + x2 /2 provided x 0 (still only works well near 0) The second and third practice exams are actual tests from previous years. The exam this year is similar to the one from 2006 posted at our site. It has 6 questions covering the following topics. (No Newtons method, but there is a seventh, extra credit problem.) 1. Linear and/or quadratic approximations 2. Sketch a graph y = f (x) 3. Max/min 4. Related rates 5. Find antiderivatives and solve a dierential equation by separating variables 6. Mean value theorem. Remarks. 1. Recall that linear [and quadratic] approximation is f (x) f (a) + f (a)(x a) [+(f (a)/2)(x a)2 ] 2. You should expect to graph a function y = f (x), where f (x) is a rational function (ratio of polynomials). Warnings: a) When asked to label the critical point on the graph, nd and mark the point (a, b). In lecture we called x = a the critical point and y = b the critical value, and this is what is used in 18.02, and elsewhere. But for this exam (and this is just an inconsistency in language that you will have to tolerate) the words critical point refer to the point on the graph (a, b), not the number a and the point on the x-axis. The same applies to inection points. b) y = 1/(x 1) is decreasing on the intervals < x < 1 and 1 < x < , but it is not decreasing on the interval < x < . Draw the graph to see. You cannot just use the fact that y = 1/(x 1)2 < 0 because there is a point in the middle at which y is not dierentiable and not even continuous. So the mean value theorem does not apply. c) Similarly, y = 1/(x 1)2 is concave up on < x < 1 and 1 < x < , but it is not concave up on the interval < x < . Here y = 6/(x 1)4 > 0, but there is a singularity in the middle. Plot the graph yourself to see. 1

3. The mean value theorem says that if f is dierentiable, then for some c, a < c < x, f (x) = f (a) + f (c)(x a) It is used as follows. Suppose that m < f (c) < M on the interval a < c < x, then f (x) = f (a) + f (c)(x a) < f (a) + M (x a) Similarly, f (x) = f (a) + f (c)(x a) > f (a) + m(x a) Put another way, if f = f (x) f (a) and x = x a, and m < f (c) < M for a < c < x, then mx < f < M x More consequences of the mean value theorem. A function f is called increasing (also called strictly increasing) if x > a implies f (x) > f (a). The reasoning above with m = 0 shows that if f > 0, then f is increasing. Similarly if f < 0, then f is decreasing. We use these facts every time we sketch a graph of a function or nd a maximum or minimum. A similar discussion works when the inequality is not strict. If m f (c) M for a < c < x, then f (a) + m(x a) f (x) f (a) + M (x a) A function is called nondecreasing if x > a implies f (x) f (a). If f 0, then the inequality above shows that f is nondecreasing. Conversely, if the function is nondecreasing and dierentiable, then f 0. Similarly, dierentiable functions are nonincreasing if and only if they satisfy f 0. Key corollary to the mean value theorem: f = g implies f g is constant. In Unit 2, we have found that information about f gives information about f . In particular, knowing a starting value for a function and its rate of change determines the function. A seemingly obvious example is that if f = 0 for all x, then f is constant. If this were not true, then the mathematical notion of derivative would fail to coincide with our intuitive notion of what rate of change and cause and eect mean. But this fundamental fact needs a proof. Derivatives are instantaneous quantities, obtained as limits. It is the mean value theorem that allows us to pass in rigorous mathematical fashion from the innitesimal to the practical, human scale. Here is the proof. If f = 0, then one can take m = M = 0 in the inequalities above, and conclude that f (x) = f (a). In other words, f is constant. As an immediate consequence, if f = g , then f and g dier by a constant. (Apply the previous argument to the function f g , whose derivative is 0.) This basic fact will lead us shortly to what is known as the fundamental theorem of calculus.

MIT OpenCourseWare http://ocw.mit.edu

18.01 Single Variable Calculus


Fall 2006

For information about citing these materials or our Terms of Use, visit: http://ocw.mit.edu/terms.

Lecture 18

18.01 Fall 2006

Lecture 18: Denite Integrals


Integrals are used to calculate cumulative totals, averages, areas. Area under a curve: (See Figure 1.) 1. Divide region into rectangles 2. Add up area of rectangles 3. Take limit as rectangles become thin

(i)

(ii)

Figure 1: (i) Area under a curve; (ii) sum of areas under rectangles Example 1. f (x) = x2 , a = 0, b arbitrary

1. Divide into n intervals Length b/n = base of rectangle 2. Heights: 1st : x = 2nd : x = b , n 2b , n height = 2 b n 2 2b height = n

Sum of areas of rectangles: 2 2 2 2 b b b 2b b 3b b nb b3 + + + + = 3 (12 + 22 + 32 + + n2 ) n n n n n n n n n 1

Lecture 18

18.01 Fall 2006

a=0

b
Figure 2: Area under f (x) = x2 above [0, b].

We will now estimate the sum using some 3-dimensional geometry. Consider the staircase pyramid as pictured in Figure 3.

n=4 n

Figure 3: Staircase pyramid: left(top view) and right (side view) 1st level: n n bottom, represents volume n2 . 2nd level: (n 1) (n 1), represents volumne (n 1)2 ), etc. Hence, the total volume of the staircase pyramid is n2 + (n 1)2 + + 1. Next, the volume of the pyramid is greater than the volume of the inner prism: 12 + 22 + + n2 > 1 1 1 (base)(height) = n2 n = n3 3 3 3

and less than the volume of the outer prism: 12 + 22 + + n2 < 1 1 (n + 1)2 (n + 1) = (n + 1)3 3 3 2

Lecture 18

18.01 Fall 2006

In all,
1 3 n 1 12 + 22 + + n2 1 (n + 1)3 = 3 3 < < 3 n n3 3 n3

Therefore, b3 2 1 (1 + 22 + 32 + + n2 ) = b3 , n n3 3 lim and the area under x2 from 0 to b is b3 . 3

Example 2. f (x) = x; area under x above [0, b]. Reasoning similar to Example 1, but easier, gives a sum of areas: b2 1 (1 + 2 + 3 + + n) b2 (as n ) n2 2 This is the area of the triangle in Figure 4.

b
Figure 4: Area under f (x) = x above [0, b].

Pattern:
d db b3 = b2 3 d b2 =b db 2

The area A(b) under f (x) should satisfy A (b) = f (b).

Lecture 18

18.01 Fall 2006

General Picture

y=f(x)

ci
ba n

Figure 5: One rectangle from a Riemann Sum

Divide into n equal pieces of length = x =

Pick any ci in the interval; use f (ci ) as the height of the rectangle Sum of areas: f (c1 )x + f (c2 )x + + f (cn )x In summation notation:
n i=1

f (ci )x called a Riemann sum.

Denition: lim
n i=1

f (ci )x =
a

f (x)dx called a denite integral

This denite integral represents the area under the curve y = f (x) above [a, b]. Example 3. (Integrals applied to quantity besides area.) Student borrows from parents. P = principal in dollars, t = time in years, r = interest rate (e.g., 6 % is r = 0.06/year). After time t, you owe P (1 + rt) = P + P rt The integral can be used to represent the total amount borrowed as follows. Consider a function f (t), the borrowing function in dollars per year. For instance, if you borrow $ 1000 /month, then f (t) = 12, 000/year. Allow f to vary over time. Say t = 1/12 year = 1 month. ti = i/12 i = 1, , 12. 4

Lecture 18

18.01 Fall 2006

f (ti ) is the borrowing rate during the ith month so the amount borrowed is f (ti )t. The total is
12 i=1

f (ti )t.

In the limit as t 0, we have


0 1

f (t)dt which represents the total borrowed in one year in dollars per year. The integral can also be used to represent the total amount owed. The amount owed depends on the interest rate. You owe f (ti )(1 + r(1 ti ))t for the amount borrowed at time ti . The total owed for borrowing at the end of the year is 1 f (t)(1 + r(1 t))dt
0

Lecture 19

18.01 Fall 2006

Lecture 19: First Fundamental Theorem of Calculus

Fundamental Theorem of Calculus (FTC 1)


If f (x) is continuous and F (x) = f (x), then b f (x)dx = F (b) F (a)
a

b x=b Notation: F (x) = F (x) = F (b) F (a)


a x=a

x3 Example 1. F (x) = , F (x) = x2 ; 3

b 3 3 x3 =b a x dx = 3 a 3 3
2

Example 2. Area under one hump of sin x (See Figure 1.) sin x dx = cos x = cos ( cos 0) = (1) (1) = 2
0 0

Figure 1: Graph of f (x) = sin x for 0 x .

Example 3.
0

1 x6 = 1 0= 1 x dx = 6 0 6 6
5

Lecture 19

18.01 Fall 2006

Intuitive Interpretation of FTC:


x(t) is a position; v (t) = x (t) =
a b

dx is the speed or rate of change of x. dt v (t)dt = x(b) x(a) (FTC 1)

R.H.S. is how far x(t) went from time t = a to time t = b (dierence between two odometer readings). L.H.S. represents speedometer readings.
n i=1

v (ti )t

approximates the sum of distances traveled over times t

The approximation above is accurate if v (t) is close to v (ti ) on the ith interval. The interpretation of x(t) as an odometer reading is no longer valid if v changes sign. Imagine a round trip so that x(b) x(a) = 0. Then the positive and negative velocities v (t) cancel each other, whereas an odometer would measure the total distance not the net distance traveled. Example 4.
0 2

2 sin x dx = cos x = cos 2 ( cos 0) = 0.


0

The integral represents the sum of areas under the curve, above the x-axis minus the areas below the x-axis. (See Figure 2.)

+ -

Figure 2: Graph of f (x) = sin x for 0 x 2.

Lecture 19

18.01 Fall 2006

Integrals have an important additive property (See Figure 3.)


a b

f (x)dx +
b

f (x)dx =
a

f (x)dx

a
New Denition:
b a

Figure 3: Illustration of the additive property of integrals f (x)dx =


a b

f (x)dx

This denition is used so that the fundamental theorem is valid no matter if a < b or b < a. It also makes it so that the additive property works for a, b, c in any order, not just the one pictured in Figure 3.

Lecture 19

18.01 Fall 2006

Estimation:
If f (x) g (x), then
a b

f (x)dx
a

g (x)dx (only if a < b)

Example 5. Estimation of ex Since 1 ex for x 0,


0 1 1

1dx
0

ex dx

1 ex dx = ex = e1 e0 = e 1
0

Thus 1 e 1, or e 2. Example 6. We showed earlier that 1 + x ex . It follows that 1 1 (1 + x)dx ex dx = e 1


0 0

(1 + x)dx =

1 x2 =3 x+ 2 0 2

Hence,

3 5 e 1,or, e . 2 2

Change of Variable:
If f (x) = g (u(x)), then we write du = u (x)dx and g (u)du = g (u(x))u (x)dx = f (x)u (x)dx For denite integrals: x2
x1

(indenite integrals)

f (x)u (x)dx =

u2

g (u)du
u1

where u1 = u(x1 ), u2 = u(x2 )

Example 7.
1

3 4 x + 2 x2 dx Let u = x3 + 2. Then du = 3x2 dx = x2 dx = du ; 3

x1 = 1, x2 = 2 = u1 = 13 + 2 = 3, u2 = 23 + 2 = 10, and 10 2 10 5 5 3 4 du u5 = 10 3 x + 2 x2 dx = u4 = 3 15 3 15 1 3

Lecture 20

18.01 Fall 2006

Lecture 20: Second Fundamental Theorem


Recall: First Fundamental Theorem of Calculus (FTC 1)
If f is continuous and F = f , then b f (x)dx = F (b) F (a)
a

We can also write that as


a

f (x)dx =

x=b f (x)dx

x=a

Do all continuous functions have antiderivatives? Yes. However... What about a function like this? 2 ex dx =?? Yes, this antiderivative exists. No, its not a function weve met before: its a new function. The new function is dened as an integral: F (x) =
0 x

et dt

It will have the property that F (x) = e

x2

.
2 2

Other new functions include antiderivatives of ex , x1/2 ex ,

sin x , sin(x2 ), cos(x2 ), . . . x

Second Fundamental Theorem of Calculus (FTC 2)


If F (x) =
a x

f (t)dt and f is continuous, then F (x) = f (x)

Geometric Proof of FTC 2: Use the area interpretation: F (x) equals the area under the curve between a and x.

F F F x F Hence lim x0 x

= =

F (x + x) F (x) (base)(height) (x)f (x) f (x) f (x) (See Figure 1.)

But, by the denition of the derivative:


x0

lim

F = F (x) x 1

Lecture 20

18.01 Fall 2006

F F(x)

x+x

Figure 1: Geometric Proof of FTC 2. Therefore, F (x) = f (x) Another way to prove FTC 2 is as follows: x x+x F 1 = f (t)dt f (t)dt x x a a x+x 1 = f (t)dt (which is the average value of f on the interval x t x + x.) x x As the length x of the interval tends to 0, this average tends to f (x).

Proof of FTC 1 (using FTC 2)


Start with F = f (we assume that f is continuous). Next, dene G(x) =
a

f (t)dt. By FTC2,

G (x) = f (x). Therefore, (F G) = F G = f f = 0. Thus, F G = constant. (Recall we used the Mean Value Theorem to show this). Hence, F (x) = G(x) + c. Finally since G(a) = 0, b f (t)dt = G(b) = G(b) G(a) = [F (b) c] [F (a) c] = F (b) F (a)
a

which is FTC 1. Remark. In the preceding proof G was a denite integral and F could be any antiderivative. Let us illustrate with the example f (x) = sin x. Taking a = 0 in the proof of FTC 1, x x G(x) = cos t dt = sin t = sin x and G(0) = 0.
0 0

Lecture 20

18.01 Fall 2006

If, for example, F (x) = sin x + 21. Then F (x) = cos x and
a b

sin x dx = F (b) F (a) = (sin b + 21) (sin a + 21) = sin b sin a Every function of the form F (x) = G(x) + c works in FTC 1.

Examples of new functions


The error function, which is often used in statistics and probability, is dened as x 2 2 erf(x) = et dt 0 and lim erf(x) = 1 (See Figure 2)
x

Figure 2: Graph of the error function. Another new function of this type, called the logarithmic integral, is dened as x dt Li(x) = 2 ln t This function gives the approximate number of prime numbers less than x. A common encryption technique involves encoding sensitive information like your bank account number so that it can be sent over an insecure communication channel. The message can only be decoded using a secret prime number. To know how safe the secret is, a cryptographer needs to know roughly how many 200-digit primes there are. You can nd out by estimating the following integral:
10201

10200

dt ln t

We know that ln 10200 = 200 ln(10) 200(2.3) = 460 3 and ln 10201 = 201 ln(10) 462

Lecture 20

18.01 Fall 2006

We will approximate to one signicant gure: ln t 500 for 200 t 10201 . With all of that in mind, the number of 200-digit primes is roughly
10201 1

10200

dt ln t

10201

10200

9 10200 dt 1 201 = 10 10200 10198 500 500 500

There are LOTS of 200-digit primes. The odds of some hacker nding the 200-digit prime required to break into your bank account number are very very slim. Another set of new functions are the Fresnel functions, which arise in optics: x C (x) = cos(t2 )dt 0 x S (x) = sin(t2 )dt
0

Bessel functions often arise in problems with circular symmetry: 1 J0 (x) = cos(x sin )d 2 0 On the homework, you are asked to nd C (x). Thats easy! C (x) = cos(x2 ) We will use FTC 2 to discuss the function L(x) =
1 x

dt from rst principles next lecture. t

The middle equality in this approximation is a very basic and useful fact b c dx = c(b a)
a

Think of this as nding the area of a rectangle with base (b a) and height c. In the computation above, a = 1 10200 , b = 10201 , c = 500

Lecture 21

18.01 Fall 2006

Lecture 21: Applications to Logarithms and Geometry

Application of FTC 2 to Logarithms


The integral denition of functions like C (x), S (x) of Fresnel makes them nearly as easy to use as elementary functions. It is possible to draw their graphs and tabulate values. You are asked to carry out an example or two of this on your problem set. To get used to using denite integrals and FTC2, we will discuss in detail the simplest integral that gives rise to a relatively new function, namely the logarithm. Recall that xn dx = xn+1 +c n+1

except when n = 1. It follows that the antiderivative of 1/x is not a power, but something else. So let us dene a function L(x) by x dt L(x) = t 1 (This function turns out to be the logarithm. But recall that our approach to the logarithm was fairly involved. We rst analyzed ax , and then dened the number e, and nally dened the logarithm as the inverse function to ex . The direct approach using this integral formula will be easier.) All the basic properties of L(x) follow directly from its denition. Note that L(x) is dened for 0 < x < . (We will not extend the denition past x = 0 because 1/t is innite at t = 0.) Next, the fundamental theorem of calculus (FTC2) implies L (x) = 1 x

Also, because we have started the integration with lower limit 1, we see that 1 dt L(1) = =0 1 t Thus L is increasing and crosses the x-axis at x = 1: L(x) < 0 for 0 < x < 1 and L(x) > 0 for x > 1. Dierentiating a second time, L (x) = 1/x2 It follows that L is concave down. The key property of L(x) (showing that it is, indeed, a logarithm) is that it converts multiplication into addition: Claim 1. L(ab) = L(a) + L(b) Proof: By denition of L(ab) and L(a), L(ab) =
1 ab

dt = t

dt + t

ab

dt = L(a) + t

ab

dt t

Lecture 21

18.01 Fall 2006

To handle
a

ab

dt , make the substitution t = au. Then t dt = adu; a < t < ab = 1 < u < b
u=b

Therefore,
a ab

dt = t

u=1

adu = au

du = L(b) u

This conrms L(ab) = L(a) + L(b). Two more properties, the end values, complete the general picture of the graph. Claim 2. L(x) as x . Proof: It suces to show that L(2n ) as n , because the fact that L is increasing lls in all the values in between the powers of 2. L(2n ) = = L(2 2n1 ) = L(2) + L(2n1 ) L(2) + L(2) + L(2n2 ) = L(2) + L(2) + + L(2) (n times)

Consequently, L(2n ) = nL(2) as n . (In more familiar notation, ln 2n = n ln 2.) Claim 3. L(x) as x 0+ . 1 Proof: 0 = L(1) = L x = L(x) + L(1/x) = L(x) = L(1/x). As x 0+ , 1/x +, so x Claim 2 implies L(1/x) . Hence L(x) = L(1/x) , as x 0+

Thus L(x), dened on 0 < x < increases from to , crossing the x-axis at x = 1. It is concave down and its graph can be drawn as in Fig. 1. This provides an alternative to our previous approach to the exponential and log functions. Starting from L(x), we can dene the log function by ln x = L(x), dene e as the number such that L(e) = 1, dene ex as the inverse function of L(x), and dene ax = exL(a) .

.(1,0)
to

to +

Figure 1: Graph of y = ln(x).

Lecture 21

18.01 Fall 2006

Application of FTCs to Geometry (Volumes and Areas)


1. Areas between two curves

f(x) y
dx

g(x)

Figure 2: Finding the area between two curves. Refer to Figure 2. Find the crossing points a and b. The area, A, between the curves is A=
a b

(f (x) g (x)) dx

Example 1. Find the area in the region between x = y 2 and y = x 2.

(4, 2) x = y2 y=x2
(0, 0)

(1,1)
(0, -2)

Figure 3: The intersection of x = y2 and y = x 2.

Lecture 21

18.01 Fall 2006

First, graph these functions and nd the crossing points (see Figure 3). y+2 = x = y2 0 0

y2 y 2 = (y 2)(y + 1) =

Crossing points at y = 1, 2. Plug these back in to nd the associated x values, x = 1 and x = 4. Thus the curves meet at (1, 1) and (4, 2) (see Figure 3). There are two ways of nding the area between these two curves, a hard way and an easy way. Hard Way: Vertical Slices If we slice the region between the two curves vertically, we need to consider two dierent regions.

(4, 2) dx x = y2

y=x2 (0, 0)

(1,1) (0, -2)

Figure 4: The intersection of x = y2 and y = x 2. Where x > 1, the regions lower bound is the straight line. For x < 1, however, the regions lower bound is the lower half of the sideways parabola. We nd the area, A, between the two curves by integrating the dierence between the top curve and the bottom curve in each region: 1 4 A= x ( x) dx + x (x 2) dx = (ytop ybottom ) dx
0 1

Easy Way: Horizontal Slices Here, instead of subtracting the bottom curve from the top curve, we subtract the right curve from the left one.

A= (xleft xright ) dy =

y =2

(y + 2) y 2 dx =
y = 1

y2 y 3 + 2y + 2 3

4 8 1 1 9 2 = +4 ( 2+ ) = 2 3 2 3 2 1

Lecture 21

18.01 Fall 2006

x = y2

(4, 2)

dy

(0, 0)

y = x 2 ; (x = y +2)

(1,1) (0, -2)

Figure 5: The intersection of x = y2 and y = x 2.

2. Volumes of solids of revolution


Rotate f (x) about the x-axis, coming out of the page, to get:
rotate an x-y plane section by 2 radians f(x)

dx

Figure 6: A solid of revolution: the purple slice is rotated by /4 and /2. We want to gure out the volume of a slice of that solid. We can approximate each slice as a disk with width dx, radius y , and a cross-sectional area of y 2 . The volume of one slice is then: dV = y 2 dx (for a solid of revolution around the x-axis)

Integrate with respect to x to nd the total volume of the solid of revolution. 5

Lecture 21

18.01 Fall 2006

Example 2. Find the volume of a ball of radius a.

a a
dx

Figure 7: A ball of radius a The equation for the upper half of the circle is y = a2 x2 . If we spin the upper part of the curve about the x-axis, we get a ball of radius a. Notice that x ranges from a to +a. Putting all this together, we nd x=a x3 2 2 4 a V = y 2 dx = (a2 x2 )dx = a2 x = a3 a3 = a3 3 3 3 3 a x=a One can often exploit symmetry to further simplify these types of problems. In the problem above, for example, notice that the curve is symmetric about the y-axis. Therefore, a a x3 a V = (a2 x2 )dx = 2 (a2 x2 )dx = 2 a2 x 3 0 a 0 (The savings is that zero is an easier lower limit to work with than a.) We get the same answer: x3 4 a 2 V = 2 a x = 2 a3 a3 = a3 3 3 3 0

Lecture 22

18.01 Fall 2006

Lecture 22: Volumes by Disks and Shells

Disks and Shells


We will illustrate the 2 methods of nding volume through an example. Example 1. A witchs cauldron
y

Figure 1: y = x2 rotated around the y-axis.

Method 1: Disks
y

a thickness of dy

Figure 2: Volume by Disks for the Witchs Cauldron problem. The area of the disk in Figure 2 is x2 . The disk has thickness dy and volume dV = x2 dy . The volume V of the cauldron is a V = x2 dy (substitute y = x2 ) 0 a a2 y2 a V = y dy = = 2 0 2 0

Lecture 22 2 a gives 2

18.01 Fall 2006

If a = 1 meter, then V = V =

3 m = (100 cm)3 = 106 cm3 1600 liters (a huge cauldron) 2 2 2

Warning about units. If a = 100 cm, then (100)2 = 104 cm3 = 10 16 liters 2 2 2 But 100cm = 1m. Why is this answer dierent? The resolution of this paradox is hiding in the equation. y = x2 V = At the top, 100 = x2 = x = 10 cm. So the second cauldron looks like Figure 3. By contrast, when
20 cm

Figure 3: The skinny cauldron. a = 1 m, the top is ten times wider: 1 = x2 or x = 1 m. Our equation, y = x2 , is not scale-invariant. The shape described depends on the units used.

Method 2: Shells
This really should be called the cylinder method.
y

100 cm a x

Figure 4: x = radius of cylinder. Thickness of cylinder = dx. Height of cylinder = a y = a x2 .

Lecture 22

18.01 Fall 2006

The thin shell/cylinder has height a x2 , circumference 2x, and thickness dx. dV V (a x2 )(2x)dx a x=a 2 = (a x )(2x)dx = 2 (ax x3 )dx x=0 0 2 2 2 x x4 a a2 a a2 a = 2 a = 2 = = 2 2 4 2 4 4 2 0 =

(same as before)

Example 2. The boiling cauldron Now, lets ll this cauldron with water, and light a re under it to get the water to boil (at 100o C). Lets say its a cold day: the temperature of the air outside the cauldron is 0o C. How much energy does it take to boil this water, i.e. to raise the waters temperature from 0o C to 100o C? Assume the
y 70oC

100oC

Figure 5: The boiling cauldron (y = a = 1 meter.) temperature decreases linearly between the top and the bottom (y = 0) of the cauldron: T = 100 30y (degrees Celsius)

Use the method of disks, because the waters temperature is constant over each horizontal disk. The total heat required is 1 H = T (x2 )dy (units are (degree)(cubic meters))
0

=
0

(100 30y )(y )dy


1

1 (100y 30y 2 )dy = (50y 2 10y 3 ) = 40 (deg.)m3


0

How many calories is that? # of calories = 1 cal (40 ) cm3 deg 100 cm 1m 3 = (40 )(106 ) cal = 125 103 kcal

There are about 250 kcals in a candy bar, so there are about 1 # of calories = candy bar 103 500 candy bars 2 So, it takes about 500 candy bars worth of energy to boil the water. 3

Lecture 22

18.01 Fall 2006

velocity

Figure 6: Flow is faster in the center of the pipe. It slows sticks at the edges (i.e. the inner surface of the pipe.) Example 3. Pipe ow Poiseuille was the rst person to study uid ow in pipes (arteries, capillaries). He gured out the velocity prole for uid owing in pipes is: v v = = c(R2 r2 ) distance speed = time

v cR2 v=c(R2-r2)

Figure 7: The velocity of uid ow vs. distance from the center of a pipe of radius R. The ow through the annulus (a.k.a ring) is (area of ring)(ow rate) area of ring = 2rdr (See Fig. 8: circumference 2r, thickness dr)

v is analogous to the height of the shell.

Lecture 22

18.01 Fall 2006

dr

Figure 8: Cross-section of the pipe. total ow through pipe = = ow through pipe =


R

(R2 r2 )2rdr 2 2 R R r r4 R 2c (R2 r r3 )dr = 2c 2 4 0 0 4 cR 2 v (2rdr) = c


0 0

Notice that the ow is proportional to R4 . This means theres a big advantage to having thick pipes. Example 4. Dart board You aim for the center of the board, but your aims not always perfect. Your number of hits, N , at 2 radius r is proportional to er . 2 N = cer This looks like:

y = ce-r

Figure 9: This graph shows how likely you are to hit the dart board at some distance r from its center. The number of hits within a given ring with r1 < r < r2 is r2 2 c er (2rdr)
r1

We will examine this problem more in the next lecture.

Lecture 23

18.01 Fall 2006

Lecture 23: Work, Average Value, Probability

Application of Integration to Average Value


You already know how to take the average of a set of discrete numbers: a1 + a2 + a3 a 1 + a2 or 2 3 Now, we want to nd the average of a continuum.

y4.

y=f(x)

x4

Figure 1: Discrete approximation to y = f (x) on a x b. y1 + y2 + ... + yn n

Average where

a = x0 < x1 < xn = b y0 = f (x0 ), y1 = f (x1 ), . . . yn = f (xn ) and n(x) = b a and The limit of the Riemann Sums is lim (y1 + + yn ) ba = n
a b

x =

ba n

f (x) dx

Divide by b a to get the continuous average y1 + + yn 1 = n n ba lim


a b

f (x) dx

Lecture 23

18.01 Fall 2006

y=1-x2

area = /2

Figure 2: Average height of the semicircle. Example 1. Find the average of y = 1 x2 on the interval 1 x 1. (See Figure 2)

Average height =

1 2

1 x2 dx =

1 = 2 2 4

Example 2. The average of a constant is the same constant 1 ba


a b

53 dx = 53

Example 3. Find the average height y on a semicircle, with respect to arclength. (Use d not dx. See Figure 3)

equal weighting in

dierent weighting in x
Figure 3: Dierent weighted averages.

Lecture 23

18.01 Fall 2006

Average =

y 1 sin d = ( cos ) 0

= =

sin 1 2 ( cos ( cos 0)) =

Example 4. Find the average temperature of water in the witches cauldron from last lecture. (See Figure 4).

2m

1m

Figure 4: y = x2 , rotated about the y-axis. First, recall how to nd the volume of the solid of revolution by disks. 1 1 y 2 1 V = (x2 ) dy = y dy = = 2 0 2 0 0 Recall that T (y ) = 100 30y and (T (0) = 100o ; T (1) = 70o ). The average temperature per unit volume is computed by giving an importance or weighting w(y ) = y to the disk at height y . 1 T (y )w(y ) dy 0 1 w(y ) dy 0 The numerator is
0 1 1 0

T y dy =

1 (100 30y )ydy = (500y 2 10y 3 ) = 40


0

Thus the average temperature is: 40 = 80o C /2 Compare this with the average taken with respect to height y : 1 1 1 1 T dy = (100 30y )dy = (100y 15y 2 ) = 85o C 1 0 0 0 T is linear. Largest T = 100o C , smallest T = 70o C , and the average of the two is 70 + 100 = 85 2 3

Lecture 23

18.01 Fall 2006

The answer 85o is consistent with the ordinary average. The weighted average (integration with respect to y dy ) is lower (80o ) because there is more water at cooler temperatures in the upper parts of the cauldron.

Dart board, revisited


Last time, we said that the accuracy of your aim at a dart board follows a normal distribution: cer
2

Now, lets pretend someone say, your little brother foolishly decides to stand close to the dart board. What is the chance that hell get hit by a stray dart?

dart board

r 2r

3r
little brother

Figure 5: Shaded section is 2ri < r < 3r1 between 3 and 5 oclock. To make our calculations easier, lets approximate your brother as a sector (the shaded region in Fig. 5). Your brother doesnt quite stand in front of the dart board. Let us say he stands at a distance r from the center where 2r1 < r < 3r1 and r1 is the radius of the dart board. Note that your brother doesnt surround the dart board. Let us say he covers the region between 3 oclock 1 and 5 oclock, or of a ring. 6 Remember that probability = part whole

Lecture 23

18.01 Fall 2006

dr

width dr, circumference 2r weighting ce-r

Figure 6: Integrating over rings. 2 The ring has weight cer (2r)(dr) (see Figure 6). The probability of a dart hitting your brother is: 1 3r1 r 2 2r dr 6 2r1 ce 2 r ce 2r dr 0 1 53 = is our approximation to the portion of the circumference where the little 6 12 2 2 brother stands. (Note: er = e(r ) not (er )2 ) Recall that
a b r 2

re Denominator:

2 b 2 2 1 1 1 dr = er = eb + ea 2 2 2 a
0

2 d r2 e = 2rer dr

2 2 R 2 2 1 1 1 1 er rdr = er = eR + e0 = 2 2 2 2 0

(Note that e

R 2

0 as R .)

Figure 7: Normal Distribution.

Probability =

1 6

2 cer 2r dr 2r1 cer2 2r dr 0

3r1

er r dr 1 2r1 = = r 2 r dr 3 e 0
1 6

3r1

3r1

er r dr =

2r1

2 e r 3r1 6 2r1

Lecture 23

18.01 Fall 2006

e9r1 + e4r1 6 Lets assume that the person throwing the darts hits the dartboard 0 r r1 about half the time. (Based on personal experience with 7-year-olds, this is realistic.) r1 2 2 2 1 1 P (0 r r1 ) = = 2er rdr = er1 + 1 = er1 = 2 2 0 Probability = er1 = e
2 9r1 2

1 2

e4r1

9 1 = e = 0 2 2 4 1 4 1 = er1 = = 2 16
2 r1

So, the probability that a stray dart will strike your little brother is 1 1 1 16 6 100 In other words, theres about a 1% chance hell get hit with each dart thrown.

Lecture 23

18.01 Fall 2006

Volume by Slices: An Important Example


Compute Q =

ex dx

Figure 8: Q = Area under curve e(x ) . This is one of the most important integrals in all of calculus. It is especially important in probability and statistics. Its an improper integral, but dont let those s scare you. In this integral, theyre actually easier to work with than nite numbers would be. To nd Q, we will rst nd a volume of revolution, namely, 2 V = volume under er (r = x2 + y 2 ) We nd this volume by the method of shells, which leads to the same integral as in the last problem. 2 The shell or cylinder under er at radius r has circumference 2r, thickness dr; (see Figure 9). 2 Therefore dV = er 2rdr. In the range 0 r R,
0 R

2 2 R 2 er 2r dr = er = eR +
0

When R , eR 0, V =
0

er 2r dr =

(same as in the darts problem)

Lecture 23

18.01 Fall 2006

width dr

Figure 9: Area of annulus or ring, (2r)dr. Next, we will nd V by a second method, the method of slices. Slice the solid along a plane where y is xed. (See Figure 10). Call A(y ) the cross-sectional area. Since the thickness is dy (see Figure 11),

V =

A(y ) dy

z A(y)

x
Figure 10: Slice A(y).

Lecture 23

18.01 Fall 2006

y dy
above level of y in cross-section of area A(y)

top view

Figure 11: Top view of A(y) slice. To compute A(y ), note that it is an integral (with respect to dx) 2 2 r 2 x2 y 2 y 2 A(y ) = e dx = e dx = e ex dx = ey Q

Here, we have used r2 = x2 + y 2 and ex


2

y 2

= ex ey

and the fact that y is a constant in the A(y ) slice (see Figure 12). In other words, 2 2 2 cex dx = c ex dx with c = ey

y fixed ce-x
2

Figure 12: Side view of A(y) slice.

Lecture 23

18.01 Fall 2006

It follows that V =

A(y ) dy =

y 2

Q dy = Q

ey dy = Q2

Indeed, Q=

x2

dx =

ey dy

because the name of the variable does not matter. To conclude the calculation read the equation backwards: = V = Q2 = Q = We can rewrite Q = as 1

ex dx = 1

An equivalent rescaled version of this formula (replacing x with x/ 2 )is used: 2 2 1 ex /2 dx = 1 2


2 2 1 This formula is central to probability and statistics. The probability distribution ex /2 on 2 < x < is known as the normal distribution, and > 0 is its standard deviation.

10

Lecture 24

18.01 Fall 2006

Lecture 24: Numerical Integration


Numerical Integration
We use numerical integration to nd the denite integrals of expressions that look like: b (a big mess)
a

We also resort to numerical integration when an integral has no elementary antiderivative. For instance, there is no formula for x 3 2 2 cos(t )dt or ex dx
0 0

Numerical integration yields numbers rather than analytical expressions. Well talk about three techniques for numerical integration: Riemann sums, the trapezoidal rule, and Simpsons rule.

1. Riemann Sum

Figure 1: Riemann sum with left endpoints: (y0 + y1 + . . . + yn1 )x Here, xi xi1 = x (or, xi = xi1 + x) a = x0 < x1 < x2 < . . . < xn = b y0 = f (x0 ), y1 = f (x1 ), . . . yn = f (xn ) 1

Lecture 24

18.01 Fall 2006

2. Trapezoidal Rule
The trapezoidal rule divides up the area under the function into trapezoids, rather than rectangles. The area of a trapezoid is the height times the average of the parallel bases: base 1 + base 2 y3 + y4 Area = height = x (See Figure 2) 2 2

y4 y3

x
Figure 2: Area =
y3 + y 4 2 x

Figure 3: Trapezoidal rule = sum of areas of trapezoids. y0 + y1 y1 + y2 y2 + y3 yn1 + yn + + + ... + 2 2 2 2 y yn 0 x + y1 + y2 + ... + yn1 + 2 2 2

Total Trapezoidal Area = =

Lecture 24

18.01 Fall 2006

Note: The trapezoidal rule gives a more symmetric treatment of the two ends (a and b) than a Riemann sum does the average of left and right Riemann sums.

3. Simpsons Rule
This approach often yields much more accurate results than the trapezoidal rule does. Here, we match quadratics (i.e. parabolas), instead of straight or slanted lines, to the graph. This approach requires an even number of intervals.

y0

y2 y1
x x x

Figure 4: Area under a parabola.

Area under parabola = (base)(weighted average height) = (2x)

y0 + 4y1 + y2 6

Simpsons rule for n intervals (n must be even!) 1 Area = (2x) [(y0 + 4y1 + y2 ) + (y2 + 4y3 + y4 ) + (y4 + 4y5 + y6 ) + + (yn2 + 4yn1 + yn )] 6 Notice the following pattern in the coecients: 1 4 1 1 2

4 4

1 1 2

4 4

1 1

Lecture 24

18.01 Fall 2006

1st chunk

2nd chunk

Figure 5: Area given by Simpsons rule for four intervals Simpsons rule:
a b

f (x) dx

x (y0 + 4y1 + 2y2 + 4y3 + 2y4 + . . . + 4yn3 + 2yn2 + 4yn1 + yn ) 3

The pattern of coecients in parentheses is: 1 4 2 4 2 4 1 4 2 = = = sum 6 sum 12 sum 18

1 4

1 4

To double check plug in f (x) = 1 (n even!). n n x x (1 + 4 + 2 + 4 + 2 + + 2 + 4 + 1) = 1+1+4 +2 1 = nx (n even) 3 3 2 2

Lecture 24

18.01 Fall 2006

Example 1. Evaluate integration.


0

1 dx using two methods (trapezoidal and Simpsons) of numerical 1 + x2

x
1 (1+x2 )

1
above [0, 1].

Figure 6: Area under x 0


1 2

1/(1 + x2 ) 1
4 5 1 2

1 By the trapezoidal rule: x 1 1 y0 + y1 + y2 2 2 1 = 2

1 4 1 (1) + + 2 5 2

1 1 4 1 1 = + + = 0.775 2 2 2 5 4

By Simpsons rule: x 1/2 (y0 + 4y1 + y2 ) = 3 3 Exact answer:


0 1

1+4

4 1 + 5 2

= 0.78333...

1 1 dx = tan1 x = tan1 1 tan1 0 = 0 = 0.785 2 1+x 4 4 0

Roughly speaking, the error, | Simpsons Exact |, has order of magnitude (x)4 .

Exam 3 Review

18.01 Fall 2006

Lecture 25: Exam 3 Review

Integration
1. Evaluate denite integrals. Substitution, rst fundamental theorem of calculus (FTC 1), (and hints?) 2. FTC 2: d dx If F (x) =
a x

f (t) dt = f (t)

f (t) dt, nd the graph of F , estimate F , and change variables.

3. Riemann sums; trapezoidal and Simpsons rules. 4. Areas, volumes. 5. Other cumulative sums: average value, probability, work, etc. There are two types of volume problems: 1. solids of revolution 2. other (do by slices) In these problems, there will be something you can draw in 2D, to be able to see whats going on in that one plane. In solid of revolution problems, the solid is formed by revolution around the x-axis or the y -axis. You will have to decide how to chop up the solid: into shells or disks. Put another way, you must decide whether to integrate with dx or dy . After making that choice, the rest of the procedure is systematically determined. For example, consider a shape rotated around the y -axis. Shells : height y2 y1 , circumference 2x, thickness dx
2 Disks (washers) : area x2 (or x2 2 x1 ), thickness dy ; integrate dy .

Work
Work = Force Distance We need to use an integral if the force is variable.

Exam 3 Review

18.01 Fall 2006

Example 1: Pendulum. See Figure 1 Consider a pendulum of length L, with mass m at angle . The vertical force of gravity is mg (g = gravitational coecient on Earths surface)

L mass m mg

Figure 1: Pendulum. In Figure 2, we nd the component of gravitational force acting along the pendulums path F = mg sin .

mg

Figure 2: F = mg sin (force tangent to path of motion).

Exam 3 Review

18.01 Fall 2006

Is it possible to build a perpetual motion machine? Lets think about a simple pendulum, and how much work gravity performs in pulling the pendulum from 0 to the bottom of the pendulums arc. Notice that F varies. Thats why we have to use an integral for this problem. W =
0 0

(Force) (Distance) =
0

(mg sin )(L d)

0 W = Lmg cos = Lmg (cos 0 1) = mg [L(1 cos 0 )]


0

In Figure 3, we see that the work performed by gravity moving the pendulum down a distance L(1 cos ) is the same as if it went straight down.

L(1-cos)

Figure 3: Eect of gravity on a pendulum. In other words, the amount of work required depends only on how far down the pendulum goes. It doesnt matter what path it takes to get there. So, theres no free (energy) lunch, no perpetual motion machine.

MIT OpenCourseWare http://ocw.mit.edu

18.01 Single Variable Calculus


Fall 2006

For information about citing these materials or our Terms of Use, visit: http://ocw.mit.edu/terms.

Lecture 26

18.01 Fall 2006

Lecture 26: Trigonometric Integrals and Substitution

Trigonometric Integrals
How do you integrate an expression like sinnx cosmx dx? (n = 0, 1, 2... and m = 0, 1, 2, . . .)

We already know that: sin x dx = cos x + c

and cos x dx = sin x + c

Method A
Suppose either n or m is odd. Example 1. sin3x cos2x dx. Our strategy is to use sin2x + cos2x = 1 to rewrite our integral in the form: 3 2 sin x cos x dx = f (cosx) sinx dx Indeed, sin3x cos2x dx = sin2x cos2x sin x dx = (1 cos2x) cos2x sin x dx

Next, use the substitution u = cos x and du = sin x dx Then, = (1 cos2 x) cos2 x sin x dx = (1 u2 )u2 (du)

1 1 1 1 (u2 + u4 )du = u3 + u5 + c = cos3 u + cos5 x + c 5 5 3 3

Example 2. cos3 x dx = f (sin x) cos x dx = (1 sin2 x) cos x dx

Again, use a substitution, namely u = sin x and du = cos x dx u3 sin3 x cos3 x dx = (1 u2 )du = u + c = sin x +c 3 3

Lecture 26

18.01 Fall 2006

Method B
This method requires both m and n to be even. It requires double-angle formulae such as cos2 x = 1 + cos 2x 2

(Recall that cos 2x = cos2 x sin2 x = cos2 x (1 sin2 x) = 2 cos2 x 1) Integrating gets us 1 + cos 2x x sin(2x) 2 cos x dx = dx = + +c 2 2 4 We follow a similar process for integrating sin2 x. sin2 x = sin x dx =
2

1 cos(2x) 2

1 cos(2x) x sin(2x) dx = +c 2 2 4

The full strategy for these types of problems is to keep applying Method B until you can apply Method A (when one of m or n is odd). Example 3. sin2 x cos2 x dx.

Applying Method B twice yields 1 cos 2x 1 + cos 2x 1 1 2 cos 2x dx dx = 2 2 4 4 1 1 1 1 (1 + cos 4x) dx = x = sin 4x + c 4 8 8 32 There is a shortcut for Example 3. Because sin 2x = 2 sin x cos x, sin x cos x dx =
2 2

1 sin 2x 2

1 dx = 4

1 cos 4x dx = same as above 2

The next family of trig integrals, which well start today, but will not nish is: secn x tanm x dx where n = 0, 1, 2, . . . and m = 0, 1, 2, . . . Remember that sec2 x = 1 + tan2 x which we double check by writing 1 sin2 x cos2 x + sin2 x = 1 + = cos2 x cos2 x cos3 x sec2 x dx = tan x + c sec x tan x dx = sec x + c

Lecture 26

18.01 Fall 2006

To calculate the integral of tan x, write sin x tan x dx = dx cos x Let u = cos x and du = sin x dx, then sin x du tan x dx = dx = = ln(u) + c cos x u tan x dx = ln(cos x) + c (Well gure out what sec x dx is later.)

Now, lets see what happens when you have an even power of secant. (The case n even.) sec4 x dx = f (tanx) sec2 x dx = (1 + tan2 x) sec2 x dx Make the following substitution: u = tan x and du = sec2 x dx sec4 x dx = (1 + u2 )du = u + u3 tan3 x + c = tan x + +c 3 3

What happens when you have a odd power of tan? (The case m odd.) tan3 x sec x dx = f (sec x) d(sec x) = (sec2 x 1) sec x tan x dx

(Remember that sec2 x 1 = tan2 x.) Use substitution: u = sec x and du = sec x tan x dx Then, tan x secx dx =
3

(u2 1)du =

u3 sec3 x sec x + c u+c= 3 3

We carry out one nal case: n = 1, m = 0 sec x dx = ln (tan x + sec x) + c

Lecture 26

18.01 Fall 2006

We get the answer by advanced guessing, i.e., knowing the answer ahead of time. sec x + tan x sec2 x + sec x tan x sec x dx = sec x dx = dx sec x + tan x tan x + sec x Make the following substitutions: u = tan x + sec x and du = (sec2 x + sec x tan x) dx This gives sec x dx = du = ln(u) + c = ln(tan x + sec x) + c u

Cases like n = 3, m = 0 or more generally n odd and m even are more complicated and will be discussed later.

Trigonometric Substitution
Knowing how to evaluate all of these trigonometric integrals turns out to be useful for evaluating integrals involving square roots. Example 4. y = a2 x2

Figure 1: Graph of the circle x2 + y2 = a2 . We already know that the area of the top half of the disk is a a2 a2 x2 dx = 2 a 4

Lecture 26

18.01 Fall 2006

What if we want to nd this area?

Figure 2: Area to be evaluated is shaded. To do so, you need to evaluate this integral: t=x a2 t2 dt
t=0

Let t = a sin u and dt = a cos u du. (Remember to change the limits of integration when you do a change of variables.) Then, a2 t2 = a2 a2 sin2 u = a2 cos2 u; a2 t2 = a cos u Plugging this into the integral gives us
0 x

a2 t2 dt = (a cos u) a cos u du = a2

u=sin1 (x/a)

cos2 u du

u=0

Heres how we calculated the new limits of integration: t = t =


0 x

0 = a sin u = 0 = u = 0 x = a sin u = x = u = sin1 (x/a)


0 sin1 (x/a)

a2 t2 dt = a2 = a sin
2 1

cos2 u du = a2 + a 4
2

u sin 2u + 2 4

1 sin (x/a)
0

(x/a)

2 sin(sin1 (x/a)) cos(sin1 (x/a))

(Remember, sin 2u = 2 sin u cos u.) Well pick up from here next lecture (Lecture 28 since Lecture 27 is Exam 3). 5

Lecture 28

18.01 Fall 2006

Lecture 28: Integration by Inverse Substitution; Completing the Square

Trigonometric Substitutions, continued

-a
x

Figure 1: Find area of shaded portion of semicircle. a2 t2 dt

dt = a cos u du a2 t2 = a2 a2 sin2 u = a2 cos2 u = a2 t2 = a cos u (No more square root!) Start: x = a u = /2; Finish: x = a u = /2 1 + cos(2u) u sin(2u) a2 t2 dt = a2 cos2 u du = a2 du = a2 + +c 2 2 4 1 + cos(2u) ). 2 We want to express this in terms of x, not u. When t = 0, a sin u = 0, and therefore u = 0. When t = x, a sin u = x, and therefore u = sin1 (x/a). (Recall, cos2 u = sin(2u) 2 sin u cos u 1 = = sin u cos u 4 4 2 x sin u = sin sin1 (x/a) = a

t = a sin u;

Lecture 28

18.01 Fall 2006

How can we nd cos u = cos sin1 (x/a) ? Answer: use a right triangle (Figure 2).

a u a-x
Figure 2: sin u = x/a; cos u = From the diagram, we see cos u = And nally,
0 x

p a2 x2 /a.

a 2 x2 a

a2

t2

dt = a

1 u 1 (x/a) 1 x a2 x2 2 sin + sin u cos u 0 = a + 4 2 2 2 a a a2 x 1 a2 t2 dt = sin1 ( ) + x a2 x2 2 a 2

When the answer is this complicated, the route to getting there has to be rather complicated. Theres no way to avoid the complexity. 1 Lets double-check this answer. The area of the upper shaded sector in Figure 3 is a2 u. The 2 2 2 area of the lower shaded region, which is a triangle of height a2 x2 and base x, is 1 2x a x .

Lecture 28

18.01 Fall 2006

Figure 3: Area divided into a sector and a triangle. Here is a list of integrals that can be computed using a trig substitution and a trig identity. integral dx x2 + 1 dx x2 1 dx 1 x2 substitution x = tan u x = sec u x = sin u trig identity tan2 u + 1 = sec2 u sec2 u 1 = tan2 u 1 sin2 u = cos2 u

Lets extend this further. How can we evaluate an integral like this? dx 2 x + 4x When you have a linear and a quadratic term under the square root, complete the square. x2 + 4x = (something)2 constant In this case, (x + 2)2 = x2 + 4x + 4 = x2 + 4x = (x + 2)2 4 Now, we make a substitution. v =x+2 Plugging these in gives us dx = (x + 2)2 4 dv v2 4 and dv = dx

Now, let v = 2 sec u and dv = 2 sec u tan u dv 2 sec u tan u du = = sec u du 2 tan u v2 4 3

Lecture 28

18.01 Fall 2006

Remember that

sec u du = ln(sec u + tan u) + c

Finally, rewrite everything in terms of x. v = 2 sec u cos u = 2 v

Set up a right triangle as in Figure 4. Express tan u in terms of v .

v u 2

v-4

Figure 4: sec u = v/2 or cos u = 2/v. Just from looking at the triangle, we can read o v2 4 and tan u = 2 v v2 4 2 sec u du = ln + +c 2 2 = ln(v + v 2 4) ln 2 + c v sec u = 2 We can combine those last two terms into another constant, c . dx = ln(x + 2 + x2 + 4x) + c x2 + 4x Heres a teaser for next time. In the next lecture, well integrate all rational functions. By rational functions, we mean functions that are the ratios of polynomials: P (x) Q(x) Its easy to evaluate an expression like this: 1 3 + dx = ln |x 1| + 3 ln |x + 2| + c x1 x+2 4

Lecture 28

18.01 Fall 2006

If we write it a bit dierently, however, it becomes much harder to integrate: 1 3 x + 2 + 3(x 1) 4x 1 + = = 2 x1 x+2 (x 1)(x + 2) x +x2 4x 1 = ??? x2 + x 2 How can we reorganize what to do starting from (4x 1)/(x2 + x 2)? Next time, well see how. It involves some algebra.

Lecture 29

18.01 Fall 2006

Lecture 29: Partial Fractions


We continue the discussion we started last lecture about integrating rational functions. We dened a rational function as the ratio of two polynomials: P (x) Q(x) We looked at the example

1 3 + dx = ln |x 1| + 3 ln |x + 2| + c x1 x+2

That same problem can be disguised: 1 3 (x + 2) + 3(x 1) 4x 1 + = = 2 x1 x+2 (x 1)(x + 2) x +x2 which leaves us to integrate this: 4x 1 dx = ??? x2 + x 2 P (x) into simpler pieces. Q(x)

Goal: we want to gure out a systematic way to split First, we factor the denominator Q(x).

4x 1 4x 1 A B = = + x2 + x 2 (x 1)(x + 2) x1 x+2

Theres a slow way to nd A and B . You can clear the denominator by multiplying through by (x 1)(x + 2): (4x 1) = A(x + 2) + B (x 1) From this, you nd 4=A+B and 1 = 2A B You can then solve these simultaneous linear equations for A and B . This approach can take a very long time if youre working with 3, 4, or more variables.

Theres a faster way, which we call the cover-up method. Multiply both sides by (x 1): 4x 1 B =A+ (x 1) x+2 x+2 Set x = 1 to make the B term drop out: 41 =A 1+2 A=1 1

Lecture 29

18.01 Fall 2006

The fastest way is to do this in your head or physically cover up the struck-through terms. For instance, to evaluate B : 4x 1 A B = + (x 1) (x + 2) x1 (x + 2) Implicitly, we are multiplying by (x + 2) and setting x = 2. This gives us 4(2) 1 =B 2 1 = B=3

What weve described so far works when Q(x) factors completely into distinct factors and the degree of P is less than the degree of Q.

If the factors of Q repeat, we use a slightly dierent approach. For example: A B C x2 + 2 = + + 2 2 (x 1) (x + 2) x 1 (x 1) x+2 Use the cover-up method on the highest degree term in (x 1). x2 + 1 2 = B + [stu](x 1) x+2 = 12 + 2 =B 1+2 = B=1

Implicitly, we multiplied by (x 1)2 , then took the limit as x 1. C can also be evaluated by the cover-up method. Set x = 2 to get x2 + 2 = C + [stu](x + 2) (x 1) This yields x2 + 2 A 1 2/3 = + + 2 2 (x 1) (x + 2) x 1 (x 1) x+2 Cover-up cant be used to evaluate A. Instead, plug in an easy value of x: x = 0. 2 A 1 1 1 = +1+ = 1 = 1 + A = A = 2 (1) (2) 1 3 3 3 Now we have a complete answer: x2 + 2 1 1 2 = + + (x 1)2 (x + 2) 3(x 1) (x 1)2 3(x + 2)
2

(2)2 + 2 =C (2 1)2

C=

2 3

Not all polynomials factor completely (without resorting to using complex numbers). For example: 1 A1 B1 x + C1 = + 2 (x + 1)(x 1) x1 x2 + 1 We nd A1 , as usual, by the cover-up method. 12 1 = A1 +1 2 = A1 = 1 2

Lecture 29

18.01 Fall 2006

Now, we have 1 1/2 B1 x + C1 = + (x2 + 1)(x 1) x1 x2 + 1 Plug in x = 0. 1 1 C1 = + 1(1) 2 1 = C1 = 1 2

Now, plug in any value other than x = 0, 1. For example, lets use x = 1. 1 1/2 B1 (1) 1/2 B1 1/2 1 = + = 0 = = B1 = 2(2) 2 2 2 2 Alternatively, you can multiply out to clear the denominators (not done here). Lets try to integrate this function, now. dx 1 dx 1 x dx 1 dx = 2 2 2 (x + 1)(x 1) 2 x1 2 x +1 2 x +1 = 1 1 1 ln |x 1| ln | x2 + 1 | tan1 x + c 2 4 2

What if were faced with something that looks like this? dx (x 1)10 This is actually quite simple to integrate: dx 1 = (x 1)9 + c (x 1)10 9

What about this?

dx (x2 + 1)10

Here, we would use trig substitution: x = tan u and and the trig identity tan2 u + 1 = sec2 u to get sec2 u du = (sec2 u)10 cos18 u du dx = sec2 udu

From here, we can evaluate this integral using the methods we introduced two lectures ago.

Lecture 30

18.01 Fall 2006

Lecture 30: Integration by Parts, Reduction Formulae

Integration by Parts
Remember the product rule: (uv ) = u v + uv We can rewrite that as uv = (uv ) u v Integrate this to get the formula for integration by parts: uv dx = uv u v dx

Example 1.

tan1 x dx.

At rst, its not clear how integration by parts helps. Write tan1 x dx = tan1 x(1 dx) = uv dx with u = tan1 x and Therefore, 1 1 + x2 Plug all of these into the formula for integration by parts to get: tan1 x dx = uv dx = (tan1 x)x v = x and u = = x tan1 x v = 1.

1 (x)dx 1 + x2

1 ln |1 + x2 | + c 2

Alternative Approach to Integration by Parts


As above, the product rule: (uv ) = u v + uv can be rewritten as uv = (uv ) u v This time, lets take the denite integral:
a b

uv dx =
a

(uv ) dx
a

u v dx

Lecture 30

18.01 Fall 2006

By the fundamental theorem of calculus, we can say b b uv dx = uv


a a

u v dx

Another notation in the indenite case is u dv = uv v du This is the same because dv = v dx = uv dx = u dv Example 2. (ln x)dx 1 u = ln x; du = dx and dv = dx; v = x x 1 (ln x)dx = x ln x x dx = x ln x dx = x ln x x + c x We can also use advanced guessing to solve this problem. We know that the derivative of something equals ln x: d (??) = ln x dx Lets try d 1 (x ln x) = ln x + x = ln x + 1 dx x Thats almost it, but not quite. Lets repair this guess to get: d (x ln x x) = ln x + 1 1 = ln x dx and du = u dx = u v dx = vu dx = v du

Reduction Formulas (Recurrence Formulas)


Example 3. Lets try: u = (ln x)n = u = n(ln x)n1 v = dx; v = x Plugging these into the formula for integration by parts gives us: (ln x) dx = x(ln x)
n n

(ln x) dx 1 x

n(ln x)

n1

1 1 x dx x

Keep repeating integration by parts to get the full formula: n (n 1) (n 2) (n 3) etc Example 4. xn ex dx Lets try: u = xn = u = nxn1 ; 2 v = ex = v = ex

Lecture 30

18.01 Fall 2006

Putting these into the integration by parts formula gives us: xn ex dx = xn ex nxn1 ex dx Repeat, going from n (n 1) (n 2) etc.

Bad news: If you change the integrals just a little bit, they become impossible to evaluate: 1 2 tan x dx = impossible ex dx = also impossible x

Good news: When you cant evaluate an integral, then 2 x e dx 1 x is an answer, not a question. This is the solution you dont have to integrate it! The most important thing is setting up the integral! (Once youve done that, you can always evaluate it numerically on a computer.) So, why bother to evaluate integrals by hand, then? Because you often get families of related integrals, such as x e F (a) = dx a x 1 where you want to nd how the answer depends on, say, a.

Lecture 30

18.01 Fall 2006

Arc Length
This is very useful to know for 18.02 (multi-variable calculus).

y y=f(x)
ds dx dy

Figure 1: Innitesimal Arc Length ds

ds dx

dy

Figure 2: Zoom in on Figure 1 to see an approximate right triangle. In Figures 1 and 2, s denotes arc length and ds = the innitesmal of arc length. 2 ds = (dx)2 + (dy )2 = 1 + (dy/dx) dx Integrating with respect to ds nds the length of a curve between two points (see Figure 3). To nd the length of the curve between P0 and P1 , evaluate:
P1

ds
P0

Lecture 30

18.01 Fall 2006

P P

Figure 3: Find length of curve between P0 and P1 . We want to integrate with respect to x, not s, so we do the same algebra as above to nd ds in terms of dx. 2 (ds)2 (dx)2 (dy )2 dy = + =1+ (dx)2 (dx)2 (dx)2 dx Therefore,
P1

ds =
a

1+

P0

dy dx

2 dx

Example 5: The Circle. x2 + y 2 = 1 (see Figure 4).

Figure 4: The circle in Example 1.

Lecture 30

18.01 Fall 2006

We want to nd the length of the arc in Figure 5:

a
Figure 5: Arc length to be evaluated.

1 x2 dy 2x 1 x = = 2 dx 2 1x 1 x2 2 x ds = 1 + dx 1 x2 2 x x2 1 x2 + x2 1 1+ =1+ = = 2 2 2 1x 1x 1 x2 1x 1 ds = dx 1 x2 a a dx s= = sin1 x = sin1 a sin1 0 = sin1 a 2 0 1x 0 sin s = a y= This is illustrated in Figure 6.

Lecture 30

18.01 Fall 2006

s a 1 a

Figure 6: s = angle in radians.

Parametric Equations
Example 6. x = a cos t y = a sin t Ask yourself: whats constant? Whats varying? Here, t is variable and a is constant. Is there a relationship between x and y ? Yes: x2 + y 2 = a2 cos2 t + a2 sin2 t = a2 Extra information (besides the circle): At t = 0, x = a cos 0 = a and y = a sin 0 = 0 At t = , 2 x = a cos = 0 and y = a sin = a 2 2 Thus, for 0 t /2, a quarter circle is traced counter-clockwise (Figure 7).

Lecture 30

18.01 Fall 2006

t=/2 (0,a)

(a,0) t=0
Figure 7: Example 6. x = a cos t, y = a sin t; the particle is moving counterclockwise. Example 7: The Ellipse See Figure 8. x = 2 sin t;
2

y = cos t

x + y 2 = 1( = (2 sin t)2 /4 + (cos t)2 = sin2 t + cos2 t = 1) 4

t=0 (0,1)

(2,0) t=/2
Figure 8: Ellipse: x = 2 sin t, y = cos t (traced clockwise). Arclength ds for Example 6. dx = a sin t dt, dy = a cos t dt ds = (dx)2 + (dy )2 = (a sin t dt)2 + (a cos t dt)2 = (a sin t)2 + (a cos t)2 dt = a dt

Lecture 31

18.01 Fall 2006

Lecture 31: Parametric Equations, Arclength, Surface Area

Arclength, continued
Example 1. Consider this parametric equation: x = t2 x3 = (t2 )3 = t6 ; y = t3 for 0 t 1 0x1

y 2 = (t3 )2 = t6

= x3 = y 2 = y = x2/3

ds
ds dy dx

dy

dx

Figure 1: Innitesimal Arclength. (ds)2 = (dx)2 + (dy )2 (2t dt)2 + (3t2 dt)2 = (4t2 + 9t4 )(dt)2 (dx)2 (dy )2 t=1 1 1 2 4 Length = ds = 4t + 9t dt = t 4 + 9t2 dt (ds)2 =
t=0 0 2 3/2 1 0

(4 + 9t ) 1 (133/2 43/2 ) = 27 27 0 Even if you cant evaluate the integral analytically, you can always use numerical methods. =

Lecture 31

18.01 Fall 2006

Surface Area (surfaces of revolution)

y ds y x

a
Figure 2: Calculating surface area

ds (the innitesimal curve length in Figure 2) is revolved a distance 2y . The surface area of the thin strip of width ds is 2y ds. Example 2. Revolve Example 1 (x = t2 , y = t3 , 0 t 1) around the x-axis. Refer to Figure 3.

Figure 3: Curved surface of a trumpet.

Lecture 31

18.01 Fall 2006

Area = 2y ds =

t3 y

1 t 4 + 9t2 dt t4 4 + 9t2 dt = 2 0 ds

Now, we discuss the method used to evaluate t4 (4 + 9t2 )1/2 dt Were going to ignore the factor of 2 . You can reinsert it once youre done evaluating the integral. We use the trigonometric substitution t= 2 tan u; 3 dt = 2 sec2 u du; 3 tan2 u + 1 = sec2 u

Putting all of this together gives us: t4 (4 + 9t2 )1/2 dt = = 4 1/2 2 4 2 tan u 4+9 tan2 u sec2 u du 3 9 3 5 2 tan4 u(2 sec u)(sec2 u du) 3

This is a tan sec integral. Its doable, but it will take a long time for you to work the whole thing out. Were going to stop evaluating it here.

Example 3 Lets use what weve learned to nd the surface area of the unit sphere (see Figure 4).

rotate the curve by 2 radians

. .

Figure 4: Slice of spherical surface (orange peel, only, not the insides).

Lecture 31

18.01 Fall 2006

For the top half of the sphere, y= 1 x2 We want to nd the area of the spherical slice between x = a and x = b. A spherical slice has area A=
x=a x=b

2y ds

From last time, dx ds = 1 x2 Plugging that in yields a remarkably simple formula for A: A=
a b

1 x2

dx = 1 x2

2 dx

= 2 (b a) Special Cases For a whole sphere, a = 1, and b = 1. 2 (1 (1)) = 4 is the surface area of a unit sphere. For a half sphere, a = 0 and b = 1. 2 (1 0) = 2

Lecture 32

18.01 Fall 2006

Lecture 32: Polar Co-ordinates, Area in Polar Co-ordinates

Polar Coordinates

Figure 1: Polar Co-ordinates. In polar coordinates, we specify an objects position in terms of its distance r from the origin and the angle that the ray from the origin to the point makes with respect to the x-axis. Example 1. What are the polar coordinates for the point specied by (1, 1) in rectangular coordinates?

r
(1,-1)
Figure 2: Rectangular Co-ordinates to Polar Co-ordinates. 2

= =

12 + (1)2 = 4

In most cases, we use the convention that r 0 and 0 2 . But another common convention is to say r 0 and . All values of and even negative values of r can be used.

Lecture 32

18.01 Fall 2006

r
x

Figure 3: Rectangular Co-ordinates to Polar Co-ordinates. Regardless of whether we allow positive or negative values of r or , what is always true is: x = r cos and y = r sin

3 For instance, x = 1, y = 1 can be represented by r = 2, = : 4 3 1 = x = 2 cos 4 and 3 1 = y = 2 sin 4

Example 2. Consider a circle of radius a with its center at x = a, y = 0. We want to nd an equation that relates r to .

(a,0)

Figure 4: Circle of radius a with center at x = a, y = 0.

Lecture 32

18.01 Fall 2006

We know the equation for the circle in rectangular coordinates is (x a)2 + y 2 = a2 Start by plugging in: x = r cos This gives us (r cos a)2 + (r sin )2 = a2 r2 cos2 2arcos + a2 + r2 sin2 = a2 r2 2ar cos = 0 r = 2a cos The range of 0 traces out the top half of the circle, while 0 traces out the bottom 2 2 half. Lets graph this. and y = r sin

= /4 r (a,0) =0 x

Figure 5: r = 2a cos , /2 /2.

At = 0, r = 2a = x = 2a, y = 0 At = , r = 2a cos = a 2 4 4 The main issue is nding the range of tracing the circle once. In this case, = = 2 (down) 2 (up) << . 2 2

3 << . When = , r = 2a cos = 2a(1) = 2a. The 2 2 3 radius points backwards. In the range < < , the same circle is traced out a second time. 2 2 Weird range (avoid this one):

Lecture 32

18.01 Fall 2006

r=f()

Figure 6: Using polar co-ordinates to nd area of a generic function.

Area in Polar Coordinates


Since radius is a function of angle (r = f ()), we will integrate with respect to . The question is: what, exactly, should we integrate? 2 ?? d
1

Lets look at a very small slice of this region:

rd

Figure 7: Approximate slice of area in polar coordinates. This innitesimal slice is approximately a right triangle. To nd its area, we take: Area of slice So, Total Area =
1 2

1 1 (base) (height) = r(r d) 2 2 1 2 r d 2

Lecture 32 < < (the circle in Figure 5). 2 2 /2 /2 1 A = area = (2a cos )2 d = 2a2 cos2 d /2 2 /2

18.01 Fall 2006

Example 3. r = 2a cos , and

Because cos2 =

1 1 + cos 2, we can rewrite this as 2 2 /2 A = area = (1 + cos 2) d = a2


/2

/2

d + a2

/2

cos 2 d
/2

/2

= a2 +

/2 0 1 1 sin 2 = a2 + [sin sin( )] 2 2 /2 A = area = a2

Example 4: Circle centered at the Origin.

r=a

Figure 8: Example 4: Circle centered at the origin x = r cos ; y = r sin x + y 2 = r2 cos2 + r2 sin2 = r2
2

The circle is x2 + y 2 = a2 , so r = a and x = a cos ; y = a sin A=


0 2

1 2 1 a d = a2 2 = a2 . 2 2

Lecture 32

18.01 Fall 2006

Example 5: A Ray. In this case, = b.

=b

Figure 9: Example 5: The ray = b, 0 r < . The range of r is 0 r < ; x = r cos b; y = r sin b.

Example 6: Finding the Polar Formula, based on the Cartesian Formula

1/sin

Figure 10: Example 6: Cartesian Form to Polar Form Consider, in cartesian coordinates, the line y = 1. To nd the polar coordinate equation, plug in y = r sin and x = r cos and solve for r. r sin = 1 = r = 1 sin with 0<<

Lecture 32

18.01 Fall 2006

Example 7: Going back to (x, y ) coordinates from r = f (). Start with 1 r= . 1 1 + 2 sin Hence, r+ Plug in r = x2 + y 2 : Finally, 3y 2 +y =1 4 This is an equation for an ellipse, with the origin at one focus. x2 + Useful conversion formulas: r= x2 + y 2 and = tan1 y x x2 + y 2 = 1 y 2 r sin = 1 2 y =1 2 y 2 y2 x2 + y 2 = 1 =1y+ 2 4

x2 + y 2 +

Example 8: A Rose r = cos(2) The graph looks a bit like a ower:

r<0

/4

r>0 r>0 1

r<0
Figure 11: Example 8: Rose For the rst petal << 4 4

-/4

Note: Next lecture is Lecture 34 as Lecture 33 is Exam 4. 7

Lecture 32: Exam 4 Review

18.01 Fall 2006

Exam 4 Review
1. Trig substitution and trig integrals. 2. Partial fractions. 3. Integration by parts. 4. Arc length and surface area of revolution 5. Polar coordinates 6. Area in polar coordinates.

Questions from the Students


Q: What do we need to know about parametric equations? A: Just keep this formula in mind: ds = Example: Youre given x(t) = t4 and y (t) = 1 + t Find s (length). ds = Then, integrate with respect to t. Q: Can you quickly review how to do partial fractions? A: When nding partial fractions, rst check whether the degree of the numerator is greater than or equal to the degree of the denominator. If so, you rst need to do algebraic longdivision. If not, then you can split into partial fractions. Example. x2 + x + 1 (x 1)2 (x + 2) We already know the form of the solution: x2 + x + 1 A B C = + + (x 1)2 (x + 2) x 1 (x 1)2 x+2 There are two coecients that are easy to nd: B and C . We can nd these by the cover-up method. 12 + 1 + 1 3 B= = (x 1) 1+2 3 1 (4t3 )2 + (1)2 dt dx dt 2 + dy dt 2

Lecture 32: Exam 4 Review

18.01 Fall 2006

To nd C , C= (2)2 2 + 1 1 = (2 1)2 3 (x 2)

To nd A, one method is to plug in the easiest value of x other than the ones we already used (x = 1, 2). Usually, we use x = 0. 1 A 1 1/3 = + + (1)2 (2) 1 (1)2 2 and then solve to nd A. The Review Sheet handed out during lecture follows on the next page.

Lecture 32: Exam 4 Review

18.01 Fall 2006

Exam 4 Review Handout


1. Integrate by trigonometric substitution; evaluate the trigonometric integral and work backwards to the original variable by evaluating trig(trig1 ) using a right triangle: a) a2 x2 use x = a sin u, dx = a cos u du. b) a2 + x2 use x = a tan u, dx = a sec2 u du c) x2 a2 use x = a sec u, dx = a sec u tan u du 2. Integrate rational functions P/Q (ratio of polynomials) by the method of partial fractions: If the degree of P is less than the degree of Q, then factor Q completely into linear and quadratic factors, and write P/Q as a sum of simpler terms. For example, 3x2 + 1 A B1 B2 Cx + D = + + + 2 2 2 2 (x 1)(x + 2) (x + 9) x 1 (x + 2) (x + 2) x +9 Terms such as D/(x2 + 9) can be integrated using the trigonometric substitution x = 3 tan u. This method can be used to evaluate the integral of any rational function. In practice, the hard part turns out to be factoring the denominator! In recitation you encountered two other steps required to cover every case systematically, namely, completing the square1 and long division.2 3. Integration by parts:
a b

b b uv dx = uv u vdx a
a

This is used when u v is simpler than uv . (This is often the case if u is simpler than u.) 4. Arclength: ds = dx2 + dy 2 . Depending on whether you want to integrate with respect to x, t or y this is written ds = 1 + (dy/dx)2 dx; ds = (dx/dt)2 + (dy/dt)2 dt; ds = (dx/dy )2 + 1 dy 5. Surface area for a surface of revolution: a) around the x-axis: 2yds = 2y 1 + (dy/dx)2 dx (requires a formula for y = y (x)) b) around the y -axis: 2xds = 2x (dx/dy )2 + 1 dy (requires a formula for x = x(y )) 6. Polar coordinates: x = r cos , y = r sin (or, more rarely, r = x2 + y 2 , = tan1 (y/x)) a) Find the polar equation for a curve from its equation in (x, y ) variables by substitution. b) Sketch curves given in polar coordinates and understand the range of the variable (often in preparation for integration). 7. Area in polar coordinates:
2 1

1 2 r d 2

(Pay attention to the range of to be sure that you are not double-counting regions or missing them.)
example, we rewrite the denominator x2 + 4x + 13 = (x + 2)2 + 9 = u2 + a2 with u = x + 2 and a = 3. division is used when the degree of P is greater than or equal to the degree of Q. It expresses P (x)/Q(x) = P1 (x) + R(x)/Q(x) with P1 a quotient polynomial (easy to integrate) and R a remainder. The key point is that the remainder R has degree less than Q, so R/Q can be split into partial fractions.
2 Long 1 For

Lecture 32: Exam 4 Review

18.01 Fall 2006

The following formulas will be printed with Exam 4


sin2 x + cos2 x = 1; sin2 x = 1 1 cos 2x; 2 2 sec2 x = tan2 x + 1 cos2 x = 1 1 + cos 2x 2 2

cos 2x = cos2 x sin2 x;

sin 2x = 2 sin x cos x

d d tan x = sec2 x; sec x = sec x tan x; dx dx tan x dx = ln(cos x) + c;

d 1 d 1 tan1 x = ; sin1 x = dx 1 + x2 dx 1 x2 sec x dx = ln(sec x + tan x) + c

See the next page for a review on integration of rational functions.

Lecture 32: Exam 4 Review

18.01 Fall 2006

Postscript: Systematic integration of rational functions


For a general rational function P/Q, the rst step is to express P/Q as the sum of a polynomial and a ratio in which the numerator has smaller degree than the denominator. For example, x3 3x 2 =x+2+ 2 x2 2x + 1 x 2x + 1 (To carry out this long division, do not factor the denominator Q(x) = x2 2x + 1, just leave it alone.) The quotient x + 2 is a polynomial and is easy to integrate. The remainder term 3x 2 (x 1)2 has a numerator 3x 2 of degree 1 which is less than the degree 2 of the denominator (x 1)2 . Therefore there is a partial fraction decomposition. In fact, 3x 2 (3x 3) + 1 3 1 = = + (x 1)2 (x 1)2 x 1 (x 1)2 In general, if P has degree n and Q has degree m, then long division gives P (x) R(x) = P1 (x) + Q(x) Q(x) in which P1 , the quotient in the long division, has degree n m and R, the remainder in the long division, has degree at most m 1. Evaluation of the simple pieces The integral dx 1 = (x a)1n + c (x a)n n1

if n = 1 and ln |x a| + c if n = 1. On the other hand the terms xdx dx and (Ax2 + Bx + C )n (Ax2 + Bx + C )n are handled by rst completing the square: B2 Ax + Bx + C = A(x B/2A) + C 4A
2 2

Using the variable u =

A(x B/2A) yields combinations of integrals of the form udu du and 2 2 n 2 (u + k ) (u + k 2 )n

The rst integral is handled by the substitution w = u2 + k 2 , dw = 2udu. The second integral can be worked out using the trigonometric substitution u = k tan du = k sec2 d. This then leads to sec-tan integrals, and the actual computation for large values of n are long. There are also other cases that we will not cover systematically. Examples are below: 1. If Q(x) = (x a)m (x b)n , then the expression is A1 A2 Am B1 B2 Bn + + + + + + + x a (x a)2 x b (x b)2 (x a)m (x b)n 5

Lecture 32: Exam 4 Review

18.01 Fall 2006

2. If there are quadratic factors like (Ax2 + Bx + C )p , one gets terms Ax2 a1 x + b1 a2 x + b2 x ap x + bp + + + 2 2 2 + Bx + C (Ax + Bx + C ) (Ax + Bx + C )p

for each such factor. (To integrate these quadratic pieces complete the square and make a trigonometric substitution.)

Lecture 34

18.01 Fall 2006

Lecture 34: Indeterminate Forms - LHpitals Rule

LHpitals Rule
(Two correct spellings: LHpital and LHospital) Sometimes, we run into indeterminate forms. These are things like 0 0 and For instance, how do you deal with the following? x3 1 0 = ?? 2 x 1 x 1 0 lim

Example 0. One way of dealing with this is to use algebra to simplify things: x3 1 (x 1)(x2 + x + 1) x2 + x + 1 3 = lim = lim = 2 x1 x 1 x1 x1 (x 1)(x + 1) x+1 2 lim In general, when f (a) = g (a) = 0, f (x) f (x) f (a) lim f (x) f (a) xa xa lim = lim x a = = xa g (x) xa g (x) g (x) g (a) g (a) lim xa xa xa This is the easy version of LHpitals rule: f (x) f (a) = xa g (x) g (a) lim Note: this only works when g (a) = 0! In example 0, f (x) = x3 = 1; g (x) = x2 1 f (x) = 3x2 ; g (x) = 2x = f (1) = 3; g (1) = 2 The limit is f (1)/g (1) = 3/2. Now, lets go on to the full LHpital rule.

Lecture 34

18.01 Fall 2006

Example 1. Apply LHpitals rule (a.k.a. LHop) to x15 1 x 1 x3 1 lim to get x15 1 15x14 15 = lim = =5 3 2 x1 x 1 x1 3x 3 Lets compare this with the answer wed get if we used linear approximation techniques, instead of LHpitals rule: x15 1 15(x 1) lim (Here, f (x) = x15 1, a = 1, f (a) = b = 0, m = f (1) = 15, and f (x) m(x a) + b.) Similarly, x3 1 3(x 1) Therefore, x15 1 15(x 1) =5 x3 1 3(x 1)

Example 2. Apply LHop to


x 0

lim

sin 3x x

to get
x 0

lim

3 cos 3x =3 1

This is the same as

d sin(3x) = 3 cos(3x) =3 dx x=0 x=0

Example 3.
x 4

lim

sin x cos x cos x + sin x 1 1 = lim = + = 2 x 4 x 4 1 2 2 f (x) = sin x cos x, f (x) = cos x + sin x f = 2 4 y 0 are always a type of limit. x 0

Remark: Derivatives lim

x0

cos x 1 . x Use LHpitals rule to evaluate the limit: Example 4. lim


x 0

x 0

lim

cos x 1 sin x = lim =0 x0 x x

Lecture 34

18.01 Fall 2006

cos x 1 . x 0 x2 cos x 1 cos x 1 sin x cos x 1 lim = lim = lim = lim = x0 x0 x0 x0 x2 x2 2x 2 2 Just to check, lets compare that answer to the one we would get if we used quadratic approximation techniques. Remember that: 1 cos x 1 x2 (x 0) 2 1 2 1 1 x 1 ( )x2 cos x 1 1 2 2 = = x2 x2 2 x2 Example 5. lim

Example 6. lim

x 0

sin x . x2
x0

sin x cos x = lim By LHpitals rule x0 2x x2 If we apply LHpital again, we get sin x lim =0 x0 2 But this doesnt agree with what we get from taking the linear approximation: lim sin x x 1 2 = as x 0+ x2 x x We can clear up this seeming paradox by noting that lim cos x 1 = 2x 0

x0

0 The limit is not of the form , which means LHpitals rule cannot be used. The point is: look 0 before you LHp!

More interesting cases that work.


, or if x , or x . Lets apply this to rates of growth. Which function goes to faster: x, eax , or ln x? It is also okay to use LHpitals rule on limits of the form

Example 7. For a > 0,

So eax

eax aeax = lim = + x x x 1 grows faster than x (for a > 0). lim

Example 8. eax aeax c2 eax a10 eax = by LHpital = lim = lim = = lim = 10 9 8 x x x 10x x 10 9x x 10! lim

Lecture 34

18.01 Fall 2006

You can apply LHpitals rule ten times. Theres a better way, though: eax x10 1/10 = eax/10 x 10 = 10 =

eax = lim x x10 x lim

eax/10 x

Example 9.
x

lim

ln x 1/x = lim = lim 3x1/3 = 0 x 1/3x2/3 x x1/3 (x , a > 0)

Combining the preceding examples, ln x x1/3 x x10 eax LHpitals rule applies to

0 and . But, we sometimes face other indeterminate limits, such 0 0 as 1 , 0 , and 0 . Use algebra, exponentials, and logarithms to put these in LHpital form. Example 10. lim xx for x > 0.
x 0

Because the exponent is a variable, use base e:


x 0

lim xx = lim ex ln x
x 0

First, we need to evaluate the limit of the exponent


x0

lim x ln x 0 or . 0

This limit has the form 0 . We want to put it in the form Lets try to put it into the 0 form: 0

x 1/ ln x

We dont know how to nd lim

1 , though, so that approach isnt helpful. ln x Instead, lets try to put it into the form:
x0

ln x 1/x Using LHpitals rule, we nd lim x ln x = lim ln x 1/x = lim = lim (x) = 0 x0 1/x x0 1/x2 x0

x 0

Therefore,
x 0

lim (x ln x) lim xx = lim ex ln x = e x0 = e0 = 1


x 0

Lecture 35

18.01 Fall 2006

Lecture 35: Improper Integrals

Denition.
An improper integral, dened by
a

f (x)dx = lim
M a

f (x)dx

is said to converge if the limit exists (diverges if the limit does not exist). Example 1.
0

ekx dx = 1/k
0 M

(k > 0)

M ekx dx = (1/k )ekx = (1/k )(1 ekM )


0

Taking the limit as M , we nd ekM 0 and ekx dx = 1/k


0

We rewrite this calculation more informally as follows, k ekx dx = (1/k )ekx ) = 1/k = (1/k )(1 e
0 0

(since k > 0)

Note that the integral over the innite interval ekx dx = 1/k has an easier formula than the 0 M corresponding nite integral ekx dx = (1/k )(1 ekM ). As a practical matter, for large M , the term ekM is negligible, so even the simpler formula 1/k serves as a good approximation to the nite integral. Innite integrals are often easier than nite ones, just as innitesimals and derivatives are easier than dierence quotients. Application: Replace x by t = time in seconds in Example 1. R = rate of decay = number of atoms that decay per second at time 0. At later times t > 0 the decay rate is Rekt (smaller by an exponential factor ekt ) Eventually (over time 0 t < ) every atom decays. So the total number of atoms N is calculated using the formula we found in Example 1, N= Rekt dt = R/k
0 0

The half life H of a radioactive element is the time H at which the decay rate is half what it was at the start. Thus ekH = 1/2 = kH = ln(1/2) 1 = k = (ln 2)/H

Lecture 35

18.01 Fall 2006

Hence R = N k = N (ln 2)/H Let us illustrate with Polonium 210, which has been in the news lately. The half life is 138 days or H = (138days)(24hr/day)(602 sec/hr) = (138)(24)(60)2 seconds Using this value of H , we nd that one gram of Polonium 210 emits (1 gram)(6 1023 /210 atoms/gram)(ln2)/H = 1.661014 decays/sec 4500 curies At 5.3 MeV per decay, Polonium gives o 140 watts of radioactive energy per gram (white hot). Polonium emits alpha rays, which are blocked by skin but when ingested are 20 times more dangerous than gamma and X-rays. The lethal dose, when ingested, is about 107 grams. Example 2. We calculate,
0

dx/(1 + x2 ) = /2.
0 M

M dx 1 = tan x = tan1 M /2 1 + x2
0

as M . (If = tan

M then /2 as M . See Figures 1 and 2.)

y = tan(x)
x = -/2

.
x

x = /2

Figure 1: Graph of the tangent function, M = tan .

Lecture 35

18.01 Fall 2006

y = arctan(x)

y= /2

Figure 2: Graph of the arctangent function, = tan1 M . Example 3.


0

.
M x = tan(y)
y = -/2

ex dx =

/2

Recall that we already computed this improper integral (by computing a volume in two ways, slices and the method of shells). This shows vividly that a nite integral can be harder to understand than its innite counterpart: M 2 ex dx
0

can only evaluated numerically. It has no elementary formula. By contrast, we found an explicit formula when M = . Example 4.
1

dx/x
1 M

M dx/x = ln x = ln M ln 1 = ln M
1

as M . This improper integral is innite (called divergent or not convergent). Example 5.


1

dx/xp
M

(p > 1)

M dx/xp = (1/(1 p))x1p = (1/(1 p))(M 1p 1) 1/(p 1)


1

as M because 1 p < 0. Thus, this integral is convergent. Example 6.


1

dx/xp

(0 < p < 1)

This is very similar to the previous example, but diverges M M p 1p dx/x = (1/(1 p))x = (1/(1 p))(M 1p 1) 1
1

as M because 1 p > 0. 3

Lecture 35

18.01 Fall 2006

Determining Divergence and Convergence


To decide whether an integral converges or diverges, dont need to evaluate. Instead one can compare it to a simpler integral that can be evaluated. dx The General Story for powers: xp 1 From Examples 4, 5 and 6 we know that this diverges (is innite) for 0 < p 1 and converges (is nite) for p > 1. The comparison of integrals says that a larger function has a larger integral. If we restrict ourselves to nonnegative functions, then even when the region is unbounded, as in the case of an improper integral, the area under the graph of the larger function is more than the area under the graph of the smaller one. Consider 0 f (x) g (x) (as in Figure 3)
y

f(x)

g(x) x x =a

Figure 3: The area under f (x) is less than the area under g(x) for a x < . If
a

g (x) dx converges, then so does


a

f (x) dx. (In other words, if the area under g is nite,

then the area under f , being smaller, must also be nite.) If f (x) dx diverges, then so does g (x) dx. (In other words, if the area under f is innite,
a a

then the area under g , being larger, must also be innite.) The way comparison is used is by replacing functions by simpler ones whose integrals we can calculate. You will have to decide whether you want to trap the function from above or below. This will depend on whether you are demonstrating that the integral is nite or innite.

Lecture 35

18.01 Fall 2006

Example 7.
0

dx It is natural to try the comparison x3 + 1 1 1 3/2 3 x x +1

But the area under x3/2 on the interval 0 < x < , dx 3/2 x 0 turns out to be innite because of the innite behavior as x 0. We can rescue this comparison by excluding an interval near 0. 1 dx dx dx = + 3 3 x +1 x +1 x3 + 1 0 0 1 The integral on 0 < x < 1 is a nite integral and the second integral now works well with comparison, dx dx < 3 x3/2 x +1 1 1 because 3/2 > 1. Example 8.
0

ex dx
1 x3

For x 1, x3 x, so

dx
1

ex dx = 1 <
3

Thus the full integral from 0 x < of ex converges as well. We can ignore the interval 3 0 x 1 because it has nite length and ex does not tend to innity there. Limit comparison: Suppose that 0 f (x) and lim f (x)/g (x) 1. Then f (x) 2g (x) for x a (some large a). x Hence f (x) dx 2 g (x) dx.
a a

(x + 10) dx x2 + 1 0 The limiting behavior as x is Example 9. 1 (x + 10)dx x 2 = x2 + 1 x x Since


1

dx = , the integral x

(x + 10) dx also diverges. x2 + 1

Lecture 35

18.01 Fall 2006

Example 10 (from PS8).


0

xn ex dx

This converges. To carry out a convenient comparison requires some experience with growth rates of functions. xn << ex not enough. Instead use xn /ex/2 0 (true by LHop). It follows that xn << ex/2 = xn ex << ex/2 ex = ex/2 Now by limit comparison, since ex/2 dx converges, so does our integral. You will deal with this integral on the problem set.
0

Improper Integrals of the Second Type

0 1

dx x

1 We know that as x 0. x
0 1

dx = lim x a0+

x1/2 dx

1 x1/2 dx = 2x1/2 = 2 2a1/2


a

As a 0, 2a1/2 0. So,
0 1

x1/2 dx = 2

Similarly,
0 1

xp dx =

1 p + 1

for all p < 1. 1 For p = , 2

1 =2 1 +1 2

However, for p 1, the integral diverges.

Lecture 36

18.01 Fall 2006

Lecture 36: Innite Series and Convergence Tests

Innite Series
Geometric Series
A geometric series looks like 1 + a + a2 + a3 + ... = S Theres a trick to evaluate this: multiply both sides by a: a + a2 + a3 + ... = aS Subtracting, (1 + a + a2 + a3 + ) (a + a2 + a3 + ) = S aS In other words, 1 = S aS = 1 = (1 a)S = S = This only works when |a| < 1, i.e. 1 < a < 1. a = 1 cant work: 1 + 1 + 1 + ... = a = 1 cant work, either: 1 1 + 1 1 + ... = 1 1 = 2 1 (1) 1 1a

Notation
Here is some notation thats useful for dealing with series or sums. An innite sum is written:
k=0

ak = a0 + a1 + a2 + ...

The nite sum Sn =

n k=0

ak = a0 + ... + an

is called the nth partial sum of the innite series.

Lecture 36

18.01 Fall 2006

Denition
k=0

ak = s

means the same thing as


n

lim Sn = s, where Sn =

n k=0

ak

We say the series converges to s, if the limit exists and is nite. The importance of convergence is illustrated here by the example of the geometric series. If a = 1, S = 1 + 1 + 1 + ... = . But S aS = 1 or does not make sense and is not usable! =1

Another type of series:


1 p n n=1

We can use integrals to decide if this type of series converges. First, turn the sum into an integral: 1 dx p n xp 1 n=1 If that improper integral evaluates to a nite number, the series converges. Note : This approach only tells us whether or not a series converges. It does not tell us what number the series converges to. That is a much harder problem. For example, it takes a lot of work to determine 1 2 = n2 6 n=1 Mathematicians have only recently been able to determine that
1 3 n n=1

converges to an irrational number! Harmonic Series 1 dx n x 1 n=1 We can evaluate the improper integral via Riemann sums. Well use the upper Riemann sum (see Figure 1) to get an upper bound on the value of the integral.

Lecture 36

18.01 Fall 2006

y=x 1

1 2 3

Figure 1: Upper Riemann Sum.

dx 1 1 1 + + ... + = sN 1 sN x 2 N 1
N

We know that

As N , ln N , so sN

dx = ln N x 1 as well. In other words,


1 n n=1

diverges. Actually, sN approaches rather slowly. Lets take the lower Riemann sum (see Figure 2).

y=x

1 2

3 4

Figure 2: Lower Riemann Sum. sN = 1 + Therefore, ln N < sN < 1 + ln N 3 N N 1 dx 1 1 1+ = 1 + ln N + ... + =1+ n x 2 N 1 n=2

Lecture 36

18.01 Fall 2006

Integral Comparison
Consider a positive, decreasing function f (x) > 0. (For example, f (x) = f (n) f (x)dx < f (1) 1
n=1

1 ) xp

So, either both of the terms converge, or they both diverge. This is what we mean when we say 1 dx p n xp 1 n=1 Therefore,
1 diverges for p 1 and converges for p > 1. p n n=1

Lots of fudge room: in comparison. 1 2 n + 10 n=1 diverges, because 1 1 1 2 1/2 = 2 n (n ) n + 10 Limit comparison : If f (x) g (x) as x , then f (n) and g (n) either both converge or both diverge. What, exactly, does f (x) g (x) mean? It means that lim f (x) =c g (x)

where 0 < c < . Lets check: does the following series converge? n 5 n 10 n=1 n n 1 5/2 = n3/2 = 3/2 5 n n n 10 Since 3 > 1, this series does converge. 2

Lecture 36

18.01 Fall 2006

Playing with blocks


At this point in the lecture, the professor brings out several long, identical building blocks. Do you think its possible to stack the blocks like this?

Top block is farther out than the bottom block.

Figure 3: Collective center of mass of upper blocks is always over the base block. In order for this to work, you want the collective center of mass of the upper blocks always to be over the base block. The professor successfully builds the stack. Is it possible to extend this stack clear across the room? The best strategy is to build from the top block down. Let C0 be the left end of the rst (top) block. Let C1 = the center of mass of the rst block (top block). Put the second block as far to the right as possible, namely, so that its left end is at C1 (Figure 4). Let C2 = the center of mass of the top two blocks. Strategy : put the left end of the next block underneath the center of mass of all the previous ones combined. (See Figure 5).

Lecture 36

18.01 Fall 2006

1/2

C0

C1

C2

Figure 4: Stack of 2 Blocks.


2

1 2 3
1 1/2 1/3

C0

C1

C2 C3

Figure 5: Stack of 3 Blocks. Left end of block 3 is C2 = center of mass of blocks 1 and 2.

C0 = 0 C1 = 1 C2 = 1 + 1 2

Cn+1 =

nCn + 1(Cn + 1) (n + 1)Cn + 1 1 = = Cn + n+1 n+1 n+1 1 1 C3 = 1 + + 2 3 1 1 1 C4 = 1 + + + 2 3 4 1 1 1 1 C5 = 1 + + + + > 2 2 3 4 5 6

Lecture 36

18.01 Fall 2006

}
center of mass of the rst n blocks

n
n+1 block

Figure 6: Stack of n + 1 Blocks. So yes, you can extend this stack as far (horizontally) as you want provided that you have enough blocks. Another way of looking at this problem is to say
N 1 = SN n n=1

Recall the Riemann Sum estimation from the beginning of this lecture: ln N < SN < (ln N ) + 1 as N , SN . How high would this stack of blocks be if we extended it across the two lab tables here at the front of the lecture hall? The blocks are 30 cm by 3 cm (see Figure 7). One lab table is 6.5 blocks, or 13 units, long. Two tables are 26 units long. There will be 26 2 = 24 units of overhang in the stack.

3 cm 30 cm

Figure 7: Side view of one block. If ln N = 24, then N = e24 . Height = 3 cm e24 8 108 m That height is roughly twice the distance to the moon. If you want the stack to span this room ( 30 ft.), it would have to be 1026 meters high. Thats about the diameter of the observable universe. 7

Lecture 37

18.01 Fall 2006

Lecture 37: Taylor Series

General Power Series


What is cos x anyway? Recall: geometric series 1 + a + a2 + = General power series is an innite sum: f (x) = a0 + a1 x + a2 x2 + a3 x3 + represents f when |x| < R where R = radius of convergence. This means that for |x| < R, |an xn | 0 as n (geometrically). On the other hand, if |x| > R, then |an xn | does not tend to 0. For 1 1 example, in the case of the geometric series, if |a| = , then |an | = n . Since the higher-order terms 2 2 get increasingly small if |a| < 1, the tail of the series is negligible. Example 1. If a = 1, |an | = 1 does not tend to 0. 1 1 + 1 1 + The sum bounces back and forth between 0 and 1. Therefore it does not approach 0. Outside the interval 1 < a < 1, the series diverges. 1 1a for | a |< 1

Basic Tools
Rules of polynomials apply to series within the radius of convergence. Substitution/Algebra 1 = 1 + x + x2 + 1x

Example 2. x = -u. 1 = 1 u + u2 u3 + 1+u

Example 3. x = v 2 . 1 = 1 v2 + v4 v6 + 1 + v2

Lecture 37

18.01 Fall 2006

Example 4. 1 1x 1 1x = (1 + x + x2 + )(1 + x + x2 + )

Term-by-term multiplication gives: 1 + 2x + 3x2 + 1 Remember, here x is some number like . As you take higher and higher powers of x, the result 2 gets smaller and smaller. Dierentiation (term by term) d 1 d = 1 + x + x2 + x3 + dx 1 x dx 1 = 0 + 1 + 2x + 3x2 + (1 x)2 where 1 is a0 , 2 is a1 and 3 is a2

Same answer as Example 4, but using a new method. Integration (term by term) where f (x) = a0 + a1 x + a2 x2 + a1 a2 f (x) dx = c + a0 + x2 + x3 + 2 3

Example 5.

du 1+u 1 = 1 u + u2 u3 + 1+u

du u2 u3 u4 =c+u + + 1+u 2 3 4 x du x2 x3 x4 ln(1 + x) = =x + + 3 4 2 0 1+u So now we know the series expansion of ln(1 + x).

Example 6. Integrate Example 3. 1 = 1 v2 + v4 v6 + 1 + v2 dv v3 v5 v7 =c+ v + + 1 + v2 3 5 7 x dv x3 x5 x7 tan1 x = =x + + 2 5 7 3 0 1+v

Lecture 37

18.01 Fall 2006

Taylors Series and Taylors Formula


If f (x) = a0 + a1 x + a2 x2 + , we want to gure out what all these coecients are. Dierentiating, f (x) = a1 + 2a2 x + 3a3 x2 + f (x) = (2)(1)a2 + (3)(2)a3 x + (4)(3)a4 x2 + f (x) = (3)(2)(1)a3 + (4)(3)(2)a4 x + Lets plug in x = 0 to all of these equations. f (0) = a0 ; f (0) = a1 ; f (0) = 2a2 ; f (0) = (3!)a3 Taylors Formula tells us what the coecients are: f (n) (0) = (n!)an Remember, n! = n(n 1)(n 2) (2)(1) and 0! = 1. Coecients an are given by: an = 1 n! f (n) (0)

Example 7. f (x) = ex . f (x) = ex f (x) = ex f (n) (x) = ex f (n) (0) = e0 = 1 Therefore, by Taylors Formula an = ex = Or in compact form, ex = Now, we can calculate e to any accuracy: e=1+1+ 1 1 1 1 + + + + 2 3! 4! 5!
xn n! n=0

1 and n! 1 1 1 1 + x + x2 + x3 + 0! 1! 2! 3!

Example 7. f (x) = cos x. f (x) = sin x f (x) = cos x 3

Lecture 37

18.01 Fall 2006

f (x) = sin x f (4) (x) = cos x f (0) = cos(0) = 1 f (0) = sin(0) = 0 f (0) = cos(0) = 1 f (0) = sin(0) = 0 Only even coecients are non-zero, and their signs alternate. Therefore, 1 1 1 1 cos x = 1 x2 + x4 x6 + x8 + 2 4! 8! 6! Note: cos(x) is an even function. So is this power series as it contains only even powers of x. There are two ways of nding the Taylor Series for sin x. Take derivative of cos x, or use Taylors formula. We will take the derivative: d 1 4 6 8 sin x = cos x = 0 2 x + x3 x5 + x7 + dx 2 4! 6! 8! = x + sin(x) = x x3 x5 x7 + + 3! 5! 7!

x3 x5 x7 + + 3! 5! 7!

Compare with quadratic approximation from earlier in the term: 1 cos x 1 x2 2 We can also write: cos x =
x2k x0 x2 1 (1)k = (1)0 + (1)2 + = 1 x2 + (2k )! 0! 2! 2 x2k+1 (1)k n = 2k + 1 (2k + 1)!

sin x x

k=0

sin x =

k=0

Example 8: Binomial Expansion. f (x) = (1 + x)a a a(a 1) 2 a(a 1)(a 2) 3 (1 + x)a = 1 + x + x + x + 1 2! 3!

Lecture 37

18.01 Fall 2006

Taylor Series with Another Base Point


A Taylor series with its base point at a (instead of at 0) looks like: f (3) (b) f (b) (x b)2 + (x b)3 + ... 2 3! Taylor series for x. Its a bad idea to expand using b = 0 because x is not dierentiable at x = 0. Instead use b = 1. 1 1 1 1 2 2 x1/2 = 1 + (x 1) + (x 1)2 + 2 2! f (x) = f (b) + f (b)(x b) +

Lecture 38

18.01 Fall 2006

Lecture 38: Final Review


Review: Dierentiating and Integrating Series.
If f (x) =
n=0 n=1

an xn , then and f (x)dx = C +


an xn+1 n+1 n=0

f (x) =

nan x

n1

Example 1: Normal (or Gaussian) Distribution. x x 2 (t2 )2 (t2 )3 et dt = 1 t2 + + + dt 2! 3! 0 0 x t4 t6 t8 2 = 1 t + + ... dt 2! 3! 4! 0 =x Even though
0 x
2

x3 1 x5 1 x7 + + ... 3 2! 5 3! 7

et dt isnt an elementary function, we can still compute it. Elementary functions

are still a little bit better, though. For example: sin x = x x3 x5 (/2)3 (/2)5 + = sin = + 3! 5! 2 2 3! 5!

But to compute sin(/2) numerically is a waste of time. We know that the sum if something very simple, namely, sin = 1 2 Its not obvious from the series expansion that sin x deals with angles. Series are sometimes complicated and unintuitive. Nevertheless, we can read this formula backwards to nd a formula for . Start with sin = 1. 2 2 Then, 1 1 dx = sin1 x = sin1 1 sin1 0 = 0 = 2 2 2 0 1x 0 We want to nd the series expansion for (1 x2 )1/2 , but lets tackle a simpler case rst: 1 1 1 1 1 1 2 1 1 2 2 2 2 2 (1 + u)1/2 = 1 + u+ u2 + u3 + 12 123 2 1 13 2 135 3 =1 u+ u u + 24 2 246 Notice the pattern: odd numbers go on the top, even numbers go on the bottom, and the signs alternate. 1

Lecture 38

18.01 Fall 2006

Now, let u = x2 . 1 13 4 135 6 x + x + (1 x2 )1/2 = 1 + x2 + 2 24 246 1 x3 1 3 x5 1 3 5 x7 2 1/2 (1 x ) dx = C + x + + + + 2 3 24 5 246 7 1 1 1 13 1 135 1 = (1 x2 )1/2 dx = 1 + + + + 2 2 3 24 5 246 7 0 Heres a hard (optional) extra credit problem: why does this series converge? LHpitals rule to nd out how quickly the terms decrease. Hint: use

The Final Exam


Heres another attempt to clarify the concept of weighted averages.

Weighted Average
A weighted average of some function, f , is dened as: b Average(f ) = Here,
a b a

w(x)f (x) dx b w(x) dx a

w(x) dx is the total, and w(x) is the weighting function.

Example: taken from a past problem set. You get $t if a certain particle decays in t seconds. How much should you pay to play? You were given that the likelihood that the particle has not decayed (the weighting function) is: w(x) = ekt Remember,
0

ekt dt =

1 k

The payo is f (t) = t The expected (or average) payo is kt f (t)w(t) dt te dt 0 = 0 kt w(t) dt e dt 0 0 =k
0

tekt dt =

(kt)ekt dt

Do the change of variable: u = kt and du = k dt

Lecture 38

18.01 Fall 2006

Average =
0

ueu

du k

On a previous problem set, you evaluated this using integration by parts:


0

ueu du = 1.

Average =
0

ueu

du 1 = k k

On the problem set, we calculated the half-life (H ) for Polonium120 was (131)(24)(60)2 seconds. We also found that ln 2 k= H Therefore, the expected payo is 1 H = k ln 2 where H is the half-life of the particle in seconds. Now, youre all probably wondering: who on earth bets on particle decays? In truth, no one does. There is, however, a very similar problem that is useful in the real world. There is something called an annuity, which is basically a retirement pension. You can buy an annuity, and then get paid a certain amount every month once you retire. Once you die, the annuity payments stop. You (and the people paying you) naturally care about how much money you can expect to get over the course of your retirement. In this case, f (t) = t represents how much money you end up with, and w(t) = ekt represents how likely your are to be alive after t years. What if you want a 2-life annuity? Then, you need multiple integrals, which you will learn about in multivariable calculus (18.02). Our rst goal in this class was to be able to dierentiate anything. In multivariable calculus, you will learn about another chain rule. That chain rule will unify the (single-variable) chain rule, the product rule, the quotient rule, and implicit dierentiation. You might say the multivariable chain rule is One One One And thing to rule them all thing to nd them thing to bring them all in a matrix bind them.

(with apologies to JRR Tolkien).

You might also like