\(\int \frac {1}{(\cos (x)+\cos (5 x))^4} \, dx\) [47]

Optimal result
Mathematica [A] (verified)
Rubi [A] (verified)
Maple [A] (verified)
Fricas [B] (verification not implemented)
Sympy [F]
Maxima [F(-2)]
Giac [A] (verification not implemented)
Mupad [B] (verification not implemented)
Reduce [F]

Optimal result

Integrand size = 9, antiderivative size = 159 \[ \int \frac {1}{(\cos (x)+\cos (5 x))^4} \, dx=\frac {103}{8} \text {arctanh}(2 \cos (x) \sin (x))+\frac {1808 \log \left (\cos (x)-\sqrt {3} \sin (x)\right )}{81 \sqrt {3}}-\frac {1808 \log \left (\cos (x)+\sqrt {3} \sin (x)\right )}{81 \sqrt {3}}+\frac {43 \tan (x)}{3888}+\frac {\tan ^3(x)}{3888}+\frac {4 \tan (x) \left (2699-7073 \tan ^2(x)\right )}{6561 \left (1-4 \tan ^2(x)+3 \tan ^4(x)\right )^3}-\frac {2 \tan (x) \left (17527-20226 \tan ^2(x)\right )}{6561 \left (1-4 \tan ^2(x)+3 \tan ^4(x)\right )^2}+\frac {\tan (x) \left (198061-287289 \tan ^2(x)\right )}{8748 \left (1-4 \tan ^2(x)+3 \tan ^4(x)\right )} \] Output:

103/8*arctanh(2*cos(x)*sin(x))+1808/243*ln(cos(x)-sin(x)*3^(1/2))*3^(1/2)- 
1808/243*ln(cos(x)+sin(x)*3^(1/2))*3^(1/2)+43/3888*tan(x)+1/3888*tan(x)^3+ 
4/6561*tan(x)*(2699-7073*tan(x)^2)/(1-4*tan(x)^2+3*tan(x)^4)^3-2/6561*tan( 
x)*(17527-20226*tan(x)^2)/(1-4*tan(x)^2+3*tan(x)^4)^2+tan(x)*(198061-28728 
9*tan(x)^2)/(8748-34992*tan(x)^2+26244*tan(x)^4)
 

Mathematica [A] (verified)

Time = 1.11 (sec) , antiderivative size = 146, normalized size of antiderivative = 0.92 \[ \int \frac {1}{(\cos (x)+\cos (5 x))^4} \, dx=\frac {-115712 \sqrt {3} \text {arctanh}\left (\sqrt {3} \tan (x)\right )-100116 \log (\cos (x)-\sin (x))+100116 \log (\cos (x)+\sin (x))+\frac {1539}{(\cos (x)-\sin (x))^2}+162 (169 \cos (x)+82 \cos (3 x)+83 \cos (5 x)) \sec ^3(2 x) \sin (x)-\frac {1539}{(\cos (x)+\sin (x))^2}-\frac {9472 \sin (2 x)}{(1-2 \cos (2 x))^2}+\frac {1536 \sin (2 x)}{(-1+2 \cos (2 x))^3}+\frac {51456 \sin (2 x)}{-1+2 \cos (2 x)}+84 \tan (x)+2 \sec ^2(x) \tan (x)}{7776} \] Input:

Integrate[(Cos[x] + Cos[5*x])^(-4),x]
 

Output:

(-115712*Sqrt[3]*ArcTanh[Sqrt[3]*Tan[x]] - 100116*Log[Cos[x] - Sin[x]] + 1 
00116*Log[Cos[x] + Sin[x]] + 1539/(Cos[x] - Sin[x])^2 + 162*(169*Cos[x] + 
82*Cos[3*x] + 83*Cos[5*x])*Sec[2*x]^3*Sin[x] - 1539/(Cos[x] + Sin[x])^2 - 
(9472*Sin[2*x])/(1 - 2*Cos[2*x])^2 + (1536*Sin[2*x])/(-1 + 2*Cos[2*x])^3 + 
 (51456*Sin[2*x])/(-1 + 2*Cos[2*x]) + 84*Tan[x] + 2*Sec[x]^2*Tan[x])/7776
 

Rubi [A] (verified)

