Logarithmic Derivatives: From Slope to a Powerful Method

CBSE Mathematics · 2026–27 · Class 12

Learn with Rajesh Sir

The curve rises steeply near zero and gently farther along. How can one formula capture both behaviours? Start with the slope of ln x, then use logarithms to make products and changing powers easier to differentiate.

By the end, you can…
  • Derive the slope 1/x from a logarithmic limit.
  • Differentiate logarithms and exponentials with different bases.
  • Include the inner derivative in a composite function.
  • Use logarithmic differentiation on positive products and quotients.
  • Differentiate x^x and interpret the sign of its derivative.
About 5 minutes
TOPIC 01Class 12

The slope of ln x is 1/x

At a positive input x, the derivative measures the limiting slope of nearby secants on y=ln⁡xy=\ln x. Begin with the definition:

ddxln⁡x=lim⁡h→0ln⁡(x+h)−ln⁡xh.\frac{d}{dx}\ln x=\lim_{h\to0}\frac{\ln(x+h)-\ln x}{h}.

For sufficiently small h, both x and x+h are positive. Combine the logarithms, then divide the small change by x:

ln⁡(x+h)−ln⁡xh=ln⁡(1+h/x)h=1xln⁡(1+h/x)h/x.\frac{\ln(x+h)-\ln x}{h}=\frac{\ln(1+h/x)}h=\frac1x\frac{\ln(1+h/x)}{h/x}.

As h approaches zero, h/x also approaches zero. The bracketed logarithm ratio tends to 1, giving ddxln⁡x=1x(x>0).\boxed{\frac{d}{dx}\ln x=\frac1x\qquad(x>0).}

The formula agrees with the graph. Its slope is positive everywhere in its domain, so the curve increases. But the slope becomes smaller as x grows: at x=1 it is 1, at x=2 it is 1/2, and at x=5 it is 1/5.

A tangent slope is not the height of the curve. At x=1, the height is ln⁡1=0\ln1=0, while the slope is 1. Keep these quantities separate when reading the exploration. To find a tangent line, use both the point and the slope in y−y0=m(x−x0)y-y_0=m(x-x_0).

There is no tangent to the real ln curve at x=0 because that point is outside the domain. The derivative formula does not extend the original function to nonpositive inputs.

Work it through

Example. Find the tangent to y=ln⁡xy=\ln x at x=1.

The point is (1,0) and the slope is 1. Therefore y−0=1(x−1)y-0=1(x-1), or y=x−1\boxed{y=x-1}.

Enable JavaScript to explore the inputs. The explanation and worked example remain available here.

Pause. Think. Try.

1. What is the derivative of ln⁡x\ln x at x=4?
A hint, pleaseDifferentiate first, then substitute.
Read the answer and explanation

1/41/4

The derivative is 1/x on x>0, so its value at 4 is 1/4.
2. At x=1 on y=ln⁡xy=\ln x, which pair is (height, slope)?
A hint, pleaseUse ln 1 and 1/1 separately.
Read the answer and explanation

(0,1)(0,1)

ln⁡1=0\ln1=0, while y′=1/x=1y'=1/x=1 at x=1.
About 5 minutes
TOPIC 02Class 12

Other bases keep a constant factor

Changing the logarithm base changes a constant multiplier. For a fixed b>0b>0, b≠1b\ne1, log⁡bx=ln⁡xln⁡b.\log_bx=\frac{\ln x}{\ln b}. Since ln⁡b\ln b does not depend on x, differentiation gives ddxlog⁡bx=1xln⁡b(x>0).\boxed{\frac{d}{dx}\log_bx=\frac1{x\ln b}\qquad(x>0).}

If b>1, the factor ln b is positive and the derivative is positive. If 0<b<1, ln b is negative and the derivative is negative. This is the calculus version of the two logarithm graph families. For the common logarithm, d(log⁡10x)/dx=1/(xln⁡10)d(\log_{10}x)/dx=1/(x\ln10), not simply 1/x.

