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

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

Optimal result

Integrand size = 24, antiderivative size = 157 \[ \int \frac {\cos (c+d x)}{(a+i a \tan (c+d x))^{3/2}} \, dx=\frac {15 i \text {arctanh}\left (\frac {\sqrt {a} \sec (c+d x)}{\sqrt {2} \sqrt {a+i a \tan (c+d x)}}\right )}{32 \sqrt {2} a^{3/2} d}+\frac {i \cos (c+d x)}{4 d (a+i a \tan (c+d x))^{3/2}}+\frac {5 i \cos (c+d x)}{16 a d \sqrt {a+i a \tan (c+d x)}}-\frac {15 i \cos (c+d x) \sqrt {a+i a \tan (c+d x)}}{32 a^2 d} \] Output:

15/64*I*arctanh(1/2*a^(1/2)*sec(d*x+c)*2^(1/2)/(a+I*a*tan(d*x+c))^(1/2))*2 
^(1/2)/a^(3/2)/d+1/4*I*cos(d*x+c)/d/(a+I*a*tan(d*x+c))^(3/2)+5/16*I*cos(d* 
x+c)/a/d/(a+I*a*tan(d*x+c))^(1/2)-15/32*I*cos(d*x+c)*(a+I*a*tan(d*x+c))^(1 
/2)/a^2/d
 

Mathematica [A] (verified)

Time = 1.00 (sec) , antiderivative size = 120, normalized size of antiderivative = 0.76 \[ \int \frac {\cos (c+d x)}{(a+i a \tan (c+d x))^{3/2}} \, dx=\frac {\sec (c+d x) \left (\frac {30 e^{2 i (c+d x)} \text {arctanh}\left (\sqrt {1+e^{2 i (c+d x)}}\right )}{\sqrt {1+e^{2 i (c+d x)}}}-2 (-9+6 \cos (2 (c+d x))+10 i \sin (2 (c+d x)))\right )}{64 a d (-i+\tan (c+d x)) \sqrt {a+i a \tan (c+d x)}} \] Input:

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

Output:

(Sec[c + d*x]*((30*E^((2*I)*(c + d*x))*ArcTanh[Sqrt[1 + E^((2*I)*(c + d*x) 
)]])/Sqrt[1 + E^((2*I)*(c + d*x))] - 2*(-9 + 6*Cos[2*(c + d*x)] + (10*I)*S 
in[2*(c + d*x)])))/(64*a*d*(-I + Tan[c + d*x])*Sqrt[a + I*a*Tan[c + d*x]])
 

Rubi [A] (verified)

Time = 0.68 (sec) , antiderivative size = 163, normalized size of antiderivative = 1.04, number of steps used = 10, number of rules used = 9, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.375, Rules used = {3042, 3983, 3042, 3983, 3042, 3971, 3042, 3970, 219}

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

\(\Big \downarrow \) 3042

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

\(\Big \downarrow \) 3983

\(\displaystyle \frac {5 \int \frac {\cos (c+d x)}{\sqrt {i \tan (c+d x) a+a}}dx}{8 a}+\frac {i \cos (c+d x)}{4 d (a+i a \tan (c+d x))^{3/2}}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {5 \int \frac {1}{\sec (c+d x) \sqrt {i \tan (c+d x) a+a}}dx}{8 a}+\frac {i \cos (c+d x)}{4 d (a+i a \tan (c+d x))^{3/2}}\)

\(\Big \downarrow \) 3983

\(\displaystyle \frac {5 \left (\frac {3 \int \cos (c+d x) \sqrt {i \tan (c+d x) a+a}dx}{4 a}+\frac {i \cos (c+d x)}{2 d \sqrt {a+i a \tan (c+d x)}}\right )}{8 a}+\frac {i \cos (c+d x)}{4 d (a+i a \tan (c+d x))^{3/2}}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {5 \left (\frac {3 \int \frac {\sqrt {i \tan (c+d x) a+a}}{\sec (c+d x)}dx}{4 a}+\frac {i \cos (c+d x)}{2 d \sqrt {a+i a \tan (c+d x)}}\right )}{8 a}+\frac {i \cos (c+d x)}{4 d (a+i a \tan (c+d x))^{3/2}}\)

