49.10.5 problem 1(e)

Internal problem ID [7663]
Book : An introduction to Ordinary Differential Equations. Earl A. Coddington. Dover. NY 1961
Section : Chapter 2. Linear equations with constant coefficients. Page 89
Problem number : 1(e)
Date solved : Sunday, March 30, 2025 at 12:18:21 PM
CAS classification : [[_high_order, _linear, _nonhomogeneous]]

\begin{align*} y^{\prime \prime \prime \prime }-y&=\cos \left (x \right ) \end{align*}

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