77.5.7 problem 7

Internal problem ID [20387]
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 (D) at page 16
Problem number : 7
Date solved : Thursday, October 02, 2025 at 05:49:49 PM
CAS classification : [_rational, [_1st_order, `_with_symmetry_[F(x)*G(y),0]`]]

\begin{align*} \left (x y^{2}+1+x \right ) y^{\prime }+y+y^{3}&=0 \end{align*}
Maple. Time used: 0.013 (sec). Leaf size: 16
ode:=(1+x+x*y(x)^2)*diff(y(x),x)+y(x)+y(x)^3 = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = \tan \left (\operatorname {RootOf}\left (-\textit {\_Z} -x \tan \left (\textit {\_Z} \right )+c_1 \right )\right ) \]
Mathematica. Time used: 0.104 (sec). Leaf size: 71
ode=(1+x+x*y[x]^2)*D[y[x],x]+(y[x]*y[x]^3)==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ \text {Solve}\left [x=e^{\frac {1}{y(x)}+\frac {1}{3 y(x)^3}} \int _1^{y(x)}-\frac {e^{-\frac {1}{K[1]}-\frac {1}{3 K[1]^3}}}{K[1]^4}dK[1]+c_1 e^{\frac {1}{y(x)}+\frac {1}{3 y(x)^3}},y(x)\right ] \]
Sympy. Time used: 0.557 (sec). Leaf size: 12
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq((x*y(x)**2 + x + 1)*Derivative(y(x), x) + y(x)**3 + y(x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ C_{1} + x y{\left (x \right )} + \operatorname {atan}{\left (y{\left (x \right )} \right )} = 0 \]