Class 12 Maths, Worked in Full Past papersGet updates
Chapter 9 · Differential Equations

Miscellaneous · Q11: dydx+ycot⁡x=4xcosec⁡x\frac{dy}{dx} + y\cot x = 4x\operatorname{cosec}x⁠, y(π2)=0y(\frac{\pi}{2}) = 0

Miscellaneous ExerciseLinear differential equations, particular solution · Section 9.4.3
The question

11. Find a particular solution of the differential equation dydx+ycot⁡x=4x cosec x\dfrac{dy}{dx} + y\cot x = 4x\,\text{cosec}\,x (x≠0)(x \ne 0)⁠, given that y=0y = 0 when x=π2x = \dfrac{\pi}{2}⁠.

Exam answer

This is a linear differential equation of the form dydx+Py=Q\frac{dy}{dx} + Py = Q⁠, where P=cot⁡xP = \cot x and Q=4x cosec xQ = 4x\,\text{cosec}\,x⁠.

I.F.=e∫cot⁡x dx=elog⁡sin⁡x=sin⁡x\begin{aligned} \text{I.F.} &= e^{\int\cot x\,dx} \\ &= e^{\log\sin x} = \sin x \end{aligned}

So the solution is given by

ysin⁡x=∫4x cosec xsin⁡x dx+C=∫4x dx+C=2x2+C…(i)\begin{aligned} y\sin x &= \int 4x\,\text{cosec}\,x\sin x\,dx \\ &\qquad + C \\ &= \int 4x\,dx + C \\ &= 2x^2 + C\quad\ldots(\text{i}) \end{aligned}

Putting x=π2x = \frac{\pi}{2}⁠, y=0y = 0 in (i),

0⋅sin⁡π2=2⋅π24+CC=−π22\begin{aligned} 0\cdot\sin\frac{\pi}{2} &= 2\cdot\frac{\pi^2}{4} + C \\ C &= -\frac{\pi^2}{2} \end{aligned}

Putting C=−π22C = -\frac{\pi^2}{2} in (i),

∴\therefore The particular solution is ysin⁡x=2x2−π22y\sin x = 2x^2 - \dfrac{\pi^2}{2} (sin⁡x≠0)(\sin x \ne 0)⁠.

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

The one idea this problem is built on

The equation is linear with P=cot⁡xP = \cot x⁠, so the integrating factor is e∫cot⁡x dx=sin⁡xe^{\int\cot x\,dx} = \sin x⁠. Multiplying by sin⁡x\sin x does two things at once: the left side becomes ddx(ysin⁡x)\frac{d}{dx}(y\sin x)⁠, and on the right cosec x⋅sin⁡x=1\text{cosec}\,x\cdot\sin x = 1⁠, leaving just 4x4x⁠. One integration and the point (π2,0)\left(\frac{\pi}{2}, 0\right) finish the problem.

Given, to find, and the plan
Given
dydx+ycot⁡x=4x cosec x\frac{dy}{dx} + y\cot x = 4x\,\text{cosec}\,x⁠, and y=0y = 0 when x=π2x = \frac{\pi}{2}⁠.
To find
The particular solution through (π2,0)\left(\frac{\pi}{2}, 0\right)⁠.
Plan
(1) Read off PP and QQ⁠; note where they are defined. (2) I.F. =e∫P dx= e^{\int P\,dx}⁠. (3) Multiply and see the product rule. (4) Integrate, with one constant. (5) Use the condition. (6) Solve for yy and see where the solution lives. (7) Check by substituting back, and see the curve.

Basics you need

1First order linear equations

dydx+Py=Q\frac{dy}{dx} + Py = Q⁠; I.F. =e∫P dx= e^{\int P\,dx}⁠; y (I.F.)=∫(Q×I.F.) dx+Cy\,(\text{I.F.}) = \int(Q\times\text{I.F.})\,dx + C (Section 9.4.3). Lesson: linear equations, the integrating factor

2∫cot⁡x dx=log⁡∣sin⁡x∣\int\cot x\,dx = \log|\sin x|

Since cot⁡x=cos⁡xsin⁡x\cot x = \frac{\cos x}{\sin x} and the top is the derivative of the bottom (Section 7.3.1). Basics: every method ends with an integral

