Derivatives of Logarithmic Functions

Contributed by:
Sharp Tutor
In this section, we use implicit differentiation to find the derivatives of the logarithmic functions and, in particular, the natural logarithmic function.
1. 3
DIFFERENTIATION RULES
2. DIFFERENTIATION RULES
3.6
Derivatives of
Logarithmic Functions
In this section, we:
use implicit differentiation to find the derivatives of
the logarithmic functions and, in particular,
the natural logarithmic function.
3. DERIVATIVES OF LOGARITHMIC FUNCTIONS
An example of a logarithmic function
is: y = loga x
An example of a natural logarithmic function
is: y = ln x
4. DERIVATIVES OF LOG FUNCTIONS
It can be proved that logarithmic
functions are differentiable.
 This is certainly
plausible from their
graphs.
5. DERIVATIVES OF LOG FUNCTIONS Formula 1—Proof
d 1
(log a x) 
dx x ln a
 Let y = loga x.
 Then, ay = x.
 Differentiating this equation implicitly with respect to x,
using Formula 5 in Section 3.4, we get: y dy
a (ln a ) 1
 So, dy 1 1 dx
 y

dx a ln a x ln a
6. DERIVATIVES OF LOG FUNCTIONS Formula 2
If we put a = e in Formula 1, then the factor
on the right side becomes ln e = 1 and we get
the formula for the derivative of the natural
logarithmic function loge x = ln x.
d 1
(ln x) 
dx x
7. DERIVATIVES OF LOG FUNCTIONS
By comparing Formulas 1 and 2, we see
one of the main reasons why natural
logarithms (logarithms with base e) are used
in calculus:
 The differentiation formula is simplest when
a = e because ln e = 1.
8. DERIVATIVES OF LOG FUNCTIONS Example 1
Differentiate y = ln(x3 + 1).
 To use the Chain Rule, we let u = x3 + 1.
 Then y = ln u.
2
dy dy du 1 du 1 3 x
 So,    3 (3 x 2 )  3
dx du dx u dx x  1 x 1
9. DERIVATIVES OF LOG FUNCTIONS Formula 3
In general, if we combine Formula 2
with the Chain Rule, as in Example 1,
we get:
d 1 du d g '( x )
(ln u )  or  ln g ( x) 
dx u dx dx g ( x)
10. DERIVATIVES OF LOG FUNCTIONS Example 2
d
Find ln(sin x) .
dx
 Using Formula 3, we have:
d 1 d
ln(sin x)  (sin x)
dx sin x dx
1
 cos x cot x
sin x
11. DERIVATIVES OF LOG FUNCTIONS Example 3
Differentiate f ( x)  ln x .
 This time, the logarithm is the inner function.
 So, the Chain Rule gives:
d
1 2
f '( x)  (ln x)
1
2 (ln x)
dx
1 1 1
  
2 ln x x 2 x ln x
12. DERIVATIVES OF LOG FUNCTIONS Example 4
Differentiate f(x) = log10(2 + sin x).
 Using Formula 1 with a = 10, we have:
d
f '( x)  log10 (2  sin x)
dx
1 d
 (2  sin x)
(2  sin x) ln10 dx
cos x

(2  sin x) ln10
13. DERIVATIVES OF LOG FUNCTIONS E. g. 5—Solution 1
d x 1
Find ln .
dx x 2
d x 1 1 d x 1
ln 
dx x 2 x 1 dx x  2
x 2


x  2 x  2 1 (x 1) (x  2)
1
2
1 2
x 1 x 2
x  2  12 (x 1) x 5
 
(x 1)(x  2) 2(x 1)(x  2)
14. DERIVATIVES OF LOG FUNCTIONS E. g. 5—Solution 2
If we first simplify the given function using
the laws of logarithms, then the differentiation
becomes easier:
d x 1 d
ln   ln( x  1)  12 ln( x  2)
dx x  2 dx
1 1 1 
   
x 1 2  x  2 
 This answer can be left as written.
 However, if we used a common denominator,
it would give the same answer as in Solution 1.
15. DERIVATIVES OF LOG FUNCTIONS Example 6
Find f ’(x) if f(x) = ln |x|.
 Since f ( x ) 
ln x if x  0
ln( x) if x  0
1
 x if x  0
it follows that f ( x) 
 1 ( 1)  1 if x  0
  x x
 Thus, f ’(x) = 1/x for all x ≠ 0.
16. DERIVATIVES OF LOG FUNCTIONS Equation 4
The result of Example 6 is
worth remembering:
d 1
ln x 
dx x
17. LOGARITHMIC DIFFERENTIATION
The calculation of derivatives of complicated
functions involving products, quotients, or
powers can often be simplified by taking
 The method used in the following example
