Internal problem ID [866]
Book: Elementary differential equations and boundary value problems, 11th ed., Boyce, DiPrima,
Meade
Section: Chapter 6.5, The Laplace Transform. Impulse functions. page 273
Problem number: 12.
ODE order: 2.
ODE degree: 1.
CAS Maple gives this as type [[_2nd_order, _linear, _nonhomogeneous]]
\[ \boxed {y^{\prime \prime }+y=\frac {\operatorname {Heaviside}\left (t -4+k \right )-\operatorname {Heaviside}\left (t -4-k \right )}{2 k}} \] With initial conditions \begin {align*} [y \left (0\right ) = 0, y^{\prime }\left (0\right ) = 0] \end {align*}
✓ Solution by Maple
Time used: 0.109 (sec). Leaf size: 83
dsolve([diff(y(t),t$2)+y(t)=1/(2*k)*(Heaviside(t-(4-k)) - Heaviside(t-(4+k)) ),y(0) = 0, D(y)(0) = 0],y(t), singsol=all)
\[ y \left (t \right ) = \frac {\left (\operatorname {Heaviside}\left (4+k \right )+\operatorname {Heaviside}\left (t -4-k \right )-1\right ) \cos \left (-t +4+k \right )-\operatorname {Heaviside}\left (t -4-k \right )+\left (-\cos \left (t -4+k \right )+1\right ) \operatorname {Heaviside}\left (t -4+k \right )-\cos \left (t \right ) \operatorname {Heaviside}\left (-4+k \right )-\cos \left (t \right ) \operatorname {Heaviside}\left (4+k \right )+\operatorname {Heaviside}\left (-4+k \right ) \cos \left (t -4+k \right )+\cos \left (t \right )}{2 k} \]
✓ Solution by Mathematica
Time used: 1.204 (sec). Leaf size: 181
DSolve[{y''[t]+y[t]==1/(2*k)*(UnitStep[t-(4-k)] - UnitStep[t-(4+k)] ),{y[0]==0,y'[0]==0}},y[t],t,IncludeSingularSolutions -> True]
\begin{align*} y(t)\to \fbox {$\frac {(\cos (k-t+4)-1) \theta (-k+t-4)-(\cos (-k-t+4)-1) \theta (k+t-4)}{2 k}\text { if }-4<k<4$} y(t)\to \fbox {$\frac {\cos (-k-t+4)-\cos (t)+(\cos (k-t+4)-1) \theta (-k+t-4)-(\cos (-k-t+4)-1) \theta (k+t-4)}{2 k}\text { if }k>4$} y(t)\to \fbox {$\frac {-\cos (k-t+4)+\cos (t)+(\cos (k-t+4)-1) \theta (-k+t-4)-(\cos (-k-t+4)-1) \theta (k+t-4)}{2 k}\text { if }k<-4$} \end{align*}