3cosec x=1sin⁡x\text{cosec}\,x = \frac{1}{\sin x}

So cosec x⋅sin⁡x=1\text{cosec}\,x\cdot\sin x = 1 wherever sin⁡x≠0\sin x \ne 0⁠. Basics: (y · g)′ = g(y′ + Py)

4Particular solutions

Put the given point into the general solution to find the constant (Section 9.3). Lesson: general and particular solutions

Solution

  1. Recognise the linear form: P=cot⁡xP = \cot x⁠, Q=4x cosec xQ = 4x\,\text{cosec}\,x

    The equation already has the form dydx+Py=Q\frac{dy}{dx} + Py = Q with

    P=cot⁡x,Q=4x cosec x.P = \cot x, \qquad Q = 4x\,\text{cosec}\,x.
    yy and dydx\frac{dy}{dx} appear only to the first power, and PP⁠, QQ depend on xx only. The equation has order 1 and, as a polynomial in dydx\frac{dy}{dx}⁠, degree 1. Both cot⁡x\cot x and cosec x\text{cosec}\,x need sin⁡x≠0\sin x \ne 0⁠, that is x≠nπx \ne n\pi⁠; the book writes "(x≠0)(x \ne 0)", but the condition actually needed is sin⁡x≠0\sin x \ne 0⁠. The given point x=π2x = \frac{\pi}{2} lies in the interval 0<x<π0 < x < \pi⁠, and we work there.
    Section 9.4.3, step (i). Lesson: linear equations
  2. The integrating factor: sin⁡x\sin x

    I.F.=e∫cot⁡x dx=elog⁡∣sin⁡x∣=∣sin⁡x∣=sin⁡x.\begin{aligned} \text{I.F.} &= e^{\int\cot x\,dx} = e^{\log|\sin x|} \\ &= |\sin x| = \sin x. \end{aligned}
    On 0<x<π0 < x < \pi⁠, sin⁡x>0\sin x > 0⁠, so ∣sin⁡x∣=sin⁡x|\sin x| = \sin x⁠. (On an interval where sin⁡x<0\sin x < 0⁠, ∣sin⁡x∣=−sin⁡x|\sin x| = -\sin x⁠, a constant multiple, and sin⁡x\sin x works there too, giving the same relation below.)
    Section 9.4.3, step (ii); ∫cot⁡x dx=log⁡∣sin⁡x∣\int\cot x\,dx = \log|\sin x|⁠. Basics: exponentials
  3. Multiply by sin⁡x\sin x⁠: the left side is one derivative

    sin⁡x dydx+ycos⁡x=4x cosec x⋅sin⁡xddx(ysin⁡x)=4x.\begin{aligned} \sin x\,\frac{dy}{dx} + y\cos x &= 4x\,\text{cosec}\,x\cdot\sin x \\ \frac{d}{dx}(y\sin x) &= 4x. \end{aligned}
    cot⁡x⋅sin⁡x=cos⁡x\cot x\cdot\sin x = \cos x⁠, and the product rule gives ddx(ysin⁡x)=sin⁡x dydx+ycos⁡x\frac{d}{dx}(y\sin x) = \sin x\,\frac{dy}{dx} + y\cos x⁠, which is the left side. On the right, cosec x⋅sin⁡x=1\text{cosec}\,x\cdot\sin x = 1⁠.
    Product rule (Chapter 5, Section 5.3). Basics: (y · g)′ = g(y′ + Py)
  4. Integrate, with one constant

    ysin⁡x=∫4x cosec xsin⁡x dx+C=∫4x dx+C=2x2+C.…(1)\begin{aligned} y\sin x &= \int 4x\,\text{cosec}\,x\sin x\,dx + C \\ &= \int 4x\,dx + C \\ &= 2x^2 + C.\quad\ldots(1) \end{aligned}
    This is y (I.F.)=∫(Q×I.F.) dx+Cy\,(\text{I.F.}) = \int(Q\times\text{I.F.})\,dx + C⁠, and ∫4x dx=4⋅x22=2x2\int 4x\,dx = 4\cdot\frac{x^2}{2} = 2x^2⁠. The CC is the one arbitrary constant; (1) is the general solution.
    Section 9.4.3, step (iii); Section 7.2, formula (i). Basics: one constant for order 1
  5. Use the condition: y=0y = 0 when x=π2x = \frac{\pi}{2}

    Putting x=π2x = \frac{\pi}{2}⁠, y=0y = 0 in (1):

    0⋅sin⁡π2=2(π2)2+C=π22+CC=−π22.\begin{aligned} 0\cdot\sin\frac{\pi}{2} &= 2\left(\frac{\pi}{2}\right)^2 + C = \frac{\pi^2}{2} + C \\ C &= -\frac{\pi^2}{2}. \end{aligned}
    The left side is 0 because y=0y = 0⁠. On the right, 2⋅π24=π222\cdot\frac{\pi^2}{4} = \frac{\pi^2}{2}⁠. This picks the one curve of the family through (π2,0)\left(\frac{\pi}{2}, 0\right)⁠.
    Section 9.3: a particular solution. Lesson: general and particular solutions
  6. The particular solution, and where it lives

    ysin⁡x=2x2−π22y=2x2−π22sin⁡x(sin⁡x≠0).\begin{aligned} y\sin x &= 2x^2 - \frac{\pi^2}{2} \\ y &= \frac{2x^2 - \frac{\pi^2}{2}}{\sin x}\quad(\sin x \ne 0). \end{aligned}
    Put C=−π22C = -\frac{\pi^2}{2} in (1), then divide by sin⁡x\sin x⁠. The curve through (π2,0)\left(\frac{\pi}{2}, 0\right) lives on 0<x<π0 < x < \pi⁠: as x→0+x \to 0^+ the top tends to −π22-\frac{\pi^2}{2} and y→−∞y \to -\infty⁠; as x→π−x \to \pi^- the top tends to 3π22\frac{3\pi^2}{2} and y→+∞y \to +\infty⁠. The same formula also satisfies the equation on every other interval where sin⁡x≠0\sin x \ne 0⁠, which is what the textbook's "(sin⁡x≠0)(\sin x \ne 0)" records.
    Section 9.4.3: the particular solution. Lesson: Examples 14 to 18
  7. Check by substituting back, and see the curve

    Differentiate ysin⁡x=2x2−π22y\sin x = 2x^2 - \frac{\pi^2}{2} with respect to xx⁠, using the product rule on the left:

    sin⁡x dydx+ycos⁡x=4x.\sin x\,\frac{dy}{dx} + y\cos x = 4x.

    Dividing by sin⁡x\sin x gives dydx+ycot⁡x=4x cosec x\frac{dy}{dx} + y\cot x = 4x\,\text{cosec}\,x⁠, the given equation. At x=π2x = \frac{\pi}{2}⁠: y⋅1=π22−π22=0y\cdot1 = \frac{\pi^2}{2} - \frac{\pi^2}{2} = 0⁠.

    X Y Y′ −20 20 40 (π/2, 0) x = π y sin x = 2x² − π²/2 O
    The particular solution y=2x2−π2/2sin⁡xy = \frac{2x^2 - \pi^2/2}{\sin x} for 0<x<π0 < x < \pi⁠, drawn with unequal scales: the yy-axis is compressed ten times (the ticks mark y=−20y = -20⁠, 2020⁠, 4040⁠). It crosses the xx-axis only at (π2,0)\left(\frac{\pi}{2}, 0\right)⁠, falls without bound towards x=0x = 0 and rises without bound towards the dashed line x=πx = \pi⁠, where sin⁡x=0\sin x = 0⁠.
    Differentiating the answer gives back the equation, and the point satisfies it. The curve is negative for x<π2x < \frac{\pi}{2} and positive for x>π2x > \frac{\pi}{2}⁠, since 2x2−π222x^2 - \frac{\pi^2}{2} changes sign only at x=π2x = \frac{\pi}{2} on this interval.
    A solution makes L.H.S. = R.H.S. (Section 9.3). Compare Example 17, which has the same PP⁠. Basics: a rule for slopes
