\(\int \frac {1}{(a+i a \tan (e+f x))^3 \sqrt {c+d \tan (e+f x)}} \, dx\) [1124]

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

Optimal result

Integrand size = 30, antiderivative size = 298 \[ \int \frac {1}{(a+i a \tan (e+f x))^3 \sqrt {c+d \tan (e+f x)}} \, dx=-\frac {i \text {arctanh}\left (\frac {\sqrt {c+d \tan (e+f x)}}{\sqrt {c-i d}}\right )}{8 a^3 \sqrt {c-i d} f}+\frac {\left (2 i c^3-8 c^2 d-13 i c d^2+12 d^3\right ) \text {arctanh}\left (\frac {\sqrt {c+d \tan (e+f x)}}{\sqrt {c+i d}}\right )}{16 a^3 (c+i d)^{7/2} f}-\frac {\sqrt {c+d \tan (e+f x)}}{6 (i c-d) f (a+i a \tan (e+f x))^3}+\frac {(3 i c-8 d) \sqrt {c+d \tan (e+f x)}}{24 a (c+i d)^2 f (a+i a \tan (e+f x))^2}+\frac {\left (2 c^2+7 i c d-10 d^2\right ) \sqrt {c+d \tan (e+f x)}}{16 (i c-d)^3 f \left (a^3+i a^3 \tan (e+f x)\right )} \] Output:

-1/8*I*arctanh((c+d*tan(f*x+e))^(1/2)/(c-I*d)^(1/2))/a^3/(c-I*d)^(1/2)/f+1 
/16*(2*I*c^3-8*c^2*d-13*I*c*d^2+12*d^3)*arctanh((c+d*tan(f*x+e))^(1/2)/(c+ 
I*d)^(1/2))/a^3/(c+I*d)^(7/2)/f-1/6*(c+d*tan(f*x+e))^(1/2)/(I*c-d)/f/(a+I* 
a*tan(f*x+e))^3+1/24*(3*I*c-8*d)*(c+d*tan(f*x+e))^(1/2)/a/(c+I*d)^2/f/(a+I 
*a*tan(f*x+e))^2+1/16*(2*c^2+7*I*c*d-10*d^2)*(c+d*tan(f*x+e))^(1/2)/(I*c-d 
)^3/f/(a^3+I*a^3*tan(f*x+e))
 

Mathematica [A] (verified)

Time = 2.28 (sec) , antiderivative size = 266, normalized size of antiderivative = 0.89 \[ \int \frac {1}{(a+i a \tan (e+f x))^3 \sqrt {c+d \tan (e+f x)}} \, dx=-\frac {\frac {6 i (c+i d)^2 \text {arctanh}\left (\frac {\sqrt {c+d \tan (e+f x)}}{\sqrt {c-i d}}\right )}{\sqrt {c-i d}}+\frac {3 \left (-2 i c^3+8 c^2 d+13 i c d^2-12 d^3\right ) \text {arctanh}\left (\frac {\sqrt {c+d \tan (e+f x)}}{\sqrt {c+i d}}\right )}{(c+i d)^{3/2}}+\frac {8 (c+i d) \sqrt {c+d \tan (e+f x)}}{(-i+\tan (e+f x))^3}+\frac {2 i (3 c+8 i d) \sqrt {c+d \tan (e+f x)}}{(-i+\tan (e+f x))^2}-\frac {3 \left (2 c^2+7 i c d-10 d^2\right ) \sqrt {c+d \tan (e+f x)}}{(c+i d) (-i+\tan (e+f x))}}{48 a^3 (c+i d)^2 f} \] Input:

Integrate[1/((a + I*a*Tan[e + f*x])^3*Sqrt[c + d*Tan[e + f*x]]),x]
 

Output:

-1/48*(((6*I)*(c + I*d)^2*ArcTanh[Sqrt[c + d*Tan[e + f*x]]/Sqrt[c - I*d]]) 
/Sqrt[c - I*d] + (3*((-2*I)*c^3 + 8*c^2*d + (13*I)*c*d^2 - 12*d^3)*ArcTanh 
[Sqrt[c + d*Tan[e + f*x]]/Sqrt[c + I*d]])/(c + I*d)^(3/2) + (8*(c + I*d)*S 
qrt[c + d*Tan[e + f*x]])/(-I + Tan[e + f*x])^3 + ((2*I)*(3*c + (8*I)*d)*Sq 
rt[c + d*Tan[e + f*x]])/(-I + Tan[e + f*x])^2 - (3*(2*c^2 + (7*I)*c*d - 10 
*d^2)*Sqrt[c + d*Tan[e + f*x]])/((c + I*d)*(-I + Tan[e + f*x])))/(a^3*(c + 
 I*d)^2*f)
 

Rubi [A] (warning: unable to verify)

Time = 1.67 (sec) , antiderivative size = 338, normalized size of antiderivative = 1.13, number of steps used = 17, number of rules used = 16, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.533, Rules used = {3042, 4042, 27, 3042, 4079, 27, 3042, 4079, 25, 3042, 4022, 3042, 4020, 25, 73, 221}

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}{(a+i a \tan (e+f x))^3 \sqrt {c+d \tan (e+f x)}} \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {1}{(a+i a \tan (e+f x))^3 \sqrt {c+d \tan (e+f x)}}dx\)

\(\Big \downarrow \) 4042

\(\displaystyle -\frac {\int -\frac {a (6 i c-11 d)+5 i a d \tan (e+f x)}{2 (i \tan (e+f x) a+a)^2 \sqrt {c+d \tan (e+f x)}}dx}{6 a^2 (-d+i c)}-\frac {\sqrt {c+d \tan (e+f x)}}{6 f (-d+i c) (a+i a \tan (e+f x))^3}\)

