15.11.23 problem 23

Internal problem ID [3133]
Book : Differential Equations by Alfred L. Nelson, Karl W. Folley, Max Coral. 3rd ed. DC heath. Boston. 1964
Section : Exercise 19, page 86
Problem number : 23
Date solved : Monday, January 27, 2025 at 07:22:45 AM
CAS classification : [[_2nd_order, _linear, _nonhomogeneous]]

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

Solution by Maple

Time used: 0.003 (sec). Leaf size: 43

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

Solution by Mathematica

Time used: 0.830 (sec). Leaf size: 59

DSolve[D[y[x],{x,2}]+4*D[y[x],x]+5*y[x]==2*x-Exp[-4*x]+Sin[2*x],y[x],x,IncludeSingularSolutions -> True]
 
\[ y(x)\to \frac {2 x}{5}-\frac {e^{-4 x}}{5}+\frac {1}{65} \sin (2 x)-\frac {8}{65} \cos (2 x)+c_2 e^{-2 x} \cos (x)+c_1 e^{-2 x} \sin (x)-\frac {8}{25} \]