\(\int \frac {\cos ^3(c+d x)}{(a+b \tan ^2(c+d x))^2} \, dx\) [469]

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

Optimal result

Integrand size = 23, antiderivative size = 143 \[ \int \frac {\cos ^3(c+d x)}{\left (a+b \tan ^2(c+d x)\right )^2} \, dx=\frac {(6 a-b) b^2 \text {arctanh}\left (\frac {\sqrt {a-b} \sin (c+d x)}{\sqrt {a}}\right )}{2 a^{3/2} (a-b)^{7/2} d}+\frac {(a-3 b) \sin (c+d x)}{(a-b)^3 d}-\frac {\sin ^3(c+d x)}{3 (a-b)^2 d}-\frac {b^3 \sin (c+d x)}{2 a (a-b)^3 d \left (a-(a-b) \sin ^2(c+d x)\right )} \] Output:

1/2*(6*a-b)*b^2*arctanh((a-b)^(1/2)*sin(d*x+c)/a^(1/2))/a^(3/2)/(a-b)^(7/2 
)/d+(a-3*b)*sin(d*x+c)/(a-b)^3/d-1/3*sin(d*x+c)^3/(a-b)^2/d-1/2*b^3*sin(d* 
x+c)/a/(a-b)^3/d/(a-(a-b)*sin(d*x+c)^2)
 

Mathematica [A] (verified)

Time = 0.97 (sec) , antiderivative size = 147, normalized size of antiderivative = 1.03 \[ \int \frac {\cos ^3(c+d x)}{\left (a+b \tan ^2(c+d x)\right )^2} \, dx=\frac {\frac {3 b^2 (-6 a+b) \left (\log \left (\sqrt {a}-\sqrt {a-b} \sin (c+d x)\right )-\log \left (\sqrt {a}+\sqrt {a-b} \sin (c+d x)\right )\right )}{a^{3/2} (a-b)^{7/2}}+\frac {3 \left (3 a-11 b-\frac {4 b^3}{a (a+b+(a-b) \cos (2 (c+d x)))}\right ) \sin (c+d x)}{(a-b)^3}+\frac {\sin (3 (c+d x))}{(a-b)^2}}{12 d} \] Input:

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

Output:

((3*b^2*(-6*a + b)*(Log[Sqrt[a] - Sqrt[a - b]*Sin[c + d*x]] - Log[Sqrt[a] 
+ Sqrt[a - b]*Sin[c + d*x]]))/(a^(3/2)*(a - b)^(7/2)) + (3*(3*a - 11*b - ( 
4*b^3)/(a*(a + b + (a - b)*Cos[2*(c + d*x)])))*Sin[c + d*x])/(a - b)^3 + S 
in[3*(c + d*x)]/(a - b)^2)/(12*d)
 

Rubi [A] (verified)

Time = 0.37 (sec) , antiderivative size = 135, normalized size of antiderivative = 0.94, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.174, Rules used = {3042, 4159, 300, 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 ^3(c+d x)}{\left (a+b \tan ^2(c+d x)\right )^2} \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {1}{\sec (c+d x)^3 \left (a+b \tan (c+d x)^2\right )^2}dx\)

\(\Big \downarrow \) 4159

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

\(\Big \downarrow \) 300

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

\(\Big \downarrow \) 2009

\(\displaystyle \frac {\frac {b^2 (6 a-b) \text {arctanh}\left (\frac {\sqrt {a-b} \sin (c+d x)}{\sqrt {a}}\right )}{2 a^{3/2} (a-b)^{7/2}}-\frac {b^3 \sin (c+d x)}{2 a (a-b)^3 \left (a-(a-b) \sin ^2(c+d x)\right )}-\frac {\sin ^3(c+d x)}{3 (a-b)^2}+\frac {(a-3 b) \sin (c+d x)}{(a-b)^3}}{d}\)

Input:

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

Output:

