3.68 \(\int \frac{1}{\sqrt{a+b \tanh (c+d x)}} \, dx\)

Optimal. Leaf size=74 \[ \frac{\tanh ^{-1}\left (\frac{\sqrt{a+b \tanh (c+d x)}}{\sqrt{a+b}}\right )}{d \sqrt{a+b}}-\frac{\tanh ^{-1}\left (\frac{\sqrt{a+b \tanh (c+d x)}}{\sqrt{a-b}}\right )}{d \sqrt{a-b}} \]

[Out]

-(ArcTanh[Sqrt[a + b*Tanh[c + d*x]]/Sqrt[a - b]]/(Sqrt[a - b]*d)) + ArcTanh[Sqrt[a + b*Tanh[c + d*x]]/Sqrt[a +
 b]]/(Sqrt[a + b]*d)

________________________________________________________________________________________

Rubi [A]  time = 0.0686009, antiderivative size = 74, normalized size of antiderivative = 1., number of steps used = 5, number of rules used = 4, integrand size = 14, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.286, Rules used = {3485, 708, 1093, 207} \[ \frac{\tanh ^{-1}\left (\frac{\sqrt{a+b \tanh (c+d x)}}{\sqrt{a+b}}\right )}{d \sqrt{a+b}}-\frac{\tanh ^{-1}\left (\frac{\sqrt{a+b \tanh (c+d x)}}{\sqrt{a-b}}\right )}{d \sqrt{a-b}} \]

Antiderivative was successfully verified.

[In]

Int[1/Sqrt[a + b*Tanh[c + d*x]],x]

[Out]

-(ArcTanh[Sqrt[a + b*Tanh[c + d*x]]/Sqrt[a - b]]/(Sqrt[a - b]*d)) + ArcTanh[Sqrt[a + b*Tanh[c + d*x]]/Sqrt[a +
 b]]/(Sqrt[a + b]*d)

Rule 3485

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

Rule 708

Int[1/(Sqrt[(d_) + (e_.)*(x_)]*((a_) + (c_.)*(x_)^2)), x_Symbol] :> Dist[2*e, Subst[Int[1/(c*d^2 + a*e^2 - 2*c
*d*x^2 + c*x^4), x], x, Sqrt[d + e*x]], x] /; FreeQ[{a, c, d, e}, x] && NeQ[c*d^2 + a*e^2, 0]

Rule 1093

Int[((a_) + (b_.)*(x_)^2 + (c_.)*(x_)^4)^(-1), x_Symbol] :> With[{q = Rt[b^2 - 4*a*c, 2]}, Dist[c/q, Int[1/(b/
2 - q/2 + c*x^2), x], x] - Dist[c/q, Int[1/(b/2 + q/2 + c*x^2), x], x]] /; FreeQ[{a, b, c}, x] && NeQ[b^2 - 4*
a*c, 0] && PosQ[b^2 - 4*a*c]

Rule 207

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

Rubi steps

\begin{align*} \int \frac{1}{\sqrt{a+b \tanh (c+d x)}} \, dx &=-\frac{b \operatorname{Subst}\left (\int \frac{1}{\sqrt{a+x} \left (-b^2+x^2\right )} \, dx,x,b \tanh (c+d x)\right )}{d}\\ &=-\frac{(2 b) \operatorname{Subst}\left (\int \frac{1}{a^2-b^2-2 a x^2+x^4} \, dx,x,\sqrt{a+b \tanh (c+d x)}\right )}{d}\\ &=-\frac{\operatorname{Subst}\left (\int \frac{1}{-a-b+x^2} \, dx,x,\sqrt{a+b \tanh (c+d x)}\right )}{d}+\frac{\operatorname{Subst}\left (\int \frac{1}{-a+b+x^2} \, dx,x,\sqrt{a+b \tanh (c+d x)}\right )}{d}\\ &=-\frac{\tanh ^{-1}\left (\frac{\sqrt{a+b \tanh (c+d x)}}{\sqrt{a-b}}\right )}{\sqrt{a-b} d}+\frac{\tanh ^{-1}\left (\frac{\sqrt{a+b \tanh (c+d x)}}{\sqrt{a+b}}\right )}{\sqrt{a+b} d}\\ \end{align*}

