Class 12 Maths, Worked in Full Past papersGet updates
Chapter 5 · Continuity and Differentiability

Example 30: dydx\frac{dy}{dx} if yx+xy+xx=aby^x+x^y+x^x=a^b

ExamplesLogarithmic differentiation · Section 5.5
The question

Find dydx\dfrac{dy}{dx}⁠, if yx+xy+xx=aby^x + x^y + x^x = a^b⁠.

Exam answer

Let u=yxu = y^x⁠, v=xyv = x^y⁠, w=xxw = x^x⁠, where x,y>0x, y > 0⁠. Then u+v+w=abu + v + w = a^b⁠, a constant. Differentiating both sides w.r.t. xx⁠,

dudx+dvdx+dwdx=0…(i)\frac{du}{dx} + \frac{dv}{dx} + \frac{dw}{dx} = 0\quad\ldots(\text{i})

Taking log on both sides of u=yxu = y^x⁠, log⁡u=xlog⁡y\log u = x\log y⁠. Differentiating both sides w.r.t. xx⁠,

1u⋅dudx=xy⋅dydx+log⁡y\frac1u\cdot\frac{du}{dx} = \frac{x}{y}\cdot\frac{dy}{dx} + \log y ⇒ dudx=yx[xy⋅dydx+log⁡y]\Rightarrow\ \frac{du}{dx} = y^x\left[\frac{x}{y}\cdot\frac{dy}{dx} + \log y\right]

Taking log on both sides of v=xyv = x^y⁠, log⁡v=ylog⁡x\log v = y\log x⁠. Differentiating both sides w.r.t. xx⁠,

1v⋅dvdx=yx+log⁡x⋅dydx\frac1v\cdot\frac{dv}{dx} = \frac{y}{x} + \log x\cdot\frac{dy}{dx} ⇒ dvdx=xy[yx+log⁡x⋅dydx]\Rightarrow\ \frac{dv}{dx} = x^y\left[\frac{y}{x} + \log x\cdot\frac{dy}{dx}\right]

Taking log on both sides of w=xxw = x^x⁠, log⁡w=xlog⁡x\log w = x\log x⁠. Differentiating both sides w.r.t. xx⁠,

1w⋅dwdx=x⋅1x+log⁡x=1+log⁡x\frac1w\cdot\frac{dw}{dx} = x\cdot\frac1x + \log x = 1 + \log x ⇒ dwdx=xx(1+log⁡x)\Rightarrow\ \frac{dw}{dx} = x^x(1 + \log x)

Substituting in (i),

yx[xy⋅dydx+log⁡y]+xy[yx+log⁡x⋅dydx]+xx(1+log⁡x)=0\begin{aligned} &y^x\left[\frac{x}{y}\cdot\frac{dy}{dx} + \log y\right] \\ &+ x^y\left[\frac{y}{x} + \log x\cdot\frac{dy}{dx}\right] \\ &+ x^x(1 + \log x) = 0 \end{aligned}

Using yx⋅xy=x yx−1y^x\cdot\frac{x}{y} = x\,y^{x-1} and xy⋅yx=y xy−1x^y\cdot\frac{y}{x} = y\,x^{y-1}⁠, and collecting the dydx\frac{dy}{dx} terms,

(x yx−1+xylog⁡x)dydx=−[yxlog⁡y+y xy−1+xx(1+log⁡x)]\begin{aligned} &\left(x\,y^{x-1} + x^y\log x\right)\frac{dy}{dx} \\ &= -\big[y^x\log y + y\,x^{y-1} \\ &\qquad + x^x(1 + \log x)\big] \end{aligned}

∴ dydx=−ND\therefore\ \dfrac{dy}{dx} = -\dfrac{N}{D}⁠, where N=yxlog⁡y+y xy−1N = y^x\log y + y\,x^{y-1} +xx(1+log⁡x)+ x^x(1 + \log x) and D=x yx−1+xylog⁡xD = x\,y^{x-1} + x^y\log x (x,y>0, D≠0)(x, y > 0,\ D \ne 0)⁠.

Want the reason behind every step, the basics and the checks?

The one idea this problem is built on

Two techniques combine. The relation is implicit (we cannot solve for yy⁠), so we differentiate it term by term. Each term is a power whose base or exponent varies, so each is differentiated by taking logs. Logarithms do not split sums, so we must not take the log of the whole equation; instead we name the three terms uu⁠, vv⁠, ww⁠, differentiate each separately, and add.

