3.146 \(\int \frac {1}{x^2 \sqrt {\tanh ^{-1}(\tanh (a+b x))}} \, dx\)

Optimal. Leaf size=94 \[ \frac {b}{\left (b x-\tanh ^{-1}(\tanh (a+b x))\right ) \sqrt {\tanh ^{-1}(\tanh (a+b x))}}-\frac {1}{x \sqrt {\tanh ^{-1}(\tanh (a+b x))}}+\frac {b \tan ^{-1}\left (\frac {\sqrt {\tanh ^{-1}(\tanh (a+b x))}}{\sqrt {b x-\tanh ^{-1}(\tanh (a+b x))}}\right )}{\left (b x-\tanh ^{-1}(\tanh (a+b x))\right )^{3/2}} \]

[Out]

b*arctan(arctanh(tanh(b*x+a))^(1/2)/(b*x-arctanh(tanh(b*x+a)))^(1/2))/(b*x-arctanh(tanh(b*x+a)))^(3/2)-1/x/arc
tanh(tanh(b*x+a))^(1/2)+b/(b*x-arctanh(tanh(b*x+a)))/arctanh(tanh(b*x+a))^(1/2)

________________________________________________________________________________________

Rubi [A]  time = 0.05, antiderivative size = 94, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, integrand size = 15, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.200, Rules used = {2168, 2163, 2161} \[ \frac {b}{\left (b x-\tanh ^{-1}(\tanh (a+b x))\right ) \sqrt {\tanh ^{-1}(\tanh (a+b x))}}-\frac {1}{x \sqrt {\tanh ^{-1}(\tanh (a+b x))}}+\frac {b \tan ^{-1}\left (\frac {\sqrt {\tanh ^{-1}(\tanh (a+b x))}}{\sqrt {b x-\tanh ^{-1}(\tanh (a+b x))}}\right )}{\left (b x-\tanh ^{-1}(\tanh (a+b x))\right )^{3/2}} \]

Antiderivative was successfully verified.

[In]

Int[1/(x^2*Sqrt[ArcTanh[Tanh[a + b*x]]]),x]

[Out]

(b*ArcTan[Sqrt[ArcTanh[Tanh[a + b*x]]]/Sqrt[b*x - ArcTanh[Tanh[a + b*x]]]])/(b*x - ArcTanh[Tanh[a + b*x]])^(3/
2) - 1/(x*Sqrt[ArcTanh[Tanh[a + b*x]]]) + b/((b*x - ArcTanh[Tanh[a + b*x]])*Sqrt[ArcTanh[Tanh[a + b*x]]])

Rule 2161

Int[1/((u_)*Sqrt[v_]), x_Symbol] :> With[{a = Simplify[D[u, x]], b = Simplify[D[v, x]]}, Simp[(2*ArcTan[Sqrt[v
]/Rt[(b*u - a*v)/a, 2]])/(a*Rt[(b*u - a*v)/a, 2]), x] /; NeQ[b*u - a*v, 0] && PosQ[(b*u - a*v)/a]] /; Piecewis
eLinearQ[u, v, x]

Rule 2163

Int[(v_)^(n_)/(u_), x_Symbol] :> With[{a = Simplify[D[u, x]], b = Simplify[D[v, x]]}, Simp[v^(n + 1)/((n + 1)*
(b*u - a*v)), x] - Dist[(a*(n + 1))/((n + 1)*(b*u - a*v)), Int[v^(n + 1)/u, x], x] /; NeQ[b*u - a*v, 0]] /; Pi
ecewiseLinearQ[u, v, x] && LtQ[n, -1]

Rule 2168

Int[(u_)^(m_)*(v_)^(n_.), x_Symbol] :> With[{a = Simplify[D[u, x]], b = Simplify[D[v, x]]}, Simp[(u^(m + 1)*v^
n)/(a*(m + 1)), x] - Dist[(b*n)/(a*(m + 1)), Int[u^(m + 1)*v^(n - 1), x], x] /; NeQ[b*u - a*v, 0]] /; FreeQ[{m
, n}, x] && PiecewiseLinearQ[u, v, x] && NeQ[m, -1] && ((LtQ[m, -1] && GtQ[n, 0] &&  !(ILtQ[m + n, -2] && (Fra
ctionQ[m] || GeQ[2*n + m + 1, 0]))) || (IGtQ[n, 0] && IGtQ[m, 0] && LeQ[n, m]) || (IGtQ[n, 0] &&  !IntegerQ[m]
) || (ILtQ[m, 0] &&  !IntegerQ[n]))

Rubi steps

