Hersi Maths WhatsApp me

Understand · explore · practise

Logarithmic differentiation

Differentiate x to the power x and other variable powers using logarithms. Separate base and exponent contributions, simplify products and quotients, and keep real-domain restrictions.

Before you startImplicit differentiation; chain rule; natural logarithm laws

01 / Let logarithms expose a changing exponent

The power rule alone does not handle a variable exponent.

If y = uᵛ with u > 0:
ln y = v ln u
y′/y = v′ ln u + v u′/u

The formula has two contributions: one from the changing exponent and one from the changing base. Multiply by y at the end to obtain y′. Here u and v are differentiable functions of x on the interval being considered.

Changing base, changing exponentExplore
Logarithmic derivative contributionsFor x to the power x at x = 1, the base contribution to y′/y is 1 and the exponent contribution is zero.0.22Base termExponent termTotal y′/y101Bars show relative rates; multiply the total by y

u = x; v = x. Base term = 1; exponent term = ln x.

x = 1; y = 1; y′/y = 1; y′ = 1.

Both base and exponent vary. Add their relative contributions, then multiply by the function value.

All model inputs have a positive base. Negative bars mean a negative contribution. The bars show y′/y, while the gold tangent shows the actual derivative y′.

02 / Differentiate x to the power x

Both the base and the exponent depend on x.

y = xˣ, for x > 0Worked example

ln y = x ln x

Take natural logs on the positive domain.

y′/y = ln x + 1

Differentiate the right side with the product rule.

y′ = y(ln x + 1)

Multiply by y; the left derivative was y′/y, not y′.

y′ = xˣ(ln x + 1)

Replace y with the original function.

Watch the two contributions to the logarithmic derivative

Pause, replay or seek freely. The notes explain the same idea and stay in view.

01 · Gradient at one

Find the tangent to y = xˣ at x = 1.

Hint

1¹ = 1 and ln 1 = 0.

Worked solution

The gradient is 1, and the point is (1, 1). The tangent is y − 1 = x − 1, or y = x.

03 / Distinguish constant and variable powers

Choose a rule by what is changing.

Compare three expressionsWorked example

y = x²: y′ = 2x

Only the base varies; the ordinary power rule applies.

y = 2ˣ: y′ = 2ˣ ln 2

Only the exponent varies; use the exponential derivative.

y = xˣ: y′ = xˣ(ln x + 1)

Both vary, so both contributions are needed.

02 · Find the missing term

A student writes d/dx(xˣ) = x·x^(x − 1) = xˣ. Why is that incomplete?

Hint

The power-rule calculation has treated the exponent as constant.

Worked solution

It captures only the changing-base contribution. The additional changing-exponent term is xˣ ln x, so the full derivative is xˣ(1 + ln x).

03 · A scaled exponent

Differentiate y = x^(2x), for x > 0.

Hint

ln y = 2x ln x.

Worked solution

y′/y = 2 ln x + 2, hence y′ = 2x^(2x)(ln x + 1).

04 / Differentiate a changing base and exponent

Use the product rule after taking logs.

y = (x + 2)ˣ, for x > −2Worked example

ln y = x ln(x + 2)

The positive-base condition gives the stated domain.

y′/y = ln(x + 2) + x/(x + 2)

Differentiate both factors.

y′ = (x + 2)ˣ[ln(x + 2) + x/(x + 2)]

Restore the original function.

04 · Gradient at zero

Find the derivative of (x + 2)ˣ at x = 0.

Hint

The function value is 2⁰ = 1.

Worked solution

The derivative is ln 2, since the base-change contribution x/(x + 2) vanishes at zero.

05 · Two nonlinear parts

Differentiate (3x + 1)^(x²) for x > −1/3.

Hint

Differentiate x² ln(3x + 1).

Worked solution

The derivative is (3x + 1)^(x²)[2x ln(3x + 1) + 3x²/(3x + 1)].

05 / Use trig functions in a variable power

Keep the positive-base domain and radian convention.

y = x^(sin x), for x > 0Worked example

ln y = sin x · ln x

Take natural logs.

y′/y = cos x ln x + sin x/x

The derivative of sin x assumes radians.

y′ = x^(sin x)[cos x ln x + sin x/x]

Multiply by the original y.

06 · Trig in the base

Differentiate (sin x)ˣ on 0 < x < π.

Hint

The sine is positive on this interval.

Worked solution

The derivative is (sin x)ˣ[ln(sin x) + x cot x]. The formula is justified on the stated open interval.

07 · An exponential simplification

Differentiate (eˣ)^(cos x) for real x.

Hint

Rewrite it as e^(x cos x).

Worked solution

The derivative is e^(x cos x)(cos x − x sin x). This agrees with logarithmic differentiation and the base is positive everywhere.

06 / Turn a product into a sum of logarithms

This can be shorter than repeated product and quotient rules.

y = x²(x + 1)³/(x + 2), for x > 0Worked example

ln y = 2 ln x + 3 ln(x + 1) − ln(x + 2)

All factors in these logarithms are positive on the chosen domain.

y′/y = 2/x + 3/(x + 1) − 1/(x + 2)

Differentiate each term.

