3.254 \(\int \frac{1}{(a \cos (c+d x)+i a \sin (c+d x))^2} \, dx\)

Optimal. Leaf size=31 \[ \frac{i}{2 d (a \cos (c+d x)+i a \sin (c+d x))^2} \]

[Out]

(I/2)/(d*(a*Cos[c + d*x] + I*a*Sin[c + d*x])^2)

________________________________________________________________________________________

Rubi [A]  time = 0.0155649, antiderivative size = 31, normalized size of antiderivative = 1., number of steps used = 1, number of rules used = 1, integrand size = 22, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.045, Rules used = {3071} \[ \frac{i}{2 d (a \cos (c+d x)+i a \sin (c+d x))^2} \]

Antiderivative was successfully verified.

[In]

Int[(a*Cos[c + d*x] + I*a*Sin[c + d*x])^(-2),x]

[Out]

(I/2)/(d*(a*Cos[c + d*x] + I*a*Sin[c + d*x])^2)

Rule 3071

Int[(cos[(c_.) + (d_.)*(x_)]*(a_.) + (b_.)*sin[(c_.) + (d_.)*(x_)])^(n_), x_Symbol] :> Simp[(a*(a*Cos[c + d*x]
 + b*Sin[c + d*x])^n)/(b*d*n), x] /; FreeQ[{a, b, c, d, n}, x] && EqQ[a^2 + b^2, 0]

Rubi steps

\begin{align*} \int \frac{1}{(a \cos (c+d x)+i a \sin (c+d x))^2} \, dx &=\frac{i}{2 d (a \cos (c+d x)+i a \sin (c+d x))^2}\\ \end{align*}

Mathematica [A]  time = 0.0453233, size = 31, normalized size = 1. \[ \frac{i}{2 d (a \cos (c+d x)+i a \sin (c+d x))^2} \]

Antiderivative was successfully verified.

[In]

Integrate[(a*Cos[c + d*x] + I*a*Sin[c + d*x])^(-2),x]

[Out]

(I/2)/(d*(a*Cos[c + d*x] + I*a*Sin[c + d*x])^2)

________________________________________________________________________________________

Maple [A]  time = 0.092, size = 23, normalized size = 0.7 \begin{align*}{\frac{i}{{a}^{2}d \left ( i\tan \left ( dx+c \right ) +1 \right ) }} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(a*cos(d*x+c)+I*a*sin(d*x+c))^2,x)

[Out]

I/d/a^2/(I*tan(d*x+c)+1)

________________________________________________________________________________________

Maxima [A]  time = 0.982692, size = 30, normalized size = 0.97 \begin{align*} \frac{1}{{\left (a^{2} \tan \left (d x + c\right ) - i \, a^{2}\right )} d} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/((a^2*tan(d*x + c) - I*a^2)*d)

________________________________________________________________________________________

Fricas [A]  time = 1.99282, size = 49, normalized size = 1.58 \begin{align*} \frac{i \, e^{\left (-2 i \, d x - 2 i \, c\right )}}{2 \, a^{2} d} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/2*I*e^(-2*I*d*x - 2*I*c)/(a^2*d)

________________________________________________________________________________________

Sympy [A]  time = 0.179153, size = 46, normalized size = 1.48 \begin{align*} \begin{cases} \frac{i e^{- 2 i c} e^{- 2 i d x}}{2 a^{2} d} & \text{for}\: 2 a^{2} d e^{2 i c} \neq 0 \\\frac{x e^{- 2 i c}}{a^{2}} & \text{otherwise} \end{cases} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(a*cos(d*x+c)+I*a*sin(d*x+c))**2,x)

[Out]

Piecewise((I*exp(-2*I*c)*exp(-2*I*d*x)/(2*a**2*d), Ne(2*a**2*d*exp(2*I*c), 0)), (x*exp(-2*I*c)/a**2, True))

________________________________________________________________________________________

Giac [A]  time = 1.11583, size = 41, normalized size = 1.32 \begin{align*} -\frac{2 \, \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )}{a^{2} d{\left (\tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right ) - i\right )}^{2}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-2*tan(1/2*d*x + 1/2*c)/(a^2*d*(tan(1/2*d*x + 1/2*c) - I)^2)