14.15 problem Problem 41

Internal problem ID [2372]

Book: Differential equations and linear algebra, Stephen W. Goode and Scott A Annin. Fourth edition, 2015
Section: Chapter 10, The Laplace Transform and Some Elementary Applications. Exercises for 10.7. page 704
Problem number: Problem 41.
ODE order: 2.
ODE degree: 1.

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

Solve \begin {gather*} \boxed {y^{\prime \prime }-2 y^{\prime }+5 y-2 \sin \relax (t )-\theta \left (t -\frac {\pi }{2}\right ) \left (\cos \relax (t )+1\right )=0} \end {gather*} With initial conditions \begin {align*} [y \relax (0) = 0, y^{\prime }\relax (0) = 0] \end {align*}

Solution by Maple

Time used: 0.047 (sec). Leaf size: 67

dsolve([diff(y(t),t$2)-2*diff(y(t),t)+5*y(t)=2*sin(t)+Heaviside(t-Pi/2)*(1-sin(t-Pi/2)),y(0) = 0, D(y)(0) = 0],y(t), singsol=all)
 

\[ y \relax (t ) = -\frac {{\mathrm e}^{t} \sin \left (2 t \right )}{10}-\frac {{\mathrm e}^{t} \cos \left (2 t \right )}{5}+\frac {\left (\left (2 \cos \left (2 t \right )-3 \sin \left (2 t \right )\right ) {\mathrm e}^{t -\frac {\pi }{2}}+4 \cos \relax (t )-2 \sin \relax (t )+4\right ) \theta \left (t -\frac {\pi }{2}\right )}{20}+\frac {\cos \relax (t )}{5}+\frac {2 \sin \relax (t )}{5} \]

Solution by Mathematica

Time used: 0.206 (sec). Leaf size: 90

DSolve[{y''[t]-2*y'[t]+5*y[t]==2*Sin[t]+UnitStep[t-Pi/2]*(1-Sin[t-Pi/2]),{y[0]==0,y'[0]==0}},y[t],t,IncludeSingularSolutions -> True]
 

\begin{align*} y(t)\to {cc} \{ & {cc} \frac {1}{5} \left (\cos (t)+2 \sin (t)-e^t (\cos (2 t)+\cos (t) \sin (t))\right ) & 2 t\leq \pi \\ \frac {1}{20} \left (8 \cos (t)+2 e^t \left (-2+e^{-\pi /2}\right ) \cos (2 t)+6 \sin (t)+e^t \left (-2-3 e^{-\pi /2}\right ) \sin (2 t)+4\right ) & \text {True} \\ \\ \\ \\ \\ \end{align*}