78.9.9 problem 5 (c)

Internal problem ID [18257]
Book : DIFFERENTIAL EQUATIONS WITH APPLICATIONS AND HISTORICAL NOTES by George F. Simmons. 3rd edition. 2017. CRC press, Boca Raton FL.
Section : Chapter 3. Second order linear equations. Section 14. Introduction. Problems at page 112
Problem number : 5 (c)
Date solved : Tuesday, January 28, 2025 at 11:44:32 AM
CAS classification : [[_2nd_order, _linear, _nonhomogeneous]]

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

Solution by Maple

Time used: 0.004 (sec). Leaf size: 19

dsolve(diff(y(x),x$2)-y(x)=sin(x),y(x), singsol=all)
 
\[ y = c_{2} {\mathrm e}^{-x}+{\mathrm e}^{x} c_{1} -\frac {\sin \left (x \right )}{2} \]

Solution by Mathematica

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

DSolve[D[y[x],{x,2}] - y[x]==Sin[x],y[x],x,IncludeSingularSolutions -> True]
 
\[ y(x)\to -\frac {\sin (x)}{2}+c_1 e^x+c_2 e^{-x} \]