### 3.27 $$\int \frac{1}{(c+d x) (a+i a \tan (e+f x))^2} \, dx$$

Optimal. Leaf size=305 $-\frac{i \text{CosIntegral}\left (\frac{2 c f}{d}+2 f x\right ) \sin \left (2 e-\frac{2 c f}{d}\right )}{2 a^2 d}-\frac{i \text{CosIntegral}\left (\frac{4 c f}{d}+4 f x\right ) \sin \left (4 e-\frac{4 c f}{d}\right )}{4 a^2 d}+\frac{\text{CosIntegral}\left (\frac{2 c f}{d}+2 f x\right ) \cos \left (2 e-\frac{2 c f}{d}\right )}{2 a^2 d}+\frac{\text{CosIntegral}\left (\frac{4 c f}{d}+4 f x\right ) \cos \left (4 e-\frac{4 c f}{d}\right )}{4 a^2 d}-\frac{\sin \left (2 e-\frac{2 c f}{d}\right ) \text{Si}\left (2 x f+\frac{2 c f}{d}\right )}{2 a^2 d}-\frac{\sin \left (4 e-\frac{4 c f}{d}\right ) \text{Si}\left (4 x f+\frac{4 c f}{d}\right )}{4 a^2 d}-\frac{i \cos \left (2 e-\frac{2 c f}{d}\right ) \text{Si}\left (2 x f+\frac{2 c f}{d}\right )}{2 a^2 d}-\frac{i \cos \left (4 e-\frac{4 c f}{d}\right ) \text{Si}\left (4 x f+\frac{4 c f}{d}\right )}{4 a^2 d}+\frac{\log (c+d x)}{4 a^2 d}$

[Out]

(Cos[2*e - (2*c*f)/d]*CosIntegral[(2*c*f)/d + 2*f*x])/(2*a^2*d) + (Cos[4*e - (4*c*f)/d]*CosIntegral[(4*c*f)/d
+ 4*f*x])/(4*a^2*d) + Log[c + d*x]/(4*a^2*d) - ((I/4)*CosIntegral[(4*c*f)/d + 4*f*x]*Sin[4*e - (4*c*f)/d])/(a^
2*d) - ((I/2)*CosIntegral[(2*c*f)/d + 2*f*x]*Sin[2*e - (2*c*f)/d])/(a^2*d) - ((I/2)*Cos[2*e - (2*c*f)/d]*SinIn
tegral[(2*c*f)/d + 2*f*x])/(a^2*d) - (Sin[2*e - (2*c*f)/d]*SinIntegral[(2*c*f)/d + 2*f*x])/(2*a^2*d) - ((I/4)*
Cos[4*e - (4*c*f)/d]*SinIntegral[(4*c*f)/d + 4*f*x])/(a^2*d) - (Sin[4*e - (4*c*f)/d]*SinIntegral[(4*c*f)/d + 4
*f*x])/(4*a^2*d)

________________________________________________________________________________________

Rubi [A]  time = 0.771527, antiderivative size = 305, normalized size of antiderivative = 1., number of steps used = 21, number of rules used = 5, integrand size = 23, $$\frac{\text{number of rules}}{\text{integrand size}}$$ = 0.217, Rules used = {3728, 3303, 3299, 3302, 3312} $-\frac{i \text{CosIntegral}\left (\frac{2 c f}{d}+2 f x\right ) \sin \left (2 e-\frac{2 c f}{d}\right )}{2 a^2 d}-\frac{i \text{CosIntegral}\left (\frac{4 c f}{d}+4 f x\right ) \sin \left (4 e-\frac{4 c f}{d}\right )}{4 a^2 d}+\frac{\text{CosIntegral}\left (\frac{2 c f}{d}+2 f x\right ) \cos \left (2 e-\frac{2 c f}{d}\right )}{2 a^2 d}+\frac{\text{CosIntegral}\left (\frac{4 c f}{d}+4 f x\right ) \cos \left (4 e-\frac{4 c f}{d}\right )}{4 a^2 d}-\frac{\sin \left (2 e-\frac{2 c f}{d}\right ) \text{Si}\left (2 x f+\frac{2 c f}{d}\right )}{2 a^2 d}-\frac{\sin \left (4 e-\frac{4 c f}{d}\right ) \text{Si}\left (4 x f+\frac{4 c f}{d}\right )}{4 a^2 d}-\frac{i \cos \left (2 e-\frac{2 c f}{d}\right ) \text{Si}\left (2 x f+\frac{2 c f}{d}\right )}{2 a^2 d}-\frac{i \cos \left (4 e-\frac{4 c f}{d}\right ) \text{Si}\left (4 x f+\frac{4 c f}{d}\right )}{4 a^2 d}+\frac{\log (c+d x)}{4 a^2 d}$

