83.4.13 problem 13

Internal problem ID [19014]
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 (C) at page 12
Problem number : 13
Date solved : Monday, March 31, 2025 at 06:32:45 PM
CAS classification : [[_homogeneous, `class A`], _rational, _Bernoulli]

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

Maple. Time used: 0.002 (sec). Leaf size: 17
ode:=x^2*diff(y(x),x)+y(x)*(x+y(x)) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = \frac {2 x}{2 c_1 \,x^{2}-1} \]
Mathematica. Time used: 0.15 (sec). Leaf size: 24
ode=x^2*D[y[x],x]+y[x]*(x+y[x])==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to \frac {2 x}{-1+2 c_1 x^2} \\ y(x)\to 0 \\ \end{align*}
Sympy. Time used: 0.191 (sec). Leaf size: 12
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x**2*Derivative(y(x), x) + (x + y(x))*y(x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = \frac {2 x}{C_{1} x^{2} - 1} \]