90.34.14 problem 14

Internal problem ID [25498]
Book : Ordinary Differential Equations. By William Adkins and Mark G Davidson. Springer. NY. 2010. ISBN 978-1-4614-3617-1
Section : Chapter 9. Linear Systems of Differential Equations. Exercises at page 677
Problem number : 14
Date solved : Friday, October 03, 2025 at 12:02:09 AM
CAS classification : system_of_ODEs

\begin{align*} y_{1}^{\prime }\left (t \right )&=2 y_{1} \left (t \right )+y_{2} \left (t \right )+{\mathrm e}^{t}\\ y_{2}^{\prime }\left (t \right )&=y_{1} \left (t \right )+2 y_{2} \left (t \right )-{\mathrm e}^{t} \end{align*}

With initial conditions

\begin{align*} y_{1} \left (0\right )&=1 \\ y_{2} \left (0\right )&=1 \\ \end{align*}
Maple. Time used: 0.054 (sec). Leaf size: 26
ode:=[diff(y__1(t),t) = 2*y__1(t)+y__2(t)+exp(t), diff(y__2(t),t) = y__1(t)+2*y__2(t)-exp(t)]; 
ic:=[y__1(0) = 1, y__2(0) = 1]; 
dsolve([ode,op(ic)]);
 
\begin{align*} y_{1} \left (t \right ) &= {\mathrm e}^{3 t}+t \,{\mathrm e}^{t} \\ y_{2} \left (t \right ) &= {\mathrm e}^{3 t}-t \,{\mathrm e}^{t} \\ \end{align*}
Mathematica. Time used: 0.003 (sec). Leaf size: 31
ode={D[y1[t],t]==2*y1[t]+y2[t]+Exp[t], D[y2[t],t]==y1[t]+2*y2[t]-Exp[t]}; 
ic={y1[0]==1,y2[0]==1}; 
DSolve[{ode,ic},{y1[t],y2[t]},t,IncludeSingularSolutions->True]
 
\begin{align*} \text {y1}(t)&\to e^t \left (t+e^{2 t}\right )\\ \text {y2}(t)&\to e^{3 t}-e^t t \end{align*}
Sympy
from sympy import * 
t = symbols("t") 
y1 = Function("y1") 
y2 = Function("y2") 
ode=[Eq(-2*y1(t) - y2(t) - exp(t) + Derivative(y1(t), t),0),Eq(-y1(t) - 2*y2(t) + exp(t) + Derivative(y2(t), t),0)] 
ics = {y1(0): 1, y2(0): 1} 
dsolve(ode,func=[y1(t),y2(t)],ics=ics)
 
NotAlgebraic : Integral(-1, (t, 0)) does not seem to be an algebraic element