Excursions in Computing Science: Week v Milli-micro-nano-..math Part II

Similar documents
Time (hours) Morphine sulfate (mg)

Lab 6 Derivatives and Mutant Bacteria

2011 Fermat Contest (Grade 11)

1 Limits and Continuity

7.1 Using Antiderivatives to find Area

2.8 The Derivative as a Function

Material for Difference Quotient

Exam 1 Review Solutions

Section 3: The Derivative Definition of the Derivative

MAT 145. Type of Calculator Used TI-89 Titanium 100 points Score 100 possible points

Preface. Here are a couple of warnings to my students who may be here to get a copy of what happened on a day that you missed.

SECTION 3.2: DERIVATIVE FUNCTIONS and DIFFERENTIABILITY

Polynomials 3: Powers of x 0 + h

Average Rate of Change

3.4 Worksheet: Proof of the Chain Rule NAME

Math 102 TEST CHAPTERS 3 & 4 Solutions & Comments Fall 2006

The derivative function

Differential Calculus (The basics) Prepared by Mr. C. Hull

Week #15 - Word Problems & Differential Equations Section 8.2

HOMEWORK HELP 2 FOR MATH 151

1 The concept of limits (p.217 p.229, p.242 p.249, p.255 p.256) 1.1 Limits Consider the function determined by the formula 3. x since at this point

How to Find the Derivative of a Function: Calculus 1

1watt=1W=1kg m 2 /s 3

Combining functions: algebraic methods

REVIEW LAB ANSWER KEY

Pre-Calculus Review Preemptive Strike

1 Calculus. 1.1 Gradients and the Derivative. Q f(x+h) f(x)

Introduction to Derivatives

2.11 That s So Derivative

4. The slope of the line 2x 7y = 8 is (a) 2/7 (b) 7/2 (c) 2 (d) 2/7 (e) None of these.

INTRODUCTION AND MATHEMATICAL CONCEPTS

Lines, Conics, Tangents, Limits and the Derivative

Cubic Functions: Local Analysis

Continuity and Differentiability Worksheet

Sin, Cos and All That

THE IDEA OF DIFFERENTIABILITY FOR FUNCTIONS OF SEVERAL VARIABLES Math 225

NUMERICAL DIFFERENTIATION. James T. Smith San Francisco State University. In calculus classes, you compute derivatives algebraically: for example,

Consider a function f we ll specify which assumptions we need to make about it in a minute. Let us reformulate the integral. 1 f(x) dx.

f a h f a h h lim lim

2.1 THE DEFINITION OF DERIVATIVE

Bob Brown Math 251 Calculus 1 Chapter 3, Section 1 Completed 1 CCBC Dundalk

Higher Derivatives. Differentiable Functions

INTRODUCTION AND MATHEMATICAL CONCEPTS

Section 2: The Derivative Definition of the Derivative

WYSE Academic Challenge 2004 Sectional Mathematics Solution Set

SECTION 1.10: DIFFERENCE QUOTIENTS LEARNING OBJECTIVES

Calculus I Homework: The Derivative as a Function Page 1

1 Solutions to the in class part

1. Questions (a) through (e) refer to the graph of the function f given below. (A) 0 (B) 1 (C) 2 (D) 4 (E) does not exist

3.1 Extreme Values of a Function

232 Calculus and Structures

A = h w (1) Error Analysis Physics 141

2.3 More Differentiation Patterns

MATH 1020 Answer Key TEST 2 VERSION B Fall Printed Name: Section #: Instructor:

0.1 Differentiation Rules

Chapter 2 Limits and Continuity

CHAPTER 3: Derivatives

MVT and Rolle s Theorem

Derivatives. By: OpenStaxCollege

, meant to remind us of the definition of f (x) as the limit of difference quotients: = lim

LIMITS AND DERIVATIVES CONDITIONS FOR THE EXISTENCE OF A LIMIT

. If lim. x 2 x 1. f(x+h) f(x)

Practice Problem Solutions: Exam 1

Printed Name: Section #: Instructor:

Function Composition and Chain Rules

