81.1.14 problem 2-13

Internal problem ID [21459]
Book : The Differential Equations Problem Solver. VOL. I. M. Fogiel director. REA, NY. 1978. ISBN 78-63609
Section : Chapter 2. Separable differential equations
Problem number : 2-13
Date solved : Thursday, October 02, 2025 at 07:38:37 PM
CAS classification : [_separable]

\begin{align*} -2+2 y+x^{2} \sin \left (y\right ) y^{\prime }&=0 \end{align*}
Maple. Time used: 0.017 (sec). Leaf size: 25
ode:=2*y(x)-2+x^2*sin(y(x))*diff(y(x),x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = 1+\operatorname {RootOf}\left (\operatorname {Ci}\left (\textit {\_Z} \right ) \sin \left (1\right ) x +\operatorname {Si}\left (\textit {\_Z} \right ) \cos \left (1\right ) x +2 c_1 x -2\right ) \]
Mathematica. Time used: 0.205 (sec). Leaf size: 42
ode=2*(y[x]-1)+x^2*Sin[y[x]]*D[y[x],x]==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to \text {InverseFunction}[\sin (1) \operatorname {CosIntegral}(1-\text {$\#$1})-\cos (1) \text {Si}(1-\text {$\#$1})\&]\left [\frac {2}{x}+c_1\right ]\\ y(x)&\to 1 \end{align*}
Sympy. Time used: 0.541 (sec). Leaf size: 14
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x**2*sin(y(x))*Derivative(y(x), x) + 2*y(x) - 2,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ \int \limits ^{y{\left (x \right )}} \frac {\sin {\left (y \right )}}{y - 1}\, dy = C_{1} + \frac {2}{x} \]