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

Exercise 5.7 · Q13: y=3cos⁡(log⁡x)+4sin⁡(log⁡x)y=3\cos(\log x)+4\sin(\log x) satisfies x2y2+xy1+y=0x^2y_2+xy_1+y=0

Exercise 5.7Second order derivative · Section 5.7
The question

13. If y=3cos⁡(log⁡x)+4sin⁡(log⁡x)y = 3\cos(\log x) + 4\sin(\log x)⁠, show that x2y2+xy1+y=0x^2y_2 + xy_1 + y = 0⁠.

Exam answer

Here y=3cos⁡(log⁡x)+4sin⁡(log⁡x)y = 3\cos(\log x) + 4\sin(\log x)⁠, x>0x \gt 0⁠. Differentiating w.r.t. xx⁠,

y1=−3sin⁡(log⁡x)x+4cos⁡(log⁡x)x⇒ xy1=4cos⁡(log⁡x)−3sin⁡(log⁡x)\begin{aligned} y_1 &= -\frac{3\sin(\log x)}{x} \\ &\quad + \frac{4\cos(\log x)}{x} \\ \Rightarrow\ xy_1 &= 4\cos(\log x) \\ &\quad - 3\sin(\log x) \end{aligned}

Differentiating again w.r.t. xx (product rule on the left),

xy2+y1=−4sin⁡(log⁡x)x−3cos⁡(log⁡x)x=−yx\begin{aligned} xy_2 + y_1 &= -\frac{4\sin(\log x)}{x} \\ &\quad - \frac{3\cos(\log x)}{x} \\ &= -\frac{y}{x} \end{aligned}

Multiplying by xx⁠, x2y2+xy1=−yx^2y_2 + xy_1 = -y⁠.

∴ x2y2+xy1+y=0\therefore\ x^2y_2 + xy_1 + y = 0⁠. Hence proved.

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

The one idea this problem is built on

Every derivative of a function of log⁡x\log x brings out a factor 1x\frac{1}{x}⁠. Multiplying y1y_1 by xx removes it:

x y1=4cos⁡(log⁡x)−3sin⁡(log⁡x).x\,y_1 = 4\cos(\log x) - 3\sin(\log x).

Differentiating this equation once more (product rule on the left) gives xy2+y1xy_2 + y_1 on the left and −yx-\frac{y}{x} on the right. Multiplying by xx gives the relation.

Given, to show, and the plan
Given
y=3cos⁡(log⁡x)+4sin⁡(log⁡x)y = 3\cos(\log x) + 4\sin(\log x)⁠, defined for x>0x \gt 0 (where log⁡x\log x exists). Notation: y1=dydxy_1 = \frac{dy}{dx}⁠, y2=d2ydx2y_2 = \frac{d^2y}{dx^2}⁠.
To show
x2y2+xy1+y=0x^2y_2 + xy_1 + y = 0 for every x>0x \gt 0⁠.
Plan
(1) Find y1y_1 by the chain rule. (2) Multiply by xx and differentiate again. (3) Rearrange into the required form. (4) As an independent check, compute y2y_2 explicitly and add up the left side term by term.

Basics you need

1Chain rule with log⁡x\log x inside

With inner function u=log⁡xu = \log x⁠, dudx=1x\frac{du}{dx} = \frac{1}{x} (x>0x \gt 0⁠), so

ddxsin⁡(log⁡x)=cos⁡(log⁡x)x,ddxcos⁡(log⁡x)=−sin⁡(log⁡x)x.\begin{aligned} \tfrac{d}{dx}\sin(\log x) &= \tfrac{\cos(\log x)}{x}, \\ \tfrac{d}{dx}\cos(\log x) &= -\tfrac{\sin(\log x)}{x}. \end{aligned}

(The first is Example 26(ii).) Lesson: chain rule

2Product rule

(uv)′=u′v+uv′(uv)' = u'v + uv' (Section 5.3, rule (2)). Basics: derivative rules

3Quotient rule

(uv)′=u′v−uv′v2\left(\frac{u}{v}\right)' = \frac{u'v - uv'}{v^2}⁠, v≠0v \neq 0 (Section 5.3, rule (3)); used in the check.

4Second order derivative (Section 5.7)

y2=ddx(y1)y_2 = \frac{d}{dx}(y_1)⁠. Lesson: second order derivative