\(\Big \downarrow \) 3971

\(\displaystyle \frac {5 \left (\frac {3 \left (\frac {1}{2} a \int \frac {\sec (c+d x)}{\sqrt {i \tan (c+d x) a+a}}dx-\frac {i \cos (c+d x) \sqrt {a+i a \tan (c+d x)}}{d}\right )}{4 a}+\frac {i \cos (c+d x)}{2 d \sqrt {a+i a \tan (c+d x)}}\right )}{8 a}+\frac {i \cos (c+d x)}{4 d (a+i a \tan (c+d x))^{3/2}}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {5 \left (\frac {3 \left (\frac {1}{2} a \int \frac {\sec (c+d x)}{\sqrt {i \tan (c+d x) a+a}}dx-\frac {i \cos (c+d x) \sqrt {a+i a \tan (c+d x)}}{d}\right )}{4 a}+\frac {i \cos (c+d x)}{2 d \sqrt {a+i a \tan (c+d x)}}\right )}{8 a}+\frac {i \cos (c+d x)}{4 d (a+i a \tan (c+d x))^{3/2}}\)

\(\Big \downarrow \) 3970

\(\displaystyle \frac {5 \left (\frac {3 \left (\frac {i a \int \frac {1}{2-\frac {a \sec ^2(c+d x)}{i \tan (c+d x) a+a}}d\frac {\sec (c+d x)}{\sqrt {i \tan (c+d x) a+a}}}{d}-\frac {i \cos (c+d x) \sqrt {a+i a \tan (c+d x)}}{d}\right )}{4 a}+\frac {i \cos (c+d x)}{2 d \sqrt {a+i a \tan (c+d x)}}\right )}{8 a}+\frac {i \cos (c+d x)}{4 d (a+i a \tan (c+d x))^{3/2}}\)

\(\Big \downarrow \) 219

\(\displaystyle \frac {5 \left (\frac {3 \left (\frac {i \sqrt {a} \text {arctanh}\left (\frac {\sqrt {a} \sec (c+d x)}{\sqrt {2} \sqrt {a+i a \tan (c+d x)}}\right )}{\sqrt {2} d}-\frac {i \cos (c+d x) \sqrt {a+i a \tan (c+d x)}}{d}\right )}{4 a}+\frac {i \cos (c+d x)}{2 d \sqrt {a+i a \tan (c+d x)}}\right )}{8 a}+\frac {i \cos (c+d x)}{4 d (a+i a \tan (c+d x))^{3/2}}\)

Input:

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

Output:

((I/4)*Cos[c + d*x])/(d*(a + I*a*Tan[c + d*x])^(3/2)) + (5*(((I/2)*Cos[c + 
 d*x])/(d*Sqrt[a + I*a*Tan[c + d*x]]) + (3*((I*Sqrt[a]*ArcTanh[(Sqrt[a]*Se 
c[c + d*x])/(Sqrt[2]*Sqrt[a + I*a*Tan[c + d*x]])])/(Sqrt[2]*d) - (I*Cos[c 
+ d*x]*Sqrt[a + I*a*Tan[c + d*x]])/d))/(4*a)))/(8*a)
 

Defintions of rubi rules used

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

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

rule 3970
Int[sec[(e_.) + (f_.)*(x_)]/Sqrt[(a_) + (b_.)*tan[(e_.) + (f_.)*(x_)]], x_S 
ymbol] :> Simp[-2*(a/(b*f))   Subst[Int[1/(2 - a*x^2), x], x, Sec[e + f*x]/ 
Sqrt[a + b*Tan[e + f*x]]], x] /; FreeQ[{a, b, e, f}, x] && EqQ[a^2 + b^2, 0 
]
 

