\(\int \coth ^p(d (a+b \log (c x^n))) \, dx\) [202]

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

Optimal result

Integrand size = 15, antiderivative size = 115 \[ \int \coth ^p\left (d \left (a+b \log \left (c x^n\right )\right )\right ) \, dx=x \left (-1-e^{2 a d} \left (c x^n\right )^{2 b d}\right )^p \left (1+e^{2 a d} \left (c x^n\right )^{2 b d}\right )^{-p} \operatorname {AppellF1}\left (\frac {1}{2 b d n},p,-p,1+\frac {1}{2 b d n},e^{2 a d} \left (c x^n\right )^{2 b d},-e^{2 a d} \left (c x^n\right )^{2 b d}\right ) \] Output:

x*(-1-exp(2*a*d)*(c*x^n)^(2*b*d))^p*AppellF1(1/2/b/d/n,p,-p,1+1/2/b/d/n,ex 
p(2*a*d)*(c*x^n)^(2*b*d),-exp(2*a*d)*(c*x^n)^(2*b*d))/((1+exp(2*a*d)*(c*x^ 
n)^(2*b*d))^p)
 

Mathematica [B] (warning: unable to verify)

Leaf count is larger than twice the leaf count of optimal. \(387\) vs. \(2(115)=230\).

Time = 0.82 (sec) , antiderivative size = 387, normalized size of antiderivative = 3.37 \[ \int \coth ^p\left (d \left (a+b \log \left (c x^n\right )\right )\right ) \, dx=\frac {(1+2 b d n) x \left (\frac {1+e^{2 a d} \left (c x^n\right )^{2 b d}}{-1+e^{2 a d} \left (c x^n\right )^{2 b d}}\right )^p \operatorname {AppellF1}\left (\frac {1}{2 b d n},p,-p,1+\frac {1}{2 b d n},e^{2 a d} \left (c x^n\right )^{2 b d},-e^{2 a d} \left (c x^n\right )^{2 b d}\right )}{2 b d e^{2 a d} n p \left (c x^n\right )^{2 b d} \operatorname {AppellF1}\left (1+\frac {1}{2 b d n},p,1-p,2+\frac {1}{2 b d n},e^{2 a d} \left (c x^n\right )^{2 b d},-e^{2 a d} \left (c x^n\right )^{2 b d}\right )+2 b d e^{2 a d} n p \left (c x^n\right )^{2 b d} \operatorname {AppellF1}\left (1+\frac {1}{2 b d n},1+p,-p,2+\frac {1}{2 b d n},e^{2 a d} \left (c x^n\right )^{2 b d},-e^{2 a d} \left (c x^n\right )^{2 b d}\right )+(1+2 b d n) \operatorname {AppellF1}\left (\frac {1}{2 b d n},p,-p,1+\frac {1}{2 b d n},e^{2 a d} \left (c x^n\right )^{2 b d},-e^{2 a d} \left (c x^n\right )^{2 b d}\right )} \] Input:

Integrate[Coth[d*(a + b*Log[c*x^n])]^p,x]
 

Output:

((1 + 2*b*d*n)*x*((1 + E^(2*a*d)*(c*x^n)^(2*b*d))/(-1 + E^(2*a*d)*(c*x^n)^ 
(2*b*d)))^p*AppellF1[1/(2*b*d*n), p, -p, 1 + 1/(2*b*d*n), E^(2*a*d)*(c*x^n 
)^(2*b*d), -(E^(2*a*d)*(c*x^n)^(2*b*d))])/(2*b*d*E^(2*a*d)*n*p*(c*x^n)^(2* 
b*d)*AppellF1[1 + 1/(2*b*d*n), p, 1 - p, 2 + 1/(2*b*d*n), E^(2*a*d)*(c*x^n 
)^(2*b*d), -(E^(2*a*d)*(c*x^n)^(2*b*d))] + 2*b*d*E^(2*a*d)*n*p*(c*x^n)^(2* 
b*d)*AppellF1[1 + 1/(2*b*d*n), 1 + p, -p, 2 + 1/(2*b*d*n), E^(2*a*d)*(c*x^ 
n)^(2*b*d), -(E^(2*a*d)*(c*x^n)^(2*b*d))] + (1 + 2*b*d*n)*AppellF1[1/(2*b* 
d*n), p, -p, 1 + 1/(2*b*d*n), E^(2*a*d)*(c*x^n)^(2*b*d), -(E^(2*a*d)*(c*x^ 
n)^(2*b*d))])
 

