6.19.41 problem section 9.3, problem 41

Internal problem ID [2188]
Book : Elementary differential equations with boundary value problems. William F. Trench. Brooks/Cole 2001
Section : Chapter 9 Introduction to Linear Higher Order Equations. Section 9.3. Undetermined Coefficients for Higher Order Equations. Page 495
Problem number : section 9.3, problem 41
Date solved : Tuesday, September 30, 2025 at 05:24:45 AM
CAS classification : [[_high_order, _linear, _nonhomogeneous]]

\begin{align*} y^{\prime \prime \prime \prime }+3 y^{\prime \prime \prime }+2 y^{\prime \prime }-2 y^{\prime }-4 y&=-{\mathrm e}^{-x} \left (\cos \left (x \right )-\sin \left (x \right )\right ) \end{align*}
Maple. Time used: 0.012 (sec). Leaf size: 43
ode:=diff(diff(diff(diff(y(x),x),x),x),x)+3*diff(diff(diff(y(x),x),x),x)+2*diff(diff(y(x),x),x)-2*diff(y(x),x)-4*y(x) = -exp(-x)*(cos(x)-sin(x)); 
dsolve(ode,y(x), singsol=all);
 
\[ y = \frac {\left (\left (5 x +50 c_3 +14\right ) \cos \left (x \right )+10 \sin \left (x \right ) \left (x +5 c_4 -\frac {1}{5}\right )\right ) {\mathrm e}^{-x}}{50}+c_1 \,{\mathrm e}^{x}+c_2 \,{\mathrm e}^{-2 x} \]
Mathematica. Time used: 0.094 (sec). Leaf size: 58
ode=1*D[y[x],{x,4}]+3*D[y[x],{x,3}]+2*D[y[x],{x,2}]-2*D[y[x],x]-4*y[x]==-Exp[-1*x]*(Cos[x]-Sin[x]); 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to \frac {1}{50} e^{-2 x} \left (50 \left (c_4 e^{3 x}+c_3\right )+e^x (5 x+14+50 c_2) \cos (x)+e^x (10 x-7+50 c_1) \sin (x)\right ) \end{align*}
Sympy. Time used: 0.412 (sec). Leaf size: 60
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq((-sin(x) + cos(x))*exp(-x) - 4*y(x) - 2*Derivative(y(x), x) + 2*Derivative(y(x), (x, 2)) + 3*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^{x} + \left (C_{1} \sin {\left (x \right )} + C_{2} \cos {\left (x \right )} + \frac {3 \sqrt {2} x \sin {\left (x + \frac {\pi }{4} \right )}}{20} - \frac {\sqrt {2} x \cos {\left (x + \frac {\pi }{4} \right )}}{20}\right ) e^{- x} \]