7.5.24 problem 24

Internal problem ID [128]
Book : Elementary Differential Equations. By C. Henry Edwards, David E. Penney and David Calvis. 6th edition. 2008
Section : Chapter 1. First order differential equations. Section 1.6 (substitution and exact equations). Problems at page 72
Problem number : 24
Date solved : Saturday, March 29, 2025 at 04:34:44 PM
CAS classification : [_Bernoulli]

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

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