85.15.7 problem 1 (g)

Internal problem ID [22532]
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 : 1 (g)
Date solved : Thursday, October 02, 2025 at 08:47:37 PM
CAS classification : [_exact, [_1st_order, `_with_symmetry_[F(x),G(x)]`], [_Abel, `2nd type`, `class B`]]

\begin{align*} {\mathrm e}^{-x} y-\sin \left (x \right )-\left ({\mathrm e}^{-x}+2 y\right ) y^{\prime }&=0 \end{align*}
Maple. Time used: 0.006 (sec). Leaf size: 57
ode:=y(x)*exp(-x)-sin(x)-(exp(-x)+2*y(x))*diff(y(x),x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\begin{align*} y &= -\frac {\left (1+\sqrt {1+\left (4 c_1 +4 \cos \left (x \right )\right ) {\mathrm e}^{2 x}}\right ) {\mathrm e}^{-x}}{2} \\ y &= \frac {\left (-1+\sqrt {1+\left (4 c_1 +4 \cos \left (x \right )\right ) {\mathrm e}^{2 x}}\right ) {\mathrm e}^{-x}}{2} \\ \end{align*}
Mathematica. Time used: 25.734 (sec). Leaf size: 102
ode=(y[x]*Exp[-x]-Sin[x])-(Exp[-x]+2*y[x])*D[y[x],x]== 0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to \frac {1}{2} \left (-e^{-x}-\sqrt {e^{-x}} \sqrt {e^{-x}+4 e^x \cos (x)+4 c_1 e^x}\right )\\ y(x)&\to \frac {1}{2} \left (-e^{-x}+\sqrt {e^{-x}} \sqrt {e^{-x}+4 e^x \cos (x)+4 c_1 e^x}\right ) \end{align*}
Sympy
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-(2*y(x) + exp(-x))*Derivative(y(x), x) + y(x)*exp(-x) - sin(x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
Timed Out