Math 135 diary, second part, spring 2005


Tuesday, March 8: this is lecture 15

Chipping Sparrow
Spizella passerina
Spring?
Certainly, in spite of the horrible recent weather, spring is bound to arrive, soon, very soon. As evidence I present the fact that a Chipping Sparrow, Spizella passerina, was observed this morning at my bird feeder. This bird is normally a midspring/summer/midfall resident in New Jersey, and I haven't seen one in my backyard for months. Things are looking good (if the little feathered object can survive the miserable temperatures of the next few days!). The pictures here are not mine. They have been borrowed from places on the web.

Cook College students are supposed to admire all furry and feathered creatures. This includes math faculty members. On the other hand, Douglass College students may be allergic to feathers, and therefore creatures with feathers can be plucked and prepared for consumption by the students' extensive household staffs: chefs, butlers, etc.

Which of these birds was not seen today in my back yard?
Fox Sparrow
Passerella iliaca
White-throated Sparrow
Zonotrichia albicollis
Song Sparrow
Melospiza melodia
Phoenix

Please avoid mistakes
I began by discussing the last QotD. This involved a model of the pressure, P, volume, V, and temperature, T, of a gas: PV1.6=kT, where k is a constant. This QotD was certainly similar to questions which can be asked on Math 135 exams. I would like you to answer these questions correctly. Therefore, to a certain extent, if you "need" (?) to make mistakes answering such questions, please make the mistakes here rather than on an exam. Several solutions to the problem I asked are given in the previous diary entry. Here I want to list some common errors. Please guard yourself from these:

  1. What are the constants and what are the variables? In the original problem statement, k is designated as a constant. Therefore dk/d{anything} is zero, 0. So don't worry about it.
  2. A number of mistakes were made because of inadequate and incorrect parentheses. The formulas A·B+C and A(B+C) are not the same. If A=2 and B=3 and C=4, then the first formula equals 10 and the second formula equals 14. Please put in parentheses to keep formulas correct and clear. The person you will be helping the most is you.
  3. In this problem, the letter t was used to represent time and the letter T was used for temperature. These are rather routine abbreviations. But some people confused t and T. Please write carefully. Again, the person you will be helping the most is you, because you will use what you have written in further work. I have seen students confuse their own 5's with 3's, and confuse z's and 2's. Please write carefully.

