85.15.15 problem 2 (e)

Internal problem ID [22540]
Book : Applied Differential Equations. By Murray R. Spiegel. 3rd edition. 1980. Pearson. ISBN 978-0130400970
Section : Chapter two. First order and simple higher order ordinary differential equations. A Exercises at page 47
Problem number : 2 (e)
Date solved : Thursday, October 02, 2025 at 08:49:19 PM
CAS classification : [_exact, [_Abel, `2nd type`, `class B`]]

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

With initial conditions

\begin{align*} y \left (0\right )&=1 \\ \end{align*}
Maple. Time used: 0.114 (sec). Leaf size: 28
ode:=(x^2+2*y(x)*exp(2*x))*diff(y(x),x)+2*x*y(x)+2*y(x)^2*exp(2*x) = 0; 
ic:=[y(0) = 1]; 
dsolve([ode,op(ic)],y(x), singsol=all);
 
\[ y = \frac {\left (-x^{2}+\sqrt {x^{4}+4 \,{\mathrm e}^{2 x}}\right ) {\mathrm e}^{-2 x}}{2} \]
Mathematica. Time used: 3.255 (sec). Leaf size: 35
ode=(x^2+2*y[x]*Exp[2*x])*D[y[x],x]+2*x*y[x]+2*y[x]^2*Exp[2*x]==0; 
ic={y[0]==1}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to \frac {1}{2} e^{-2 x} \left (\sqrt {x^4+4 e^{2 x}}-x^2\right ) \end{align*}
Sympy
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(2*x*y(x) + (x**2 + 2*y(x)*exp(2*x))*Derivative(y(x), x) + 2*y(x)**2*exp(2*x),0) 
ics = {y(0): 1} 
dsolve(ode,func=y(x),ics=ics)
 
NotImplementedError : The given ODE -2*(-x - y(x)*exp(2*x))*y(x)/(x**2 + 2*y(x)*exp(2*x)) + Derivati