Result

The general solution is ysin⁡x=2x2+Cy\sin x = 2x^2 + C⁠, and the particular solution with y=0y = 0 when x=π2x = \frac{\pi}{2} is ysin⁡x=2x2−π22y\sin x = 2x^2 - \frac{\pi^2}{2} (sin⁡x≠0)(\sin x \ne 0)⁠; the curve through (π2,0)\left(\frac{\pi}{2}, 0\right) lives on 0<x<π0 < x < \pi⁠. (Textbook answer: ysin⁡x=2x2−π22y\sin x = 2x^2 - \frac{\pi^2}{2} (sin⁡x≠0)(\sin x \ne 0)⁠.)

Check it with numbers

Take x=1x = 1⁠: π22≈4.9348022\frac{\pi^2}{2} \approx 4.9348022 and sin⁡1≈0.8414710\sin 1 \approx 0.8414710⁠, so y≈2−4.93480220.8414710≈−3.4877046y \approx \frac{2 - 4.9348022}{0.8414710} \approx -3.4877046⁠. With 4 cosec 1≈4.75358044\,\text{cosec}\,1 \approx 4.7535804 and cot⁡1≈0.6420926\cot 1 \approx 0.6420926⁠, the equation gives

dydx=4x cosec x−ycot⁡x≈4.7535804+3.4877046×0.6420926≈6.9930.\begin{aligned} \frac{dy}{dx} &= 4x\,\text{cosec}\,x - y\cot x \\ &\approx 4.7535804 \\ &\quad + 3.4877046\times0.6420926 \\ &\approx 6.9930. \end{aligned}