rule 3971
Int[((d_.)*sec[(e_.) + (f_.)*(x_)])^(m_.)*((a_) + (b_.)*tan[(e_.) + (f_.)*( 
x_)])^(n_), x_Symbol] :> Simp[b*(d*Sec[e + f*x])^m*((a + b*Tan[e + f*x])^n/ 
(a*f*m)), x] + Simp[a/(2*d^2)   Int[(d*Sec[e + f*x])^(m + 2)*(a + b*Tan[e + 
 f*x])^(n - 1), x], x] /; FreeQ[{a, b, d, e, f}, x] && EqQ[a^2 + b^2, 0] && 
 EqQ[m/2 + n, 0] && GtQ[n, 0]
 

rule 3983
Int[((d_.)*sec[(e_.) + (f_.)*(x_)])^(m_.)*((a_) + (b_.)*tan[(e_.) + (f_.)*( 
x_)])^(n_), x_Symbol] :> Simp[a*(d*Sec[e + f*x])^m*((a + b*Tan[e + f*x])^n/ 
(b*f*(m + 2*n))), x] + Simp[Simplify[m + n]/(a*(m + 2*n))   Int[(d*Sec[e + 
f*x])^m*(a + b*Tan[e + f*x])^(n + 1), x], x] /; FreeQ[{a, b, d, e, f, m}, x 
] && EqQ[a^2 + b^2, 0] && LtQ[n, 0] && NeQ[m + 2*n, 0] && IntegersQ[2*m, 2* 
n]
 
Maple [B] (warning: unable to verify)

Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 373 vs. \(2 (126 ) = 252\).

Time = 9.35 (sec) , antiderivative size = 374, normalized size of antiderivative = 2.38