Name: Answer Key No calculators. Show your work! 1. (21 points) All answers should either be,, a (finite) real number, or DNE ( does not exist ).

Chapter 2. Limits and Continuity 16( ) 16( 9) = = 001. Section 2.1 Rates of Change and Limits (pp ) Quick Review 2.1

1. AB Calculus Introduction

MA119-A Applied Calculus for Business Fall Homework 4 Solutions Due 9/29/ :30AM

Exercises for numerical differentiation. Øyvind Ryan

5.1 We will begin this section with the definition of a rational expression. We

Math 34A Practice Final Solutions Fall 2007

MATH 1020 TEST 2 VERSION A FALL 2014 ANSWER KEY. Printed Name: Section #: Instructor:

The Derivative The rate of change

Mathematics 105 Calculus I. Exam 1. February 13, Solution Guide

Lecture XVII. Abstract We introduce the concept of directional derivative of a scalar function and discuss its relation with the gradient operator.

1 + t5 dt with respect to x. du = 2. dg du = f(u). du dx. dg dx = dg. du du. dg du. dx = 4x3. - page 1 -

Chapter 1D - Rational Expressions

Math 1241 Calculus Test 1

lim 1 lim 4 Precalculus Notes: Unit 10 Concepts of Calculus

1. Consider the trigonometric function f(t) whose graph is shown below. Write down a possible formula for f(t).

Click here to see an animation of the derivative

Printed Name: Section #: Instructor:

KEY CONCEPT: THE DERIVATIVE

2.3 Product and Quotient Rules

The Krewe of Caesar Problem. David Gurney. Southeastern Louisiana University. SLU 10541, 500 Western Avenue. Hammond, LA

Calculus I Practice Exam 1A

3.4 Algebraic Limits. Ex 1) lim. Ex 2)

Chapter 4: Numerical Methods for Common Mathematical Problems

11-19 PROGRESSION. A level Mathematics. Pure Mathematics

Exponentials and Logarithms Review Part 2: Exponentials

Recall from our discussion of continuity in lecture a function is continuous at a point x = a if and only if

b 1 A = bh h r V = pr

Copyright c 2008 Kevin Long

Some Review Problems for First Midterm Mathematics 1300, Calculus 1

158 Calculus and Structures

1 2 x Solution. The function f x is only defined when x 0, so we will assume that x 0 for the remainder of the solution. f x. f x h f x.

MATH1131/1141 Calculus Test S1 v8a

Lecture 15. Interpolation II. 2 Piecewise polynomial interpolation Hermite splines

Precalculus Test 2 Practice Questions Page 1. Note: You can expect other types of questions on the test than the ones presented here!

Transcription:

Excursions in Computing Science: Week v Milli-micro-nano-..mat Part II T. H. Merrett McGill University, Montreal, Canada June, 5 I. Prefatory Notes. Cube root of 8. Almost every calculator as a square-root button,. But ow would we calculate a cube root? Let s start wit one we know: 8 =. We are going to find tis by finding te zeros of a function. For tis case = f(x) = x 8 will do it: if we can find te value of x wic makes tis f(x) zero, we will know 8. Here is a plot of tis function. Cubic f(x) = x 8 4 x Copyleft c T. H. Merrett,,, 5. Permission to make digital or ard copies of part or all of tis work for personal or classroom use is granted witout fee provided tat copies are not made or distributed for profit or commercial advantage and tat copies bear tis notice and full citation in a prominent place. Copyrigt for components of tis work owned by oters tan T. H. Merrett must be onoured. Abstracting wit credit is permitted. To copy oterwise, to republis, to post on servers, or to redistribute to lists, requires prior specific permission and/or fee. Request permission to republis from: T. H. Merrett, Scool of Computer Science, McGill University, fax 54 98 88.

