76.4.15 problem 19

Internal problem ID [17338]
Book : Differential equations. An introduction to modern methods and applications. James Brannan, William E. Boyce. Third edition. Wiley 2015
Section : Chapter 2. First order differential equations. Section 2.6 (Exact equations and integrating factors). Problems at page 100
Problem number : 19
Date solved : Monday, March 31, 2025 at 03:54:57 PM
CAS classification : [_separable]

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

Maple. Time used: 0.019 (sec). Leaf size: 37
ode:=x^2*y(x)^3+x*(1+y(x)^2)*diff(y(x),x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = {\mathrm e}^{-\frac {x^{2}}{2}-c_1} \sqrt {\frac {{\mathrm e}^{x^{2}+2 c_1}}{\operatorname {LambertW}\left ({\mathrm e}^{x^{2}+2 c_1}\right )}} \]
Mathematica. Time used: 3.836 (sec). Leaf size: 46
ode=(x^2*y[x]^3)+x*(1+y[x]^2)*D[y[x],x]==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to -\frac {1}{\sqrt {W\left (e^{x^2-2 c_1}\right )}} \\ y(x)\to \frac {1}{\sqrt {W\left (e^{x^2-2 c_1}\right )}} \\ y(x)\to 0 \\ \end{align*}
Sympy. Time used: 0.763 (sec). Leaf size: 22
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x**2*y(x)**3 + x*(y(x)**2 + 1)*Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = e^{C_{1} - \frac {x^{2}}{2} + \frac {W\left (e^{- 2 C_{1} + x^{2}}\right )}{2}} \]