Rubi [A] (verified)

Time = 0.70 (sec) , antiderivative size = 115, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.267, Rules used = {6070, 6072, 1013, 1012}

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 \coth ^p\left (d \left (a+b \log \left (c x^n\right )\right )\right ) \, dx\)

\(\Big \downarrow \) 6070

\(\displaystyle \frac {x \left (c x^n\right )^{-1/n} \int \left (c x^n\right )^{\frac {1}{n}-1} \coth ^p\left (d \left (a+b \log \left (c x^n\right )\right )\right )d\left (c x^n\right )}{n}\)

\(\Big \downarrow \) 6072

\(\displaystyle \frac {x \left (c x^n\right )^{-1/n} \int \left (c x^n\right )^{\frac {1}{n}-1} \left (-e^{2 a d} \left (c x^n\right )^{2 b d}-1\right )^p \left (1-e^{2 a d} \left (c x^n\right )^{2 b d}\right )^{-p}d\left (c x^n\right )}{n}\)

\(\Big \downarrow \) 1013

\(\displaystyle \frac {x \left (c x^n\right )^{-1/n} \left (-e^{2 a d} \left (c x^n\right )^{2 b d}-1\right )^p \left (e^{2 a d} \left (c x^n\right )^{2 b d}+1\right )^{-p} \int \left (c x^n\right )^{\frac {1}{n}-1} \left (1-e^{2 a d} \left (c x^n\right )^{2 b d}\right )^{-p} \left (e^{2 a d} \left (c x^n\right )^{2 b d}+1\right )^pd\left (c x^n\right )}{n}\)

\(\Big \downarrow \) 1012

\(\displaystyle x \left (-e^{2 a d} \left (c x^n\right )^{2 b d}-1\right )^p \left (e^{2 a d} \left (c x^n\right )^{2 b d}+1\right )^{-p} \operatorname {AppellF1}\left (\frac {1}{2 b d n},p,-p,1+\frac {1}{2 b d n},e^{2 a d} \left (c x^n\right )^{2 b d},-e^{2 a d} \left (c x^n\right )^{2 b d}\right )\)

Input:

Int[Coth[d*(a + b*Log[c*x^n])]^p,x]
 

Output:

(x*(-1 - E^(2*a*d)*(c*x^n)^(2*b*d))^p*AppellF1[1/(2*b*d*n), p, -p, 1 + 1/( 
2*b*d*n), E^(2*a*d)*(c*x^n)^(2*b*d), -(E^(2*a*d)*(c*x^n)^(2*b*d))])/(1 + E 
^(2*a*d)*(c*x^n)^(2*b*d))^p
 

Defintions of rubi rules used

rule 1012
Int[((e_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_)*((c_) + (d_.)*(x_)^(n_ 
))^(q_), x_Symbol] :> Simp[a^p*c^q*((e*x)^(m + 1)/(e*(m + 1)))*AppellF1[(m 
+ 1)/n, -p, -q, 1 + (m + 1)/n, (-b)*(x^n/a), (-d)*(x^n/c)], x] /; FreeQ[{a, 
 b, c, d, e, m, n, p, q}, x] && NeQ[b*c - a*d, 0] && NeQ[m, -1] && NeQ[m, n 
 - 1] && (IntegerQ[p] || GtQ[a, 0]) && (IntegerQ[q] || GtQ[c, 0])
 

rule 1013
Int[((e_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_)*((c_) + (d_.)*(x_)^(n_ 
))^(q_), x_Symbol] :> Simp[a^IntPart[p]*((a + b*x^n)^FracPart[p]/(1 + b*(x^ 
n/a))^FracPart[p])   Int[(e*x)^m*(1 + b*(x^n/a))^p*(c + d*x^n)^q, x], x] /; 
 FreeQ[{a, b, c, d, e, m, n, p, q}, x] && NeQ[b*c - a*d, 0] && NeQ[m, -1] & 
& NeQ[m, n - 1] &&  !(IntegerQ[p] || GtQ[a, 0])
 

rule 6070
Int[Coth[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))*(d_.)]^(p_.), x_Symbol] :> S 
imp[x/(n*(c*x^n)^(1/n))   Subst[Int[x^(1/n - 1)*Coth[d*(a + b*Log[x])]^p, x 
], x, c*x^n], x] /; FreeQ[{a, b, c, d, n, p}, x] && (NeQ[c, 1] || NeQ[n, 1] 
)
 

