3.6 Derivative of Logarithmic Functions

Coming Concepts

  • •

    Find the derivative of logarithmic functions.

  • •

    Use logarithmic differentiation to determine the derivative of a function.

So far, we have learned how to differentiate a variety of functions, including trigonometric, inverse, and implicit functions. In this section, we explore derivatives logarithmic functions.

3.6.1 Derivative of the Logarithmic Function

Using the derivative of the natural exponential function, we can use implicit differentiation to find the derivative of its inverse, the natural logarithmic function.

Theorem 3.13 (The Derivative of the Natural Logarithmic Function).

dd⁢x⁢ln⁡x=1x. (3.11)

More generally, let g⁢(x) be a differentiable function. For all values of x for which g′⁢(x)>0, the derivative of ln⁡(g⁢(x)) is given by

dd⁢x⁢ln⁡(g⁢(x))=1g⁢(x)⁢g′⁢(x). (3.12)
Proof.

Let y=ln⁡x. Then ey=x and taking implicit derivatives yields

ey⁢d⁢yd⁢x=1.

Solving for d⁢yd⁢x yields

d⁢yd⁢x=1ey.

Finally, we substitute x=ey to obtain

d⁢yd⁢x=1x.

∎

The graph of y=ln⁡x and its derivative d⁢yd⁢x=1x are shown in Figure 3.12.

123456−1123y=ln⁡xy′=1/x
Figure 3.12: The function⁢y=ln⁡x is increasing on (0,+∞). Its derivative y′=1x is greater than zero on (0,+∞).
Example 3.6.1 (Taking a Derivative of a Natural Logarithm).


Find the derivative of f⁢(x)=ln⁡(x3+3⁢x−4).

Solution: Use Equation 3.12 directly.

f′⁢(x) =1x3+3⁢x−4⋅(3⁢x2+3) Use ⁢dd⁢x⁢ln⁡(g⁢(x))=1g⁢(x)⁢g′⁢(x).
=3⁢x2+3x3+3⁢x−4 Rewrite.
Example 3.6.2 (Using Properties of Logarithms in a Derivative).


Find the derivative of f⁢(x)=ln⁡(x2⁢sin⁡x2⁢x+1).

Solution: At first glance, taking this derivative appears rather complicated. However, by using the properties of logarithms prior to finding the derivative, we can make the problem much simpler.

f⁢(x) =ln⁡(x2⁢sin⁡x2⁢x+1)=2⁢ln⁡x+ln⁡(sin⁡x)−ln⁡(2⁢x+1) Apply properties of logarithms.
f′⁢(x) =2x+cot⁡x−22⁢x+1 Apply sum rule and ⁢h′⁢(x)=1g⁢(x)⁢g′⁢(x).
Checkpoint 3.6.1.

Differentiate: f(x)=ln(3x+2)5.

Hint: Use a property of logarithms to simplify before taking the derivative.

Now that we can differentiate the natural logarithmic function, we can use this result to find the derivatives of y=l⁢o⁢gb⁢x and y=bx for b>0,b≠1.

Theorem 3.14 (Derivatives of General Exponential and Logarithmic Functions).

Let b>0,b≠1, and let g⁢(x) be a differentiable function.

  1. 1.

    If, y=logb⁡x, then

    d⁢yd⁢x=1x⁢ln⁡b. (3.13)

    More generally, if h⁢(x)=logb⁡(g⁢(x)), then for all values of x for which g⁢(x)>0,

    h′⁢(x)=g′⁢(x)g⁢(x)⁢ln⁡b. (3.14)
  2. 2.

    If y=bx, then

    d⁢yd⁢x=bx⁢ln⁡b. (3.15)

    More generally, if h⁢(x)=bg⁢(x), then

    h′⁢(x)=bg⁢(x)⁢g′⁢(x)⁢ln⁡b. (3.16)
Proof.

If y=logb⁡x, then by=x. It follows that ln⁡(by)=ln⁡x. Thus y⁢ln⁡b=ln⁡x. Solving for y, we have y=ln⁡xln⁡b. Differentiating and keeping in mind that ln⁡b is a constant, we see that

d⁢yd⁢x=1x⁢ln⁡b.

The derivative in Equation 3.14 now follows from the chain rule.

If y=bx, then ln⁡y=x⁢ln⁡b. Using implicit differentiation, again keeping in mind that ln⁡b is constant, it follows that 1y⁢d⁢yd⁢x=ln⁡b. Solving for d⁢yd⁢x and substituting y=bx, we see that

d⁢yd⁢x=y⁢ln⁡b=bx⁢ln⁡b.

The more general derivative (Equation 3.16) follows from the chain rule.

∎

Example 3.6.3 (Applying Derivative Formulas).


Find the derivative of h⁢(x)=3x3x+2.

Solution: Use the quotient rule and Theorem 3.14.

h′⁢(x) =3x⁢ln⁡3⁢(3x+2)−3x⁢ln⁡3⁢(3x)(3x+2)2 Apply the quotient rule.
=2⋅3x⁢ln⁡3(3x+2)2 Simplify.
Example 3.6.4 (Finding the Slope of a Tangent Line).


Find the slope of the line tangent to the graph of y=log2⁡(3⁢x+1) at x=1.

Solution: To find the slope, we must evaluate d⁢yd⁢x at x=1. Using Equation 3.14, we see that

d⁢yd⁢x=3(3⁢x+1)⁢ln⁡2.

By evaluating the derivative at x=1, we see that the tangent line has slope

d⁢yd⁢x|x=1=34⁢ln⁡2=3ln⁡16.
Checkpoint 3.6.2.

Find the slope for the line tangent to y=3x at x=2.

