\(\int \frac {\sqrt {\coth (a+b \log (c x^n))}}{x} \, dx\) [201]

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

Optimal result

Integrand size = 19, antiderivative size = 48 \[ \int \frac {\sqrt {\coth \left (a+b \log \left (c x^n\right )\right )}}{x} \, dx=-\frac {\arctan \left (\sqrt {\coth \left (a+b \log \left (c x^n\right )\right )}\right )}{b n}+\frac {\text {arctanh}\left (\sqrt {\coth \left (a+b \log \left (c x^n\right )\right )}\right )}{b n} \]

[Out]

-arctan(coth(a+b*ln(c*x^n))^(1/2))/b/n+arctanh(coth(a+b*ln(c*x^n))^(1/2))/b/n

Rubi [A] (verified)

Time = 0.03 (sec) , antiderivative size = 48, normalized size of antiderivative = 1.00, number of steps used = 6, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.263, Rules used = {3557, 335, 304, 209, 212} \[ \int \frac {\sqrt {\coth \left (a+b \log \left (c x^n\right )\right )}}{x} \, dx=\frac {\text {arctanh}\left (\sqrt {\coth \left (a+b \log \left (c x^n\right )\right )}\right )}{b n}-\frac {\arctan \left (\sqrt {\coth \left (a+b \log \left (c x^n\right )\right )}\right )}{b n} \]

[In]

Int[Sqrt[Coth[a + b*Log[c*x^n]]]/x,x]

[Out]

-(ArcTan[Sqrt[Coth[a + b*Log[c*x^n]]]]/(b*n)) + ArcTanh[Sqrt[Coth[a + b*Log[c*x^n]]]]/(b*n)

Rule 209

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[b, 2]))*ArcTan[Rt[b, 2]*(x/Rt[a, 2])], x] /;
 FreeQ[{a, b}, x] && PosQ[a/b] && (GtQ[a, 0] || GtQ[b, 0])

Rule 212

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[-b, 2]))*ArcTanh[Rt[-b, 2]*(x/Rt[a, 2])], x]
 /; FreeQ[{a, b}, x] && NegQ[a/b] && (GtQ[a, 0] || LtQ[b, 0])

Rule 304

Int[(x_)^2/((a_) + (b_.)*(x_)^4), x_Symbol] :> With[{r = Numerator[Rt[-a/b, 2]], s = Denominator[Rt[-a/b, 2]]}
, Dist[s/(2*b), Int[1/(r + s*x^2), x], x] - Dist[s/(2*b), Int[1/(r - s*x^2), x], x]] /; FreeQ[{a, b}, x] &&  !
GtQ[a/b, 0]

Rule 335

Int[((c_.)*(x_))^(m_)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> With[{k = Denominator[m]}, Dist[k/c, Subst[I
nt[x^(k*(m + 1) - 1)*(a + b*(x^(k*n)/c^n))^p, x], x, (c*x)^(1/k)], x]] /; FreeQ[{a, b, c, p}, x] && IGtQ[n, 0]
 && FractionQ[m] && IntBinomialQ[a, b, c, n, m, p, x]

Rule 3557

Int[((b_.)*tan[(c_.) + (d_.)*(x_)])^(n_), x_Symbol] :> Dist[b/d, Subst[Int[x^n/(b^2 + x^2), x], x, b*Tan[c + d
*x]], x] /; FreeQ[{b, c, d, n}, x] &&  !IntegerQ[n]

Rubi steps \begin{align*} \text {integral}& = \frac {\text {Subst}\left (\int \sqrt {\coth (a+b x)} \, dx,x,\log \left (c x^n\right )\right )}{n} \\ & = -\frac {\text {Subst}\left (\int \frac {\sqrt {x}}{-1+x^2} \, dx,x,\coth \left (a+b \log \left (c x^n\right )\right )\right )}{b n} \\ & = -\frac {2 \text {Subst}\left (\int \frac {x^2}{-1+x^4} \, dx,x,\sqrt {\coth \left (a+b \log \left (c x^n\right )\right )}\right )}{b n} \\ & = \frac {\text {Subst}\left (\int \frac {1}{1-x^2} \, dx,x,\sqrt {\coth \left (a+b \log \left (c x^n\right )\right )}\right )}{b n}-\frac {\text {Subst}\left (\int \frac {1}{1+x^2} \, dx,x,\sqrt {\coth \left (a+b \log \left (c x^n\right )\right )}\right )}{b n} \\ & = -\frac {\arctan \left (\sqrt {\coth \left (a+b \log \left (c x^n\right )\right )}\right )}{b n}+\frac {\text {arctanh}\left (\sqrt {\coth \left (a+b \log \left (c x^n\right )\right )}\right )}{b n} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.09 (sec) , antiderivative size = 43, normalized size of antiderivative = 0.90 \[ \int \frac {\sqrt {\coth \left (a+b \log \left (c x^n\right )\right )}}{x} \, dx=-\frac {\arctan \left (\sqrt {\coth \left (a+b \log \left (c x^n\right )\right )}\right )-\text {arctanh}\left (\sqrt {\coth \left (a+b \log \left (c x^n\right )\right )}\right )}{b n} \]

[In]

Integrate[Sqrt[Coth[a + b*Log[c*x^n]]]/x,x]

[Out]

-((ArcTan[Sqrt[Coth[a + b*Log[c*x^n]]]] - ArcTanh[Sqrt[Coth[a + b*Log[c*x^n]]]])/(b*n))

Maple [A] (verified)

Time = 0.49 (sec) , antiderivative size = 61, normalized size of antiderivative = 1.27

method result size
derivativedivides \(\frac {-\frac {\ln \left (\sqrt {\coth \left (a +b \ln \left (c \,x^{n}\right )\right )}-1\right )}{2}+\frac {\ln \left (\sqrt {\coth \left (a +b \ln \left (c \,x^{n}\right )\right )}+1\right )}{2}-\arctan \left (\sqrt {\coth \left (a +b \ln \left (c \,x^{n}\right )\right )}\right )}{n b}\) \(61\)
default \(\frac {-\frac {\ln \left (\sqrt {\coth \left (a +b \ln \left (c \,x^{n}\right )\right )}-1\right )}{2}+\frac {\ln \left (\sqrt {\coth \left (a +b \ln \left (c \,x^{n}\right )\right )}+1\right )}{2}-\arctan \left (\sqrt {\coth \left (a +b \ln \left (c \,x^{n}\right )\right )}\right )}{n b}\) \(61\)

[In]

int(coth(a+b*ln(c*x^n))^(1/2)/x,x,method=_RETURNVERBOSE)

[Out]

1/n/b*(-1/2*ln(coth(a+b*ln(c*x^n))^(1/2)-1)+1/2*ln(coth(a+b*ln(c*x^n))^(1/2)+1)-arctan(coth(a+b*ln(c*x^n))^(1/
2)))

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 305 vs. \(2 (44) = 88\).

Time = 0.28 (sec) , antiderivative size = 305, normalized size of antiderivative = 6.35 \[ \int \frac {\sqrt {\coth \left (a+b \log \left (c x^n\right )\right )}}{x} \, dx=\frac {2 \, \arctan \left (-\cosh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )^{2} - 2 \, \cosh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right ) \sinh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right ) - \sinh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )^{2} + {\left (\cosh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )^{2} + 2 \, \cosh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right ) \sinh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right ) + \sinh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )^{2} - 1\right )} \sqrt {\frac {\cosh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )}{\sinh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )}}\right ) - \log \left (-\cosh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )^{2} - 2 \, \cosh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right ) \sinh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right ) - \sinh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )^{2} + {\left (\cosh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )^{2} + 2 \, \cosh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right ) \sinh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right ) + \sinh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )^{2} - 1\right )} \sqrt {\frac {\cosh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )}{\sinh \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )}}\right )}{2 \, b n} \]