\begin {align*} \int \frac {1}{x^2 \sqrt {\tanh ^{-1}(\tanh (a+b x))}} \, dx &=-\frac {1}{x \sqrt {\tanh ^{-1}(\tanh (a+b x))}}-\frac {1}{2} b \int \frac {1}{x \tanh ^{-1}(\tanh (a+b x))^{3/2}} \, dx\\ &=-\frac {1}{x \sqrt {\tanh ^{-1}(\tanh (a+b x))}}+\frac {b}{\left (b x-\tanh ^{-1}(\tanh (a+b x))\right ) \sqrt {\tanh ^{-1}(\tanh (a+b x))}}-\frac {b \int \frac {1}{x \sqrt {\tanh ^{-1}(\tanh (a+b x))}} \, dx}{2 \left (-b x+\tanh ^{-1}(\tanh (a+b x))\right )}\\ &=\frac {b \tan ^{-1}\left (\frac {\sqrt {\tanh ^{-1}(\tanh (a+b x))}}{\sqrt {b x-\tanh ^{-1}(\tanh (a+b x))}}\right )}{\left (b x-\tanh ^{-1}(\tanh (a+b x))\right )^{3/2}}-\frac {1}{x \sqrt {\tanh ^{-1}(\tanh (a+b x))}}+\frac {b}{\left (b x-\tanh ^{-1}(\tanh (a+b x))\right ) \sqrt {\tanh ^{-1}(\tanh (a+b x))}}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.08, size = 78, normalized size = 0.83 \[ \frac {b \tanh ^{-1}\left (\frac {\sqrt {\tanh ^{-1}(\tanh (a+b x))}}{\sqrt {\tanh ^{-1}(\tanh (a+b x))-b x}}\right )}{\left (\tanh ^{-1}(\tanh (a+b x))-b x\right )^{3/2}}-\frac {\sqrt {\tanh ^{-1}(\tanh (a+b x))}}{x \left (\tanh ^{-1}(\tanh (a+b x))-b x\right )} \]

Antiderivative was successfully verified.

[In]

Integrate[1/(x^2*Sqrt[ArcTanh[Tanh[a + b*x]]]),x]

[Out]

(b*ArcTanh[Sqrt[ArcTanh[Tanh[a + b*x]]]/Sqrt[-(b*x) + ArcTanh[Tanh[a + b*x]]]])/(-(b*x) + ArcTanh[Tanh[a + b*x
]])^(3/2) - Sqrt[ArcTanh[Tanh[a + b*x]]]/(x*(-(b*x) + ArcTanh[Tanh[a + b*x]]))

________________________________________________________________________________________

fricas [A]  time = 0.58, size = 93, normalized size = 0.99 \[ \left [\frac {\sqrt {a} b x \log \left (\frac {b x + 2 \, \sqrt {b x + a} \sqrt {a} + 2 \, a}{x}\right ) - 2 \, \sqrt {b x + a} a}{2 \, a^{2} x}, -\frac {\sqrt {-a} b x \arctan \left (\frac {\sqrt {b x + a} \sqrt {-a}}{a}\right ) + \sqrt {b x + a} a}{a^{2} x}\right ] \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/x^2/arctanh(tanh(b*x+a))^(1/2),x, algorithm="fricas")

[Out]

[1/2*(sqrt(a)*b*x*log((b*x + 2*sqrt(b*x + a)*sqrt(a) + 2*a)/x) - 2*sqrt(b*x + a)*a)/(a^2*x), -(sqrt(-a)*b*x*ar
ctan(sqrt(b*x + a)*sqrt(-a)/a) + sqrt(b*x + a)*a)/(a^2*x)]

________________________________________________________________________________________

giac [A]  time = 0.24, size = 47, normalized size = 0.50 \[ -\frac {\frac {b^{2} \arctan \left (\frac {\sqrt {b x + a}}{\sqrt {-a}}\right )}{\sqrt {-a} a} + \frac {\sqrt {b x + a} b}{a x}}{b} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/x^2/arctanh(tanh(b*x+a))^(1/2),x, algorithm="giac")

[Out]

-(b^2*arctan(sqrt(b*x + a)/sqrt(-a))/(sqrt(-a)*a) + sqrt(b*x + a)*b/(a*x))/b

________________________________________________________________________________________