rule 6072
Int[Coth[((a_.) + Log[x_]*(b_.))*(d_.)]^(p_.)*((e_.)*(x_))^(m_.), x_Symbol] 
 :> Int[(e*x)^m*((-1 - E^(2*a*d)*x^(2*b*d))^p/(1 - E^(2*a*d)*x^(2*b*d))^p), 
 x] /; FreeQ[{a, b, d, e, m, p}, x]
 
Maple [F]

\[\int {\coth \left (d \left (a +b \ln \left (c \,x^{n}\right )\right )\right )}^{p}d x\]

Input:

int(coth(d*(a+b*ln(c*x^n)))^p,x)
 

Output:

int(coth(d*(a+b*ln(c*x^n)))^p,x)
 

Fricas [F]

\[ \int \coth ^p\left (d \left (a+b \log \left (c x^n\right )\right )\right ) \, dx=\int { \coth \left ({\left (b \log \left (c x^{n}\right ) + a\right )} d\right )^{p} \,d x } \] Input:

integrate(coth(d*(a+b*log(c*x^n)))^p,x, algorithm="fricas")
 

Output:

integral(coth(b*d*log(c*x^n) + a*d)^p, x)
 

Sympy [F]

\[ \int \coth ^p\left (d \left (a+b \log \left (c x^n\right )\right )\right ) \, dx=\int \coth ^{p}{\left (d \left (a + b \log {\left (c x^{n} \right )}\right ) \right )}\, dx \] Input:

integrate(coth(d*(a+b*ln(c*x**n)))**p,x)
 

Output:

Integral(coth(d*(a + b*log(c*x**n)))**p, x)
 

Maxima [F]

\[ \int \coth ^p\left (d \left (a+b \log \left (c x^n\right )\right )\right ) \, dx=\int { \coth \left ({\left (b \log \left (c x^{n}\right ) + a\right )} d\right )^{p} \,d x } \] Input:

integrate(coth(d*(a+b*log(c*x^n)))^p,x, algorithm="maxima")
 

Output:

integrate(coth((b*log(c*x^n) + a)*d)^p, x)
 

Giac [F]

\[ \int \coth ^p\left (d \left (a+b \log \left (c x^n\right )\right )\right ) \, dx=\int { \coth \left ({\left (b \log \left (c x^{n}\right ) + a\right )} d\right )^{p} \,d x } \] Input:

integrate(coth(d*(a+b*log(c*x^n)))^p,x, algorithm="giac")
 

Output:

integrate(coth((b*log(c*x^n) + a)*d)^p, x)
 

Mupad [F(-1)]

Timed out. \[ \int \coth ^p\left (d \left (a+b \log \left (c x^n\right )\right )\right ) \, dx=\int {\mathrm {coth}\left (d\,\left (a+b\,\ln \left (c\,x^n\right )\right )\right )}^p \,d x \] Input:

int(coth(d*(a + b*log(c*x^n)))^p,x)
 

Output:

int(coth(d*(a + b*log(c*x^n)))^p, x)
 

Reduce [F]

\[ \int \coth ^p\left (d \left (a+b \log \left (c x^n\right )\right )\right ) \, dx={\coth \left (\mathrm {log}\left (x^{n} c \right ) b d +a d \right )}^{p} x -\left (\int \frac {{\coth \left (\mathrm {log}\left (x^{n} c \right ) b d +a d \right )}^{p}}{\coth \left (\mathrm {log}\left (x^{n} c \right ) b d +a d \right )}d x \right ) b d n p +\left (\int {\coth \left (\mathrm {log}\left (x^{n} c \right ) b d +a d \right )}^{p} \coth \left (\mathrm {log}\left (x^{n} c \right ) b d +a d \right )d x \right ) b d n p \] Input:

int(coth(d*(a+b*log(c*x^n)))^p,x)
 

Output:

coth(log(x**n*c)*b*d + a*d)**p*x - int(coth(log(x**n*c)*b*d + a*d)**p/coth 
(log(x**n*c)*b*d + a*d),x)*b*d*n*p + int(coth(log(x**n*c)*b*d + a*d)**p*co 
th(log(x**n*c)*b*d + a*d),x)*b*d*n*p