83.17.4 problem 4

Internal problem ID [19200]
Book : A Text book for differentional equations for postgraduate students by Ray and Chaturvedi. First edition, 1958. BHASKAR press. INDIA
Section : Chapter III. Ordinary linear differential equations with constant coefficients. Misc. Examples on chapter III at page 50
Problem number : 4
Date solved : Tuesday, January 28, 2025 at 01:13:08 PM
CAS classification : [[_2nd_order, _linear, _nonhomogeneous]]

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

Solution by Maple

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

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

Solution by Mathematica

Time used: 0.020 (sec). Leaf size: 25

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