Antiderivative was successfully veriﬁed.

[In]

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

[Out]

(Cos[2*e - (2*c*f)/d]*CosIntegral[(2*c*f)/d + 2*f*x])/(2*a^2*d) + (Cos[4*e - (4*c*f)/d]*CosIntegral[(4*c*f)/d
+ 4*f*x])/(4*a^2*d) + Log[c + d*x]/(4*a^2*d) - ((I/4)*CosIntegral[(4*c*f)/d + 4*f*x]*Sin[4*e - (4*c*f)/d])/(a^
2*d) - ((I/2)*CosIntegral[(2*c*f)/d + 2*f*x]*Sin[2*e - (2*c*f)/d])/(a^2*d) - ((I/2)*Cos[2*e - (2*c*f)/d]*SinIn
tegral[(2*c*f)/d + 2*f*x])/(a^2*d) - (Sin[2*e - (2*c*f)/d]*SinIntegral[(2*c*f)/d + 2*f*x])/(2*a^2*d) - ((I/4)*
Cos[4*e - (4*c*f)/d]*SinIntegral[(4*c*f)/d + 4*f*x])/(a^2*d) - (Sin[4*e - (4*c*f)/d]*SinIntegral[(4*c*f)/d + 4
*f*x])/(4*a^2*d)

Rule 3728

