Loading [MathJax]/jax/element/mml/optable/GreekAndCoptic.js
Skip to main content
Library homepage
 

Text Color

Text Size

 

Margin Size

 

Font Type

Enable Dyslexic Font
Mathematics LibreTexts

3.9: Derivatives of Ln, General Exponential & Log Functions; and Logarithmic Differentiation

( \newcommand{\kernel}{\mathrm{null}\,}\)

So far, we have learned how to differentiate a variety of functions, including trigonometric, inverse, and implicit functions. In this section, we explore derivatives of logarithmic functions. Logarithmic functions can help rescale large quantities and are particularly helpful for rewriting complicated expressions.

Derivative of the Logarithmic Function

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

Theorem: The Derivative of the Natural Logarithmic Function

If x>0 and y=lnx,then

dydx=1x.

If x0 and y=ln|x|,then

dydx=1x.

Suppose the argument of the natural log is not just x, but instead is g(x), a differentiable function. Now, using the chain rule, we get a more general derivative: for all values of x for which g(x)>0, the derivative of h(x)=ln(g(x)) is given by

h(x)=1g(x)g(x).

Proof

If x>0 and y=lnx, then ey=x. Differentiating both sides of this equation results in the equation

eydydx=1.

Solving for dydx yields

dydx=1ey.

Finally, we substitute x=ey to obtain

dydx=1x.

We may also derive this result by applying the inverse function theorem, as follows. Since y=g(x)=lnx

is the inverse of f(x)=ex, by applying the inverse function theorem we have

dydx=1f(g(x))=1elnx=1x.

Using this result and applying the chain rule to h(x)=ln(g(x)) yields

h(x)=1g(x)g(x).

The graph of y=lnx and its derivative dydx=1x are shown in Figure.

CNX_Calc_Figure_03_09_003.jpeg

Figure 3.9.3: The function y=lnx is increasing on (0,+). Its derivative y=1x is greater than zero on (0,+)

Example 3.9.1:Taking a Derivative of a Natural Logarithm

Find the derivative of f(x)=ln(x3+3x4).

Solution

Use Equation directly.

f(x)=1x3+3x4(3x2+3) Use g(x)=x3+3x4 in h(x)=1g(x)g(x).

=3x2+3x3+3x4 Rewrite.

Example 3.9.2:Using Properties of Logarithms in a Derivative

Find the derivative of f(x)=ln(x2sinx2x+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(x2sinx2x+1)=2lnx+ln(sinx)ln(2x+1) Apply properties of logarithms.

f(x)=2x+cotx22x+1 Apply sum rule and h(x)=1g(x)g(x).

try-it.png Exercise 3.9.1

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

Hint

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

Answer

f(x)=153x+2

Now that we can differentiate the natural logarithmic function, we can use this result to find the derivatives of y=logbx and y=bx for b>0,b1.

Derivatives of General Exponential and Logarithmic Functions

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

i. If, y=logbx, then

dydx=1xlnb.

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)lnb.

ii. If y=bx, then

dydx=bxlnb.

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

h(x)=bg(x)g(x)lnb

Proof

If y=logbx, then by=x. It follows that ln(by)=lnx. Thus ylnb=lnx. Solving for y, we have y=lnxlnb. Differentiating and keeping in mind that lnb is a constant, we see that

dydx=1xlnb.

The derivative in Equation now follows from the chain rule.

If y=bx. then lny=xlnb. Using implicit differentiation, again keeping in mind that lnb is constant, it follows that 1ydydx=lnb. Solving for dydx and substituting y=bx, we see that

dydx=ylnb=bxlnb.

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

Example 3.9.3:Applying Derivative Formulas

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

Solution

Use the quotient rule and Note.

h(x)=3xln3(3x+2)3xln3(3x)(3x+2)2 Apply the quotient rule.

=23xln3(3x+2)2 Simplify.

Example 3.9.4: Finding the Slope of a Tangent Line

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

Solution

To find the slope, we must evaluate dydx at x=1. Using Equation, we see that

dydx=3ln2(3x+1).

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

dydxx=1=34ln2=3ln16.

try-it.png Exercise 3.9.2

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

Hint

Evaluate the derivative at x=2.

