\(\int \frac {(e x)^{-1+3 n}}{a+b \csc (c+d x^n)} \, dx\) [81]

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

Optimal result

Integrand size = 24, antiderivative size = 499 \[ \int \frac {(e x)^{-1+3 n}}{a+b \csc \left (c+d x^n\right )} \, dx=\frac {(e x)^{3 n}}{3 a e n}+\frac {i b x^{-n} (e x)^{3 n} \log \left (1-\frac {i a e^{i \left (c+d x^n\right )}}{b-\sqrt {-a^2+b^2}}\right )}{a \sqrt {-a^2+b^2} d e n}-\frac {i b x^{-n} (e x)^{3 n} \log \left (1-\frac {i a e^{i \left (c+d x^n\right )}}{b+\sqrt {-a^2+b^2}}\right )}{a \sqrt {-a^2+b^2} d e n}+\frac {2 b x^{-2 n} (e x)^{3 n} \operatorname {PolyLog}\left (2,\frac {i a e^{i \left (c+d x^n\right )}}{b-\sqrt {-a^2+b^2}}\right )}{a \sqrt {-a^2+b^2} d^2 e n}-\frac {2 b x^{-2 n} (e x)^{3 n} \operatorname {PolyLog}\left (2,\frac {i a e^{i \left (c+d x^n\right )}}{b+\sqrt {-a^2+b^2}}\right )}{a \sqrt {-a^2+b^2} d^2 e n}+\frac {2 i b x^{-3 n} (e x)^{3 n} \operatorname {PolyLog}\left (3,\frac {i a e^{i \left (c+d x^n\right )}}{b-\sqrt {-a^2+b^2}}\right )}{a \sqrt {-a^2+b^2} d^3 e n}-\frac {2 i b x^{-3 n} (e x)^{3 n} \operatorname {PolyLog}\left (3,\frac {i a e^{i \left (c+d x^n\right )}}{b+\sqrt {-a^2+b^2}}\right )}{a \sqrt {-a^2+b^2} d^3 e n} \] Output:

1/3*(e*x)^(3*n)/a/e/n+I*b*(e*x)^(3*n)*ln(1-I*a*exp(I*(c+d*x^n))/(b-(-a^2+b 
^2)^(1/2)))/a/(-a^2+b^2)^(1/2)/d/e/n/(x^n)-I*b*(e*x)^(3*n)*ln(1-I*a*exp(I* 
(c+d*x^n))/(b+(-a^2+b^2)^(1/2)))/a/(-a^2+b^2)^(1/2)/d/e/n/(x^n)+2*b*(e*x)^ 
(3*n)*polylog(2,I*a*exp(I*(c+d*x^n))/(b-(-a^2+b^2)^(1/2)))/a/(-a^2+b^2)^(1 
/2)/d^2/e/n/(x^(2*n))-2*b*(e*x)^(3*n)*polylog(2,I*a*exp(I*(c+d*x^n))/(b+(- 
a^2+b^2)^(1/2)))/a/(-a^2+b^2)^(1/2)/d^2/e/n/(x^(2*n))+2*I*b*(e*x)^(3*n)*po 
lylog(3,I*a*exp(I*(c+d*x^n))/(b-(-a^2+b^2)^(1/2)))/a/(-a^2+b^2)^(1/2)/d^3/ 
e/n/(x^(3*n))-2*I*b*(e*x)^(3*n)*polylog(3,I*a*exp(I*(c+d*x^n))/(b+(-a^2+b^ 
2)^(1/2)))/a/(-a^2+b^2)^(1/2)/d^3/e/n/(x^(3*n))
 

Mathematica [F]

\[ \int \frac {(e x)^{-1+3 n}}{a+b \csc \left (c+d x^n\right )} \, dx=\int \frac {(e x)^{-1+3 n}}{a+b \csc \left (c+d x^n\right )} \, dx \] Input:

Integrate[(e*x)^(-1 + 3*n)/(a + b*Csc[c + d*x^n]),x]
 

Output:

Integrate[(e*x)^(-1 + 3*n)/(a + b*Csc[c + d*x^n]), x]
 

Rubi [A] (verified)

Time = 1.15 (sec) , antiderivative size = 418, normalized size of antiderivative = 0.84, number of steps used = 6, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.208, Rules used = {4697, 4693, 3042, 4679, 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 \frac {(e x)^{3 n-1}}{a+b \csc \left (c+d x^n\right )} \, dx\)

\(\Big \downarrow \) 4697