A return to the snowball
A few lectures ago we analyzed a problem about the melting of a snowball. I felt somewhat dissatisfied with the statement of the problem, because I didn't think the statement gave enough background. Let's look again at the problem. The setup is certainly simplified from "real life". The snowball is a sphere of radius r, with surface area S=4Pi r2 and with volume V=[4/3]Pi r3. Put the snowball in a warm environment. The snowball will melt, of course. But how does it melt? If you think about it, the volume, V, will decrease, but more precisely it will decrease as the snowball absorbs heat. Heat is absorbed through the surface of the snowball. (I don't think in this model that we should imagine a little machine in the middle of the snowball radiating heat!) So I think that the rate of change of the snowball's volume should be directly proportional to the surface area. That is, there is a constant k so that dV/dt=kS. What happens to the radius of the snowball? Well, since V=[4/3]Pi r3, then (r varies!) dV/dt=[4/3]Pi 3r2[dr/dt]. Match this with dV/dt=kS, and, wow!, we see that dr/dt=k. So if we believe this model, then (as the original problem statement specifies) the radius of the snowball is constantly decreasing.

The surface area of a baby?
The snowball problem is quite relevant to certain aspects of biology. There are approximate formulas for the surface area of a baby. Such formulas can be useful if estimations of fluid balance (sweat) or temperature change are needed. Babies are smaller than adults, and such balances may be very unstable. If the balances are not maintained, illness and even death can result.

So how does the radius change?
The snowball problem is quite relevant to certain aspects of biology. There are approximate formulas for the surface area of a baby. Such formulas can be useful if estimations of fluid balance (sweat) or temperature change are needed. Babies are smaller than adults, and such balances may be very unstable. If the balances are not maintained, illness and even death can result. Notice that the crucial number is the ratio between the surface area, S, and the volume, V: for a sphere this is 4Pi r2 divided by [4/3]Pi r3, which is 1/3r. When r is large, this is small, so the surface area "percolation" won't be that important in fluid or temperature balance, But when r is small, this ratio is much larger, and surface area considerations can be vital. I don't think aducts or babies are spheres (!) but still some of the same reasoning will apply.

What is (7.3)2?
Well, (7.3)2 is exactly 53.29 as some people were happy to tell me. But then I said that there was a way to approximate this number using calculus. Look at the picture on the right. The true value of (7.3)2 is the length of the dashed line which, at 7.3, is perpendicular to the x-axis. Now consider the tangent line to y=x2 at x=7. Tangent lines to this parabola have slope equal to 2x (since this is the derivative of x2). Therefore the slope of the tangent line at x=7 is 14. This slope is the tangent of the angle that the line makes with the x-axis, and therefore it is equal to the ratio, OPP/ADJ (abbreviations for "Opposite over adjacent"). So 14=OPP/ADJ. Now if we add OPP to the length of the line perpendicular to the x-axis at x=7, we will get an approximation to (7.3)2. Notice that OPP=14ADJ. Here are the numbers:

f(7) + f´(7)(.3) 
 72  +   14(.3) = 49+4.2 = 53.2
This is an approximation to the true value, 53.29. This scheme has various names. The name I like the best, because it reminds me of the geometry, is the tangent line approximation. You can look at this picture and see that there isn't much error, although the pictures drawn in this lecture may not necessarily be true to the actual proportions
Here is the general form:

f(x+h) is approximately f(x)+f´(x)h

What is (50)2?
Well, we can use the same x: x=7. Now if I want x+h to be 50, h should be 43. Then the statement, f(x+h) is approximately f(x)+f´(x)h, becomes
72+14(43) and this is 49+602, which is 651.
The true value is, of course, 502=2,500. The real picture is even worse than what is shown here. I don't think that 651 is a very good approximation to 2,500.
So it seems that sometimes it can be a good idea to use this tangent line approximation, and sometimes it can be a silly idea, or even a dreadful idea. There are ways of analyzing the error, and I will mention some, but if you use this approximation (and most of you really will use it!) you need to be careful, and worry about the error (the discrepancy between f(x+h) and f(x)+f´(x)h) and worry sometimes about the relative error: if the "true" value of f(x+h) is 128,453,201, an error of, say, 6,500 doesn't matter very much, but if the true value is 8,000 an error of 6,500 is horrible.

The chip company again
We actually have already used the idea of the tangent line approximation, which the textbook frequently calls the differential We first saw this wnen we analyzed the finances of the chip company. Let me reproduce just the beginning of the information we had:

                              CHIPCO
                 INVESTMENT DOLLARS & PRODUCTION

Capital Invested    Chips produced      Marginal chips produced
$ in millions       1,000's of units    1,000's of units per
                                        millions of $'s

      200               3,000                    .23
A key word here is marginal. Major vocabulary step:

"Marginal" means "rate of change" means "derivative".

Here is how to read the data quoted above about the chip company. If M=capital invested, and C=chips produced (all quoted in the units at the top of the table) then we kow:
C=C(M), C is a function of M, and more precisely, C(200)=3,000 and [dC/dM](200)=.23.
We then used this information to try to predict what chip production would be if we increased the invested capital by, say, 6 million dollars. This means that we'd like to approximate C(206). So here we go:
C(206) is approximately C(200)+C´(200)·6=3,000+(.23)6 thousands of chips. Here x is 200 and h is 6.

Biological systems are complicated
I wanted to give an example of the sometimes paradoxical responses of biological systems, and this becomes very evident if this linear approximation idea is carried out thoughtlessly.
An easy example of the possible complications is determining dosages of psychoactive drugs. Unfortunately this example is also quite technical and intricate. I've been unable to find simple data (numbers, graphs) on the web to support the following assertions which I believe after reading various sources.
Both human drugs (Prozac is an example) and animal drugs (certain horse tranquilizers) show the following effect in relief of symptoms. An initial dose of the drug gives some help, and then small additional doses give more help. Mathematically, f(x)>0 and f'(x)>0, so f(x+h), for suitably small h, is even better. However, in both cases, if h is sufficiently large, f(x+h) is actually much worse than f(x). In practice, as I mentioned in class, there are usually initial doses suggested mostly by the recipient's weight (mass) and metabolism (fast/slow, adolescent/mature adult, etc.). Then there are recommended changes (the derivative). But careless or impatient or unknowing people can just "assume" that the linear approximation holds for relatively large h's. Sometimes the results can be very unpleasant.
Apology I hope I have not gotten the general idea wrong. I am definitely not an expert in this material, which is quite complicated. Please let me know if you think I have communicated something wrong. Thank you in advance.

The formula and a picture
The formula is, again, f(x+h) is approximately f(x)+f´(x)h
I asked people to try to identify as many of the terms possible in a picture like the one shown here. Here is how I would assign things:
A is x.
The length of the line AB is f(x).
The length of the line AC is h.
The length of the line CD is f(x+h).
The length of the line CE is f(x)+f´(x)h.
The length of the line DE is the error, the difference between the true value and the tangent line approximation.
This curve bends down (we will call it "concave down" later) and this bending causes the tangent line approximation (the differential) to be an overestimate.
If you flip the curve, the approximation will be an underestimate, and this occurs when the curve bends up.

Still ahead
I will try to give you more information about the error later when we have more specific language. The bending has to do with how f´(x) changes (the tangent lines have changing slopes), so it is actually governed by f´´(x), the second derivative. The bending has specific names which we will learn: concave up and concave down. The picture shown is concave down, and f´´(x) is negative.

QotD
What is the approximate value of (7.98)1/3? here I asked that people not use calculators, and use the linear approximation scheme discussed above.
I drew the picture shown, and asked if the approximate value would be more or less than the true value.

Solution
Here f(x)=x1/3, so f´(x) is (1/3)x-2/3. The specific x value I'd use would be x=8 and I'd take h to be -.02. I was "nasty" and tried to surprise people with a negative value of h. The famous (?) f(x+h) is approximately f(x)+f´(x)h becomes:
x=8, so f(8)=81/3=2 and f´(8)=(1/3)2-2/3=(1/3)(1/4)=1/12. Therefore (7.98)1/3 is approximately 2+(1/12)(-.02).
The picture tells us that the approximation will be an overestimate. The true value is less than the approximation because the tangent line in this case is above the curve.
Indeed, an electronic friend of mine reports that this tangent line approximation is 1.998333333 while the "true" value is 1.998331943.

HOMEWORK
Please read sections 3.7 and 3.8 and hand in these problems on Thursday:
3.7: 4, 15, 24, 25;
3.8: 19, 20, 25, 35.


Friday, March 4: this is lecture 14

The most recent QotD
Last time I had the following information on the board:
x2+xy+2y2=11
(1,2) is on this ellipse.
dy/dx=-(2x+y)/(x+4y)
I asked for an equation of a line tangent to the ellipse at (1,2). I wanted people to use the information in front of them and insert (1,2) into the equation for dy/dx. The result is -(2(1)+2)/(1+4(2))=-4/9, the slope of the line. Then a valid answer is:
(y-2)=-(4/9)(x-1)
and nothing else needs to be done! Please: this was supposed to be easy!

Why QotD?
I guess I can see who is coming to class. Wow. This is not too valuable, since what I really report on via the student grades for the course is whether you have learned the material, principally as shown by work done on exams. The QotD is a way to communicate between the instructor and the students. I will try to give a meaningful, hopefully interesting problem. You try to show me what you do or don't know. I will try to give feedback in the next class. I can learn if I did a "good" job teaching. You can learn about your learning and your own mastery of the work, and see what I think of this. I honestly believe this is a good deal for you.

Differentiating a few more things ...
What about y=10x? Take logs. Rather, take lns. This becomes ln(y)=x ln(10). Then d/dx this equation. The Chain Rule applies to the left side and gives: (1/y)(dy/dx). The right side is CONSTANTx, so its derivative is just the CONSTANT. Therefore we know that (1/y)(dy/dx)=ln(10), and dy/dx=ln(10)y, and since y=10x, dy/dx=ln(10)10x=(2.30258)10x. Most people don't like that weird number, so they stick to ex in calculus.

Here is (approximately) a problem from WeBWorK. Suppose f(x)=(5x2+7x+9)sin x. What is f´(x)? First I will take ln's and then I will d/dx:
ln(f(x))=ln((5x2+7x+9)sin x)=(sin x)ln(5x2+7x+9) because ln(AB)=Bln(A). Now let us d/dx the equation, not forgetting either the Chain Rule or the Product Rule.
Left side So d/dx of ln(f(x)) is [1/f(x)]f´(x).
Right side d/dx of (sin x)ln(5x2+7x+9) is:
    (cos x)ln(5x2+7x+9)+(sin x)[1/(5x2+7x+9)](10x+7).
Together So [1/f(x)]f´(x)=(cos x)ln(5x2+7x+9)+(sin x)[1/(5x2+7x+9)](10x+7) and if we multiply by f(x) and use the original formula for f(x) we get:
f´(x)=((5x2+7x+9)sin x)[(cos x)ln(5x2+7x+9)+(sin x)[1/(5x2+7x+9)](10x+7)]
You will never see formulas like this outside of a first semester calculus course.

Squares that grow
I began with this problem:
    Suppose we have a square whose edges are increasing at 2 cm/min. How fast is the area of the square increasing when the area of the square is 100 cm2?
We discussed this problem. I emphasized the need to translate things to mathspeak, including the dialect calcspeak.
   a square whose edges are increasing at 2 cm/min.
This means that the rate of change of the edge is 2 (in cm/min) and is actually + (positive) because of increasing. We should use algebra and name the edge length: I'll call this, e. Then we know that de/dt=2. Now we need
   ... the area of the square
If A is the area of the square, then A=e2. We want to know
   How fast is the area of the square increasing ...
and we need dA/dt. Let's d/dt the equation A=e2 and let us not forget the Chain Rule! Then:
dA/dt=2e(de/dt).
I know de/dt is 2. But what is A? One more thing:
   ... when the area of the square is 100 cm2?
So A=100=e2 and therefore e is 10 when we want dA/dt. Therefore:
dA/dt=2e(de/dt)=2(10)2=40.
Again: please read the statements of such problems very carefully.

Roger and Jane
Here's the statement:
    Suppose Roger is driving north from the center of town at 40 miles per hour, and Jane is driving east from the town center at 50 miles per hour. How quickly is the distance between them changing when Roger is 10 miles north of town and Jane is 30 miles east of town?
There are lots of numbers here, but I tried to be kind and make the numbers all distinct so maybe the problem will be less confusing!
I think in this problem I tried to invent an acronym ("a word ... formed from the initial letters of other words") for investigating such problems. Let me try:

This outline doesn't always work, and sometimes parts of it aren't needed. To the right is a diagram (P). The basic outline is a right triangle. The "legs" of the triangle are Roger and Jane's distances, which vary with time, from the town center. This distance certainly varies. I have labeled (L) the two distances a and b. The distance between them is called c. What I know (I) from the problem statement is that da/dt=40 and db/dt=50, and that at a certain time (which is not known) a=10 and b=30. I would like to know (W) what dc/dt is at that "certain time". There is one more ingredient (E). Since north and east are perpendicular, we have Pythag: a2+b2=c2.

Let us d/dt the equation. The result is 2a(da/dt)+2b(db/dt)=2c(dc/dt). We know values of a, da/dt, b, and db/dt, so that 2(10)(40)+2(30)(50)=2c(dc/dt). What is c? We can get c from the original equation: a2+b2=c2 becomes (10)2+(30>2=c2, so that c=sqrt((10)2+(30>2). This allows us to solve for dc/dt:
dc/dt=[2(10)(40)+2(30)(50])/sqrt((10)2+(30>2)

Comment I remarked that this problem is not as silly as it might seem. One simple problem dealing with cell phone networks is similar to this. Maybe imagine a cell phone user driving (or even, as I mentioned, flying). How fast is the distance changing between the user and the network of cell phone towers? That sort of information could be rather important in practice.

Pulling taffy
We all know that pulling taffy is a principal industry at the New Jersey shore. There are these wonderful machines that take sticky stuff and, well, pull it. Why? The pulling changes the texture. I hope some of you will try this. Let me make a simple model of taffy pulling.

    I will suppose that the taffy is a circular cylinder. The cylinder is pictured to the right. The cylinder has a height of h (although the cylinder is lying on its side, so maybe the height is a width? I am confused!). The radius of the circular cross-section is r. The volume, V, of the cylinder is given by its height multiplied by its constant cross-section: V=Pi r2h.
I will assume that the amount of taffy stays constant as it is pulled: there is no change in V. (This may be wrong: does taffy get denser as it is pulled? I don't know. Comments from someone who has food laboratory facilities?)
Suppose that h=10 inches and r=2 inches, and that the height is increasing by 1/3 inch per second. How will r change?
   

 
Let's d/dt the equation V=Pi r2h. The most interesting part of this is to think about dV/dt. I claim this is 0, and this is a consequence of the conservation of taffy: there is no change in V over time! Then we need to use the product rule and the chain rule on the right-hand side:
0=Pi 2r(dr/dt)+Pi r2(dh/dt).
Let us insert the values we know:
0=Pi 2(2)(dr/dt)+Pi 22(1/3).
Then dr/dt=-[Pi 22(1/3)]/[=Pi 2(2)] and we see that the conservation of taffy automatically gives us a negative sign on the rate of change of r: if h is increasing, then r must be decreasing. To me that is sort of neat.

Is pressure
really
measured
in ATM's?
Pressure, volume, and temperature of a gas
Let us assume that the pressure, P, and the volume, V, and the temperature, T, are related by PV1.6=kT, where k is a constant.
Part 1 Suppose you know that when P=2 and V=10, then T=200. What is the constant, k?
A graphing calculator is required for this course.
So 2(10)1.6=k(200). Therefore k=[2(10)1.6]/200=.398 (approximately, as reported by several students).
Part 2 Now suppose that P increases at the rate of .2 atm/min, and V decreases at 3 cm3/min. Does T increase or decrease, and at what rate? (The QotD!)

Solution of the QotD
So d/dt the equation PV1.6=kT remembering both the product rule and the Chain Rule, and that k is a constant. This is the result:
(dP/dt)V1.6+P[1.6V.6(dV/dt)]=k(dT/dt)
The .6 comes from 1.6-1, I think. Let's insert all of the known values:
(+.2)101.6+2[1.6(10.6)(-3)]=.398(dT/dt).
Wow. I get -76.02, approximately, for dT/dt. So my number states that T is decreasing, and the rate of decrease is the that number.

Another way to solve the QotD
Well, some students took the equation PV1.6=kT and ln'd it first. They should have gotten ln(P)+1.6ln(V)=ln(k)+ln(T). If this equation is d/dt'd, we get (1/P)[dP/dt]+1/6(1/V)[dV/dt]=0+(1/T)[dT/dt]. Notice that dk/dt is still 0, since k is still a constant. Then insert the various values of everything and solve for dT/dt. The result should be the same.

HOMEWORK
Please read sections 3.6 and 3.7 and do homework problems.


Tuesday, March 1: this is lecture 13

Students volunteered (well, maybe) to do a many derivative computations using the Chain Rule. I don't remember all of these valiant individuals (except for Chi Chi!). I think the functions were something like the following:

FunctionIts derivative
sqrt(1+5x2) (1/2)(1+5x2)-1/2(0+10x)
tan(78x) (sec(78x))2(78)
Comment The squaring of secant is part of the derivative of tangent. Sometimes this can give irritation if you forget it.
ln(37+sin(8x)) [1/(37+sin(9x))](0+cos(8x)8)
Comment This is a composition inside of a composition! You need to use the Chain Rule twice.
(3e2x-7e5x)500 500(3e2x-7e5x)499(3e2x2-7e5x5)
Comment Another double composition. Even if you know what you are doing, you can make "bookkeeping" errors quite easily. Please use many, many pairs of parentheses. The person you are helping is yourself!
cos(3sin(5cos(x2))) (-sin(3sin(5cos(x2))))(3cos(5cos(x2)))(-5sin(x2))(2x)
Comment Hey -- how many compositions does this function have? Who cares? Just try to keep track of the layer of the onion you are "traversing".
sqrt(7+sqrt(2+x2)) (1/2)(7+sqrt(2+x2))-1/2(0+(1/2)(2+x2)-1/2(2x))
Comment Another double composition.
Suppose f(x) is differentiable, and you know that f(1)=3 and f´(1)=7. Define F(x)=f(x2). What is G´(1)? F´(x)=2(f´(x))1(2x) so that F´(1)=2(f´(1))(2·1)=2·7·2·1=28.
Suppose f(x) is differentiable, and you know that f(1)=3 and f´(1)=7. Define G(x)=(f(x))2. What is G´(1)? G´(x)=2(f(x))1(f´(x)) so that G´(1)=2(f(1))(f´(1))=2·3·7=42.
Comment The two examples just done are an effort to show you that order of composition matters a great deal in using the Chain Rule. Look: the answers, 42 and 14, are not the same!

Important!!
The Chain Rule is probably the most useful differentiation algorithm.

algorithm
[Math.] a process or set of rules used for calculation or problem-solving
It will be used in many ways in this course. The idea of multiplication of rates, as I discussed last time in the chip example, is also one which you will use in real life (if you are alert enough to recognize it!).

3.5 #52
I discussed an actual textbook homework problem. Let me first quote what problem writers call the stem of the problem, the descriptive material which sets the stage:
    Assume that a spherical snowball melts in such a way that its radius decreases at a constant rate (that is the radius is a linear function of time). Suppose it begins as a sphere with radius 10 cm and takes 2 hours to disappear.
Before going on let's see what information in "calcspeak" we can get from this paragraph. We'll call the radius, r, and measure it in cm. Time will be measured in hours, and labeled, t. The sentence
its radius decreases at a constant rate
informs me, first, that I should look at a rate, and in calcspeak that's a derivative. That the rate is constant means dr/dt is a constant. Further the word decreases tells me that the suggested constant is negative. Now what is the actual number? For this I will use the information begins as a sphere with radius 10 cm and takes 2 hours to disappear. This phrase suggests that (10-0)/2 (first noticed at radius 10, then after 2 hours at radius 0, then divided by the time elapsed) is the constant. So now I know that dr/dt=-5. Wow! There is a good amount of translation going on. Now let's see what the text asks:
    a) What is the rate of change of its volume after one hour? (Recall V=(4/3)Pi r3.)
The phrase rate of change indicates to me that I want a derivative. The word volume tells me I want dV/dt. I can use the equation supplied by the text, V=(4/3)Pi r3 and differentiate. I may not forget that r is a function varying with time. So then the Chain Rule gives:
dV/dt=(4/3)Pi 3r2(dr/dt).
Well, I know that dr/dt is -5. But what is r? There's a phrase that hasn't been used yet: after one hour. Well, the snowball starts with r=10, and decreases at a constant rate until after 2 hours, r=0. Since one hour is exactly in the middle, I think that r is 5 then. Therefore
dV/dt=(4/3)Pi 3r2(dr/dt)=(4/3)Pi 3(5)2(-5).
And I have learned that the volume is also decreasing (that is what the minus sign declares) and that the rate of decrease (in units of cm3/hour) is what's there. There is another part to the problem:
    b) At what rate is the surface area changing of after one hour? (Recall S=4Pi r2.)
Now I differentiate S=4Pi r2 with respect to t:
dS/dt=4Pi 2r1(dr/dt)=4Pi 2(5)1(-5) using the Chain Rule to get dS/dt and the previously obtained value of r for after one hour.

d/dt
"Let's get rid of the bugs, and use d/dt ..."
This was supposed to be a joke. Oh well, here is more than I know about ddt.

A useful trick: implict differentiation
The circle with center at (0,0) and radius 1 is x2+y2=1. Suppose we wanted to find the slope of the tangent line. Most of what we have done in this course applies to graphs of functions, and the unit circle is definitely not the graph of a function. How could we find the slopes of tangent lines? Well, we could "solve" for y as a function of x:
y=+/-sqrt(1-x2)
and then differentiate, using the Chain Rule. The +/- sign there is the algebraic version of the idea of splitting the unit circle into its TOP half and its bottom HALF. Each of these is the graph of a function.
What the heck can we do to minimize work? And what can we do if we don't have an equation that's so easy to solve for x?
What we can do is d/dx the whole equation x2+y2=1. The right-hand side offers no problem. The first term on the left gives 2x. The problematical one is y2. Here we need to realize that y is some "implicit" function of x.

implicit
implied though not plainly expressed.
Therefore d/dx(y2) must be (Chain Rule!) 2y·dy/dx. Thus we have 2x+2y(dy/dx)=0, and so dy/dx=(-2x)/(2y)
This works on both the TOP and the BOTTOM.

How about another one?
I did something ugly. Maybe it was sort of like this:
Assume that y is implicitly defined as a function of x by the equation
5x3+7x2y5-9y7=38.
What is dy/dx? I would try to d/dx the entire equation, and try to remember to use the Product Rule and Chain Rule as appropriate. Again, it is easy to lose one's way in all this.

      5x3      +      7x2y5      -9y7   =    38

Just d/dx  The product rule   The Chain Rule 
           & the Chain Rule   

15x2  +  14xy5+(7x2)(5y4)(dy/dx)  -9·7(y)6(dy/dx) =0

Now collect terms without dy/dx and put them on the other
side. Collect the dy/dx terms and factor out dy/dx:

[(7·5)x2y4-(9·7)y6](dy/dx)=-[15x2+14xy5]

Divide by the dy/dx coefficient and get "the answer":
         -[15x2+14xy5] 
dy/dx= --------------------
       [(7·5)x2y4-(9·7)y6]

So here is Implicit differentiation:

  1. d/dx the whole equation. Don't assume something is a constant unless you know that for sure.
  2. Use the Chain Rule, the product and quotient rules, etc.
  3. Algebraically put all the stuff not involving dy/dx on one side of the equation. Put all the dy/dx stuff on the other side.
  4. Divide by the dy/dx coefficient, and that should give you a formula for dy/dx.
Maybe a more realistic example
Look at the equation x2+xy+2y2=11. The collection of (x,y)'s which satisfy this equation turn out to be a tilted ellipse. I had a silicon friend of mine draw this ellipse, and the picture obtained is shown to the right.

How is "typesetting" done? Many times people want to display paragraphs of type and pictures and tables and ... lots of things. In order to allocate space, each "chunk" of the page has a bounding box. This is the smallest box (rectangle with sides parallel to the coordinate axes) which contains the figure. This bounding box is then used to pack the chunks of the page neatly together. What is the bounding box of this ellipse?

I've tried to draw the bounding box and the ellipse together here. The geometry says that there are four points where the box touches the ellipse. If we knew the coordinates of the points, then we would be able to find the dimensions of the bounding box.

The top and bottom of the box are determined by two points where the tangent line is horizontal. Maybe we could find these points. They would be points on the ellipse where dy/dx is 0. So let's find dy/dx when x2+xy+2y2=11. I'll use implicit differentiation. I'll begin by d/dx'ing the whole equation. The result is:
2x+y+x(dy/dx)+4y1(dy/dx)=0.
On the left-hand side, I used the product rule and Chain Rule on the second term and the Chain Rule on the third term. Then we can regroup the terms in the equation">br? [x+4y](dy/dx)=-(2x+y)
and solve for dy/dx:
dy/dx=-(2x+y)/(x+4y).

When is dy/dx=0? Well, the only way a fraction can be 0 is when the top is 0. So this means that -(2x+y) is 0, os 2x+y=0 or y=-2x. But the point (x,y) is also on the ellipse, so that x2+xy+2y2=11 must also be true. If y is -2x, I can substitute for y and the equation become:
x2+x(-2x)+2(-2x)2=11
and (if I do the arithmetic correctly!) this is (1-2+8)x2=11 so that x=+/-sqrt(11/7). At points where the tangent line is horizontal, we know that y=-2x, so that the two points of contact on the top and the bottom are (sqrt(11/7),-2sqrt(11/7)) and (-sqrt(11/7),2sqrt(11/7)). These points are approximately (1.254,-2.508) and (-1.254,2.508) and to me this looks approximately correct compared to the pictures.

What about the points of contact of the bounding box on the left and the right? Well, at those points the tangent line is vertical. It has no slope. We have a formula for the slope of the tangent line:
dy/dx=-(2x+y)/(x+4y).
The formula doesn't work when the bottom, the denominator, is 0. That occurs when x+4y=0 of x=-4y. If I insert this value of x in the equation x2+xy+2y2=11, I'll get (-4y)2+(-4y)y+2y2=11. Again, if I do the arithmetic correctly, this means 14y2=11 so that y=+/-sqrt(11/14). Since x=-4y the left and right touching points are (-4sqrt(11/14),sqrt(11/14)) and (4sqrt(11/14),-sqrt(11/14)). These are (-3.545,.886) and (3.545,-.886). Again, this looks about right to me.

QotD Write an equation for a line tangent to the ellipse x2+xy+2y2=11 at the point (1,2).
(We checked by substituting that (1,2) was on this ellipse!) What's needed is a point and a slope for the line.

HOMEWORK
Please read 3.5 and 3.6 and hand in these problems on Thursday:
3.5 24, 31, 48a, 53
3.6: 4, 7, 34, 39


Friday, February 25: this is lecture 12

I distributed copies of the chart below and wrote a copy on the side blackboard. I remarked that the numbers on the chart were invented, but for the purposes of this class we should believe they were real. We discussed the chart for a while (45 minutes is "a while"!). There's a great deal of information, and I hoped that we could understand the information.

	                      CHIPCO
                 INVESTMENT DOLLARS & PRODUCTION

Capital Invested    Chips produced      Marginal chips produced
$ in millions       1,000's of units    1,000's of units per 
                                        millions of $'s

      200               3,000                    .23  
      300               3,040                    .28
      400               3,070                    .42
      500               3,100                    .78 
      600               3,190                    .31 

CHIPCO SALES & PROFITS Chips marketed Profit gained Marginal profit 1,000's of units $'s in millions Millions of $'s per 1,000's of units 3,000 1.2 .03 3,050 2.8 .02 3,100 3.6 .05 3,150 4.9 -.01 3,200 5.1 .02

We decided that the pair of numbers 400  3,070 referred to the following phenomenon: if the corporation invests 400 million dollars in capital (building a factory, furnishing it, hiring and training people, etc.) then 3,070,000 chips can be produced.

Then we tried to understand the third column. The word "marginal" is used in a fairly technical sense, although the use is common in economics. In the first table above, it refers to the approximate amount that chip production would increase per each million dollars of increase in capital investment. Therefore, for example, if $302 million were invested, then (according to this model) chip production would be 3,040,000 (chip production at the $300 million level) plus .28(2)(1,000) chips. The 2 comes from the additional millions of dollars of capital. The 1,000 comes from the units used for chip production. The .28 is this "marginal" quantity. In the first table, the marginal quantity is therefore the approximate amount  P/ C, relating the change in chip production to the change in capital investment. It is sort of a slope, or, more likely, sort of a derivative: indeed, the use of "marginal" in economics usually means a derivative. In this model, if $297 million were invested, the approximate expected chip production would be 3,040,000 (again, chip production at the $300 million level) plus .28(-3)(1,000). The novelty here is the use of the minus sign, since the capital investment is decreasing rather than increasing.
The marginal production may vary because at different levels, maybe different new machines have to be purchased, or different types of employees need to be hired and trained, etc. Things aren't simple. I hoped that students would recognize the third column of the table was actually list of values of the derivative of production with respect to the "independent variable", capital invested.

The second table describes a similar phenomenon, here connecting the chip amount, C, with the profit derived from these marketing and sale of these chips. For example, the profit derived from the sale of 3,000,000 chips (the first line of the second table) is $1.2 million. If we now look at the third column, the model predicts a marginal profit of .03 (in the given units). Using this, if 3,010,000 chips are marketed (that's 10 more 1,000 units of chips) the additional profit would be .03(10) million dollars, or $300,000. And if only 2,970,000 chips were marketed, then the profit would be 1.2 million+(.03)(-30)(1,000)million. (I think I got all the units correct.) The third column gives  P/ C for various amounts of chip marketing: the change in profits compared to the change in chips marketed. One of the numbers in the third column is negative: the -.01 at the 3,150 level. Is that realistic? I tried to make a metaphor with a much more modest "business". I could deliver newspapers every morning. Say that I have 100 customers, located on five consecutive blocks of one street. It is easy and efficient for newspaper delivery: the costs are low. What if I get 1 additional customer? Well, if the customer lives "across town", with a half-hour of driving needed, taking on this additional business will actually probably cost money. There may be reasons that the business is desired, but on a direct basis the incremental profit is negative rather than positive.
Of course the validity of such models can certainly be criticized, but I really wanted to show you these tables to explain what's in the next paragraph.

The two tables linked together describe a complicated phenomenon. First we "input" capital, M (M is for money), which produces C, a certain number of chips. Then the chips are marketed (and sold, hopefully!) to obtain a certain amount of profit, P. Here we have a composition of functions. For example, suppose we were asked how much profit there is if we put in M=500 million dollars. From the first table we read off C=3,100,000 chips, and from the second table we can then see that P will be 3.6 million dollars.

I hoped that this was all fairly clear. Now I asked what I thought was a difficult question. Suppose we increase M from 500 million dollars to, say, 503 million dollars. What will the model predict the likely profit will be? We can trace this if we are sufficiently alert. The first marginal quantity we need to consider is  C/ M. For M=500 million dollars, this is .78. So the new chip production is old chip production + increase in chip production, and this will be 3,100,000+(.78)(3)(1,000). Now let us consider the chip/profit table. With C=3,100,000, we see that profit is supposed to be 3.6 million. But we are changing C by adding on the (relatively small) amount of .78(3)(1,000). The relevant marginal quantity here is  P/ C, on the row where C is 3,100(,000). The marginal amount here is .05, so that the new profit will be the old profit (3.6 million) plus (.05)(.78)(3)(1,000) million dollars. The 3 comes from perturbing the capital investment. The 1,000 comes from my weird units. The really interesting stuff is (.05)(.78): indeed, this represents the marginal profit as capital invested changes, when the capital investment is 500 million dollars. Symbolically, the multiplication might make sense written this way:

P   P C
--- = --- ---
M   C M
So the  C's just seem to cancel out. This multiplication of rates is typical of what happens when a composition changes. This is more complicated than just multiplying fractions, since the fractions (the marginal stuff, the derivatives) need to be "evaluated" on the appropriate rows of the tables. But the key idea is that the rates multiply, but you need to evaluate the rates at the correct inputs.

Further comments One student remark was quite clever and exposed a weakness of the method used. For example, the marginal cost of chip production at the level M=200 is .23 and at M=300 it is .28. What do we know about the marginal cost at, say, 350? In my examples, I was very careful to consider only changes which were quite small compared to the original quantity. I would not want to use these ideas far away from the known data. I would need to rethink my model.
It is easy to get interesting compositions and rates of change in biology. I remarked that the transmission of influenza through humans and other species (birds, pigs) provides very interesting examples, although I think the biology is more difficult to explain than the economics behind the tables above.

I've tried to present heuristic evidence that would allow us to believe the chain rule.

/heuristic/ adj.  
1. allowing or assisting to discover.
2. [Computing] proceeding to a solution by trial and error.
The Chain Rule Suppose that f and g are differentiable functions. Then F(x)=f(g(x)) is differentiable, and F´(x)=f´(g(x))·g´(x).
Here F(x) is the composition of the functions f and g. The tables above sort of indicated that chip production was a function of capital investment, and then that profits were a function of the chips marketed, so that profit as a function of capital investment was a composition of the two functions.

The balance of the lecture was devoted to using the chain rule with functions defined by formulas. There is a correct proof of the chain rule in the book. My first example was something like this (about as simple as I could imagine):
If F(x)=(x2+7)300, what will F´(x) be? Success here probably will result from recognizing that the chain rule applies.
If F(x)=f(g(x)), then g(x) is x2+7 so g´(x)=2x, and f(x) is x300 so f´(x)=300x299. Thus F´(x)=f´(g(x))g´(x)=f´(x2+7)(2x)=300(x2+7)299(2x). Whew!
Alternate strategy You could take the summer off and "expand" (x2+7)300. It is only a polynomial of degree 600. And then it will be easy to differentiate this as a sum of constants multiplying monomials. That's it: take the summer off and report back next fall on this method. Be sure to get everything correct.

But now comes the realistic comment. Almost no one ever bothers to write all of the intermediate steps. That is, in practice very few f's and g's are actually identified. What happens is that people see and differentiate the outside most function (f above), put in the inner function (g) in that derivative, and then multiply by g'. For example, consider sin(ex+x2). What is its derivative? The outside function is sine, whose derivative is cosine. So I begin by writing
cos(what's insidethe derivative of what's inside.
The result is
cos(ex+x2)·(ex+2x).
This expression is a formula for the derivative of sin(ex+x2). Again, I urge you to consider the significance and necessity (!) of appropriate parentheses in these expressions. The "argument" of cosine is ex+x2 and the cosine expression is then multiplied by the expression (ex+2x).

I did several other examples, included repeated composition:
If F(x)=cos(e37x2), then
F´(x)=[-sin(e37x2)](e37x2)37·2x.
Here I see F(x) as a composition of three functions. The outermost function is cosine, whose derivative is -sine. The next function is "e-to-the", which is what I think when I see the exponential function written in its usual form. The derivative of e-to-the is e-to-the. The innermost function is 37x2 which has derivative 37·2x. Maybe using the Chain Rule is like peeling an onion, layer after layer, and each layer when "peeled" (differentiated?) contains a copy of the contents of its unpeeled self. Sigh. Sometimes metaphors are really silly. (Why are you crying? I don't always cry when I peel an onion.)

QotD What is the derivative of [sin(x2)]100? I emphasized that this was not a situation where the 100 and the 2 could be combined.
This is a triple compositon, but don't worry about it: just handle each layer as you see it.
The derivative is 100[sin(x2)]99·[-sin(x2)]·2x.

I returned the exam together with an answer sheet. I remarked that detailed statistics and discussion of partial credit can be read here. I also said that about 40% of the course has gone by, and the next 60% would be denser and more technical. Although I believe that the grading is not perfect (I'd check additions first!) my suggestion for treatment of suspected errors in grading has two parts: first read through the partial credit treatment on the web and see if the scoring of your paper was consistent with that, and then if needed, report the suspected errors to me.

HOMEWORK
The material of this lecture is in section 3.5, and certainly the Chain Rule is the most important differentiation rule. You need to practice the Chain Rule a great deal. Here is the first time I've made this suggestion to you: do every problem suggested. If you still can't get it, do more problems!
Also, the WeBWorK assignment is due tonight.


Tuesday, February 22: this would be lecture 11

This would be lecture 11 except that we had an exam. I am currently grading the exam, and have graded half of the problems. I hope to return the graded exam on Friday, when I will also discuss the Chain Rule, which is probably the most important differentiation algorithm.

ATTEND RECITATION!
I have asked Mr. Jin to discuss some matters relating to derivatives: graphs and certain computations. After his discussions I hope that he will give a quiz. The material I have suggested to him relates well to certain exam questions which I have already graded. I was not able to give full credit to many students on these problems. Therefore you should attend recitations on Thursday, and learn from him, please.


Friday, February 18: this is lecture 10

I spent a fairly short amount of time on the elements of calculus dealing with motion in a straight line. In particular I discussed:
  • Position
     Distance traveled
  • Velocity
     Speed
  • Acceleration

    Rectilinear motion
    This means motion in a straight line. I'll try to use traditional notation for this stuff. I'll consider the motion of a bug on a straight line, here drawn horizontally. The position of the bug at time t will be s(t). There are now a whole bunch of definitions.

    The adventures of Fred the bug I was going to illustrate this with a picture of a typical New Jersey bug, but the Department of Entomology of Cook College was no help. I learned that the New Jersey State Bug is the honeybee, though.

    After a request in this diary for a good New Jersey bug, Mr. Paul Remelgado gallantly suggested the Brown Marmorated Stink Bug (Halyomorpha halys) as somehow particularly appropriate for these pages. Perhaps this is understandable. How wonderful is Cook College, and how wonderful are its students!

    Suppose that the position of Fred at time, t, is given by s(t)=t2-2t.
    Question #1 What is the average velocity of Fred from t=5 to t=7?
    Answer s(7)=72-2·7=35, and s(5)=52-2·5=15. So the average velocity in the interval from 5 to 7 is (35-15)/(7-5)=10.

    Question #2 What is the (instantaneous) velocity of Fred at time t=6?
    Answer Since s(t)=t2-2t, ds/dt=2t-2, and when t=6, this is 2·6-2=10. I felt really silly when the answers to these first two questions were the same, and I hope people realize that the equal answers were just coincidences, and equality won't always be correct.

    Question #3 How far does Fred crawl from time t=-10 to time t=10? (Fred is a remarkable and immortal bug, and travels from -infinity time to +infinity time.)
    Note This is a very tricky question.
    Answer Well, I first computed the positions of Fred at both times. s(10)=102-2·10=80 and s(-10)=(-10)2-2·(-10)=120. One guess might be that we could compute the requested quantity from the numbers 120 and 80. This is not correct! The answer would just be the net change in position of Fred from -10 to 10. It would not necessarily be the total distance that Fred crawls in the time interval [-10,10]. Fred's path is much more dynamic than that!

    Digression on velocity
    Velocity has a sign and a magnitude. The sign describes the direction of travel. Conventionally (as I've done in the accompanying pictures) +, plus or positive velocity, means that the bug is moving from left to right. The opposite, -, minus or negative velocity, means the bug is traveling right to left. The magnitude of the velocity, the speed, tells me how fast the bug is moving. (The speedometer on your car goes up when you move either forward or backward. My car doesn't have a +/- sign to tell me, on the speedometer, which direction that the car is moving.)

    Question #4 When is Fred moving to the left? (And the right, etc.)
    Answer Since ds/dt=2t-2, Fred moves to the left when 2t-2<0, so that 2t<2 or t<1. So for times less than 1, Fred moves left. Similarly, Fred moves right for times greater than 1. Fred's motion is not very complicated.

    Back to question #3
    Between -10 and 10 Fred moves to the left from -10 to 1, and then to the right from 1 to 10. The key positions for Fred's motion are s(-10)=120, s(1)=12-2·1=-1, and s(10)=80. So Fred moves left 121 units, and then right 81 units. The total distance that Fred moves seems to be 121+81=202. The picture above attempts to show more kinetic (!) view of Fred's motion, with the blue arrows trying to show Fred's path.
    As far as I know, the simplest way to answer questions of this type is to first find all possible turning points, that is, times when s´(t)=0 and see how they affect the motion during the time interval of interest.

    While standing in a tree ...
    I quoted a formula from p.133 in the text:
         h(t)=-(1/2)gt2+v0t+s0
    Here h(t) is supposed to be the "formula for the height of a projectile", and g is the acceleration due to gravity, v0 "is the initial velocity" and s0 "is the initial height.

    Now, on Earth, if distance is measured in feet (almost obsolete!) and time is measured in seconds, then g is about 32. Height is measured so that more + means higher. The g term has a negative sign because the gravity pulls an object down.
    Problem statement Suppose you are standing in a tree on Earth 50 feet above ground, and you throw a ball straight up in the air at 30 feet per second. Question #1 What is a formula giving the height of the ball for later times?
    Answer Well, s0=50 and v0=30. These numbers have positive signs because you are in a tree above ground and because you throw the ball up: those words encode the signs and you can't do the problem correctly without paying attention to them. g is 32 because the tree is on Earth. So I use the textbook's equation and obtain
         h(t)=-16t2+30t+50

    Question #2 What is the highest that the ball gets, and what time does it get that high?
    Answer The velocity is positive while the ball is on its way up, and is negative while the ball is on its way down. When the ball has velocity=0, it is (metaphorically!) stopped, at the tippy-top of its path. So we need to find when the velocity is 0. Since h(t)=-16t2+30t+50 we know v(t)=-32t+30, and this is zero when t=30/32. How high is it at that time? Well, we plug the time into the formula giving the height:
    h(30/32)=-16(30/32)2+30(30/32)+50 and that's the answer.

    Question #3 At what time does the ball hit the ground?
    Answer The ball hits the ground when the height is 0. That occurs when -16t2+30t+50=0. I would not waste my time trying to factor such a silly quadratic. I would just use the quadratic formula. That tells me the roots are at
    [-30+/-sqrt((30)2-4(-16)(50))]/(2·-16).
    But which root is the hitting time? We need the positive root. The bottom of this giant fraction is negative, so we want the top to be negative also. But the top will be negative when we choose the minus sign in front of the square root, so the unique answer is
    [-30-sqrt((30)2-4(-16)(50))]/(2·-16).

    In these exercises I am trying to behave as you should during a Math 135 exam (see the discussion which follows for more detail). In fact, if this really were somehow a problem I needed to solve in the real real world, I would use a calculator freely at various times to approximate the answers to questions 2 and 3. Math 135 is not the real world.

    I am writing the following part of this diary entry before class.

    WeBWorK
    The closing time for WeBWorK assignments will now be 9 PM on Friday beginning with next week (set 5). This will take into account our exam, and the subsequent delays in the lectures.

    My grading on an exam ...
    The QotD from the previous class meeting provides an excellent opportunity for me to explain in some detail how I will grade exam problems.
    The question was:

    Use calculus to find the exact coordinates of the bump on the graph of y=xex.

    The setting of the question included a sketch of the graph, and the sketch clearly displayed a "bump" in the third quadrant, where both coordinates of the point would be negative. I'd classify this question as one of medium difficulty for a Math 135 exam, and I'd probably give it a value of 7 or 8 points on a 100 point exam.

    What would I look for when I graded this question? I would want recognition by the student that the bump occurred when the tangent line was horizontal. An effort to locate the point would therefore involve setting the derivative equal to 0. But let me be more precise:

    The cover page for the exam will have the following sentence:
           Show your work. An answer alone may not receive full credit.
    Therefore if I were grading this problem on an exam I would give 1 or 2 points to a bare answer. I would not give more credit to a bare answer. I want to see supporting evidence that the student has understood the process.
    Note also that the answer is (-1,-e-1). The answer is not any sort of approximation. There are several reasons for this:
    1. The question asked for "the exact coordinates". An approximation is therefore not correct.
    2. The formal review problems state:
           Answers to exam questions must be exact, not calculator approximations. For example, the number 1.732050808 is not a correct answer when the right answer is actually sqrt{3}.

    I assess this question as one of medium difficulty on a Math 135 exam. My reading of the QotD solutions suggests that about half of the students would have received full credit if their answers were graded. Other students would get no points. Also, I will generally insist that students do "my" problem, the one whose statement appears on the exam. Substitutes or simplifications are not acceptable.

    Further ...
    I've gotten a WeBWorK report on the first four problem sets. Some students have done little or no work. WeBWorK scores will be a component of course grades. Here is what one of my wise colleagues said to me:
           You don't give grades. You report the grades students have gotten.

    Today's QotD
    The graph of y=2x3-3x2-12x+1 is as displayed. What are the coordinates of A and B?

    Comment Yeah, I purposely (and meanly!) did not draw any axes. So part of the problem is to figure out which point has which coordinates. And I even wrote it this way on an exam: another irritation!

    I will attempt to have students' solutions graded and available at the review session Monday evening.

    HOMEWORK
    Study for the exam.

    Diary entry in progress! More to come.


    Tuesday, February 15: this is lecture 9

    Exam! Exam!! Exam!!!
    There will be an exam for sections 21, 22, and 23 of Math 135 a week from today at the standard class time and place. Please see review material linked from the course homepage. The material includes an official formula sheet which will be included with the exam. Note that students who need to consult the formula sheet extensively during the exam usually do not know the material very well and tend to do poorly on exams.
    Also, students should bring with them a graphing calculator which cannot do symbolic manipulation. The general instructions for the course state:
           ... you may not use calculators with QWERTY keypads or symbolic manipulation capabilities. In particular, the TI-89, the TI-89 Titanium, the TI-92 and the Voyage 200 will not be allowed on any exam.
    The lecturer will hold a review session in Loree 020 on Monday evening, February 21, beginning at 7:30 PM.

    We will continue to explain how to write (generally, less simple!) formulas for the derivatives of functions which are defined in terms of (simple) formulas.

    Opening exercises

    FunctionIts derivative
    17x44+4sqrt(x)-9817·44x43+4(1/2)x-1/2+0
    Comment Hey, there are certain traditional ways to indicate some powers. "Sqrt" (or, better, the usual square root sign) means the half power and should be treated that way for differentiation purposes.
    44x44+9/x244·x43+9(-2)/x3
    Comment And another way powers of x can be written is with a division sign: /. So +9/x2 is "really" 9x-2 and that's the way we'll understand it for differentiation purposes.
         [-5+2x4]
    -------------------
     5x55+e(Pi)sqrt(2)]
    [0+2·4x3][55x55+e(Pi)sqrt(2)]-[-5+2x4][55·x54+0]
    -----------------------------------------------
                 [55x55+e(Pi)sqrt(2)]2
    Comment It can be easy to get lost in differentiating a quotient. And the other tricky thing here is to realize that the mess e(Pi)sqrt(2) is just a constant, and its derivative is 0.

    A quote
    L. Kronecker, a 19th century mathematician, declared that
    "God created the integers, all else is the work of man."
    This is the standard English statement. I searched on the web and I can't find the original German. I think this statement is relevant because, especially in what follows, we will see many coincidences which will make finding derivatives easy. These aren't coincidences. These computations have all be arranged over a few centuries by people so that other people will be able to compute more easily. So please: There are no coincidences! Everything has been prepared!!

    Sine
    In all this I cannot constantly review the geometry and algebra of the trig functions. This was done in a rapid way earlier in the course. Also I hope you will recall for computational examples the magical values of various trig functions. I tried to draw an accurate picture of sine and then discussed what properties the derivative of sine would have.


    Everything is arranged. Everything works out. What function has a graph which looks like the one drawn for the derivative of sine? Well, heck, we know such a function: cosine.

    The derivative of sine is cosine.

    In the textbook, something like the following is done when f(x)=sin(x):

     
     sin(x+h)-sin(x)     sin(x)cos(h)+sin(h)cos(x)-sin(x)
    ----------------- = ---------------------------------- = PIECE #1 + PIECE #2
            h                          h
    where
                       sin(h) 
    PIECE #1 = cos(x) --------
                         h
    and as h-->0 this --> cos(x)·1 because we arranged it this way when we decided to use radian measure! Also,
     
                       cos(h)-1 
    PIECE #2 = sin(x) ----------
                           h
    If we multiply this top and bottom by cos(h)+1, the result on top is [cos(h)]2-1 which is [sin(h)]2. Then
                        [sin(h)]2             sin(h)               1  
    PIECE #2 = sin(x) ------------- = sin(x) -------- sin(h) ------------
                       h [cos(h)+1]             h             [cos(h)+1]
    Now as h-->0, I claim:
                     sin(h)                         1
    sin(x)-->sin(x); ------ -->1;  sin(h)-->0; ----------- --> 1/2.
    Nothing happens!      h                       [cos(h)+1]
    
    So the result is sin(x)·1·0·1/2=0.
    Dont't worry. I believe this is the only time in the course I'll even write the addition formula for sine and you don't need to remember this. Any of this. It is just a bad dream.

    Cosine and the other guys
    You can play the same game with cosine as with sine. Here is an impression of what the picture might look like:

    If you look closely at the picture, there is a loose minus sign around. This we can't get rid of: I'm sorry.

    The derivative of cosine is -sine.

    There are the derivatives of other trig functions. Mostly I don't know these formulas. O.k.: I do remember the derivative of tangent:
    Since tan(x)=sin(x)/cos(x), I can use the Quotient Rule, and then tan´(x)=[cos(x)·cos(x)-sin(x)·{-sin(x)}]/[cos(x)]2. The top can be recognized (?) as cos(x)2+sin(x)2 which is 1. So the derivative of tangent is 1/[cos(x)]2. The book calls this [sec(x)]2.

    The derivative of tangent is secant squared.

    An example
    What is the equation of the line tangent to y=cos(x) when x=Pi/3? We need a point and a slope.
    Point Well, f(x)=cos(x), and cos(Pi/3)=1/2 (yes, this is one of the magical values you should know). Therefore the point (Pi/3,1/2) is on the graph, and the tangent line we're looking for goes through it.
    Slope If f(x)=cos(x), then f´(x)=-sin(x). This derivative gives the slope of the tangent line. So the specific slope we are looking for is -sin(Pi/3). This is -sqrt(3)/2 (more magic).
    The answer (y-1/2)=[-sqrt(3)/2](x-Pi/3).
    Please notice that the picture "confirms" a negative slope on the tangent line.

    Another example so students could do some work!
    I asked what the graph of y=sin(x)+cos(x) looked like and glared at the students menacingly. I also asked, yet again, what century we were in. After what seemed like a long, l-o-n-g, l--o--n--g time to me, some people got the idea and decided to use their graphing calculators. I expected, I hoped, I wanted people to get a picture similar to the one displayed to the right, which was done by a machine.

    Question What is the point on the top of the first bump?
    Well, the bump's top has a horizontal tangent, an x where f´(x)=0. So let's compute this derivative. If f(x)=sin(x)+cos(x), then f´(x)=cos(x)-sin(x). Where is this equal to 0? Well, then cos(x)-sin(x)=0 or cos(x)=sin(x) or (dividing by cosine) we get tan(x)=1. Hey: yet another magic value! (Is that happiness?) Well, if tan(x)=1 then x=Pi/4. But what is that point? To answer that we need to figure our the coordinates, an ordered pair, of the point. The bump is on y=sin(x)+cos(x). So we need to "stuff in" x=Pi/4 into the original function, sin(x)+cos(x). The value we get is sin(Pi/4)+cos(Pi/4), and (magic, magic ...) this is 2/sqrt(2) or just sqrt(2). The coordinates of the bump are (Pi/4,sqrt(2)). This does look approximately correct on the graph.

    Exp
    Well, if f(x)=ex, then f(x+h)=ex+h. Now look:

     f(x+h)-f(x)     ex+h-ex     exeh-ex        eh-1
    ------------- = -------- = --------- = ex ------
          h            h          h              h
    But we chose the number e exactly so that as h-->0, [eh-1]/h-->1. This makes things much easier.

    The derivative of the exponential function is the exponential function: (ex=ex.

    So (yawn) the 37th derivative of ex is ex. So ex, called the exponential function, should truly be the favorite function of the lazy individual.

    Flipping exp to get ln

    Suppose we look at y=ex. On this graph is a point whose coordinates are, not surprisingly, (x,ex). There's a line tangent to y=ex at this point, and this line has slope ex since we previously arranged all this. The slope is OPPOSITE/ADJACENT because slope is a tangent of an angle.

    Now ... here's the hard or amusing or whatever idea: take this picture: coordinate axes, curve, tangent line, and flip it: pick the picture up and flip it over the diagonal line y=x. The coordinate axes get interchanged. The exponential curve gets changed to another curve which we will identify. The tangent line is flipped but still remains tangent to the flipped curve. Algebraically, what we are doing is exchanging the first and second coordinates of each point. So the point (x,ex) becomes (ex,x). Hey: if the ex is a new variable, say, w, then since w=ex, ln(w)=x, and the flipped point (ex,x) wonderfully becomes the point (w,ln(w)). The tangent line's slope flips (because ADJACENT and OPPOSITE get interchanged). The flipped line's slope is 1/ex which is 1/w in terms of w. Hey: the slope of the tangent line is the derivative.

    The derivative of the natural log function, ln(x), is 1/x: (ln(x)=1/x.

    An example
    Find the equation of a line tangent to y=3ln(x)-x when x=e. Now f(x)=3ln(x)-x. Since f(e)=3ln(e)-e=3-e. The tangent line goes through the point (e,3-e). The slope of the tangent line comes from the derivative. Now f´(x)=3(1/x)-1 (I am using the differentiation rules and the derivative fact stated above). Therefore the slope is f´(e)=[3/e]-1 and an equation for the tangent line is (y-[3-e])={[3/e]-1}(x-e).

    Yet another picture request
    I asked what the graph of y=xex looked like. Here some people had learned and took out their calculators. Although I really like these electronic helpers, I will also admit that they need to be used with some care.

    Here's a picture of y=xex with both x and y in the interval -20 to 20. It is difficult to see much "fine structure" at this scale. I guess (for my purposes) this is a bad picture.
    Now this is a picture of y=xex with both x and y in the interval -3 to 3. In this picture the curve, which goes through the point (0,0), has a sort of bump in the third quadrant.
    The "correct scale" to look at a curve is not always clear, and this can be a problem both in classroom examples and in real-life applications. Experiments may be necessary.

    QotD
    Use calculus to find the exact coordinates of the bump on the graph of y=xex.

    What should you have gotten out of this lecture?
    There's lots of stuff here. But let's cut to the chase, the bottom line, summarize, winterize, whatever ... what should you remember?

    First, remember this:
    FunctionDerivative
    sin(x)cos(x)
    cos(x)-sin(x)
    tan(x)(sec(x))2
    exex
    ln(x)1/x
    Comment If you really need the derivative of secant (and this to me is very unlikely outside of a calculus course!), you can look it up or, heck, since secant=1/cosine, use the quotient rule: sec´(x)=[0·cos(x)-1·(-sin(x))]/(cos(x))2 which is sec(x)tan(x) as books would tell you.

    And really remember this:
    If curve looks like:then the derivative is
    Tangent lines go up
    Tangent slopes are positive
    Derivative is positive
    Tangent lines go down
    Tangent slopes are negative
    Derivative is negative
    If the top is round ("differentiable")
    then the tangent line is flat
    Derivative is zero
    If the bottom is round ("differentiable")
    then the tangent line is flat
    Derivative is zero
    Comment This is what I'd like you to take from this lecture's discussion. These are extremely important qualitative properties of derivative. This is what people use in practice. I don't think many veterinarians or financial analysts need to compute tangent lines to sec(x), but many of these people must work with graphs and with data: when do these things increase, decrease, have maxima ("tops") and have minima ("bottoms"). This is the important stuff!

    HOMEWORK
    Please read the assigned sections of chapter 3 and do the suggested homework problems Students should also look at the review material for the first exam. The Thursday recitation will include a short quiz on differentiation of formulas. Please hand in these problems:
    3.2: 37, 43
    3.3: 52, 54


    Friday, February 11: this is lecture 8

    Here is the official definition of derivative:

      lim   f(x+h)-f(x)
     h-->0 ------------ = f´(x)
                 h

    Hey: I am aware that in the text h is usually written x, but I find that sometime confusing. It is supposed to indicate a small amount of x, but the writing of two symbols is sort of weird.

    The derivative is supposed to indicate the slope of a non-vertical tangent line. Geometrically, you should be able to "see" this, especially with the help of a graphing calculator and zooming in on the suggested point of tangency. Here are some pictures which might help.

    After a few zooms, the graph of the function should look more and more like a straight line through (x,f(x)), and the straight line will have slope equal to f´(x).

    How to recognize from the graph whether the derivative exists
    Pick a point on the graph to investigate. Zoom in, and zoom in, and zoom in. If what you get does not look like a (non-vertical) line, that the derviative does not exist: the function is not differentiable at that point.

    An example: absolute value
    I hope that the graph of f(x)=|x|, the absolute value function, is slightly familiar to you. It is a big V. Officially from the algebraic side, absolute value is a piecewise -defined function, but I am interested here in pictures. The point of interest on the graph of |x| is (0,0). If you zoom in on it, the graph looks just the same: it is still a V. It never "straightens out" into a line. So this function is not differentiable at x=0. The textboook verifies algebraically that the limit defining the derivative does not exist at x=0 ifyou prefer that approach. You should see, I hope, that for non-zero x's, |x| is differentiable. Actually the derivative is 1 for x>0 and is -1 for x<0.

    This is not such a weird example. The continuous tax functions we discussed in the second lecture have exactly the same problems. So Schedule X of form 1040 is continuous, but not differentiable. Indeed, the behavior of absolute value under magnification occurs in a variety of biological applications (the idea is that this picture is what's called scale-free: it occurs at any length).

    A problem
    To the right is drawn a portion of the graph of y=f(x). Five points on the graph are labeled: A, B, C, D, E. Here are some questions about the function. My answers are below. Please try to get your answers without looking at mine. Answers should have some reasoning supporting them. Questions

    Some answers

    As I remarked in class, I am filled now with trepidation, which was accurately defined by a student as worry, fear, concern. The algebraic density of the course is about to increase abruptly. You'll need to practice what we'll discuss a great deal. I will tell you how to find the derivative of many functions which are defined by simple algebraic formulas. I will not cover everything in the syllabus scheduled for today!

    What's the derivative of ...
    A wonderful aspect of our intelligence is pattern recognition. But certainly we need to train ourselves when we see new things. So here are some new things.

    ... x7
    Now [f(x+h)-f(x)]/h is [(x+h)7-x7]/h. What can we do? I guess I could multiply out the (x+h)7 but I prefer to be a bit more lazy. I'll think about it:
         seven times
    (x+h)(x+h)···(x+h)
    Now one thing I certainly get from this product of sums, by selecting the x term from each of them, is an x7. What else can I get? Since I've already taken the product with all of the x's, the other terms will have at least one h. For example, I could select the h in the first partentheses, and then x's from all the others: this gets me hx6. But I could get something similar by selecting one h from the second term and x's from the first and all the others. In fact, I can select one h seven ways. So I will get 7hx6. I'm not done yet, of course (if you know the Binomial Theorem, you can see the rest of the swamp). I don't want to write all of the other terms. I do know that there will be at least two h's in all the rest. So in fact, here is what I will write:
    (x+h)7=x7+7hx6+h2JUNK
    It will turn out that the term I called JUNK doesn't matter very much. Why is that? Well, I want to understand the behavior of [(x+h)7-x7]/h as h-->0? So that is:

     x7+7hx6+h2JUNK-x7    7hx6+h2JUNK
    ------------------ = ------------ = 7x6+hJUNK
            h                 h
    
    First the x7's cancel, and then the h's drop out. Now we can see that as h-->0, this easily -->7x6.
    The derivative of x7 is 7x6.

    The derivative of xn is nxn-1

    ... x7+x32
    Now [f(x+h)-f(x)]/h is [(x+h)7+(x+h)32-(x7+x32]/h. What should we do? Always first try to be lazy. Look:

     [(x+h)7+(x+h)32-(x7+x32)]    [(x+h)7-x7]+[(x+h)32-x32]
    -------------------------- = -------------------------
               h                              h
    
    Now stop writing and starting thinking. There are two pieces to this, and one you should recognize, because we just analyzed it. It comes from the definition of derivative applied to x7. The other piece comes from the definition of derivative applied to x32. I bet that after acres of algebraic manipulation, the result will be the sum, that is, 7x6+32x31. This is actually correct. You might worry, though, about whether algebraic manipulation can be measured in acres. I am not sure.

    If f(x) has derivative f´(x) and g(x) has derivative g´(x), then the derivative of f(x)+g(x) is f´(x)+g´(x)

    ... products?
    The situation with regard to products is much more subtle, and I tried to motivate the answer by looking at some invented economic data.

    CategoryThis yearNext year
    Cars per househould
    in the U.S.
    2.22.3
    Number of households
    in the U.S.
    93 million95 million

    Again I mention that this is invented data, but is similar to what people really do count and worry about.
    Question #1 How many cars are there in the U.S. this year?
    This is easy. How about just (2.2)·(93 million), whatever this is?
    Question #2 How many cars will there be next year in the U.S.?
    Well, I guess I could do a similar direct computation, which would give (2.3)·(95 million) as the answer. But let me try a more challenging question, which may seem a bit silly to you. Suppose that we forecast an increase in cars per household of .1, starting from a base of 2.2 cars per household. And we forecast an increase in the number of households of 2 million, starting from "today's" 93 million. What increase in number of cars could we approximately predict using these numbers?
    Well, each household in existence would have .1 more cars (yes, these are silly numbers) so that we would have at least (.1)·(93 million) more cars. And each of the new households would have to get cars, so that means we'd need, hey, at least (2.2)·(2 million) more cars for that reason. I guess that the approximate number of additional cars would be
    (.1)·(93 million)+(2.2)·(2 million)=9.3+4.4=13.7 million cars
    If we compare the additional number of cars that the direct computations imply, we would have:
    (2.3)·(95 million)-(2.2)·(93 million)=218.5-204.6=13.9 million
    This is fairly subtle, but I hope that you see that the number of additional cars is almost all due to the (change in number of cars)·(original number of households)+(original number of cars)·(change in number of households). This sort of tells you why the derivative of a product of two functions is more interesting than one might suspect. The algebraic proof of the following result is in the text:

    If f(x) has derivative f´(x) and g(x) has derivative g´(x), then the derivative of f(x)·g(x) is f´(x)·g(x)+f(x)·g´(x)

    If you still think this is too complicated, a simpler example may convince you that the complexity is needed. The derivative of x5 is 5x4. But x5=x2·x3. Now x2 has derivative 2x and x3 has derivative 3x2. How can we construct 5x4 out of x2 and 2x and x3 and 3x2? Well, the product rule (that's the name of the result above) does the construction correctly:
    5x4=2x·x3+x2middot;3x2.

    ... 17
    If f(x)=17 for all x, then [f(x+h)-f(x)]/h is ... uhhhh ... 0. This is almost embarrassing. The derivative of the function which is always 17 is 0 always. (Well, the tangent line is horizontal!)

    The derivative of a constant is 0.

    ... 17x7
    We could apply the product rule to computing the derivative of 17x7, and the result would be 0·x7+17·7x6. This sort of thing arises so frequently (in, for example, polynomials) that we should note it.

    If k is a constant and f(x) is a differentiable function with derivative f´(x), then the derivative of kf(x) is kf´(x).

    Many derivatives
    If f(x)=5x8-9x2+38, then f´(x)=5·8x7-9·2x+0. Wow! So f´(x)=40x7-18x. We can take a derivative of this derivative, and get f´´(x)=40·7x6-18=280x6-18. And even another (here people mostly use a different notation) to get f(3)(x)=280·6x5. Etc. Well, etc. except that I can tell you that the 50th derivative of f(x) is 0. Can you see why?

    The quotient rule, which describes the derivative of a quotient of differentiable functions, is almost silly, and it is complicated. Here it is:

    If f(x) has derivative f´(x) and g(x) has derivative g´(x), then the derivative of f(x)/g(x) is [f´(x)·g(x)-f(x)·g´(x)]/(g(x))2

    The derivative of (3x-7)/(4x2+2) is therefore
    [3·(4x2+2)-(3x-7)(8x)]/(4x2+2)2. We could find the second derivative and the third, but things would get increasingly messy, very, very messy. The opportunity for error would get large.

    An equation for a tangent line
    Suppose that f(x) and g(x) are differentiable functions, and the following is known:
    f(1)=2, f´(1)=3, g(1)=5, and g´(1)=-2.
    What is an equation of the line tangent to the graph of y=f(x)g(x) when x=1?
    Since f(1)g(1)=10, the tangent line goes through the point (1,10). And the derviative of f(x)g(x) at x=1 is f´(1)g(1)+f(1)g´(1)=3(5)+2(-2)=11. So the slope of the tangent line is 11. The equation therefore must be:
    (y-10)=11(x-1).

    QotD
    Use the same data, and find an equation of the line tangent to the graph of y=f(x)/g(x) when x=1?
    Now when x=1, y=f(1)/g(1)=2/5. And the derivative of f(x)/g(x) when x=1 is [f´(1)g(1)-f(1)g´(1)]/[g(1)]2, which is [3(5)-2(-2)]/52=19/25. So an equation for the tangent line is (y-[2/5])=[19/25](x-1).

    HOMEWORK
    Keep up! There's an exam coming!


    Maintained by greenfie@math.rutgers.edu and last modified 2/13/2005.