Exponentials have a matching pair of rules. The standard limit for (ah−1)/h(a^h-1)/h gives ddxax=axln⁡a(a>0).\frac{d}{dx}a^x=a^x\ln a\qquad(a>0). In particular, d(ex)/dx=exd(e^x)/dx=e^x, because ln e=1. If a=1, the function is constant and the derivative is 0; the same expression gives 1·ln 1=0.

The multiplier ln a is essential. For example, the slope of 2x2^x is 2xln⁡22^x\ln2, whereas the slope of (1/2)x(1/2)^x is negative. Differentiate the function that is actually written rather than treating every exponential as e^x.

In these rules the base is a fixed constant. If the base itself depends on x, as in x^x, a different argument is needed. We will build that method after the chain rule.

Work it through

Example. Differentiate y=log⁡1/2xy=\log_{1/2}x.

y′=1xln⁡(1/2)=−1xln⁡2,x>0.y'=\frac1{x\ln(1/2)}=-\frac1{x\ln2},\qquad x>0.

The negative derivative matches the decreasing graph.

Pause. Think. Try.

1. Differentiate log⁡10x\log_{10}x, for x>0.
A hint, pleaseConvert the logarithm to ln.
Read the answer and explanation

1/(xln⁡10)1/(x\ln10)

The constant factor 1/ln 10 remains when ln x is differentiated.
2. Differentiate 2x2^x.
A hint, pleaseThe exponent varies while the base 2 is fixed.
Read the answer and explanation

2xln⁡22^x\ln2

The exponential rule gives axln⁡aa^x\ln a; here a=2.
About 5 minutes
TOPIC 03Class 12

Differentiate the inside as well

For y=ln⁡(3x−2)y=\ln(3x-2), the logarithm is applied to an expression that changes three times as fast as x. The chain rule records both layers: differentiate the outer logarithm, then multiply by the derivative of its argument.

