29.3.9 problem 63

Internal problem ID [4671]
Book : Ordinary differential equations and their solutions. By George Moseley Murphy. 1960
Section : Various 3
Problem number : 63
Date solved : Sunday, March 30, 2025 at 03:35:48 AM
CAS classification : [_separable]

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

Maple. Time used: 0.003 (sec). Leaf size: 19
ode:=diff(y(x),x) = x*y(x)*(3+y(x)); 
dsolve(ode,y(x), singsol=all);
 
\[ y = \frac {3}{-1+3 \,{\mathrm e}^{-\frac {3 x^{2}}{2}} c_1} \]
Mathematica. Time used: 0.247 (sec). Leaf size: 49
ode=D[y[x],x]==x*y[x](3+y[x]); 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to -\frac {3 e^{\frac {3 x^2}{2}+3 c_1}}{-1+e^{\frac {3 x^2}{2}+3 c_1}} \\ y(x)\to -3 \\ y(x)\to 0 \\ \end{align*}
Sympy. Time used: 10.082 (sec). Leaf size: 83
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-x*(y(x) + 3)*y(x) + Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ \left [ y{\left (x \right )} = \frac {3 \left (\sqrt {e^{6 C_{1} + 3 x^{2}}} - e^{6 C_{1} + 3 x^{2}}\right )}{e^{6 C_{1} + 3 x^{2}} - 1}, \ y{\left (x \right )} = - \frac {3 \left (\sqrt {e^{6 C_{1} + 3 x^{2}}} + e^{6 C_{1} + 3 x^{2}}\right )}{e^{6 C_{1} + 3 x^{2}} - 1}\right ] \]