MAT1051 Lecture5
MAT1051 Lecture5
MAT1051 Lecture5
𝑓 𝑥 −𝑓 𝑎
𝑚 = lim 𝑚𝑃𝑄 = lim .
𝑄→𝑃 𝑥→𝑎 𝑥−𝑎
◦ We can only find 𝑚, if the above limit exists. Otherwise, the tangent line to the curve 𝐶 will
not exist.
Definition
The tangent line to the curve
𝑦 = 𝑓(𝑥) at the point
𝑃(𝑎, 𝑓 𝑎 ) is the line through
𝑃 with slope
𝑓 𝑥 −𝑓 𝑎
𝑚 = lim ,
𝑥→𝑎 𝑥−𝑎
provided that this limit exists.
The tangent line is the unique
line through (𝑎, 𝑓 𝑎 ) with
slope 𝑚, whose equation is
𝑦 − 𝑓 𝑎 = 𝑚(𝑥 − 𝑎)
Example 1
◦ Find an equation of the tangent line to the parabola 𝑓 𝑥 = 𝑥 2 at the point
𝑃 1,1 .
◦ Solution:
◦ In this example, we have 𝑎 = 1, and 𝑓 𝑎 = 1, so the slope is
𝑓 𝑥 − 𝑓(𝑎) 𝑥2 − 1
𝑚 = lim = lim
𝑥→1 𝑥−1 𝑥→1 𝑥 − 1
(𝑥 − 1)(𝑥 + 1)
= lim = lim 𝑥 + 1 = 1 + 1 = 2 .
𝑥→1 𝑥−1 𝑥→1
◦ Thus, the equation of the tangent line to the parabola 𝑓 𝑥 = 𝑥 2 at the point 𝑃 1,1 is:
𝑦−1=2 𝑥−1
𝑦 = 2𝑥 − 1
Geometric
Interpretation of
Example 1
In the previous example, we
found the equation of the tangent
line to the parabola 𝑓 𝑥 = 𝑥 2 at
the point 𝑃 1,1 . This means that
if you were to zoom in closely on
the curve of 𝑓 at that point, the
tangent line’s slope approximates
the rate of change of the function
at that point, in our case, 𝑃 1,1 .
In other words, the more we
zoom in at 𝑃 1,1 , the more the
parabola looks like a line.
Derivatives
◦ In lecture 3 and in the previous example, we have witnessed a similar limiting process to obtain
the slope of the tangent line to a curve as well as the instantaneous velocity of an object.
◦ In fact, limits of the above mentioned form arise whenever a rate of change is involved, such as:
◦ The rate of change of light intensity and the bending of light rays, which are important in lens and mirror
design,
◦ The rate of change of economic indicators, such as inflation, GDP, and interest rates,
◦ How populations of species change over time,
◦ The rate at which drugs are absorbed and eliminated from the body,
◦ Techniques like MRI and CT scans use this equation to analyze changes in tissue properties over time,
◦ Etc.
◦ Consequently, given the versatility of this specific type of limit, we equip it with a name and
extensively study it in this course, namely, the derivative.
The Derivative of a Function at a Number
𝑎
Definition
The derivative of a function 𝒇 at a number 𝒂, denoted by 𝑓 ′ 𝑎 , is
𝑓 𝑎 + ℎ − 𝑓(𝑎)
𝑓′ 𝑎 = lim ,
h→0 ℎ
if this limit exists.
Note: This limit is not different from the one discussed in the tangent line and the
velocity problems.
In fact, if we consider the curve 𝑦 = 𝑓(𝑥) and the secant line intersecting the curve at
the point 𝑃(𝑎, 𝑓 𝑎 ) and 𝑄(𝑎 + ℎ, 𝑓 𝑎 + ℎ ), then the difference in the 𝑥-coordinate 𝑓 ′ 𝑎 is read “f prime of a.”
of 𝑃 and 𝑄 is 𝑎 + ℎ − 𝑎 = ℎ.
Example 2
◦ Find the derivate of the function 𝑓 𝑥 = 𝑥 2 − 2𝑥 + 1 at the number 𝑎.
◦ Solution:
◦ From the definition of the derivative at a number, we have
𝑓 𝑎 + ℎ − 𝑓(𝑎) ( 𝑎 + ℎ 2 −2 𝑎 + ℎ + 1) − (𝑎 2 − 2𝑎 + 1)
𝑓 ′ 𝑎 = lim = lim
ℎ→0 ℎ ℎ→0 ℎ
2 2 2
𝑎 + 2𝑎ℎ + ℎ − 2𝑎 − 2ℎ + 1 − 𝑎 + 2𝑎 − 1
= lim Simplify
ℎ→0 ℎ 0
ℎ2 + 2𝑎ℎ − 2ℎ Factor!
= lim 0
ℎ→0 ℎ
ℎ(ℎ + 2𝑎 − 2)
lim = lim ℎ + 2𝑎 − 2 = 2𝑎 − 2
ℎ→0 ℎ ℎ→0
Therefore, we only need to evaluate 𝑓′(2) to find the slope of the tangent line. That is, since
𝑓 ′ 𝑎 = 2𝑎 − 2, then
𝑓 ′ 2 = 2 2 − 2 = 2.
Thus, the equation of the tangent line to the graph of 𝑓 𝑥 = 𝑥 2 − 2𝑥 + 1 at 2,1 is
𝑦−1=2 𝑥−2 .
Or,
𝑦 = 2𝑥 − 3.
Different 𝑎 Different Slopes!
𝑓 𝑥 = 𝑥 2 − 2𝑥 + 1 𝑓 𝑥 = 𝑥 2 − 2𝑥 + 1 𝑓 𝑥 = 𝑥 2 − 2𝑥 + 1
Equation of the tangent Equation of the tangent Equation of the tangent line
line at −1,4 is 𝑦 = −𝟒𝑥. line at 1,0 is 𝑦 = 𝟎. at 2,1 is 𝑦 = 𝟐𝑥 − 3.
𝑚𝑡𝑎𝑛 < 0 𝑚𝑡𝑎𝑛 = 0 𝑚𝑡𝑎𝑛 > 0
The Derivative Function
◦ From the previous graph, we note that as the point is changed, the tangent line also changes. More generally, its
slope changes.
◦ Consequently, the slope of the tangent line for the function 𝑓 is itself a function, called the derivative of 𝑓.
Definition
The derivative of 𝑓 is the function
𝑓 𝑥 + ℎ − 𝑓(𝑥)
𝑓′ 𝑥 = lim ,
h→0 ℎ
provided the limit exists and 𝑥 is in the domain of 𝑓. If 𝑓′(𝑥) exists, we say that 𝑓 is
differentiable at 𝑥. If 𝑓 is differentiable at every point of an open interval 𝐼, we say that 𝑓 is
differentiable on 𝐼.
Important Note:
Since the definition of 𝑓′ applies only at points in the domain of 𝑓, then the domain of 𝑓′ is no larger than the one of 𝑓.
Remark:
• The domain of 𝑓 𝑥 = 𝑥 is 0, ∞ .
Example 3 1
• The domain of 𝑓′ 𝑥 = 2 𝑥 is 0, ∞ .
◦ Let 𝑓 𝑥 = 𝑥.
◦ Find 𝑓 ′ 𝑥 .
◦ Find an equation of the line tangent to the graph of 𝑓 at 4,2 .
◦ Solution:
◦ From the definition of the derivative, we have:
𝑓 𝑥 + ℎ − 𝑓(𝑥)
𝑓 ′ 𝑥 = lim
ℎ→0 ℎ
𝑥+ℎ− 𝑥
= lim
ℎ→0 ℎ
𝑥 + ℎ − 𝑥 ( 𝑥 + ℎ + 𝑥)
= lim Multiply by the conjugate
ℎ→0 ℎ ( 𝑥 + ℎ + 𝑥)
𝑥+ℎ−𝑥 ℎ 1
2 𝑥 Simplify then evaluate the limit
lim = lim =
ℎ→0 ℎ( 𝑥 + ℎ + 𝑥) ℎ→0 ℎ( 𝑥 + ℎ + 𝑥)
Example 3 Continued
◦ Let 𝑓 𝑥 = 𝑥.
◦ Find 𝑓 ′ 𝑥 .
◦ Find an equation of the line tangent to the graph of 𝑓 at 4,2 .
◦ Solution:
◦ The slope of the tangent line at 4,2 is given by the derivative function evaluated at 𝑥 = 4,
1 1
𝑓′ 4 = = .
2 4 4
◦ Therefore, the equation of the tangent line is
1 1
𝑦 − 2 = 4 (𝑥 − 4) or 𝑦 = 4 𝑥 + 1
Example 4
2
◦ Find the derivative of 𝑓 𝑥 = .
𝑥2
◦ Solution:
◦ Use the formal definition of derivative to compute 𝑓 ′ 𝑥 .
𝑓 𝑥 + ℎ − 𝑓(𝑥)
𝑓′ 𝑥 = lim
ℎ→0 ℎ
2 2 2𝑥 2 − 2 𝑥 + ℎ 2
2 − 2
𝑥+ℎ 𝑥 𝑥2 𝑥 + ℎ 2
Common denominator = lim = lim
ℎ→0 ℎ ℎ→0 ℎ
2𝑥 2 − 2𝑥 2 − 4𝑥ℎ − 2ℎ2 ℎ(−4𝑥 − 2ℎ)
Expand the numerator and simplify = lim = lim
ℎ→0 ℎ(𝑥 2 𝑥 + ℎ 2 ) ℎ→0 ℎ 𝑥 2 𝑥 + ℎ 2
−4𝑥 − 2ℎ 4
Evaluate the limit = lim 2 =− 3
ℎ→0 𝑥 𝑥 + ℎ 2 𝑥
Derivative Notation
◦ Several notations for the derivative are used in the literature, for practical reasons. We
will give the explanation for one of them.
◦ Suppose that 𝑦 is a quantity that depends on another of 𝑥, i.e., 𝑦 = 𝑓(𝑥). If 𝑥 changes
from 𝑥1 to 𝑥2 , then the change in 𝑥 (also called the increment of 𝑥) is
∆𝑥 = 𝑥2 − 𝑥1 ,
and the corresponding change in 𝑦 is
∆𝑦 = 𝑓 𝑥2 − 𝑓 𝑥1 .
◦ The difference quotient,
∆𝑦 𝑓 𝑥2 − 𝑓(𝑥1 )
=
∆𝑥 𝑥2 − 𝑥1
is called the average rate of change of 𝑦 with respect to 𝑥 over the interval 𝑥1 , 𝑥2 .
Observe that this is also the slope of the secant line 𝑃𝑄, in the figure below (next slide)
◦ Therefore, using the above difference quotient and by
letting 𝑥2 → 𝑥1 , we can define the following:
◦ The slope of the tangent line,
◦ The instantaneous velocity,
◦ The (instantaneous) rate of change of 𝑦 with respect to
𝑥 at 𝑥 = 𝑥1 .
◦ In other words,
∆𝒚
𝐥𝐢𝐦 = 𝒇′(𝒙)
∆𝒙→𝟎 ∆𝒙
◦ Other notations for the derivatives, perhaps more
modern are:
𝑑𝑦 𝑑𝑓 ′ 𝑑
, ,𝑦 , 𝑓 𝑥 , and 𝐷𝑥 𝑓 𝑥 .
𝑑𝑥 𝑑𝑥 𝑑𝑥
Graphs of Derivatives
𝑚 = 0 at Solution:
𝑥 = 1.3 • Geometrically, the derivative
𝑚<0 function is the slope of the
tangent line at different values
of 𝑥.
𝑚 = 0 at 𝑚<0
𝑚>0 • Thus, it is natural to draw
𝑥 = 0.5
several tangent lines and
investigate the slope 𝑚, i.e.,
positive, negative or zero.
𝑚 = 0 at
𝑥=3
Example 5 Continued
◦ Based on the graph of 𝑓, we make the following observations:
• On the intervals −∞, 0.5 and (1.3, 3) the function 𝑓 is decreasing, thus the
slope of any tangent line will always be negative, thus 𝑓′ is negative on these
intervals.
• The slope of the tangent line to the curve is 0 at 𝑥 = 0.5, 1.3, and 3. Thus
𝑓 ′ 0.5 = 𝑓 ′ 1.3 = 𝑓 ′ 3 = 0.
• On the intervals 0.5,1.3 and 3, ∞ the function 𝑓 is increasing, thus the
slope of any tangent line on this interval is positive, thus 𝑓 ′ > 0.
Example 5 Continued
|ℎ| ℎ |ℎ| −ℎ
lim+
ℎ→0 ℎ
= lim+ = 1
ℎ→0 ℎ ≠ lim−
ℎ→0 ℎ
= lim−
ℎ→0 ℎ
= −1
Since both limits are different, one concludes that 𝑓 ′ 0 does not exist. Consequently, 𝑓 𝑥 = 𝑥 is differentiable
for all 𝑥 except 0, and
1 𝑖𝑓 𝑥 > 0
𝑓′ 𝑥 =
−1 𝑖𝑓 𝑥 < 0
Example 6
Continued
• Geometrically, we see that
𝑓(𝑥) does not have a
tangent line at (0,0). This is
due to the fact that the
direction of 𝑓 abruptly
changes.
• Thus,
“continuity does not imply
differentiability.”
Does Differentiability Imply Continuity?
◦ The answer to this question is:YES!
Theorem
If 𝑓 is differentiable at 𝑎, then 𝑓 is continuous at 𝑎.
Example:
𝑑 𝑑 𝑒
𝜋 = 0, 𝑒 =0
𝑑𝑥 𝑑𝑥
The Power Rule
Theorem
𝑑
If 𝑛 is any real number, then 𝑥 𝑛 = 𝑛𝑥 𝑛−1 .
𝑑𝑥
𝑑
𝑥 = 1𝑥 1−1 = 1. 3
𝑑𝑦
𝑑𝑥 If 𝑦 = 𝑥 , find
2 .
𝑑𝑥
𝑑 1 𝑑 −1 1
𝑑𝑦 3 1 = 𝑥 = −1𝑥 −1−1 = − 2
𝑑 1 1−1 1 𝑑𝑥 𝑥 𝑑𝑥 𝑥
𝑥 = 𝑥2 = . = 𝑥2
𝑑𝑥 2 2 𝑥 𝑑𝑥 2
The Constant
Multiple Rule
Theorem
If 𝑐 is a constant and 𝑓 is a
differentiable function, then
𝑑 𝑑
𝑐𝑓 𝑥 = 𝑐 𝑓(𝑥)
𝑑𝑥 𝑑𝑥
Examples:
𝑑
1. 3𝑥 4 = 3 4 𝑥 3 = 12𝑥 3 .
𝑑𝑥
1
𝑑 𝜋 𝑑 −2 𝜋
2. 𝑑𝑥 𝑥
= 𝜋 𝑑𝑥 𝑥 = − 2𝑥 3/2 .
The above graph gives a geometric description of the constant multiple rule.
Multiplying the function by 2 stretches the curve vertically by a factor of 2.
Therefore, all slopes of tangent lines are doubled.
The Sum Rule
Theorem
If 𝑓 and 𝑔 are both differentiable, then
𝑑 𝑑 𝑑
𝑓 𝑥 +𝑔 𝑥 = 𝑓 𝑥 + 𝑔 𝑥 .
𝑑𝑥 𝑑𝑥 𝑑𝑥
For the sake of completeness, let us prove this differentiation rule. The rule tells us that the derivative of the sum
is the sum of the derivatives. To prove this statement, we must revisit the formal definition of the derivative, that is;
𝑓 𝑥 + ℎ − 𝑓(𝑥)
𝑓 ′ 𝑥 = lim .
h→0 ℎ
Thus,
′ 𝑓 𝑥 + ℎ + 𝑔 𝑥 + ℎ − (𝑓 𝑥 + 𝑔 𝑥 ) 𝑓 𝑥 + ℎ − 𝑓 𝑥 + (𝑔 𝑥 + ℎ − 𝑔 𝑥 )
𝑓 𝑥 + 𝑔 𝑥 = lim = lim
ℎ→0 ℎ ℎ→0 ℎ
Limit Law 1 𝑓 𝑥+ℎ −𝑓 𝑥 𝑔 𝑥+ℎ −𝑔 𝑥
= lim + lim = 𝑓 ′ 𝑥 + 𝑔′(𝑥)
ℎ→0 ℎ ℎ→0 ℎ
The Difference Rule
Theorem
If 𝑓 and 𝑔 are both differentiable, then
𝑑 𝑑 𝑑
𝑓 𝑥 −𝑔 𝑥 = 𝑓 𝑥 − 𝑔 𝑥 .
𝑑𝑥 𝑑𝑥 𝑑𝑥
Example:
Let 𝑓 𝑥 = 2𝑥 3 − 5𝑥 2 + 3𝑥 − 2. Find 𝑓 ′ 𝑥 .
Solution:
Applying the Sum and Difference Rules, we get:
𝑓 ′ 𝑥 = 6𝑥 2 − 10𝑥 + 3.
The Derivative of the Natural Exponential
Functions
◦ Recall: The exponential function is defined as 𝑓 𝑥 = 𝑎 𝑥 , where 𝑎 > 0.
◦ Clearly, none of the above differentiation rules can be applied to find the derivative of
𝑎𝑥 .
◦ Let us attempt to find the derivative of the exponential function using the formal
definition of the derivative:
𝑓 𝑥 + ℎ − 𝑓(𝑥) 𝑎 𝑥+ℎ − 𝑎 𝑥 𝑎 𝑥 𝑎ℎ − 𝑎 𝑥
𝑓 ′ 𝑥 = lim = lim = lim
ℎ→0 ℎ ℎ→0 ℎ ℎ→0 ℎ
𝑎 𝑥 (𝑎ℎ − 1) 𝑎 ℎ−1
= lim = 𝑎 𝑥 lim
ℎ→0 ℎ ℎ→0 ℎ
= 𝑓′(0)𝑎 𝑥
The fact that 𝑓 ′ 𝑥 = 𝑓 ′ 0 𝑎 𝑥 says that:
The rate of change of an exponential function is proportional to the This is the derivative of 𝑓 at 0, i.e., 𝑓 ′ 0 .
function itself.
′ 𝑎ℎ −1
◦ It turns out that 𝑓 0 = lim exists for values of 𝑎 > 0, and we will be able to
ℎ→0 ℎ
evaluate it later in the course.
◦ For now, we will direct our attention to the case when this limit equals to 1, that is;
𝑎ℎ − 1
lim = 1.
ℎ→0 ℎ
◦ The number 𝑎 for which 𝑓 ′ 0 = 1 (recall 𝑓 𝑥 = 𝑎 𝑥 ) is given a special symbol 𝑒.
◦ This means that the slope of the tangent line at any given point is equal to the function
itself.
Definition
Theorem
The function 𝑓 𝑥 = 𝑒 𝑥 is differentiable for all real
numbers 𝑥, and
𝑑 𝑥
𝑒 = 𝑒𝑥
𝑑𝑥
Example 7
𝑒𝑥 1
a) Write an equation of the line tangent to the graph 𝑓 𝑥 = 2𝑥 − at the point 0, − .
2 2
b) Find the point(s) on the graph of 𝑓 at which the tangent line is horizontal.
Solution:
a) To answer this question, we need to find the slope of the tangent line, i.e., the derivative of 𝑓 𝑥 at the
given point.
′
𝑒𝑥
𝑓 𝑥 =2− .
2
1
Thus, the slope of the tangent line at 0, − is
2
𝑒 0 3
′
𝑓 0 =2− = .
2 2
1
Now, we are ready to write an equation of the tangent line at the point 0, − .
2
1 3 3 1
𝑦 + = 𝑥 − 0 or 𝑦 = 𝑥 − .
2 2 2 2
Example 7 Continued
b) To find the point(s) on the graph of 𝑓 at
which the tangent line is horizontal simply
means that we are looking for lines whose
slope is 0. More specifically, we need to solve
the following equation in 𝑥 :
𝑓′ 𝑥 = 0
𝑒𝑥
2− =0
2
𝑒𝑥
=2
2𝑥
𝑒 =4
Thus, 𝑓 ′ 𝑥 = 0 when 𝑥 = ln 4.
𝑓 has a horizontal tangent at (ln 4, 𝑓(ln 4)) .
Higher Order Derivatives
◦ Since the derivative of a function 𝑓 is a function itself, then we can talk about
the derivative of 𝑓 ′ , called the second derivative of 𝑓 and denoted by 𝑓 ′′ .
Then, we can talk about the derivative of 𝑓 ′′ , called the third derivative of 𝑓,
and so on…
Definition
𝑑2𝑦
2
= 6 − 4𝑒 𝑥 Second derivative
𝑑𝑥
𝑑3 𝑦 𝑥 Third derivative
= −4𝑒 .
𝑑𝑥 3
The Product Rule
◦ In the first lecture, we introduced new functions constructed from old ones
arithmetically.
◦ Recall, we also defined the differentiation rules for the sum and difference of two
differentiable functions.
◦ How can we define the derivative of the product and quotient of two differentiable
functions?
Theorem
If 𝑓 and 𝑔 are differentiable at 𝑥, then
𝑑
𝑓 𝑥 𝑔 𝑥 = 𝑓 ′ 𝑥 𝑔 𝑥 + 𝑔′ 𝑥 𝑓(𝑥)
𝑑𝑥
Example 9
𝑑
◦ Find 𝑥2 2 𝑥 + 3 .
𝑑𝑥
𝑓′ 𝑔′
◦ Solution: 𝑓 𝑔 𝑔 𝑓
𝑑 2 𝑑 2 2
𝑑
𝑥 2 𝑥+3 = 𝑥 2 𝑥+3 +𝑥 2 𝑥+3
𝑑𝑥 𝑑𝑥 𝑑𝑥
2
2
= 2𝑥 2 𝑥 + 3 + 𝑥 = 4𝑥 3/2 + 6𝑥 + 𝑥 3/2 = 5𝑥 3/2 + 6𝑥.
2 𝑥
Example 10
◦ Let 𝑓 𝑥 = 𝑥 2 𝑒 𝑥 , find 𝑓 ′ 𝑥 .
◦ Solution:
◦ Whenever we are differentiating a function, we need to first decide on the rules
we will use to compute the derivative of the function.
◦ In this problem, it is quite clear that we have the product of two functions namely
𝑥 2 and 𝑒 𝑥 .
◦ Thus, we must apply the Product Rule to find the derivative,
𝑓 ′ 𝑥 = 2𝑥𝑒 𝑥 + 𝑥 2 𝑒 𝑥
The Quotient Rule
Theorem
If 𝑓 and 𝑔 are differentiable at 𝑥 and 𝑔 𝑥 ≠ 0, then the derivative of 𝑓/𝑔 at 𝑥
exists and
𝑑 𝑓 𝑥 𝑓 ′ 𝑥 𝑔 𝑥 − 𝑓 𝑥 𝑔′(𝑥)
= 2
𝑑𝑥 𝑔 𝑥 𝑔 𝑥
Example 11
◦ Find and simplify
𝑑 𝑥 2 + 3𝑥 + 4
2
.
𝑑𝑥 𝑥 −1
◦ Solution:
◦ Applying the Quotient Rule, we get:
𝑑 𝑥 2 + 3𝑥 + 4 2𝑥 + 3 𝑥 2 − 1 − (𝑥 2 + 3𝑥 + 4)(2𝑥)
2
=
𝑑𝑥 𝑥 −1 𝑥2 − 1 2
2𝑥 3 − 2𝑥 + 3𝑥 2 − 3 − 2𝑥 3 − 6𝑥 2 − 8𝑥 −3𝑥 2 − 10𝑥 − 3
= 2 2
=
𝑥 −1 𝑥2 − 1 2
Example 12
𝑑
◦ Compute 𝑒 −𝑥 .
𝑑𝑥
◦ Solution:
1
◦ First observe that 𝑒 −𝑥 = .
𝑒𝑥
𝑑 −𝑥 𝑑 1 0 𝑒𝑥 − 𝑒𝑥 −𝑥 .
𝑒 = = = −𝑒
𝑑𝑥 𝑑𝑥 𝑒 𝑥 𝑒𝑥 2