\(\Big \downarrow \) 27

\(\displaystyle \frac {\int \frac {a (6 i c-11 d)+5 i a d \tan (e+f x)}{(i \tan (e+f x) a+a)^2 \sqrt {c+d \tan (e+f x)}}dx}{12 a^2 (-d+i c)}-\frac {\sqrt {c+d \tan (e+f x)}}{6 f (-d+i c) (a+i a \tan (e+f x))^3}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {\int \frac {a (6 i c-11 d)+5 i a d \tan (e+f x)}{(i \tan (e+f x) a+a)^2 \sqrt {c+d \tan (e+f x)}}dx}{12 a^2 (-d+i c)}-\frac {\sqrt {c+d \tan (e+f x)}}{6 f (-d+i c) (a+i a \tan (e+f x))^3}\)

\(\Big \downarrow \) 4079

\(\displaystyle \frac {-\frac {\int \frac {3 \left (\left (4 c^2+11 i d c-12 d^2\right ) a^2+(3 c+8 i d) d \tan (e+f x) a^2\right )}{(i \tan (e+f x) a+a) \sqrt {c+d \tan (e+f x)}}dx}{4 a^2 (-d+i c)}-\frac {a (3 c+8 i d) \sqrt {c+d \tan (e+f x)}}{2 f (c+i d) (a+i a \tan (e+f x))^2}}{12 a^2 (-d+i c)}-\frac {\sqrt {c+d \tan (e+f x)}}{6 f (-d+i c) (a+i a \tan (e+f x))^3}\)

\(\Big \downarrow \) 27

\(\displaystyle \frac {-\frac {3 \int \frac {\left (4 c^2+11 i d c-12 d^2\right ) a^2+(3 c+8 i d) d \tan (e+f x) a^2}{(i \tan (e+f x) a+a) \sqrt {c+d \tan (e+f x)}}dx}{4 a^2 (-d+i c)}-\frac {a (3 c+8 i d) \sqrt {c+d \tan (e+f x)}}{2 f (c+i d) (a+i a \tan (e+f x))^2}}{12 a^2 (-d+i c)}-\frac {\sqrt {c+d \tan (e+f x)}}{6 f (-d+i c) (a+i a \tan (e+f x))^3}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {-\frac {3 \int \frac {\left (4 c^2+11 i d c-12 d^2\right ) a^2+(3 c+8 i d) d \tan (e+f x) a^2}{(i \tan (e+f x) a+a) \sqrt {c+d \tan (e+f x)}}dx}{4 a^2 (-d+i c)}-\frac {a (3 c+8 i d) \sqrt {c+d \tan (e+f x)}}{2 f (c+i d) (a+i a \tan (e+f x))^2}}{12 a^2 (-d+i c)}-\frac {\sqrt {c+d \tan (e+f x)}}{6 f (-d+i c) (a+i a \tan (e+f x))^3}\)

\(\Big \downarrow \) 4079

\(\displaystyle \frac {-\frac {3 \left (\frac {a^2 \left (2 i c^2-7 c d-10 i d^2\right ) \sqrt {c+d \tan (e+f x)}}{f (c+i d) (a+i a \tan (e+f x))}-\frac {\int -\frac {(i c-2 d) \left (4 c^2+6 i d c-7 d^2\right ) a^3+d \left (2 i c^2-7 d c-10 i d^2\right ) \tan (e+f x) a^3}{\sqrt {c+d \tan (e+f x)}}dx}{2 a^2 (-d+i c)}\right )}{4 a^2 (-d+i c)}-\frac {a (3 c+8 i d) \sqrt {c+d \tan (e+f x)}}{2 f (c+i d) (a+i a \tan (e+f x))^2}}{12 a^2 (-d+i c)}-\frac {\sqrt {c+d \tan (e+f x)}}{6 f (-d+i c) (a+i a \tan (e+f x))^3}\)

\(\Big \downarrow \) 25

\(\displaystyle \frac {-\frac {3 \left (\frac {\int \frac {(i c-2 d) \left (4 c^2+6 i d c-7 d^2\right ) a^3+d \left (2 i c^2-7 d c-10 i d^2\right ) \tan (e+f x) a^3}{\sqrt {c+d \tan (e+f x)}}dx}{2 a^2 (-d+i c)}+\frac {a^2 \left (2 i c^2-7 c d-10 i d^2\right ) \sqrt {c+d \tan (e+f x)}}{f (c+i d) (a+i a \tan (e+f x))}\right )}{4 a^2 (-d+i c)}-\frac {a (3 c+8 i d) \sqrt {c+d \tan (e+f x)}}{2 f (c+i d) (a+i a \tan (e+f x))^2}}{12 a^2 (-d+i c)}-\frac {\sqrt {c+d \tan (e+f x)}}{6 f (-d+i c) (a+i a \tan (e+f x))^3}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {-\frac {3 \left (\frac {\int \frac {(i c-2 d) \left (4 c^2+6 i d c-7 d^2\right ) a^3+d \left (2 i c^2-7 d c-10 i d^2\right ) \tan (e+f x) a^3}{\sqrt {c+d \tan (e+f x)}}dx}{2 a^2 (-d+i c)}+\frac {a^2 \left (2 i c^2-7 c d-10 i d^2\right ) \sqrt {c+d \tan (e+f x)}}{f (c+i d) (a+i a \tan (e+f x))}\right )}{4 a^2 (-d+i c)}-\frac {a (3 c+8 i d) \sqrt {c+d \tan (e+f x)}}{2 f (c+i d) (a+i a \tan (e+f x))^2}}{12 a^2 (-d+i c)}-\frac {\sqrt {c+d \tan (e+f x)}}{6 f (-d+i c) (a+i a \tan (e+f x))^3}\)

