83.5.7 problem 7

Internal problem ID [19023]
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, March 13, 2025 at 01:23:35 PM
CAS classification : [_rational, [_1st_order, `_with_symmetry_[F(x)*G(y),0]`]]

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

Maple. Time used: 0.020 (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 \left (x \right ) = \tan \left (\operatorname {RootOf}\left (-\textit {\_Z} -x \tan \left (\textit {\_Z} \right )+c_{1} \right )\right ) \]
Mathematica. Time used: 0.177 (sec). Leaf size: 78
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 {3 y(x)^2+1}{3 y(x)^3}} \int _1^{y(x)}-\frac {e^{-\frac {3 K[1]^2+1}{3 K[1]^3}}}{K[1]^4}dK[1]+c_1 e^{\frac {3 y(x)^2+1}{3 y(x)^3}},y(x)\right ] \]
Sympy. Time used: 0.861 (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 \]