The curve itself: y(1.001)≈−3.4807154134y(1.001) \approx -3.4807154134 and y(0.999)≈−3.4947014442y(0.999) \approx -3.4947014442⁠, a difference of 0.01398603080.0139860308⁠, so

0.01398603080.002≈6.9930.\frac{0.0139860308}{0.002} \approx 6.9930.
Common mistakes
  1. I.F. =log⁡sin⁡x= \log\sin x or ecot⁡xe^{\cot x}⁠. The I.F. is e∫cot⁡x dx=elog⁡sin⁡x=sin⁡xe^{\int\cot x\,dx} = e^{\log\sin x} = \sin x⁠.
  2. Forgetting that cosec x⋅sin⁡x=1\text{cosec}\,x\cdot\sin x = 1 and integrating 4x cosec xsin⁡x4x\,\text{cosec}\,x\sin x the hard way.
  3. Using sin⁡π2=0\sin\frac{\pi}{2} = 0⁠. It is 1; here the left side is 0 only because y=0y = 0⁠.
  4. Sign of CC⁠: 0=π22+C0 = \frac{\pi^2}{2} + C gives C=−π22C = -\frac{\pi^2}{2}⁠.
What to take away
  1. P=cot⁡xP = \cot x gives I.F. sin⁡x\sin x (and P=tan⁡xP = \tan x gives sec⁡x\sec x⁠): worth knowing on sight.
  2. Multiply QQ by the I.F. before integrating; here it collapses to 4x4x⁠.
  3. A solution through a given point lives on the interval containing that point where PP and QQ are defined.

Every fact used, and where it comes from

FactUsed inSource
Linear equation; I.F. =e∫P dx= e^{\int P\,dx}⁠; y (I.F.)=∫(Q×I.F.) dx+Cy\,(\text{I.F.}) = \int(Q\times\text{I.F.})\,dx + CSteps 1, 2, 4Section 9.4.3, steps (i) to (iii) (Lesson)
Order and degreeStep 1Sections 9.2.1 and 9.2.2 (Lesson)
∫cot⁡x dx=log⁡∣sin⁡x∣\int\cot x\,dx = \log|\sin x|Step 2Section 7.3.1 (Basics)
Product rule; cot⁡xsin⁡x=cos⁡x\cot x\sin x = \cos x⁠, cosec xsin⁡x=1\text{cosec}\,x\sin x = 1Steps 3, 7Chapter 5, Section 5.3; trigonometric ratios (Basics)
∫x dx=x22+C\int x\,dx = \frac{x^2}{2} + CStep 4Section 7.2, formula (i) (Basics)
Particular solution from a pointSteps 5, 6Section 9.3 (Lesson)
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 →