83.2.3 problem 3

Internal problem ID [18978]
Book : A Text book for differentional equations for postgraduate students by Ray and Chaturvedi. First edition, 1958. BHASKAR press. INDIA
Section : Chapter II. Equations of first order and first degree. Exercise II (A) at page 8
Problem number : 3
Date solved : Monday, March 31, 2025 at 06:27:59 PM
CAS classification : [_Bernoulli]

\begin{align*} \sin \left (x \right ) y^{\prime }-y \cos \left (x \right )+y^{2}&=0 \end{align*}

Maple. Time used: 0.003 (sec). Leaf size: 12
ode:=sin(x)*diff(y(x),x)-y(x)*cos(x)+y(x)^2 = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = \frac {\sin \left (x \right )}{x +c_1} \]
Mathematica. Time used: 0.176 (sec). Leaf size: 19
ode=Sin[x]*D[y[x],x]-y[x]*Cos[x]+y[x]^2==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to \frac {\sin (x)}{x+c_1} \\ y(x)\to 0 \\ \end{align*}
Sympy. Time used: 0.221 (sec). Leaf size: 8
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(y(x)**2 - y(x)*cos(x) + sin(x)*Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = \frac {\sin {\left (x \right )}}{C_{1} + x} \]