\(\Big \downarrow \) 4022

\(\displaystyle \frac {-\frac {3 \left (\frac {a^3 \left (2 i c^3-8 c^2 d-13 i c d^2+12 d^3\right ) \int \frac {1-i \tan (e+f x)}{\sqrt {c+d \tan (e+f x)}}dx-2 a^3 (-d+i c)^3 \int \frac {i \tan (e+f x)+1}{\sqrt {c+d \tan (e+f x)}}dx}{2 a^2 (-d+i c)}+\frac {a^2 \left (2 i c^2-7 c d-10 i d^2\right ) \sqrt {c+d \tan (e+f x)}}{f (c+i d) (a+i a \tan (e+f x))}\right )}{4 a^2 (-d+i c)}-\frac {a (3 c+8 i d) \sqrt {c+d \tan (e+f x)}}{2 f (c+i d) (a+i a \tan (e+f x))^2}}{12 a^2 (-d+i c)}-\frac {\sqrt {c+d \tan (e+f x)}}{6 f (-d+i c) (a+i a \tan (e+f x))^3}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {-\frac {3 \left (\frac {a^3 \left (2 i c^3-8 c^2 d-13 i c d^2+12 d^3\right ) \int \frac {1-i \tan (e+f x)}{\sqrt {c+d \tan (e+f x)}}dx-2 a^3 (-d+i c)^3 \int \frac {i \tan (e+f x)+1}{\sqrt {c+d \tan (e+f x)}}dx}{2 a^2 (-d+i c)}+\frac {a^2 \left (2 i c^2-7 c d-10 i d^2\right ) \sqrt {c+d \tan (e+f x)}}{f (c+i d) (a+i a \tan (e+f x))}\right )}{4 a^2 (-d+i c)}-\frac {a (3 c+8 i d) \sqrt {c+d \tan (e+f x)}}{2 f (c+i d) (a+i a \tan (e+f x))^2}}{12 a^2 (-d+i c)}-\frac {\sqrt {c+d \tan (e+f x)}}{6 f (-d+i c) (a+i a \tan (e+f x))^3}\)

\(\Big \downarrow \) 4020

\(\displaystyle \frac {-\frac {3 \left (\frac {-\frac {i a^3 \left (2 i c^3-8 c^2 d-13 i c d^2+12 d^3\right ) \int -\frac {1}{(i \tan (e+f x)+1) \sqrt {c+d \tan (e+f x)}}d(-i \tan (e+f x))}{f}-\frac {2 i a^3 (-d+i c)^3 \int -\frac {1}{(1-i \tan (e+f x)) \sqrt {c+d \tan (e+f x)}}d(i \tan (e+f x))}{f}}{2 a^2 (-d+i c)}+\frac {a^2 \left (2 i c^2-7 c d-10 i d^2\right ) \sqrt {c+d \tan (e+f x)}}{f (c+i d) (a+i a \tan (e+f x))}\right )}{4 a^2 (-d+i c)}-\frac {a (3 c+8 i d) \sqrt {c+d \tan (e+f x)}}{2 f (c+i d) (a+i a \tan (e+f x))^2}}{12 a^2 (-d+i c)}-\frac {\sqrt {c+d \tan (e+f x)}}{6 f (-d+i c) (a+i a \tan (e+f x))^3}\)

\(\Big \downarrow \) 25

\(\displaystyle \frac {-\frac {3 \left (\frac {\frac {i a^3 \left (2 i c^3-8 c^2 d-13 i c d^2+12 d^3\right ) \int \frac {1}{(i \tan (e+f x)+1) \sqrt {c+d \tan (e+f x)}}d(-i \tan (e+f x))}{f}+\frac {2 i a^3 (-d+i c)^3 \int \frac {1}{(1-i \tan (e+f x)) \sqrt {c+d \tan (e+f x)}}d(i \tan (e+f x))}{f}}{2 a^2 (-d+i c)}+\frac {a^2 \left (2 i c^2-7 c d-10 i d^2\right ) \sqrt {c+d \tan (e+f x)}}{f (c+i d) (a+i a \tan (e+f x))}\right )}{4 a^2 (-d+i c)}-\frac {a (3 c+8 i d) \sqrt {c+d \tan (e+f x)}}{2 f (c+i d) (a+i a \tan (e+f x))^2}}{12 a^2 (-d+i c)}-\frac {\sqrt {c+d \tan (e+f x)}}{6 f (-d+i c) (a+i a \tan (e+f x))^3}\)

\(\Big \downarrow \) 73

\(\displaystyle \frac {-\frac {3 \left (\frac {\frac {2 a^3 \left (2 i c^3-8 c^2 d-13 i c d^2+12 d^3\right ) \int \frac {1}{-\frac {i \tan ^2(e+f x)}{d}-\frac {i c}{d}+1}d\sqrt {c+d \tan (e+f x)}}{d f}-\frac {4 a^3 (-d+i c)^3 \int \frac {1}{\frac {i \tan ^2(e+f x)}{d}+\frac {i c}{d}+1}d\sqrt {c+d \tan (e+f x)}}{d f}}{2 a^2 (-d+i c)}+\frac {a^2 \left (2 i c^2-7 c d-10 i d^2\right ) \sqrt {c+d \tan (e+f x)}}{f (c+i d) (a+i a \tan (e+f x))}\right )}{4 a^2 (-d+i c)}-\frac {a (3 c+8 i d) \sqrt {c+d \tan (e+f x)}}{2 f (c+i d) (a+i a \tan (e+f x))^2}}{12 a^2 (-d+i c)}-\frac {\sqrt {c+d \tan (e+f x)}}{6 f (-d+i c) (a+i a \tan (e+f x))^3}\)