Time = 0.59 (sec) , antiderivative size = 133, normalized size of antiderivative = 0.84, number of steps used = 12, number of rules used = 11, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 1.222, Rules used = {3042, 4823, 27, 1517, 27, 2206, 27, 2206, 27, 2205, 2009}

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

\(\displaystyle \int \frac {1}{(\cos (x)+\cos (5 x))^4} \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {1}{(\cos (x)+\cos (5 x))^4}dx\)

\(\Big \downarrow \) 4823

\(\displaystyle \int \frac {\left (\tan ^2(x)+1\right )^9}{16 \left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^4}d\tan (x)\)

\(\Big \downarrow \) 27

\(\displaystyle \frac {1}{16} \int \frac {\left (\tan ^2(x)+1\right )^9}{\left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^4}d\tan (x)\)

\(\Big \downarrow \) 1517

\(\displaystyle \frac {1}{16} \left (\frac {64 \tan (x) \left (2699-7073 \tan ^2(x)\right )}{6561 \left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^3}-\frac {1}{24} \int \frac {8 \left (-2187 \tan ^{14}(x)-22599 \tan ^{12}(x)-108135 \tan ^{10}(x)-320355 \tan ^8(x)-666657 \tan ^6(x)-1057653 \tan ^4(x)+2702355 \tan ^2(x)+166175\right )}{2187 \left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^3}d\tan (x)\right )\)

\(\Big \downarrow \) 27

\(\displaystyle \frac {1}{16} \left (\frac {64 \tan (x) \left (2699-7073 \tan ^2(x)\right )}{6561 \left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^3}-\frac {\int \frac {-2187 \tan ^{14}(x)-22599 \tan ^{12}(x)-108135 \tan ^{10}(x)-320355 \tan ^8(x)-666657 \tan ^6(x)-1057653 \tan ^4(x)+2702355 \tan ^2(x)+166175}{\left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^3}d\tan (x)}{6561}\right )\)

\(\Big \downarrow \) 2206

\(\displaystyle \frac {1}{16} \left (\frac {\frac {1}{16} \int \frac {48 \left (243 \tan ^{10}(x)+2835 \tan ^8(x)+15714 \tan ^6(x)+55602 \tan ^4(x)+1221691 \tan ^2(x)+131563\right )}{\left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^2}d\tan (x)-\frac {32 \tan (x) \left (17527-20226 \tan ^2(x)\right )}{\left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^2}}{6561}+\frac {64 \tan (x) \left (2699-7073 \tan ^2(x)\right )}{6561 \left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^3}\right )\)

\(\Big \downarrow \) 27

\(\displaystyle \frac {1}{16} \left (\frac {3 \int \frac {243 \tan ^{10}(x)+2835 \tan ^8(x)+15714 \tan ^6(x)+55602 \tan ^4(x)+1221691 \tan ^2(x)+131563}{\left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^2}d\tan (x)-\frac {32 \tan (x) \left (17527-20226 \tan ^2(x)\right )}{\left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^2}}{6561}+\frac {64 \tan (x) \left (2699-7073 \tan ^2(x)\right )}{6561 \left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^3}\right )\)

\(\Big \downarrow \) 2206

\(\displaystyle \frac {1}{16} \left (\frac {3 \left (\frac {4 \tan (x) \left (198061-287289 \tan ^2(x)\right )}{3 \tan ^4(x)-4 \tan ^2(x)+1}-\frac {1}{8} \int \frac {72 \left (-9 \tan ^6(x)-117 \tan ^4(x)+126949 \tan ^2(x)+73409\right )}{3 \tan ^4(x)-4 \tan ^2(x)+1}d\tan (x)\right )-\frac {32 \tan (x) \left (17527-20226 \tan ^2(x)\right )}{\left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^2}}{6561}+\frac {64 \tan (x) \left (2699-7073 \tan ^2(x)\right )}{6561 \left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^3}\right )\)

\(\Big \downarrow \) 27

\(\displaystyle \frac {1}{16} \left (\frac {3 \left (\frac {4 \tan (x) \left (198061-287289 \tan ^2(x)\right )}{3 \tan ^4(x)-4 \tan ^2(x)+1}-9 \int \frac {-9 \tan ^6(x)-117 \tan ^4(x)+126949 \tan ^2(x)+73409}{3 \tan ^4(x)-4 \tan ^2(x)+1}d\tan (x)\right )-\frac {32 \tan (x) \left (17527-20226 \tan ^2(x)\right )}{\left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^2}}{6561}+\frac {64 \tan (x) \left (2699-7073 \tan ^2(x)\right )}{6561 \left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^3}\right )\)

