Home » Blog » Find all solutions of the differential equation y′ sin x + y cos x = 1

Find all solutions of the differential equation y′ sin x + y cos x = 1

Find all solutions of the following differential equation on the interval (0, \pi):

    \[ y' \sin x + y \cos x = 1. \]

Prove that exactly one of these solutions has a finite limit as x \to 0, and that exactly one of these solutions has a finite limit as x \to \pi.


Proof. First, to find the solutions of the differential equation we divide by \sin x (noting \sin x \neq 0 for any x \in (0, \pi)),

    \[ y' \sin x + y \cos x = 1 \qquad \implies \qquad y' + y \cot x = \csc x. \]

We apply Theorem 8.3 (page 310 of Apostol) with

    \[ P(x) = \cot x, \qquad Q(x) = \csc x. \]

Then, we choose a = \frac{\pi}{2} and find solutions in terms of b. This gives us

    \[ A(x) = \int_{\frac{\pi}{2}}^x \cot t \, dt = \log(\sin x). \]

Therefore,

    \begin{align*}  f(x) &= be^{-\log(\sin x)} + e^{-\log(\sin x)} \int_{\frac{\pi}{2}}^x (\csc t) e^{\log(\sin t)} \, dt \\[9pt]  &= \frac{b}{\sin x} + \frac{1}{\sin x} \int_{\frac{\pi}{2}}^x \, dt \\[9pt]  &= \frac{b}{\sin x} + \frac{x - \frac{\pi}{2}}{\sin x} \\[9pt]  &= \frac{x + C}{\sin x} \end{align*}

where c = b - \frac{\pi}{2}. These are all of the solutions on the given interval.

Next, to find the solutions with finite limits as x \to 0 and x \to \pi. If

    \[ \lim_{x \to 0} \frac{x + C}{\sin x} \]

is finite, we must have C = 0 (otherwise the limit will go to infinity). Therefore, b = \frac{\pi}{2}.
If

    \[ \lim_{x \to \pi} \frac{x + C}{\sin x} \]

is finite, we must have C = -\pi. Therefore, b = -\frac{\pi}{2}. \qquad \blacksquare

3 comments

      • Anonymous says:

        I’m sorry – I meant having ln(sin(a))=0 (which is the case here since sin(pi/2)=1 and ln(1)=0) makes calculations easier :) If I’m reasoning correctly, of course

Point out an error, ask a question, offer an alternative solution (to use Latex type [latexpage] at the top of your comment):