67.1.4 problem Problem 1(d)

Internal problem ID [13880]
Book : APPLIED DIFFERENTIAL EQUATIONS The Primary Course by Vladimir A. Dobrushkin. CRC Press 2015
Section : Chapter 2, First Order Equations. Problems page 149
Problem number : Problem 1(d)
Date solved : Monday, March 31, 2025 at 08:16:05 AM
CAS classification : [_separable]

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

Maple. Time used: 0.026 (sec). Leaf size: 19
ode:=x*(exp(y(x))+4) = exp(x+y(x))*diff(y(x),x); 
dsolve(ode,y(x), singsol=all);
 
\[ y = \ln \left (-4+c_1 \,{\mathrm e}^{-\left (x +1\right ) {\mathrm e}^{-x}}\right ) \]
Mathematica. Time used: 4.113 (sec). Leaf size: 51
ode=x*(Exp[y[x]]+4)==Exp[x+y[x]]*D[y[x],x]; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to \log \left (-4+e^{e^{-x} \left (-x+c_1 e^x-1\right )}\right ) \\ y(x)\to \log (4)+i \pi \\ y(x)\to \log (4)+i \pi \\ \end{align*}
Sympy. Time used: 0.421 (sec). Leaf size: 17
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x*(exp(y(x)) + 4) - exp(x + y(x))*Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = \log {\left (C_{1} e^{\left (- x - 1\right ) e^{- x}} - 4 \right )} \]