\(\int \frac {\cos ^5(c+d x)}{(a+b \sin (c+d x))^2} \, dx\) [435]

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

Optimal result

Integrand size = 21, antiderivative size = 120 \[ \int \frac {\cos ^5(c+d x)}{(a+b \sin (c+d x))^2} \, dx=-\frac {4 a \left (a^2-b^2\right ) \log (a+b \sin (c+d x))}{b^5 d}+\frac {\left (3 a^2-2 b^2\right ) \sin (c+d x)}{b^4 d}-\frac {a \sin ^2(c+d x)}{b^3 d}+\frac {\sin ^3(c+d x)}{3 b^2 d}-\frac {\left (a^2-b^2\right )^2}{b^5 d (a+b \sin (c+d x))} \] Output:

-4*a*(a^2-b^2)*ln(a+b*sin(d*x+c))/b^5/d+(3*a^2-2*b^2)*sin(d*x+c)/b^4/d-a*s 
in(d*x+c)^2/b^3/d+1/3*sin(d*x+c)^3/b^2/d-(a^2-b^2)^2/b^5/d/(a+b*sin(d*x+c) 
)
 

Mathematica [A] (verified)

Time = 0.73 (sec) , antiderivative size = 127, normalized size of antiderivative = 1.06 \[ \int \frac {\cos ^5(c+d x)}{(a+b \sin (c+d x))^2} \, dx=\frac {\left (8 a^2 b-4 b^3\right ) \sin (c+d x)-2 a b^2 \sin ^2(c+d x)+\frac {b^4 \cos ^4(c+d x)-4 \left (a^2-b^2\right ) \left (a^2-b^2+3 a^2 \log (a+b \sin (c+d x))+3 a b \log (a+b \sin (c+d x)) \sin (c+d x)\right )}{a+b \sin (c+d x)}}{3 b^5 d} \] Input:

Integrate[Cos[c + d*x]^5/(a + b*Sin[c + d*x])^2,x]
 

Output:

((8*a^2*b - 4*b^3)*Sin[c + d*x] - 2*a*b^2*Sin[c + d*x]^2 + (b^4*Cos[c + d* 
x]^4 - 4*(a^2 - b^2)*(a^2 - b^2 + 3*a^2*Log[a + b*Sin[c + d*x]] + 3*a*b*Lo 
g[a + b*Sin[c + d*x]]*Sin[c + d*x]))/(a + b*Sin[c + d*x]))/(3*b^5*d)
 

Rubi [A] (verified)

Time = 0.31 (sec) , antiderivative size = 104, normalized size of antiderivative = 0.87, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.190, Rules used = {3042, 3147, 476, 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 {\cos ^5(c+d x)}{(a+b \sin (c+d x))^2} \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {\cos (c+d x)^5}{(a+b \sin (c+d x))^2}dx\)

\(\Big \downarrow \) 3147

\(\displaystyle \frac {\int \frac {\left (b^2-b^2 \sin ^2(c+d x)\right )^2}{(a+b \sin (c+d x))^2}d(b \sin (c+d x))}{b^5 d}\)

\(\Big \downarrow \) 476

\(\displaystyle \frac {\int \left (3 \left (1-\frac {2 b^2}{3 a^2}\right ) a^2-2 b \sin (c+d x) a+b^2 \sin ^2(c+d x)-\frac {4 \left (a^3-a b^2\right )}{a+b \sin (c+d x)}+\frac {\left (a^2-b^2\right )^2}{(a+b \sin (c+d x))^2}\right )d(b \sin (c+d x))}{b^5 d}\)

\(\Big \downarrow \) 2009

\(\displaystyle \frac {b \left (3 a^2-2 b^2\right ) \sin (c+d x)-\frac {\left (a^2-b^2\right )^2}{a+b \sin (c+d x)}-4 a \left (a^2-b^2\right ) \log (a+b \sin (c+d x))-a b^2 \sin ^2(c+d x)+\frac {1}{3} b^3 \sin ^3(c+d x)}{b^5 d}\)

Input:

Int[Cos[c + d*x]^5/(a + b*Sin[c + d*x])^2,x]
 

Output:

(-4*a*(a^2 - b^2)*Log[a + b*Sin[c + d*x]] + b*(3*a^2 - 2*b^2)*Sin[c + d*x] 
 - a*b^2*Sin[c + d*x]^2 + (b^3*Sin[c + d*x]^3)/3 - (a^2 - b^2)^2/(a + b*Si 
n[c + d*x]))/(b^5*d)
 

Defintions of rubi rules used

rule 476
Int[((c_) + (d_.)*(x_))^(n_)*((a_) + (b_.)*(x_)^2)^(p_.), x_Symbol] :> Int[ 
ExpandIntegrand[(c + d*x)^n*(a + b*x^2)^p, x], x] /; FreeQ[{a, b, c, d, n}, 
 x] && IGtQ[p, 0]
 

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

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

rule 3147
Int[cos[(e_.) + (f_.)*(x_)]^(p_.)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m 
_.), x_Symbol] :> Simp[1/(b^p*f)   Subst[Int[(a + x)^m*(b^2 - x^2)^((p - 1) 
/2), x], x, b*Sin[e + f*x]], x] /; FreeQ[{a, b, e, f, m}, x] && IntegerQ[(p 
 - 1)/2] && NeQ[a^2 - b^2, 0]
 
Maple [A] (verified)

Time = 1.04 (sec) , antiderivative size = 116, normalized size of antiderivative = 0.97

