Professional Documents
Culture Documents
Diff Calc Notes Inc
Diff Calc Notes Inc
DIFFERENTIAL CALCULUS
WORKBOOK
Leo Jonker
Queens University
Fall 2007-2008
Foreword
Most of the students entering in rst year engineering at Queens University have taken dierential Calculus in High School. This applies to students who have graduated from Ontario high schools, those who have had
some CEGEP education in Quebec, all Alberta Students (assuming they took
mathematics 31 in their nal high school year), and some British Columbia
and Saskatchewan students, . Most of the students coming from outside
Canada have also had some Calculus before they get here. A smaller number,
including most of those who come from schools in the Maritime provinces,
and those coming from Manitoba have not had any signicant amount of
calculus. This should not worry you. You are probably better prepared in
other ways, but it does meant that you will need some extra help at the
beginning of rst year.
We would like our rst year calculus course to make use of the more advanced
preparation of some students, without creating a situation that is impossible
for those students for whom Calculus is a completely new experience. These
notes are intended to prepare all students for APSC 171, Calculus I.
In them we will introduce students to dierential calculus in a highly intuitive fashion, one that will, we think, t well with the tenor of the rest of the
course. We will introduce the idea of the derivative, discover formulas for
the derivatives of polynomial functions, the exponential functions, and logarithmic functions, and we will discuss basic rules for calculating derivatives
of combinations of functions (the Product Rule, Quotient Rule and Chain
Rule).
This is a set of (deliberately) incomplete notes prepared for your use. The
notes reect the way in which the material should be learned. The intro-
ii
duction to each topic is concise, but complete. You should be able to read
and understand it. At certain points the ow of thought in interrupted by
a question for which the answer is not provided. If the notes are used in
a class, this is where the instructor will ask you to become involved in the
completion of the argument. If the notes are used as self-study, then this is
where you try to make sense of the question. When you get stuck you can
consult James Stewart, Calculus: Early Transcendentals, the text for the
course, or any Calculus book that may be available to you. At other times,
the gaps in the notes follow problems in which the theory you have learned
can be applied. These, too, are for you to ll in. Some of these problems are
indicated as Concept Questions. These are multiple-choice questions that
signal points at which key concepts are often misunderstood or misapplied.
They have short answers, but do require some thought.
Computer assisted learning
There are also some computer-based learning objects designed specically
for the course, and written a few years ago by Thomas Norman, a former
student in Mathematics and Engineering. These are small interactive computer programmes to help you learn the concepts behind a topic. Whenever
a topic has one of these learning objects associated with it, this is indicated
in the interactive notes as follows:
Computer help for this topic is available on the course website
To nd these learning objects, go to the course website and click on Computer assistance in the column on the left.
Contents
What is a derivative really? . . . . . . . . . . . . . . . . . . . . . .
Rates of Change
(Sections 2.7 and 2.9 in Stewart)
. . . . . . . . . . . . . . . . 10
. . . . . . . . . . . . . . . . . . . . . 30
Inverse Functions
(Section 1.6 in Stewart)
. . . . . . . . . . . . . . . . . . . . . 35
Logarithmic Functions
(Section 1.6 in Stewart)
. . . . . . . . . . . . . . . . . . . . . 43
. . . . . . . . . . . . . . . . . . . . . 48
iii
iv
CONTENTS
This means that if you try successive input values, equally spaced and very
close to each other, the output values seem to go up at a constant rate. Here
are two examples:
Consider the function f (x) = x2 . We know this function is not linear (its
graph is not a straight line), and yet, look at the following table of (a few)
values of this function:
x
3.000
3.001
3.002
3.003
x2
9.000
9.006
9.012
9.018
It sure looks linear on this small scale! So does the following table of some
values of the function f (x) = ex :
x
1.000
1.001
1.002
1.003
ex
2.71828
2.72100
2.72372
2.72644
In each case the output goes up by 0.00272 when the input goes up by 0.001;
so once again, this function looks linear when you get close.
This property of looking linear when you zoom in to a point becomes
visual when you apply it to the graph of a function. Here are three pictures,
produced by Maple, of the graph of the exponential function ex at smaller
and smaller scales around the point x = 1:
CONTENTS
3.2
3.6
3.1
3
3.2
2.9
y4
2.8
2.8
2.7
2
2.6
2.4
2.5
0
0
0.5
1
x
1.5
0.8
0.9
1
x
1.1
1.2
0.9
0.95
1.05
1.1
This property that makes graphs look linear when observed on a small scale,
is closely related to the fact that when we look around us, the earth looks
more or less at. We can, perhaps, forgive our distant ancestors for thinking
that it really was at.
Of course, as with all simplications, there is a caveat. The secret is not
quite true of all functions. If the graph of your function has a corner at some
point, as in the case of f (x) = |x|, no amount of zooming in is going to make
that corner go away. A function that looks linear when you zoom in to a
point on its graph is called a dierentiable function. Fortunately most
of the functions we deal with are dierentiable, or else are dierentiable at
most points.
Eventually we should turn our observation about the local linearity of functions into something we can do mathematics with. In particular, the insight
should help us do certain kinds of calculations.
Before we get to that, however, there is a second secret at the heart of
Calculus, which has a lot to do with the one we revealed at the start of this
chapter, even though it may seem quite unlike it:
If a quantity is very small, then its square 2 is negligible by comparison.
5
5+
3
3
2
+
2.
2
3. 5 + 5
1.
7
7
2
+
13
5.
13
4.
A. Equation 3.
B. Equation 5.
C. Equations 1 and 3.
D. Equations 1, 3, and 4.
E. All of the equations.
CONTENTS
explain why this function will seem linear if we stay very close to any given
initial point. Say we start at x = a, and examine what happens to f (x) when
x is replaced by a + x, where x represents a very small number. That is,
we want to see how the value of this function changes as x changes, but is
kept very small. Then
f (a + x) = (a + x)2 = a2 + 2ax + (x)2 .
By the secret on page 2, we can ignore (x)2 for all practical purposes, as
long as x stays very small. Thus
f (a + x) a2 + 2ax .
Notice that if we think of x as a variable (and keep a constant), the right
side is a linear function g(a + x) = a2 + 2ax. Notice that we do not want
to say
f (a + x) a2 + 2ax a2 ,
which is also true, though with a rougher approximation. The reason is, we
want to see what linear function f (a + x) resembles, so if there is a term of
rst degree in x we do not want to remove it, for it indicates the manner
in which the value of f (a + x) changes.
If we go back to writing x for a + x we get
g(x) = a2 + 2a(x a) ,
where, as we said already, f (x) and g(x) are extremely close to each other,
as long as x is very close to a. Notice that if we let x = a the two function
are precisely equal to each other.
Example 1. If we write down the equation of the graph of g we get y =
a2 + 2a(x a). Since a is kept constant, this is clearly the equation of a
line. Zooming in to the graph of f around the point (a, f (a)) is the same as
restricting x to values close to a. What do we call the line given by the graph
of g?
Click here for help
Notice, from the equation of the graph of g, that the tangent line to the
graph of f at (a, f (a)) has slope 2a. This slope is dened as the derivative
of f (x) = x2 at a.
The derivative of a function f at an input value a is the slope of the
tangent line to the graph of the function at the corresponding point
(a, f (a)) on the graph.
CONTENTS
A
B
CONTENTS
A polynomial function is just a sum of constant multiples of power functions. Suppose we have a polynomial
f (x) = c0 + c1 x + c2 x2 + + cn xn .
Then to nd the derivative f we could apply the same idea to all of the
terms at once: replace x by a + x. Then
f (a + x) = c0 + c1 (a + x) + c2 (a + x)2 + + cn (a + x)n
c0 + c1 (a + x) + c2 (a2 + 2ax + ) + + cn (an + nan1 x + ) ,
where the dots indicate terms that involve x to power 2 or higher, and
which can therefore be ignored relative to the lower order terms. Thus
f (a + x) c0 + c1 (a + x) + c2 (a2 + 2ax) + + cn (an + nan1 x)
= f (a) + (c1 + 2c2 a + 3c3 a2 ncn an1 )x .
If we extract the coecient in front of x, and then replace a by x we get
the derivative (the slope):
Notice that this says that to calculate the derivative of a polynomial you
should calculate the derivatives of the power functions in the terms, and then
combine the results in the way they were combined in the original polynomial.
Notice also that the derivative of a constant function is always 0 (see what
you get if all the coecients except c0 are equal to zero). The reason is that
the graph of a constant function is a horizontal line, and therefore the slope
is 0 at each point.
Example 4. For what values of x does the graph of f (x) = x4 8x3 + 22x2
24x + 3 have positive slope and for which values does it have negative slope?
Click here for help
10
CONTENTS
Rates of Change
(Sections 2.7 and 2.9 in Stewart)
NOTE: James Stewart: Calculus, Early Transcendentals 6e, is the textbook we will be using in the rst year Applied Science calculus
courses. However, you should be able to read these notes without
any reference text so there is no need to buy the book before you
arrive at Queens.
The most important characterization of a derivative is its ability to measure
instantaneous rate of change. Most of you have discussed rates of change
in high school, especially in cases when the function expresses distance (its
output) in terms of time (its input). If f is the function whose rate of change
we want to discuss, say at an input value a, then we might begin by taking
a value not too far from a, say a + x, and comparing the function values at
these inputs by subtracting f (a + x) f (a). This expresses a change in
the function value, but not yet a rate of change. To get that, you have to
compare this change in the output value of the function to the corresponding
change in the input. This comparison is achieved by division: The average
rate of change of the function f between inputs a and a + x is
f (a + x) f (a)
Average rate of change =
.
x
Sometimes it is convenient to give a name to the output of the function, say
y = f (x). Then the numerator in the above expression represents a change
in the y-value and can be denoted as y. That is, the average rate of change
is the ratio
y
.
x
f
y
x
a + x
RATES OF CHANGE
11
In the diagram, this average rate is equal to the slope of the line segment
joining the points (a, f (a)) and (a + x, f (a + x)). The line extending this
segment is sometimes referred to as a secant line. Now suppose we let x
get smaller and smaller. Then the point (a + x, f (a + x)) will gradually
slide (along the graph) towards (a, f (a)), and in the process the secant line
will turn (a little) and gradually converge to the tangent line, as in the next
picture:
a
On the one hand, the slope of this tangent line is what we mean by the
derivative f (a). On the other hand, this slope is what the slopes of the
secant lines get closer and closer to as we let x get smaller and smaller.
This idea is expressed as a limit:
f (a + x) f (a)
.
x0
x
f (a) = lim
This means that if, in the fractional expression on the right, you let x get
closer and closer to 0, then the value of that expression gets closer and closer
to f (a). In general, whenever we have any kind of expression E(u) that
depends on a variable u, then by the limit of E(u) as u c we mean the
quantity L that E(u) gets closer and closer to when u is allowed to get closer
and closer to c. The notation for this is
L = lim E(u) .
uc
12
CONTENTS
f (x) f (a)
.
xa
xa
f (a) = lim
dy
d
=
f (x) .
dx
dx
Let us see how this limit approach might work for the function f (x) = x2 :
The slope of the secant between (a, a2 ) and (a + x, (a + x)2 ) is
(a + x)2 a2
a2 + 2ax + (x)2 a2
2ax + (x)2
=
=
.
x
x
x
At this point we can either notice that we can disregard (x)2 because it is
so small in comparison to the other terms in the numerator, in which case
we conclude
2ax + (x)2
= 2a ,
f (a) =
x
or we can say, slightly more formally, that
2ax + (x)2
= lim (2a + x) = 2a .
x0
x0
x
f (a) = lim
Either way, we have conrmed the derivative calculation we did much earlier.
We saw earlier that the derivative of xn is nxn1 , for any positive integer n.
In fact this formula is valid even when n is not a positive integer, but any
xed real number. We do not have time to do all the proofs necessary to
show this, but we do have time to show it for two instances.
RATES OF CHANGE
13
x0
f (a + x) f (a)
.
x
What does the expression on the right look like for this function?
A.
B.
C.
lim
x0
lim
x0
lim
x0
1
a
+ x
x
1
a+x
1
a
1
a
x
(a + x) a
Click here for help
14
CONTENTS
x = x1/2 .
a + x a
A.
x
(a + x) a
B.
x
( a + x) a
C.
x
Click here for help
RATES OF CHANGE
15
We must take the limit of this expression as x 0. This does not look
simple, and may require some algebra to transform the expression:
Example 6. Find the limit of
the expression for the average rate of change
at a for the function f (x) = x.
Click here for help
A combination of similar techniques will show that the theorem for derivatives
of power functions,
d n
x = nxn1 ,
dx
16
CONTENTS
is true for any xed rational power n. In fact,as already pointed out, the
theorem is true for any xed real power whatsoever; but proving that requires
other methods.
e
(0.5)x
(1.5)x
1x
17
ea+x ea
=1
x0
x
B.
(e0 + ex ) e0
=1
x0
x
C.
ex 1
=1
x0
x
lim
lim
lim
d x
(e ) = ex
dx
In other words, at every point, the value of the function ex is precisely
equal to its rate of change.
If you have had some study of exponential growth in high school, this will
sound very familiar. When something grows exponentially, it means that the
rate at which a function increases is proportional to is value.
18
CONTENTS
19
The Constant Multiple Rule: If c is a constant and f is a dierentiable function, then so is cf , and
d
d
[cf (x)] = c f (x)
dx
dx
or, equivalently,
(cf ) = cf
Note that when we speak of the function cf we mean the function whose value
at an input x is equal to the product cf (x). If we evaluate this function at
a we get cf (a); if we evaluate it at a + x we get cf (a + x). Thus the
average rate of change of cf between a and a + x is
cf (a + x) cf (a)
.
x
This factors immediately to become
f (a + x) f (a)
.
x
To nd the derivative of cf we have to take the limit of this as x 0. But
since c is constant we can take the limit of the fraction and multiply by c
afterwards - it will come to the same thing (think about this!) Therefore
c
f (a + x) f (a)
= cf (a) .
x0
x
If now we replace a by x we have a proof of the theorem.
(cf ) (a) = c lim
20
CONTENTS
The next theorem tells us how to dierentiate the sum of two functions whose
derivatives we know already. Notice that it tells us to go ahead, dierentiate
each function, and add the results afterward.
The Sum Rule: If the functions f and g are both dierential, then so
is f + g, and
d
d
d
[f (x) + g(x)] =
f (x) + g(x)
dx
dx
dx
or, equivalently,
(f + g) = f + g
Notice that we have already seen instances illustrating the sum rule, for when
we dierentiated polynomials we found that it amounted to dierentiating
each of the polynomials terms separately and then adding (or subtracting)
them.
Concept Question 6. What is the correct expression for the average rate
of increase of the function f (x) + g(x) between a and a + x?
A.
B.
C.
21
We are now ready to prove the Sum Rule, by taking the limit of this expression as x 0:
(f (a + x) + g(a + x)) (f (a) + g(a))
x0
x
f (a + x) f (a) g(a + x) g(a)
+
= lim
x0
x
x
f (a + x) f (a)
g(a + x) g(a)
+ lim
= lim
x0
x0
x
x
(f + g) (a) =
lim
= f (a) + g (a) .
22
CONTENTS
(f g) = f g
Now that we know how to dierentiate the sum and the dierence of two
functions whose derivatives we already know, it is time to turn to their product. Here the product of f and g is thought of as a new function whose value,
at input x, is given by f (x)g(x). In other words,
(f g)(x) = f (x)g(x) .
23
(f g) = f g + gf
You are probably wondering why the formula is so complicated. This will
become clear when we look at the proof:
Example 10. Prove the Product Rule.
Click here for help
24
CONTENTS
25
Quotient Rule: If f and g are dierentiable functions, then the quotient function f /g is dierentiable at the points x where g(x) =
0; and
at those points,
d
d
[f (x)] f (x) dx
[g(x)]
g(x) dx
d f (x)
=
dx g(x)
[g(x)]2
or, equivalently,
f g g f
f
=
g
g2
Again, when we prove this theorem we will see why the Quotient Rule has
this strange form.
Example 11. Prove the Quotient Rule.
Click here for help
26
CONTENTS
27
ex
.
x2
x
x+1
28
CONTENTS
Example 14. Determine, from the expression we found for its derivative,
whether the graph has a low point, high point, or inection point at x = 1.
Click here for help
Here is a picture of this graph, generated using Maple by entering the command
> plot(sqrt(x)/(x+1), 0..2);
0.5
0.4
0.3
0.2
0.1
0
0
0.5
1
x
1.5
29
Example 15. (From Section 3.7 in Stewart) If a tank holds 5000 liters of
water, which drains from the bottom of the tank in 40 minutes, then Torricellis law give the volume V of the water remaining after t minutes as
2
t
V = 5000 1
0 t 40
40
Find the rate at which water is draining from the tank after 5 minutes, and
after 30 minutes.
Click here for help
30
CONTENTS
If you go to the course web site and click computer-assisted learning in the
column on the left, it will take you to MathQs a set of interactive learning
devices. One of these is on the topic of the chain rule. Try it out!
We have studied derivatives of constant multiples, sums, dierences, products
and quotients of functions. Another important way to combine functions is
through composition. If f and g are functions, the composite f g is the
function that for the input x gives the output f (g(x)). In other words,
(f g)(x) = f (g(x))
A. x + 1
2
x(x + 1)
B.
x2 + 1
C.
D. x x2 + 1
Click here for help
31
3
3 +5
and g(x) = x3 + 5
Click here for help
32
CONTENTS
The idea behind the chain rule is very simple. The following diagram illustrate this. Imagine starting at some initial input x, as illustrated on the left
of the diagram. The function g turns x into u, which f then turns into y.
Composing the two functions f and g is a little like building a box around
the two components f and g to make a new input-output machine called
F (dashed line in the diagram). Suppose we change x by a small amount x.
This produces a small change u in the output of g, where the relationship
between the two small changes is given (approximately) by the derivative:
u
g (x)
x
Since u is also the input to f , the small change u in its input in turn
produces a small change y in the output of f , again related to u by the
derivative of f :
y
f (u)
u
The derivative of F at x is (approximately) the ratio of the two small changes:
F (x)
produces
u
x
so,
g (x)
y u
y
=
x
u x
u = g(x)
produces
y
u
f (u)
33
y
f (g(x)) g (x) .
x
y
u
u
x
While the equations in this discussion are all in the form of approximate
y
y u
,
and
all represent average rates
equalities, in that the ratios
u x
x
of change, and therefore only approximate the instantaneous rates, these
approximations get better and better as x (and therefore also u) tend to
zero. In the limit, therefore the equality becomes an exact equality combining
derivatives.
y
Notice that lim
represents the derivative of f at u = g(x); that is, it
u0 u
is equal to f (u) = f (g(x)). This accounts for the form of the rst factor in
the formula for the chain rule:
F (x) = f (g(x))g (x)
Example 16. Calculate the derivative of
x2 + 1
34
CONTENTS
3 +5
2 +3x+8)7
INVERSE FUNCTIONS
35
Inverse Functions
(Section 1.6 in Stewart)
Our next goal and nal goal in this short introduction to derivatives is to
present the formulas for the derivatives of logarithmic functions. In order
to do this we have included a brief review of the theory of inverse functions
(this section) followed by the denition of logarithmic functions (the next
section), before we discuss their derivatives in the last section.
Note the following indication that there is computer help for this topic on the
course web site. This computer help is interactive and designed not only to
test whether you remember the facts about inverse functions, but also to help
you understand them.
Computer help for this topic is available on the course website
A function f is one-to-one if no two inputs (values in its domain) have the
same output (values in its range). The following graphs illustrate this.
y
f (x)
x1
Not one-to-one
x2
The graph shows that the points x1 and x2 produce the same output
(i.e. f (x1 ) = f (x2 )), therefore the function f (x) is not one-to-one. We can
geometrically check to see if a function is one-to-one if no horizontal line
intersects the graph of the function at more than one point.
36
CONTENTS
y
g(x)
One-to-one
x
satises horizontal line test
The graph of g(x) illustrates that there are no two distinct points in its
domain that produce the same output (i.e. g(x1 ) = g(x2 ), whenever x1 = x2 ).
Suppose we have a function f with domain D and range R. We want to look
for a function g that undoes what f does. If such a function g exists for
f , then it is called the inverse of f . In symbols this can be written as
g(y) = x f (x) = y.
This can be illustrated with the following diagram:
R
x
Then
g(f (x)) = x,
and
f (g(x)) = x.
INVERSE FUNCTIONS
37
38
CONTENTS
Example 19. Suppose f (x) = 1/x, then what is its inverse g(x)?
Click here for help
B. It has no inverse
C. g(x) = x2
Click here for help
INVERSE FUNCTIONS
39
N2 + 3H2 2NH3 .
If the reaction is started with the concentration of hydrogen (in moles per
litre) three times as high as the concentration of nitrogen, then the amount
of ammonia (in moles) produced after t minutes is given by the formula
A(t) = 2
1
1
83
,
+ kt
40
CONTENTS
INVERSE FUNCTIONS
41
y1
x1
Example 21. Sketch the graph of the inverse of f on the axes given above.
Click here for help
42
CONTENTS
Usually we write f 1 , rather than g, for the inverse. Note that this means
that f 1 (x) is not the same as (f (x))1 ! The former is the inverse function
applied to x, while the latter is the reciprocal of f (x).
To understand the eect of the inverse function g of a function f whose
graph is before you, you do not have to reect the graph of f to produce the
graph of g! The eect of the function f is shown by going from a point x1
on the horizontal axis via a vertical line to the graph of f , and then moving
horizontally towards the vertical axis, reaching it at y1 = f (x1 ). The eect of
g is seen on the same picture (without drawing the graph of g) by reversing
this procedure: start at a point y1 , then travel horizontally to the graph of
f and then vertically to reach the horizontal axis at x1 = g(y1).
LOGARITHMIC FUNCTIONS
43
Logarithmic Functions
(Section 1.6 in Stewart)
One of the most important applications of the theory of inverse functions is
the introduction of Logarithmic Functions.
From its graph we know that ax (a > 1) is increasing, and therefore has an
inverse. The inverse of the function ax is the logarithm to the base a,
loga (x).
Recall the relationship between a function f and its inverse g. We expressed
it in three dierent but equivalent ways:
g(y) = x f (x) = y ,
g(f (x)) = x ,
f (g(x)) = x .
Concept Question 11. Let f (x) = ax and g(x) = loga (x). Which of the
following statements is true? ( means if and only if )
[i. ] loga (y) = x ax = y
[ii. ] a(loga )x = x
44
CONTENTS
y
ax
loga x
1
x
1
= y loga (x).
You might say that logarithms turn products into sums, quotients into differences and powers into products. These laws are a direct consequence of
the laws of exponents on page 57 in the textbook. MAKE SURE YOU
KNOW THESE LAWS VERY WELL.
LOGARITHMIC FUNCTIONS
45
46
CONTENTS
ln ex = x;
eln x = x
ln(e) = 1.
x2
x1
= 1 + ln
x3
x1
LOGARITHMIC FUNCTIONS
47
48
CONTENTS
49
d
dx
ln |x|.
50
CONTENTS