47.2.47 problem 43

Internal problem ID [7463]
Book : Ordinary differential equations and calculus of variations. Makarets and Reshetnyak. Wold Scientific. Singapore. 1995
Section : Chapter 1. First order differential equations. Section 1.2 Homogeneous equations problems. page 12
Problem number : 43
Date solved : Sunday, March 30, 2025 at 12:09:28 PM
CAS classification : [[_homogeneous, `class G`], _rational, _Bernoulli]

\begin{align*} 2 x^{2} y^{\prime }&=y^{3}+x y \end{align*}

Maple. Time used: 0.005 (sec). Leaf size: 45
ode:=2*x^2*diff(y(x),x) = y(x)^3+x*y(x); 
dsolve(ode,y(x), singsol=all);
 
\begin{align*} y &= \frac {\sqrt {\left (-\ln \left (x \right )+c_1 \right ) x}}{\ln \left (x \right )-c_1} \\ y &= \frac {\sqrt {\left (-\ln \left (x \right )+c_1 \right ) x}}{-\ln \left (x \right )+c_1} \\ \end{align*}
Mathematica. Time used: 0.166 (sec). Leaf size: 49
ode=2*x^2*D[y[x],x]==y[x]^3+x*y[x]; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to -\frac {\sqrt {x}}{\sqrt {-\log (x)+c_1}} \\ y(x)\to \frac {\sqrt {x}}{\sqrt {-\log (x)+c_1}} \\ y(x)\to 0 \\ \end{align*}
Sympy. Time used: 0.728 (sec). Leaf size: 26
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(2*x**2*Derivative(y(x), x) - x*y(x) - y(x)**3,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ \left [ y{\left (x \right )} = - \sqrt {\frac {x}{C_{1} - \log {\left (x \right )}}}, \ y{\left (x \right )} = \sqrt {\frac {x}{C_{1} - \log {\left (x \right )}}}\right ] \]