← Back to all lessons
Class 12Calculus12:25Published 17 Aug 2024

Logarithmic Differentiation

Learn how to differentiate functions raised to powers, complicated products, and quotients by taking logarithms first. Three worked examples show the full method step by step.

Logarithmic differentiation is the go-to method when a function involves powers of x or y, long products, or messy quotients. This lesson first reviews the laws of logarithms you need, then works through three examples: a square-root quotient, the derivative of a constant raised to x, and a product of three bracketed factors. Each example follows the same routine of taking logs on both sides, simplifying, and differentiating implicitly.

What you'll learn

  • When to reach for logarithmic differentiation: powers of x or y, long products, and awkward quotients
  • The logarithm laws that turn products, quotients, and powers into sums and multiples
  • The take-logs-on-both-sides routine, then differentiating implicitly to find the derivative

Lesson chapters

0:00When to use logarithmic differentiation and the log laws
1:54Example 1: a square-root quotient
7:05Example 2: derivative of a constant raised to x
8:24Example 3: a product of three bracketed factors

Lesson notes

This lesson introduces logarithmic differentiation: the method you use when a function is a power of xx or yy, a complicated product, or a quotient that would be painful to differentiate directly. The idea is to take logarithms of both sides first, simplify with the log laws, and then differentiate.

When to use it

Use logarithmic differentiation when the function involves:

  • a power whose base or exponent contains xx or yy,
  • a product of more than two functions,
  • a complicated quotient.

Laws of logarithms

These are the rules we lean on to simplify before differentiating.

log(ab)=loga+logb\log(ab) = \log a + \log b

log ⁣(ab)=logalogb\log\!\left(\tfrac{a}{b}\right) = \log a - \log b

logxm=mlogx\log x^{m} = m\,\log x

Special cases follow from the power rule:

logx=logx1/2=12logx,logan=1nloga\log \sqrt{x} = \log x^{1/2} = \tfrac{1}{2}\log x, \qquad \log \sqrt[n]{a} = \tfrac{1}{n}\log a

and for products of three factors,

log(abc)=loga+logb+logc.\log(abc) = \log a + \log b + \log c.

Also loge=1\log e = 1, log1=0\log 1 = 0, and logex=xloge=x\log e^{x} = x\log e = x.

Example 1: a square-root quotient

Differentiate

y=(x3)(x2+4)3x2+4x+3.y = \sqrt{\frac{(x-3)(x^{2}+4)}{3x^{2}+4x+3}}.

Set up. Write the square root as a power 12\tfrac{1}{2}:

y=((x3)(x2+4)3x2+4x+3)1/2.y = \left(\frac{(x-3)(x^{2}+4)}{3x^{2}+4x+3}\right)^{1/2}.

Take logs on both sides and apply the laws:

logy=12[log(x3)+log(x2+4)log(3x2+4x+3)].\log y = \tfrac{1}{2}\Big[\log(x-3) + \log(x^{2}+4) - \log(3x^{2}+4x+3)\Big].

Differentiate with respect to xx. The left side gives 1ydydx\tfrac{1}{y}\tfrac{dy}{dx} (implicit differentiation):

1ydydx=12[1x3+2xx2+46x+43x2+4x+3].\frac{1}{y}\frac{dy}{dx} = \tfrac{1}{2}\left[\frac{1}{x-3} + \frac{2x}{x^{2}+4} - \frac{6x+4}{3x^{2}+4x+3}\right].

Solve for the derivative by multiplying through by yy and substituting yy back:

dydx=12(x3)(x2+4)3x2+4x+3[1x3+2xx2+46x+43x2+4x+3].\frac{dy}{dx} = \tfrac{1}{2}\sqrt{\frac{(x-3)(x^{2}+4)}{3x^{2}+4x+3}}\left[\frac{1}{x-3} + \frac{2x}{x^{2}+4} - \frac{6x+4}{3x^{2}+4x+3}\right].

Example 2: a constant raised to x

Find ddxax\dfrac{d}{dx}\,a^{x}. Because the exponent contains xx, take logs.

y=ax    logy=xloga.y = a^{x} \;\Rightarrow\; \log y = x\log a.

Differentiating (with loga\log a a constant):

1ydydx=loga    dydx=yloga=axloga.\frac{1}{y}\frac{dy}{dx} = \log a \;\Rightarrow\; \frac{dy}{dx} = y\log a = a^{x}\log a.

So ddxax=axloga\dfrac{d}{dx}\,a^{x} = a^{x}\log a, the standard result.

Example 3: a product of three factors

Differentiate

y=(x+3)2(x+4)3(2x+5)4.y = (x+3)^{2}(x+4)^{3}(2x+5)^{4}.

Take logs and split the product into a sum, then bring down each power:

logy=2log(x+3)+3log(x+4)+4log(2x+5).\log y = 2\log(x+3) + 3\log(x+4) + 4\log(2x+5).

Differentiate term by term, remembering the chain rule on 2x+52x+5 (its derivative is 22):

1ydydx=2x+3+3x+4+422x+5=2x+3+3x+4+82x+5.\frac{1}{y}\frac{dy}{dx} = \frac{2}{x+3} + \frac{3}{x+4} + \frac{4\cdot 2}{2x+5} = \frac{2}{x+3} + \frac{3}{x+4} + \frac{8}{2x+5}.

Substitute yy back:

dydx=(x+3)2(x+4)3(2x+5)4[2x+3+3x+4+82x+5].\frac{dy}{dx} = (x+3)^{2}(x+4)^{3}(2x+5)^{4}\left[\frac{2}{x+3} + \frac{3}{x+4} + \frac{8}{2x+5}\right].

Key takeaways

  • Take logarithms of both sides when you have powers, long products, or quotients, then use the log laws to turn them into sums and multiples.
  • Differentiating logy\log y gives 1ydydx\tfrac{1}{y}\tfrac{dy}{dx}, so always multiply back by yy and substitute the original function for the final answer.
  • The standard result ddxax=axloga\dfrac{d}{dx}\,a^{x} = a^{x}\log a comes straight from this method.