\(\int \frac {\csc ^4(e+f x)}{(a+b \sec ^2(e+f x))^2} \, dx\) [52]

Optimal result
Mathematica [C] (warning: unable to verify)
Rubi [A] (verified)
Maple [A] (verified)
Fricas [B] (verification not implemented)
Sympy [F]
Maxima [A] (verification not implemented)
Giac [A] (verification not implemented)
Mupad [B] (verification not implemented)
Reduce [B] (verification not implemented)

Optimal result

Integrand size = 23, antiderivative size = 123 \[ \int \frac {\csc ^4(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^2} \, dx=-\frac {(3 a-2 b) \sqrt {b} \arctan \left (\frac {\sqrt {b} \tan (e+f x)}{\sqrt {a+b}}\right )}{2 (a+b)^{7/2} f}-\frac {(a-b) \cot (e+f x)}{(a+b)^3 f}-\frac {\cot ^3(e+f x)}{3 (a+b)^2 f}-\frac {a b \tan (e+f x)}{2 (a+b)^3 f \left (a+b+b \tan ^2(e+f x)\right )} \] Output:

-1/2*(3*a-2*b)*b^(1/2)*arctan(b^(1/2)*tan(f*x+e)/(a+b)^(1/2))/(a+b)^(7/2)/ 
f-(a-b)*cot(f*x+e)/(a+b)^3/f-1/3*cot(f*x+e)^3/(a+b)^2/f-1/2*a*b*tan(f*x+e) 
/(a+b)^3/f/(a+b+b*tan(f*x+e)^2)
 

Mathematica [C] (warning: unable to verify)

Result contains complex when optimal does not.

Time = 4.87 (sec) , antiderivative size = 303, normalized size of antiderivative = 2.46 \[ \int \frac {\csc ^4(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^2} \, dx=\frac {(a+2 b+a \cos (2 (e+f x))) \sec ^4(e+f x) \left (-2 (a+b) (a+2 b+a \cos (2 (e+f x))) \cot (e) \csc ^2(e+f x)+\frac {3 (3 a-2 b) b \arctan \left (\frac {\sec (f x) (\cos (2 e)-i \sin (2 e)) (-((a+2 b) \sin (f x))+a \sin (2 e+f x))}{2 \sqrt {a+b} \sqrt {b (\cos (e)-i \sin (e))^4}}\right ) (a+2 b+a \cos (2 (e+f x))) (\cos (2 e)-i \sin (2 e))}{\sqrt {a+b} \sqrt {b (\cos (e)-i \sin (e))^4}}+4 (a-2 b) (a+2 b+a \cos (2 (e+f x))) \csc (e) \csc (e+f x) \sin (f x)+2 (a+b) (a+2 b+a \cos (2 (e+f x))) \csc (e) \csc ^3(e+f x) \sin (f x)-3 a b \sec (2 e) \sin (2 f x)+3 b (a+2 b) \tan (2 e)\right )}{24 (a+b)^3 f \left (a+b \sec ^2(e+f x)\right )^2} \] Input:

Integrate[Csc[e + f*x]^4/(a + b*Sec[e + f*x]^2)^2,x]
 

Output:

((a + 2*b + a*Cos[2*(e + f*x)])*Sec[e + f*x]^4*(-2*(a + b)*(a + 2*b + a*Co 
s[2*(e + f*x)])*Cot[e]*Csc[e + f*x]^2 + (3*(3*a - 2*b)*b*ArcTan[(Sec[f*x]* 
(Cos[2*e] - I*Sin[2*e])*(-((a + 2*b)*Sin[f*x]) + a*Sin[2*e + f*x]))/(2*Sqr 
t[a + b]*Sqrt[b*(Cos[e] - I*Sin[e])^4])]*(a + 2*b + a*Cos[2*(e + f*x)])*(C 
os[2*e] - I*Sin[2*e]))/(Sqrt[a + b]*Sqrt[b*(Cos[e] - I*Sin[e])^4]) + 4*(a 
- 2*b)*(a + 2*b + a*Cos[2*(e + f*x)])*Csc[e]*Csc[e + f*x]*Sin[f*x] + 2*(a 
+ b)*(a + 2*b + a*Cos[2*(e + f*x)])*Csc[e]*Csc[e + f*x]^3*Sin[f*x] - 3*a*b 
*Sec[2*e]*Sin[2*f*x] + 3*b*(a + 2*b)*Tan[2*e]))/(24*(a + b)^3*f*(a + b*Sec 
[e + f*x]^2)^2)
 

Rubi [A] (verified)

Time = 0.39 (sec) , antiderivative size = 125, normalized size of antiderivative = 1.02, number of steps used = 7, number of rules used = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.261, Rules used = {3042, 4620, 361, 25, 1584, 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 {\csc ^4(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^2} \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {1}{\sin (e+f x)^4 \left (a+b \sec (e+f x)^2\right )^2}dx\)

\(\Big \downarrow \) 4620

\(\displaystyle \frac {\int \frac {\cot ^4(e+f x) \left (\tan ^2(e+f x)+1\right )}{\left (b \tan ^2(e+f x)+a+b\right )^2}d\tan (e+f x)}{f}\)

\(\Big \downarrow \) 361

\(\displaystyle \frac {-\frac {1}{2} b \int -\frac {\cot ^4(e+f x) \left (-\frac {a \tan ^4(e+f x)}{(a+b)^3}+\frac {2 a \tan ^2(e+f x)}{b (a+b)^2}+\frac {2}{b (a+b)}\right )}{b \tan ^2(e+f x)+a+b}d\tan (e+f x)-\frac {a b \tan (e+f x)}{2 (a+b)^3 \left (a+b \tan ^2(e+f x)+b\right )}}{f}\)

\(\Big \downarrow \) 25

\(\displaystyle \frac {\frac {1}{2} b \int \frac {\cot ^4(e+f x) \left (-\frac {a \tan ^4(e+f x)}{(a+b)^3}+\frac {2 a \tan ^2(e+f x)}{b (a+b)^2}+\frac {2}{b (a+b)}\right )}{b \tan ^2(e+f x)+a+b}d\tan (e+f x)-\frac {a b \tan (e+f x)}{2 (a+b)^3 \left (a+b \tan ^2(e+f x)+b\right )}}{f}\)

\(\Big \downarrow \) 1584

\(\displaystyle \frac {\frac {1}{2} b \int \left (\frac {2 \cot ^4(e+f x)}{b (a+b)^2}+\frac {2 (a-b) \cot ^2(e+f x)}{b (a+b)^3}+\frac {2 b-3 a}{(a+b)^3 \left (b \tan ^2(e+f x)+a+b\right )}\right )d\tan (e+f x)-\frac {a b \tan (e+f x)}{2 (a+b)^3 \left (a+b \tan ^2(e+f x)+b\right )}}{f}\)

\(\Big \downarrow \) 2009

\(\displaystyle \frac {\frac {1}{2} b \left (-\frac {(3 a-2 b) \arctan \left (\frac {\sqrt {b} \tan (e+f x)}{\sqrt {a+b}}\right )}{\sqrt {b} (a+b)^{7/2}}-\frac {2 \cot ^3(e+f x)}{3 b (a+b)^2}-\frac {2 (a-b) \cot (e+f x)}{b (a+b)^3}\right )-\frac {a b \tan (e+f x)}{2 (a+b)^3 \left (a+b \tan ^2(e+f x)+b\right )}}{f}\)

Input:

Int[Csc[e + f*x]^4/(a + b*Sec[e + f*x]^2)^2,x]
 

Output:

((b*(-(((3*a - 2*b)*ArcTan[(Sqrt[b]*Tan[e + f*x])/Sqrt[a + b]])/(Sqrt[b]*( 
a + b)^(7/2))) - (2*(a - b)*Cot[e + f*x])/(b*(a + b)^3) - (2*Cot[e + f*x]^ 
3)/(3*b*(a + b)^2)))/2 - (a*b*Tan[e + f*x])/(2*(a + b)^3*(a + b + b*Tan[e 
+ f*x]^2)))/f
 

Defintions of rubi rules used

rule 25
Int[-(Fx_), x_Symbol] :> Simp[Identity[-1]   Int[Fx, x], x]
 

rule 361
Int[(x_)^(m_)*((a_) + (b_.)*(x_)^2)^(p_)*((c_) + (d_.)*(x_)^2), x_Symbol] : 
> Simp[(-a)^(m/2 - 1)*(b*c - a*d)*x*((a + b*x^2)^(p + 1)/(2*b^(m/2 + 1)*(p 
+ 1))), x] + Simp[1/(2*b^(m/2 + 1)*(p + 1))   Int[x^m*(a + b*x^2)^(p + 1)*E 
xpandToSum[2*b*(p + 1)*Together[(b^(m/2)*(c + d*x^2) - (-a)^(m/2 - 1)*(b*c 
- a*d)*x^(-m + 2))/(a + b*x^2)] - ((-a)^(m/2 - 1)*(b*c - a*d))/x^m, x], x], 
 x] /; FreeQ[{a, b, c, d}, x] && NeQ[b*c - a*d, 0] && LtQ[p, -1] && ILtQ[m/ 
2, 0] && (IntegerQ[p] || EqQ[m + 2*p + 1, 0])
 

rule 1584
Int[((f_.)*(x_))^(m_.)*((d_) + (e_.)*(x_)^2)^(q_.)*((a_) + (b_.)*(x_)^2 + ( 
c_.)*(x_)^4)^(p_.), x_Symbol] :> Int[ExpandIntegrand[(f*x)^m*(d + e*x^2)^q* 
(a + b*x^2 + c*x^4)^p, x], x] /; FreeQ[{a, b, c, d, e, f, m, q}, x] && NeQ[ 
b^2 - 4*a*c, 0] && IGtQ[p, 0] && IGtQ[q, -2]
 

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

Time = 0.88 (sec) , antiderivative size = 106, normalized size of antiderivative = 0.86

method result size
derivativedivides \(\frac {-\frac {1}{3 \left (a +b \right )^{2} \tan \left (f x +e \right )^{3}}-\frac {a -b}{\left (a +b \right )^{3} \tan \left (f x +e \right )}-\frac {b \left (\frac {a \tan \left (f x +e \right )}{2 a +2 b +2 b \tan \left (f x +e \right )^{2}}+\frac {\left (3 a -2 b \right ) \arctan \left (\frac {b \tan \left (f x +e \right )}{\sqrt {\left (a +b \right ) b}}\right )}{2 \sqrt {\left (a +b \right ) b}}\right )}{\left (a +b \right )^{3}}}{f}\) \(106\)
default \(\frac {-\frac {1}{3 \left (a +b \right )^{2} \tan \left (f x +e \right )^{3}}-\frac {a -b}{\left (a +b \right )^{3} \tan \left (f x +e \right )}-\frac {b \left (\frac {a \tan \left (f x +e \right )}{2 a +2 b +2 b \tan \left (f x +e \right )^{2}}+\frac {\left (3 a -2 b \right ) \arctan \left (\frac {b \tan \left (f x +e \right )}{\sqrt {\left (a +b \right ) b}}\right )}{2 \sqrt {\left (a +b \right ) b}}\right )}{\left (a +b \right )^{3}}}{f}\) \(106\)
risch \(\frac {i \left (9 \,{\mathrm e}^{8 i \left (f x +e \right )} a b -6 \,{\mathrm e}^{8 i \left (f x +e \right )} b^{2}+12 a^{2} {\mathrm e}^{6 i \left (f x +e \right )}+18 a b \,{\mathrm e}^{6 i \left (f x +e \right )}+66 b^{2} {\mathrm e}^{6 i \left (f x +e \right )}+20 a^{2} {\mathrm e}^{4 i \left (f x +e \right )}+44 a b \,{\mathrm e}^{4 i \left (f x +e \right )}-66 b^{2} {\mathrm e}^{4 i \left (f x +e \right )}+4 a^{2} {\mathrm e}^{2 i \left (f x +e \right )}-18 a b \,{\mathrm e}^{2 i \left (f x +e \right )}+38 b^{2} {\mathrm e}^{2 i \left (f x +e \right )}-4 a^{2}+11 a b \right )}{3 f \left (a +b \right )^{3} \left ({\mathrm e}^{2 i \left (f x +e \right )}-1\right )^{3} \left (a \,{\mathrm e}^{4 i \left (f x +e \right )}+2 a \,{\mathrm e}^{2 i \left (f x +e \right )}+4 b \,{\mathrm e}^{2 i \left (f x +e \right )}+a \right )}+\frac {3 \sqrt {-\left (a +b \right ) b}\, \ln \left ({\mathrm e}^{2 i \left (f x +e \right )}+\frac {2 i \sqrt {-\left (a +b \right ) b}+a +2 b}{a}\right ) a}{4 \left (a +b \right )^{4} f}-\frac {\sqrt {-\left (a +b \right ) b}\, \ln \left ({\mathrm e}^{2 i \left (f x +e \right )}+\frac {2 i \sqrt {-\left (a +b \right ) b}+a +2 b}{a}\right ) b}{2 \left (a +b \right )^{4} f}-\frac {3 \sqrt {-\left (a +b \right ) b}\, \ln \left ({\mathrm e}^{2 i \left (f x +e \right )}-\frac {2 i \sqrt {-\left (a +b \right ) b}-a -2 b}{a}\right ) a}{4 \left (a +b \right )^{4} f}+\frac {\sqrt {-\left (a +b \right ) b}\, \ln \left ({\mathrm e}^{2 i \left (f x +e \right )}-\frac {2 i \sqrt {-\left (a +b \right ) b}-a -2 b}{a}\right ) b}{2 \left (a +b \right )^{4} f}\) \(431\)

Input:

int(csc(f*x+e)^4/(a+b*sec(f*x+e)^2)^2,x,method=_RETURNVERBOSE)
 

Output:

1/f*(-1/3/(a+b)^2/tan(f*x+e)^3-(a-b)/(a+b)^3/tan(f*x+e)-1/(a+b)^3*b*(1/2*a 
*tan(f*x+e)/(a+b+b*tan(f*x+e)^2)+1/2*(3*a-2*b)/((a+b)*b)^(1/2)*arctan(b*ta 
n(f*x+e)/((a+b)*b)^(1/2))))
 

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 288 vs. \(2 (109) = 218\).

Time = 0.15 (sec) , antiderivative size = 663, normalized size of antiderivative = 5.39 \[ \int \frac {\csc ^4(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^2} \, dx =\text {Too large to display} \] Input:

integrate(csc(f*x+e)^4/(a+b*sec(f*x+e)^2)^2,x, algorithm="fricas")
 

Output:

[-1/24*(4*(4*a^2 - 11*a*b)*cos(f*x + e)^5 - 8*(3*a^2 - 8*a*b + 4*b^2)*cos( 
f*x + e)^3 + 3*((3*a^2 - 2*a*b)*cos(f*x + e)^4 - (3*a^2 - 5*a*b + 2*b^2)*c 
os(f*x + e)^2 - 3*a*b + 2*b^2)*sqrt(-b/(a + b))*log(((a^2 + 8*a*b + 8*b^2) 
*cos(f*x + e)^4 - 2*(3*a*b + 4*b^2)*cos(f*x + e)^2 - 4*((a^2 + 3*a*b + 2*b 
^2)*cos(f*x + e)^3 - (a*b + b^2)*cos(f*x + e))*sqrt(-b/(a + b))*sin(f*x + 
e) + b^2)/(a^2*cos(f*x + e)^4 + 2*a*b*cos(f*x + e)^2 + b^2))*sin(f*x + e) 
- 12*(3*a*b - 2*b^2)*cos(f*x + e))/(((a^4 + 3*a^3*b + 3*a^2*b^2 + a*b^3)*f 
*cos(f*x + e)^4 - (a^4 + 2*a^3*b - 2*a*b^3 - b^4)*f*cos(f*x + e)^2 - (a^3* 
b + 3*a^2*b^2 + 3*a*b^3 + b^4)*f)*sin(f*x + e)), -1/12*(2*(4*a^2 - 11*a*b) 
*cos(f*x + e)^5 - 4*(3*a^2 - 8*a*b + 4*b^2)*cos(f*x + e)^3 - 3*((3*a^2 - 2 
*a*b)*cos(f*x + e)^4 - (3*a^2 - 5*a*b + 2*b^2)*cos(f*x + e)^2 - 3*a*b + 2* 
b^2)*sqrt(b/(a + b))*arctan(1/2*((a + 2*b)*cos(f*x + e)^2 - b)*sqrt(b/(a + 
 b))/(b*cos(f*x + e)*sin(f*x + e)))*sin(f*x + e) - 6*(3*a*b - 2*b^2)*cos(f 
*x + e))/(((a^4 + 3*a^3*b + 3*a^2*b^2 + a*b^3)*f*cos(f*x + e)^4 - (a^4 + 2 
*a^3*b - 2*a*b^3 - b^4)*f*cos(f*x + e)^2 - (a^3*b + 3*a^2*b^2 + 3*a*b^3 + 
b^4)*f)*sin(f*x + e))]
 

Sympy [F]

\[ \int \frac {\csc ^4(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^2} \, dx=\int \frac {\csc ^{4}{\left (e + f x \right )}}{\left (a + b \sec ^{2}{\left (e + f x \right )}\right )^{2}}\, dx \] Input:

integrate(csc(f*x+e)**4/(a+b*sec(f*x+e)**2)**2,x)
 

Output:

Integral(csc(e + f*x)**4/(a + b*sec(e + f*x)**2)**2, x)
 

Maxima [A] (verification not implemented)

Time = 0.12 (sec) , antiderivative size = 193, normalized size of antiderivative = 1.57 \[ \int \frac {\csc ^4(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^2} \, dx=-\frac {\frac {3 \, {\left (3 \, a b - 2 \, b^{2}\right )} \arctan \left (\frac {b \tan \left (f x + e\right )}{\sqrt {{\left (a + b\right )} b}}\right )}{{\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} \sqrt {{\left (a + b\right )} b}} + \frac {3 \, {\left (3 \, a b - 2 \, b^{2}\right )} \tan \left (f x + e\right )^{4} + 2 \, {\left (3 \, a^{2} + a b - 2 \, b^{2}\right )} \tan \left (f x + e\right )^{2} + 2 \, a^{2} + 4 \, a b + 2 \, b^{2}}{{\left (a^{3} b + 3 \, a^{2} b^{2} + 3 \, a b^{3} + b^{4}\right )} \tan \left (f x + e\right )^{5} + {\left (a^{4} + 4 \, a^{3} b + 6 \, a^{2} b^{2} + 4 \, a b^{3} + b^{4}\right )} \tan \left (f x + e\right )^{3}}}{6 \, f} \] Input:

integrate(csc(f*x+e)^4/(a+b*sec(f*x+e)^2)^2,x, algorithm="maxima")
 

Output:

-1/6*(3*(3*a*b - 2*b^2)*arctan(b*tan(f*x + e)/sqrt((a + b)*b))/((a^3 + 3*a 
^2*b + 3*a*b^2 + b^3)*sqrt((a + b)*b)) + (3*(3*a*b - 2*b^2)*tan(f*x + e)^4 
 + 2*(3*a^2 + a*b - 2*b^2)*tan(f*x + e)^2 + 2*a^2 + 4*a*b + 2*b^2)/((a^3*b 
 + 3*a^2*b^2 + 3*a*b^3 + b^4)*tan(f*x + e)^5 + (a^4 + 4*a^3*b + 6*a^2*b^2 
+ 4*a*b^3 + b^4)*tan(f*x + e)^3))/f
 

Giac [A] (verification not implemented)

Time = 0.23 (sec) , antiderivative size = 185, normalized size of antiderivative = 1.50 \[ \int \frac {\csc ^4(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^2} \, dx=-\frac {\frac {3 \, a b \tan \left (f x + e\right )}{{\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} {\left (b \tan \left (f x + e\right )^{2} + a + b\right )}} + \frac {3 \, {\left (\pi \left \lfloor \frac {f x + e}{\pi } + \frac {1}{2} \right \rfloor \mathrm {sgn}\left (b\right ) + \arctan \left (\frac {b \tan \left (f x + e\right )}{\sqrt {a b + b^{2}}}\right )\right )} {\left (3 \, a b - 2 \, b^{2}\right )}}{{\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} \sqrt {a b + b^{2}}} + \frac {2 \, {\left (3 \, a \tan \left (f x + e\right )^{2} - 3 \, b \tan \left (f x + e\right )^{2} + a + b\right )}}{{\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} \tan \left (f x + e\right )^{3}}}{6 \, f} \] Input:

integrate(csc(f*x+e)^4/(a+b*sec(f*x+e)^2)^2,x, algorithm="giac")
 

Output:

-1/6*(3*a*b*tan(f*x + e)/((a^3 + 3*a^2*b + 3*a*b^2 + b^3)*(b*tan(f*x + e)^ 
2 + a + b)) + 3*(pi*floor((f*x + e)/pi + 1/2)*sgn(b) + arctan(b*tan(f*x + 
e)/sqrt(a*b + b^2)))*(3*a*b - 2*b^2)/((a^3 + 3*a^2*b + 3*a*b^2 + b^3)*sqrt 
(a*b + b^2)) + 2*(3*a*tan(f*x + e)^2 - 3*b*tan(f*x + e)^2 + a + b)/((a^3 + 
 3*a^2*b + 3*a*b^2 + b^3)*tan(f*x + e)^3))/f
 

Mupad [B] (verification not implemented)

Time = 13.42 (sec) , antiderivative size = 141, normalized size of antiderivative = 1.15 \[ \int \frac {\csc ^4(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^2} \, dx=-\frac {\frac {1}{3\,\left (a+b\right )}+\frac {{\mathrm {tan}\left (e+f\,x\right )}^2\,\left (3\,a-2\,b\right )}{3\,{\left (a+b\right )}^2}+\frac {b\,{\mathrm {tan}\left (e+f\,x\right )}^4\,\left (3\,a-2\,b\right )}{2\,{\left (a+b\right )}^3}}{f\,\left (b\,{\mathrm {tan}\left (e+f\,x\right )}^5+\left (a+b\right )\,{\mathrm {tan}\left (e+f\,x\right )}^3\right )}-\frac {\sqrt {b}\,\mathrm {atan}\left (\frac {\sqrt {b}\,\mathrm {tan}\left (e+f\,x\right )\,\left (a^3+3\,a^2\,b+3\,a\,b^2+b^3\right )}{{\left (a+b\right )}^{7/2}}\right )\,\left (3\,a-2\,b\right )}{2\,f\,{\left (a+b\right )}^{7/2}} \] Input:

int(1/(sin(e + f*x)^4*(a + b/cos(e + f*x)^2)^2),x)
 

Output:

- (1/(3*(a + b)) + (tan(e + f*x)^2*(3*a - 2*b))/(3*(a + b)^2) + (b*tan(e + 
 f*x)^4*(3*a - 2*b))/(2*(a + b)^3))/(f*(tan(e + f*x)^3*(a + b) + b*tan(e + 
 f*x)^5)) - (b^(1/2)*atan((b^(1/2)*tan(e + f*x)*(3*a*b^2 + 3*a^2*b + a^3 + 
 b^3))/(a + b)^(7/2))*(3*a - 2*b))/(2*f*(a + b)^(7/2))
 

Reduce [B] (verification not implemented)

Time = 0.21 (sec) , antiderivative size = 735, normalized size of antiderivative = 5.98 \[ \int \frac {\csc ^4(e+f x)}{\left (a+b \sec ^2(e+f x)\right )^2} \, dx =\text {Too large to display} \] Input:

int(csc(f*x+e)^4/(a+b*sec(f*x+e)^2)^2,x)
 

Output:

( - 9*sqrt(b)*sqrt(a + b)*atan((sqrt(a + b)*tan((e + f*x)/2) - sqrt(a))/sq 
rt(b))*sin(e + f*x)**5*a**2 + 6*sqrt(b)*sqrt(a + b)*atan((sqrt(a + b)*tan( 
(e + f*x)/2) - sqrt(a))/sqrt(b))*sin(e + f*x)**5*a*b + 9*sqrt(b)*sqrt(a + 
b)*atan((sqrt(a + b)*tan((e + f*x)/2) - sqrt(a))/sqrt(b))*sin(e + f*x)**3* 
a**2 + 3*sqrt(b)*sqrt(a + b)*atan((sqrt(a + b)*tan((e + f*x)/2) - sqrt(a)) 
/sqrt(b))*sin(e + f*x)**3*a*b - 6*sqrt(b)*sqrt(a + b)*atan((sqrt(a + b)*ta 
n((e + f*x)/2) - sqrt(a))/sqrt(b))*sin(e + f*x)**3*b**2 - 9*sqrt(b)*sqrt(a 
 + b)*atan((sqrt(a + b)*tan((e + f*x)/2) + sqrt(a))/sqrt(b))*sin(e + f*x)* 
*5*a**2 + 6*sqrt(b)*sqrt(a + b)*atan((sqrt(a + b)*tan((e + f*x)/2) + sqrt( 
a))/sqrt(b))*sin(e + f*x)**5*a*b + 9*sqrt(b)*sqrt(a + b)*atan((sqrt(a + b) 
*tan((e + f*x)/2) + sqrt(a))/sqrt(b))*sin(e + f*x)**3*a**2 + 3*sqrt(b)*sqr 
t(a + b)*atan((sqrt(a + b)*tan((e + f*x)/2) + sqrt(a))/sqrt(b))*sin(e + f* 
x)**3*a*b - 6*sqrt(b)*sqrt(a + b)*atan((sqrt(a + b)*tan((e + f*x)/2) + sqr 
t(a))/sqrt(b))*sin(e + f*x)**3*b**2 - 4*cos(e + f*x)*sin(e + f*x)**4*a**3 
+ 7*cos(e + f*x)*sin(e + f*x)**4*a**2*b + 11*cos(e + f*x)*sin(e + f*x)**4* 
a*b**2 + 2*cos(e + f*x)*sin(e + f*x)**2*a**3 - 4*cos(e + f*x)*sin(e + f*x) 
**2*a**2*b - 14*cos(e + f*x)*sin(e + f*x)**2*a*b**2 - 8*cos(e + f*x)*sin(e 
 + f*x)**2*b**3 + 2*cos(e + f*x)*a**3 + 6*cos(e + f*x)*a**2*b + 6*cos(e + 
f*x)*a*b**2 + 2*cos(e + f*x)*b**3)/(6*sin(e + f*x)**3*f*(sin(e + f*x)**2*a 
**5 + 4*sin(e + f*x)**2*a**4*b + 6*sin(e + f*x)**2*a**3*b**2 + 4*sin(e ...