ddxln⁡f(x)=f′(x)f(x)\boxed{\frac{d}{dx}\ln f(x)=\frac{f'(x)}{f(x)}}

This rule requires f to be differentiable and f(x)>0f(x)>0 on the interval being considered. The positivity condition belongs to the original logarithm; it cannot be discarded after simplifying the derivative.

For a fixed valid base b, the extra constant remains:

ddxlog⁡bf(x)=f′(x)f(x)ln⁡b.\frac{d}{dx}\log_b f(x)=\frac{f'(x)}{f(x)\ln b}.

Similarly, d(ef(x))/dx=ef(x)f′(x)d(e^{f(x)})/dx=e^{f(x)}f'(x), and d(af(x))/dx=af(x)ln⁡a f′(x)d(a^{f(x)})/dx=a^{f(x)}\ln a\,f'(x) for a fixed a>0. Always identify the inside function before applying a memorised rule.

Compare ln⁡(x2+1)\ln(x^2+1) and ln⁡(x2−1)\ln(x^2-1). Their derivatives look similar, but their domains differ. The first exists for every real x and has derivative 2x/(x2+1)2x/(x^2+1). The second requires x<−1x<-1 or x>1x>1, and has derivative 2x/(x2−1)2x/(x^2-1) only on those intervals.

A useful check is to name the inside, its derivative and its allowed inputs in three short steps. This prevents both a missing multiplier and a derivative used where the original function never existed.

Work it through

Example. Differentiate y=ln⁡(3x−2)y=\ln(3x-2).

The domain is 3 x−2>0, or x>2/3. The inner derivative is 3, so y′=33x−2,x>23.y'=\frac3{3x-2},\qquad x>\frac23. A denominator of 3 x−2 alone would omit the chain-rule factor.

Pause. Think. Try.

1. Differentiate ln⁡(x2+1)\ln(x^2+1).
A hint, pleaseThe inside derivative is 2 x.
Read the answer and explanation

2x/(x2+1)2x/(x^2+1)

The chain rule gives 2x/(x2+1)2x/(x^2+1). Since x²+1>0, the derivative is valid for every real x.
2. Where does the real function ln⁡(x2−1)\ln(x^2-1) exist?
A hint, pleaseThe original argument must be positive, not merely nonzero.
Read the answer and explanation

x<−1 or x>1x<-1\text{ or }x>1

x2−1>0x^2-1>0 means ∣x∣>1|x|>1. A nonzero derivative denominator alone would allow invalid inputs between−1 and 1.
About 5 minutes
TOPIC 04Class 12

Use logs to untangle a positive product

A long product with powers may be easier to differentiate after taking a logarithm. Logarithms turn products into sums, quotients into differences and powers into coefficients. Differentiate the simpler relation, then recover the derivative of the original function.

Consider y=x2(x+1)3x+2,x>0.y=\frac{x^2(x+1)^3}{x+2},\qquad x>0. On this stated interval, every factor and y itself is positive. Taking natural logarithms is therefore legal:

ln⁡y=2ln⁡x+3ln⁡(x+1)−ln⁡(x+2).\ln y=2\ln x+3\ln(x+1)-\ln(x+2).

Now differentiate both sides. The left side also needs the chain rule because y depends on x:

y′y=2x+3x+1−1x+2.\frac{y'}{y}=\frac2x+\frac3{x+1}-\frac1{x+2}.

Finally multiply by y and substitute its original expression:

y′=x2(x+1)3x+2(2x+3x+1−1x+2).y'=\frac{x^2(x+1)^3}{x+2}\left(\frac2x+\frac3{x+1}-\frac1{x+2}\right).

Stopping at y′/y would give the relative rate of change, not the derivative y′. The last multiplication is part of the method.

Why did we state x>0? It makes the positive-log expansion valid in every line. The original rational expression may exist elsewhere, but this derivation is deliberately restricted to the stated interval. If a problem asks for other sign intervals, handle them carefully with absolute-value logarithms or direct differentiation; do not take ln of a negative factor.

Choose this method because it simplifies the structure, not because every product must be treated this way. A short product may be quicker with the ordinary product rule.

Work it through

Example. For y=x2(x+1)3/(x+2)y=x^2(x+1)^3/(x+2), find y′ at x=1.

Here y=8/3 and y′/y=2+3/2−1/3=19/6y'/y=2+3/2-1/3=19/6. Therefore y′(1)=83⋅196=769.y'(1)=\frac83\cdot\frac{19}6=\frac{76}9.

Pause. Think. Try.

1. When y is a positive differentiable function of x, what is d(ln⁡y)/dxd(\ln y)/dx?
A hint, pleaseThe argument y is itself changing with x.
Read the answer and explanation

y′/yy'/y

The chain rule gives the outer derivative 1/y multiplied by the inner derivative y′.
2. For y=x(x+1)y=x(x+1), x>0, logarithmic differentiation gives y′/y=1/x+1/(x+1)y'/y=1/x+1/(x+1). What is y′?
A hint, pleaseMultiply the equation by y=x(x+1).
Read the answer and explanation

2x+12x+1

y′=(x+1)+x=2x+1y'=(x+1)+x=2x+1, agreeing with direct differentiation of x²+x.
About 5 minutes
TOPIC 05Class 12

When both the base and exponent change

In y=xxy=x^x, neither the ordinary fixed-power rule nor the fixed-base exponential rule applies on its own: x appears in both positions. Work on x>0 so that the real variable power can be written as exln⁡xe^{x\ln x}.

Taking logarithms exposes a familiar product:

ln⁡y=xln⁡x.\ln y=x\ln x.

Differentiate with respect to x. The left side gives y′/y; the right side uses the product rule:

y′y=ln⁡x+x1x=ln⁡x+1.\frac{y'}{y}=\ln x+x\frac1x=\ln x+1.

Multiplying by y gives the result ddxxx=xx(ln⁡x+1),x>0.\boxed{\frac{d}{dx}x^x=x^x(\ln x+1),\qquad x>0.}

The derivative’s sign is especially easy to read. The factor x^x is positive, so the sign comes from ln x + 1. It is negative for 0<x<1/e, zero at x=1/e and positive for x>1/e. Thus the function decreases and then increases, with a minimum at 1/e. A changing exponent does not force a function to increase everywhere.

The same method handles y=f(x)g(x)y=f(x)^{g(x)} on an interval where f>0 and both functions are differentiable. Write ln⁡y=gln⁡f\ln y=g\ln f, then use the product and chain rules:

y′=fg(g′ln⁡f+gf′f).y'=f^g\left(g'\ln f+g\frac{f'}{f}\right).

Use the expanded reasoning until the two contributions are clear: one comes from the changing exponent, the other from the changing base. Keep the positive-base interval visible throughout.

Work it through

Example. Differentiate y=(x+1)xy=(x+1)^x on x>−1.

Write ln⁡y=xln⁡(x+1)\ln y=x\ln(x+1). Then y′/y=ln⁡(x+1)+x/(x+1)y'/y=\ln(x+1)+x/(x+1), giving y′=(x+1)x(ln⁡(x+1)+xx+1).y'=(x+1)^x\left(\ln(x+1)+\frac{x}{x+1}\right).

Pause. Think. Try.

1. Differentiate xxx^x on x>0.
A hint, pleaseTake ln first; the right side becomes x ln x.
Read the answer and explanation

xx(ln⁡x+1)x^x(\ln x+1)

Product differentiation gives ln x + 1. Multiply by the original y=x^x.
2. At which positive x does the derivative of x^x equal zero?
A hint, pleaseThe positive factor x^x cannot be zero.
Read the answer and explanation

1/e1/e

ln⁡x+1=0\ln x+1=0 gives ln x=−1, hence x=1/e.
PUT IT TOGETHER

Your chapter checkpoint

Mix the ideas. Try each question before opening its explanation.

1. Differentiate log⁡2(1+x2)\log_2(1+x^2).
A hint, pleaseUse both the base-conversion factor and the inner derivative.
Read the answer and explanation

2x/((1+x2)ln⁡2)2x/((1+x^2)\ln2)

The derivative is 2 x divided by(1+x²)ln 2. The original argument is positive for all real x.
2. Differentiate e3x−1e^{3x-1}.
A hint, pleaseMultiply the exponential by the inner derivative.
Read the answer and explanation

3e3x−13e^{3x-1}

The derivative of 3 x−1 is 3, giving 3 e^(3 x−1).
3. What is ddxxx∣x=1\left.\frac{d}{dx}x^x\right|_{x=1}?
A hint, pleaseSubstitute only after finding the derivative.
Read the answer and explanation

11

11(ln⁡1+1)=11^1(\ln1+1)=1.

Write the reasoning

Show the domain, the key steps and a check of your answer.

A product with a square root

Use logarithmic differentiation to find the derivative of y=x2x+1y=x^2\sqrt{x+1} on x>0, and check it by the product rule.
Compare your solution

Both y and its factors are positive. Take logs:

ln⁡y=2ln⁡x+12ln⁡(x+1),y′y=2x+12(x+1).\ln y=2\ln x+\frac12\ln(x+1),\qquad \frac{y'}{y}=\frac2x+\frac1{2(x+1)}.

Multiply by y and simplify:

y′=2xx+1+x22x+1=x(5x+4)2x+1.y'=2x\sqrt{x+1}+\frac{x^2}{2\sqrt{x+1}}=\frac{x(5x+4)}{2\sqrt{x+1}}.

The ordinary product rule gives the same first sum. The derivation above is on the requested x>0 interval.

A changing base and exponent

Find the derivative of y=x2xy=x^{2x} on x>0, then evaluate it at x=1.
Compare your solution

Take logs: ln⁡y=2xln⁡x\ln y=2x\ln x. Differentiate using the product rule:

y′y=2ln⁡x+2,y′=2x2x(ln⁡x+1).\frac{y'}{y}=2\ln x+2,\qquad y'=2x^{2x}(\ln x+1).

At x=1 this gives y′=2y'=2. The rewrite y=e2xln⁡xy=e^{2x\ln x} gives the same expression using the chain rule.

Class 12 milestone

You can now differentiate a changing power

You have linked slopes, logarithm rules and the chain rule, then used them on positive products and variable powers. Practise x^x once more without the solution. Continue to logarithmic and exponential integrals to reverse the process.