Int[((c_.) + (d_.)*(x_))^(m_)*((a_) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(n_), x_Symbol] :> Int[ExpandIntegrand[(c
+ d*x)^m, (1/(2*a) + Cos[2*e + 2*f*x]/(2*a) + Sin[2*e + 2*f*x]/(2*b))^(-n), x], x] /; FreeQ[{a, b, c, d, e, f
}, x] && EqQ[a^2 + b^2, 0] && ILtQ[m, 0] && ILtQ[n, 0]

Rule 3303

Int[sin[(e_.) + (f_.)*(x_)]/((c_.) + (d_.)*(x_)), x_Symbol] :> Dist[Cos[(d*e - c*f)/d], Int[Sin[(c*f)/d + f*x]
/(c + d*x), x], x] + Dist[Sin[(d*e - c*f)/d], Int[Cos[(c*f)/d + f*x]/(c + d*x), x], x] /; FreeQ[{c, d, e, f},
x] && NeQ[d*e - c*f, 0]

Rule 3299

Int[sin[(e_.) + (f_.)*(x_)]/((c_.) + (d_.)*(x_)), x_Symbol] :> Simp[SinIntegral[e + f*x]/d, x] /; FreeQ[{c, d,
e, f}, x] && EqQ[d*e - c*f, 0]

Rule 3302

Int[sin[(e_.) + (f_.)*(x_)]/((c_.) + (d_.)*(x_)), x_Symbol] :> Simp[CosIntegral[e - Pi/2 + f*x]/d, x] /; FreeQ
[{c, d, e, f}, x] && EqQ[d*(e - Pi/2) - c*f, 0]

Rule 3312

Int[((c_.) + (d_.)*(x_))^(m_)*sin[(e_.) + (f_.)*(x_)]^(n_), x_Symbol] :> Int[ExpandTrigReduce[(c + d*x)^m, Sin
[e + f*x]^n, x], x] /; FreeQ[{c, d, e, f, m}, x] && IGtQ[n, 1] && ( !RationalQ[m] || (GeQ[m, -1] && LtQ[m, 1])
)

Rubi steps

\begin{align*} \int \frac{1}{(c+d x) (a+i a \tan (e+f x))^2} \, dx &=\int \left (\frac{1}{4 a^2 (c+d x)}+\frac{\cos (2 e+2 f x)}{2 a^2 (c+d x)}+\frac{\cos ^2(2 e+2 f x)}{4 a^2 (c+d x)}-\frac{i \sin (2 e+2 f x)}{2 a^2 (c+d x)}-\frac{\sin ^2(2 e+2 f x)}{4 a^2 (c+d x)}-\frac{i \sin (4 e+4 f x)}{4 a^2 (c+d x)}\right ) \, dx\\ &=\frac{\log (c+d x)}{4 a^2 d}-\frac{i \int \frac{\sin (4 e+4 f x)}{c+d x} \, dx}{4 a^2}-\frac{i \int \frac{\sin (2 e+2 f x)}{c+d x} \, dx}{2 a^2}+\frac{\int \frac{\cos ^2(2 e+2 f x)}{c+d x} \, dx}{4 a^2}-\frac{\int \frac{\sin ^2(2 e+2 f x)}{c+d x} \, dx}{4 a^2}+\frac{\int \frac{\cos (2 e+2 f x)}{c+d x} \, dx}{2 a^2}\\ &=\frac{\log (c+d x)}{4 a^2 d}-\frac{\int \left (\frac{1}{2 (c+d x)}-\frac{\cos (4 e+4 f x)}{2 (c+d x)}\right ) \, dx}{4 a^2}+\frac{\int \left (\frac{1}{2 (c+d x)}+\frac{\cos (4 e+4 f x)}{2 (c+d x)}\right ) \, dx}{4 a^2}-\frac{\left (i \cos \left (4 e-\frac{4 c f}{d}\right )\right ) \int \frac{\sin \left (\frac{4 c f}{d}+4 f x\right )}{c+d x} \, dx}{4 a^2}-\frac{\left (i \cos \left (2 e-\frac{2 c f}{d}\right )\right ) \int \frac{\sin \left (\frac{2 c f}{d}+2 f x\right )}{c+d x} \, dx}{2 a^2}+\frac{\cos \left (2 e-\frac{2 c f}{d}\right ) \int \frac{\cos \left (\frac{2 c f}{d}+2 f x\right )}{c+d x} \, dx}{2 a^2}-\frac{\left (i \sin \left (4 e-\frac{4 c f}{d}\right )\right ) \int \frac{\cos \left (\frac{4 c f}{d}+4 f x\right )}{c+d x} \, dx}{4 a^2}-\frac{\left (i \sin \left (2 e-\frac{2 c f}{d}\right )\right ) \int \frac{\cos \left (\frac{2 c f}{d}+2 f x\right )}{c+d x} \, dx}{2 a^2}-\frac{\sin \left (2 e-\frac{2 c f}{d}\right ) \int \frac{\sin \left (\frac{2 c f}{d}+2 f x\right )}{c+d x} \, dx}{2 a^2}\\ &=\frac{\cos \left (2 e-\frac{2 c f}{d}\right ) \text{Ci}\left (\frac{2 c f}{d}+2 f x\right )}{2 a^2 d}+\frac{\log (c+d x)}{4 a^2 d}-\frac{i \text{Ci}\left (\frac{4 c f}{d}+4 f x\right ) \sin \left (4 e-\frac{4 c f}{d}\right )}{4 a^2 d}-\frac{i \text{Ci}\left (\frac{2 c f}{d}+2 f x\right ) \sin \left (2 e-\frac{2 c f}{d}\right )}{2 a^2 d}-\frac{i \cos \left (2 e-\frac{2 c f}{d}\right ) \text{Si}\left (\frac{2 c f}{d}+2 f x\right )}{2 a^2 d}-\frac{\sin \left (2 e-\frac{2 c f}{d}\right ) \text{Si}\left (\frac{2 c f}{d}+2 f x\right )}{2 a^2 d}-\frac{i \cos \left (4 e-\frac{4 c f}{d}\right ) \text{Si}\left (\frac{4 c f}{d}+4 f x\right )}{4 a^2 d}+2 \frac{\int \frac{\cos (4 e+4 f x)}{c+d x} \, dx}{8 a^2}\\ &=\frac{\cos \left (2 e-\frac{2 c f}{d}\right ) \text{Ci}\left (\frac{2 c f}{d}+2 f x\right )}{2 a^2 d}+\frac{\log (c+d x)}{4 a^2 d}-\frac{i \text{Ci}\left (\frac{4 c f}{d}+4 f x\right ) \sin \left (4 e-\frac{4 c f}{d}\right )}{4 a^2 d}-\frac{i \text{Ci}\left (\frac{2 c f}{d}+2 f x\right ) \sin \left (2 e-\frac{2 c f}{d}\right )}{2 a^2 d}-\frac{i \cos \left (2 e-\frac{2 c f}{d}\right ) \text{Si}\left (\frac{2 c f}{d}+2 f x\right )}{2 a^2 d}-\frac{\sin \left (2 e-\frac{2 c f}{d}\right ) \text{Si}\left (\frac{2 c f}{d}+2 f x\right )}{2 a^2 d}-\frac{i \cos \left (4 e-\frac{4 c f}{d}\right ) \text{Si}\left (\frac{4 c f}{d}+4 f x\right )}{4 a^2 d}+2 \left (\frac{\cos \left (4 e-\frac{4 c f}{d}\right ) \int \frac{\cos \left (\frac{4 c f}{d}+4 f x\right )}{c+d x} \, dx}{8 a^2}-\frac{\sin \left (4 e-\frac{4 c f}{d}\right ) \int \frac{\sin \left (\frac{4 c f}{d}+4 f x\right )}{c+d x} \, dx}{8 a^2}\right )\\ &=\frac{\cos \left (2 e-\frac{2 c f}{d}\right ) \text{Ci}\left (\frac{2 c f}{d}+2 f x\right )}{2 a^2 d}+\frac{\log (c+d x)}{4 a^2 d}-\frac{i \text{Ci}\left (\frac{4 c f}{d}+4 f x\right ) \sin \left (4 e-\frac{4 c f}{d}\right )}{4 a^2 d}-\frac{i \text{Ci}\left (\frac{2 c f}{d}+2 f x\right ) \sin \left (2 e-\frac{2 c f}{d}\right )}{2 a^2 d}-\frac{i \cos \left (2 e-\frac{2 c f}{d}\right ) \text{Si}\left (\frac{2 c f}{d}+2 f x\right )}{2 a^2 d}-\frac{\sin \left (2 e-\frac{2 c f}{d}\right ) \text{Si}\left (\frac{2 c f}{d}+2 f x\right )}{2 a^2 d}-\frac{i \cos \left (4 e-\frac{4 c f}{d}\right ) \text{Si}\left (\frac{4 c f}{d}+4 f x\right )}{4 a^2 d}+2 \left (\frac{\cos \left (4 e-\frac{4 c f}{d}\right ) \text{Ci}\left (\frac{4 c f}{d}+4 f x\right )}{8 a^2 d}-\frac{\sin \left (4 e-\frac{4 c f}{d}\right ) \text{Si}\left (\frac{4 c f}{d}+4 f x\right )}{8 a^2 d}\right )\\ \end{align*}

Mathematica [A]  time = 0.421838, size = 211, normalized size = 0.69 $\frac{\left (\cos \left (2 e-\frac{2 c f}{d}\right )-i \sin \left (2 e-\frac{2 c f}{d}\right )\right ) \left (\text{CosIntegral}\left (\frac{4 f (c+d x)}{d}\right ) \left (\cos \left (2 e-\frac{2 c f}{d}\right )-i \sin \left (2 e-\frac{2 c f}{d}\right )\right )+2 \text{CosIntegral}\left (\frac{2 f (c+d x)}{d}\right )-\sin \left (2 e-\frac{2 c f}{d}\right ) \text{Si}\left (\frac{4 f (c+d x)}{d}\right )-i \cos \left (2 e-\frac{2 c f}{d}\right ) \text{Si}\left (\frac{4 f (c+d x)}{d}\right )+i \sin \left (2 e-\frac{2 c f}{d}\right ) \log (f (c+d x))+\cos \left (2 e-\frac{2 c f}{d}\right ) \log (f (c+d x))-2 i \text{Si}\left (\frac{2 f (c+d x)}{d}\right )\right )}{4 a^2 d}$

Warning: Unable to verify antiderivative.

[In]

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

[Out]

((Cos[2*e - (2*c*f)/d] - I*Sin[2*e - (2*c*f)/d])*(2*CosIntegral[(2*f*(c + d*x))/d] + Cos[2*e - (2*c*f)/d]*Log[
f*(c + d*x)] + CosIntegral[(4*f*(c + d*x))/d]*(Cos[2*e - (2*c*f)/d] - I*Sin[2*e - (2*c*f)/d]) + I*Log[f*(c + d
*x)]*Sin[2*e - (2*c*f)/d] - (2*I)*SinIntegral[(2*f*(c + d*x))/d] - I*Cos[2*e - (2*c*f)/d]*SinIntegral[(4*f*(c
+ d*x))/d] - Sin[2*e - (2*c*f)/d]*SinIntegral[(4*f*(c + d*x))/d]))/(4*a^2*d)

________________________________________________________________________________________

Maple [A]  time = 0.234, size = 114, normalized size = 0.4 \begin{align*}{\frac{\ln \left ( dx+c \right ) }{4\,{a}^{2}d}}-{\frac{1}{4\,{a}^{2}d}{{\rm e}^{{\frac{4\,i \left ( cf-de \right ) }{d}}}}{\it Ei} \left ( 1,4\,ifx+4\,ie+{\frac{4\,i \left ( cf-de \right ) }{d}} \right ) }-{\frac{1}{2\,{a}^{2}d}{{\rm e}^{{\frac{2\,i \left ( cf-de \right ) }{d}}}}{\it Ei} \left ( 1,2\,ifx+2\,ie+{\frac{2\,i \left ( cf-de \right ) }{d}} \right ) } \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/4*ln(d*x+c)/a^2/d-1/4/a^2/d*exp(4*I*(c*f-d*e)/d)*Ei(1,4*I*f*x+4*I*e+4*I*(c*f-d*e)/d)-1/2/a^2/d*exp(2*I*(c*f-
d*e)/d)*Ei(1,2*I*f*x+2*I*e+2*I*(c*f-d*e)/d)

________________________________________________________________________________________

Maxima [A]  time = 1.42361, size = 257, normalized size = 0.84 \begin{align*} -\frac{f \cos \left (-\frac{4 \,{\left (d e - c f\right )}}{d}\right ) E_{1}\left (\frac{4 i \,{\left (f x + e\right )} d - 4 i \, d e + 4 i \, c f}{d}\right ) + 2 \, f \cos \left (-\frac{2 \,{\left (d e - c f\right )}}{d}\right ) E_{1}\left (\frac{2 i \,{\left (f x + e\right )} d - 2 i \, d e + 2 i \, c f}{d}\right ) + 2 i \, f E_{1}\left (\frac{2 i \,{\left (f x + e\right )} d - 2 i \, d e + 2 i \, c f}{d}\right ) \sin \left (-\frac{2 \,{\left (d e - c f\right )}}{d}\right ) + i \, f E_{1}\left (\frac{4 i \,{\left (f x + e\right )} d - 4 i \, d e + 4 i \, c f}{d}\right ) \sin \left (-\frac{4 \,{\left (d e - c f\right )}}{d}\right ) - f \log \left ({\left (f x + e\right )} d - d e + c f\right )}{4 \, a^{2} d f} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-1/4*(f*cos(-4*(d*e - c*f)/d)*exp_integral_e(1, (4*I*(f*x + e)*d - 4*I*d*e + 4*I*c*f)/d) + 2*f*cos(-2*(d*e - c
*f)/d)*exp_integral_e(1, (2*I*(f*x + e)*d - 2*I*d*e + 2*I*c*f)/d) + 2*I*f*exp_integral_e(1, (2*I*(f*x + e)*d -
2*I*d*e + 2*I*c*f)/d)*sin(-2*(d*e - c*f)/d) + I*f*exp_integral_e(1, (4*I*(f*x + e)*d - 4*I*d*e + 4*I*c*f)/d)*
sin(-4*(d*e - c*f)/d) - f*log((f*x + e)*d - d*e + c*f))/(a^2*d*f)

________________________________________________________________________________________

Fricas [A]  time = 1.564, size = 203, normalized size = 0.67 \begin{align*} \frac{2 \,{\rm Ei}\left (\frac{-2 i \, d f x - 2 i \, c f}{d}\right ) e^{\left (\frac{-2 i \, d e + 2 i \, c f}{d}\right )} +{\rm Ei}\left (\frac{-4 i \, d f x - 4 i \, c f}{d}\right ) e^{\left (\frac{-4 i \, d e + 4 i \, c f}{d}\right )} + \log \left (\frac{d x + c}{d}\right )}{4 \, a^{2} d} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/4*(2*Ei((-2*I*d*f*x - 2*I*c*f)/d)*e^((-2*I*d*e + 2*I*c*f)/d) + Ei((-4*I*d*f*x - 4*I*c*f)/d)*e^((-4*I*d*e + 4
*I*c*f)/d) + log((d*x + c)/d))/(a^2*d)

________________________________________________________________________________________

Sympy [F(-2)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: AttributeError} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

Exception raised: AttributeError

________________________________________________________________________________________

Giac [A]  time = 1.19047, size = 567, normalized size = 1.86 \begin{align*} \frac{2 \, \cos \left (\frac{2 \, c f}{d}\right ) \cos \left (2 \, e\right ) \operatorname{Ci}\left (-\frac{2 \,{\left (d f x + c f\right )}}{d}\right ) + \cos \left (2 \, e\right )^{2} \log \left (d x + c\right ) + 2 i \, \cos \left (2 \, e\right ) \operatorname{Ci}\left (-\frac{2 \,{\left (d f x + c f\right )}}{d}\right ) \sin \left (\frac{2 \, c f}{d}\right ) + 2 i \, \cos \left (\frac{2 \, c f}{d}\right ) \operatorname{Ci}\left (-\frac{2 \,{\left (d f x + c f\right )}}{d}\right ) \sin \left (2 \, e\right ) + 2 i \, \cos \left (2 \, e\right ) \log \left (d x + c\right ) \sin \left (2 \, e\right ) - 2 \, \operatorname{Ci}\left (-\frac{2 \,{\left (d f x + c f\right )}}{d}\right ) \sin \left (\frac{2 \, c f}{d}\right ) \sin \left (2 \, e\right ) - \log \left (d x + c\right ) \sin \left (2 \, e\right )^{2} - 2 i \, \cos \left (\frac{2 \, c f}{d}\right ) \cos \left (2 \, e\right ) \operatorname{Si}\left (\frac{2 \,{\left (d f x + c f\right )}}{d}\right ) + 2 \, \cos \left (2 \, e\right ) \sin \left (\frac{2 \, c f}{d}\right ) \operatorname{Si}\left (\frac{2 \,{\left (d f x + c f\right )}}{d}\right ) + 2 \, \cos \left (\frac{2 \, c f}{d}\right ) \sin \left (2 \, e\right ) \operatorname{Si}\left (\frac{2 \,{\left (d f x + c f\right )}}{d}\right ) + 2 i \, \sin \left (\frac{2 \, c f}{d}\right ) \sin \left (2 \, e\right ) \operatorname{Si}\left (\frac{2 \,{\left (d f x + c f\right )}}{d}\right ) + \cos \left (\frac{4 \, c f}{d}\right ) \operatorname{Ci}\left (-\frac{4 \,{\left (d f x + c f\right )}}{d}\right ) + i \, \operatorname{Ci}\left (-\frac{4 \,{\left (d f x + c f\right )}}{d}\right ) \sin \left (\frac{4 \, c f}{d}\right ) - i \, \cos \left (\frac{4 \, c f}{d}\right ) \operatorname{Si}\left (\frac{4 \,{\left (d f x + c f\right )}}{d}\right ) + \sin \left (\frac{4 \, c f}{d}\right ) \operatorname{Si}\left (\frac{4 \,{\left (d f x + c f\right )}}{d}\right )}{4 \,{\left (a^{2} d \cos \left (2 \, e\right )^{2} + 2 i \, a^{2} d \cos \left (2 \, e\right ) \sin \left (2 \, e\right ) - a^{2} d \sin \left (2 \, e\right )^{2}\right )}} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/4*(2*cos(2*c*f/d)*cos(2*e)*cos_integral(-2*(d*f*x + c*f)/d) + cos(2*e)^2*log(d*x + c) + 2*I*cos(2*e)*cos_int
egral(-2*(d*f*x + c*f)/d)*sin(2*c*f/d) + 2*I*cos(2*c*f/d)*cos_integral(-2*(d*f*x + c*f)/d)*sin(2*e) + 2*I*cos(
2*e)*log(d*x + c)*sin(2*e) - 2*cos_integral(-2*(d*f*x + c*f)/d)*sin(2*c*f/d)*sin(2*e) - log(d*x + c)*sin(2*e)^
2 - 2*I*cos(2*c*f/d)*cos(2*e)*sin_integral(2*(d*f*x + c*f)/d) + 2*cos(2*e)*sin(2*c*f/d)*sin_integral(2*(d*f*x
+ c*f)/d) + 2*cos(2*c*f/d)*sin(2*e)*sin_integral(2*(d*f*x + c*f)/d) + 2*I*sin(2*c*f/d)*sin(2*e)*sin_integral(2
*(d*f*x + c*f)/d) + cos(4*c*f/d)*cos_integral(-4*(d*f*x + c*f)/d) + I*cos_integral(-4*(d*f*x + c*f)/d)*sin(4*c
*f/d) - I*cos(4*c*f/d)*sin_integral(4*(d*f*x + c*f)/d) + sin(4*c*f/d)*sin_integral(4*(d*f*x + c*f)/d))/(a^2*d*
cos(2*e)^2 + 2*I*a^2*d*cos(2*e)*sin(2*e) - a^2*d*sin(2*e)^2)