\(\Big \downarrow \) 221

\(\displaystyle \frac {-\frac {3 \left (\frac {a^2 \left (2 i c^2-7 c d-10 i d^2\right ) \sqrt {c+d \tan (e+f x)}}{f (c+i d) (a+i a \tan (e+f x))}+\frac {\frac {2 a^3 \left (2 i c^3-8 c^2 d-13 i c d^2+12 d^3\right ) \arctan \left (\frac {\tan (e+f x)}{\sqrt {c+i d}}\right )}{f \sqrt {c+i d}}-\frac {4 a^3 (-d+i c)^3 \arctan \left (\frac {\tan (e+f x)}{\sqrt {c-i d}}\right )}{f \sqrt {c-i d}}}{2 a^2 (-d+i c)}\right )}{4 a^2 (-d+i c)}-\frac {a (3 c+8 i d) \sqrt {c+d \tan (e+f x)}}{2 f (c+i d) (a+i a \tan (e+f x))^2}}{12 a^2 (-d+i c)}-\frac {\sqrt {c+d \tan (e+f x)}}{6 f (-d+i c) (a+i a \tan (e+f x))^3}\)

Input:

Int[1/((a + I*a*Tan[e + f*x])^3*Sqrt[c + d*Tan[e + f*x]]),x]
 

Output:

-1/6*Sqrt[c + d*Tan[e + f*x]]/((I*c - d)*f*(a + I*a*Tan[e + f*x])^3) + (-1 
/2*(a*(3*c + (8*I)*d)*Sqrt[c + d*Tan[e + f*x]])/((c + I*d)*f*(a + I*a*Tan[ 
e + f*x])^2) - (3*(((-4*a^3*(I*c - d)^3*ArcTan[Tan[e + f*x]/Sqrt[c - I*d]] 
)/(Sqrt[c - I*d]*f) + (2*a^3*((2*I)*c^3 - 8*c^2*d - (13*I)*c*d^2 + 12*d^3) 
*ArcTan[Tan[e + f*x]/Sqrt[c + I*d]])/(Sqrt[c + I*d]*f))/(2*a^2*(I*c - d)) 
+ (a^2*((2*I)*c^2 - 7*c*d - (10*I)*d^2)*Sqrt[c + d*Tan[e + f*x]])/((c + I* 
d)*f*(a + I*a*Tan[e + f*x]))))/(4*a^2*(I*c - d)))/(12*a^2*(I*c - d))
 

Defintions of rubi rules used

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

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 73
Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_), x_Symbol] :> With[ 
{p = Denominator[m]}, Simp[p/b   Subst[Int[x^(p*(m + 1) - 1)*(c - a*(d/b) + 
 d*(x^p/b))^n, x], x, (a + b*x)^(1/p)], x]] /; FreeQ[{a, b, c, d}, x] && Lt 
Q[-1, m, 0] && LeQ[-1, n, 0] && LeQ[Denominator[n], Denominator[m]] && IntL 
inearQ[a, b, c, d, m, n, x]
 

rule 221
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[-a/b, 2]/a)*ArcTanh[x 
/Rt[-a/b, 2]], x] /; FreeQ[{a, b}, x] && NegQ[a/b]
 

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

