4.29 problem Problem 4(e)

Internal problem ID [12337]

Book: APPLIED DIFFERENTIAL EQUATIONS The Primary Course by Vladimir A. Dobrushkin. CRC Press 2015
Section: Chapter 5.6 Laplace transform. Nonhomogeneous equations. Problems page 368
Problem number: Problem 4(e).
ODE order: 2.
ODE degree: 1.

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

\[ \boxed {y^{\prime \prime }+4 y=\left \{\begin {array}{cc} 8 t & 0\le t <\frac {\pi }{2} \\ 8 \pi & \frac {\pi }{2}\le t \end {array}\right .} \] With initial conditions \begin {align*} [y \left (0\right ) = 0, y^{\prime }\left (0\right ) = 0] \end {align*}

Solution by Maple

Time used: 6.25 (sec). Leaf size: 40

dsolve([diff(y(t),t$2)+4*y(t)=piecewise(0<=t and t<Pi/2,8*t,t>=Pi/2,8*Pi),y(0) = 0, D(y)(0) = 0],y(t), singsol=all)
 

\[ y \left (t \right ) = \left \{\begin {array}{cc} -\sin \left (2 t \right )+2 t & t <\frac {\pi }{2} \\ -2 \sin \left (2 t \right )+2 \cos \left (t \right )^{2} \pi +\pi & \frac {\pi }{2}\le t \end {array}\right . \]

Solution by Mathematica

Time used: 0.068 (sec). Leaf size: 48

DSolve[{y''[t]+4*y[t]==Piecewise[{{8*t,0<=t<Pi/2},{8*Pi,t>=Pi/2}}],{y[0]==0,y'[0]==0}},y[t],t,IncludeSingularSolutions -> True]
 

\[ y(t)\to \begin {array}{cc} \{ & \begin {array}{cc} 0 & t\leq 0 \\ 2 t-\sin (2 t) & t>0\land 2 t\leq \pi \\ \pi \cos (2 t)-2 \sin (2 t)+2 \pi & \text {True} \\ \end {array} \\ \end {array} \]