maple [A]  time = 0.17, size = 95, normalized size = 1.01 \[ 2 b \left (\frac {2 \sqrt {\arctanh \left (\tanh \left (b x +a \right )\right )}}{\left (-4 \arctanh \left (\tanh \left (b x +a \right )\right )+4 b x \right ) b x}-\frac {2 \arctanh \left (\frac {\sqrt {\arctanh \left (\tanh \left (b x +a \right )\right )}}{\sqrt {\arctanh \left (\tanh \left (b x +a \right )\right )-b x}}\right )}{\left (-4 \arctanh \left (\tanh \left (b x +a \right )\right )+4 b x \right ) \sqrt {\arctanh \left (\tanh \left (b x +a \right )\right )-b x}}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/x^2/arctanh(tanh(b*x+a))^(1/2),x)

[Out]

2*b*(2*arctanh(tanh(b*x+a))^(1/2)/(-4*arctanh(tanh(b*x+a))+4*b*x)/b/x-2/(-4*arctanh(tanh(b*x+a))+4*b*x)/(arcta
nh(tanh(b*x+a))-b*x)^(1/2)*arctanh(arctanh(tanh(b*x+a))^(1/2)/(arctanh(tanh(b*x+a))-b*x)^(1/2)))

________________________________________________________________________________________

maxima [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {1}{x^{2} \sqrt {\operatorname {artanh}\left (\tanh \left (b x + a\right )\right )}}\,{d x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/x^2/arctanh(tanh(b*x+a))^(1/2),x, algorithm="maxima")

[Out]

integrate(1/(x^2*sqrt(arctanh(tanh(b*x + a)))), x)

________________________________________________________________________________________

mupad [B]  time = 7.02, size = 570, normalized size = 6.06 \[ \frac {2\,\sqrt {\frac {\ln \left (\frac {2\,{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )}{2}-\frac {\ln \left (\frac {2}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )}{2}}}{x\,\left (\ln \left (\frac {2}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )-\ln \left (\frac {2\,{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )+2\,b\,x\right )}+\frac {\sqrt {2}\,b\,\ln \left (\frac {\left (\sqrt {2}\,b\,x-\sqrt {2}\,\left (\ln \left (\frac {2}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )-\ln \left (\frac {2\,{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )+2\,b\,x\right )+\sqrt {\frac {\ln \left (\frac {2\,{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )}{2}-\frac {\ln \left (\frac {2}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )}{2}}\,\sqrt {\ln \left (\frac {2}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )-\ln \left (\frac {2\,{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )+2\,b\,x}\,2{}\mathrm {i}\right )\,\left ({\left (2\,a-\ln \left (\frac {2\,{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )+\ln \left (\frac {2}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )+2\,b\,x\right )}^3-8\,a^3-6\,a\,{\left (2\,a-\ln \left (\frac {2\,{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )+\ln \left (\frac {2}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )+2\,b\,x\right )}^2+12\,a^2\,\left (2\,a-\ln \left (\frac {2\,{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )+\ln \left (\frac {2}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )+2\,b\,x\right )\right )\,1{}\mathrm {i}}{2\,x\,\sqrt {\ln \left (\frac {2}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )-\ln \left (\frac {2\,{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )+2\,b\,x}}\right )\,1{}\mathrm {i}}{{\left (\ln \left (\frac {2}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )-\ln \left (\frac {2\,{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}}{{\mathrm {e}}^{2\,a}\,{\mathrm {e}}^{2\,b\,x}+1}\right )+2\,b\,x\right )}^{3/2}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(x^2*atanh(tanh(a + b*x))^(1/2)),x)

[Out]

(2*(log((2*exp(2*a)*exp(2*b*x))/(exp(2*a)*exp(2*b*x) + 1))/2 - log(2/(exp(2*a)*exp(2*b*x) + 1))/2)^(1/2))/(x*(
log(2/(exp(2*a)*exp(2*b*x) + 1)) - log((2*exp(2*a)*exp(2*b*x))/(exp(2*a)*exp(2*b*x) + 1)) + 2*b*x)) + (2^(1/2)
*b*log((((log((2*exp(2*a)*exp(2*b*x))/(exp(2*a)*exp(2*b*x) + 1))/2 - log(2/(exp(2*a)*exp(2*b*x) + 1))/2)^(1/2)
*(log(2/(exp(2*a)*exp(2*b*x) + 1)) - log((2*exp(2*a)*exp(2*b*x))/(exp(2*a)*exp(2*b*x) + 1)) + 2*b*x)^(1/2)*2i
- 2^(1/2)*(log(2/(exp(2*a)*exp(2*b*x) + 1)) - log((2*exp(2*a)*exp(2*b*x))/(exp(2*a)*exp(2*b*x) + 1)) + 2*b*x)
+ 2^(1/2)*b*x)*((2*a - log((2*exp(2*a)*exp(2*b*x))/(exp(2*a)*exp(2*b*x) + 1)) + log(2/(exp(2*a)*exp(2*b*x) + 1
)) + 2*b*x)^3 - 8*a^3 - 6*a*(2*a - log((2*exp(2*a)*exp(2*b*x))/(exp(2*a)*exp(2*b*x) + 1)) + log(2/(exp(2*a)*ex
p(2*b*x) + 1)) + 2*b*x)^2 + 12*a^2*(2*a - log((2*exp(2*a)*exp(2*b*x))/(exp(2*a)*exp(2*b*x) + 1)) + log(2/(exp(
2*a)*exp(2*b*x) + 1)) + 2*b*x))*1i)/(2*x*(log(2/(exp(2*a)*exp(2*b*x) + 1)) - log((2*exp(2*a)*exp(2*b*x))/(exp(
2*a)*exp(2*b*x) + 1)) + 2*b*x)^(1/2)))*1i)/(log(2/(exp(2*a)*exp(2*b*x) + 1)) - log((2*exp(2*a)*exp(2*b*x))/(ex
p(2*a)*exp(2*b*x) + 1)) + 2*b*x)^(3/2)

________________________________________________________________________________________

sympy [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {1}{x^{2} \sqrt {\operatorname {atanh}{\left (\tanh {\left (a + b x \right )} \right )}}}\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/x**2/atanh(tanh(b*x+a))**(1/2),x)

[Out]

Integral(1/(x**2*sqrt(atanh(tanh(a + b*x)))), x)

________________________________________________________________________________________