65.7.1 problem 14.1 (i)

Internal problem ID [13765]
Book : AN INTRODUCTION TO ORDINARY DIFFERENTIAL EQUATIONS by JAMES C. ROBINSON. Cambridge University Press 2004
Section : Chapter 14, Inhomogeneous second order linear equations. Exercises page 140
Problem number : 14.1 (i)
Date solved : Tuesday, January 28, 2025 at 06:02:22 AM
CAS classification : [[_2nd_order, _with_linear_symmetries]]

\begin{align*} x^{\prime \prime }-4 x&=t^{2} \end{align*}

Solution by Maple

Time used: 0.007 (sec). Leaf size: 23

dsolve(diff(x(t),t$2)-4*x(t)=t^2,x(t), singsol=all)
 
\[ x \left (t \right ) = c_{2} {\mathrm e}^{2 t}+c_{1} {\mathrm e}^{-2 t}-\frac {t^{2}}{4}-\frac {1}{8} \]

Solution by Mathematica

Time used: 0.014 (sec). Leaf size: 32

DSolve[D[x[t],{t,2}]-4*x[t]==t^2,x[t],t,IncludeSingularSolutions -> True]
 
\[ x(t)\to -\frac {t^2}{4}+c_1 e^{2 t}+c_2 e^{-2 t}-\frac {1}{8} \]