80.5.31 problem C 7

Internal problem ID [21252]
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 5. Second order equations. Excercise 5.9 at page 119
Problem number : C 7
Date solved : Thursday, October 02, 2025 at 07:27:21 PM
CAS classification : [[_2nd_order, _linear, _nonhomogeneous]]

\begin{align*} x^{\prime \prime }-x&={\mathrm e}^{2 t} t \end{align*}
Maple. Time used: 0.004 (sec). Leaf size: 26
ode:=diff(diff(x(t),t),t)-x(t) = t*exp(2*t); 
dsolve(ode,x(t), singsol=all);
 
\[ x = {\mathrm e}^{t} c_2 +{\mathrm e}^{-t} c_1 +\frac {\left (3 t -4\right ) {\mathrm e}^{2 t}}{9} \]
Mathematica. Time used: 0.011 (sec). Leaf size: 34
ode=D[x[t],{t,2}]-x[t]==t*Exp[2*t]; 
ic={}; 
DSolve[{ode,ic},x[t],t,IncludeSingularSolutions->True]
 
\begin{align*} x(t)&\to \frac {1}{9} e^{2 t} (3 t-4)+c_1 e^t+c_2 e^{-t} \end{align*}
Sympy. Time used: 0.064 (sec). Leaf size: 24
from sympy import * 
t = symbols("t") 
x = Function("x") 
ode = Eq(-t*exp(2*t) - x(t) + Derivative(x(t), (t, 2)),0) 
ics = {} 
dsolve(ode,func=x(t),ics=ics)
 
\[ x{\left (t \right )} = C_{1} e^{- t} + C_{2} e^{t} + \frac {\left (3 t - 4\right ) e^{2 t}}{9} \]