(((6*a - b)*b^2*ArcTanh[(Sqrt[a - b]*Sin[c + d*x])/Sqrt[a]])/(2*a^(3/2)*(a 
 - b)^(7/2)) + ((a - 3*b)*Sin[c + d*x])/(a - b)^3 - Sin[c + d*x]^3/(3*(a - 
 b)^2) - (b^3*Sin[c + d*x])/(2*a*(a - b)^3*(a - (a - b)*Sin[c + d*x]^2)))/ 
d
 

Defintions of rubi rules used

rule 300
Int[((a_) + (b_.)*(x_)^2)^(p_)*((c_) + (d_.)*(x_)^2)^(q_), x_Symbol] :> Int 
[PolynomialDivide[(a + b*x^2)^p, (c + d*x^2)^(-q), x], x] /; FreeQ[{a, b, c 
, d}, x] && NeQ[b*c - a*d, 0] && IGtQ[p, 0] && ILtQ[q, 0] && GeQ[p, -q]
 

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 4159
Int[sec[(e_.) + (f_.)*(x_)]^(m_.)*((a_) + (b_.)*tan[(e_.) + (f_.)*(x_)]^(n_ 
))^(p_.), x_Symbol] :> With[{ff = FreeFactors[Sin[e + f*x], x]}, Simp[ff/f 
  Subst[Int[ExpandToSum[b*(ff*x)^n + a*(1 - ff^2*x^2)^(n/2), x]^p/(1 - ff^2 
*x^2)^((m + n*p + 1)/2), x], x, Sin[e + f*x]/ff], x]] /; FreeQ[{a, b, e, f} 
, x] && IntegerQ[(m - 1)/2] && IntegerQ[n/2] && IntegerQ[p]
 
Maple [A] (verified)

Time = 16.76 (sec) , antiderivative size = 164, normalized size of antiderivative = 1.15

