73.15.9 problem 22.3 (d)

Internal problem ID [15440]
Book : Ordinary Differential Equations. An introduction to the fundamentals. Kenneth B. Howell. second edition. CRC Press. FL, USA. 2020
Section : Chapter 22. Method of undetermined coefficients. Additional exercises page 412
Problem number : 22.3 (d)
Date solved : Tuesday, January 28, 2025 at 07:55:49 AM
CAS classification : [[_2nd_order, _linear, _nonhomogeneous]]

\begin{align*} y^{\prime \prime }+4 y^{\prime }-5 y&=\cos \left (x \right ) \end{align*}

Solution by Maple

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

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

Solution by Mathematica

Time used: 0.074 (sec). Leaf size: 68

DSolve[D[y[x],{x,2}]+4*D[y[x],x]-5*y[x]==Cos[x],y[x],x,IncludeSingularSolutions -> True]
 
\[ y(x)\to e^{-5 x} \left (\int _1^x-\frac {1}{6} e^{5 K[1]} \cos (K[1])dK[1]+e^{6 x} \int _1^x\frac {1}{6} e^{-K[2]} \cos (K[2])dK[2]+c_2 e^{6 x}+c_1\right ) \]