7.7 problem 14.1 (vii)

Internal problem ID [11715]

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 (vii).
ODE order: 2.
ODE degree: 1.

CAS Maple gives this as type [[_2nd_order, _linear, _nonhomogeneous]]

\[ \boxed {x^{\prime \prime }+\omega ^{2} x=\sin \left (\omega t \right )} \]

Solution by Maple

Time used: 0.015 (sec). Leaf size: 35

dsolve(diff(x(t),t$2)+omega^2*x(t)=sin(omega*t),x(t), singsol=all)
 

\[ x \left (t \right ) = \sin \left (t \omega \right ) c_{2} +\cos \left (t \omega \right ) c_{1} +\frac {\sin \left (t \omega \right )-\cos \left (t \omega \right ) \omega t}{2 \omega ^{2}} \]

Solution by Mathematica

Time used: 0.081 (sec). Leaf size: 29

DSolve[x''[t]+w^2*x[t]==Sin[w*t],x[t],t,IncludeSingularSolutions -> True]
 

\[ x(t)\to \left (-\frac {t}{2 w}+c_1\right ) \cos (t w)+c_2 \sin (t w) \]