method result size
derivativedivides \(\frac {-\frac {\frac {a \sin \left (d x +c \right )^{3}}{3}-\frac {b \sin \left (d x +c \right )^{3}}{3}-\sin \left (d x +c \right ) a +3 b \sin \left (d x +c \right )}{\left (a^{2}-2 a b +b^{2}\right ) \left (a -b \right )}-\frac {b^{2} \left (-\frac {b \sin \left (d x +c \right )}{2 a \left (a \sin \left (d x +c \right )^{2}-b \sin \left (d x +c \right )^{2}-a \right )}-\frac {\left (6 a -b \right ) \operatorname {arctanh}\left (\frac {\left (a -b \right ) \sin \left (d x +c \right )}{\sqrt {a \left (a -b \right )}}\right )}{2 a \sqrt {a \left (a -b \right )}}\right )}{\left (a -b \right )^{3}}}{d}\) \(164\)
default \(\frac {-\frac {\frac {a \sin \left (d x +c \right )^{3}}{3}-\frac {b \sin \left (d x +c \right )^{3}}{3}-\sin \left (d x +c \right ) a +3 b \sin \left (d x +c \right )}{\left (a^{2}-2 a b +b^{2}\right ) \left (a -b \right )}-\frac {b^{2} \left (-\frac {b \sin \left (d x +c \right )}{2 a \left (a \sin \left (d x +c \right )^{2}-b \sin \left (d x +c \right )^{2}-a \right )}-\frac {\left (6 a -b \right ) \operatorname {arctanh}\left (\frac {\left (a -b \right ) \sin \left (d x +c \right )}{\sqrt {a \left (a -b \right )}}\right )}{2 a \sqrt {a \left (a -b \right )}}\right )}{\left (a -b \right )^{3}}}{d}\) \(164\)
risch \(-\frac {i {\mathrm e}^{3 i \left (d x +c \right )}}{24 d \left (a^{2}-2 a b +b^{2}\right )}-\frac {3 i {\mathrm e}^{i \left (d x +c \right )} a}{8 \left (a^{2}-2 a b +b^{2}\right ) \left (a -b \right ) d}+\frac {11 i {\mathrm e}^{i \left (d x +c \right )} b}{8 \left (a^{2}-2 a b +b^{2}\right ) \left (a -b \right ) d}+\frac {3 i {\mathrm e}^{-i \left (d x +c \right )} a}{8 d \left (a^{3}-3 a^{2} b +3 a \,b^{2}-b^{3}\right )}-\frac {11 i {\mathrm e}^{-i \left (d x +c \right )} b}{8 d \left (a^{3}-3 a^{2} b +3 a \,b^{2}-b^{3}\right )}+\frac {i {\mathrm e}^{-3 i \left (d x +c \right )}}{24 d \left (a^{2}-2 a b +b^{2}\right )}+\frac {i b^{3} \left ({\mathrm e}^{3 i \left (d x +c \right )}-{\mathrm e}^{i \left (d x +c \right )}\right )}{d \left (-a +b \right ) a \left (a^{2}-2 a b +b^{2}\right ) \left (-a \,{\mathrm e}^{4 i \left (d x +c \right )}+b \,{\mathrm e}^{4 i \left (d x +c \right )}-2 a \,{\mathrm e}^{2 i \left (d x +c \right )}-2 b \,{\mathrm e}^{2 i \left (d x +c \right )}-a +b \right )}+\frac {3 b^{2} \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}+\frac {2 i a \,{\mathrm e}^{i \left (d x +c \right )}}{\sqrt {a^{2}-a b}}-1\right )}{2 \sqrt {a^{2}-a b}\, \left (a -b \right )^{3} d}-\frac {b^{3} \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}+\frac {2 i a \,{\mathrm e}^{i \left (d x +c \right )}}{\sqrt {a^{2}-a b}}-1\right )}{4 \sqrt {a^{2}-a b}\, \left (a -b \right )^{3} d a}-\frac {3 b^{2} \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}-\frac {2 i a \,{\mathrm e}^{i \left (d x +c \right )}}{\sqrt {a^{2}-a b}}-1\right )}{2 \sqrt {a^{2}-a b}\, \left (a -b \right )^{3} d}+\frac {b^{3} \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}-\frac {2 i a \,{\mathrm e}^{i \left (d x +c \right )}}{\sqrt {a^{2}-a b}}-1\right )}{4 \sqrt {a^{2}-a b}\, \left (a -b \right )^{3} d a}\) \(561\)

Input:

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

Output:

1/d*(-1/(a^2-2*a*b+b^2)/(a-b)*(1/3*a*sin(d*x+c)^3-1/3*b*sin(d*x+c)^3-sin(d 
*x+c)*a+3*b*sin(d*x+c))-b^2/(a-b)^3*(-1/2/a*b*sin(d*x+c)/(a*sin(d*x+c)^2-b 
*sin(d*x+c)^2-a)-1/2*(6*a-b)/a/(a*(a-b))^(1/2)*arctanh((a-b)*sin(d*x+c)/(a 
*(a-b))^(1/2))))
 

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 282 vs. \(2 (130) = 260\).