rule 4020
Int[((a_.) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(m_)*((c_) + (d_.)*tan[(e_.) + 
(f_.)*(x_)]), x_Symbol] :> Simp[c*(d/f)   Subst[Int[(a + (b/d)*x)^m/(d^2 + 
c*x), x], x, d*Tan[e + f*x]], x] /; FreeQ[{a, b, c, d, e, f, m}, x] && NeQ[ 
b*c - a*d, 0] && NeQ[a^2 + b^2, 0] && EqQ[c^2 + d^2, 0]
 

rule 4022
Int[((a_.) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(m_)*((c_.) + (d_.)*tan[(e_.) + 
 (f_.)*(x_)]), x_Symbol] :> Simp[(c + I*d)/2   Int[(a + b*Tan[e + f*x])^m*( 
1 - I*Tan[e + f*x]), x], x] + Simp[(c - I*d)/2   Int[(a + b*Tan[e + f*x])^m 
*(1 + I*Tan[e + f*x]), x], x] /; FreeQ[{a, b, c, d, e, f, m}, x] && NeQ[b*c 
 - a*d, 0] && NeQ[a^2 + b^2, 0] && NeQ[c^2 + d^2, 0] &&  !IntegerQ[m]
 

rule 4042
Int[((a_) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(m_)*((c_.) + (d_.)*tan[(e_.) + 
(f_.)*(x_)])^(n_), x_Symbol] :> Simp[a*(a + b*Tan[e + f*x])^m*((c + d*Tan[e 
 + f*x])^(n + 1)/(2*f*m*(b*c - a*d))), x] + Simp[1/(2*a*m*(b*c - a*d))   In 
t[(a + b*Tan[e + f*x])^(m + 1)*(c + d*Tan[e + f*x])^n*Simp[b*c*m - a*d*(2*m 
 + n + 1) + b*d*(m + n + 1)*Tan[e + f*x], x], x], x] /; FreeQ[{a, b, c, d, 
e, f, n}, x] && NeQ[b*c - a*d, 0] && EqQ[a^2 + b^2, 0] && NeQ[c^2 + d^2, 0] 
 && LtQ[m, 0] && (IntegerQ[m] || IntegersQ[2*m, 2*n])
 

rule 4079
Int[((a_) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(m_)*((A_.) + (B_.)*tan[(e_.) + 
(f_.)*(x_)])*((c_.) + (d_.)*tan[(e_.) + (f_.)*(x_)])^(n_), x_Symbol] :> Sim 
p[(a*A + b*B)*(a + b*Tan[e + f*x])^m*((c + d*Tan[e + f*x])^(n + 1)/(2*f*m*( 
b*c - a*d))), x] + Simp[1/(2*a*m*(b*c - a*d))   Int[(a + b*Tan[e + f*x])^(m 
 + 1)*(c + d*Tan[e + f*x])^n*Simp[A*(b*c*m - a*d*(2*m + n + 1)) + B*(a*c*m 
- b*d*(n + 1)) + d*(A*b - a*B)*(m + n + 1)*Tan[e + f*x], x], x], x] /; Free 
Q[{a, b, c, d, e, f, A, B, n}, x] && NeQ[b*c - a*d, 0] && EqQ[a^2 + b^2, 0] 
 && LtQ[m, 0] &&  !GtQ[n, 0]
 
Maple [A] (verified)

Time = 0.48 (sec) , antiderivative size = 357, normalized size of antiderivative = 1.20

method result size
derivativedivides \(\frac {2 d^{4} \left (\frac {\frac {-\frac {d \left (7 i c d +2 c^{2}-10 d^{2}\right ) \left (c +d \tan \left (f x +e \right )\right )^{\frac {5}{2}}}{2 \left (3 i c^{2} d -i d^{3}+c^{3}-3 c \,d^{2}\right )}+\frac {2 d \left (15 i c^{2} d -19 i d^{3}+3 c^{3}-31 c \,d^{2}\right ) \left (c +d \tan \left (f x +e \right )\right )^{\frac {3}{2}}}{3 \left (3 i c^{2} d -i d^{3}+c^{3}-3 c \,d^{2}\right )}-\frac {d \left (13 i c^{3} d -45 i c \,d^{3}+2 c^{4}-38 c^{2} d^{2}+18 d^{4}\right ) \sqrt {c +d \tan \left (f x +e \right )}}{2 \left (3 i c^{2} d -i d^{3}+c^{3}-3 c \,d^{2}\right )}}{\left (-d \tan \left (f x +e \right )+i d \right )^{3}}-\frac {\left (2 i c^{3}-13 i c \,d^{2}-8 c^{2} d +12 d^{3}\right ) \arctan \left (\frac {\sqrt {c +d \tan \left (f x +e \right )}}{\sqrt {-i d -c}}\right )}{2 \left (3 i c^{2} d -i d^{3}+c^{3}-3 c \,d^{2}\right ) \sqrt {-i d -c}}}{16 d^{4}}+\frac {i \arctan \left (\frac {\sqrt {c +d \tan \left (f x +e \right )}}{\sqrt {i d -c}}\right )}{16 d^{4} \sqrt {i d -c}}\right )}{f \,a^{3}}\) \(357\)
default \(\frac {2 d^{4} \left (\frac {\frac {-\frac {d \left (7 i c d +2 c^{2}-10 d^{2}\right ) \left (c +d \tan \left (f x +e \right )\right )^{\frac {5}{2}}}{2 \left (3 i c^{2} d -i d^{3}+c^{3}-3 c \,d^{2}\right )}+\frac {2 d \left (15 i c^{2} d -19 i d^{3}+3 c^{3}-31 c \,d^{2}\right ) \left (c +d \tan \left (f x +e \right )\right )^{\frac {3}{2}}}{3 \left (3 i c^{2} d -i d^{3}+c^{3}-3 c \,d^{2}\right )}-\frac {d \left (13 i c^{3} d -45 i c \,d^{3}+2 c^{4}-38 c^{2} d^{2}+18 d^{4}\right ) \sqrt {c +d \tan \left (f x +e \right )}}{2 \left (3 i c^{2} d -i d^{3}+c^{3}-3 c \,d^{2}\right )}}{\left (-d \tan \left (f x +e \right )+i d \right )^{3}}-\frac {\left (2 i c^{3}-13 i c \,d^{2}-8 c^{2} d +12 d^{3}\right ) \arctan \left (\frac {\sqrt {c +d \tan \left (f x +e \right )}}{\sqrt {-i d -c}}\right )}{2 \left (3 i c^{2} d -i d^{3}+c^{3}-3 c \,d^{2}\right ) \sqrt {-i d -c}}}{16 d^{4}}+\frac {i \arctan \left (\frac {\sqrt {c +d \tan \left (f x +e \right )}}{\sqrt {i d -c}}\right )}{16 d^{4} \sqrt {i d -c}}\right )}{f \,a^{3}}\) \(357\)

Input:

int(1/(a+I*a*tan(f*x+e))^3/(c+d*tan(f*x+e))^(1/2),x,method=_RETURNVERBOSE)
 

Output:

2/f/a^3*d^4*(1/16/d^4*((-1/2*d*(2*c^2+7*I*c*d-10*d^2)/(3*I*c^2*d-I*d^3+c^3 
-3*c*d^2)*(c+d*tan(f*x+e))^(5/2)+2/3*d*(-31*c*d^2+15*I*c^2*d-19*I*d^3+3*c^ 
3)/(3*I*c^2*d-I*d^3+c^3-3*c*d^2)*(c+d*tan(f*x+e))^(3/2)-1/2*d*(13*I*c^3*d- 
45*I*c*d^3+2*c^4-38*c^2*d^2+18*d^4)/(3*I*c^2*d-I*d^3+c^3-3*c*d^2)*(c+d*tan 
(f*x+e))^(1/2))/(-d*tan(f*x+e)+I*d)^3-1/2*(2*I*c^3-8*c^2*d-13*I*c*d^2+12*d 
^3)/(3*I*c^2*d-I*d^3+c^3-3*c*d^2)/(-c-I*d)^(1/2)*arctan((c+d*tan(f*x+e))^( 
1/2)/(-c-I*d)^(1/2)))+1/16*I/d^4/(I*d-c)^(1/2)*arctan((c+d*tan(f*x+e))^(1/ 
2)/(I*d-c)^(1/2)))
 

Fricas [B] (verification not implemented)

Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 1747 vs. \(2 (240) = 480\).

Time = 0.48 (sec) , antiderivative size = 1747, normalized size of antiderivative = 5.86 \[ \int \frac {1}{(a+i a \tan (e+f x))^3 \sqrt {c+d \tan (e+f x)}} \, dx=\text {Too large to display} \] Input:

integrate(1/(a+I*a*tan(f*x+e))^3/(c+d*tan(f*x+e))^(1/2),x, algorithm="fric 
as")
 

Output:

1/192*(48*(I*a^3*c^3 - 3*a^3*c^2*d - 3*I*a^3*c*d^2 + a^3*d^3)*f*sqrt(1/64* 
I/((-I*a^6*c - a^6*d)*f^2))*e^(6*I*f*x + 6*I*e)*log(-2*(8*((I*a^3*c + a^3* 
d)*f*e^(2*I*f*x + 2*I*e) + (I*a^3*c + a^3*d)*f)*sqrt(((c - I*d)*e^(2*I*f*x 
 + 2*I*e) + c + I*d)/(e^(2*I*f*x + 2*I*e) + 1))*sqrt(1/64*I/((-I*a^6*c - a 
^6*d)*f^2)) - (c - I*d)*e^(2*I*f*x + 2*I*e) - c)*e^(-2*I*f*x - 2*I*e)) + 4 
8*(-I*a^3*c^3 + 3*a^3*c^2*d + 3*I*a^3*c*d^2 - a^3*d^3)*f*sqrt(1/64*I/((-I* 
a^6*c - a^6*d)*f^2))*e^(6*I*f*x + 6*I*e)*log(-2*(8*((-I*a^3*c - a^3*d)*f*e 
^(2*I*f*x + 2*I*e) + (-I*a^3*c - a^3*d)*f)*sqrt(((c - I*d)*e^(2*I*f*x + 2* 
I*e) + c + I*d)/(e^(2*I*f*x + 2*I*e) + 1))*sqrt(1/64*I/((-I*a^6*c - a^6*d) 
*f^2)) - (c - I*d)*e^(2*I*f*x + 2*I*e) - c)*e^(-2*I*f*x - 2*I*e)) + 3*(-I* 
a^3*c^3 + 3*a^3*c^2*d + 3*I*a^3*c*d^2 - a^3*d^3)*f*sqrt(-(-4*I*c^6 + 32*c^ 
5*d + 116*I*c^4*d^2 - 256*c^3*d^3 - 361*I*c^2*d^4 + 312*c*d^5 + 144*I*d^6) 
/((-I*a^6*c^7 + 7*a^6*c^6*d + 21*I*a^6*c^5*d^2 - 35*a^6*c^4*d^3 - 35*I*a^6 
*c^3*d^4 + 21*a^6*c^2*d^5 + 7*I*a^6*c*d^6 - a^6*d^7)*f^2))*e^(6*I*f*x + 6* 
I*e)*log(1/16*(2*I*c^4 - 10*c^3*d - 21*I*c^2*d^2 + 25*c*d^3 + 12*I*d^4 + ( 
(a^3*c^4 + 4*I*a^3*c^3*d - 6*a^3*c^2*d^2 - 4*I*a^3*c*d^3 + a^3*d^4)*f*e^(2 
*I*f*x + 2*I*e) + (a^3*c^4 + 4*I*a^3*c^3*d - 6*a^3*c^2*d^2 - 4*I*a^3*c*d^3 
 + a^3*d^4)*f)*sqrt(((c - I*d)*e^(2*I*f*x + 2*I*e) + c + I*d)/(e^(2*I*f*x 
+ 2*I*e) + 1))*sqrt(-(-4*I*c^6 + 32*c^5*d + 116*I*c^4*d^2 - 256*c^3*d^3 - 
361*I*c^2*d^4 + 312*c*d^5 + 144*I*d^6)/((-I*a^6*c^7 + 7*a^6*c^6*d + 21*...
 

Sympy [F]

\[ \int \frac {1}{(a+i a \tan (e+f x))^3 \sqrt {c+d \tan (e+f x)}} \, dx=\frac {i \int \frac {1}{\sqrt {c + d \tan {\left (e + f x \right )}} \tan ^{3}{\left (e + f x \right )} - 3 i \sqrt {c + d \tan {\left (e + f x \right )}} \tan ^{2}{\left (e + f x \right )} - 3 \sqrt {c + d \tan {\left (e + f x \right )}} \tan {\left (e + f x \right )} + i \sqrt {c + d \tan {\left (e + f x \right )}}}\, dx}{a^{3}} \] Input:

integrate(1/(a+I*a*tan(f*x+e))**3/(c+d*tan(f*x+e))**(1/2),x)
 

Output:

I*Integral(1/(sqrt(c + d*tan(e + f*x))*tan(e + f*x)**3 - 3*I*sqrt(c + d*ta 
n(e + f*x))*tan(e + f*x)**2 - 3*sqrt(c + d*tan(e + f*x))*tan(e + f*x) + I* 
sqrt(c + d*tan(e + f*x))), x)/a**3
                                                                                    
                                                                                    
 

Maxima [F(-2)]

Exception generated. \[ \int \frac {1}{(a+i a \tan (e+f x))^3 \sqrt {c+d \tan (e+f x)}} \, dx=\text {Exception raised: RuntimeError} \] Input:

integrate(1/(a+I*a*tan(f*x+e))^3/(c+d*tan(f*x+e))^(1/2),x, algorithm="maxi 
ma")
 

Output:

Exception raised: RuntimeError >> ECL says: expt: undefined: 0 to a negati 
ve exponent.
 

Giac [B] (verification not implemented)

Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 625 vs. \(2 (240) = 480\).

Time = 0.57 (sec) , antiderivative size = 625, normalized size of antiderivative = 2.10 \[ \int \frac {1}{(a+i a \tan (e+f x))^3 \sqrt {c+d \tan (e+f x)}} \, dx=-\frac {i \, {\left (\frac {3 \, \sqrt {2} {\left (2 \, c^{3} + 8 i \, c^{2} d - 13 \, c d^{2} - 12 i \, d^{3}\right )} \arctan \left (\frac {2 \, {\left (\sqrt {d \tan \left (f x + e\right ) + c} c - \sqrt {c^{2} + d^{2}} \sqrt {d \tan \left (f x + e\right ) + c}\right )}}{\sqrt {2} c \sqrt {-c + \sqrt {c^{2} + d^{2}}} + i \, \sqrt {2} \sqrt {-c + \sqrt {c^{2} + d^{2}}} d - \sqrt {2} \sqrt {c^{2} + d^{2}} \sqrt {-c + \sqrt {c^{2} + d^{2}}}}\right )}{{\left (c^{3} + 3 i \, c^{2} d - 3 \, c d^{2} - i \, d^{3}\right )} \sqrt {-c + \sqrt {c^{2} + d^{2}}} {\left (\frac {i \, d}{c - \sqrt {c^{2} + d^{2}}} + 1\right )}} - \frac {6 \, \sqrt {2} \arctan \left (\frac {2 \, {\left (\sqrt {d \tan \left (f x + e\right ) + c} c - \sqrt {c^{2} + d^{2}} \sqrt {d \tan \left (f x + e\right ) + c}\right )}}{\sqrt {2} c \sqrt {-c + \sqrt {c^{2} + d^{2}}} - i \, \sqrt {2} \sqrt {-c + \sqrt {c^{2} + d^{2}}} d - \sqrt {2} \sqrt {c^{2} + d^{2}} \sqrt {-c + \sqrt {c^{2} + d^{2}}}}\right )}{\sqrt {-c + \sqrt {c^{2} + d^{2}}} {\left (-\frac {i \, d}{c - \sqrt {c^{2} + d^{2}}} + 1\right )}} + \frac {6 i \, {\left (d \tan \left (f x + e\right ) + c\right )}^{\frac {5}{2}} c^{2} d - 12 i \, {\left (d \tan \left (f x + e\right ) + c\right )}^{\frac {3}{2}} c^{3} d + 6 i \, \sqrt {d \tan \left (f x + e\right ) + c} c^{4} d - 21 \, {\left (d \tan \left (f x + e\right ) + c\right )}^{\frac {5}{2}} c d^{2} + 60 \, {\left (d \tan \left (f x + e\right ) + c\right )}^{\frac {3}{2}} c^{2} d^{2} - 39 \, \sqrt {d \tan \left (f x + e\right ) + c} c^{3} d^{2} - 30 i \, {\left (d \tan \left (f x + e\right ) + c\right )}^{\frac {5}{2}} d^{3} + 124 i \, {\left (d \tan \left (f x + e\right ) + c\right )}^{\frac {3}{2}} c d^{3} - 114 i \, \sqrt {d \tan \left (f x + e\right ) + c} c^{2} d^{3} - 76 \, {\left (d \tan \left (f x + e\right ) + c\right )}^{\frac {3}{2}} d^{4} + 135 \, \sqrt {d \tan \left (f x + e\right ) + c} c d^{4} + 54 i \, \sqrt {d \tan \left (f x + e\right ) + c} d^{5}}{{\left (c^{3} + 3 i \, c^{2} d - 3 \, c d^{2} - i \, d^{3}\right )} {\left (d \tan \left (f x + e\right ) - i \, d\right )}^{3}}\right )}}{48 \, a^{3} f} \] Input:

integrate(1/(a+I*a*tan(f*x+e))^3/(c+d*tan(f*x+e))^(1/2),x, algorithm="giac 
")
 

Output:

-1/48*I*(3*sqrt(2)*(2*c^3 + 8*I*c^2*d - 13*c*d^2 - 12*I*d^3)*arctan(2*(sqr 
t(d*tan(f*x + e) + c)*c - sqrt(c^2 + d^2)*sqrt(d*tan(f*x + e) + c))/(sqrt( 
2)*c*sqrt(-c + sqrt(c^2 + d^2)) + I*sqrt(2)*sqrt(-c + sqrt(c^2 + d^2))*d - 
 sqrt(2)*sqrt(c^2 + d^2)*sqrt(-c + sqrt(c^2 + d^2))))/((c^3 + 3*I*c^2*d - 
3*c*d^2 - I*d^3)*sqrt(-c + sqrt(c^2 + d^2))*(I*d/(c - sqrt(c^2 + d^2)) + 1 
)) - 6*sqrt(2)*arctan(2*(sqrt(d*tan(f*x + e) + c)*c - sqrt(c^2 + d^2)*sqrt 
(d*tan(f*x + e) + c))/(sqrt(2)*c*sqrt(-c + sqrt(c^2 + d^2)) - I*sqrt(2)*sq 
rt(-c + sqrt(c^2 + d^2))*d - sqrt(2)*sqrt(c^2 + d^2)*sqrt(-c + sqrt(c^2 + 
d^2))))/(sqrt(-c + sqrt(c^2 + d^2))*(-I*d/(c - sqrt(c^2 + d^2)) + 1)) + (6 
*I*(d*tan(f*x + e) + c)^(5/2)*c^2*d - 12*I*(d*tan(f*x + e) + c)^(3/2)*c^3* 
d + 6*I*sqrt(d*tan(f*x + e) + c)*c^4*d - 21*(d*tan(f*x + e) + c)^(5/2)*c*d 
^2 + 60*(d*tan(f*x + e) + c)^(3/2)*c^2*d^2 - 39*sqrt(d*tan(f*x + e) + c)*c 
^3*d^2 - 30*I*(d*tan(f*x + e) + c)^(5/2)*d^3 + 124*I*(d*tan(f*x + e) + c)^ 
(3/2)*c*d^3 - 114*I*sqrt(d*tan(f*x + e) + c)*c^2*d^3 - 76*(d*tan(f*x + e) 
+ c)^(3/2)*d^4 + 135*sqrt(d*tan(f*x + e) + c)*c*d^4 + 54*I*sqrt(d*tan(f*x 
+ e) + c)*d^5)/((c^3 + 3*I*c^2*d - 3*c*d^2 - I*d^3)*(d*tan(f*x + e) - I*d) 
^3))/(a^3*f)
 

Mupad [B] (verification not implemented)

Time = 8.07 (sec) , antiderivative size = 60949, normalized size of antiderivative = 204.53 \[ \int \frac {1}{(a+i a \tan (e+f x))^3 \sqrt {c+d \tan (e+f x)}} \, dx=\text {Too large to display} \] Input:

int(1/((a + a*tan(e + f*x)*1i)^3*(c + d*tan(e + f*x))^(1/2)),x)
 

Output:

log(a^3*d^14*f*240i - ((-(140*d^11 - c*d^10*140i + 35*c^2*d^9 - c^3*d^8*24 
5i - 280*c^4*d^7 + c^5*d^6*168i + 56*c^6*d^5 - c^7*d^4*8i - a^6*c^6*f^2*(4 
*(256*d^6 + 256*c^2*d^4)*(((649*c^2*d^14)/1024 - (9*d^16)/64 + (85*c^4*d^1 
2)/1024 + (119*c^6*d^10)/1024 + (15*c^8*d^8)/1024 - (c^10*d^6)/64 - (c^12* 
d^4)/256)/(a^12*c^12*f^4 + a^12*d^12*f^4 + 6*a^12*c^2*d^10*f^4 + 15*a^12*c 
^4*d^8*f^4 + 20*a^12*c^6*d^6*f^4 + 15*a^12*c^8*d^4*f^4 + 6*a^12*c^10*d^2*f 
^4) - (((69*c*d^15)/128 - (55*c^3*d^13)/512 + (57*c^5*d^11)/256 + (61*c^7* 
d^9)/512 + (5*c^9*d^7)/128 + (c^11*d^5)/128)*1i)/(a^12*c^12*f^4 + a^12*d^1 
2*f^4 + 6*a^12*c^2*d^10*f^4 + 15*a^12*c^4*d^8*f^4 + 20*a^12*c^6*d^6*f^4 + 
15*a^12*c^8*d^4*f^4 + 6*a^12*c^10*d^2*f^4)) + ((((1225*c^2*d^15)/4 - 35*d^ 
17 + (35*c^4*d^13)/4 + (427*c^6*d^11)/4 + (197*c^8*d^9)/4 + 12*c^10*d^7 + 
2*c^12*d^5)*1i)/(a^6*c^12*f^2 + a^6*d^12*f^2 + 6*a^6*c^2*d^10*f^2 + 15*a^6 
*c^4*d^8*f^2 + 20*a^6*c^6*d^6*f^2 + 15*a^6*c^8*d^4*f^2 + 6*a^6*c^10*d^2*f^ 
2) + (175*c*d^16 - (735*c^3*d^14)/4 + (203*c^5*d^12)/4 + (83*c^7*d^10)/4 + 
 (85*c^9*d^8)/4 + 12*c^11*d^6 + 2*c^13*d^4)/(a^6*c^12*f^2 + a^6*d^12*f^2 + 
 6*a^6*c^2*d^10*f^2 + 15*a^6*c^4*d^8*f^2 + 20*a^6*c^6*d^6*f^2 + 15*a^6*c^8 
*d^4*f^2 + 6*a^6*c^10*d^2*f^2))^2)^(1/2)*4i + a^6*d^6*f^2*(4*(256*d^6 + 25 
6*c^2*d^4)*(((649*c^2*d^14)/1024 - (9*d^16)/64 + (85*c^4*d^12)/1024 + (119 
*c^6*d^10)/1024 + (15*c^8*d^8)/1024 - (c^10*d^6)/64 - (c^12*d^4)/256)/(a^1 
2*c^12*f^4 + a^12*d^12*f^4 + 6*a^12*c^2*d^10*f^4 + 15*a^12*c^4*d^8*f^4 ...
 

Reduce [F]

\[ \int \frac {1}{(a+i a \tan (e+f x))^3 \sqrt {c+d \tan (e+f x)}} \, dx=\int \frac {1}{\left (a +i a \tan \left (f x +e \right )\right )^{3} \sqrt {d \tan \left (f x +e \right )+c}}d x \] Input:

int(1/(a+I*a*tan(f*x+e))^3/(c+d*tan(f*x+e))^(1/2),x)
 

Output:

int(1/(a+I*a*tan(f*x+e))^3/(c+d*tan(f*x+e))^(1/2),x)