30.1.9 problem 9

Internal problem ID [7399]
Book : Fundamentals of Differential Equations. By Nagle, Saff and Snider. 9th edition. Boston. Pearson 2018.
Section : Chapter 2, First order differential equations. Section 2.2, Separable Equations. Exercises. page 46
Problem number : 9
Date solved : Tuesday, September 30, 2025 at 04:30:30 PM
CAS classification : [_separable]

\begin{align*} x^{\prime }&=\frac {t \,{\mathrm e}^{-t -2 x}}{x} \end{align*}
Maple. Time used: 0.008 (sec). Leaf size: 25
ode:=diff(x(t),t) = t/x(t)/exp(t+2*x(t)); 
dsolve(ode,x(t), singsol=all);
 
\[ x = \frac {\operatorname {LambertW}\left (-4 \left (-c_1 \,{\mathrm e}^{t}+t +1\right ) {\mathrm e}^{-t -1}\right )}{2}+\frac {1}{2} \]
Mathematica. Time used: 0.278 (sec). Leaf size: 43
ode=D[x[t],t]==t/(x[t]*Exp[t+2*x[t]]); 
ic={}; 
DSolve[{ode,ic},x[t],t,IncludeSingularSolutions->True]
 
\begin{align*} x(t)&\to \text {InverseFunction}\left [\int _1^{\text {$\#$1}}e^{2 K[1]} K[1]dK[1]\&\right ]\left [\int _1^te^{-K[2]} K[2]dK[2]+c_1\right ] \end{align*}
Sympy. Time used: 0.293 (sec). Leaf size: 29
from sympy import * 
t = symbols("t") 
x = Function("x") 
ode = Eq(-t*exp(-t - 2*x(t))/x(t) + Derivative(x(t), t),0) 
ics = {} 
dsolve(ode,func=x(t),ics=ics)
 
\[ x{\left (t \right )} = \frac {W\left (C_{1} - 4 t e^{- t - 1} - 4 e^{- t - 1}\right )}{2} + \frac {1}{2} \]