6.19.50 problem section 9.3, problem 50

Internal problem ID [2197]
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 50
Date solved : Tuesday, September 30, 2025 at 05:24:54 AM
CAS classification : [[_3rd_order, _missing_y]]

\begin{align*} y^{\prime \prime \prime }-y^{\prime }&=-2-2 x +4 \,{\mathrm e}^{x}-6 \,{\mathrm e}^{-x}+96 \,{\mathrm e}^{3 x} \end{align*}
Maple. Time used: 0.002 (sec). Leaf size: 41
ode:=diff(diff(diff(y(x),x),x),x)-diff(y(x),x) = -2*x-2+4*exp(x)-6*exp(-x)+96*exp(3*x); 
dsolve(ode,y(x), singsol=all);
 
\[ y = \frac {\left (-6 x -2 c_2 -9\right ) {\mathrm e}^{-x}}{2}+4 \,{\mathrm e}^{3 x}+\left (2 x -3+c_1 \right ) {\mathrm e}^{x}+x^{2}+2 x +c_3 \]
Mathematica. Time used: 0.371 (sec). Leaf size: 49
ode=1*D[y[x],{x,3}]-0*D[y[x],{x,2}]-1*D[y[x],x]-0*y[x]==-2*(1+x)+4*Exp[x]-6*Exp[-x]+96*Exp[3*x]; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to x (x+2)+4 e^{3 x}+e^x (2 x-3+c_1)-\frac {1}{2} e^{-x} (6 x+9+2 c_2)+c_3 \end{align*}
Sympy. Time used: 0.182 (sec). Leaf size: 34
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(2*x - 96*exp(3*x) - 4*exp(x) - Derivative(y(x), x) + Derivative(y(x), (x, 3)) + 2 + 6*exp(-x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = C_{1} + x^{2} + 2 x + \left (C_{2} - 3 x\right ) e^{- x} + \left (C_{3} + 2 x\right ) e^{x} + 4 e^{3 x} \]