Answer

9ln(3)

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 b1. 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=\frac{x\sqrt{2x+1}}{e^x\sin ^3x}. We outline this technique in the following problem-solving strategy.

how-to.png Problem-Solving Strategy: Using Logarithmic Differentiation

  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. Use properties of logarithms to expand \ln (h(x)) as much as possible.
  3. Differentiate both sides of the equation. On the left we will have \frac{1}{y}\frac{dy}{dx}.
  4. Multiply both sides of the equation by y to solve for \frac{dy}{dx}.
  5. Replace y by h(x).

Example \PageIndex{5}: Using Logarithmic Differentiation

Find the derivative of y=(2x^4+1)^{\tan x}.

Solution

Use logarithmic differentiation to find this derivative.

\ln y=\ln (2x^4+1)^{\tan x} Step 1. Take the natural logarithm of both sides.

\ln y=\tan x\ln (2x^4+1) Step 2. Expand using properties of logarithms.

\frac{1}{y}\frac{dy}{dx}=\sec ^2x\ln (2x^4+1)+\frac{8x^3}{2x^4+1}⋅\tan x Step 3. Differentiate both sides. Use theproduct rule on the right.

\frac{dy}{dx}=y⋅(\sec ^2x\ln (2x4+1)+\frac{8x^3}{2x^4+1}⋅\tan x) Step 4. Multiply byyon both sides.

\frac{dy}{dx}=(2x^4+1)^{\tan x}(\sec ^2x\ln (2x^4+1)+\frac{8x^3}{2x^4+1}⋅\tan x) Step 5. Substitute y=(2x^4+1)^{\tan x}.

Example \PageIndex{6}: Extending the Power Rule

Find the derivative of y=\frac{x\sqrt{2x+1}}{e^x\sin ^3x}.

Solution

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

\ln y=\ln \frac{x\sqrt{2x+1}}{e^x\sin ^3x} Step 1. Take the natural logarithm of both sides.
\ln y=\ln x+\frac{1}{2}ln(2x+1)−x\ln e−3\ln \sin x Step 2. Expand using properties of logarithms.
\frac{1}{y}\frac{dy}{dx}=\frac{1}{x}+\frac{1}{2x+1}−1−3\frac{\cos x}{\sin x} Step 3. Differentiate both sides.
\frac{dy}{dx}=y(\frac{1}{x}+\frac{1}{2x+1}−1−3\cot x) Step 4. Multiply by y on both sides.
\frac{dy}{dx}=\frac{x\sqrt{2x+1}}{e^x\sin ^3x}(\frac{1}{x}+\frac{1}{2x+1}−1−3\cot x) Step 5. Substitute y=\frac{x\sqrt{2x+1}}{e^x\sin ^3x}.

try-it.png Exercise \PageIndex{3}

Use logarithmic differentiation to find the derivative of y=x^x.

Hint

Follow the problem solving strategy.

Answer

Solution: \frac{dy}{dx}=x^x(1+\ln x)

try-it.png Exercise \PageIndex{4}

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

Hint

Use the result from Example.

Answer

y′=π(\tan x)^{π−1}\sec ^2x

Key Concepts

  • On the basis of the assumption that the exponential function y=b^x,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 log_bx=\frac{\ln x}{\ln 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

\frac{d}{dx}(e^{g(x)})=e^{g(x)}g′(x)

  • Derivative of the natural logarithmic function

\frac{d}{dx}(\ln g(x))=\frac{1}{g(x)}g′(x)

  • Derivative of the general exponential function

\frac{d}{dx}(b^{g(x)})=b^{g(x)}g′(x)\ln b

  • Derivative of the general logarithmic function

\frac{d}{dx}(log_bg(x))=\frac{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

Contributors

  • Gilbert Strang (MIT) and Edwin “Jed” Herman (Harvey Mudd) with many contributing authors. This content by OpenStax is licensed with a CC-BY-SA-NC 4.0 license. Download for free at http://cnx.org.


This page titled 3.9: Derivatives of Ln, General Exponential & Log Functions; and Logarithmic Differentiation is shared under a CC BY-NC-SA 4.0 license and was authored, remixed, and/or curated by OpenStax.

Support Center

How can we help?