\(\displaystyle \frac {x^{-3 n} (e x)^{3 n} \int \frac {x^{3 n-1}}{a+b \csc \left (d x^n+c\right )}dx}{e}\)

\(\Big \downarrow \) 4693

\(\displaystyle \frac {x^{-3 n} (e x)^{3 n} \int \frac {x^{2 n}}{a+b \csc \left (d x^n+c\right )}dx^n}{e n}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {x^{-3 n} (e x)^{3 n} \int \frac {x^{2 n}}{a+b \csc \left (d x^n+c\right )}dx^n}{e n}\)

\(\Big \downarrow \) 4679

\(\displaystyle \frac {x^{-3 n} (e x)^{3 n} \int \left (\frac {x^{2 n}}{a}-\frac {b x^{2 n}}{a \left (b+a \sin \left (d x^n+c\right )\right )}\right )dx^n}{e n}\)

\(\Big \downarrow \) 2009

\(\displaystyle \frac {x^{-3 n} (e x)^{3 n} \left (\frac {2 i b \operatorname {PolyLog}\left (3,\frac {i a e^{i \left (d x^n+c\right )}}{b-\sqrt {b^2-a^2}}\right )}{a d^3 \sqrt {b^2-a^2}}-\frac {2 i b \operatorname {PolyLog}\left (3,\frac {i a e^{i \left (d x^n+c\right )}}{b+\sqrt {b^2-a^2}}\right )}{a d^3 \sqrt {b^2-a^2}}+\frac {2 b x^n \operatorname {PolyLog}\left (2,\frac {i a e^{i \left (d x^n+c\right )}}{b-\sqrt {b^2-a^2}}\right )}{a d^2 \sqrt {b^2-a^2}}-\frac {2 b x^n \operatorname {PolyLog}\left (2,\frac {i a e^{i \left (d x^n+c\right )}}{b+\sqrt {b^2-a^2}}\right )}{a d^2 \sqrt {b^2-a^2}}+\frac {i b x^{2 n} \log \left (1-\frac {i a e^{i \left (c+d x^n\right )}}{b-\sqrt {b^2-a^2}}\right )}{a d \sqrt {b^2-a^2}}-\frac {i b x^{2 n} \log \left (1-\frac {i a e^{i \left (c+d x^n\right )}}{\sqrt {b^2-a^2}+b}\right )}{a d \sqrt {b^2-a^2}}+\frac {x^{3 n}}{3 a}\right )}{e n}\)

Input:

Int[(e*x)^(-1 + 3*n)/(a + b*Csc[c + d*x^n]),x]
 

Output:

((e*x)^(3*n)*(x^(3*n)/(3*a) + (I*b*x^(2*n)*Log[1 - (I*a*E^(I*(c + d*x^n))) 
/(b - Sqrt[-a^2 + b^2])])/(a*Sqrt[-a^2 + b^2]*d) - (I*b*x^(2*n)*Log[1 - (I 
*a*E^(I*(c + d*x^n)))/(b + Sqrt[-a^2 + b^2])])/(a*Sqrt[-a^2 + b^2]*d) + (2 
*b*x^n*PolyLog[2, (I*a*E^(I*(c + d*x^n)))/(b - Sqrt[-a^2 + b^2])])/(a*Sqrt 
[-a^2 + b^2]*d^2) - (2*b*x^n*PolyLog[2, (I*a*E^(I*(c + d*x^n)))/(b + Sqrt[ 
-a^2 + b^2])])/(a*Sqrt[-a^2 + b^2]*d^2) + ((2*I)*b*PolyLog[3, (I*a*E^(I*(c 
 + d*x^n)))/(b - Sqrt[-a^2 + b^2])])/(a*Sqrt[-a^2 + b^2]*d^3) - ((2*I)*b*P 
olyLog[3, (I*a*E^(I*(c + d*x^n)))/(b + Sqrt[-a^2 + b^2])])/(a*Sqrt[-a^2 + 
b^2]*d^3)))/(e*n*x^(3*n))
 

Defintions of rubi rules used

rule 2009
Int[u_, x_Symbol] :> Simp[IntSum[u, x], x] /; SumQ[u]
 

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

