Overview: Differential Calculus
Overview: Differential Calculus
1. The Derivative
2. Limits
4. Rules of Differentiation
5. Monotonicity
7. Extrema
If you think you've already mastered the content of this chapter, you can proceed directly to the Final
Exam.
3
Learning Goals
▪ To be able to calculate the derivative of a function with the help of the limits of difference
quotients (Section 1).
▪ To understand the relationship between the derivative of a function and the slope of the
tangent of its graph. To understand the derivative of a function as the instantaneous rate of
change of the function (Section 1).
▪ To be able to determine the limit of a function at a point, as well as the left-handed and right-
handed limits at that point. To be able to understand the behaviour of a function at infinity as
well as calculate its asymptotes (Abschnitt 2).
▪ To be able to use the rules of differentiation (constant rule, sum rule, product rule, chain rule)
(Section 4).
▪ To be able to determine the qualitative behaviour of the graph of the derivative of a function
by looking at the graph of the function, and vice versa (Section 5).
▪ To understand the concavity of a function with the help of the second derivative (Section 6).
▪ To be able to calculate the inflection points and saddle points of a function (Section 6).
▪ To become familiar with the terms extremum, maximum, and minimum. To use the
necessary criterium for a function to have an extremum, as well as the sufficient critieria for a
maximum or minimum with respect to the first and second derivatives. To be able to
calculate the extrema of a function, what type of extrema they are, and how to sketch the
graph of a function (Section 7).
Summary
In this chapter you will learn about the derivative of a function. You will learn to understand the
derivative at a point as the slope of the tangent of the graph at that point, as well as how to use
difference quotients. You will find out how to calculate the derivative of a function, and how to
deal with important features of functions such as monotonicity, concavity, extrema, inflection
points, and saddle points all with the help of the first and second derivative.
4
General Notation
The left- and right-handed limits of a function f at a point x0 are denoted respectively by
f (x + h) − f (x)
′
f (x) = lim .
h→0 h
f (x + h) − f (x)
as h approaches 0.
5
1. THE DERIVATIVE
6
Table of Contents
1.1 The Derivative as the Slope of the Tangent
1.2 The Derivative as the Rate of Change
1.3 The Derivative as a Linear Approximation
Learning Goals
In this section you will learn about the idea of a derivative and the relationship between the
derivative of a function and the slope of its tangent on its graph. You will also learn to think of the
derivative as the instantaneous rate of change of a function.
The concept of the derivative of a function f (x) at a point x0 and what the general idea entails will be
discussed and then expanded upon in detail. Mathematic precision is unfortunately not a possibility in the
scope of this course since the exact idea of limits isn't available. In general, such exacting precision isn't
necessary in high school mathematics. The idea of a derivative can still be described in enough detail to be
used in very interesting and useful applications while still remaining in the scope of this course. Calculus
has been used in such ways for hundreds of years without needing such precision, like in determining the
orbits of planets, for example.
In order to visualize a function f (x) we normally consider its graph. Using graphs we can describe the idea
of a derivative as follows: The derivative of the function f (x) at a point x0 is the slope of the tangent at the
point on the graph with coordinates P = (x0, f (x0)) .
Warning: The tangent of a graph doesn't necessarily exist at all points on the graph. In order to understand
this better, we need to further analyze the idea of the tangent of a graph at a point P = (x0, f (x0)) . To do
so, we'll consider the graph of f (x), a fixed point P , a moveable point near P called Q:
Q = (x, f (x)) = (x0 + h, f (x0 + h)) , and the line through P and Q called a secant line. Now if we let
Q move in a free manner in the neighbourhood of P (letting h tend to 0) we'll consider the behaviour of
the secant line. In many cases, the position of the secant approximates the end position (when h is at 0)
independently of how we move the point Q. In such cases we call the result of this limiting process the
tangent line or simply the tangent of f (x) at a point P .
In the following applet the function being visualized is f (x)
P = (x0, f (x0)) = (1, 1)
value 1.
The tangent at the point P
−1
in order to vary x
If P
point P
= Q
−0.5
, i.e. h
1.5
0.5
−0.5
−1
−1.5
= x
= 0
1
2
− x
= x0 + h = 1+0.5
+ 1
1
P
x0
– o
1.5
, fixed point: P
Use the mouse to move around the black point along the x-axis
←
2
↓ ↑ →
= x
2
∣
x + 1
The following second visualization deals with an exception: a point where there is no tangent to the graph
and hence no derivative. Here, again we'll consider the function f (x)
= (x0, f (x0)) = (0,1)
= x
2
and
yourself that there is a tangent of f at the point P and that the derivative (the slope of the tangent) has the
1.5
P
1
0.5
−0.5
−1
−1.5
– o + ← ↓ ↑ →
Like in the first visualization, if the secant line gets closer to the tangent, and hence the slope of the secant
approaches the slope of the tangent, we call f differentiable at x0.
1.1 DEFINITION
f is called differentiable at x0 if there exists a unique c ∈ R such that the slope of the secant
f (x0 + h) − f (x0)
(h ≠ 0)
h
(1.1)
′
c =: f (x0).
1.2 THEOREM
′
T (x) = f (x0) ⋅ (x − x0) + f (x0).
Up until now we've understood differentiability at a point x0 via the slope of secant. In order to calculate
′
f (x0) this visualization isn't very necessary. Now we'll learn an analogous but more abstract way to define
differentiability.
1.3 DEFINITION
f (x0 + h) − f (x0)
lim .
h→0 h
f (x0 + h) − f (x0)
′
f (x0) = lim .
h→0 h
Up until now we've spoken about a function approaching something. If we say that an expression
f (x) approaches a when we let x get closer to x0, then we write
lim f (x) = a.
x→x0
In such cases, f (x) can get arbitrarily close to a depending on how close x gets to x0.
lim f (x) = a mathematically means that up to any tolerance ε > 0 there exists a region
x→x0
(x0 − δ, x0 + δ) with δ ε
= δ( ) > 0 so that
for all x in the interval (x0 − δ, x0 + δ) where x ≠ x0. This means that f (x) can't vary in value
around a more than ε, if x ≠ x0 doesn't vary by more than δ around x0. The number a is called the
limit.
12
13
1.4 EXAMPLE
f (x0+h)−f (x0)
The difference quotient is then Q(h) =
h
= 2 . Since Q(h) = 2 is constant,
Q(h) goes to 2 as h goes to 0. This means that f is differentiable at any point x0 and
′
f (x0) = 2 .
2. Let f (x) = |x| be the absolute value function: f (x) = x for x ≥ 0 and f (x) = −x for
x < 0 . If h > 0 then f (h) = h, hence f (0 + h) − f (0) = h and Q(h) = 1 .
If we look back to (1.1), the idea of a number c comes into question. If we consider h < 0
then we can see that beacuse f (0 + h) − f (0) = −h and Q(h) = −1 , the value of c for
h < 0 is c = −1 ; for h > 0 c = 1. We can't find a unique c for Q(h) as h approaches 0,
and hence f is not differentiable at 0.
14
1.5 DEFINITION
If a function f is differentiable at every point of its domain we call f differentiable. In this case,
since the function f has a derivative f ′(x) at every point in its domain, we can think of f ′ as a
function that gives us the derivative of the function f at any point x0.
1.6 REMARK
1. The derivative will be denoted as the first derivative in order to distinguish it from higher
derivatives (such as the second derivative, introduced later on).
2. Because f ′(x0) is also the limit of the difference quotient, instead of writing f ′(x0) we
df df
sometimes write dx
. Instead of f ′ we can also write
(x0)
dx
if f is dependent on x.
Δy
3. The derivative f ′(x0) is sometimes written lim
Δx
. In this case Δx = h and
Δx→0
f (y) − f (x)
′
f (x) = lim .
y→x y − x
15
One further example is the distance travelled by someone walking. If we start a clock at time t = 0 and let
the distance travelled up to the time t ≥ 0 be denoted by x(t).
x(t+h)−x(t)
In the time interval from the time point t to t + h the average velocity is h
. If we let h get
smaller and smaller (approaching zero), then this average velocity becomes a better approximation for the
instantaneous velocity at a time point t. The instantaneous velocity is often denoted by v(t), hence we
have:
x(t + h) − x(t)
′
v(t) = lim = x (t).
h→0 h
The instantaneous velocity of x(t) corresponds to the velocity v(t), in that v(t) ′
= x (t) .
A special notation is sometimes used for time-dependent variables: instead of writing a vertical dash for
the derivative, we write a dot above the function: ẋ(t) instead of x′(t).
f (x0 + h) − f (x0)
lim = c.
h→0 h
f (x0 + h) − f (x0)
− c =: R(h)
h
f (x0 + h) − f (x0)
= c + R(h), (1.2)
h
and
lim R(h) = 0.
h→0
and hence
1.7 DEFINITION
with
lim R(h) = 0.
h→0
′
c =: f (x0).
EXERCISE 1
19
Calculate the derivative of the function f (x) 2
= x + 2x + 1 at the point x = 1 by determining the
difference quotient.
Answer
′
f (1) = 4
20
Solution
f (1 + h) − f (1)
′
f (1) = lim
h→0 h
f (1 + h) − f (1)
for h ,
∈ R h ≠ 0 .
Step 2:
2 2
f (1+h)−f (1) (1+h) +2(1+h)+1−(1 +2+1)
=
h h
2
1+2h+h +2+2h+1−4
=
h
2
h +4h
=
h
= h + 4
lim h + 4 = 4
h→0
So f ′(1) = 4 .
21
EXERCISE 2
22
Let f (x) = x
3
+ 2 . Calculate the slope of the tangent T (x) on the graph of f at the point (−1, f (−1)),
and specify the equation of T (x).
Answer
Solution
3 3 2 3
f (−1 + h) − f (−1) (−1 + h) + 2 − ((−1) + 2) −1 + 3h − 3h + h + 2 − (−1
= =
h h h
f (−1 + h) − f (−1)
′
f (−1) = lim = 3
h→0 h
′
T (x) = f (−1) ⋅ (x − (−1)) + f (−1) = 3(x + 1) + 1 = 3x + 4
23
EXERCISE 3
24
The derivative of a function f is given by f ′(x) . Find the value of x in R such that the tangent of
= 2x + 1
Answer
Solution
The line x = y has a slope of 1. So the tangent of the graph of f is parallel to the line x = y
In addition, the slope of the tangent of the graph of f at x is calculated by f ′(x). So we are
looking for x such that f ′(x) = 1 .
We set f ′(x) = 1 , so 2x + 1 = 1 . This holds only when x = 0 . Therefore, the tangent of the
graph of f has a slope of 1 only at x = 0 .
25
EXERCISE 4
26
Let f (x) =
1
1+x
2
. Calculate f ′(x) using difference quotients. Find the value of x such that the tangent on
the graph of the function is horizontal.
Answer
′
f (x) = −
2x
(1+x2)2
. The tangent of the graph of the function is horizontal when x = 0 .
Solution
f (x+h)−f (x)
We calculate the difference quotient h
.
1 1
− 2 2
f (x + h) − f (x) 1+(x+h)
2
1+x
2
1 + x − (1 + (x + h) ) −2x − h
= = =
2 2 2
h h h(1 + (x + h) )(1 + x ) (1 + (x + h) )(1 +
)
. Therefore 2 2
2x
′
f (x) = −
2 2
(1 + x )
The tangent on the graph of f at x has the slope f ′(x). When the tangent is horizontal it has a
slope of 0. So, to find x we set
′
f (x) = 0
′
f (x) = 0 only when x = 0 . So, the tangent on the graph of f is horizontal at the point x = 0 .
27
2. LIMITS
28
Table of Contents
2.1 The Behaviour of a Function Close to a Gap in the Domain
2.2 The Limit of a Function at Infinity
2.3 The Limit of a Sequence
Learning Goals
In this section we will learn different behaviours of functions near specific points, e.g. at gaps in the
domain, as well as their behaviour with large and small arguments. You will also know the idea of
limits with the help of examples and be able to understand them and calculate them with ease.
This section is about the idea of limits of a function and, more generally, about how functions behave close
to gaps in their domain. We will also investigate their behaviour for very large arguments (for example, at
infinity).
We already learned about the idea of a limit in the previous section on the derivative of a function. The
derivative of a function f (x) at the point x0 is:
f (x0 + h) − f (x0)
lim .
h→0 h
f (x0+h)−f (x0)
There, we used the limit to understand the behaviour of the difference quotient h
for smaller
and smaller values of h. Substituting h = 0 does not work, because division by 0 is not allowed.
In order to be fluent with the ideas of limits and behaviour at infinity, in most cases it suffices to have a
descriptive understanding of the concepts. We will limit ourselves to these cases. The exact mathematical
discussion is the topic of university mathematics.
sin(x)
f or x ≠ 0
x
f (x) = {
1
f or x = 0
2
Study the function's graph and investigate the behaviour of the function close to the point x = 0 .
WARNING
If the limit lim g(x) of a function g exists then it does not necessarily have to be equal to
x→x0
You should be able to see that for very small x the values of f (x) are very close to 1. Alternatively,
we say that as the argument x tends towards zero, the value of f (x) tends towards 1.
30
We say this as follows:
As x goes to zero, f (x) goes to 1
or
The limit of f (x) as x tends to 0 is 1
lim f (x) = 1.
x→0
sin(ax)
f (a, x) = , a ∈ R.
x
Take a look at how the limits depend on the values of a with the help of the visualization below.
−6 −4 −2 2 4 6
−2
−4
a = 3.00
1 8 – o + ← ↓ ↑ →
31
We already encountered an example of this type in the last section on the derivative. The difference
quotient of the polynomial p(x) = x
2
+ x − 2 at the point x0 = 2 is the function of the variable h:
p(2 + h) − p(2)
Δ(h) = .
h
It has a maximal domain of D(Δ) = R\{0} . In this case the limit, i.e. the derivative, can be
calculated easily, since the difference quotient Δ(h) can be simplified: Δ(h) = h + 5 . This
expression is not only defined on D(Δ) = R\{0} ; it is also defined at the point h = 0. The result is
then:
As h goes to zero, Δ(h) goes to 5. The limit is the derivative of the function p(x) at the point x0 = 2
2
x − 1
f (x) =
x + 1
on its maximal domain D(f ) = R\{−1} . The expression is not defined at x = −1 because the
denominator disappears there. Now we will investigate the function close to this gap in the domain.
The expression can be simplified using the binomial formula to:
2
x − 1
f (x) = = x − 1.
x + 1
Because x − 1 is defined on R, the limit can be calculated easily: The limit of f (x) at the point
x = −1 is −2.
32
1
f (x) =
2
x
Notice that for arguments x that approach zero, the value of the function gets larger and larger.
Using short form: As x goes to zero, f (x) goes to ∞ (infinity) or The function f (x) tends to ∞ as x
approaches 0, and we write:
lim f (x) = ∞.
x→0
The graph of the function approaches but never touches the y-axis. We say that the y-axis is a
vertical asymptote of the function f (x) as x goes to zero.
33
2.6 EXAMPLE (BEHAVIOUR LEFT AND RIGHT OF GAPS IN THE DOMAIN, VERSION 1)
The function
1
f (x) =
x
on its maximal domain D(f ) = R\{0} has a gap in the domain at x = 0. In order to study the
behaviour of the function around 0 we need to look at its graph.
The graph behaves differently on the left and right side of the gap in the domain (i.e. for x > 0 and
x < 0 ):
Case If we let the argument x approach zero from the right side (positive x-values), then the value
1: of the function f (x) gets bigger and bigger. We say: For positive arguments x approaching
zero, the value of the function f (x) approaches positive infinity, +∞.
Case If we let the argument x approach zero from the left side (negative x-values), then the value
2: of the function f (x) gets smaller and smaller. We say: For negative arguments x
approaching zero, the value of the function f (x) approaches negative infinity, −∞.
34
The y-axis is a vertical asymptote of the function f (x) as x approaches zero.
35
2.7 EXAMPLE (BEHAVIOUR LEFT AND RIGHT OF GAPS IN THE DOMAIN, VERSION 2)
x
f (x) =
1 − x
on its maximal domain D(f ) = R\{1} . In order to study the behaviour of the function close to the
gap in the domain at x = 1 , we need to investigate the graph.
The graph behaves differently on the left (x < 1 ) and right (x > 1 ) side of the gap in the domain.
This is because the numerator x is positive around the point x = 1 , however the denominator 1 − x
is positive and negative around x = 1:
Case If we let the argument x approach 1 from the right side then the value of the function f (x)
1: gets smaller and smaller. We say: For arguments x > 1 the value of the function f (x)
approaches negative infinity, −∞.
Case If we let the argument x approach 1 from the left side then the value of the function f (x)
2: gets larger and larger. We say: For arguments x < 1 the value of the function f (x)
approaches positive infinity, +∞.
The vertical line {(1, y) ∣ y ∈ R} is an asymptote of the function f (x) around the point x = 1 .
36
With the above two examples we have seen the cases that arise in practice when describing the
behaviour of functions near gaps in their domains.
analyze the behaviour as x approaches −∞ - here we substitute smaller and smaller x, and then we call the
limit lim , as long as the limit exists.
g(x)
x→−∞
37
2
f (x) = , x → +∞
x + 2
The denominator (x + 2) of f (x) grows without limit as x goes to +∞, and hence f (x)
approaches zero, i.e. .
lim f (x) = 0
x→∞
38
3x
f (x) = , x → +∞
x + 5
We write
3x 3x + 15 15 15
= − = 3 − .
x + 5 x + 5 x + 5 x + 5
The denominator (x + 5) of 15
x+5
grows without limit as x goes to +∞, and hence 15
x+5
approaches
zero, i.e. .
lim f (x) = 3
x→∞
39
5
x + 1
f (x) = , x → +∞.
4
x
5
x + 1 1
= x + .
4 4
x x
Click on the tab below for an example of when a limit does not exist.
40
Example
The limits lim g(x) and lim g(x) of a function g do not necessarily have to exist, in general. For
x→+∞ x→−∞
example, sin(x) does not approach a fixed value as x approaches +∞. If we substitute the sequence
of all natural multiples of 2π into sin x, it is zero at all of those points. If we add to each of those
π
values and then substitute this new sequence into sin x, it is always equal to 1. There is no number
that sin x approaches as x goes to +∞; it oscillates forever.
2.11 DEFINITION
Let g be a function defined on the natural numbers, i.e. g : N → R . Then g is called a sequence.
2.12 EXAMPLE
1. For example, the constant sequence g where g(n) = 1 for all n ∈ N is an example of a very
simple sequence.
2. g(n) = (−1) n
n
for n ∈ N is one further example of a somewhat more complicated sequence.
The first terms in the sequence are −1,2, −3,4, ….
41
If g is a sequence, then we are often interested in the behaviour of g(n) for increasing n. If g(n)
approaches a unique value a ∈ R as n increases, then we say that g converges and we call a the
limit of g:
a = lim g(n).
n→∞
Definition
The exact definition goes as follows: if there exists an a ∈ R such that for all ε > 0 there exists an
N ∈ N such that
lim g(n)
n→+∞
lim g(n) = a.
n→+∞
42
2.13 EXAMPLE
1
2. f (n) = , n → ∞
n
Because the denominator grows without bound and the numerator is constant, f (n) tends to
zero as n goes to ∞.
WARNING
As with the limits of functions, the limit of a sequence does not necessarily have to exist!
2.14 EXAMPLE
n
f (n) = (−1) , n → ∞
If n is an even number, then (−1)n = 1 . If n is an odd number, then (−1)n = −1, thus f (n)
swaps between 1 and −1. There is thus no unique number in R (or +∞ or −∞) that f (n)
approaches as close as we desire, hence f (n) has no limit.
EXERCISE 1
44
|x|
Verify whether lim
x
exists.
x→0
Answer
|x|
lim
x
does not exist.
x→0
Solution
|x|
Step 1: We check whether the right-hand and left-hand limits of x
at 0 exist and whether they
are equal.
|x| |x|
Step 2: For x > 0 , x
= 1 . So the right-hand limit of x
at 0 exists, and
|x|
lim = lim 1 = 1
x→0+ x x→0+
|x| |x|
Step 3: For x < 0 , x
= −1 . So the left-hand limit of x
at 0 exists, and
|x|
lim = lim − 1 = −1
x→0− x x→0−
|x| |x|
Step 4: Since the right-hand and left-hand limits of x
at 0 do not match, lim
x
does not exist.
x→0
45
EXERCISE 2
46
Verify whether lim
2x
x+2
exists and determine this limit if it does exist.
x→∞
Answer
lim
2x
x+2
exists and lim
2x
x+2
.
= 2
x→∞ x→∞
47
Solution
x+2
. For x > 0
1
2x 2x x
2
= ⋅ = .
1 2
x + 2 x + 2 1 +
x x
x
of the quotient 1+
2
2
tends to 1 as x , i.e.
→ ∞
x
2
lim (1 + ) = 1.
x→∞ x
lim 2 = 2.
x→∞
48
Step 4: Since the limit of the denominator is 1 and not 0, we can calculate the limit of the quotient
as the quotient of the limits:
lim 2
2 x→∞
lim = = 2.
x→∞ 2 2
1 + lim (1 + )
x x
x→∞
Therefore it follows
2x
lim = 2.
x→∞ x + 2
49
EXERCISE 3
50
Verify whether lim
2x+1
2
−x −x+2
exists and determine this limit if it does exist. What can you say about the
x→−∞
2
Answer
3 2
We divide the numerator and denominator of f (x) by the highest power of x in the denominator,
i.e. x2.
We obtain:
1 2 1
2x + 1 2 2x + 1 + 2
x x x
f (x) = = ⋅ = .
2 1 2 1 2
−x − x + 2 −x − x + 2 −1 − +
2 2
x x x
x
, 1
2
x
, − x1 and x
2
2
tend to zero.
x
+
1
x
2
tends to 0 and −1 − 1
x
+
2
2
x
tends to −1.
Since the limit of the new denominator is the real number −1, we can divide the numerator by
the denominator within the limit. We obtain:
2 1
2 1 lim +
2x + 1 + 2 x→−∞
x 2
x 0
x x
lim = lim = = = 0.
2 1 2 1 2
x→−∞ −x − x + 2 x→−∞
−1 − + lim − 1 − + −1
2 2
x x x x
x→−∞
Now we can discuss . Analogously to the first limit, we divide the numerator and
−x −x+2
lim
2x+1
x→−∞
denominator by x:
2 2
−x − x + 2 −x − 1 +
x
=
1
2x + 1 2 +
x
EXERCISE 4
53
Verify whether lim
x
x+1
exists and determine the limit if it does exist.
x→−1
Answer
lim
x
x+1
does not exist.
x→−1
54
Solution
Step 1: We write
x x + 1 − 1 x + 1 1 1
= = − = 1 − . (1)
x + 1 x + 1 x + 1 x + 1 x + 1
1
lim = +∞
x→−1+ x + 1
and
1
lim = −∞.
x→−1− x + 1
55
Step 3: Now with equation (1) we can conclude immediately that
x
lim = −∞
x→−1+ x + 1
and
x
lim = +∞.
x→−1− x + 1
56
3. DERIVATIVES OF ELEMENTARY
FUNCTIONS
57
Learning Goals
In this section we'll learn about the derivatives of certain simple elementary functions.
Now that we know in principle how we can take the derivative of a function f (by taking the limit of the
difference quotient) we can take the derivative of many different functions.
3.1 EXAMPLE
If we consider the function f (x) = c where c is a fixed real number, we can calculate:
f (x + h) − f (x) c − c
′
f (x) = lim = lim = lim 0 = 0.
h→0 h h→0 h h→0
The next most complicated functions that we'd like to take the derivative of are monomials and
polynomials.
58
3.2 EXAMPLE
f (x + h) − f (x) x + h − x h
′
f (x) = lim = lim = lim = lim 1 = 1.
h→0 h h→0 h h→0 h h→0
′ f (x+h)−f (x)
f (x)= lim
h
h→0
2 2
(x+h) −x
= lim
h
h→0
2 2 2
x +2xh+h −x
= lim
h
h→0
2
2xh+h
= lim
h
h→0
= lim 2x + h
h→0
= 2x
3.3 EXAMPLE
Now we'll look at the function , which is defined in x . If x and h is small enough,
1
∈ R ∖ {0} ≠ 0
x
then
1 1
f (x+h)−f (x) −
x+h x
=
h h
1 x−(x+h)
= ⋅
h x(x+h)
1 −h
= ⋅
h x(x+h)
1
= − ,
x(x+h)
and hence
1 1
′
f (x) = lim − = − .
2
h→0 x(x + h) x
60
3.4 EXAMPLE
f (x + h) − f (x) = √ x + h − √x
(√ x+h−√x)⋅(√ x+h+√x)
=
√ x+h+√x
2 2
(√ x+h) −(√x)
=
√ x+h+√ x
x+h−x
=
√ x+h+√x
h
= ,
√ x+h+√x
i.e.
f (x + h) − f (x) 1
= .
h √ x + h + √x
Therefore
1 1
′
f (x) = lim = .
h→0 √ x + h + √x 2√x
We can see in this example that the square root is not differentiable at 0.
Now that we know some of the derivatives of elementary functions, here is a short table summarizing
some of the results we know.
61
3.5 RULE
′
Function f (x) Derivative f (x) Conditions on (1)
¯
¯
¯
c (c ∈ R) 0 (2)
n n−1
x (n ∈ N0) nx (3)
n n−1
x (n ∈ Z, n < 0) nx x ≠ 0 (4)
1
√x x > 0 (5)
2√x
x x
e e (6)
1
ln(x) x > 0 (7)
x
x x
a (a > 0) ln a ⋅ a (8)
EXERCISE 1
63
Show with the help of difference quotients that the derivative of f (x) = x
3
is 3x2, as indicated in the
table.
Solution
f (x + h) − f (x)
3 3 3 2 2 3 3
f (x + h) − f (x) (x + h) − x x + 3x h + 3xh + h − x
2 2
= = = 3x + 3xh + h
h h h
2 2 2
lim 3x + 3xh + h = 3x
h→0
So f ′(x) = 3x
2
.
64
EXERCISE 2
65
Show with the help of difference quotients that the derivative of the function f (x) =
1
2
x
is − x2 , as
3
Solution
f (x + h) − f (x)
1 1
− 2 2
f (x + h) − f (x) (x+h)
2
x
2
x − (x + h) 2x + h
= = = −
2 2 2 2
h h x (x + h) h x (x + h)
2x + h 2x 2
lim − = − = −
2 2 4 3
h→0 x (x + h) x x
So f ′(x) .
2
= − 3
x
66
EXERCISE 3
67
Show that the function f (x) = √x is not differentiable in x . Note that the function f is not defined
= 0
Step 1: We consider the differential quotient for x = 0 . In order for it to be defined at all, we
assume that h > 0.
f (0 + h) − f (0)
f (0 + h) − f (0) √0 + h − √0 √h 1
= = =
h h h √h
1
lim = +∞
h→0 √h
Since we cannot have +∞ as a value for the slope, f (x) is not differentiable at x = 0.
As you can see in the picture, the y-axis is tangent to the graph of √x at the point (0,0).
70
EXERCISE 4
71
Let f (x) = sin(x) be the sine function. Draw the graph of f and draw the tangents of the graph at the
points x ,
= 0 x =
π
2
, π, and 3π
2
. Try to use these points to help derive the derivative of f (x) .
= sin(x)
72
Solution
The tangents of the graph of sin(x) at the point x = 0 is the line y , as can be seen from the
= x
At the point x =
π
2
the tangent of the graph of sin(x) is parallel to the x-axis. This tangent has a
slope of 0, and hence f ′( π2 ) = 0 .
73
At x = π the tangent of the graph of sin(x) is parallel to the line y = −x . The line y = −x has
a slope of −1, i.e. f . At x the tangent of the graph of sin(x) is parallel to the x-
′ 3π
(π) = −1 =
2
axis. Here, f ′
(
π
2
) = 0 . At x , ′
= 2π f (2π) = 1 .
The the values of the function f ′(x) at the respective points are: f ′(0) , ,
′ π
= 1 f ( ) = 0
2
, , and f .
′ ′ 3π ′
f (π) = −1 f ( ) = 0 (2π) = 1
2
74
If we were to complete the values of the tangent of the graph of sin(x) at more values than the
ones considered here, we would see that the slopes of the tangents (and hence the value of f ′ at
these points) decrease to −1 as we go from 0 to π. If we move from π to 2π, then the the slopes
of the tangents of the graph increase (as does the value of f ′) up to 1. The following image shows
the approximate behaviour of the graph of f ′(x):
This is the graph of cos(x). As we know from formula sheets, cos(x) is the actually the derivative
of sin(x), i.e. f ′(x) .
= cos(x)
75
Learning Goals
In this section we will learn step-by-step methods for taking the derivatives of sums, powers,
products, quotients, as well as compositions and constant multiples of functions.
From the previous sections we already know how to take the derivative of a function, and we've learned
the derivatives of the most important elementary functions. For the operations on combinations and
compositions of functions, there are a set of rules that break down taking the derivative into manageable
parts.
If f and g are differentiable functions, then
′ (f +g)(x+h)−(f +g)(x)
(f + g) (x) = lim
h
h→0
f (x+h)+g(x+h)−f (x)−g(x)
= lim
h
h→0
′ ′
= f (x) + g (x)
The sum of differentiable functions is also differentiable. The name of the rule comes from the operation
we just performed: the Sum Rule.
4.1 RULE
Sum Rule:
Given two differentiable functions f and g then
′ ′ ′
(f + g) (x) = f (x) + g (x).
Hence any finite sum of differentiable functions f1, f2, … , fn is also differentiable:
′ ′ ′ ′
(f1 + f2 + … fn) = f1 + f2 + … fn .
77
4.2 EXAMPLE
′ 2
f (x) = 3x + 1
If we multiply a differentiable function f with a real number c, then the product is differentiable. The
derivative is then
c ⋅ f (x + h) − c ⋅ f (x) f (x + h) − f (x)
′ ′
(c ⋅ f ) (x) = lim = c ⋅ lim = c ⋅ f (x).
h→0 h h→0 h
4.3 RULE
′ ′
(c ⋅ f ) (x) = c ⋅ f (x).
How we take the derivative of the product of differentiable functions is described by the product rule.
78
4.4 RULE
′ ′ ′
(f ⋅ g) (x) = f (x) ⋅ g(x) + f (x) ⋅ g (x).
Derivation
(f ⋅g)(x+h)−(f ⋅g)(x)
′
(f ⋅ g) (x) = lim
h
h→0
f (x+h)⋅g(x+h)−f (x)⋅g(x)
= lim
h
h→0
′ ′
= f (x) ⋅ g(x) + f (x) ⋅ g (x)
4.5 EXAMPLE
As an example we can calculate the derivative of the function F (x) , which is the
1
= 2
⋅ sin x
x
2 1
′ ′ ′
F (x) = f (x) ⋅ g(x) + f (x) ⋅ g (x) = − ⋅ sin x + ⋅ cos x.
3 2
x x
79
4.6 REMARK
In the earlier section we stated that the derivative of every constant function is 0. According to the
product rule, if we treat g(x) = c as a function:
′ ′ ′ ′ ′ ′
(c ⋅ f ) (x) = (g ⋅ f ) (x) = g (x) ⋅ f (x) + g(x) ⋅ f (x) = 0 ⋅ f (x) + c ⋅ f (x) = c ⋅ f (x).
From this example we can see that the constant rule is simply a special case of the product rule.
Sometimes we would also like to take the derivative of composed functions of the form f (g(x)) (The
composition of functions is explained in Chapter VI Section 8). When dealing with compositions, we call f
the outer function and g the inner function. An example for such a composed function would be with
2
f (y) = e
y
,y = g(x) = x
2
: f (g(x)) = e
x
. We'll also often write (f ∘ g)(x) (spoken: f composed with g)
instead of f (g(x)) (spoken f of g of x).
The differentiation of the composition of two functions leads to the chain rule.
4.7 RULE
′ ′ ′
(f ∘ g) (x) = f (g(x)) ⋅ g (x)
We take the derivative of f , f ′, and evaluate it at g(x) and then take the derivative of the function g(x)
with respect to x and multiply both together.
80
4.8 EXAMPLE
1. As an example, we can calculate the derivative of the function sin(x2). First we let the outer
function be f (y) = sin y and then use g(x) = x
2
as the inner function, and hence
f (g(x)) = sin(x )
2
. Since we have the composition of two functions, we can use the chain
rule here. First, f ′
(y) = cos y . For y = g(x) = x
2
we get that:
′ 2
f (g(x)) = cos(g(x)) = cos(x ).
′
g (x) = 2x.
′ ′ ′ 2
(f ∘ g) (x) = f (g(x)) ⋅ g (x) = 2x cos(x ).
Once we have gained enough experience taking the derivative of functions, we do not need to
perform these small steps any longer. The calculation can be reduced and the last line can be
written down in one step.
2. If we know the derivative of a function f (x), then we also know the derivative of 1
f (x)
. If f is
differentiable and f (x) ≠ 0 , if we let h(y) =
1
y
then 1
f (x)
= (h ∘ f )(x) is differentiable as
per the chain rule, and
′
1 1 f (x)
′ ′ ′ ′
( ) = h (f (x)) ⋅ f (x) = − ⋅ f (x) = − .
2 2
f (x) (f (x)) (f (x))
f (x)
3. The previous example can be used to determine the derivative of a function of the form g(x)
.
f (x)
Let f and g be differentiable functions and g(x) ≠ 0 . Then interpret the quotient g(x)
as the
product f (x) ⋅ 1
g(x)
and apply the product rule
81
f (x) 1 1 1
′ ′ ′ ′
( ) = (f (x) ⋅ ) = f (x) ⋅ + f (x) ⋅ ( ).
g(x) g(x) g(x) g(x)
g(x)
after 2. and obtain
′
1 1 g (x)
′ ′
(f (x) ⋅ ) = f (x) ⋅ + f (x) ⋅ (− ).
2
g(x) g(x) (g(x))
If you bring the right-hand side to the main denominator, you have obtained quotient rule of
differentiation
′ ′
f (x) f (x) ⋅ g(x) − f (x) ⋅ g (x)
′
( ) = .
2
g(x) (g(x))
4.9 RULE
′
c ⋅ f (x) c ⋅ f (x)
′ ′
f (x) ⋅ g(x) f (x) ⋅ g(x) + f (x) ⋅ g (x)
′ ′
(f ∘ g)(x) f (g(x)) ⋅ g (x)
′
1 f (x)
− 2
f (x) ≠ 0
f (x) (f (x))
′ ′
f (x) f (x)⋅g(x)−f (x)⋅g (x)
2
g(x) ≠ 0
g(x) (g(x))
EXERCISE 1
84
Calculate the derivative of the function h(x) 2
= (1 − x )
9
using the chain rule.
Answer
′ 2 8
h (x) = −18x(1 − x )
85
Solution
We set f (y) = y
9
as the outer function and g(x) = 1 − x
2
as the inner function, so
f (g(x)) = (1 − x )
2 9
= h(x) . Using the chain rule, we can calculate the following:
′ ′ ′
h (x) = f (g(x)) ⋅ g (x).
First of all
′ 8
f (y) = 9y .
With y = g(x) = 1 − x
2
, we get
′ 8 2 8
f (g(x)) = 9(g(x)) = 9(1 − x ) .
′
g (x) = −2x.
′ ′ ′ 2 8 2 8
(f ∘ g) (x) = f (g(x)) ⋅ g (x) = 9(1 − x ) ⋅ (−2x) = −18x(1 − x )
86
EXERCISE 2
87
Calculate the derivative of the function h(x) 2x
= xe .
Answer
′ 2x
h (x) = (1 + 2x)e
Solution
Step 1: We aim to express h as the sum, product or composition of functions whose derivatives
we know.
′ ′ ′ g(x) ′ 2x
(f ∘ g) (x) = f (g(x)) ⋅ g (x) = e ⋅ g (x) = 2e
′ ′ 2x 2x 2x
h (x) = 1 ⋅ (f ∘ g)(x) + x ⋅ (f ∘ g) (x) = e + 2xe = (1 + 2x)e
88
EXERCISE 3
89
Calculate the derivative of the function f (x) = a
x
(for a > 0), by representing ax with the help of the
exponential function ex.
Answer
′ x
f (x) = ln a ⋅ a
Solution
First we write
x x⋅ln a
a = e
We see that we can differentiate f using the chain rule. The outer function is ey, the inner
function is x ln a.
Then
x ′ x⋅ln a ′ x⋅ln a x
(a ) = (e ) = ln a ⋅ e = ln a ⋅ a
This is the formula that you know from the previous section.
90
EXERCISE 4
91
Prove the quotient rule: f and g are differentiable functions and g(x) ≠ 0 such that
′ ′ ′
f (x) f (x) ⋅ g(x) − f (x) ⋅ g (x)
( ) =
2
g(x) (g(x))
Use the product rule and the rule for the derivative of a reciprocal function.
Solution
′ ′
f (x) 1
( ) = (f (x) ⋅ )
g(x) g(x)
′ ′
1 1 1
′
(f (x) ⋅ ) = f (x) ⋅ + f (x) ⋅ ( )
g(x) g(x) g(x)
g(x)
. Thus, we obtain
′ ′ ′
1 g (x) f (x) ⋅ g(x) − f (x) ⋅ g (x)
′
f (x) ⋅ − f (x) ⋅ =
2 2
g(x) (g(x)) (g(x))
92
5. MONOTONICITY OF FUNCTIONS
93
Table of Contents
5.1 Monotonicity
5.2 Qualitative Behaviour of the Graphs of f and f ′
Learning Goals
In this section you will learn the relationship between the first deriative of a function and its
monotonicity and how to determine regions where functions increase or decrease.
5.1 Monotonicity
In calculus we are often interested in the regions in which a function f is increasing or decreasing. Finding
these regions is important when looking for the extrema of a given function. The monotonicity of a
function f together with its derivative f ′ will be brought to light here (the idea of monotonicity was
introduced already in Chapter VI, Section 1.4).
f (x + h) − f (x)
≥ 0
h
Of course, the limit of the difference quotient as h → 0 greater than or equal to 0, i.e. f ′(x) .
≥ 0
94
Given a differentiable function f that is monotonically increasing on an interval I , then the first
derivative of f is greater than or equal to 0, i.e.
′
f (x) ≥ 0, x ∈ I
In a similar fashion we can show that for monotonically decreasing functions, f ′(x) ≤ 0 for
x ∈ I .
Conversely, from the fact that f ′(x) ≥ 0 for x ∈ I , we can show that f is monotonically
increasing on I and from the fact that f ′(x) > 0 that it is strictly monotonically increasing.
Similar results hold for decreasing functions.
95
5.1 EXAMPLE
The slope of a differentiable function is closely related to the sign of its first derivative. If the first derivative
of a function f vanishes at a point x0, then the tangent of the graph at that point is horizontal. Points on
the graph of a function where the the tangent line is horizontal are called critical or stationary points.
5.2 DEFINITION
Any point at which f ′(x) = 0 is called a critical point or a stationary point of f . We say that f has
a critical point at x or at the point (x, f (x)).
96
5.3 EXAMPLE
function g(x) = x
3
− 3x has a first derivative of g′(x) = 3x
2
− 3 , and since
′ ′
g (1) = 0 = g (−1) g , has critical points at x = 1 and x = −1 .
To summarize:
5.4 RULE
′
f (x) on I Monotonicity of f on I (1)
¯
¯ ′
f (x) ≥ 0 ⇔f monotonically increasing (2)
′
f (x) ≤ 0 ⇔f monotonically decreasing (3)
and (4)
′
f (x) > 0 ⇒f strictly monotonically increasing (5)
′
f (x) < 0 ⇒f strictly monotonically decreasing (6)
f 1
−5 −4 −3 −2 −1 1 2 3 4 5
−1
−2
−3
−4
−5
– o + ← ↓ ↑ →
a : 1 , b : 3 , c : 1 , d : −1
In this Mathlet you can compare the monotonicity of the function f (blue graph) with the properties of f ′
(red graph) such as its sign and its roots. You also have the chance to define the roots of f ′.
A Derivative and its Corresponding Function
98
f
3
′
f
2
−5 −4 −3 −2 −1 1 2 3 4 5
−1
−2
−3
−4
−5
– o + ← ↓ ↑ →
In order to change the blue graph of f with its derivative f ′(x) = a(x − b)(x − c) (displayed
in red), choose the variables a, b and c: (b and c are the roots of f !) ′
a : −1 , b : −1 , c : 2
Observe how the monotonic intervals correspond to the sign and roots of the derivative f ′.
Try values b and c with b ≠ c and b = c !
In contrast with the earlier Mathlet, f ′ has forced roots due to the required form of f above.
EXERCISE 1
100
The derivative of a function f should have the following sign:
′
f + 0 − 0 + 0 +
Since the slope is positive in the interval (−∞, −1), f is monotonically increasing. In addition,
′
f (−1) = 0 i.e. at x , the tangent on the graph has a slope of 0. Therefore, the graph of f
= −1
The slope is positive again in the interval (1,3), so f increases. Since f ′(3) ,
= 0 x = 3 is a
stationary point.
103
Since f ′(x) is positive for x ,
> 3 f continues to increase in the interval (3, ∞).
The derivative described above could be, for example, f ′(x) = (x + 1)(x − 1)(x − 3)
2
.
104
EXERCISE 2
105
Consider the graph of a function f . Determine the sign of the derivative of f in suitable intervals.
Solution
f is monotonically increasing in the interval (−∞, x0), so the sign of f ′ is positive there.
′
f (0) = 0 again at x = 0 , since the tangent on the graph has a slope of 0.
f increases monotonically in the interval (0, ∞). Therefore f ′ has a positive sign there.
′
f + 0 − 0 +
106
EXERCISE 3
107
Consider the function f (x) = x
4
+
4
3
x
3
− 4x
2
. Determine the intervals of monotonicity of f .
+ 2
Answer
f is strictly monotonically decreasing in the intervals (−∞, −2) and (0,1) and strictly
monotonically increasing in (−2,0) and (1, ∞).
Solution
′ 3 2
f (x) = 4x + 4x − 8x
′ 2
f (x) = 4x(x + x − 2)
The other two roots −2 and 1 can be determined using the quadratic formula. With this we get
′
f (x) = 4x(x − 1)(x + 2)
For x ∈ (−∞, −2) or x ∈ (0,1) we have f ′(x) < 0 , and so f is strictly monotonically
decreasing there.
For x ∈ (−2,0) or x ∈ (1, ∞) we have f ′(x) > 0 , and so f is strictly monotonically increasing
there.
108
EXERCISE 4
109
Let f (x) = x ln x for x > 0 . Where is f monotonically increasing and where is f monotonically
decreasing? Where are the stationary points of f ?
Answer
f is monotonically decreasing in the interval (0, e−1) and monotonically increasing in the interval
(e
−1
, ∞) . There is a single stationary point which is at e−1.
Solution
1
′
f (x) = ln x + x = ln x + 1
x
We set f ′(x) = 0 :
0 = ln x + 1
Learning Goals
In this section you will learn how to find the concavity of a function with the help of the second
derivative, as well as what inflection points and saddle points of a function are and how to
calculate them.
The last section dealt with the growth of graphs with the help of the first derivative. One further aspect of
the behaviour of curves will now be investigated: concavity. In this section we will require that f is
differentiable on its domain, and that its derivative f ′ is a function defined on its domain.
The graph of the function x2 opens upwards, and the graph of the function −x2 opens
downwards.
Regions of a function that are concave up have increasing slope, in that the first derivative f ′ is
monotonically increasing. Regions of a function that are concave down have decreasing slope and
the derivative in that region is monotonically decreasing.
In many functions, the curvature of a function can change from being concave up to concave
down. Points at which the concavity changes are called inflection points, which need to be defined
precisely. In order to define an inflection point properly, we need the second derivative.
112
6.1 DEFINITION
Let f be a differentiable function with first derivative f ′. If f ′ is differentiable at a point x0, i.e. the
limit
′ ′
f (x0 + h) − f (x0)
lim
h→0 h
exists, then (f ′)′(x0) exists as well. If the first derivative f ′ is differentiable at all of the points in
its domain, then the function f is called twice differentiable. Instead of writing (f ′)′, we write f ′′.
The second derivative of f at x0 is just the derivative of f ′:
′ ′
f (x0 + h) − f (x0)
′′
f (x0) = lim
h→0 h
6.2 EXAMPLE
1. Let f (x) = x
3
+ 2x
2
+ 5. Then f ′(x) = 3x
2
+ 4x and f ′′(x) = 6x + 4 .
3. Let f (x) = cos(x) . Taking the derivative we get f ′(x) = − sin(x) and f ′′(x) .
= − cos(x)
4. Let f (x) = e
2x
. By the chain rule, f ′(x) = 2e
2x
and f ′′(x) 2x
= 4e .
x
and f ′′(x) = −
x
1
2
.
113
6.3 EXAMPLE
From the image it can be seen that f ′ is increasing until the point x = 0 and then starts
decreasing. At this point the sign of f ( ) ′ ′
= f
′′
needs to change from positive to negative. At the
point x = 1 the sign of f ′′ needs to change from negative to positive.
114
6.4 DEFINITION
Let f be twice differentiable. If f ′′(x) = 0 and the sign of f ′′ changes from one side to another at
x, then x is said to be an inflection point.
6.5 RULE
If f ′′(x) > 0 for x ∈ I then f is concave up on I . If f ′′(x) < 0 for x ∈ I then f is concave
down on I .
115
6.6 REMARK
For a simple critierium for determining an inflection point, we need the second derivative: the
first derivative is not sufficient. The first derivative does however help in describing the inflection
point further. In Example 6.3 we can see that the type of inflection point at x = 0 and x = 1 is
different. At x = 1 the slope of the tangent is 0, and at x = 0 the slope of the tangent is 2.
An inflection point x that also satisfies f ′
(x) = 0 is called a saddle point.
Every saddle point is both an inflection point as well as a critical point.
6.7 EXAMPLE
EXERCISE 1
117
Determine the second derivative of the function f (x) x
= e (x
2
− 4x + 5) and find where f ′′(x) is
positive, negative or 0. Where is the graph of f convex and where is it concave?
Answer
′′
f (x) = e (x
x 2
. ′′
− 1) f (x) = 0 for x = 1 and x .
= −1 f (x)
′′
is negative in the interval (−1,1)
and positive in the intervals (−∞, −1) and (1, ∞). So, the graph of f is concave in (−1,1) and
convex in (−∞, −1) and (1, ∞).
Solution
′ x 2 x
f (x) = e (x − 4x + 5) + e (2x − 4)
x 2
= e (x − 4x + 5 + 2x − 4)
x 2
= e (x − 2x + 1)
′′ x 2 x
f (x) = e (x − 2x + 1) + e (2x − 2)
x 2
= e (x − 2x + 1 + 2x − 2)
x 2
= e (x − 1)
x
2
− 1 = 0 if x = −1 or x = 1 . So, f ′′(x) = 0 for x = 1 and x = −1 .
x
2
− 1 > 0 for x ∈ (−∞, −1) or x ∈ (1, ∞) . So, f ′′(x) is positive in (−∞, −1) and (1, ∞).
Therefore, the graph of f in (−∞, −1) and (1, ∞) is convex.
x
2
− 1 < 0 for x ∈ (−1,1) . So, f ′′(x) is negative in (−1,1) and the graph of f in (−1,1) is
concave.
118
EXERCISE 2
119
Determine the second derivative and the inflection points of the function f (x) = 3x
5 4
− 5x + 2x + 1 .
Answer
′′
f (x) = 60x (x − 1) f
2
. has only one inflection point which is at 1.
Solution
We calculate f ′(x):
′ 4 3
f (x) = 15x − 20x + 2
We calculate f ′′(x):
′′ 3 2 2
f (x) = 60x − 60x = 60x (x − 1)
f (x)
′′
has two roots 0 and 1.
Since x2 ≥ 0 for all x ∈ R and x − 1 < 0 for all x < 1 then f ′′(x) 2
= 60x (x − 1) ≤ 0 for all
x < 1 . Therefore, there is no change of sign of f ′′ at 0 and it follows that 0 is not an inflection
point of f .
Since 60x2(x − 1) < 0 for all 0 < x < 1 and 60x2(x − 1) > 0 for all x > 1 , there exists a
change of sign of f and, therefore, an inflection point of f .
′′
120
EXERCISE 3
121
2
Determine the second derivative and the inflection points of the function f (x) = xe
x
.
Answer
2
′′
f (x) = 2xe
x 2
(3 + 2x ) f . has only one inflection point which is at 0.
Solution
2 2
′ x 2 x
f (x) = e + 2x e
We calculate f ′′(x) as the derivative of f ′(x) with the sum, product and chain rule:
2 2 2 2
′′ x x 3 x x 2
f (x) = 2xe + 4xe + 4x e = 2xe (3 + 2x )
Since 2ex > 0 and 3 + 2x2 > 0 for all x ∈ R 0 , is the only root of f ′′.
2
Since 2ex (3 + 2x2) is always positive, f ′′(x) has the same sign as x. Therefore, the sign of f ′′
changes at 0 and there exists an inflection point at 0.
122
EXERCISE 4
123
Determine the second derivative, the inflection points and the saddle points of the function
f (x) = x
4
− 4x
3
+ 1.
Answer
′′
f (x) = 12x
2
− 24x f. has inflection points at 0 and 2. Moreover, there exists a saddle point at 0.
Solution
We calculate f ′(x):
′ 3 2
f (x) = 4x − 12x
We calculate f ′′(x):
′′ 2
f (x) = 12x − 24x = 12x(x − 2)
f
′′
has two roots at 0 and 2.
For x , ′′
< 0 f (x) = 12x(x − 2) is positive. For x ,
∈ (0,2) 12x(x − 2) is negative. For x ,
> 2
Since f ′(0) = 0 , there also exists a saddle point at 0. Since f ′(2) = −16 2 , is not a saddle point
of f .
124
7. EXTREMA
125
Table of Contents
7.1 Global and Local Extrema
7.2 The Necessary Condition for Local Extrema
7.3 Sufficient Conditions for Local Extrema
7.4 Curve Sketching
Learning goals
In this section you will learn what extrema (minima/maxima) are and how to calculate the
extrema of a function with the help of the first and second derivative.
7.1 DEFINITION
f (x1) ≥ f (x)
at a given point x1 for all x in the domain of f , then f is said to have a global maximum at x1.
The global maximum of f is the value of the function at that point, f (x1).
f (x2) ≤ f (x)
for all x in the domain of f . The value f (x2) is called the global minimum of f .
126
Whether a function has a global maximum and/or minimum depends on the function. The function
2
f (x) = x , x ∈ R has a global minimum of zero at x = 0 , but does not have a global maximum. x2
reaches its global minimum at only one point. The function g(x) = cos(x), x ∈ R has a global minimum
of 1 and a global minimum of −1. The minima exist at points xl = π + l ⋅ 2π, l ∈ Z and the maxima
exist at points xk = k ⋅ 2π, k ∈ Z . Note as well that cos(x) has infinitely many minima and maxima. The
function h(x) = x, x ∈ R has no global extrema.
At local extrema, we only allow values of the variable x in the domain of f that are in a neighbourhood of
the local extrema. If f has a local extremum at x1, then we let δ > 0 be a small positive difference, and
examine the function in the region x1 − δ < x < x1 + δ .
7.2 DEFINITION
Local Extrema:
If at a given point x1 there is a δ > 0 such that for all x in the domain of f
then f has a local maximum of f (x1) at x1. Local minima can be defined in a similar fashion.
127
Every global extremum is also a local extremum. The converse is in general not true, as the image above
illustrates.
If it is clear from the context whether local or global extrema are being referred to, the adjectives "local"
and "global" are often left out.
If f has a local maximum at x1 ∈ I , then f (x1 + h) − f (x1) ≤ 0 for all h where −δ < h < δ . From
this, it follows that for the slope of the secant to the left (h < 0) and the right (h > 0) of this point:
f (x1 + h) − f (x1)
≥ 0, h < 0, and
h
f (x1 + h) − f (x1)
≤ 0, h > 0
h
In addition:
f (x + h) − f (x) f (x + h) − f (x)
lim ≥ 0 and lim ≤ 0
h→0− h h→0+ h
128
The limit f ′
(x1) satisfies both f ′
(x1) ≥ 0 and f ′
(x1) ≤ 0 , from which we can conclude that f ′
(x1) = 0 .
The point x1 is a critical point.
Geometrically, the secants to the left of a maximum are increasing or horizontal, and to the right of that
point are either decreasing or horizontal. Similarly, the secants to the left of a minimum are decreasing or
horizontal, and to the right of that point are either increasing or horizontal. Hence at minima and maxima
the tangent lines must be horizontal.
If a function f has an extremum at a point x, then those points are critical points of the function (see the
section on Monotonicity).
7.3 THEOREM
Necessary Condition:
Let f be differentiable on (a, b). In order for f to have a local extremum at a point x ∈ (a, b) , at
that point:
′
f (x) = 0.
7.4 EXAMPLE
1. Let f (x) = sin(x) . Because sin(x) ≤ 1 for all x ∈ R and sin( π2 ) , the point x
= 1 =
π
2
is
a local maximum. The derivative of f is f ′(x) = cos(x) . At the local extremum x =
π
2
,
f (
′ π
2
) = cos(
π
2
) = 0 .
2. If f (x) = x
3
, then f ′(x) = 3x
2
and x = 0 is a critical point, but there is no extremum
there, since f (x) > 0 for all x > 0 and f (x) < 0 for all x < 0. The critical points - the roots
of the derivative - are only candidates for points at which extrema can exist. Whether or not a
critical point is a point at which the function has an extremum, including whether it is a
minimum or maximum, needs to be investigated further.
changes sign at x1 from positive to negative. Then f increases to the left of x1 and decreases to the right
of x1. It follows that f needs to have a local maximum at x1. If the derivative to the left of x2 is negative
and positive to the right of x2, then f has a minimum at x2. When doing this analysis, it suffices to only
look at neighbouring x-values, i.e. x1 − δ < x < x1 + δ for some small δ > 0 .
7.5 THEOREM
Let f be differentiable on an open interval I , let f ′(x0) = 0 , and let δ > 0 . If f ′(x) > 0 for
x0 − δ < x < x0 and f ′(x) < 0 for x0 < x < x0 + δ , then f has a maximum at x0.
If f ′
(x) < 0 for x0 − δ < x < x0 and f ′
(x) > 0 for x0 < x < x0 + δ then f has a minimum at
x0 .
7.6 EXAMPLE
2 2 2
Let f (x) = e
−x
, and hence f ′(x) = −2xe
−x
. Because e−x > 0 for all x ,
∈ R x = 0 is the only
root of f ′
. At x
(x) = 0 the sign of f changes from positive to negative, hence f has a maximum
′
at x .
= 0
A change in the derivative near a critical point from positive values to negative values means that f ′(x) is
strictly monotonically decreasing there. That is certainly the case when the derivative of the derivative (the
second derivative) is negative, as we saw in the previous section on monotonicity.
We now require that f is not only differentiable on an interval I , but twice differentiable. For almost all of
the example functions, this condition is satisfied.
7.7 THEOREM
The conditions in theorems 7.5 and 7.7 are sufficient conditions for a function to have a local
maximum or minimum, i.e. the existence of local extrema follows from these requirements. These
conditions are however not necessary: there are functions that have local extrema that do not
satisfy these conditions. For example, the function f (x) = x
4
has a minimum at x = 0 , even
though f ′′
(0) = 0 is not positive.
On the other hand, it is necessary for a function to have an extremum at a given point x0 in an open
interval that the derivative of the function has a root there (Theorem 7.3). If f ′(x0) ≠ 0 , then the
function definitely has no extremum at x0. This result is not true for closed intervals!
7.8 EXAMPLE
3. Let f (x) = 1 − (x + 2)
4
and hence f ′(x) = −4(x + 2)
3
. The only critical point is at
x = −2 . Obviously f ′ changes sign at x = −2 from positive to negative, hence f has a local
maximum at x = −2 .
Because f ′′(x) = −12(x + 2)
2
, f ′′(−2) = 0 . According to Theorem 7.7, nothing can be
said about this function's extrema based off of this information.
One way of finding the extrema of this function without using differential calculus is to
consider the values of the function near the point x = −2 f (−2) = 1. and f (x) ≤ 1 for all
x ∈ R , hence f has a global maximum at x = −2 .
The following table has a summarized list of sufficient conditions for local extrema:
131
′
f
= changes sign at x1 f rom positive to negative ⇒ local maximum at x1
′
f
= changes sign at x2 f rom negative to positive ⇒ local minimum at x2
or alternatively
′ ′′
f (x1) = 0 and f (x1) < 0 ⇒ local maximum at x1
=
′ ′′
f (x2) = 0 and f (x2) > 0 ⇒ local minimum at x2
=
132
Expanded Note on Extrema on Intervals with Boundary Points
Sometimes the extrema of a function f need to be determined on an interval that includes its
boundary points. How to proceed in such a case will be examined below.
Let f (x) = x
2
on the interval [−1,2]. In order to find all the local and global extrema, we first need
to find all of the local extrema. A local extremum can be at −1, 2, or on the interval (−1,2).
Because the interval (−1,2) is open, the local extrema on that interval can be found with the help
of the first derivative. From the fact that f ′(x) = 2x , the only critical point is x = 0 . Because
′′
f (x) = 2 , it follows that f ′′
(0) = 2 > 0 , and hence there is a local minimum of f at x = 0 . Now,
we need to determine whether f has local extrema at the points x = −1 and x = 2 . Because f is
strictly monotonically decreasing on [−1,0), there is a local maximum at −1. Because f is strictly
monotonically increasing on (0,2], f has a local maximum at x = 2 . Here, we can also use the
monotonicity of f to prove the existence of local extrema - because x = −1 and x = 2 are the
boundary points of the domain of f , we cannot argue using the above method.
If we now want to find what the global maximum and global minimum are, then we compare the
value of the function at each of the corresponding local extrema. This method is successful only
because on closed intervals, the global extrema will always exist; every global extremum is also a
local extremum.
The points at x = −1 and x = 2 are both local maxima; f takes on the values f (−1) = 1 and
f (2) = 4 there. Because f (2) = 4 > 1 = f (−1) f , has its global maximum of 4 at x = 2 .
Because there is only one local minimum, namely at x , this is also the point where f has its
= 0
7.9 EXAMPLE
Let f (x) = x
4
− 4x
3
+ 4x , and hence
2
′
f (x) = 4x
3
− 12x
2
+ 8x = 4x(x
2
− 3x + 2) = 4x(x − 1)(x − 2) f . ′
has roots x0 = 0 ,
x1 = 1 , and x2 = 2. Because f ′
(x) changes sign at all three of its roots, there are extrema at x0,
x1 and x2.
Because the sign changes from positive to negative at x0, there is a local minimum at x0 = 0 .
Analogously, we can show that f has a local maximum at x1 = 1 and a local minimum at x2 = 2 .
Here, f ′′(x) and hence the roots of f ′′ can be
2 2 2
= 12x − 24x + 8 = 12(x − 2x + )
3
be rewritten:
1 1
′′
f (x) = 12(x − (1 + ))(x − (1 − )).
√3 √3
f
′′
changes sign at x3 and x4 and hence x3 and x4 are inflection points. Because neither x3 nor x4
are roots of f ′, neither of these inflection points can be saddle points, i.e. f has no saddle points.
Curve sketching is a valuable tool for analyzing functions. You can use it to get a rough picture of how the
graph of a function f looks. In the following applet you can change the properties of f and watch how the
curves of f , f ′, and f ′′ relate to each other.
2
′
f
−5 −4 −3 −2 −1 1 2 3 4 5
−1
−2
−3
−4
−5
– o + ← ↓ ↑ →
To change the blue graph of the function f (x) = (x − a)(x − b)(x − c)(x − d) ,
choose the variables a, b, c, and d: (these are the roots of f !)
a : 0 , b : 0 , c : 2 , d : 2
EXERCISE 1
137
Calculate the local extrema of the function f (x) = xe
−0.5x
, using only the first derivative of f .
Answer
Solution
We set f ′(x) = 0 , so
−0.5x
e (1 − 0.5x) = 0.
Since e−0.5x ≠ 0 for all values of x, we must have 1 − 0.5x = 0 and so x = 2 . Therefore, a local
extremum can only exist at x0 := 2 . Now we must verify whether a local extremum does in fact
exist at x = 2 and, if this is the case, which type it is.
EXERCISE 2
139
Calculate the local extrema of the function f (x) 2
= x e . Use the second derivative to determine
−2x
Answer
We set f ′(x) = 0 , so
−2x
2xe (1 − x) = 0
Since e−2x ≠ 0 for all values of x, either x = 0 or x = 1 . So, local extrema can only exist at
x0 := 0 and x1 := 1 . Now we must verify whether local extrema do in fact exist at these points
and, if so, which type they are.
′′
f (0) = 2 > 0
With x1 = 1 , we get
′′ −2
f (1) = −2e < 0
EXERCISE 3
143
Maximize the perimeter, U , of a rectangle that lies on the x-axis with a corner at the origin and the
opposite corner on the parabola −0.25x2 + 4. The base should be on the positive x-axis.
Answer
First, we need to find the function that we want to maximize. It should be determined by the
maximum value of 2x + 2y, where x is the width of the rectangle (plotted along the x-axis) and y
is the height (plotted along the y-axis). Since y = −0.25x
2
+ 4, we can replace y in the equation
for the [Link], we can determine the maximum value of
2x + 2 ⋅ (−0.25x
2
+ 4) = −0.5x
2
+ 2x + 8 .
Of course, we should continue to apply x ≥ 0 , and since the parabola cuts the x-axis at the point
(4,0) , we can also apply x ≤ 4 . So we set f (x) = −0.5x
2
+ 2x + 8 for x ∈ [0,4] and
determine the maximum value of f .
′
f (x) = −x + 2
Then f ′(2) = 0 , and there are no more roots of f ′. Therefore, in the interval (0,4), f has only the
critical point x = 2 .
Since f (0) = 8 and f (4) = 8 , but f (2) = 10 , the maximum value of f in [0,4] is at x = 2 . So
the maximum perimeter is U = 10 .
145
EXERCISE 4
146
Find the minimum value of the function f (x) = x
3
−
3
2
2
x + 1 in the interval [−1,2]. Where does this
occur?
Answer
To determine the smallest value of the function, we need to find the global minimum. First, we
look for the critical points in the interval (−1,2). Therefore, we calculate f ′(x):
′ 2
f (x) = 3x − 3x = 3x(x − 1)
3x(x − 1) = 0
′
f (x) has two roots, x = 0 and x = 1 , which both lie in the interval (−1,2). So, minima can only
exist at x = 0 and x = 1 in the interval (−1,2). Now, we calculate the second derivative:
′′
f (x) = 6x − 3
Furthermore, f ′′(1) = 3 > 0 . Therefore, f has a local minimum at x = 1 . The value of the
function at that point is f (1) =
1
2
.
To verify whether this is in fact the smallest value of the function in [−1,2], we still need to
compare it with f (−1) and f (2).
On a f (−1) = −
3
2
<
1
2
, f (2) = 3 >
1
2
. Therefore, in the interval [−1,2], the smallest value of
the function f occurs at x = −1 , and the smallest value is − 32 .
148
As you can see from the picture, the global minimum occurs at x = −1 and a local maximum
occurs at x .
= 0
149
EXERCISE 1
150
Let f (x) 2
= x + 2x + 3. Calculate, with the help of difference quotients, the derivative of f at x .
= 1
Give the tangent, T (x), of the graph of f at the point (1, f (1))!
Answer
T (x) = 4x + 2
151
Solution
f (1 + h) − f (1)
2 2 2 2
(1 + h) + 2(1 + h) + 3 − (1 + 2 + 3) 1 + 2h + h + 2 + 2h + 3 − 6 4h + h
= = =
h h h
lim 4 + h = 4
h→0
Therefore, f ′(1) = 4 .
′
T (x) = f (1) ⋅ (x − 1) + f (1) = 4(x − 1) + 6 = 4x + 2
152
EXERCISE 2
153
Let f (x) =
1
x−2
− 2
5
x +x−6
. Determine the maximum domain, D, in R for which f is defined, and then
determine the shape of the curve of f . Use the knowledge of monotonicity and asymptotic behavior that
you have learned in this section.
Answer
The maximum domain for which f is defined is D = R ∖ {−3,2} . The graph has the form:
154
Solution
x−2
and − x +x−6
5
2
over a common denominator:
1 5 1 5 x + 3 5
f (x) = − = − = −
2
x − 2 x + x − 6 x − 2 (x − 2)(x + 3) (x − 2)(x + 3) (x − 2)(
1
′
f (x) = −
2
(x + 3)
Since f ′(x) < 0 for all values of x in D, f is strictly monotonically decreasing over all intervals in
D . Hence, f is strictly monotonically decreasing over (−∞, −3), (−3,2) and (2, ∞).
Now, we examine the behavior of f as x tends towards x0 and x1. As x tends towards 2,
f (x) =
1
x+3
tends towards 1
5
, i.e.
1
lim f (x) = lim f (x) = lim f (x) =
x→2− x→2+ x→2 5
For x ,
< −3 f (x) is always negative. As we approach x = −3 from the left, the term x + 3
tends towards 0. Therefore, the reciprocal, f (x), tends towards −∞:
lim f (x) = −∞
x→−3−
155
For x ,
> −3 f (x) is always positive. Again, x + 3 tends to 0, as we approach x = −3 from the
right. However, since x + 3 is positive, the reciprocal, f (x), tends towards +∞:
lim f (x) = ∞
x→−3+
Since the right and left-hand limits at x = −3 are different, the limit lim f (x) does not exist.
x→−3
Now, we will determine the behaviour of f (x) as x tends to +∞ and −∞. Since x + 3 increases
unbounded towards +∞ and decreases unbounded towards −∞, then f (x), as the reciprocal
of x + 3, tends towards zero in both cases. I.e.
EXERCISE 3
157
Let f (x) x
= e (x − 1)
3
. Sketch the graph of f (x) by investigating the aspects of functions learned in this
chapter, i.e. look for local and global extrema of f , as well as inflection and saddle points.
Answer
There is a local and global minimum at x = −2 . There are no other local or global extrema. f has
inflection points at x ,
= 1 x = −2 + √ 3 , and x = −2 − √ 3 . The point x = 1 is also a saddle
point. There are no other inflection or saddle points.
158
Solution
First of all, take the derivative of f with the help of the product rule:
′ x 3 x 2 x 2
f (x) = e (x − 1) + 3e (x − 1) = e (x + 2)(x − 1) .
Critical points occur at the roots of f ′(x). Since ex > 0 for all real x, x = −2 and x = 1 are the
only roots of f ′(x). So, local extrema can only exist at x = −2 or x = 1 .
By looking at the conditions on the first derivative, we can then investigate these critical points for
the existence of local extrema.
At x = −2 f (x) , ′
changes sign from negative to positive, hence there exists at local minimum at
x = −2 .
At x ,
= 1 f (x)
′
does not change sign: f ′(x) > 0 for −2 < x < 1 and f ′(x) > 0 for x > 1, i.e
f is strictly monotonically increasing in (−2,1) as well as (1, ∞). Therefore, there is no local
extremum at x = 1.
Since f ′(x) is negative in the interval (−∞, −2), this means f is decreasing in this interval. Since
f is monotonically increasing in the interval [−2, ∞), there must exist a global minimum at
x = −2 .
′′ x 2 x 2 x x 2
f (x) = e (x + 2)(x − 1) + e (x − 1) + 2e (x + 2)(x − 1) = e (x − 1)(x + 4x + 1)
′′
f (x) has the roots at x = 1 as well as x = −2 + √ 3 and −2 − √3. So, these points are the
only options for an inflection point.
EXERCISE 4
161
A lamp hangs over the center of a round table. The diameter is one meter, so that the radius of the
tabletop is half a meter. The height of the lamp above the table will be denoted by h. The brightness, I, at
the edge of the table is then calculated as:
sin φ
I = k ⋅ ,
2
a
Answer
First of all, we must construct a function to maximize. I is a function depending on two variables (
φ and a), one of which we have to eliminate from I.
Since sin φ =
h
a
, we obtain:
h
I = k ⋅
3
a
4
, and so a = √
1
4
2
+ h . Hence, we obtain:
h
I = k ⋅
3
1 2
( + h ) 2
4
h
f (h) = k ⋅
3
1 2
( + h ) 2
4
For h = 0, we have f (0) = 0 . Obviously the global maximum does not occur at this point since f
takes positive values for all h > 0. So, we look for the global maximum in the interval (0, ∞).
Since every global maximum of f in (0, ∞) is also a local maximum, we first look for local
extrema.
163
We calculate the derivative:
2
1 h
′
f (h) = k ⋅ − 3k ⋅
3 5
1 2 1 2
( + h ) 2 ( + h ) 2
4 4
1 2
− 2h
′ 4
f (h) = k ⋅
5
1 2
( + h ) 2
4
The point where the global extremum occurs, must be obtained from f ′(h) = 0 . So, we set
1 2
− 2h
′ 4
0 = f (h) = k ⋅
5
1 2
( + h ) 2
4
Since f ′ only changes sign (from positive to negative) at h in the interval (0, ∞), it also
1
=
2√ 2
decreasing in ( 1
. Therefore, the global maximum occurs at h
, ∞) =
1
.
2√ 2 2√ 2