Hint: Evaluate the derivative at x=2.

3.6.2 Logarithmic Differentiation

At this point, we can take derivatives of functions of the form y=(g⁢(x))n for certain values of n, as well as functions of the form y=bg⁢(x), where b>0 and b≠1. Unfortunately, we still do not know the derivatives of functions such as y=xx or y=xπ. These functions require a technique called logarithmic differentiation, which allows us to differentiate any function of the form h⁢(x)=g⁢(x)f⁢(x). It can also be used to convert a very complex differentiation problem into a simpler one, such as finding the derivative of y=x⁢2⁢x+1ex⁢sin3⁡x. We outline this technique in the following problem-solving strategy.

Problem Solving Strategy (Using Logarithmic Differentiation).

  1. 1.

    To differentiate y=h⁢(x) using logarithmic differentiation, take the natural logarithm of both sides of the equation to obtain ln⁡y=ln⁡(h⁢(x)).

  2. 2.

    Use properties of logarithms to expand ln⁡(h⁢(x)) as much as possible.

  3. 3.

    Differentiate both sides of the equation. On the left we will have 1y⁢d⁢yd⁢x.

  4. 4.

    Multiply both sides of the equation by y to solve for d⁢yd⁢x.

  5. 5.

    Replace y by h⁢(x).

Example 3.6.5 (Using Logarithmic Differentiation).


Find the derivative of y=(2⁢x4+1)tan⁡x.

Solution: We use logarithmic differentiation:

ln⁡y =ln(2x4+1)tan⁡x
ln⁡y =tan⁡x⁢ln⁡(2⁢x4+1)
1y⁢d⁢yd⁢x =sec2⁡x⁢ln⁡(2⁢x4+1)+8⁢x32⁢x4+1⋅tan⁡x
d⁢yd⁢x =y⋅(sec2⁡x⁢ln⁡(2⁢x4+1)+8⁢x32⁢x4+1⋅tan⁡x)
d⁢yd⁢x =(2⁢x4+1)tan⁡x⁢(sec2⁡x⁢ln⁡(2⁢x4+1)+8⁢x32⁢x4+1⋅tan⁡x)
Example 3.6.6 (Using Logarithmic Differentiation).


Find the derivative of y=x⁢2⁢x+1ex⁢sin3⁡x.

Solution: This problem really makes use of the properties of logarithms and the differentiation rules given in this chapter.

ln⁡y =ln⁡x⁢2⁢x+1ex⁢sin3⁡x Step 1. Take the natural logarithm of both sides.
ln⁡y =ln⁡x+12⁢ln⁡(2⁢x+1)−x⁢ln⁡e−3⁢ln⁡sin⁡x Step 2. Expand using properties of logarithms.
1y⁢d⁢yd⁢x =1x+12⁢x+1−1−3⁢cos⁡xsin⁡x Step 3. Differentiate both sides.
d⁢yd⁢x =y⁢(1x+12⁢x+1−1−3⁢cot⁡x) Step 4. Multiply by⁢y⁢on both sides.
d⁢yd⁢x =x⁢2⁢x+1ex⁢sin3⁡x⁢(1x+12⁢x+1−1−3⁢cot⁡x) Step 5. Substitute y=x⁢2⁢x+1ex⁢sin3⁡x.
Example 3.6.7 (Extending the Power Rule).


Find the derivative of y=xr where r is an arbitrary real number.

Solution: The process is the same as in Example 3.6.6, though with fewer complications.

ln⁡y =ln⁡xr Step 1. Take the natural logarithm of both sides.
ln⁡y =r⁢ln⁡x Step 2. Expand using properties of logarithms.
1y⁢d⁢yd⁢x =r⁢1x Step 3. Differentiate both sides.
d⁢yd⁢x =y⁢rx Step 4. Multiply by y on both sides.
d⁢yd⁢x =xr⁢rx Step 5. Substitute y=xr.
d⁢yd⁢x =r⁢xr−1 Simplify.
Checkpoint 3.6.3.

Use logarithmic differentiation to find the derivative of y=xx.

Hint: Follow the problem solving strategy.

Checkpoint 3.6.4.

Find the derivative of y=(tan⁡x)π.

Hint: Use the result from Example 3.6.7.

Key Concepts

  • •

    On the basis of the assumption that the exponential function y=bx,b>0 is continuous everywhere and differentiable at 0, this function is differentiable everywhere and there is a formula for its derivative.

  • •

    We can use a formula to find the derivative of y=ln⁡x, and the relationship logb⁡x=ln⁡xln⁡b allows us to extend our differentiation formulas to include logarithms with arbitrary bases.

  • •

    Logarithmic differentiation allows us to differentiate functions of the form y=g⁢(x)f⁢(x) or very complex functions by taking the natural logarithm of both sides and exploiting the properties of logarithms before differentiating.

Key Equations

  • •

    Derivative of the natural exponential function

    dd⁢x⁢(eg⁢(x))=eg⁢(x)⁢g′⁢(x)

  • •

    Derivative of the natural logarithmic function

    dd⁢x⁢(ln⁡g⁢(x))=1g⁢(x)⁢g′⁢(x)

  • •

    Derivative of the general exponential function

    dd⁢x⁢(bg⁢(x))=bg⁢(x)⁢g′⁢(x)⁢ln⁡b

  • •

    Derivative of the general logarithmic function

    dd⁢x⁢(logb⁡g⁢(x))=g′⁢(x)g⁢(x)⁢ln⁡b

Glossary

logarithmic differentiation

is a technique that allows us to differentiate a function by first taking the natural logarithm of both sides of an equation, applying properties of logarithms to simplify the equation, and differentiating implicitly