method result size
derivativedivides \(\frac {\frac {\frac {\sin \left (d x +c \right )^{3} b^{2}}{3}-a b \sin \left (d x +c \right )^{2}+3 a^{2} \sin \left (d x +c \right )-2 \sin \left (d x +c \right ) b^{2}}{b^{4}}-\frac {a^{4}-2 b^{2} a^{2}+b^{4}}{b^{5} \left (a +b \sin \left (d x +c \right )\right )}-\frac {4 a \left (a^{2}-b^{2}\right ) \ln \left (a +b \sin \left (d x +c \right )\right )}{b^{5}}}{d}\) \(116\)
default \(\frac {\frac {\frac {\sin \left (d x +c \right )^{3} b^{2}}{3}-a b \sin \left (d x +c \right )^{2}+3 a^{2} \sin \left (d x +c \right )-2 \sin \left (d x +c \right ) b^{2}}{b^{4}}-\frac {a^{4}-2 b^{2} a^{2}+b^{4}}{b^{5} \left (a +b \sin \left (d x +c \right )\right )}-\frac {4 a \left (a^{2}-b^{2}\right ) \ln \left (a +b \sin \left (d x +c \right )\right )}{b^{5}}}{d}\) \(116\)
parallelrisch \(\frac {-96 a \left (a -b \right ) \left (a +b \right ) \left (a +b \sin \left (d x +c \right )\right ) \ln \left (2 b \tan \left (\frac {d x}{2}+\frac {c}{2}\right )+a \sec \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}\right )+96 a \left (a -b \right ) \left (a +b \right ) \left (a +b \sin \left (d x +c \right )\right ) \ln \left (\sec \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}\right )+\left (-24 b^{2} a^{2}+20 b^{4}\right ) \cos \left (2 d x +2 c \right )-12 a \,b^{3} \sin \left (d x +c \right )+4 a \sin \left (3 d x +3 c \right ) b^{3}+\cos \left (4 d x +4 c \right ) b^{4}-96 a^{4}+120 b^{2} a^{2}-45 b^{4}}{24 b^{5} d \left (a +b \sin \left (d x +c \right )\right )}\) \(185\)
risch \(-\frac {7 i {\mathrm e}^{-i \left (d x +c \right )}}{8 b^{2} d}+\frac {7 i {\mathrm e}^{i \left (d x +c \right )}}{8 b^{2} d}+\frac {a \,{\mathrm e}^{2 i \left (d x +c \right )}}{4 b^{3} d}+\frac {4 i a^{3} x}{b^{5}}-\frac {4 i a x}{b^{3}}+\frac {3 i {\mathrm e}^{-i \left (d x +c \right )} a^{2}}{2 b^{4} d}-\frac {3 i {\mathrm e}^{i \left (d x +c \right )} a^{2}}{2 b^{4} d}+\frac {a \,{\mathrm e}^{-2 i \left (d x +c \right )}}{4 b^{3} d}-\frac {8 i a c}{b^{3} d}+\frac {8 i a^{3} c}{b^{5} d}-\frac {2 \left (a^{4}-2 b^{2} a^{2}+b^{4}\right ) {\mathrm e}^{i \left (d x +c \right )}}{b^{5} d \left (-i {\mathrm e}^{2 i \left (d x +c \right )} b +i b +2 a \,{\mathrm e}^{i \left (d x +c \right )}\right )}-\frac {4 a^{3} \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}+\frac {2 i a \,{\mathrm e}^{i \left (d x +c \right )}}{b}-1\right )}{b^{5} d}+\frac {4 a \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}+\frac {2 i a \,{\mathrm e}^{i \left (d x +c \right )}}{b}-1\right )}{b^{3} d}-\frac {\sin \left (3 d x +3 c \right )}{12 b^{2} d}\) \(315\)
norman \(\frac {\frac {4 \left (36 a^{2}-28 b^{2}\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{6}}{3 b^{3} d}+\frac {\left (96 a^{2}-80 b^{2}\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{4}}{3 b^{3} d}+\frac {\left (96 a^{2}-80 b^{2}\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{8}}{3 b^{3} d}+\frac {2 \left (4 a^{2}-4 b^{2}\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}}{b^{3} d}+\frac {2 \left (4 a^{2}-4 b^{2}\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{10}}{b^{3} d}+\frac {4 \left (20 a^{4}-24 b^{2} a^{2}+5 b^{4}\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{5}}{a \,b^{4} d}+\frac {4 \left (20 a^{4}-24 b^{2} a^{2}+5 b^{4}\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{7}}{a \,b^{4} d}+\frac {2 \left (60 a^{4}-68 b^{2} a^{2}+15 b^{4}\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{3}}{3 a \,b^{4} d}+\frac {2 \left (60 a^{4}-68 b^{2} a^{2}+15 b^{4}\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{9}}{3 a \,b^{4} d}+\frac {2 \left (4 a^{4}-4 b^{2} a^{2}+b^{4}\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{b^{4} a d}+\frac {2 \left (4 a^{4}-4 b^{2} a^{2}+b^{4}\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{11}}{b^{4} a d}}{\left (1+\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}\right )^{5} \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2} a +2 b \tan \left (\frac {d x}{2}+\frac {c}{2}\right )+a \right )}+\frac {4 a \left (a^{2}-b^{2}\right ) \ln \left (1+\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}\right )}{b^{5} d}-\frac {4 a \left (a^{2}-b^{2}\right ) \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2} a +2 b \tan \left (\frac {d x}{2}+\frac {c}{2}\right )+a \right )}{b^{5} d}\) \(516\)

Input:

int(cos(d*x+c)^5/(a+b*sin(d*x+c))^2,x,method=_RETURNVERBOSE)
 

Output:

1/d*(1/b^4*(1/3*sin(d*x+c)^3*b^2-a*b*sin(d*x+c)^2+3*a^2*sin(d*x+c)-2*sin(d 
*x+c)*b^2)-1/b^5*(a^4-2*a^2*b^2+b^4)/(a+b*sin(d*x+c))-4*a/b^5*(a^2-b^2)*ln 
(a+b*sin(d*x+c)))
 

Fricas [A] (verification not implemented)

Time = 0.12 (sec) , antiderivative size = 156, normalized size of antiderivative = 1.30 \[ \int \frac {\cos ^5(c+d x)}{(a+b \sin (c+d x))^2} \, dx=\frac {2 \, b^{4} \cos \left (d x + c\right )^{4} - 6 \, a^{4} + 27 \, a^{2} b^{2} - 16 \, b^{4} - 4 \, {\left (3 \, a^{2} b^{2} - 2 \, b^{4}\right )} \cos \left (d x + c\right )^{2} - 24 \, {\left (a^{4} - a^{2} b^{2} + {\left (a^{3} b - a b^{3}\right )} \sin \left (d x + c\right )\right )} \log \left (b \sin \left (d x + c\right ) + a\right ) + {\left (4 \, a b^{3} \cos \left (d x + c\right )^{2} + 18 \, a^{3} b - 13 \, a b^{3}\right )} \sin \left (d x + c\right )}{6 \, {\left (b^{6} d \sin \left (d x + c\right ) + a b^{5} d\right )}} \] Input:

integrate(cos(d*x+c)^5/(a+b*sin(d*x+c))^2,x, algorithm="fricas")
 

Output:

1/6*(2*b^4*cos(d*x + c)^4 - 6*a^4 + 27*a^2*b^2 - 16*b^4 - 4*(3*a^2*b^2 - 2 
*b^4)*cos(d*x + c)^2 - 24*(a^4 - a^2*b^2 + (a^3*b - a*b^3)*sin(d*x + c))*l 
og(b*sin(d*x + c) + a) + (4*a*b^3*cos(d*x + c)^2 + 18*a^3*b - 13*a*b^3)*si 
n(d*x + c))/(b^6*d*sin(d*x + c) + a*b^5*d)
 

Sympy [F(-1)]

Timed out. \[ \int \frac {\cos ^5(c+d x)}{(a+b \sin (c+d x))^2} \, dx=\text {Timed out} \] Input:

integrate(cos(d*x+c)**5/(a+b*sin(d*x+c))**2,x)
 

Output:

Timed out
 

Maxima [A] (verification not implemented)

Time = 0.03 (sec) , antiderivative size = 116, normalized size of antiderivative = 0.97 \[ \int \frac {\cos ^5(c+d x)}{(a+b \sin (c+d x))^2} \, dx=-\frac {\frac {3 \, {\left (a^{4} - 2 \, a^{2} b^{2} + b^{4}\right )}}{b^{6} \sin \left (d x + c\right ) + a b^{5}} - \frac {b^{2} \sin \left (d x + c\right )^{3} - 3 \, a b \sin \left (d x + c\right )^{2} + 3 \, {\left (3 \, a^{2} - 2 \, b^{2}\right )} \sin \left (d x + c\right )}{b^{4}} + \frac {12 \, {\left (a^{3} - a b^{2}\right )} \log \left (b \sin \left (d x + c\right ) + a\right )}{b^{5}}}{3 \, d} \] Input:

integrate(cos(d*x+c)^5/(a+b*sin(d*x+c))^2,x, algorithm="maxima")
 

Output:

-1/3*(3*(a^4 - 2*a^2*b^2 + b^4)/(b^6*sin(d*x + c) + a*b^5) - (b^2*sin(d*x 
+ c)^3 - 3*a*b*sin(d*x + c)^2 + 3*(3*a^2 - 2*b^2)*sin(d*x + c))/b^4 + 12*( 
a^3 - a*b^2)*log(b*sin(d*x + c) + a)/b^5)/d
 

Giac [A] (verification not implemented)

Time = 0.13 (sec) , antiderivative size = 138, normalized size of antiderivative = 1.15 \[ \int \frac {\cos ^5(c+d x)}{(a+b \sin (c+d x))^2} \, dx=-\frac {4 \, {\left (a^{3} - a b^{2}\right )} \log \left ({\left | b \sin \left (d x + c\right ) + a \right |}\right )}{b^{5} d} - \frac {a^{4} - 2 \, a^{2} b^{2} + b^{4}}{{\left (b \sin \left (d x + c\right ) + a\right )} b^{5} d} + \frac {b^{4} d^{2} \sin \left (d x + c\right )^{3} - 3 \, a b^{3} d^{2} \sin \left (d x + c\right )^{2} + 9 \, a^{2} b^{2} d^{2} \sin \left (d x + c\right ) - 6 \, b^{4} d^{2} \sin \left (d x + c\right )}{3 \, b^{6} d^{3}} \] Input:

integrate(cos(d*x+c)^5/(a+b*sin(d*x+c))^2,x, algorithm="giac")
 

Output:

-4*(a^3 - a*b^2)*log(abs(b*sin(d*x + c) + a))/(b^5*d) - (a^4 - 2*a^2*b^2 + 
 b^4)/((b*sin(d*x + c) + a)*b^5*d) + 1/3*(b^4*d^2*sin(d*x + c)^3 - 3*a*b^3 
*d^2*sin(d*x + c)^2 + 9*a^2*b^2*d^2*sin(d*x + c) - 6*b^4*d^2*sin(d*x + c)) 
/(b^6*d^3)
 

Mupad [B] (verification not implemented)

Time = 0.05 (sec) , antiderivative size = 118, normalized size of antiderivative = 0.98 \[ \int \frac {\cos ^5(c+d x)}{(a+b \sin (c+d x))^2} \, dx=-\frac {\sin \left (c+d\,x\right )\,\left (\frac {2}{b^2}-\frac {3\,a^2}{b^4}\right )-\frac {{\sin \left (c+d\,x\right )}^3}{3\,b^2}+\frac {a\,{\sin \left (c+d\,x\right )}^2}{b^3}-\frac {\ln \left (a+b\,\sin \left (c+d\,x\right )\right )\,\left (4\,a\,b^2-4\,a^3\right )}{b^5}+\frac {a^4-2\,a^2\,b^2+b^4}{b\,\left (\sin \left (c+d\,x\right )\,b^5+a\,b^4\right )}}{d} \] Input:

int(cos(c + d*x)^5/(a + b*sin(c + d*x))^2,x)
 

Output:

-(sin(c + d*x)*(2/b^2 - (3*a^2)/b^4) - sin(c + d*x)^3/(3*b^2) + (a*sin(c + 
 d*x)^2)/b^3 - (log(a + b*sin(c + d*x))*(4*a*b^2 - 4*a^3))/b^5 + (a^4 + b^ 
4 - 2*a^2*b^2)/(b*(a*b^4 + b^5*sin(c + d*x))))/d
 

Reduce [B] (verification not implemented)

Time = 0.18 (sec) , antiderivative size = 336, normalized size of antiderivative = 2.80 \[ \int \frac {\cos ^5(c+d x)}{(a+b \sin (c+d x))^2} \, dx=\frac {12 \,\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}+1\right ) \sin \left (d x +c \right ) a^{3} b -12 \,\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}+1\right ) \sin \left (d x +c \right ) a \,b^{3}+12 \,\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}+1\right ) a^{4}-12 \,\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}+1\right ) a^{2} b^{2}-12 \,\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2} a +2 \tan \left (\frac {d x}{2}+\frac {c}{2}\right ) b +a \right ) \sin \left (d x +c \right ) a^{3} b +12 \,\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2} a +2 \tan \left (\frac {d x}{2}+\frac {c}{2}\right ) b +a \right ) \sin \left (d x +c \right ) a \,b^{3}-12 \,\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2} a +2 \tan \left (\frac {d x}{2}+\frac {c}{2}\right ) b +a \right ) a^{4}+12 \,\mathrm {log}\left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2} a +2 \tan \left (\frac {d x}{2}+\frac {c}{2}\right ) b +a \right ) a^{2} b^{2}+\sin \left (d x +c \right )^{4} b^{4}-2 \sin \left (d x +c \right )^{3} a \,b^{3}+6 \sin \left (d x +c \right )^{2} a^{2} b^{2}-6 \sin \left (d x +c \right )^{2} b^{4}-12 a^{4}+12 a^{2} b^{2}-3 b^{4}}{3 b^{5} d \left (\sin \left (d x +c \right ) b +a \right )} \] Input:

int(cos(d*x+c)^5/(a+b*sin(d*x+c))^2,x)
 

Output:

(12*log(tan((c + d*x)/2)**2 + 1)*sin(c + d*x)*a**3*b - 12*log(tan((c + d*x 
)/2)**2 + 1)*sin(c + d*x)*a*b**3 + 12*log(tan((c + d*x)/2)**2 + 1)*a**4 - 
12*log(tan((c + d*x)/2)**2 + 1)*a**2*b**2 - 12*log(tan((c + d*x)/2)**2*a + 
 2*tan((c + d*x)/2)*b + a)*sin(c + d*x)*a**3*b + 12*log(tan((c + d*x)/2)** 
2*a + 2*tan((c + d*x)/2)*b + a)*sin(c + d*x)*a*b**3 - 12*log(tan((c + d*x) 
/2)**2*a + 2*tan((c + d*x)/2)*b + a)*a**4 + 12*log(tan((c + d*x)/2)**2*a + 
 2*tan((c + d*x)/2)*b + a)*a**2*b**2 + sin(c + d*x)**4*b**4 - 2*sin(c + d* 
x)**3*a*b**3 + 6*sin(c + d*x)**2*a**2*b**2 - 6*sin(c + d*x)**2*b**4 - 12*a 
**4 + 12*a**2*b**2 - 3*b**4)/(3*b**5*d*(sin(c + d*x)*b + a))