Solution

  1. Domain

    log⁡x\log x needs x>0x \gt 0⁠; sin⁡\sin and cos⁡\cos accept every real number. So yy is defined, and differentiable, exactly for x>0x \gt 0⁠. Everything below is for x>0x \gt 0⁠, and in particular x≠0x \neq 0⁠.

    We shall divide by xx and multiply equations by xx⁠; knowing x>0x \gt 0 makes both safe.
  2. First derivative y1y_1

    Term by term with Basic 1:

    y1=3(−sin⁡(log⁡x)x)+4⋅cos⁡(log⁡x)x=4cos⁡(log⁡x)−3sin⁡(log⁡x)x.\begin{aligned} y_1 &= 3\left(-\frac{\sin(\log x)}{x}\right) + 4\cdot\frac{\cos(\log x)}{x} \\ &= \frac{4\cos(\log x) - 3\sin(\log x)}{x}. \end{aligned}
    Both terms are "trig of log⁡x\log x", so both get the chain-rule factor 1x\frac{1}{x}⁠. We combine them over the common denominator xx⁠.
    Basic 1; sum rule, Section 5.3, rule (1); constant multiples (Class XI, Limits and Derivatives). Lesson: chain rule
  3. Clear the denominator

    Multiply both sides by xx⁠:

    x y1=4cos⁡(log⁡x)−3sin⁡(log⁡x).x\,y_1 = 4\cos(\log x) - 3\sin(\log x).
    Now the right side is again a combination of cos⁡(log⁡x)\cos(\log x) and sin⁡(log⁡x)\sin(\log x) with no fraction, so differentiating it is as easy as Step 2. The left side is a simple product.
  4. Differentiate both sides with respect to xx

    Left side, product rule with u=xu = x⁠, v=y1v = y_1⁠: ddx(x y1)=1⋅y1+x y2\frac{d}{dx}(x\,y_1) = 1\cdot y_1 + x\,y_2⁠.

    Right side, Basic 1 again:

    ddx[4cos⁡(log⁡x)−3sin⁡(log⁡x)]=−4sin⁡(log⁡x)x−3cos⁡(log⁡x)x=−3cos⁡(log⁡x)+4sin⁡(log⁡x)x=−yx.\begin{aligned} &\frac{d}{dx}\big[4\cos(\log x) - 3\sin(\log x)\big] \\ &= -\frac{4\sin(\log x)}{x} - \frac{3\cos(\log x)}{x} \\ &= -\frac{3\cos(\log x) + 4\sin(\log x)}{x} = -\frac{y}{x}. \end{aligned}

    So

    x y2+y1=−yx.x\,y_2 + y_1 = -\frac{y}{x}.
    Two expressions that are equal for every x>0x \gt 0 have equal derivatives. On the right, after collecting, the bracket 3cos⁡(log⁡x)+4sin⁡(log⁡x)3\cos(\log x) + 4\sin(\log x) is exactly the original yy⁠. That is the whole trick of this question.
    Product rule (Basic 2); the derivative of y1y_1 is y2y_2 (Basic 4).
  5. Multiply by xx and rearrange

    x2y2+x y1=−y,x2y2+x y1+y=0.\begin{aligned} x^2y_2 + x\,y_1 &= -y, \\ x^2y_2 + x\,y_1 + y &= 0. \end{aligned}

    This is the required relation, for every x>0x \gt 0⁠.

    Multiplying x y2+y1=−yxx\,y_2 + y_1 = -\frac{y}{x} by xx (which is not zero) gives an equivalent equation without fractions; moving −y-y to the left gives the form asked for.
  6. Independent check: compute y2y_2 and each term of the left side

    Write y1=uxy_1 = \frac{u}{x} with u=4cos⁡(log⁡x)−3sin⁡(log⁡x)u = 4\cos(\log x) - 3\sin(\log x)⁠. From Step 4, u′=−3cos⁡(log⁡x)+4sin⁡(log⁡x)xu' = -\frac{3\cos(\log x) + 4\sin(\log x)}{x}⁠. By the quotient rule,

    y2=u′⋅x−u⋅1x2=−3cos⁡(log⁡x)−4sin⁡(log⁡x)−ux2=−7cos⁡(log⁡x)+sin⁡(log⁡x)x2,\begin{aligned} y_2 &= \frac{u'\cdot x - u\cdot 1}{x^2} \\ &= \frac{-3\cos(\log x) - 4\sin(\log x) - u}{x^2} \\ &= -\frac{7\cos(\log x) + \sin(\log x)}{x^2}, \end{aligned}

    since on top the cos⁡(log⁡x)\cos(\log x) terms give −3−4=−7-3 - 4 = -7 and the sin⁡(log⁡x)\sin(\log x) terms give −4+3=−1-4 + 3 = -1⁠. Now each term of the left side:

    x2y2=−7cos⁡(log⁡x)−sin⁡(log⁡x),x y1=4cos⁡(log⁡x)−3sin⁡(log⁡x),y=3cos⁡(log⁡x)+4sin⁡(log⁡x).\begin{aligned} x^2y_2 &= -7\cos(\log x) - \sin(\log x), \\ x\,y_1 &= 4\cos(\log x) - 3\sin(\log x), \\ y &= 3\cos(\log x) + 4\sin(\log x). \end{aligned}

    Adding: the cos⁡(log⁡x)\cos(\log x) coefficients give −7+4+3=0-7 + 4 + 3 = 0 and the sin⁡(log⁡x)\sin(\log x) coefficients give −1−3+4=0-1 - 3 + 4 = 0⁠. So the left side is 00⁠, the right side.

    This route computes the left side completely, term by term, without the "differentiate an equation" trick. Both routes agree.
    Quotient rule, Section 5.3, rule (3). Basics: derivative rules
Result

For x>0x \gt 0⁠: y1=4cos⁡(log⁡x)−3sin⁡(log⁡x)xy_1 = \dfrac{4\cos(\log x) - 3\sin(\log x)}{x}⁠, y2=−7cos⁡(log⁡x)+sin⁡(log⁡x)x2y_2 = -\dfrac{7\cos(\log x) + \sin(\log x)}{x^2}⁠, and

x2y2+xy1+y=0.x^2y_2 + xy_1 + y = 0.

(The answer key gives no entry for this "show that" question.)

Check it with numbers

Take x=2x = 2⁠: cos⁡(log⁡2)≈0.7692389\cos(\log 2) \approx 0.7692389⁠, sin⁡(log⁡2)≈0.6389613\sin(\log 2) \approx 0.6389613⁠. Then

y≈4.8635618,y1≈0.5800359,y2≈−1.5059084,\begin{aligned} y &\approx 4.8635618, \\ y_1 &\approx 0.5800359, \\ y_2 &\approx -1.5059084, \end{aligned}

so x2y2≈−6.0236336x^2y_2 \approx -6.0236336 and xy1≈1.1600718xy_1 \approx 1.1600718⁠, and

−6.0236336+1.1600718+4.8635618=0.-6.0236336 + 1.1600718 + 4.8635618 = 0.

From values of yy alone, with h=0.001h = 0.001⁠, the second difference y(2.001)−2y(2)+y(1.999)h2\frac{y(2.001) - 2y(2) + y(1.999)}{h^2} is about −1.505909-1.505909⁠, matching y2y_2⁠.

Common mistakes
  1. Forgetting the factor 1x\frac{1}{x}⁠. Both sin⁡(log⁡x)\sin(\log x) and cos⁡(log⁡x)\cos(\log x) need the chain rule.
  2. Not using the product rule on x y1x\,y_1⁠. ddx(x y1)=y1+x y2\frac{d}{dx}(x\,y_1) = y_1 + x\,y_2⁠, not just x y2x\,y_2⁠.
  3. Sign slips. ddxcos⁡(log⁡x)=−sin⁡(log⁡x)x\frac{d}{dx}\cos(\log x) = -\frac{\sin(\log x)}{x}⁠; track every minus sign.
  4. Ignoring the domain. The relation is about x>0x \gt 0 only.
What to take away
  1. When derivatives carry a factor 1x\frac{1}{x}⁠, multiply it away before differentiating again; the product rule then delivers terms like xy2+y1xy_2 + y_1⁠.
  2. Look for the original yy reappearing after differentiation; it is what makes relations like x2y2+xy1+y=0x^2y_2 + xy_1 + y = 0 close up.
  3. Compare Question 10, the second derivative of sin⁡(log⁡x)\sin(\log x) alone.

Every fact used, and where it comes from

FactUsed inSource
log⁡x\log x defined for x>0x \gt 0⁠; ddxlog⁡x=1x\frac{d}{dx}\log x = \frac{1}{x}Steps 1, 2, 4Section 5.4, Theorem 5 (Lesson: exponential and logarithmic functions)
ddxsin⁡x=cos⁡x\frac{d}{dx}\sin x = \cos x⁠, ddxcos⁡x=−sin⁡x\frac{d}{dx}\cos x = -\sin xSteps 2, 4Table 5.3, Section 5.3
Chain rule; ddxsin⁡(log⁡x)=cos⁡(log⁡x)x\frac{d}{dx}\sin(\log x) = \frac{\cos(\log x)}{x}Steps 2, 4Theorem 4, Section 5.3.1; Example 26(ii) (Lesson: chain rule)
Sum, product and quotient rules; constant multiplesSteps 2, 4, 6Section 5.3, rules (1)–(3); constant multiples, Class XI (Basics: derivative rules)
y1=dydxy_1 = \frac{dy}{dx}⁠, y2=d2ydx2y_2 = \frac{d^2y}{dx^2}Steps 2–6Section 5.7 (Lesson: second order derivative)
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 →