method result size
default \(-\frac {\operatorname {arctanh}\left (\frac {\left (i-\cot \left (d x +c \right )+\csc \left (d x +c \right )\right ) \sqrt {2}}{2 \sqrt {\cot \left (d x +c \right )^{2}-2 \cot \left (d x +c \right ) \csc \left (d x +c \right )+\csc \left (d x +c \right )^{2}-1}}\right ) \left (-30 \sin \left (d x +c \right )-15 \tan \left (d x +c \right )\right )+i \operatorname {arctanh}\left (\frac {\left (i-\cot \left (d x +c \right )+\csc \left (d x +c \right )\right ) \sqrt {2}}{2 \sqrt {\cot \left (d x +c \right )^{2}-2 \cot \left (d x +c \right ) \csc \left (d x +c \right )+\csc \left (d x +c \right )^{2}-1}}\right ) \left (30 \cos \left (d x +c \right )+15-15 \sec \left (d x +c \right )\right )-30 i \sin \left (d x +c \right ) \sqrt {2}\, \sqrt {-\frac {2 \cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}+\sqrt {2}\, \sqrt {-\frac {2 \cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \left (-30 \cos \left (d x +c \right )+15 \sec \left (d x +c \right )\right )+i \sin \left (d x +c \right ) \left (-40 \cos \left (d x +c \right )+20\right ) \sqrt {-\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}+\left (-24 \cos \left (d x +c \right )^{2}+36 \cos \left (d x +c \right )+30\right ) \sqrt {-\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}}{64 d \left (\cos \left (d x +c \right )+1\right ) \left (-\tan \left (d x +c \right )+i\right ) \sqrt {-\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, a \sqrt {a \left (1+i \tan \left (d x +c \right )\right )}}\) \(374\)

Input:

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

Output:

-1/64/d/(cos(d*x+c)+1)/(-tan(d*x+c)+I)/(-cos(d*x+c)/(cos(d*x+c)+1))^(1/2)/ 
a/(a*(1+I*tan(d*x+c)))^(1/2)*(arctanh(1/2/(cot(d*x+c)^2-2*cot(d*x+c)*csc(d 
*x+c)+csc(d*x+c)^2-1)^(1/2)*(I-cot(d*x+c)+csc(d*x+c))*2^(1/2))*(-30*sin(d* 
x+c)-15*tan(d*x+c))+I*arctanh(1/2/(cot(d*x+c)^2-2*cot(d*x+c)*csc(d*x+c)+cs 
c(d*x+c)^2-1)^(1/2)*(I-cot(d*x+c)+csc(d*x+c))*2^(1/2))*(30*cos(d*x+c)+15-1 
5*sec(d*x+c))-30*I*sin(d*x+c)*2^(1/2)*(-2*cos(d*x+c)/(cos(d*x+c)+1))^(1/2) 
+2^(1/2)*(-2*cos(d*x+c)/(cos(d*x+c)+1))^(1/2)*(-30*cos(d*x+c)+15*sec(d*x+c 
))+I*sin(d*x+c)*(-40*cos(d*x+c)+20)*(-cos(d*x+c)/(cos(d*x+c)+1))^(1/2)+(-2 
4*cos(d*x+c)^2+36*cos(d*x+c)+30)*(-cos(d*x+c)/(cos(d*x+c)+1))^(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. 270 vs. \(2 (118) = 236\).

Time = 0.09 (sec) , antiderivative size = 270, normalized size of antiderivative = 1.72 \[ \int \frac {\cos (c+d x)}{(a+i a \tan (c+d x))^{3/2}} \, dx=\frac {{\left (-15 i \, \sqrt {\frac {1}{2}} a^{2} d \sqrt {\frac {1}{a^{3} d^{2}}} e^{\left (4 i \, d x + 4 i \, c\right )} \log \left (-\frac {15 \, {\left (\sqrt {2} \sqrt {\frac {1}{2}} {\left (i \, a d e^{\left (2 i \, d x + 2 i \, c\right )} + i \, a d\right )} \sqrt {\frac {a}{e^{\left (2 i \, d x + 2 i \, c\right )} + 1}} \sqrt {\frac {1}{a^{3} d^{2}}} - i\right )} e^{\left (-i \, d x - i \, c\right )}}{16 \, a d}\right ) + 15 i \, \sqrt {\frac {1}{2}} a^{2} d \sqrt {\frac {1}{a^{3} d^{2}}} e^{\left (4 i \, d x + 4 i \, c\right )} \log \left (-\frac {15 \, {\left (\sqrt {2} \sqrt {\frac {1}{2}} {\left (-i \, a d e^{\left (2 i \, d x + 2 i \, c\right )} - i \, a d\right )} \sqrt {\frac {a}{e^{\left (2 i \, d x + 2 i \, c\right )} + 1}} \sqrt {\frac {1}{a^{3} d^{2}}} - i\right )} e^{\left (-i \, d x - i \, c\right )}}{16 \, a d}\right ) + \sqrt {2} \sqrt {\frac {a}{e^{\left (2 i \, d x + 2 i \, c\right )} + 1}} {\left (-8 i \, e^{\left (6 i \, d x + 6 i \, c\right )} + i \, e^{\left (4 i \, d x + 4 i \, c\right )} + 11 i \, e^{\left (2 i \, d x + 2 i \, c\right )} + 2 i\right )}\right )} e^{\left (-4 i \, d x - 4 i \, c\right )}}{64 \, a^{2} d} \] Input:

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

Output:

1/64*(-15*I*sqrt(1/2)*a^2*d*sqrt(1/(a^3*d^2))*e^(4*I*d*x + 4*I*c)*log(-15/ 
16*(sqrt(2)*sqrt(1/2)*(I*a*d*e^(2*I*d*x + 2*I*c) + I*a*d)*sqrt(a/(e^(2*I*d 
*x + 2*I*c) + 1))*sqrt(1/(a^3*d^2)) - I)*e^(-I*d*x - I*c)/(a*d)) + 15*I*sq 
rt(1/2)*a^2*d*sqrt(1/(a^3*d^2))*e^(4*I*d*x + 4*I*c)*log(-15/16*(sqrt(2)*sq 
rt(1/2)*(-I*a*d*e^(2*I*d*x + 2*I*c) - I*a*d)*sqrt(a/(e^(2*I*d*x + 2*I*c) + 
 1))*sqrt(1/(a^3*d^2)) - I)*e^(-I*d*x - I*c)/(a*d)) + sqrt(2)*sqrt(a/(e^(2 
*I*d*x + 2*I*c) + 1))*(-8*I*e^(6*I*d*x + 6*I*c) + I*e^(4*I*d*x + 4*I*c) + 
11*I*e^(2*I*d*x + 2*I*c) + 2*I))*e^(-4*I*d*x - 4*I*c)/(a^2*d)
 

Sympy [F]

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

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

Output:

Integral(cos(c + d*x)/(I*a*(tan(c + d*x) - I))**(3/2), x)
 

Maxima [B] (verification not implemented)

Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 1821 vs. \(2 (118) = 236\).

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

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

Output:

-1/256*(36*(cos(1/2*arctan2(sin(4*d*x + 4*c), cos(4*d*x + 4*c)))^2 + sin(1 
/2*arctan2(sin(4*d*x + 4*c), cos(4*d*x + 4*c)))^2 + 2*cos(1/2*arctan2(sin( 
4*d*x + 4*c), cos(4*d*x + 4*c))) + 1)^(3/4)*((-I*sqrt(2)*cos(4*d*x + 4*c) 
- sqrt(2)*sin(4*d*x + 4*c))*cos(3/2*arctan2(sin(1/2*arctan2(sin(4*d*x + 4* 
c), cos(4*d*x + 4*c))), cos(1/2*arctan2(sin(4*d*x + 4*c), cos(4*d*x + 4*c) 
)) + 1)) + (sqrt(2)*cos(4*d*x + 4*c) - I*sqrt(2)*sin(4*d*x + 4*c))*sin(3/2 
*arctan2(sin(1/2*arctan2(sin(4*d*x + 4*c), cos(4*d*x + 4*c))), cos(1/2*arc 
tan2(sin(4*d*x + 4*c), cos(4*d*x + 4*c))) + 1)))*sqrt(a) + 4*(cos(1/2*arct 
an2(sin(4*d*x + 4*c), cos(4*d*x + 4*c)))^2 + sin(1/2*arctan2(sin(4*d*x + 4 
*c), cos(4*d*x + 4*c)))^2 + 2*cos(1/2*arctan2(sin(4*d*x + 4*c), cos(4*d*x 
+ 4*c))) + 1)^(1/4)*((7*I*sqrt(2)*cos(4*d*x + 4*c) + 7*sqrt(2)*sin(4*d*x + 
 4*c) + 8*I*sqrt(2))*cos(1/2*arctan2(sin(1/2*arctan2(sin(4*d*x + 4*c), cos 
(4*d*x + 4*c))), cos(1/2*arctan2(sin(4*d*x + 4*c), cos(4*d*x + 4*c))) + 1) 
) - (7*sqrt(2)*cos(4*d*x + 4*c) - 7*I*sqrt(2)*sin(4*d*x + 4*c) + 8*sqrt(2) 
)*sin(1/2*arctan2(sin(1/2*arctan2(sin(4*d*x + 4*c), cos(4*d*x + 4*c))), co 
s(1/2*arctan2(sin(4*d*x + 4*c), cos(4*d*x + 4*c))) + 1)))*sqrt(a) + 15*(2* 
sqrt(2)*arctan2((cos(1/2*arctan2(sin(4*d*x + 4*c), cos(4*d*x + 4*c)))^2 + 
sin(1/2*arctan2(sin(4*d*x + 4*c), cos(4*d*x + 4*c)))^2 + 2*cos(1/2*arctan2 
(sin(4*d*x + 4*c), cos(4*d*x + 4*c))) + 1)^(1/4)*sin(1/2*arctan2(sin(1/2*a 
rctan2(sin(4*d*x + 4*c), cos(4*d*x + 4*c))), cos(1/2*arctan2(sin(4*d*x ...
 

Giac [F(-2)]

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

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

Output:

Exception raised: TypeError >> an error occurred running a Giac command:IN 
PUT:sage2:=int(sage0,sageVARx):;OUTPUT:Error: Bad Argument TypeError: Bad 
Argument TypeDone
 

Mupad [F(-1)]

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

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

Output:

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

Reduce [F]

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

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

Output:

int(cos(c + d*x)/(sqrt(tan(c + d*x)*i + 1)*tan(c + d*x)*i + sqrt(tan(c + d 
*x)*i + 1)),x)/(sqrt(a)*a)