11.5.2 problem 2

Internal problem ID [1507]
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 : 2
Date solved : Monday, January 27, 2025 at 04:58:25 AM
CAS classification : [[_2nd_order, _linear, _nonhomogeneous]]

\begin{align*} y^{\prime \prime }+4 y&=\delta \left (t -\pi \right )-\delta \left (t -2 \pi \right ) \end{align*}

Using Laplace method With initial conditions

\begin{align*} y \left (0\right )&=0\\ y^{\prime }\left (0\right )&=0 \end{align*}

Solution by Maple

Time used: 0.332 (sec). Leaf size: 25

dsolve([diff(y(t),t$2)+4*y(t)=Dirac(t-Pi)-Dirac(t-2*Pi),y(0) = 0, D(y)(0) = 0],y(t), singsol=all)
 
\[ y = \frac {\left (-\operatorname {Heaviside}\left (t -2 \pi \right )+\operatorname {Heaviside}\left (t -\pi \right )\right ) \sin \left (2 t \right )}{2} \]

Solution by Mathematica

Time used: 0.036 (sec). Leaf size: 26

DSolve[{D[y[t],{t,2}]+4*y[t]==DiracDelta[t-Pi]-DiracDelta[t-2*Pi],{y[0]==0,Derivative[1][y][0] ==0}},y[t],t,IncludeSingularSolutions -> True]
 
\[ y(t)\to (\theta (t-2 \pi )-\theta (t-\pi )) \sin (t) (-\cos (t)) \]