Given, to find, and the plan
Given
yx+xy+xx=aby^x + x^y + x^x = a^b⁠, where aa and bb are constants. We work with x>0x > 0 and y>0y > 0⁠, so that all three powers are defined and positive, and (as the book does) take yy to be a differentiable function of xx⁠.
To find
dydx\frac{dy}{dx}⁠, and where the formula holds.
Plan
(1) Put u=yxu = y^x⁠, v=xyv = x^y⁠, w=xxw = x^x⁠, so u′+v′+w′=0u' + v' + w' = 0⁠. (2), (3), (4) Find u′u'⁠, v′v'⁠, w′w' by logarithmic differentiation. (5) Substitute and collect the dydx\frac{dy}{dx} terms. (6) Solve, stating the condition.

Basics you need

1Implicit differentiation

Differentiate every term with respect to xx⁠, writing dydx\frac{dy}{dx} whenever yy is differentiated; then solve for dydx\frac{dy}{dx} (Section 5.3.2). Basics: solving for dy/dx

2Logarithmic differentiation

For a positive uu⁠: ddxlog⁡u=1ududx\frac{d}{dx}\log u = \frac1u\frac{du}{dx}⁠. So if log⁡u\log u is easy to differentiate, dudx=u⋅ddx(log⁡u)\frac{du}{dx} = u\cdot\frac{d}{dx}(\log u) (Section 5.5). Basics: exponentials and logarithms

3Product rule and chain rule

(fg)′=f′g+fg′(fg)' = f'g + fg'⁠; and ddxlog⁡y=1ydydx\frac{d}{dx}\log y = \frac1y\frac{dy}{dx} because yy depends on xx⁠. Basics: derivative rules

