Integrand size = 27, antiderivative size = 99 \[ \int e^{2 (a+i b x)} \cot (d+b x) \csc ^2(d+b x) \, dx=\frac {2 e^{2 a-2 i d}}{b \left (1-e^{2 i (d+b x)}\right )^2}-\frac {6 e^{2 a-2 i d}}{b \left (1-e^{2 i (d+b x)}\right )}-\frac {2 e^{2 a-2 i d} \log \left (1-e^{2 i (d+b x)}\right )}{b} \] Output:
2*exp(2*a-2*I*d)/b/(1-exp(2*I*(b*x+d)))^2-6*exp(2*a-2*I*d)/b/(1-exp(2*I*(b *x+d)))-2*exp(2*a-2*I*d)*ln(1-exp(2*I*(b*x+d)))/b
Time = 0.26 (sec) , antiderivative size = 78, normalized size of antiderivative = 0.79 \[ \int e^{2 (a+i b x)} \cot (d+b x) \csc ^2(d+b x) \, dx=-\frac {2 e^{2 a-2 i d} \left (2-3 e^{2 i (d+b x)}+\left (-1+e^{2 i (d+b x)}\right )^2 \log \left (1-e^{2 i (d+b x)}\right )\right )}{b \left (-1+e^{2 i (d+b x)}\right )^2} \] Input:
Integrate[E^(2*(a + I*b*x))*Cot[d + b*x]*Csc[d + b*x]^2,x]
Output:
(-2*E^(2*a - (2*I)*d)*(2 - 3*E^((2*I)*(d + b*x)) + (-1 + E^((2*I)*(d + b*x )))^2*Log[1 - E^((2*I)*(d + b*x))]))/(b*(-1 + E^((2*I)*(d + b*x)))^2)
Time = 0.37 (sec) , antiderivative size = 109, normalized size of antiderivative = 1.10, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.074, Rules used = {4974, 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 e^{2 (a+i b x)} \cot (b x+d) \csc ^2(b x+d) \, dx\) |
\(\Big \downarrow \) 4974 |
\(\displaystyle \int \left (-\frac {4 i e^{2 (a+i d)+4 i b x}}{\left (-1+e^{2 i (b x+d)}\right )^2}-\frac {8 i e^{2 (a+i d)+4 i b x}}{\left (-1+e^{2 i (b x+d)}\right )^3}\right )dx\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle -\frac {2 e^{2 a-2 i d}}{b \left (1-e^{2 i (b x+d)}\right )}+\frac {2 e^{2 (a-i d)+4 i (b x+d)}}{b \left (1-e^{2 i (b x+d)}\right )^2}-\frac {2 e^{2 a-2 i d} \log \left (1-e^{2 i (b x+d)}\right )}{b}\) |
Input:
Int[E^(2*(a + I*b*x))*Cot[d + b*x]*Csc[d + b*x]^2,x]
Output:
(2*E^(2*(a - I*d) + (4*I)*(d + b*x)))/(b*(1 - E^((2*I)*(d + b*x)))^2) - (2 *E^(2*a - (2*I)*d))/(b*(1 - E^((2*I)*(d + b*x)))) - (2*E^(2*a - (2*I)*d)*L og[1 - E^((2*I)*(d + b*x))])/b
Int[(F_)^((c_.)*((a_.) + (b_.)*(x_)))*(G_)[(d_.) + (e_.)*(x_)]^(m_.)*(H_)[( d_.) + (e_.)*(x_)]^(n_.), x_Symbol] :> Int[ExpandTrigToExp[F^(c*(a + b*x)), G[d + e*x]^m*H[d + e*x]^n, x], x] /; FreeQ[{F, a, b, c, d, e}, x] && IGtQ[ m, 0] && IGtQ[n, 0] && TrigQ[G] && TrigQ[H]
Time = 0.26 (sec) , antiderivative size = 76, normalized size of antiderivative = 0.77
method | result | size |
risch | \(\frac {4 \,{\mathrm e}^{4 i b x} {\mathrm e}^{2 i d} {\mathrm e}^{2 a}-2 \,{\mathrm e}^{2 a} {\mathrm e}^{2 i b x}}{b \left (-1+{\mathrm e}^{2 i \left (b x +d \right )}\right )^{2}}-\frac {2 \,{\mathrm e}^{2 a} {\mathrm e}^{-2 i d} \ln \left (-1+{\mathrm e}^{2 i \left (b x +d \right )}\right )}{b}\) | \(76\) |
Input:
int(exp(2*a+2*I*b*x)*cot(b*x+d)*csc(b*x+d)^2,x,method=_RETURNVERBOSE)
Output:
2/b/(-1+exp(2*I*(b*x+d)))^2*(2*exp(4*I*b*x)*exp(2*I*d)*exp(2*a)-exp(2*a)*e xp(2*I*b*x))-2*exp(2*a)/b*exp(-2*I*d)*ln(-1+exp(2*I*(b*x+d)))
Time = 0.08 (sec) , antiderivative size = 96, normalized size of antiderivative = 0.97 \[ \int e^{2 (a+i b x)} \cot (d+b x) \csc ^2(d+b x) \, dx=-\frac {2 \, {\left ({\left (e^{\left (4 i \, b x + 2 \, a + 2 i \, d\right )} - 2 \, e^{\left (2 i \, b x + 2 \, a\right )} + e^{\left (2 \, a - 2 i \, d\right )}\right )} \log \left (e^{\left (2 i \, b x + 2 i \, d\right )} - 1\right ) - 3 \, e^{\left (2 i \, b x + 2 \, a\right )} + 2 \, e^{\left (2 \, a - 2 i \, d\right )}\right )}}{b e^{\left (4 i \, b x + 4 i \, d\right )} - 2 \, b e^{\left (2 i \, b x + 2 i \, d\right )} + b} \] Input:
integrate(exp(2*a+2*I*b*x)*cot(b*x+d)*csc(b*x+d)^2,x, algorithm="fricas")
Output:
-2*((e^(4*I*b*x + 2*a + 2*I*d) - 2*e^(2*I*b*x + 2*a) + e^(2*a - 2*I*d))*lo g(e^(2*I*b*x + 2*I*d) - 1) - 3*e^(2*I*b*x + 2*a) + 2*e^(2*a - 2*I*d))/(b*e ^(4*I*b*x + 4*I*d) - 2*b*e^(2*I*b*x + 2*I*d) + b)
\[ \int e^{2 (a+i b x)} \cot (d+b x) \csc ^2(d+b x) \, dx=e^{2 a} \int e^{2 i b x} \cot {\left (b x + d \right )} \csc ^{2}{\left (b x + d \right )}\, dx \] Input:
integrate(exp(2*a+2*I*b*x)*cot(b*x+d)*csc(b*x+d)**2,x)
Output:
exp(2*a)*Integral(exp(2*I*b*x)*cot(b*x + d)*csc(b*x + d)**2, x)
Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 808 vs. \(2 (80) = 160\).
Time = 0.06 (sec) , antiderivative size = 808, normalized size of antiderivative = 8.16 \[ \int e^{2 (a+i b x)} \cot (d+b x) \csc ^2(d+b x) \, dx=\text {Too large to display} \] Input:
integrate(exp(2*a+2*I*b*x)*cot(b*x+d)*csc(b*x+d)^2,x, algorithm="maxima")
Output:
-(2*(cos(2*d)^2*e^(2*a) + e^(2*a)*sin(2*d)^2 + (cos(2*d)*e^(2*a) - I*e^(2* a)*sin(2*d))*cos(4*b*x + 6*d) - 2*(cos(2*d)*e^(2*a) - I*e^(2*a)*sin(2*d))* cos(2*b*x + 4*d) + (I*cos(2*d)*e^(2*a) + e^(2*a)*sin(2*d))*sin(4*b*x + 6*d ) + 2*(-I*cos(2*d)*e^(2*a) - e^(2*a)*sin(2*d))*sin(2*b*x + 4*d))*arctan2(s in(b*x) + sin(d), cos(b*x) - cos(d)) + 2*(cos(2*d)^2*e^(2*a) + e^(2*a)*sin (2*d)^2 + (cos(2*d)*e^(2*a) - I*e^(2*a)*sin(2*d))*cos(4*b*x + 6*d) - 2*(co s(2*d)*e^(2*a) - I*e^(2*a)*sin(2*d))*cos(2*b*x + 4*d) + (I*cos(2*d)*e^(2*a ) + e^(2*a)*sin(2*d))*sin(4*b*x + 6*d) + 2*(-I*cos(2*d)*e^(2*a) - e^(2*a)* sin(2*d))*sin(2*b*x + 4*d))*arctan2(sin(b*x) - sin(d), cos(b*x) + cos(d)) + 6*I*cos(2*b*x + 2*d)*e^(2*a) - (I*cos(2*d)^2*e^(2*a) + I*e^(2*a)*sin(2*d )^2 + (I*cos(2*d)*e^(2*a) + e^(2*a)*sin(2*d))*cos(4*b*x + 6*d) - 2*(I*cos( 2*d)*e^(2*a) + e^(2*a)*sin(2*d))*cos(2*b*x + 4*d) - (cos(2*d)*e^(2*a) - I* e^(2*a)*sin(2*d))*sin(4*b*x + 6*d) + 2*(cos(2*d)*e^(2*a) - I*e^(2*a)*sin(2 *d))*sin(2*b*x + 4*d))*log(cos(b*x)^2 + 2*cos(b*x)*cos(d) + cos(d)^2 + sin (b*x)^2 - 2*sin(b*x)*sin(d) + sin(d)^2) - (I*cos(2*d)^2*e^(2*a) + I*e^(2*a )*sin(2*d)^2 + (I*cos(2*d)*e^(2*a) + e^(2*a)*sin(2*d))*cos(4*b*x + 6*d) - 2*(I*cos(2*d)*e^(2*a) + e^(2*a)*sin(2*d))*cos(2*b*x + 4*d) - (cos(2*d)*e^( 2*a) - I*e^(2*a)*sin(2*d))*sin(4*b*x + 6*d) + 2*(cos(2*d)*e^(2*a) - I*e^(2 *a)*sin(2*d))*sin(2*b*x + 4*d))*log(cos(b*x)^2 - 2*cos(b*x)*cos(d) + cos(d )^2 + sin(b*x)^2 + 2*sin(b*x)*sin(d) + sin(d)^2) - 6*e^(2*a)*sin(2*b*x ...
Time = 0.13 (sec) , antiderivative size = 120, normalized size of antiderivative = 1.21 \[ \int e^{2 (a+i b x)} \cot (d+b x) \csc ^2(d+b x) \, dx=-\frac {2 \, {\left (e^{\left (4 i \, b x + 2 \, a + 2 i \, d\right )} \log \left (e^{\left (2 i \, b x + 2 i \, d\right )} - 1\right ) - 2 \, e^{\left (2 i \, b x + 2 \, a\right )} \log \left (e^{\left (2 i \, b x + 2 i \, d\right )} - 1\right ) + e^{\left (2 \, a - 2 i \, d\right )} \log \left (e^{\left (2 i \, b x + 2 i \, d\right )} - 1\right ) - 3 \, e^{\left (2 i \, b x + 2 \, a\right )} + 2 \, e^{\left (2 \, a - 2 i \, d\right )}\right )}}{b {\left (e^{\left (4 i \, b x + 4 i \, d\right )} - 2 \, e^{\left (2 i \, b x + 2 i \, d\right )} + 1\right )}} \] Input:
integrate(exp(2*a+2*I*b*x)*cot(b*x+d)*csc(b*x+d)^2,x, algorithm="giac")
Output:
-2*(e^(4*I*b*x + 2*a + 2*I*d)*log(e^(2*I*b*x + 2*I*d) - 1) - 2*e^(2*I*b*x + 2*a)*log(e^(2*I*b*x + 2*I*d) - 1) + e^(2*a - 2*I*d)*log(e^(2*I*b*x + 2*I *d) - 1) - 3*e^(2*I*b*x + 2*a) + 2*e^(2*a - 2*I*d))/(b*(e^(4*I*b*x + 4*I*d ) - 2*e^(2*I*b*x + 2*I*d) + 1))
Timed out. \[ \int e^{2 (a+i b x)} \cot (d+b x) \csc ^2(d+b x) \, dx=\int \frac {\mathrm {cot}\left (d+b\,x\right )\,{\mathrm {e}}^{2\,a+b\,x\,2{}\mathrm {i}}}{{\sin \left (d+b\,x\right )}^2} \,d x \] Input:
int((cot(d + b*x)*exp(2*a + b*x*2i))/sin(d + b*x)^2,x)
Output:
int((cot(d + b*x)*exp(2*a + b*x*2i))/sin(d + b*x)^2, x)
\[ \int e^{2 (a+i b x)} \cot (d+b x) \csc ^2(d+b x) \, dx=e^{2 a} \left (\int e^{2 b i x} \cot \left (b x +d \right ) \csc \left (b x +d \right )^{2}d x \right ) \] Input:
int(exp(2*a+2*I*b*x)*cot(b*x+d)*csc(b*x+d)^2,x)
Output:
e**(2*a)*int(e**(2*b*i*x)*cot(b*x + d)*csc(b*x + d)**2,x)