\(\Big \downarrow \) 2205

\(\displaystyle \frac {1}{16} \left (\frac {3 \left (\frac {4 \tan (x) \left (198061-287289 \tan ^2(x)\right )}{3 \tan ^4(x)-4 \tan ^2(x)+1}-9 \int \left (-3 \tan ^2(x)+\frac {12 \left (10565 \tan ^2(x)+6121\right )}{3 \tan ^4(x)-4 \tan ^2(x)+1}-43\right )d\tan (x)\right )-\frac {32 \tan (x) \left (17527-20226 \tan ^2(x)\right )}{\left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^2}}{6561}+\frac {64 \tan (x) \left (2699-7073 \tan ^2(x)\right )}{6561 \left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^3}\right )\)

\(\Big \downarrow \) 2009

\(\displaystyle \frac {1}{16} \left (\frac {3 \left (\frac {4 \tan (x) \left (198061-287289 \tan ^2(x)\right )}{3 \tan ^4(x)-4 \tan ^2(x)+1}-9 \left (-100116 \text {arctanh}(\tan (x))+57856 \sqrt {3} \text {arctanh}\left (\sqrt {3} \tan (x)\right )-\tan ^3(x)-43 \tan (x)\right )\right )-\frac {32 \tan (x) \left (17527-20226 \tan ^2(x)\right )}{\left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^2}}{6561}+\frac {64 \tan (x) \left (2699-7073 \tan ^2(x)\right )}{6561 \left (3 \tan ^4(x)-4 \tan ^2(x)+1\right )^3}\right )\)

Input:

Int[(Cos[x] + Cos[5*x])^(-4),x]
 

Output:

((64*Tan[x]*(2699 - 7073*Tan[x]^2))/(6561*(1 - 4*Tan[x]^2 + 3*Tan[x]^4)^3) 
 + ((-32*Tan[x]*(17527 - 20226*Tan[x]^2))/(1 - 4*Tan[x]^2 + 3*Tan[x]^4)^2 
+ 3*(-9*(-100116*ArcTanh[Tan[x]] + 57856*Sqrt[3]*ArcTanh[Sqrt[3]*Tan[x]] - 
 43*Tan[x] - Tan[x]^3) + (4*Tan[x]*(198061 - 287289*Tan[x]^2))/(1 - 4*Tan[ 
x]^2 + 3*Tan[x]^4)))/6561)/16
 

Defintions of rubi rules used

rule 27
Int[(a_)*(Fx_), x_Symbol] :> Simp[a   Int[Fx, x], x] /; FreeQ[a, x] &&  !Ma 
tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
 

rule 1517
Int[((d_) + (e_.)*(x_)^2)^(q_)*((a_) + (b_.)*(x_)^2 + (c_.)*(x_)^4)^(p_), x 
_Symbol] :> With[{f = Coeff[PolynomialRemainder[(d + e*x^2)^q, a + b*x^2 + 
c*x^4, x], x, 0], g = Coeff[PolynomialRemainder[(d + e*x^2)^q, a + b*x^2 + 
c*x^4, x], x, 2]}, Simp[x*(a + b*x^2 + c*x^4)^(p + 1)*((a*b*g - f*(b^2 - 2* 
a*c) - c*(b*f - 2*a*g)*x^2)/(2*a*(p + 1)*(b^2 - 4*a*c))), x] + Simp[1/(2*a* 
(p + 1)*(b^2 - 4*a*c))   Int[(a + b*x^2 + c*x^4)^(p + 1)*ExpandToSum[2*a*(p 
 + 1)*(b^2 - 4*a*c)*PolynomialQuotient[(d + e*x^2)^q, a + b*x^2 + c*x^4, x] 
 + b^2*f*(2*p + 3) - 2*a*c*f*(4*p + 5) - a*b*g + c*(4*p + 7)*(b*f - 2*a*g)* 
x^2, x], x], x]] /; FreeQ[{a, b, c, d, e}, x] && NeQ[b^2 - 4*a*c, 0] && NeQ 
[c*d^2 - b*d*e + a*e^2, 0] && IGtQ[q, 1] && LtQ[p, -1]
 

