Example 27: Log-differentiate
Differentiate w.r.t. .
Let , . Taking log on both sides,
Differentiating both sides w.r.t. ,
.
Want the reason behind every step, the basics and the checks?
A square root of a product divided by something is painful with the product and quotient rules. Taking logarithms turns the root into a factor , the product into a sum and the quotient into a difference. Sums are easy to differentiate term by term. This is logarithmic differentiation. Its one demand is that every quantity we take the log of is positive, so we first find where that is true.
- Given
- .
- To find
- , and where it is valid.
- Plan
- (1) Find where is defined and where the logs exist. (2) Take logs and expand with the log laws. (3) Differentiate both sides. (4) Multiply by . (5) Look at the endpoint .
Basics you need
, , , all for . With : . Basics: exponentials and logarithms
By the chain rule and Theorem 5: , where . In particular . Basics: derivative rules
If and the discriminant , then for every (the parabola opens upward and never meets the -axis). This is from Class XI (quadratic equations).
Solution
Where is defined, and where can we take logs?
Look at the sign of each factor.
- for every .
- : here and , so it is positive for every . Completing the square shows it directly:
- is positive for , zero at , negative for .
So the fraction under the root has the sign of . A real square root needs it , so is defined for . For the logarithms we need , so we work on
The book stresses that in logarithmic differentiation the function and the quantities whose logs we take must be positive, "as otherwise their logarithms are not defined". Its solution does not say where this holds; here it is . The point (where ) is treated separately in Step 5.A quadratic with positive leading coefficient and negative discriminant is always positive (Basic 3).Take logarithms and expand
For , write the root as a power,
and take of both sides:
Three log laws are used, each valid because every quantity is positive for : brings the root down as a factor; splits the product and the quotient. The right side is now a sum of simple logs, each of which we can differentiate with one chain-rule step.Differentiate both sides with respect to
Left side: the outer function is , the inner is , so . Right side: use on each term:
So
Each log term is a composite with outer and an inner polynomial . The chain rule gives times . The inner derivatives are , and by the power rule. Forgetting them (writing just ) is the classic error.Theorem 5 (2) and the chain rule: . Lesson: logarithmic differentiationMultiply by and substitute it back
that is, for ,
The left side was ; multiplying both sides by isolates . We then replace by its formula so the answer is in alone. This is exactly the book's final form.What happens at ?
At , and the log method cannot be used. Near , (using and ), so the right-hand difference quotient behaves like
which grows without bound as . The graph starts at with a vertical tangent, and has no derivative there.
This explains why the formula is valid only for : the factor in the bracket blows up as , and the derivative really does not exist at . The function is not defined at all for .A derivative exists only when the limit of the difference quotient is finite (Section 5.3). Basics: slope at a point
For ,
(This is the book's answer. The function exists only for ; the formula holds for , and at there is no derivative.)
At : . The bracket is . So
The central difference quotient gives , the same to 7 decimal places.
- Forgetting the on the left: , not .
- Dropping inner derivatives: , not .
- "Log of a sum is the sum of the logs." False: . Only products and quotients split.
- Losing the from the square root, or forgetting to multiply back by at the end.
- Ignoring where the logs exist; here only .
- Logarithmic differentiation: take logs, expand with the log laws, differentiate (left side gives ), multiply by .
- It pays off whenever the function is built from products, quotients and powers of several factors.
- First find where every logged quantity is positive; the answer is valid only there.
Every fact used, and where it comes from
| Fact | Used in | Source |
|---|---|---|
| Positivity requirement for logarithmic differentiation | Step 1 | Section 5.5 (Lesson: logarithmic differentiation) |
| Quadratic with , is always positive | Step 1 | Quadratic equations (Class XI) |
| , , laws | Step 2 | Section 5.4 |
| ; chain rule | Step 3 | Theorem 5, Section 5.4; Theorem 4, Section 5.3.1 |
| Power rule for the inner derivatives | Step 3 | Table 5.3, Section 5.3 |
| Derivative as a finite limit | Step 5 | Section 5.3 |
Tell us if something on this page is wrong or unclear, or if you would like a fuller explanation, another method or a new feature. Send feedback on this problem →