7.20 problem 21

Internal problem ID [1080]

Book: Elementary differential equations with boundary value problems. William F. Trench. Brooks/Cole 2001
Section: Chapter 2, First order equations. Exact equations. Integrating factors. Section 2.6 Page 91
Problem number: 21.
ODE order: 1.
ODE degree: 1.

CAS Maple gives this as type [_linear]

Solve \begin {gather*} \boxed {a \cos \relax (x ) y-\sin \relax (x ) y^{2}+\left (b \cos \relax (x ) y-x \sin \relax (x ) y\right ) y^{\prime }=0} \end {gather*}

Solution by Maple

Time used: 0.017 (sec). Leaf size: 68

dsolve((a*cos(x)*y(x)-y(x)*sin(x)*y(x))+(b*cos(x)*y(x)-x*sin(x)*y(x))*diff(y(x),x)=0,y(x), singsol=all)
 

\begin{align*} y \relax (x ) = 0 \\ y \relax (x ) = \left (\int -\frac {\cos \relax (x ) a \,{\mathrm e}^{-\left (\int \frac {\sin \relax (x )}{\cos \relax (x ) b -\sin \relax (x ) x}d x \right )}}{\cos \relax (x ) b -\sin \relax (x ) x}d x +c_{1}\right ) {\mathrm e}^{\int \frac {\sin \relax (x )}{\cos \relax (x ) b -\sin \relax (x ) x}d x} \\ \end{align*}

Solution by Mathematica

Time used: 2.155 (sec). Leaf size: 85

DSolve[(a*Cos[x]*y[x]-y[x]*Sin[x]*y[x])+(b*Cos[x]*y[x]-x*Sin[x]*y[x])*y'[x]==0,y[x],x,IncludeSingularSolutions -> True]
 

\begin{align*} y(x)\to 0 \\ y(x)\to \exp \left (\int _1^x\frac {1}{b \cot (K[1])-K[1]}dK[1]\right ) \left (\int _1^x-\frac {a \exp \left (-\int _1^{K[2]}\frac {1}{b \cot (K[1])-K[1]}dK[1]\right )}{b-K[2] \tan (K[2])}dK[2]+c_1\right ) \\ y(x)\to 0 \\ \end{align*}