rule 2009
Int[u_, x_Symbol] :> Simp[IntSum[u, x], x] /; SumQ[u]
 

rule 2205
Int[(Px_)/((a_) + (b_.)*(x_)^2 + (c_.)*(x_)^4), x_Symbol] :> Int[ExpandInte 
grand[Px/(a + b*x^2 + c*x^4), x], x] /; FreeQ[{a, b, c}, x] && PolyQ[Px, x^ 
2] && Expon[Px, x^2] > 1
 

rule 2206
Int[(Px_)*((a_) + (b_.)*(x_)^2 + (c_.)*(x_)^4)^(p_), x_Symbol] :> With[{d = 
 Coeff[PolynomialRemainder[Px, a + b*x^2 + c*x^4, x], x, 0], e = Coeff[Poly 
nomialRemainder[Px, a + b*x^2 + c*x^4, x], x, 2]}, Simp[x*(a + b*x^2 + c*x^ 
4)^(p + 1)*((a*b*e - d*(b^2 - 2*a*c) - c*(b*d - 2*a*e)*x^2)/(2*a*(p + 1)*(b 
^2 - 4*a*c))), x] + Simp[1/(2*a*(p + 1)*(b^2 - 4*a*c))   Int[(a + b*x^2 + c 
*x^4)^(p + 1)*ExpandToSum[2*a*(p + 1)*(b^2 - 4*a*c)*PolynomialQuotient[Px, 
a + b*x^2 + c*x^4, x] + b^2*d*(2*p + 3) - 2*a*c*d*(4*p + 5) - a*b*e + c*(4* 
p + 7)*(b*d - 2*a*e)*x^2, x], x], x]] /; FreeQ[{a, b, c}, x] && PolyQ[Px, x 
^2] && Expon[Px, x^2] > 1 && NeQ[b^2 - 4*a*c, 0] && LtQ[p, -1]
 

rule 3042
Int[u_, x_Symbol] :> Int[DeactivateTrig[u, x], x] /; FunctionOfTrigOfLinear 
Q[u, x]
 

rule 4823
Int[(cos[(m_.)*((c_.) + (d_.)*(x_))]*(a_.) + cos[(n_.)*((c_.) + (d_.)*(x_)) 
]*(b_.))^(p_), x_Symbol] :> Simp[1/d   Subst[Int[Simplify[TrigExpand[a*Cos[ 
m*ArcTan[x]] + b*Cos[n*ArcTan[x]]]]^p/(1 + x^2), x], x, Tan[c + d*x]], x] / 
; FreeQ[{a, b, c, d}, x] && ILtQ[p/2, 0] && IntegerQ[(m - 1)/2] && IntegerQ 
[(n - 1)/2]
 
Maple [A] (verified)

Time = 13.34 (sec) , antiderivative size = 115, normalized size of antiderivative = 0.72

method result size
default \(\frac {\tan \left (x \right )^{3}}{3888}+\frac {43 \tan \left (x \right )}{3888}-\frac {1}{24 \left (\tan \left (x \right )-1\right )^{3}}+\frac {5}{16 \left (\tan \left (x \right )-1\right )^{2}}-\frac {25}{8 \left (\tan \left (x \right )-1\right )}-\frac {103 \ln \left (\tan \left (x \right )-1\right )}{8}+\frac {-\frac {3424 \tan \left (x \right )^{5}}{27}+\frac {17920 \tan \left (x \right )^{3}}{243}-\frac {2720 \tan \left (x \right )}{243}}{\left (3 \tan \left (x \right )^{2}-1\right )^{3}}-\frac {3616 \sqrt {3}\, \operatorname {arctanh}\left (\tan \left (x \right ) \sqrt {3}\right )}{243}-\frac {1}{24 \left (\tan \left (x \right )+1\right )^{3}}-\frac {5}{16 \left (\tan \left (x \right )+1\right )^{2}}-\frac {25}{8 \left (\tan \left (x \right )+1\right )}+\frac {103 \ln \left (\tan \left (x \right )+1\right )}{8}\) \(115\)
risch \(-\frac {i \left (1111 \,{\mathrm e}^{28 i x}-3616 \,{\mathrm e}^{26 i x}+552 \,{\mathrm e}^{24 i x}-5707 \,{\mathrm e}^{22 i x}-12743 \,{\mathrm e}^{20 i x}-3768 \,{\mathrm e}^{18 i x}-23899 \,{\mathrm e}^{16 i x}-15629 \,{\mathrm e}^{14 i x}-13800 \,{\mathrm e}^{12 i x}-26785 \,{\mathrm e}^{10 i x}-7469 \,{\mathrm e}^{8 i x}-13728 \,{\mathrm e}^{6 i x}-9560 \,{\mathrm e}^{4 i x}-1111 \,{\mathrm e}^{2 i x}-4392\right )}{324 \left ({\mathrm e}^{10 i x}+{\mathrm e}^{6 i x}+{\mathrm e}^{4 i x}+1\right )^{3}}+\frac {103 \ln \left ({\mathrm e}^{2 i x}+i\right )}{8}-\frac {103 \ln \left ({\mathrm e}^{2 i x}-i\right )}{8}+\frac {1808 \sqrt {3}\, \ln \left ({\mathrm e}^{2 i x}-\frac {1}{2}-\frac {i \sqrt {3}}{2}\right )}{243}-\frac {1808 \sqrt {3}\, \ln \left ({\mathrm e}^{2 i x}-\frac {1}{2}+\frac {i \sqrt {3}}{2}\right )}{243}\) \(184\)