rule 4679
Int[(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(n_.)*((c_.) + (d_.)*(x_))^(m_.) 
, x_Symbol] :> Int[ExpandIntegrand[(c + d*x)^m, 1/(Sin[e + f*x]^n/(b + a*Si 
n[e + f*x])^n), x], x] /; FreeQ[{a, b, c, d, e, f}, x] && ILtQ[n, 0] && IGt 
Q[m, 0]
 

rule 4693
Int[((a_.) + Csc[(c_.) + (d_.)*(x_)^(n_)]*(b_.))^(p_.)*(x_)^(m_.), x_Symbol 
] :> Simp[1/n   Subst[Int[x^(Simplify[(m + 1)/n] - 1)*(a + b*Csc[c + d*x])^ 
p, x], x, x^n], x] /; FreeQ[{a, b, c, d, m, n, p}, x] && IGtQ[Simplify[(m + 
 1)/n], 0] && IntegerQ[p]
 

rule 4697
Int[((a_.) + Csc[(c_.) + (d_.)*(x_)^(n_)]*(b_.))^(p_.)*((e_)*(x_))^(m_.), x 
_Symbol] :> Simp[e^IntPart[m]*((e*x)^FracPart[m]/x^FracPart[m])   Int[x^m*( 
a + b*Csc[c + d*x^n])^p, x], x] /; FreeQ[{a, b, c, d, e, m, n, p}, x]
 
Maple [F]

\[\int \frac {\left (e x \right )^{-1+3 n}}{a +b \csc \left (c +d \,x^{n}\right )}d x\]

Input:

int((e*x)^(-1+3*n)/(a+b*csc(c+d*x^n)),x)
 

Output:

int((e*x)^(-1+3*n)/(a+b*csc(c+d*x^n)),x)
 

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. 1663 vs. \(2 (447) = 894\).

Time = 0.28 (sec) , antiderivative size = 1663, normalized size of antiderivative = 3.33 \[ \int \frac {(e x)^{-1+3 n}}{a+b \csc \left (c+d x^n\right )} \, dx=\text {Too large to display} \] Input:

integrate((e*x)^(-1+3*n)/(a+b*csc(c+d*x^n)),x, algorithm="fricas")
 

Output:

1/6*(6*I*a*b*d*e^(3*n - 1)*x^n*sqrt((a^2 - b^2)/a^2)*dilog(((a*sqrt((a^2 - 
 b^2)/a^2) + I*b)*cos(d*x^n + c) + (I*a*sqrt((a^2 - b^2)/a^2) - b)*sin(d*x 
^n + c) - a)/a + 1) + 6*I*a*b*d*e^(3*n - 1)*x^n*sqrt((a^2 - b^2)/a^2)*dilo 
g(-((a*sqrt((a^2 - b^2)/a^2) + I*b)*cos(d*x^n + c) - (I*a*sqrt((a^2 - b^2) 
/a^2) - b)*sin(d*x^n + c) + a)/a + 1) - 6*I*a*b*d*e^(3*n - 1)*x^n*sqrt((a^ 
2 - b^2)/a^2)*dilog(((a*sqrt((a^2 - b^2)/a^2) - I*b)*cos(d*x^n + c) + (-I* 
a*sqrt((a^2 - b^2)/a^2) - b)*sin(d*x^n + c) - a)/a + 1) - 6*I*a*b*d*e^(3*n 
 - 1)*x^n*sqrt((a^2 - b^2)/a^2)*dilog(-((a*sqrt((a^2 - b^2)/a^2) - I*b)*co 
s(d*x^n + c) - (-I*a*sqrt((a^2 - b^2)/a^2) - b)*sin(d*x^n + c) + a)/a + 1) 
 + 3*a*b*c^2*e^(3*n - 1)*sqrt((a^2 - b^2)/a^2)*log(2*a*cos(d*x^n + c) + 2* 
I*a*sin(d*x^n + c) + 2*a*sqrt((a^2 - b^2)/a^2) + 2*I*b) + 3*a*b*c^2*e^(3*n 
 - 1)*sqrt((a^2 - b^2)/a^2)*log(2*a*cos(d*x^n + c) - 2*I*a*sin(d*x^n + c) 
+ 2*a*sqrt((a^2 - b^2)/a^2) - 2*I*b) - 3*a*b*c^2*e^(3*n - 1)*sqrt((a^2 - b 
^2)/a^2)*log(-2*a*cos(d*x^n + c) + 2*I*a*sin(d*x^n + c) + 2*a*sqrt((a^2 - 
b^2)/a^2) + 2*I*b) - 3*a*b*c^2*e^(3*n - 1)*sqrt((a^2 - b^2)/a^2)*log(-2*a* 
cos(d*x^n + c) - 2*I*a*sin(d*x^n + c) + 2*a*sqrt((a^2 - b^2)/a^2) - 2*I*b) 
 + 2*(a^2 - b^2)*d^3*e^(3*n - 1)*x^(3*n) + 6*a*b*e^(3*n - 1)*sqrt((a^2 - b 
^2)/a^2)*polylog(3, -((a*sqrt((a^2 - b^2)/a^2) + I*b)*cos(d*x^n + c) + (-I 
*a*sqrt((a^2 - b^2)/a^2) + b)*sin(d*x^n + c))/a) - 6*a*b*e^(3*n - 1)*sqrt( 
(a^2 - b^2)/a^2)*polylog(3, ((a*sqrt((a^2 - b^2)/a^2) + I*b)*cos(d*x^n ...
 

Sympy [F]

\[ \int \frac {(e x)^{-1+3 n}}{a+b \csc \left (c+d x^n\right )} \, dx=\int \frac {\left (e x\right )^{3 n - 1}}{a + b \csc {\left (c + d x^{n} \right )}}\, dx \] Input:

integrate((e*x)**(-1+3*n)/(a+b*csc(c+d*x**n)),x)
 

Output:

Integral((e*x)**(3*n - 1)/(a + b*csc(c + d*x**n)), x)
 

Maxima [F]

\[ \int \frac {(e x)^{-1+3 n}}{a+b \csc \left (c+d x^n\right )} \, dx=\int { \frac {\left (e x\right )^{3 \, n - 1}}{b \csc \left (d x^{n} + c\right ) + a} \,d x } \] Input:

integrate((e*x)^(-1+3*n)/(a+b*csc(c+d*x^n)),x, algorithm="maxima")
 

Output:

-1/3*(6*a*b*e^(3*n + 1)*n*integrate((2*b*x^(3*n)*cos(d*x^n + c)^2 + a*x^(3 
*n)*cos(d*x^n + c)*sin(2*d*x^n + 2*c) - a*x^(3*n)*cos(2*d*x^n + 2*c)*sin(d 
*x^n + c) + 2*b*x^(3*n)*sin(d*x^n + c)^2 + a*x^(3*n)*sin(d*x^n + c))/(a^3* 
e*x*cos(2*d*x^n + 2*c)^2 + 4*a*b^2*e*x*cos(d*x^n + c)^2 + 4*a^2*b*e*x*cos( 
d*x^n + c)*sin(2*d*x^n + 2*c) + a^3*e*x*sin(2*d*x^n + 2*c)^2 + 4*a*b^2*e*x 
*sin(d*x^n + c)^2 + 4*a^2*b*e*x*sin(d*x^n + c) + a^3*e*x - 2*(2*a^2*b*e*x* 
sin(d*x^n + c) + a^3*e*x)*cos(2*d*x^n + 2*c)), x) - e^(3*n)*x^(3*n))/(a*e* 
n)
 

Giac [F]

\[ \int \frac {(e x)^{-1+3 n}}{a+b \csc \left (c+d x^n\right )} \, dx=\int { \frac {\left (e x\right )^{3 \, n - 1}}{b \csc \left (d x^{n} + c\right ) + a} \,d x } \] Input:

integrate((e*x)^(-1+3*n)/(a+b*csc(c+d*x^n)),x, algorithm="giac")
                                                                                    
                                                                                    
 

Output:

integrate((e*x)^(3*n - 1)/(b*csc(d*x^n + c) + a), x)
 

Mupad [F(-1)]

Timed out. \[ \int \frac {(e x)^{-1+3 n}}{a+b \csc \left (c+d x^n\right )} \, dx=\int \frac {{\left (e\,x\right )}^{3\,n-1}}{a+\frac {b}{\sin \left (c+d\,x^n\right )}} \,d x \] Input:

int((e*x)^(3*n - 1)/(a + b/sin(c + d*x^n)),x)
 

Output:

int((e*x)^(3*n - 1)/(a + b/sin(c + d*x^n)), x)
 

Reduce [F]

\[ \int \frac {(e x)^{-1+3 n}}{a+b \csc \left (c+d x^n\right )} \, dx=\frac {e^{3 n} \left (\int \frac {x^{3 n}}{\csc \left (x^{n} d +c \right ) b x +a x}d x \right )}{e} \] Input:

int((e*x)^(-1+3*n)/(a+b*csc(c+d*x^n)),x)
 

Output:

(e**(3*n)*int(x**(3*n)/(csc(x**n*d + c)*b*x + a*x),x))/e