Note tat te line crosses te orizontal (x) axis at x =, wic we know to be te cube root of 8.. Slope. Now we introduce te idea of a slope. Loosely speaking, te slope of a function f(x) at a specific value of x is te tangent to te function curve at tat point. To be precise, we define te slope to be a number: te eigt divided by te base of te triangle generated by tat tangent. In te figure slope x=x f(x) def = f(x ) base 6 Root of f(x) 5 4 f(x) f(x ) x base.5.5.5 4 x x. Approximations. Now we are going to start making approximations. Tese will be true enoug wen tings get close enoug togeter, so in te end we will ave exact results. (We ll use te symbol to mean approximately equals. If we use it in a cain of equalities, te last expression in te cain will not exactly equal te first expression even toug tere may be many = signs and only one sign but will only approximately equal it.) In te above figure, we don t know wat te base is, so we ll approximate it by x x. We don t know wat x is, eiter, but we want to find it: it is te unknown place were f(x ) =. So we ll use it to stand for wat we don t yet know and do some algebra until we can eventually pin it down. Now we can write te slope down approximately. slope x=x f(x) = f(x ) base f(x ) x x So we can rearrange tis to write down x, our quarry, approximately. x x f(x ) slope x=x f(x) Since we know f(x) = x 8 we can calculate f(x ) for any given x. We must now figure out ow to calculate slope x=x f(x).

4. Slope of cubic. Here is f(x) = x 8 again, wit all te pieces needed to find its slope at x lo. 6 Slope of x 8 5 4 f(x i ) f(x) = x 8 f(x lo ) x lo x i x.5.5.5.5.5 4 x Te definition of slope tells us, if x lo and x i are close enoug togeter, So let s try it for f(x) = x 8. Tat is, slope x a = x for any a. slope x=xlo f(x) = f(x i) f(x lo ) = f(x lo + x) f(x lo ) x i x lo x slope x=xlo x 8 = (x lo + x) (x lo ) x = (x lo) x + x lo ( x) + ( x) x (x lo) x x = (x lo ) Te in te above cain olds more and more exactly te smaller x gets, i.e., te closer x i and x lo get togeter. But tis is wat we intend to appen in calling te result te slope at te specified value. Wat we really do is take te limit as te two points get closer and closer togeter. Tis justifies using te exact = in saying above slope x a = x. 5. Te root. So now we can go back to Note were we ad and replace it for f(x) = x 8 by x x f(x ) slope x=x f(x) x x (x ) 8 (x ) Let s try it. We ll need a value for x. We ll just guess. We know for tis case tat te final cube root will be, but it is a special case we cose to make it easy to ceck te answer. Usually we

can only guess te value of te final cube root, maybe from plotting te function. So we ll pretend we don t know and try x = as a guess. x = x (x ) 8 (x ) =.9444 Tis is pretty close to, but let s try te result as te next guess (call it x ). Better. Try again. Keep trying. x = x (x ) 8 (x ) =. x 4 = x (x ) 8 (x ) =.9856 x 5 = x 4 (x 4) 8 (x 4 ) =.74 x 6 = x 5 (x 5) 8 (x 5 ) =.9964 x 7 = x 6 (x 6) 8 (x 6 ) =.8 x 8 = x 7 (x 7) 8 (x 7 ) =.999 x 9 = x 8 (x 8) 8 (x 8 ) =.5 x = x 9 (x 9) 8 (x 9 ) =.9998 : How many more steps before te result is.?.? So we see x n x in te limit as n gets arbitrarily large. 6. Square roots. Tis process works for square roots, too. In fact, it is te basis for te button on your calculator, and for te sqrt function in any programming language. We just need to work out tat slope(x a) = x. Now try finding te square root of 4. x x (x ) 4 (x ) 7. Antislopes. Now we know about slopes we migt wonder about going te oter way. Just as division undoes multiplication, antislopes undo slopes. Here are some examples. slope x f f(x) antislope x f x + C x x / + C x x x / + C x x x 4 /4 + C 4x x 4 x 5 /5 + C : : : We saw tat division goes wit finding slopes and we ll see tat multiplication goes wit finding antislopes, so it would be more appropriate to reverse tis prase and say Just as multiplication undoes division, antislopes undo slopes. 4