Input:

int(1/(cos(x)+cos(5*x))^4,x,method=_RETURNVERBOSE)
 

Output:

1/3888*tan(x)^3+43/3888*tan(x)-1/24/(tan(x)-1)^3+5/16/(tan(x)-1)^2-25/8/(t 
an(x)-1)-103/8*ln(tan(x)-1)+64/9*(-107/6*tan(x)^5+280/27*tan(x)^3-85/54*ta 
n(x))/(3*tan(x)^2-1)^3-3616/243*3^(1/2)*arctanh(tan(x)*3^(1/2))-1/24/(tan( 
x)+1)^3-5/16/(tan(x)+1)^2-25/8/(tan(x)+1)+103/8*ln(tan(x)+1)
 

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 318 vs. \(2 (135) = 270\).

Time = 0.14 (sec) , antiderivative size = 318, normalized size of antiderivative = 2.00 \[ \int \frac {1}{(\cos (x)+\cos (5 x))^4} \, dx=\frac {25029 \, {\left (512 \, \cos \left (x\right )^{15} - 1920 \, \cos \left (x\right )^{13} + 2976 \, \cos \left (x\right )^{11} - 2440 \, \cos \left (x\right )^{9} + 1116 \, \cos \left (x\right )^{7} - 270 \, \cos \left (x\right )^{5} + 27 \, \cos \left (x\right )^{3}\right )} \log \left (2 \, \cos \left (x\right ) \sin \left (x\right ) + 1\right ) - 25029 \, {\left (512 \, \cos \left (x\right )^{15} - 1920 \, \cos \left (x\right )^{13} + 2976 \, \cos \left (x\right )^{11} - 2440 \, \cos \left (x\right )^{9} + 1116 \, \cos \left (x\right )^{7} - 270 \, \cos \left (x\right )^{5} + 27 \, \cos \left (x\right )^{3}\right )} \log \left (-2 \, \cos \left (x\right ) \sin \left (x\right ) + 1\right ) + 14464 \, {\left (512 \, \sqrt {3} \cos \left (x\right )^{15} - 1920 \, \sqrt {3} \cos \left (x\right )^{13} + 2976 \, \sqrt {3} \cos \left (x\right )^{11} - 2440 \, \sqrt {3} \cos \left (x\right )^{9} + 1116 \, \sqrt {3} \cos \left (x\right )^{7} - 270 \, \sqrt {3} \cos \left (x\right )^{5} + 27 \, \sqrt {3} \cos \left (x\right )^{3}\right )} \log \left (-\frac {8 \, \cos \left (x\right )^{4} - 4 \, {\left (2 \, \sqrt {3} \cos \left (x\right )^{3} - 3 \, \sqrt {3} \cos \left (x\right )\right )} \sin \left (x\right ) - 9}{16 \, \cos \left (x\right )^{4} - 24 \, \cos \left (x\right )^{2} + 9}\right ) + 3 \, {\left (4497408 \, \cos \left (x\right )^{14} - 14047744 \, \cos \left (x\right )^{12} + 17367936 \, \cos \left (x\right )^{10} - 10622496 \, \cos \left (x\right )^{8} + 3215624 \, \cos \left (x\right )^{6} - 386460 \, \cos \left (x\right )^{4} + 288 \, \cos \left (x\right )^{2} + 9\right )} \sin \left (x\right )}{3888 \, {\left (512 \, \cos \left (x\right )^{15} - 1920 \, \cos \left (x\right )^{13} + 2976 \, \cos \left (x\right )^{11} - 2440 \, \cos \left (x\right )^{9} + 1116 \, \cos \left (x\right )^{7} - 270 \, \cos \left (x\right )^{5} + 27 \, \cos \left (x\right )^{3}\right )}} \] Input:

integrate(1/(cos(x)+cos(5*x))^4,x, algorithm="fricas")
 

Output:

1/3888*(25029*(512*cos(x)^15 - 1920*cos(x)^13 + 2976*cos(x)^11 - 2440*cos( 
x)^9 + 1116*cos(x)^7 - 270*cos(x)^5 + 27*cos(x)^3)*log(2*cos(x)*sin(x) + 1 
) - 25029*(512*cos(x)^15 - 1920*cos(x)^13 + 2976*cos(x)^11 - 2440*cos(x)^9 
 + 1116*cos(x)^7 - 270*cos(x)^5 + 27*cos(x)^3)*log(-2*cos(x)*sin(x) + 1) + 
 14464*(512*sqrt(3)*cos(x)^15 - 1920*sqrt(3)*cos(x)^13 + 2976*sqrt(3)*cos( 
x)^11 - 2440*sqrt(3)*cos(x)^9 + 1116*sqrt(3)*cos(x)^7 - 270*sqrt(3)*cos(x) 
^5 + 27*sqrt(3)*cos(x)^3)*log(-(8*cos(x)^4 - 4*(2*sqrt(3)*cos(x)^3 - 3*sqr 
t(3)*cos(x))*sin(x) - 9)/(16*cos(x)^4 - 24*cos(x)^2 + 9)) + 3*(4497408*cos 
(x)^14 - 14047744*cos(x)^12 + 17367936*cos(x)^10 - 10622496*cos(x)^8 + 321 
5624*cos(x)^6 - 386460*cos(x)^4 + 288*cos(x)^2 + 9)*sin(x))/(512*cos(x)^15 
 - 1920*cos(x)^13 + 2976*cos(x)^11 - 2440*cos(x)^9 + 1116*cos(x)^7 - 270*c 
os(x)^5 + 27*cos(x)^3)
 

Sympy [F]

\[ \int \frac {1}{(\cos (x)+\cos (5 x))^4} \, dx=\int \frac {1}{\left (\cos {\left (x \right )} + \cos {\left (5 x \right )}\right )^{4}}\, dx \] Input:

integrate(1/(cos(x)+cos(5*x))**4,x)
 

Output:

Integral((cos(x) + cos(5*x))**(-4), x)
 

Maxima [F(-2)]

Exception generated. \[ \int \frac {1}{(\cos (x)+\cos (5 x))^4} \, dx=\text {Exception raised: RuntimeError} \] Input:

integrate(1/(cos(x)+cos(5*x))^4,x, algorithm="maxima")
 

Output:

Exception raised: RuntimeError >> ECL says: THROW: The catch RAT-ERR is un 
defined.
 

Giac [A] (verification not implemented)

Time = 0.13 (sec) , antiderivative size = 111, normalized size of antiderivative = 0.70 \[ \int \frac {1}{(\cos (x)+\cos (5 x))^4} \, dx=\frac {1}{3888} \, \tan \left (x\right )^{3} + \frac {1808}{243} \, \sqrt {3} \log \left (\frac {{\left | -2 \, \sqrt {3} + 6 \, \tan \left (x\right ) \right |}}{{\left | 2 \, \sqrt {3} + 6 \, \tan \left (x\right ) \right |}}\right ) - \frac {287289 \, \tan \left (x\right )^{11} - 964165 \, \tan \left (x\right )^{9} + 1212446 \, \tan \left (x\right )^{7} - 699966 \, \tan \left (x\right )^{5} + 185401 \, \tan \left (x\right )^{3} - 18413 \, \tan \left (x\right )}{972 \, {\left (3 \, \tan \left (x\right )^{4} - 4 \, \tan \left (x\right )^{2} + 1\right )}^{3}} + \frac {103}{8} \, \log \left ({\left | \tan \left (x\right ) + 1 \right |}\right ) - \frac {103}{8} \, \log \left ({\left | \tan \left (x\right ) - 1 \right |}\right ) + \frac {43}{3888} \, \tan \left (x\right ) \] Input:

