78.6.3 problem 2 (c)

Internal problem ID [18171]
Book : DIFFERENTIAL EQUATIONS WITH APPLICATIONS AND HISTORICAL NOTES by George F. Simmons. 3rd edition. 2017. CRC press, Boca Raton FL.
Section : Chapter 2. First order equations. Section 10 (Linear equations). Problems at page 82
Problem number : 2 (c)
Date solved : Tuesday, January 28, 2025 at 11:36:05 AM
CAS classification : [_linear]

\begin{align*} \left (x^{2}+1\right ) y^{\prime }+2 y x&=\cot \left (x \right ) \end{align*}

Solution by Maple

Time used: 0.000 (sec). Leaf size: 17

dsolve((1+x^2)*diff(y(x),x)+2*x*y(x)=cot(x),y(x), singsol=all)
 
\[ y = \frac {\ln \left (\sin \left (x \right )\right )+c_1}{x^{2}+1} \]

Solution by Mathematica

Time used: 0.041 (sec). Leaf size: 19

DSolve[(1+x^2)*D[y[x],x]+2*x*y[x]==Cot[x],y[x],x,IncludeSingularSolutions -> True]
 
\[ y(x)\to \frac {\log (\sin (x))+c_1}{x^2+1} \]