were C in eac case is some constant, tat is, some number or expression wic does not depend on x. Ceck tese examples by finding te slopes of te antislope x f column. Ten see if you can figure out te antislopes of te slopes x f column. 8. Areas. In addition to slopes, te oter major use of arbitrarily srinking interval, x, is to find areas. Let s find te area of an equilateral triangle. (, ) (,) (,) You probably know tat te area of a triangle is b/ were b is te base and is te eigt. For te triangle of te figure, b = and = /4 so area = 4 Let s see if we can work out wy tis is te answer. We ll redraw te triangle rotated so tat its eigt is orizontal. (, ) (,) (, ) Now slice it into vertical strips of widt, and make tem rectangles just toucing te sides of te triangle at two of te four corners of eac rectangle. 5

y y j Te area of te triangle will be area ( /)/ j= y j were we must figure out wat eac y j is. (Do you see wy te number of steps of widt is ( /)/?) I used te approximation sign,, because of te missing bits of area between te steps and te sides of te triangle. Te important ting about tis approximation is tat it gets better and better te smaller is: tis is were te milli-micro-nano aspect of tis Week comes in. Let s tink of y as a function of y() = s were s is te slope of te upper side of te triangle. We can see s = / / = and we can ceck So between and we ave y() = y( ) = = j = j j = and j = / y j = y( j ) = j = j So area = ( /)/ j= ( /)/ j= y( j ) j 6

= ( /)/ ( ) j j= = ( ) ( /)/ )(( /)/ ) = / ( ) ( ( ) ( = 4 = 4 / ) / ) wic is te same result as te b/ calculation at te beginning of tis Note. Notice tat I made two approximations, wic appened, tis time, to cancel eac oter out. Te second approximation was tat / is big enoug tat / essentially equals /. Tis approximation also gets better and better as gets arbitrarily small: more milli-micro-nano-.. mat. Note also tat te sum,, disappears in te fourt line above and is replaced by n(n )/ (letting n be / ): te sum is just a triangular number (Week i Note ). (Please do not confuse te in (tis Note) wit te in n etc. (Week i Notes). Here modifies te variable following it to mean a little bit of. Tere te means triangle and as a subscript n to say ow big te triangle is.) To summarize tis procedure a little differently, we summed te base, b, as a function of te eigt, b() = over a discrete set of values, j, separated by steps of size from to /.. base.8 b()=/.6.4......4.5.6.7.8 /.9 7

We can use b = / to generalize te area from te eigt = / triangle to a triangle wit any eigt : area = b =.6 area.5 /4.4 a()= /.........4.5.6.7.8 /.9 9. Volumes. We can use te same tecnique to find te volume of a regular tetraedron. Tis as all six edges of te same lengt, say, and eigt / in te tird dimension. (Eac of te four faces is an equilateral triangle of sides and eigt on te face we won t call tis te eigt any more / as in te previous Note.) We ll turn te tetraedron sideways, so its -D eigt is sown orizontally, and slice it into triangular slabs of tickness and sizes from at te apex to sides= at te base. So te sum we need tis time is area = vol = j j j j vol // j= j 8

wit j = j as before, and wit te same reasons for noting tat tis is an approximation (wic will improve as gets small). // vol j ( ) j= = ( ) = ( ) ( = 7 // j= / ( / ) j / / )( ) In te second line I summed j from to n = wic we can work out from Week i Note as n(n )(n ). I approximated tis by n /, once again an approximation wic improves as gets small, and an approximation wic appens to counteract te first approximation above exactly, giving te exact rigt answer.. Antislopes and areas. In Notes 8 and 9 we found te areas under te following two functions...6.8.5 /4.4 b()=/.6.4 / a()= /.. /.......4.5.6.7.8 /.9......4.5.6.7.8 /.9 Let s just find te antislopes of tese functions (Note.7). antislope = antislope = + C antislope = antislope = + C were te constants C and C can be any numbers not depending on. Let s evaluate te first at = / and at = and subtract. / antislope = / = 4 = 4 and te second at = / and at = and subtract. / antislope = / = 7 = 7 9