is called logarithmic differentiation.
18. LOGARITHMIC DIFFERENTIATION Example 7
3/ 4 2
Differentiate y  x x 1
5
(3 x  2)
 We take logarithms of both sides of the equation
and use the Laws of Logarithms to simplify:
2
ln y  ln x  ln( x  1)  5ln(3 x  2)
3
4
1
2
19. LOGARITHMIC DIFFERENTIATION Example 7
 Differentiating implicitly with respect to x gives:
1 dy 3 1 1 2 x 3
    2  5
y dx 4 x 2 x  1 3x  2
 Solving for dy / dx, we get:
dy  3 x 15 
y   2  
dx  4 x x 1 3x  2 
20. LOGARITHMIC DIFFERENTIATION Example 7
 Since we have an explicit
expression for y, we can
substitute and write:
3/ 4 2
dy x x 1  3 x 15 
 5   2
 
dx (3 x  2)  4 x x  1 3x  2 
21. STEPS IN LOGARITHMIC DIFFERENTIATION
1. Take natural logarithms of both sides of
an equation y = f(x) and use the Laws of
Logarithms to simplify.
2. Differentiate implicitly with respect to x.
3. Solve the resulting equation for y’.
22. LOGARITHMIC DIFFERENTIATION
If f(x) < 0 for some values of x, then ln f(x)
is not defined.
However, we can write |y| = |f(x)| and use
Equation 4.
 We illustrate this procedure by proving the general
version of the Power Rule—as promised in Section 3.1.
23. THE POWER RULE PROOF
If n is any real number and f(x) = xn,
then n 1
f '( x) nx
 Let y = xn and use logarithmic differentiation:
n
ln y ln x n ln x x 0
 Thus,
y ' n

y x
n
y x
 Hence, y ' n n nx n  1
x x
24. LOGARITHMIC DIFFERENTIATION
You should distinguish carefully
 The Power Rule [(xn)’ = nxn-1], where the base
is variable and the exponent is constant
 The rule for differentiating exponential functions
[(ax)’ =ax ln a], where the base is constant and
the exponent is variable
25. LOGARITHMIC DIFFERENTIATION
In general, there are four cases for
exponents and bases:
d
1. ( a b ) 0 a and b are constants
dx
d b b 1
2.  f ( x) b  f ( x)  f '( x)
dx
d
3.  a g ( x )  a g ( x ) (ln a ) g '( x)
dx
4. To find ( d / dx[ f ( x)]g ( x ) , logarithmic
differentiation can be used, as in the next example.
26. LOGARITHMIC DIFFERENTIATION E. g. 8—Solution 1
x
Differentiate y  x .
 Using logarithmic differentiation,
we have:
x
ln y ln x  x ln x
y' 1 1
 x   (ln x)
y x 2 x
 1 ln x  x  2  ln x 
y ' y   x  
 x 2 x  2 x 
27. LOGARITHMIC DIFFERENTIATION E. g. 8—Solution 2
x ln x x
Another method is to write x ( e ) .
d x d x ln x
( x )  (e )
dx dx
d
x ln x
e ( x ln x)
dx
x  2  ln x 
x  
 2 x 
28. THE NUMBER e AS A LIMIT
We have shown that, if f(x) = ln x,
then f ’(x) = 1/x.
Thus, f ’(1) = 1.
 Now, we use this fact to express the number e
as a limit.
29. THE NUMBER e AS A LIMIT
From the definition of a derivative as
a limit, we have:
f (1  h)  f (1) f (1  x)  f (1)
f '(1) lim lim
h 0 h x 0 x
ln(1  x)  ln1 1
lim lim ln(1  x)
x 0 x x 0 x
lim ln(1  x)1 x
x 0
30. THE NUMBER e AS A LIMIT Formula 5
1x
As f ’(1) = 1, we have lim ln(1  x) 1
x 0
 Then, by Theorem 8 in Section 2.5 and
the continuity of the exponential function,
we have: lim ln(1 x )1/ x 1x
1 ln(1 x ) 1x
e e e x 0
lim e lim(1  x)
x 0 x 0
1x
e lim(1  x)
x 0
31. THE NUMBER e AS A LIMIT
Formula 5 is illustrated by the graph of
the function y = (1 + x)1/x here and a table
of values for small values of x.
32. THE NUMBER e AS A LIMIT
This illustrates the fact that, correct to
seven decimal places, e ≈ 2.7182818
33. THE NUMBER e AS A LIMIT Formula 6
If we put n = 1/x in Formula 5, then n → ∞
as x → 0+.
So, an alternative expression for e is:
n
 1
e lim  1  
n 
 n