65.15.4 problem 28.2 (iv)

Internal problem ID [13757]
Book : AN INTRODUCTION TO ORDINARY DIFFERENTIAL EQUATIONS by JAMES C. ROBINSON. Cambridge University Press 2004
Section : Chapter 28, Distinct real eigenvalues. Exercises page 282
Problem number : 28.2 (iv)
Date solved : Wednesday, March 05, 2025 at 10:15:00 PM
CAS classification : system_of_ODEs

\begin{align*} \frac {d}{d t}x \left (t \right )&=x \left (t \right )+20 y \left (t \right )\\ \frac {d}{d t}y \left (t \right )&=40 x \left (t \right )-19 y \left (t \right ) \end{align*}

Maple. Time used: 0.042 (sec). Leaf size: 34
ode:=[diff(x(t),t) = x(t)+20*y(t), diff(y(t),t) = 40*x(t)-19*y(t)]; 
dsolve(ode);
 
\begin{align*} x \left (t \right ) &= c_{1} {\mathrm e}^{-39 t}+c_{2} {\mathrm e}^{21 t} \\ y \left (t \right ) &= -2 c_{1} {\mathrm e}^{-39 t}+c_{2} {\mathrm e}^{21 t} \\ \end{align*}
Mathematica. Time used: 0.005 (sec). Leaf size: 71
ode={D[x[t],t]==x[t]+20*y[t],D[y[t],t]==40*x[t]-19*y[t]}; 
ic={}; 
DSolve[{ode,ic},{x[t],y[t]},t,IncludeSingularSolutions->True]
 
\begin{align*} x(t)\to \frac {1}{3} e^{-39 t} \left (c_1 \left (2 e^{60 t}+1\right )+c_2 \left (e^{60 t}-1\right )\right ) \\ y(t)\to \frac {1}{3} e^{-39 t} \left (2 c_1 \left (e^{60 t}-1\right )+c_2 \left (e^{60 t}+2\right )\right ) \\ \end{align*}
Sympy. Time used: 0.097 (sec). Leaf size: 32
from sympy import * 
t = symbols("t") 
x = Function("x") 
y = Function("y") 
ode=[Eq(-x(t) - 20*y(t) + Derivative(x(t), t),0),Eq(-40*x(t) + 19*y(t) + Derivative(y(t), t),0)] 
ics = {} 
dsolve(ode,func=[x(t),y(t)],ics=ics)
 
\[ \left [ x{\left (t \right )} = - \frac {C_{1} e^{- 39 t}}{2} + C_{2} e^{21 t}, \ y{\left (t \right )} = C_{1} e^{- 39 t} + C_{2} e^{21 t}\right ] \]