7.11.23 problem 23

Internal problem ID [344]
Book : Elementary Differential Equations. By C. Henry Edwards, David E. Penney and David Calvis. 6th edition. 2008
Section : Chapter 2. Linear Equations of Higher Order. Section 2.5 (Nonhomogeneous equations and undetermined coefficients). Problems at page 161
Problem number : 23
Date solved : Wednesday, February 05, 2025 at 03:23:54 AM
CAS classification : [[_2nd_order, _linear, _nonhomogeneous]]

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

Solution by Maple

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

dsolve(diff(y(x),x$2)+4*y(x)=3*x*cos(2*x),y(x), singsol=all)
 
\[ y = \frac {\left (24 x^{2}+64 c_2 -3\right ) \sin \left (2 x \right )}{64}+\frac {3 \cos \left (2 x \right ) \left (x +\frac {16 c_1}{3}\right )}{16} \]

Solution by Mathematica

Time used: 0.111 (sec). Leaf size: 38

DSolve[D[y[x],{x,2}]+4*y[x]==3*x*Cos[2*x],y[x],x,IncludeSingularSolutions -> True]
 
\[ y(x)\to \frac {1}{64} \left (24 x^2-3+64 c_2\right ) \sin (2 x)+\left (\frac {3 x}{16}+c_1\right ) \cos (2 x) \]