##### 4.45.46 $$2 \left (y''''(x)+\left (a^2+b^2\right ) y''(x)+a^2 b^2 y(x)\right )=\cos (a x)+\cos (b x)$$

ODE
$2 \left (y''''(x)+\left (a^2+b^2\right ) y''(x)+a^2 b^2 y(x)\right )=\cos (a x)+\cos (b x)$ ODE Classiﬁcation

[[_high_order, _linear, _nonhomogeneous]]

Book solution method
TO DO

Mathematica
cpu = 0.938556 (sec), leaf count = 173

$\left \{\left \{y(x)\to \frac {a \left (2 b \left (b^2-a^2\right ) \left (b \sin (a x) \left (x+4 a c_4 \left (b^2-a^2\right )\right )-a \sin (b x) \left (x+4 b c_2 \left (a^2-b^2\right )\right )\right )+a \left (8 a^4 b^2 c_1-16 a^2 b^4 c_1+a^2+8 b^6 c_1-5 b^2\right ) \cos (b x)\right )+b^2 \left (8 a^6 c_3-16 a^4 b^2 c_3+a^2 \left (-5+8 b^4 c_3\right )+b^2\right ) \cos (a x)}{8 a^2 b^2 (a-b)^2 (a+b)^2}\right \}\right \}$

Maple
cpu = 2.441 (sec), leaf count = 135

$\left [y \left (x \right ) = -\frac {\left (5 a^{2}-b^{2}\right ) \cos \left (a x \right )}{8 a^{2} \left (a +b \right )^{2} \left (a -b \right )^{2}}+\frac {\left (a^{2}-5 b^{2}\right ) \cos \left (b x \right )}{8 b^{2} \left (a +b \right )^{2} \left (a -b \right )^{2}}-\frac {x \sin \left (a x \right )}{4 a \left (a -b \right ) \left (a +b \right )}+\frac {x \sin \left (b x \right )}{4 b \left (a -b \right ) \left (a +b \right )}+\cos \left (a x \right ) \textit {\_C1} +\textit {\_C2} \cos \left (b x \right )+\textit {\_C3} \sin \left (a x \right )+\textit {\_C4} \sin \left (b x \right )\right ]$ Mathematica raw input

DSolve[2*(a^2*b^2*y[x] + (a^2 + b^2)*y''[x] + y''''[x]) == Cos[a*x] + Cos[b*x],y[x],x]

Mathematica raw output

{{y[x] -> (b^2*(b^2 + 8*a^6*C[3] - 16*a^4*b^2*C[3] + a^2*(-5 + 8*b^4*C[3]))*Cos[
a*x] + a*(a*(a^2 - 5*b^2 + 8*a^4*b^2*C[1] - 16*a^2*b^4*C[1] + 8*b^6*C[1])*Cos[b*
x] + 2*b*(-a^2 + b^2)*(b*(x + 4*a*(-a^2 + b^2)*C[4])*Sin[a*x] - a*(x + 4*b*(a^2
- b^2)*C[2])*Sin[b*x])))/(8*a^2*(a - b)^2*b^2*(a + b)^2)}}

Maple raw input

dsolve(2*diff(diff(diff(diff(y(x),x),x),x),x)+2*(a^2+b^2)*diff(diff(y(x),x),x)+2*a^2*b^2*y(x) = cos(a*x)+cos(b*x), y(x))

Maple raw output

[y(x) = -1/8*(5*a^2-b^2)/a^2/(a+b)^2/(a-b)^2*cos(a*x)+1/8*(a^2-5*b^2)/b^2/(a+b)^
2/(a-b)^2*cos(b*x)-1/4/a*x/(a-b)/(a+b)*sin(a*x)+1/4/b*x/(a-b)/(a+b)*sin(b*x)+cos
(a*x)*_C1+_C2*cos(b*x)+_C3*sin(a*x)+_C4*sin(b*x)]