80.7.11 problem B 3

Internal problem ID [21330]
Book : A Textbook on Ordinary Differential Equations by Shair Ahmad and Antonio Ambrosetti. Second edition. ISBN 978-3-319-16407-6. Springer 2015
Section : Chapter 7. System of first order equations. Excercise 7.6 at page 162
Problem number : B 3
Date solved : Thursday, October 02, 2025 at 07:28:29 PM
CAS classification : system_of_ODEs

\begin{align*} x^{\prime }&=-x\\ y^{\prime }\left (t \right )&=3 x+y \left (t \right ) \end{align*}
Maple. Time used: 0.056 (sec). Leaf size: 25
ode:=[diff(x(t),t) = -x(t), diff(y(t),t) = 3*x(t)+y(t)]; 
dsolve(ode);
 
\begin{align*} x \left (t \right ) &= c_2 \,{\mathrm e}^{-t} \\ y \left (t \right ) &= -\frac {3 c_2 \,{\mathrm e}^{-t}}{2}+c_1 \,{\mathrm e}^{t} \\ \end{align*}
Mathematica. Time used: 0.002 (sec). Leaf size: 41
ode={D[x[t],t]==-x[t],D[y[t],t]==3*x[t]+y[t]}; 
ic={}; 
DSolve[{ode,ic},{x[t],y[t]},t,IncludeSingularSolutions->True]
 
\begin{align*} x(t)&\to c_1 e^{-t}\\ y(t)&\to \left (\frac {3 c_1}{2}+c_2\right ) e^t-\frac {3 c_1 e^{-t}}{2} \end{align*}
Sympy. Time used: 0.038 (sec). Leaf size: 24
from sympy import * 
t = symbols("t") 
x = Function("x") 
y = Function("y") 
ode=[Eq(x(t) + Derivative(x(t), t),0),Eq(-3*x(t) - y(t) + Derivative(y(t), t),0)] 
ics = {} 
dsolve(ode,func=[x(t),y(t)],ics=ics)
 
\[ \left [ x{\left (t \right )} = - \frac {2 C_{1} e^{- t}}{3}, \ y{\left (t \right )} = C_{1} e^{- t} + C_{2} e^{t}\right ] \]