29.10.8 problem 274

Internal problem ID [4874]
Book : Ordinary differential equations and their solutions. By George Moseley Murphy. 1960
Section : Various 10
Problem number : 274
Date solved : Sunday, March 30, 2025 at 04:08:17 AM
CAS classification : [[_homogeneous, `class G`], _rational, _Bernoulli]

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

Maple. Time used: 0.006 (sec). Leaf size: 172
ode:=x^2*diff(y(x),x) = (a*x+b*y(x)^3)*y(x); 
dsolve(ode,y(x), singsol=all);
 
\begin{align*} y &= \frac {27^{{1}/{3}} {\left (\left (c_1 \left (a -\frac {1}{3}\right ) x^{-3 a +1}-b \right )^{2} \left (a -\frac {1}{3}\right ) x \right )}^{{1}/{3}}}{c_1 \left (3 a -1\right ) x^{-3 a +1}-3 b} \\ y &= -\frac {27^{{1}/{3}} {\left (\left (c_1 \left (a -\frac {1}{3}\right ) x^{-3 a +1}-b \right )^{2} \left (a -\frac {1}{3}\right ) x \right )}^{{1}/{3}} \left (1+i \sqrt {3}\right )}{\left (6 a -2\right ) c_1 \,x^{-3 a +1}-6 b} \\ y &= \frac {27^{{1}/{3}} {\left (\left (c_1 \left (a -\frac {1}{3}\right ) x^{-3 a +1}-b \right )^{2} \left (a -\frac {1}{3}\right ) x \right )}^{{1}/{3}} \left (i \sqrt {3}-1\right )}{\left (6 a -2\right ) c_1 \,x^{-3 a +1}-6 b} \\ \end{align*}
Mathematica. Time used: 3.536 (sec). Leaf size: 149
ode=x^2 D[y[x],x]==(a x+b y[x]^3)y[x]; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to \frac {\sqrt [3]{(1-3 a) x^{3 a+1}}}{\sqrt [3]{3 b x^{3 a}+(1-3 a) c_1 x}} \\ y(x)\to -\frac {\sqrt [3]{-1} \sqrt [3]{(1-3 a) x^{3 a+1}}}{\sqrt [3]{3 b x^{3 a}+(1-3 a) c_1 x}} \\ y(x)\to \frac {(-1)^{2/3} \sqrt [3]{(1-3 a) x^{3 a+1}}}{\sqrt [3]{3 b x^{3 a}+(1-3 a) c_1 x}} \\ y(x)\to 0 \\ \end{align*}
Sympy. Time used: 32.454 (sec). Leaf size: 139
from sympy import * 
x = symbols("x") 
a = symbols("a") 
b = symbols("b") 
y = Function("y") 
ode = Eq(x**2*Derivative(y(x), x) - (a*x + b*y(x)**3)*y(x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ \left [ y{\left (x \right )} = \sqrt [3]{\frac {e^{3 a \log {\left (x \right )}}}{C_{1} - 3 b \left (\begin {cases} \frac {e^{3 a \log {\left (x \right )}}}{3 a x - x} & \text {for}\: a \neq \frac {1}{3} \\\log {\left (x \right )} & \text {otherwise} \end {cases}\right )}}, \ y{\left (x \right )} = \frac {\sqrt [3]{\frac {e^{3 a \log {\left (x \right )}}}{C_{1} - 3 b \left (\begin {cases} \frac {e^{3 a \log {\left (x \right )}}}{3 a x - x} & \text {for}\: a \neq \frac {1}{3} \\\log {\left (x \right )} & \text {otherwise} \end {cases}\right )}} \left (-1 - \sqrt {3} i\right )}{2}, \ y{\left (x \right )} = \frac {\sqrt [3]{\frac {e^{3 a \log {\left (x \right )}}}{C_{1} - 3 b \left (\begin {cases} \frac {e^{3 a \log {\left (x \right )}}}{3 a x - x} & \text {for}\: a \neq \frac {1}{3} \\\log {\left (x \right )} & \text {otherwise} \end {cases}\right )}} \left (-1 + \sqrt {3} i\right )}{2}\right ] \]