58.11.24 problem 24

Internal problem ID [14755]
Book : Differential Equations by Shepley L. Ross. Third edition. John Willey. New Delhi. 2004.
Section : Chapter 4, Section 4.3. The method of undetermined coefficients. Exercises page 151
Problem number : 24
Date solved : Thursday, October 02, 2025 at 09:50:48 AM
CAS classification : [[_high_order, _linear, _nonhomogeneous]]

\begin{align*} y^{\prime \prime \prime \prime }-5 y^{\prime \prime \prime }+7 y^{\prime \prime }-5 y^{\prime }+6 y&=5 \sin \left (x \right )-12 \sin \left (2 x \right ) \end{align*}
Maple. Time used: 0.009 (sec). Leaf size: 51
ode:=diff(diff(diff(diff(y(x),x),x),x),x)-5*diff(diff(diff(y(x),x),x),x)+7*diff(diff(y(x),x),x)-5*diff(y(x),x)+6*y(x) = 5*sin(x)-12*sin(2*x); 
dsolve(ode,y(x), singsol=all);
 
\[ y = \frac {5 \cos \left (2 x \right )}{13}+c_3 \,{\mathrm e}^{2 x}+c_4 \,{\mathrm e}^{3 x}+\frac {\sin \left (2 x \right )}{13}+\frac {\left (-2-5 x +20 c_1 \right ) \cos \left (x \right )}{20}+\frac {\left (1+x +4 c_2 \right ) \sin \left (x \right )}{4} \]
Mathematica. Time used: 0.118 (sec). Leaf size: 71
ode=D[y[x],{x,4}]-5*D[y[x],{x,3}]+7*D[y[x],{x,2}]-5*D[y[x],x]+6*y[x]==5*Sin[x]-12*Sin[2*x]; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to -\frac {5 \sin ^2(x)}{13}+\frac {5 \cos ^2(x)}{13}+e^{2 x} \left (c_4 e^x+c_3\right )+\left (\frac {x}{4}+\frac {3}{8}+c_2\right ) \sin (x)+\cos (x) \left (-\frac {x}{4}+\frac {2 \sin (x)}{13}-\frac {1}{10}+c_1\right ) \end{align*}
Sympy. Time used: 0.251 (sec). Leaf size: 48
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(6*y(x) - 5*sin(x) + 12*sin(2*x) - 5*Derivative(y(x), x) + 7*Derivative(y(x), (x, 2)) - 5*Derivative(y(x), (x, 3)) + Derivative(y(x), (x, 4)),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = C_{3} e^{2 x} + C_{4} e^{3 x} + \left (C_{1} - \frac {x}{4}\right ) \cos {\left (x \right )} + \left (C_{2} + \frac {x}{4}\right ) \sin {\left (x \right )} + \frac {\sin {\left (2 x \right )}}{13} + \frac {5 \cos {\left (2 x \right )}}{13} \]