[In]

integrate(coth(a+b*log(c*x^n))^(1/2)/x,x, algorithm="fricas")

[Out]

1/2*(2*arctan(-cosh(b*n*log(x) + b*log(c) + a)^2 - 2*cosh(b*n*log(x) + b*log(c) + a)*sinh(b*n*log(x) + b*log(c
) + a) - sinh(b*n*log(x) + b*log(c) + a)^2 + (cosh(b*n*log(x) + b*log(c) + a)^2 + 2*cosh(b*n*log(x) + b*log(c)
 + a)*sinh(b*n*log(x) + b*log(c) + a) + sinh(b*n*log(x) + b*log(c) + a)^2 - 1)*sqrt(cosh(b*n*log(x) + b*log(c)
 + a)/sinh(b*n*log(x) + b*log(c) + a))) - log(-cosh(b*n*log(x) + b*log(c) + a)^2 - 2*cosh(b*n*log(x) + b*log(c
) + a)*sinh(b*n*log(x) + b*log(c) + a) - sinh(b*n*log(x) + b*log(c) + a)^2 + (cosh(b*n*log(x) + b*log(c) + a)^
2 + 2*cosh(b*n*log(x) + b*log(c) + a)*sinh(b*n*log(x) + b*log(c) + a) + sinh(b*n*log(x) + b*log(c) + a)^2 - 1)
*sqrt(cosh(b*n*log(x) + b*log(c) + a)/sinh(b*n*log(x) + b*log(c) + a))))/(b*n)

Sympy [F]

\[ \int \frac {\sqrt {\coth \left (a+b \log \left (c x^n\right )\right )}}{x} \, dx=\int \frac {\sqrt {\coth {\left (a + b \log {\left (c x^{n} \right )} \right )}}}{x}\, dx \]

[In]

integrate(coth(a+b*ln(c*x**n))**(1/2)/x,x)

[Out]

Integral(sqrt(coth(a + b*log(c*x**n)))/x, x)

Maxima [F]

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

[In]

integrate(coth(a+b*log(c*x^n))^(1/2)/x,x, algorithm="maxima")

[Out]

integrate(sqrt(coth(b*log(c*x^n) + a))/x, x)

Giac [F(-1)]

Timed out. \[ \int \frac {\sqrt {\coth \left (a+b \log \left (c x^n\right )\right )}}{x} \, dx=\text {Timed out} \]

[In]

integrate(coth(a+b*log(c*x^n))^(1/2)/x,x, algorithm="giac")

[Out]

Timed out

Mupad [B] (verification not implemented)

Time = 2.21 (sec) , antiderivative size = 39, normalized size of antiderivative = 0.81 \[ \int \frac {\sqrt {\coth \left (a+b \log \left (c x^n\right )\right )}}{x} \, dx=-\frac {\mathrm {atan}\left (\sqrt {\mathrm {coth}\left (a+b\,\ln \left (c\,x^n\right )\right )}\right )-\mathrm {atanh}\left (\sqrt {\mathrm {coth}\left (a+b\,\ln \left (c\,x^n\right )\right )}\right )}{b\,n} \]

[In]

int(coth(a + b*log(c*x^n))^(1/2)/x,x)

[Out]

-(atan(coth(a + b*log(c*x^n))^(1/2)) - atanh(coth(a + b*log(c*x^n))^(1/2)))/(b*n)