66.8.21 problem 34

Internal problem ID [16072]
Book : DIFFERENTIAL EQUATIONS by Paul Blanchard, Robert L. Devaney, Glen R. Hall. 4th edition. Brooks/Cole. Boston, USA. 2012
Section : Chapter 1. First-Order Differential Equations. Review Exercises for chapter 1. page 136
Problem number : 34
Date solved : Thursday, October 02, 2025 at 10:40:47 AM
CAS classification : [[_linear, `class A`]]

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

With initial conditions

\begin{align*} y \left (0\right )&=-2 \\ \end{align*}
Maple. Time used: 0.027 (sec). Leaf size: 14
ode:=diff(y(t),t)+5*y(t) = 3*exp(-5*t); 
ic:=[y(0) = -2]; 
dsolve([ode,op(ic)],y(t), singsol=all);
 
\[ y = \left (3 t -2\right ) {\mathrm e}^{-5 t} \]
Mathematica. Time used: 0.035 (sec). Leaf size: 16
ode=D[y[t],t]+5*y[t]== 3*Exp[-5*t]; 
ic={y[0]==-2}; 
DSolve[{ode,ic},y[t],t,IncludeSingularSolutions->True]
 
\begin{align*} y(t)&\to e^{-5 t} (3 t-2) \end{align*}
Sympy. Time used: 0.092 (sec). Leaf size: 12
from sympy import * 
t = symbols("t") 
y = Function("y") 
ode = Eq(5*y(t) + Derivative(y(t), t) - 3*exp(-5*t),0) 
ics = {y(0): -2} 
dsolve(ode,func=y(t),ics=ics)
 
\[ y{\left (t \right )} = \left (3 t - 2\right ) e^{- 5 t} \]