Wat is te connection wit te triangular area in Note 8 and te tetraedral volume in Note 9? It turns out tat antislopes give areas wen suitably evaluated.. Te Fundamental Teorem of Calculus. Areas between two points under a function are linked to te antislope of te function, i.e., to te function wose slope is tat function. Let s see wy. Here is a function f(x) and a small section of f(x) x of te area under f(x). f ( x) x x x + x We can call te area A(x,x), supposing tat we are in te process of finding te area under f(x) starting at x, and tat we ave so far reaced x. If x is fixed, we are interested only in te area as a function of x and we can write, simply, A(x). Ten for te small increment, A(x), of te area. A(x) = f(x) x Tis is very familiar: just rearrange f(x) = A(x) x and we ave tat f(x) is te slope of A(x). So A(x) is te antislope of f(x). And if we want to find te area from say x to say x,we just evaluate We can write tis or A(x ) A(x ) A(x) x x antislope x f(x) x x Since tese definite integrals are te same antislope evaluated at two different places and subtracted, te arbitrary constant tat we introduced wit antislopes in Note 7 disappears and we can forget about it.. Summary (Tese notes sow te trees. Try to see te forest!) Te reason I called tese Notes Milli-micro-nano-..mats is because of te approximations. To make slopes exact we must apply te definition to ever smaller intervals. Te metod I ave presented to find cube and square roots is Newton s metod. It is an application of differential calculus, also invented by Isaac Newton, and independently by Gottfried

Leibniz wose notation is now used, altoug I ave not used it. Newton s metod works for finding roots (zeros) of almost any function and it converges very quickly. II. Te Excursions You ve seen lots of ideas. Now do someting wit tem!. Trowing balls: parabola and square roots. (Tis Excursion is meant to elp if you found tis topic toug going rigt from te start. It is about functions and teir roots ( zeros ).) Eric is trowing a ball for Iris to catc. Here is ow te ball goes. ballparabola 8 y = x + 6 4 4 4 x E x x I Te ball leaves Eric s and meters from te ground, rises to a maximum eigt of meters, ten drops to meter were Iris catces it. Gravity causes te ball to follow a parabola in between Eric and Iris. A parabola is an example of a function, wic gives a unique value for y (wic is wat I ve called te eigt in te grap) for eac possible value of x (wic is wat I call te orizontal position of te ball). Te relationsip between x and y is given by te equation y = x + Tat is te simplest equation to describe te particular pat I ve plotted. To make it tis simple, I cose te axes so tat te maximum eigt is attained wen x =. I also cose te orizontal scale so tat te ball is moving from somewere around x = to somewere around x =. We ll see were exactly tese endpoints are. In fact, tat is te purpose of tis Excursion. Let s make a table sowing some of te values for y tat te rule y = x + calculates for different values of x. Te table spells tis out in te second column. (We ll come to te meanings of te tird and fourt columns sortly.) x x + = y y y 9 + = 4 + = 6 4 + = 9 7 + = 8 + = 9 7 4 + = 6 4 9 + =

Ceck tese calculations. Wat do you notice about te value of y for positive and negative values of x? Now, were must Iris be to catc te ball meter off te ground? Te table says te ball is meter off te ground at x = and at x =. Since I ve sown Iris on te x-positive side, we conclude tat Iris is at x I =. Te two possible positions, from wic we ve cosen te positive one, also correspond to y =, wic I ve marked wit in te y column. Finding out were Eric must stand to trow te ball is trickier. We don t see any zeros in te y column. But we do see some negative numbers and some positive numbers in tat column. y =, or y =, must occur: a) between x =, were y =, and x =, were y = 4 and it plainly must be somewat closer to x = tan to x = ; or b) between x =, were y = 4, and x =, were y = and it plainly must be somewat closer to x = tan to x =. Let s do some algebra. = y = x + = x + 8 and ere is te grap of tis y = x + 8. (I could ave given y a new name, say y or z, but wy burden ourselves wit additional symbols?) rootparabola 8 (,8) (,7) (,7) 6 y = x + 8 4 (,4) (,4) (, ) (, ) 4 4 x E x x I We see it is anoter parabola, tis time one wic crosses te x-axis at te zeros of y, i.e., were y =, or y =, wic is just te eigt of te ball as it leaves Eric s and. Tese zeros are te roots of te parabola. (I ve also sown te pairs (x,y) for te seven values of x tat are in te table. Clearly tese are only some of te possible pairs. How many could tere be?) To find were Eric is, we need te roots of tis second parabola. We must do some more algebra. Continuing from before = x + 8 x = 8 x = 8 =.88

