14.16.1 problem 15

Internal problem ID [2671]
Book : Differential equations and their applications, 4th ed., M. Braun
Section : Chapter 2. Second order differential equations. Section 2.9, The method of Laplace transform. Excercises page 232
Problem number : 15
Date solved : Sunday, March 30, 2025 at 12:13:45 AM
CAS classification : [[_2nd_order, _with_linear_symmetries]]

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

Using Laplace method With initial conditions

\begin{align*} y \left (0\right )&=1\\ y^{\prime }\left (0\right )&=-1 \end{align*}

Maple. Time used: 0.106 (sec). Leaf size: 21
ode:=diff(diff(y(t),t),t)-5*diff(y(t),t)+4*y(t) = exp(2*t); 
ic:=y(0) = 1, D(y)(0) = -1; 
dsolve([ode,ic],y(t),method='laplace');
 
\[ y = 2 \,{\mathrm e}^{t}-\frac {{\mathrm e}^{4 t}}{2}-\frac {{\mathrm e}^{2 t}}{2} \]
Mathematica. Time used: 0.029 (sec). Leaf size: 22
ode=D[y[t],{t,2}]-5*D[y[t],t]+4*y[t]==Exp[2*t]; 
ic={y[0]==1,Derivative[1][y][0] ==-1}; 
DSolve[{ode,ic},y[t],t,IncludeSingularSolutions->True]
 
\[ y(t)\to -\frac {1}{2} e^t \left (e^t+e^{3 t}-4\right ) \]
Sympy. Time used: 0.213 (sec). Leaf size: 19
from sympy import * 
t = symbols("t") 
y = Function("y") 
ode = Eq(4*y(t) - exp(2*t) - 5*Derivative(y(t), t) + Derivative(y(t), (t, 2)),0) 
ics = {y(0): 1, Subs(Derivative(y(t), t), t, 0): -1} 
dsolve(ode,func=y(t),ics=ics)
 
\[ y{\left (t \right )} = \left (- \frac {e^{3 t}}{2} - \frac {e^{t}}{2} + 2\right ) e^{t} \]