78.16.20 problem 20

Internal problem ID [18328]
Book : DIFFERENTIAL EQUATIONS WITH APPLICATIONS AND HISTORICAL NOTES by George F. Simmons. 3rd edition. 2017. CRC press, Boca Raton FL.
Section : Chapter 3. Second order linear equations. Section 23. Operator Methods for Finding Particular Solutions. Problems at page 169
Problem number : 20
Date solved : Monday, March 31, 2025 at 05:25:42 PM
CAS classification : [[_high_order, _linear, _nonhomogeneous]]

\begin{align*} y^{\prime \prime \prime \prime }-y&=-x^{3}+1 \end{align*}

Maple. Time used: 0.003 (sec). Leaf size: 27
ode:=diff(diff(diff(diff(y(x),x),x),x),x)-y(x) = -x^3+1; 
dsolve(ode,y(x), singsol=all);
 
\[ y = x^{3}-1+c_1 \cos \left (x \right )+c_2 \,{\mathrm e}^{x}+c_3 \sin \left (x \right )+c_4 \,{\mathrm e}^{-x} \]
Mathematica. Time used: 0.003 (sec). Leaf size: 34
ode=D[y[x],{x,4}]-y[x]==1-x^3; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to x^3+c_1 e^x+c_3 e^{-x}+c_2 \cos (x)+c_4 \sin (x)-1 \]
Sympy. Time used: 0.105 (sec). Leaf size: 27
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x**3 - y(x) + Derivative(y(x), (x, 4)) - 1,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = C_{1} e^{- x} + C_{2} e^{x} + C_{3} \sin {\left (x \right )} + C_{4} \cos {\left (x \right )} + x^{3} - 1 \]