Time = 0.16 (sec) , antiderivative size = 600, normalized size of antiderivative = 4.20 \[ \int \frac {\cos ^3(c+d x)}{\left (a+b \tan ^2(c+d x)\right )^2} \, dx=\left [\frac {3 \, {\left (6 \, a b^{3} - b^{4} + {\left (6 \, a^{2} b^{2} - 7 \, a b^{3} + b^{4}\right )} \cos \left (d x + c\right )^{2}\right )} \sqrt {a^{2} - a b} \log \left (-\frac {{\left (a - b\right )} \cos \left (d x + c\right )^{2} - 2 \, \sqrt {a^{2} - a b} \sin \left (d x + c\right ) - 2 \, a + b}{{\left (a - b\right )} \cos \left (d x + c\right )^{2} + b}\right ) + 2 \, {\left (4 \, a^{4} b - 20 \, a^{3} b^{2} + 13 \, a^{2} b^{3} + 3 \, a b^{4} + 2 \, {\left (a^{5} - 3 \, a^{4} b + 3 \, a^{3} b^{2} - a^{2} b^{3}\right )} \cos \left (d x + c\right )^{4} + 2 \, {\left (2 \, a^{5} - 11 \, a^{4} b + 16 \, a^{3} b^{2} - 7 \, a^{2} b^{3}\right )} \cos \left (d x + c\right )^{2}\right )} \sin \left (d x + c\right )}{12 \, {\left ({\left (a^{7} - 5 \, a^{6} b + 10 \, a^{5} b^{2} - 10 \, a^{4} b^{3} + 5 \, a^{3} b^{4} - a^{2} b^{5}\right )} d \cos \left (d x + c\right )^{2} + {\left (a^{6} b - 4 \, a^{5} b^{2} + 6 \, a^{4} b^{3} - 4 \, a^{3} b^{4} + a^{2} b^{5}\right )} d\right )}}, -\frac {3 \, {\left (6 \, a b^{3} - b^{4} + {\left (6 \, a^{2} b^{2} - 7 \, a b^{3} + b^{4}\right )} \cos \left (d x + c\right )^{2}\right )} \sqrt {-a^{2} + a b} \arctan \left (\frac {\sqrt {-a^{2} + a b} \sin \left (d x + c\right )}{a}\right ) - {\left (4 \, a^{4} b - 20 \, a^{3} b^{2} + 13 \, a^{2} b^{3} + 3 \, a b^{4} + 2 \, {\left (a^{5} - 3 \, a^{4} b + 3 \, a^{3} b^{2} - a^{2} b^{3}\right )} \cos \left (d x + c\right )^{4} + 2 \, {\left (2 \, a^{5} - 11 \, a^{4} b + 16 \, a^{3} b^{2} - 7 \, a^{2} b^{3}\right )} \cos \left (d x + c\right )^{2}\right )} \sin \left (d x + c\right )}{6 \, {\left ({\left (a^{7} - 5 \, a^{6} b + 10 \, a^{5} b^{2} - 10 \, a^{4} b^{3} + 5 \, a^{3} b^{4} - a^{2} b^{5}\right )} d \cos \left (d x + c\right )^{2} + {\left (a^{6} b - 4 \, a^{5} b^{2} + 6 \, a^{4} b^{3} - 4 \, a^{3} b^{4} + a^{2} b^{5}\right )} d\right )}}\right ] \] Input:

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

Output:

[1/12*(3*(6*a*b^3 - b^4 + (6*a^2*b^2 - 7*a*b^3 + b^4)*cos(d*x + c)^2)*sqrt 
(a^2 - a*b)*log(-((a - b)*cos(d*x + c)^2 - 2*sqrt(a^2 - a*b)*sin(d*x + c) 
- 2*a + b)/((a - b)*cos(d*x + c)^2 + b)) + 2*(4*a^4*b - 20*a^3*b^2 + 13*a^ 
2*b^3 + 3*a*b^4 + 2*(a^5 - 3*a^4*b + 3*a^3*b^2 - a^2*b^3)*cos(d*x + c)^4 + 
 2*(2*a^5 - 11*a^4*b + 16*a^3*b^2 - 7*a^2*b^3)*cos(d*x + c)^2)*sin(d*x + c 
))/((a^7 - 5*a^6*b + 10*a^5*b^2 - 10*a^4*b^3 + 5*a^3*b^4 - a^2*b^5)*d*cos( 
d*x + c)^2 + (a^6*b - 4*a^5*b^2 + 6*a^4*b^3 - 4*a^3*b^4 + a^2*b^5)*d), -1/ 
6*(3*(6*a*b^3 - b^4 + (6*a^2*b^2 - 7*a*b^3 + b^4)*cos(d*x + c)^2)*sqrt(-a^ 
2 + a*b)*arctan(sqrt(-a^2 + a*b)*sin(d*x + c)/a) - (4*a^4*b - 20*a^3*b^2 + 
 13*a^2*b^3 + 3*a*b^4 + 2*(a^5 - 3*a^4*b + 3*a^3*b^2 - a^2*b^3)*cos(d*x + 
c)^4 + 2*(2*a^5 - 11*a^4*b + 16*a^3*b^2 - 7*a^2*b^3)*cos(d*x + c)^2)*sin(d 
*x + c))/((a^7 - 5*a^6*b + 10*a^5*b^2 - 10*a^4*b^3 + 5*a^3*b^4 - a^2*b^5)* 
d*cos(d*x + c)^2 + (a^6*b - 4*a^5*b^2 + 6*a^4*b^3 - 4*a^3*b^4 + a^2*b^5)*d 
)]
 