y′ = [x²(x + 1)³/(x + 2)] [2/x + 3/(x + 1) − 1/(x + 2)]

A factored answer is often clearer than an expansion.

08 · Evaluate a product derivative

For this y, find y′ at x = 1.

Hint

First find y = 8/3 and the bracket 2 + 3/2 − 1/3.

Worked solution

The bracket is 19/6, so y′ = (8/3)(19/6) = 76/9.

09 · Roots and quotients

Differentiate y = √x (x + 2)²/(x + 1), for x > 0.

Hint

Use ln y = ½ ln x + 2 ln(x + 2) − ln(x + 1).

Worked solution

y′ = [√x (x + 2)²/(x + 1)] [1/(2x) + 2/(x + 2) − 1/(x + 1)].

07 / Use ln|y| on a nonzero branch

The absolute value allows a negative function value.

d/dx[ln|y|] = y′/y, where y ≠ 0

y = x²(x − 2), away from its zerosWorked example

ln|y| = 2 ln|x| + ln|x − 2|

Work on intervals excluding x = 0 and x = 2.

y′/y = 2/x + 1/(x − 2)

The log derivatives keep the signed denominators.

y′ = x²(x − 2)[2/x + 1/(x − 2)] = 3x² − 4x

This simplifies to the polynomial derivative away from the zeros.

At x = 0 and x = 2, differentiate the original polynomial

The derivative exists there: 0 and 4 respectively. The log step itself was not valid at those zeros.

10 · A negative value

For y = x²(x − 2), find the value and derivative at x = 1.

Hint

The value is negative, so ln y is not real. ln|y| is valid.

Worked solution

y = −1; y′ = −1. Logarithmic differentiation gives y′/y = 2 − 1 = 1, then y′ = (−1)·1 = −1.

11 · Do not divide by a zero

Why can the log formula for this polynomial not be substituted into at x = 2, although its derivative is 4 there?

Hint

The function value is zero.

Worked solution

ln|y| and y′/y are undefined at y = 0. Use the original polynomial or a justified limit of the simplified derivative; do not substitute into a formula containing 1/(x − 2).

08 / State where the logarithmic argument is valid

A variable real power is safely defined using a positive base.

For a general real exponent v(x), define u(x)^v(x) = exp[v(x) ln u(x)] on intervals where u(x) > 0. Negative bases may give isolated real values for certain rational exponents, but this does not create an open real domain for the same general logarithmic formula.

Do not claim that every power with a negative base is undefined: a fixed integer power such as x³ is defined for negative x. Choose the domain for the actual function and method.

12 · A shifted variable power

Give a positive-base interval and derivative for (x − 1)^(x + 1).

Hint

Require x − 1 > 0.

Worked solution

On x > 1, the derivative is (x − 1)^(x + 1)[ln(x − 1) + (x + 1)/(x − 1)]. No claim is made about an extension at or below x = 1.

09 / Use the sign of the logarithmic derivative

For positive y, y′ and y′/y have the same sign.

Find the minimum of y = xˣ on x > 0Worked example

y′ = xˣ(ln x + 1)

The factor xˣ is positive.

ln x + 1 = 0 gives x = e⁻¹

There is exactly one stationary input.

y′ < 0 before e⁻¹ and y′ > 0 after e⁻¹

The function decreases then increases.

Minimum point: (e⁻¹, e^(−1/e))

The minimum is attained on the positive domain.

13 · A related minimum

Find the stationary point of y = x^(2x), x > 0, and classify it.

Hint

The sign comes from 2(ln x + 1).

Worked solution

The minimum is at (e⁻¹, e^(−2/e)). The derivative changes from negative to positive.

10 / Separate a relative rate from an absolute rate

The logarithmic derivative still needs the function value.

At x = 2 for y = xˣWorked example

y = 4

Evaluate the original function.

y′/y = ln 2 + 1

This is the relative rate per unit x.

y′ = 4(ln 2 + 1)

Multiply to obtain the actual gradient.

14 · Spot the unfinished answer

For y = (x + 1)ˣ, a solution stops at ln(x + 1) + x/(x + 1). What quantity has it found?

Hint

It came from differentiating ln y.

Worked solution

It has found y′/y. Multiply by (x + 1)ˣ to obtain y′, on x > −1.

15 · Relative and absolute rates

If y = 6 and y′/y = −0.4 at a point, find y′.

Hint

Multiply the relative rate by y.

Worked solution

y′ = 6(−0.4) = −2.4. The two quantities have different meanings.

11 / Take logs, differentiate and restore y

Check the domain before applying a log law.

  • For a variable power, separate the contributions of base and exponent.
  • Use product rules after taking logs when both factors vary.
  • The derivative of ln y is y′/y.
  • Multiply by the original y to finish.
  • Use ln|y| on nonzero branches when signs matter.
  • Check zeros and excluded points directly from the original function.

16 · A final variable power

Differentiate y = (x² + 1)^(2x) for real x.

Hint

The base is positive for every real x.

Worked solution

y′ = (x² + 1)^(2x)[2 ln(x² + 1) + 4x²/(x² + 1)].

Section 1 of 11 · Let logarithms expose a changing exponent