Solution

  1. Name the three terms and differentiate the relation

    Put

    u=yx,v=xy,w=xx.u = y^x, \qquad v = x^y, \qquad w = x^x.

    Then u+v+w=abu + v + w = a^b for every xx in question. The right side is a constant, so its derivative is 00⁠, and by the sum rule

    dudx+dvdx+dwdx=0.(1)\frac{du}{dx} + \frac{dv}{dx} + \frac{dw}{dx} = 0. \qquad (1)
    We cannot take the log of the whole equation usefully: log⁡(u+v+w)\log(u + v + w) does not split into log⁡u+log⁡v+log⁡w\log u + \log v + \log w⁠. So we keep the sum, differentiate it term by term, and handle each power on its own. aba^b is a fixed number (aa⁠, bb are constants), not a function of xx⁠.
    Sum rule (u+v+w)′=u′+v′+w′(u + v + w)' = u' + v' + w' (algebra of derivatives, Section 5.3) and derivative of a constant is 00 (Class XI). Lesson: implicit differentiation
  2. dudx\frac{du}{dx} for u=yxu = y^x

    Since y>0y > 0⁠, u>0u > 0 and log⁡u=xlog⁡y\log u = x\log y⁠. Differentiate: the right side is a product of xx and log⁡y\log y⁠, and log⁡y\log y needs the chain rule because yy depends on xx⁠:

    1u⋅dudx=x⋅ddx(log⁡y)+log⁡y⋅ddx(x)=x⋅1y⋅dydx+log⁡y⋅1.\begin{aligned} \frac1u\cdot\frac{du}{dx} &= x\cdot\frac{d}{dx}(\log y) + \log y\cdot\frac{d}{dx}(x) \\ &= x\cdot\frac1y\cdot\frac{dy}{dx} + \log y\cdot 1. \end{aligned}

    Multiply by u=yxu = y^x⁠:

    dudx=yx[xy dydx+log⁡y].(2)\frac{du}{dx} = y^x\left[\frac{x}{y}\,\frac{dy}{dx} + \log y\right]. \qquad (2)
    In yxy^x both the base (yy⁠, which depends on xx⁠) and the exponent (xx⁠) vary, so neither the power rule nor the axa^x rule applies on its own. Taking logs turns the power into the product xlog⁡yx\log y⁠. The factor dydx\frac{dy}{dx} appears because we differentiate log⁡y\log y with respect to xx⁠, not yy⁠.
    log⁡pn=nlog⁡p\log p^n = n\log p (Section 5.4); product rule; chain rule. Lesson: logarithmic differentiation
  3. dvdx\frac{dv}{dx} for v=xyv = x^y

    Since x>0x > 0⁠, v>0v > 0 and log⁡v=ylog⁡x\log v = y\log x⁠. Product rule again:

    1v⋅dvdx=y⋅ddx(log⁡x)+log⁡x⋅dydx=yx+log⁡x⋅dydx.\begin{aligned} \frac1v\cdot\frac{dv}{dx} &= y\cdot\frac{d}{dx}(\log x) + \log x\cdot\frac{dy}{dx} \\ &= \frac{y}{x} + \log x\cdot\frac{dy}{dx}. \end{aligned}

    Multiply by v=xyv = x^y⁠:

    dvdx=xy[yx+log⁡x dydx].(3)\frac{dv}{dx} = x^y\left[\frac{y}{x} + \log x\,\frac{dy}{dx}\right]. \qquad (3)
    This time the factor that needs dydx\frac{dy}{dx} is yy itself, whose derivative with respect to xx is dydx\frac{dy}{dx}⁠; and log⁡x\log x differentiates to 1x\frac1x directly.
    ddxlog⁡x=1x\frac{d}{dx}\log x = \frac1x (Theorem 5); product rule (Section 5.3). Basics: derivative rules
  4. dwdx\frac{dw}{dx} for w=xxw = x^x

    log⁡w=xlog⁡x\log w = x\log x⁠, so

    1w⋅dwdx=x⋅1x+log⁡x⋅1=1+log⁡x,\frac1w\cdot\frac{dw}{dx} = x\cdot\frac1x + \log x\cdot 1 = 1 + \log x, dwdx=xx(1+log⁡x).(4)\frac{dw}{dx} = x^x(1 + \log x). \qquad (4)
    Here yy does not appear, so no dydx\frac{dy}{dx} arises. This result, ddxxx=xx(1+log⁡x)\frac{d}{dx}x^x = x^x(1 + \log x)⁠, is worth remembering: it is a standard example of logarithmic differentiation.
    Product rule on xlog⁡xx\log x⁠. Lesson: logarithmic differentiation
  5. Substitute into (1) and collect the dydx\frac{dy}{dx} terms

    Putting (2), (3), (4) into (1):

    yx[xydydx+log⁡y]+xy[yx+log⁡xdydx]+xx(1+log⁡x)=0.\begin{aligned} &y^x\left[\frac{x}{y}\frac{dy}{dx} + \log y\right] + x^y\left[\frac{y}{x} + \log x\frac{dy}{dx}\right] \\ &\quad + x^x(1 + \log x) = 0. \end{aligned}

    Simplify the two mixed products with the index law: yx⋅xy=x yx−1y^x\cdot\frac{x}{y} = x\,y^{x-1} and xy⋅yx=y xy−1x^y\cdot\frac{y}{x} = y\,x^{y-1}⁠. Keep the dydx\frac{dy}{dx} terms on the left and move the rest to the right:

    (x yx−1+xylog⁡x)dydx=−[yxlog⁡y+y xy−1+xx(1+log⁡x)].\begin{aligned} &\left(x\,y^{x-1} + x^y\log x\right)\frac{dy}{dx} \\ &= -\left[y^x\log y + y\,x^{y-1} + x^x(1 + \log x)\right]. \end{aligned}
    After implicit differentiation the equation is linear in dydx\frac{dy}{dx}⁠. The terms containing it are xyx−1dydxx y^{x-1}\frac{dy}{dx} (from u′u'⁠) and xylog⁡xdydxx^y\log x\frac{dy}{dx} (from v′v'⁠); everything else is moved across with its sign changed.
    yxy=yx−1\frac{y^x}{y} = y^{x-1} and xyx=xy−1\frac{x^y}{x} = x^{y-1} for x,y>0x, y > 0⁠. Basics: solving for dy/dx
  6. Solve for dydx\frac{dy}{dx}⁠, with the condition

    dydx=−ND,\frac{dy}{dx} = -\frac{N}{D},

    where

    N=yxlog⁡y+y xy−1+xx(1+log⁡x),D=x yx−1+xylog⁡x,\begin{aligned} N &= y^x\log y + y\,x^{y-1} + x^x(1 + \log x), \\ D &= x\,y^{x-1} + x^y\log x, \end{aligned}

    valid wherever the denominator D=x yx−1+xylog⁡x≠0D = x\,y^{x-1} + x^y\log x \ne 0⁠.

    We may only divide by a non-zero quantity. For x≥1x \ge 1 the denominator is certainly positive (xyx−1>0x y^{x-1} > 0 and log⁡x≥0\log x \ge 0⁠). For 0<x<10 < x < 1⁠, log⁡x<0\log x < 0 and the denominator can vanish at some points of a curve of this family (for example it is zero at some yy between 11 and 33 when x=0.1x = 0.1⁠); there the formula does not apply.
    Division requires a non-zero divisor. Basics: solving for dy/dx
