7.6 problem 23

Internal problem ID [4946]

Book: ADVANCED ENGINEERING MATHEMATICS. ERWIN KREYSZIG, HERBERT KREYSZIG, EDWARD J. NORMINTON. 10th edition. John Wiley USA. 2011
Section: Chapter 6. Laplace Transforms. Problem set 6.3, page 224
Problem number: 23.
ODE order: 2.
ODE degree: 1.

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

Solve \begin {gather*} \boxed {y^{\prime \prime }+y^{\prime }-2 y-\left (\left \{\begin {array}{cc} 3 \sin \relax (t )-\cos \relax (t ) & 0<t <2 \pi \\ 3 \sin \left (2 t \right )-\cos \left (2 t \right ) & 2 \pi <t \end {array}\right .\right )=0} \end {gather*} With initial conditions \begin {align*} [y \relax (0) = 1, y^{\prime }\relax (0) = 0] \end {align*}

Solution by Maple

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

dsolve([diff(y(t),t$2)+diff(y(t),t)-2*y(t)=piecewise(0<t and t<2*Pi,3*sin(t)-cos(t),t>2*Pi,3*sin(2*t)-cos(2*t)),y(0) = 1, D(y)(0) = 0],y(t), singsol=all)
 

\[ y \relax (t ) = \left \{\begin {array}{cc} \frac {\left (2 \,{\mathrm e}^{3 t}+1\right ) {\mathrm e}^{-2 t}}{3} & t <0 \\ {\mathrm e}^{t}-\sin \relax (t ) & t <2 \pi \\ {\mathrm e}^{t}-\frac {\sin \left (2 t \right )}{2} & 2 \pi \le t \end {array}\right . \]

Solution by Mathematica

Time used: 0.031 (sec). Leaf size: 55

DSolve[{y''[t]+y'[t]-2*y[t]==Piecewise[{{3*Sin[t]-Cos[t],0<t<2*Pi},{3*Sin[2*t]-Cos[2*t],t>2*Pi}}],{y[0]==1,y'[0]==0}},y[t],t,IncludeSingularSolutions -> True]
 

\begin{align*} y(t)\to {cc} \{ & {cc} \frac {e^{-2 t}}{3}+\frac {2 e^t}{3} & t\leq 0 \\ e^t-\sin (t) & 0<t\leq 2 \pi \\ e^t-\cos (t) \sin (t) & \text {True} \\ \\ \\ \\ \\ \end{align*}