42.3.6 problem Example 3.35

Internal problem ID [8816]
Book : THEORY OF DIFFERENTIAL EQUATIONS IN ENGINEERING AND MECHANICS. K.T. CHAU, CRC Press. Boca Raton, FL. 2018
Section : Chapter 3. Ordinary Differential Equations. Section 3.5 HIGHER ORDER ODE. Page 181
Problem number : Example 3.35
Date solved : Tuesday, September 30, 2025 at 05:52:52 PM
CAS classification : [[_high_order, _linear, _nonhomogeneous]]

\begin{align*} y^{\prime \prime \prime \prime }+2 y^{\prime \prime }+y&=3 \sin \left (t \right )-5 \cos \left (t \right ) \end{align*}
Maple. Time used: 0.005 (sec). Leaf size: 45
ode:=diff(diff(diff(diff(y(t),t),t),t),t)+2*diff(diff(y(t),t),t)+y(t) = 3*sin(t)-5*cos(t); 
dsolve(ode,y(t), singsol=all);
 
\[ y = \frac {\left (5 t^{2}+\left (8 c_3 -6\right ) t +8 c_1 -10\right ) \cos \left (t \right )}{8}-\frac {3 \sin \left (t \right ) \left (t^{2}+\left (-\frac {8 c_4}{3}+\frac {10}{3}\right ) t -\frac {8 c_2}{3}-2\right )}{8} \]
Mathematica. Time used: 0.301 (sec). Leaf size: 162
ode=D[y[t],{t,4}]+2*D[y[t],{t,2}]+y[t]==3*Sin[t]-5*Cos[t]; 
ic={}; 
DSolve[{ode,ic},y[t],t,IncludeSingularSolutions->True]
 
\begin{align*} y(t)&\to \cos (t) \int _1^t-\frac {1}{2} (5 \cos (K[1])-3 \sin (K[1])) (\cos (K[1]) K[1]-\sin (K[1]))dK[1]+t \cos (t) \int _1^t\frac {1}{4} (5 \cos (2 K[2])-3 \sin (2 K[2])+5)dK[2]+\sin (t) \int _1^t-\frac {1}{2} (5 \cos (K[3])-3 \sin (K[3])) (\cos (K[3])+K[3] \sin (K[3]))dK[3]+t \sin (t) \int _1^t\frac {1}{4} (3 \cos (2 K[4])+5 \sin (2 K[4])-3)dK[4]+c_1 \cos (t)+c_2 t \cos (t)+c_3 \sin (t)+c_4 t \sin (t) \end{align*}
Sympy. Time used: 0.104 (sec). Leaf size: 29
from sympy import * 
t = symbols("t") 
y = Function("y") 
ode = Eq(y(t) - 3*sin(t) + 5*cos(t) + 2*Derivative(y(t), (t, 2)) + Derivative(y(t), (t, 4)),0) 
ics = {} 
dsolve(ode,func=y(t),ics=ics)
 
\[ y{\left (t \right )} = \left (C_{1} + t \left (C_{2} - \frac {3 t}{8}\right )\right ) \sin {\left (t \right )} + \left (C_{3} + t \left (C_{4} + \frac {5 t}{8}\right )\right ) \cos {\left (t \right )} \]