Sympy [F(-1)]

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

integrate(cos(d*x+c)**3/(a+b*tan(d*x+c)**2)**2,x)
 

Output:

Timed out
 

Maxima [F(-2)]

Exception generated. \[ \int \frac {\cos ^3(c+d x)}{\left (a+b \tan ^2(c+d x)\right )^2} \, dx=\text {Exception raised: ValueError} \] Input:

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

Output:

Exception raised: ValueError >> Computation failed since Maxima requested 
additional constraints; using the 'assume' command before evaluation *may* 
 help (example of legal syntax is 'assume(b-a>0)', see `assume?` for more 
details)Is
 

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 329 vs. \(2 (130) = 260\).

Time = 0.77 (sec) , antiderivative size = 329, normalized size of antiderivative = 2.30 \[ \int \frac {\cos ^3(c+d x)}{\left (a+b \tan ^2(c+d x)\right )^2} \, dx=\frac {\frac {3 \, b^{3} \sin \left (d x + c\right )}{{\left (a^{4} - 3 \, a^{3} b + 3 \, a^{2} b^{2} - a b^{3}\right )} {\left (a \sin \left (d x + c\right )^{2} - b \sin \left (d x + c\right )^{2} - a\right )}} + \frac {3 \, {\left (6 \, a b^{2} - b^{3}\right )} \arctan \left (-\frac {a \sin \left (d x + c\right ) - b \sin \left (d x + c\right )}{\sqrt {-a^{2} + a b}}\right )}{{\left (a^{4} - 3 \, a^{3} b + 3 \, a^{2} b^{2} - a b^{3}\right )} \sqrt {-a^{2} + a b}} - \frac {2 \, {\left (a^{4} \sin \left (d x + c\right )^{3} - 4 \, a^{3} b \sin \left (d x + c\right )^{3} + 6 \, a^{2} b^{2} \sin \left (d x + c\right )^{3} - 4 \, a b^{3} \sin \left (d x + c\right )^{3} + b^{4} \sin \left (d x + c\right )^{3} - 3 \, a^{4} \sin \left (d x + c\right ) + 18 \, a^{3} b \sin \left (d x + c\right ) - 36 \, a^{2} b^{2} \sin \left (d x + c\right ) + 30 \, a b^{3} \sin \left (d x + c\right ) - 9 \, b^{4} \sin \left (d x + c\right )\right )}}{a^{6} - 6 \, a^{5} b + 15 \, a^{4} b^{2} - 20 \, a^{3} b^{3} + 15 \, a^{2} b^{4} - 6 \, a b^{5} + b^{6}}}{6 \, d} \] Input:

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

Output:

1/6*(3*b^3*sin(d*x + c)/((a^4 - 3*a^3*b + 3*a^2*b^2 - a*b^3)*(a*sin(d*x + 
c)^2 - b*sin(d*x + c)^2 - a)) + 3*(6*a*b^2 - b^3)*arctan(-(a*sin(d*x + c) 
- b*sin(d*x + c))/sqrt(-a^2 + a*b))/((a^4 - 3*a^3*b + 3*a^2*b^2 - a*b^3)*s 
qrt(-a^2 + a*b)) - 2*(a^4*sin(d*x + c)^3 - 4*a^3*b*sin(d*x + c)^3 + 6*a^2* 
b^2*sin(d*x + c)^3 - 4*a*b^3*sin(d*x + c)^3 + b^4*sin(d*x + c)^3 - 3*a^4*s 
in(d*x + c) + 18*a^3*b*sin(d*x + c) - 36*a^2*b^2*sin(d*x + c) + 30*a*b^3*s 
in(d*x + c) - 9*b^4*sin(d*x + c))/(a^6 - 6*a^5*b + 15*a^4*b^2 - 20*a^3*b^3 
 + 15*a^2*b^4 - 6*a*b^5 + b^6))/d
 

Mupad [B] (verification not implemented)

Time = 12.72 (sec) , antiderivative size = 1690, normalized size of antiderivative = 11.82 \[ \int \frac {\cos ^3(c+d x)}{\left (a+b \tan ^2(c+d x)\right )^2} \, dx=\text {Too large to display} \] Input:

int(cos(c + d*x)^3/(a + b*tan(c + d*x)^2)^2,x)
 

Output:

- ((tan(c/2 + (d*x)/2)*(6*a^2*b - 2*a^3 + b^3))/(a*(3*a*b^2 - 3*a^2*b + a^ 
3 - b^3)) + (tan(c/2 + (d*x)/2)^9*(6*a^2*b - 2*a^3 + b^3))/(a*(3*a*b^2 - 3 
*a^2*b + a^3 - b^3)) + (4*tan(c/2 + (d*x)/2)^3*(18*a*b^2 - 8*a^2*b + 2*a^3 
 + 3*b^3))/(3*a*(a - b)*(a^2 - 2*a*b + b^2)) + (4*tan(c/2 + (d*x)/2)^7*(18 
*a*b^2 - 8*a^2*b + 2*a^3 + 3*b^3))/(3*a*(a - b)*(a^2 - 2*a*b + b^2)) + (2* 
tan(c/2 + (d*x)/2)^5*(56*a*b^2 - 18*a^2*b - 2*a^3 + 9*b^3))/(3*a*(a - b)*( 
a^2 - 2*a*b + b^2)))/(d*(a + tan(c/2 + (d*x)/2)^2*(a + 4*b) + tan(c/2 + (d 
*x)/2)^8*(a + 4*b) - tan(c/2 + (d*x)/2)^4*(2*a - 12*b) - tan(c/2 + (d*x)/2 
)^6*(2*a - 12*b) + a*tan(c/2 + (d*x)/2)^10)) - (b^2*atan(((b^2*(tan(c/2 + 
(d*x)/2)*(8*a^3*b^10 - 96*a^4*b^9 + 408*a^5*b^8 - 880*a^6*b^7 + 1080*a^7*b 
^6 - 768*a^8*b^5 + 296*a^9*b^4 - 48*a^10*b^3) - (b^2*(6*a - b)*(tan(c/2 + 
(d*x)/2)^2*(16*a^15 - 176*a^14*b + 32*a^5*b^10 - 304*a^6*b^9 + 1296*a^7*b^ 
8 - 3264*a^8*b^7 + 5376*a^9*b^6 - 6048*a^10*b^5 + 4704*a^11*b^4 - 2496*a^1 
2*b^3 + 864*a^13*b^2) + 144*a^14*b - 16*a^15 + 16*a^6*b^9 - 144*a^7*b^8 + 
576*a^8*b^7 - 1344*a^9*b^6 + 2016*a^10*b^5 - 2016*a^11*b^4 + 1344*a^12*b^3 
 - 576*a^13*b^2))/(4*a^(3/2)*(a - b)^(7/2)))*(6*a - b)*1i)/(4*a^(3/2)*(a - 
 b)^(7/2)) + (b^2*(tan(c/2 + (d*x)/2)*(8*a^3*b^10 - 96*a^4*b^9 + 408*a^5*b 
^8 - 880*a^6*b^7 + 1080*a^7*b^6 - 768*a^8*b^5 + 296*a^9*b^4 - 48*a^10*b^3) 
 + (b^2*(6*a - b)*(tan(c/2 + (d*x)/2)^2*(16*a^15 - 176*a^14*b + 32*a^5*b^1 
0 - 304*a^6*b^9 + 1296*a^7*b^8 - 3264*a^8*b^7 + 5376*a^9*b^6 - 6048*a^1...
 

Reduce [B] (verification not implemented)

Time = 0.30 (sec) , antiderivative size = 855, normalized size of antiderivative = 5.98 \[ \int \frac {\cos ^3(c+d x)}{\left (a+b \tan ^2(c+d x)\right )^2} \, dx =\text {Too large to display} \] Input:

int(cos(d*x+c)^3/(a+b*tan(d*x+c)^2)^2,x)
 

Output:

( - 18*sqrt(a)*sqrt(a - b)*log( - 2*sqrt(a - b)*tan((c + d*x)/2) + sqrt(a) 
*tan((c + d*x)/2)**2 + sqrt(a))*sin(c + d*x)**2*a**2*b**2 + 21*sqrt(a)*sqr 
t(a - b)*log( - 2*sqrt(a - b)*tan((c + d*x)/2) + sqrt(a)*tan((c + d*x)/2)* 
*2 + sqrt(a))*sin(c + d*x)**2*a*b**3 - 3*sqrt(a)*sqrt(a - b)*log( - 2*sqrt 
(a - b)*tan((c + d*x)/2) + sqrt(a)*tan((c + d*x)/2)**2 + sqrt(a))*sin(c + 
d*x)**2*b**4 + 18*sqrt(a)*sqrt(a - b)*log( - 2*sqrt(a - b)*tan((c + d*x)/2 
) + sqrt(a)*tan((c + d*x)/2)**2 + sqrt(a))*a**2*b**2 - 3*sqrt(a)*sqrt(a - 
b)*log( - 2*sqrt(a - b)*tan((c + d*x)/2) + sqrt(a)*tan((c + d*x)/2)**2 + s 
qrt(a))*a*b**3 + 18*sqrt(a)*sqrt(a - b)*log(2*sqrt(a - b)*tan((c + d*x)/2) 
 + sqrt(a)*tan((c + d*x)/2)**2 + sqrt(a))*sin(c + d*x)**2*a**2*b**2 - 21*s 
qrt(a)*sqrt(a - b)*log(2*sqrt(a - b)*tan((c + d*x)/2) + sqrt(a)*tan((c + d 
*x)/2)**2 + sqrt(a))*sin(c + d*x)**2*a*b**3 + 3*sqrt(a)*sqrt(a - b)*log(2* 
sqrt(a - b)*tan((c + d*x)/2) + sqrt(a)*tan((c + d*x)/2)**2 + sqrt(a))*sin( 
c + d*x)**2*b**4 - 18*sqrt(a)*sqrt(a - b)*log(2*sqrt(a - b)*tan((c + d*x)/ 
2) + sqrt(a)*tan((c + d*x)/2)**2 + sqrt(a))*a**2*b**2 + 3*sqrt(a)*sqrt(a - 
 b)*log(2*sqrt(a - b)*tan((c + d*x)/2) + sqrt(a)*tan((c + d*x)/2)**2 + sqr 
t(a))*a*b**3 - 4*sin(c + d*x)**5*a**5 + 12*sin(c + d*x)**5*a**4*b - 12*sin 
(c + d*x)**5*a**3*b**2 + 4*sin(c + d*x)**5*a**2*b**3 + 16*sin(c + d*x)**3* 
a**5 - 68*sin(c + d*x)**3*a**4*b + 88*sin(c + d*x)**3*a**3*b**2 - 36*sin(c 
 + d*x)**3*a**2*b**3 - 12*sin(c + d*x)*a**5 + 48*sin(c + d*x)*a**4*b - ...