15.6 problem 4 (g)

Internal problem ID [12812]

Book: Ordinary Differential Equations by Charles E. Roberts, Jr. CRC Press. 2010
Section: Chapter 5. The Laplace Transform Method. Exercises 5.4, page 265
Problem number: 4 (g).
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} x & 0\le x <1 \\ 1 & 1\le x \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: 8.235 (sec). Leaf size: 46

dsolve([diff(y(x),x$2)-4*y(x)=piecewise(0<=x and x<1,x,1<=x,1),y(0) = 0, D(y)(0) = 0],y(x), singsol=all)
 

\[ y \left (x \right ) = \frac {\left (\left \{\begin {array}{cc} \sinh \left (2 x \right )-2 x & x <1 \\ \sinh \left (2\right )-4 & x =1 \\ \sinh \left (2 x \right )-\sinh \left (2 x -2\right )-2 & 1<x \end {array}\right .\right )}{8} \]

Solution by Mathematica

Time used: 0.045 (sec). Leaf size: 36

DSolve[{y''[x]-4*y[x]==Piecewise[{ {x,0<=x<1},{x,x>=1}}],{y[0]==0,y'[0]==0}},y[x],x,IncludeSingularSolutions -> True]
                                                                                    
                                                                                    
 

\[ y(x)\to \begin {array}{cc} \{ & \begin {array}{cc} 0 & x\leq 0 \\ \frac {1}{16} e^{-2 x} \left (-4 e^{2 x} x+e^{4 x}-1\right ) & \text {True} \\ \end {array} \\ \end {array} \]