Mathematica [A]  time = 0.0638881, size = 74, normalized size = 1. \[ \frac{\tanh ^{-1}\left (\frac{\sqrt{a+b \tanh (c+d x)}}{\sqrt{a+b}}\right )}{d \sqrt{a+b}}-\frac{\tanh ^{-1}\left (\frac{\sqrt{a+b \tanh (c+d x)}}{\sqrt{a-b}}\right )}{d \sqrt{a-b}} \]

Antiderivative was successfully verified.

[In]

Integrate[1/Sqrt[a + b*Tanh[c + d*x]],x]

[Out]

-(ArcTanh[Sqrt[a + b*Tanh[c + d*x]]/Sqrt[a - b]]/(Sqrt[a - b]*d)) + ArcTanh[Sqrt[a + b*Tanh[c + d*x]]/Sqrt[a +
 b]]/(Sqrt[a + b]*d)

________________________________________________________________________________________

Maple [A]  time = 0.039, size = 62, normalized size = 0.8 \begin{align*}{\frac{1}{d}{\it Artanh} \left ({\sqrt{a+b\tanh \left ( dx+c \right ) }{\frac{1}{\sqrt{a+b}}}} \right ){\frac{1}{\sqrt{a+b}}}}+{\frac{1}{d}\arctan \left ({\sqrt{a+b\tanh \left ( dx+c \right ) }{\frac{1}{\sqrt{-a+b}}}} \right ){\frac{1}{\sqrt{-a+b}}}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

arctanh((a+b*tanh(d*x+c))^(1/2)/(a+b)^(1/2))/d/(a+b)^(1/2)+1/d/(-a+b)^(1/2)*arctan((a+b*tanh(d*x+c))^(1/2)/(-a
+b)^(1/2))

________________________________________________________________________________________

Maxima [F(-2)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: ValueError} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

Exception raised: ValueError

________________________________________________________________________________________

Fricas [B]  time = 2.84483, size = 5844, normalized size = 78.97 \begin{align*} \text{result too large to display} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

[1/4*(sqrt(a + b)*(a - b)*log(2*(a^2 + 2*a*b + b^2)*cosh(d*x + c)^4 + 8*(a^2 + 2*a*b + b^2)*cosh(d*x + c)*sinh
(d*x + c)^3 + 2*(a^2 + 2*a*b + b^2)*sinh(d*x + c)^4 + 4*(a^2 + a*b)*cosh(d*x + c)^2 + 4*(3*(a^2 + 2*a*b + b^2)
*cosh(d*x + c)^2 + a^2 + a*b)*sinh(d*x + c)^2 + 2*a^2 - b^2 + 2*((a + b)*cosh(d*x + c)^4 + 4*(a + b)*cosh(d*x
+ c)*sinh(d*x + c)^3 + (a + b)*sinh(d*x + c)^4 + (2*a + b)*cosh(d*x + c)^2 + (6*(a + b)*cosh(d*x + c)^2 + 2*a
+ b)*sinh(d*x + c)^2 + 2*(2*(a + b)*cosh(d*x + c)^3 + (2*a + b)*cosh(d*x + c))*sinh(d*x + c) + a)*sqrt(a + b)*
sqrt((a*cosh(d*x + c) + b*sinh(d*x + c))/cosh(d*x + c)) + 8*((a^2 + 2*a*b + b^2)*cosh(d*x + c)^3 + (a^2 + a*b)
*cosh(d*x + c))*sinh(d*x + c)) + (a + b)*sqrt(a - b)*log(((2*a^2 - b^2)*cosh(d*x + c)^4 + 4*(2*a^2 - b^2)*cosh
(d*x + c)*sinh(d*x + c)^3 + (2*a^2 - b^2)*sinh(d*x + c)^4 + 4*(a^2 - a*b)*cosh(d*x + c)^2 + 2*(3*(2*a^2 - b^2)
*cosh(d*x + c)^2 + 2*a^2 - 2*a*b)*sinh(d*x + c)^2 + 2*a^2 - 4*a*b + 2*b^2 - 2*(a*cosh(d*x + c)^4 + 4*a*cosh(d*
x + c)*sinh(d*x + c)^3 + a*sinh(d*x + c)^4 + (2*a - b)*cosh(d*x + c)^2 + (6*a*cosh(d*x + c)^2 + 2*a - b)*sinh(
d*x + c)^2 + 2*(2*a*cosh(d*x + c)^3 + (2*a - b)*cosh(d*x + c))*sinh(d*x + c) + a - b)*sqrt(a - b)*sqrt((a*cosh
(d*x + c) + b*sinh(d*x + c))/cosh(d*x + c)) + 4*((2*a^2 - b^2)*cosh(d*x + c)^3 + 2*(a^2 - a*b)*cosh(d*x + c))*
sinh(d*x + c))/(cosh(d*x + c)^4 + 4*cosh(d*x + c)^3*sinh(d*x + c) + 6*cosh(d*x + c)^2*sinh(d*x + c)^2 + 4*cosh
(d*x + c)*sinh(d*x + c)^3 + sinh(d*x + c)^4)))/((a^2 - b^2)*d), -1/4*(2*(a - b)*sqrt(-a - b)*arctan(((a + b)*c
osh(d*x + c)^2 + 2*(a + b)*cosh(d*x + c)*sinh(d*x + c) + (a + b)*sinh(d*x + c)^2 + a)*sqrt(-a - b)*sqrt((a*cos
h(d*x + c) + b*sinh(d*x + c))/cosh(d*x + c))/((a^2 + 2*a*b + b^2)*cosh(d*x + c)^2 + 2*(a^2 + 2*a*b + b^2)*cosh
(d*x + c)*sinh(d*x + c) + (a^2 + 2*a*b + b^2)*sinh(d*x + c)^2 + a^2 - b^2)) - (a + b)*sqrt(a - b)*log(((2*a^2
- b^2)*cosh(d*x + c)^4 + 4*(2*a^2 - b^2)*cosh(d*x + c)*sinh(d*x + c)^3 + (2*a^2 - b^2)*sinh(d*x + c)^4 + 4*(a^
2 - a*b)*cosh(d*x + c)^2 + 2*(3*(2*a^2 - b^2)*cosh(d*x + c)^2 + 2*a^2 - 2*a*b)*sinh(d*x + c)^2 + 2*a^2 - 4*a*b
 + 2*b^2 - 2*(a*cosh(d*x + c)^4 + 4*a*cosh(d*x + c)*sinh(d*x + c)^3 + a*sinh(d*x + c)^4 + (2*a - b)*cosh(d*x +
 c)^2 + (6*a*cosh(d*x + c)^2 + 2*a - b)*sinh(d*x + c)^2 + 2*(2*a*cosh(d*x + c)^3 + (2*a - b)*cosh(d*x + c))*si
nh(d*x + c) + a - b)*sqrt(a - b)*sqrt((a*cosh(d*x + c) + b*sinh(d*x + c))/cosh(d*x + c)) + 4*((2*a^2 - b^2)*co
sh(d*x + c)^3 + 2*(a^2 - a*b)*cosh(d*x + c))*sinh(d*x + c))/(cosh(d*x + c)^4 + 4*cosh(d*x + c)^3*sinh(d*x + c)
 + 6*cosh(d*x + c)^2*sinh(d*x + c)^2 + 4*cosh(d*x + c)*sinh(d*x + c)^3 + sinh(d*x + c)^4)))/((a^2 - b^2)*d), -
1/4*(2*(a + b)*sqrt(-a + b)*arctan(-(a*cosh(d*x + c)^2 + 2*a*cosh(d*x + c)*sinh(d*x + c) + a*sinh(d*x + c)^2 +
 a - b)*sqrt(-a + b)*sqrt((a*cosh(d*x + c) + b*sinh(d*x + c))/cosh(d*x + c))/((a^2 - b^2)*cosh(d*x + c)^2 + 2*
(a^2 - b^2)*cosh(d*x + c)*sinh(d*x + c) + (a^2 - b^2)*sinh(d*x + c)^2 + a^2 - 2*a*b + b^2)) - sqrt(a + b)*(a -
 b)*log(2*(a^2 + 2*a*b + b^2)*cosh(d*x + c)^4 + 8*(a^2 + 2*a*b + b^2)*cosh(d*x + c)*sinh(d*x + c)^3 + 2*(a^2 +
 2*a*b + b^2)*sinh(d*x + c)^4 + 4*(a^2 + a*b)*cosh(d*x + c)^2 + 4*(3*(a^2 + 2*a*b + b^2)*cosh(d*x + c)^2 + a^2
 + a*b)*sinh(d*x + c)^2 + 2*a^2 - b^2 + 2*((a + b)*cosh(d*x + c)^4 + 4*(a + b)*cosh(d*x + c)*sinh(d*x + c)^3 +
 (a + b)*sinh(d*x + c)^4 + (2*a + b)*cosh(d*x + c)^2 + (6*(a + b)*cosh(d*x + c)^2 + 2*a + b)*sinh(d*x + c)^2 +
 2*(2*(a + b)*cosh(d*x + c)^3 + (2*a + b)*cosh(d*x + c))*sinh(d*x + c) + a)*sqrt(a + b)*sqrt((a*cosh(d*x + c)
+ b*sinh(d*x + c))/cosh(d*x + c)) + 8*((a^2 + 2*a*b + b^2)*cosh(d*x + c)^3 + (a^2 + a*b)*cosh(d*x + c))*sinh(d
*x + c)))/((a^2 - b^2)*d), -1/2*((a + b)*sqrt(-a + b)*arctan(-(a*cosh(d*x + c)^2 + 2*a*cosh(d*x + c)*sinh(d*x
+ c) + a*sinh(d*x + c)^2 + a - b)*sqrt(-a + b)*sqrt((a*cosh(d*x + c) + b*sinh(d*x + c))/cosh(d*x + c))/((a^2 -
 b^2)*cosh(d*x + c)^2 + 2*(a^2 - b^2)*cosh(d*x + c)*sinh(d*x + c) + (a^2 - b^2)*sinh(d*x + c)^2 + a^2 - 2*a*b
+ b^2)) + (a - b)*sqrt(-a - b)*arctan(((a + b)*cosh(d*x + c)^2 + 2*(a + b)*cosh(d*x + c)*sinh(d*x + c) + (a +
b)*sinh(d*x + c)^2 + a)*sqrt(-a - b)*sqrt((a*cosh(d*x + c) + b*sinh(d*x + c))/cosh(d*x + c))/((a^2 + 2*a*b + b
^2)*cosh(d*x + c)^2 + 2*(a^2 + 2*a*b + b^2)*cosh(d*x + c)*sinh(d*x + c) + (a^2 + 2*a*b + b^2)*sinh(d*x + c)^2
+ a^2 - b^2)))/((a^2 - b^2)*d)]

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{1}{\sqrt{a + b \tanh{\left (c + d x \right )}}}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

Integral(1/sqrt(a + b*tanh(c + d*x)), x)

________________________________________________________________________________________

Giac [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{1}{\sqrt{b \tanh \left (d x + c\right ) + a}}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

integrate(1/sqrt(b*tanh(d*x + c) + a), x)