3.8 \(\int \coth ^2(a+b x) \, dx\)

Optimal. Leaf size=13 \[ x-\frac{\coth (a+b x)}{b} \]

[Out]

x - Coth[a + b*x]/b

________________________________________________________________________________________

Rubi [A]  time = 0.0081182, antiderivative size = 13, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 2, integrand size = 8, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.25, Rules used = {3473, 8} \[ x-\frac{\coth (a+b x)}{b} \]

Antiderivative was successfully verified.

[In]

Int[Coth[a + b*x]^2,x]

[Out]

x - Coth[a + b*x]/b

Rule 3473

Int[((b_.)*tan[(c_.) + (d_.)*(x_)])^(n_), x_Symbol] :> Simp[(b*(b*Tan[c + d*x])^(n - 1))/(d*(n - 1)), x] - Dis
t[b^2, Int[(b*Tan[c + d*x])^(n - 2), x], x] /; FreeQ[{b, c, d}, x] && GtQ[n, 1]

Rule 8

Int[a_, x_Symbol] :> Simp[a*x, x] /; FreeQ[a, x]

Rubi steps

\begin{align*} \int \coth ^2(a+b x) \, dx &=-\frac{\coth (a+b x)}{b}+\int 1 \, dx\\ &=x-\frac{\coth (a+b x)}{b}\\ \end{align*}

Mathematica [C]  time = 0.0091073, size = 27, normalized size = 2.08 \[ -\frac{\coth (a+b x) \, _2F_1\left (-\frac{1}{2},1;\frac{1}{2};\tanh ^2(a+b x)\right )}{b} \]

Antiderivative was successfully verified.

[In]

Integrate[Coth[a + b*x]^2,x]

[Out]

-((Coth[a + b*x]*Hypergeometric2F1[-1/2, 1, 1/2, Tanh[a + b*x]^2])/b)

________________________________________________________________________________________

Maple [B]  time = 0., size = 41, normalized size = 3.2 \begin{align*} -{\frac{{\rm coth} \left (bx+a\right )}{b}}-{\frac{\ln \left ({\rm coth} \left (bx+a\right )-1 \right ) }{2\,b}}+{\frac{\ln \left ({\rm coth} \left (bx+a\right )+1 \right ) }{2\,b}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(coth(b*x+a)^2,x)

[Out]

-coth(b*x+a)/b-1/2/b*ln(coth(b*x+a)-1)+1/2/b*ln(coth(b*x+a)+1)

________________________________________________________________________________________

Maxima [A]  time = 1.04407, size = 34, normalized size = 2.62 \begin{align*} x + \frac{a}{b} + \frac{2}{b{\left (e^{\left (-2 \, b x - 2 \, a\right )} - 1\right )}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(coth(b*x+a)^2,x, algorithm="maxima")

[Out]

x + a/b + 2/(b*(e^(-2*b*x - 2*a) - 1))

________________________________________________________________________________________

Fricas [B]  time = 2.27709, size = 82, normalized size = 6.31 \begin{align*} \frac{{\left (b x + 1\right )} \sinh \left (b x + a\right ) - \cosh \left (b x + a\right )}{b \sinh \left (b x + a\right )} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(coth(b*x+a)^2,x, algorithm="fricas")

[Out]

((b*x + 1)*sinh(b*x + a) - cosh(b*x + a))/(b*sinh(b*x + a))

________________________________________________________________________________________

Sympy [A]  time = 1.59867, size = 36, normalized size = 2.77 \begin{align*} \begin{cases} \tilde{\infty } x & \text{for}\: a = \log{\left (- e^{- b x} \right )} \vee a = \log{\left (e^{- b x} \right )} \\x \coth ^{2}{\left (a \right )} & \text{for}\: b = 0 \\x - \frac{1}{b \tanh{\left (a + b x \right )}} & \text{otherwise} \end{cases} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(coth(b*x+a)**2,x)

[Out]

Piecewise((zoo*x, Eq(a, log(exp(-b*x))) | Eq(a, log(-exp(-b*x)))), (x*coth(a)**2, Eq(b, 0)), (x - 1/(b*tanh(a
+ b*x)), True))

________________________________________________________________________________________

Giac [B]  time = 1.23787, size = 38, normalized size = 2.92 \begin{align*} \frac{b x + a}{b} - \frac{2}{b{\left (e^{\left (2 \, b x + 2 \, a\right )} - 1\right )}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(coth(b*x+a)^2,x, algorithm="giac")

[Out]

(b*x + a)/b - 2/(b*(e^(2*b*x + 2*a) - 1))