39.3.5 problem Problem 12.5

Internal problem ID [6531]
Book : Schaums Outline Differential Equations, 4th edition. Bronson and Costa. McGraw Hill 2014
Section : Chapter 12. VARIATION OF PARAMETERS. page 104
Problem number : Problem 12.5
Date solved : Monday, January 27, 2025 at 02:11:38 PM
CAS classification : [[_2nd_order, _linear, _nonhomogeneous]]

\begin{align*} x^{\prime \prime }+4 x&=\sin \left (2 t \right )^{2} \end{align*}

Solution by Maple

Time used: 0.003 (sec). Leaf size: 24

dsolve(diff(x(t),t$2)+4*x(t)=sin(2*t)^2,x(t), singsol=all)
 
\[ x \left (t \right ) = \sin \left (2 t \right ) c_2 +\cos \left (2 t \right ) c_1 +\frac {1}{8}+\frac {\cos \left (4 t \right )}{24} \]

Solution by Mathematica

Time used: 0.123 (sec). Leaf size: 31

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