Result

For x>0x > 0⁠, y>0y > 0⁠, wherever x yx−1+xylog⁡x≠0x\,y^{x-1} + x^y\log x \ne 0⁠:

dydx=−ND,N=yxlog⁡y+y xy−1+xx(1+log⁡x),D=x yx−1+xylog⁡x.\begin{aligned} \frac{dy}{dx} &= -\frac{N}{D}, \\ N &= y^x\log y + y\,x^{y-1} \\ &\quad + x^x(1 + \log x), \\ D &= x\,y^{x-1} + x^y\log x. \end{aligned}

(Written as a single fraction, −ND-\frac{N}{D} is exactly the book's answer.)

Check it with numbers

Choose a=2a = 2⁠, b=2b = 2⁠, so ab=4a^b = 4⁠. The point (1,2)(1, 2) lies on the curve: 21+12+11=42^1 + 1^2 + 1^1 = 4⁠. There the formula gives

dydx=−2log⁡2+2⋅1+1⋅(1+0)1⋅20+1⋅0=−(3+2log⁡2)=−4.3862944…\begin{aligned} \frac{dy}{dx} &= -\frac{2\log 2 + 2\cdot 1 + 1\cdot(1 + 0)}{1\cdot 2^0 + 1\cdot 0} \\ &= -(3 + 2\log 2) \\ &= -4.3862944\ldots \end{aligned}

Solving yx+xy+xx=4y^x + x^y + x^x = 4 numerically for yy at x=0.9999x = 0.9999 and x=1.0001x = 1.0001 and dividing the change in yy by 0.00020.0002 gives −4.38629…-4.38629\ldots⁠, the same value.

Common mistakes
  1. Taking the log of the whole equation and writing log⁡(yx+xy+xx)\log(y^x + x^y + x^x) as xlog⁡y+ylog⁡x+xlog⁡xx\log y + y\log x + x\log x⁠. Logs do not split sums.
  2. Treating yxy^x like xnx^n or axa^x⁠. Both base and exponent vary; use logs.
  3. Forgetting dydx\frac{dy}{dx} when differentiating log⁡y\log y or yy with respect to xx⁠.
  4. Treating aba^b as variable. It is a constant, so its derivative is 00⁠.
  5. Sign errors when moving terms across; the whole bracket in the numerator is negated.
What to take away
  1. For a sum of awkward powers: name each term, differentiate each by logs, and add. Never log a sum.
  2. Useful results: ddxxx=xx(1+log⁡x)\frac{d}{dx}x^x = x^x(1 + \log x)⁠, and ddxuv=uv[vuu′+v′log⁡u]\frac{d}{dx}u^v = u^v\left[\frac{v}{u}u' + v'\log u\right]⁠.
  3. An implicit derivative is valid only where the coefficient of dydx\frac{dy}{dx} is non-zero; say so.

Every fact used, and where it comes from

FactUsed inSource
Sum rule; derivative of a constant is 0Step 1Algebra of derivatives, Section 5.3; derivative of a constant, Class XI (Limits and Derivatives)
Implicit differentiationSteps 1, 5, 6Section 5.3.2 (Lesson: implicit differentiation)
Logarithmic differentiation (positive bases)Steps 2–4Section 5.5 (Lesson: logarithmic differentiation)
log⁡pn=nlog⁡p\log p^n = n\log p⁠; ddxlog⁡x=1x\frac{d}{dx}\log x = \frac1xSteps 2–4Section 5.4; Theorem 5
Product rule; chain ruleSteps 2–4Section 5.3; Theorem 4, Section 5.3.1
Index laws pmp=pm−1\frac{p^m}{p} = p^{m-1}Step 5Exponents (Class XI)
Found an error, or want more?

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 →