74.4.48 problem 48

Internal problem ID [15862]
Book : INTRODUCTORY DIFFERENTIAL EQUATIONS. Martha L. Abell, James P. Braselton. Fourth edition 2014. ElScAe. 2014
Section : Chapter 2. First Order Equations. Exercises 2.2, page 39
Problem number : 48
Date solved : Thursday, March 13, 2025 at 06:54:51 AM
CAS classification : [_separable]

\begin{align*} y^{\prime }&={\mathrm e}^{t -y} \end{align*}

With initial conditions

\begin{align*} y \left (0\right )&=0 \end{align*}

Maple. Time used: 0.025 (sec). Leaf size: 5
ode:=diff(y(t),t) = exp(t-y(t)); 
ic:=y(0) = 0; 
dsolve([ode,ic],y(t), singsol=all);
 
\[ y = t \]
Mathematica. Time used: 0.771 (sec). Leaf size: 9
ode=D[y[t],t]==Exp[t-y[t]]; 
ic={y[0]==0}; 
DSolve[{ode,ic},y[t],t,IncludeSingularSolutions->True]
 
\[ y(t)\to \log \left (e^t\right ) \]
Sympy. Time used: 0.185 (sec). Leaf size: 7
from sympy import * 
t = symbols("t") 
y = Function("y") 
ode = Eq(-exp(t - y(t)) + Derivative(y(t), t),0) 
ics = {y(0): 0} 
dsolve(ode,func=y(t),ics=ics)
 
\[ y{\left (t \right )} = \log {\left (e^{t} \right )} \]