Tus Eric is at x E = 8 =.88. In te last line, I used te square root button on my calculator to find te number. Ceck tis and try it on your own calculator. But wy ave I used te minus sign? Does it satisfy te requirement (b) above? Wat about requirement (a)? Wy does a square root almost always ave two possible values? How do tey relate to one anoter? Wat square root as only one value?. Write a program, say cubert(a), wic finds te cube root of a correctly to some number of decimal places wic you can fix inside te program or else control by a second parameter, say decpl, for any number, a.. a) Sow tat slope x n = nx n for any positive integer n. Hint: use te binomial coefficients of Week ii Note 6 in a way similar to te way tey are used to expand ( + x) n in Week ii Note 7. b) Sow tat slope x n = nx n for any rational number n. 4. Pytagoras. In te next tree excursions we are going to sow tat te eigt of an equilateral triangle of base b is indeed ( /)b (i.e., / wen b = as in te example of Note 8). For tis, we need to know Pytagoras teorem tat for a rigt-angled triangle of sides a,b and c (were c is te long side, te ypotenuse) Sow tis using te following diagram c = a + b b c a 5. Using Pytagoras and te following diagram, sow tat te eigt of an equilateral triangle of base b = is /. Wy is te eigt ( /)b for any base b? 6. Anoter way to find te eigt of an equilateral triangle is to start wit its base, say of lengt

(,) (,) and find te point (x,y) wic is a distance from bot (,) and (,). ( x, y) (,) (,) a) Sow tat Pytagoras says te distance between two points (x,y) and (x,y ) is b) Hence sow tat te two equations (x x ) + (y y ) x + y = (x ) + y = must be solved. c) Finally, use tis to sow tat x = / and y = / 7. Te sum of j, n j= j were n = in Note 9, could be approximated as j(j + ) for large n (small ). Tis is te sum of triangular numbers in Week i Note, and produces te nt tetraedral number. Sow tat it gives te same answer as te volume calculation in Note 9. 8. Pytagoras can sow tat te eigt of unit-sided tetraedron is / as said in Note 9. Here is te geometrical approac. Te fourt point, or apex, of te tetraedron will lie directly above te center of te equilateral triangle tat is its base (wy?) a) Tis can be found by bisecting te angle at eac corner and noting were te bisectors meet. By symmetry, all tree bisectors meet at te same point, and eac is perpendicular to te edge of te triangle opposite to te angle it bisects. 4

x Use te slope of te bisector (it s te same as te slope of te edge of te rotated triangle in Note 8) and Pytagoras to sow tat its lengt from x = to x = is /. Since te vertical bisector cuts tis bisector in alf, sow tat te common point were all bisectors meet is / from eac vetex and /( ) from eac opposite edge. b) Now rise straigt up in te tird dimension from tis common point to te apex of te tetraedron, and note were it meets te -D eigt of te triangular face sown and use Pytagoras to sow tat te -D eigt is /. 9. Te algebraic approac finds te eigt of te tetraedron muc more quickly tan te geometrical approac of te last excursion. ( x, y, z ) (,, ) (,,) (,,) Requiring te apex, (x,y,z), to be unit distance from te tree corners (,,), (,,) and (/, /, ) of te base means x + y + z = 5

Sow (x,y,z) = ±(,, ) (x ) + y + z = (x ) + (y ) + z =. Go on from te previous excursion to find te eigt in te 4t dimension of te 4-D regular simplex wit tetraedral base (,,,),(,,,),(,,,) and (,,. Any part of te Preliminary Notes tat needs working troug.,) 6