integrate(1/(cos(x)+cos(5*x))^4,x, algorithm="giac")
 

Output:

1/3888*tan(x)^3 + 1808/243*sqrt(3)*log(abs(-2*sqrt(3) + 6*tan(x))/abs(2*sq 
rt(3) + 6*tan(x))) - 1/972*(287289*tan(x)^11 - 964165*tan(x)^9 + 1212446*t 
an(x)^7 - 699966*tan(x)^5 + 185401*tan(x)^3 - 18413*tan(x))/(3*tan(x)^4 - 
4*tan(x)^2 + 1)^3 + 103/8*log(abs(tan(x) + 1)) - 103/8*log(abs(tan(x) - 1) 
) + 43/3888*tan(x)
 

Mupad [B] (verification not implemented)

Time = 22.62 (sec) , antiderivative size = 345, normalized size of antiderivative = 2.17 \[ \int \frac {1}{(\cos (x)+\cos (5 x))^4} \, dx =\text {Too large to display} \] Input:

int(1/(cos(5*x) + cos(x))^4,x)
                                                                                    
                                                                                    
 

Output:

(27*sin(x) + 2703132*cos(x)^3*atanh(sin(x)/cos(x)) - 27031320*cos(x)^5*ata 
nh(sin(x)/cos(x)) + 111729456*cos(x)^7*atanh(sin(x)/cos(x)) - 244283040*co 
s(x)^9*atanh(sin(x)/cos(x)) + 297945216*cos(x)^11*atanh(sin(x)/cos(x)) - 1 
92222720*cos(x)^13*atanh(sin(x)/cos(x)) + 51259392*cos(x)^15*atanh(sin(x)/ 
cos(x)) + 864*cos(x)^2*sin(x) - 1159380*cos(x)^4*sin(x) + 9646872*cos(x)^6 
*sin(x) - 31867488*cos(x)^8*sin(x) + 52103808*cos(x)^10*sin(x) - 42143232* 
cos(x)^12*sin(x) + 13492224*cos(x)^14*sin(x) - 1562112*3^(1/2)*atanh((3^(1 
/2)*sin(x))/cos(x))*cos(x)^3 + 15621120*3^(1/2)*atanh((3^(1/2)*sin(x))/cos 
(x))*cos(x)^5 - 64567296*3^(1/2)*atanh((3^(1/2)*sin(x))/cos(x))*cos(x)^7 + 
 141168640*3^(1/2)*atanh((3^(1/2)*sin(x))/cos(x))*cos(x)^9 - 172179456*3^( 
1/2)*atanh((3^(1/2)*sin(x))/cos(x))*cos(x)^11 + 111083520*3^(1/2)*atanh((3 
^(1/2)*sin(x))/cos(x))*cos(x)^13 - 29622272*3^(1/2)*atanh((3^(1/2)*sin(x)) 
/cos(x))*cos(x)^15)/(104976*cos(x)^3 - 1049760*cos(x)^5 + 4339008*cos(x)^7 
 - 9486720*cos(x)^9 + 11570688*cos(x)^11 - 7464960*cos(x)^13 + 1990656*cos 
(x)^15)
 

Reduce [F]

\[ \int \frac {1}{(\cos (x)+\cos (5 x))^4} \, dx=\int \frac {1}{\cos \left (5 x \right )^{4}+4 \cos \left (5 x \right )^{3} \cos \left (x \right )+6 \cos \left (5 x \right )^{2} \cos \left (x \right )^{2}+4 \cos \left (5 x \right ) \cos \left (x \right )^{3}+\cos \left (x \right )^{4}}d x \] Input:

int(1/(cos(x)+cos(5*x))^4,x)
 

Output:

int(1/(cos(5*x)**4 + 4*cos(5*x)**3*cos(x) + 6*cos(5*x)**2*cos(x)**2 + 4*co 
s(5*x)*cos(x)**3 + cos(x)**4),x)