3.72 \(\int (a+b \text {csch}(c+d x))^2 \, dx\)

Optimal. Leaf size=34 \[ a^2 x-\frac {2 a b \tanh ^{-1}(\cosh (c+d x))}{d}-\frac {b^2 \coth (c+d x)}{d} \]

[Out]

a^2*x-2*a*b*arctanh(cosh(d*x+c))/d-b^2*coth(d*x+c)/d

________________________________________________________________________________________

Rubi [A]  time = 0.03, antiderivative size = 34, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 12, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.333, Rules used = {3773, 3770, 3767, 8} \[ a^2 x-\frac {2 a b \tanh ^{-1}(\cosh (c+d x))}{d}-\frac {b^2 \coth (c+d x)}{d} \]

Antiderivative was successfully verified.

[In]

Int[(a + b*Csch[c + d*x])^2,x]

[Out]

a^2*x - (2*a*b*ArcTanh[Cosh[c + d*x]])/d - (b^2*Coth[c + d*x])/d

Rule 8

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

Rule 3767

Int[csc[(c_.) + (d_.)*(x_)]^(n_), x_Symbol] :> -Dist[d^(-1), Subst[Int[ExpandIntegrand[(1 + x^2)^(n/2 - 1), x]
, x], x, Cot[c + d*x]], x] /; FreeQ[{c, d}, x] && IGtQ[n/2, 0]

Rule 3770

Int[csc[(c_.) + (d_.)*(x_)], x_Symbol] :> -Simp[ArcTanh[Cos[c + d*x]]/d, x] /; FreeQ[{c, d}, x]

Rule 3773

Int[(csc[(c_.) + (d_.)*(x_)]*(b_.) + (a_))^2, x_Symbol] :> Simp[a^2*x, x] + (Dist[2*a*b, Int[Csc[c + d*x], x],
 x] + Dist[b^2, Int[Csc[c + d*x]^2, x], x]) /; FreeQ[{a, b, c, d}, x]

Rubi steps

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

________________________________________________________________________________________

Mathematica [A]  time = 0.22, size = 61, normalized size = 1.79 \[ -\frac {-2 a \left (a c+a d x+2 b \log \left (\tanh \left (\frac {1}{2} (c+d x)\right )\right )\right )+b^2 \tanh \left (\frac {1}{2} (c+d x)\right )+b^2 \coth \left (\frac {1}{2} (c+d x)\right )}{2 d} \]

Antiderivative was successfully verified.

[In]

Integrate[(a + b*Csch[c + d*x])^2,x]

[Out]

-1/2*(b^2*Coth[(c + d*x)/2] - 2*a*(a*c + a*d*x + 2*b*Log[Tanh[(c + d*x)/2]]) + b^2*Tanh[(c + d*x)/2])/d

________________________________________________________________________________________

fricas [B]  time = 0.42, size = 222, normalized size = 6.53 \[ \frac {a^{2} d x \cosh \left (d x + c\right )^{2} + 2 \, a^{2} d x \cosh \left (d x + c\right ) \sinh \left (d x + c\right ) + a^{2} d x \sinh \left (d x + c\right )^{2} - a^{2} d x - 2 \, b^{2} - 2 \, {\left (a b \cosh \left (d x + c\right )^{2} + 2 \, a b \cosh \left (d x + c\right ) \sinh \left (d x + c\right ) + a b \sinh \left (d x + c\right )^{2} - a b\right )} \log \left (\cosh \left (d x + c\right ) + \sinh \left (d x + c\right ) + 1\right ) + 2 \, {\left (a b \cosh \left (d x + c\right )^{2} + 2 \, a b \cosh \left (d x + c\right ) \sinh \left (d x + c\right ) + a b \sinh \left (d x + c\right )^{2} - a b\right )} \log \left (\cosh \left (d x + c\right ) + \sinh \left (d x + c\right ) - 1\right )}{d \cosh \left (d x + c\right )^{2} + 2 \, d \cosh \left (d x + c\right ) \sinh \left (d x + c\right ) + d \sinh \left (d x + c\right )^{2} - d} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

(a^2*d*x*cosh(d*x + c)^2 + 2*a^2*d*x*cosh(d*x + c)*sinh(d*x + c) + a^2*d*x*sinh(d*x + c)^2 - a^2*d*x - 2*b^2 -
 2*(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*b)*log(cosh(d*x + c) + s
inh(d*x + c) + 1) + 2*(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*b)*lo
g(cosh(d*x + c) + sinh(d*x + c) - 1))/(d*cosh(d*x + c)^2 + 2*d*cosh(d*x + c)*sinh(d*x + c) + d*sinh(d*x + c)^2
 - d)

________________________________________________________________________________________

giac [A]  time = 0.12, size = 59, normalized size = 1.74 \[ \frac {{\left (d x + c\right )} a^{2} - 2 \, a b \log \left (e^{\left (d x + c\right )} + 1\right ) + 2 \, a b \log \left ({\left | e^{\left (d x + c\right )} - 1 \right |}\right ) - \frac {2 \, b^{2}}{e^{\left (2 \, d x + 2 \, c\right )} - 1}}{d} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

((d*x + c)*a^2 - 2*a*b*log(e^(d*x + c) + 1) + 2*a*b*log(abs(e^(d*x + c) - 1)) - 2*b^2/(e^(2*d*x + 2*c) - 1))/d

________________________________________________________________________________________

maple [A]  time = 0.32, size = 37, normalized size = 1.09 \[ \frac {a^{2} \left (d x +c \right )-4 a b \arctanh \left ({\mathrm e}^{d x +c}\right )-b^{2} \coth \left (d x +c \right )}{d} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+b*csch(d*x+c))^2,x)

[Out]

1/d*(a^2*(d*x+c)-4*a*b*arctanh(exp(d*x+c))-b^2*coth(d*x+c))

________________________________________________________________________________________

maxima [A]  time = 0.32, size = 44, normalized size = 1.29 \[ a^{2} x + \frac {2 \, a b \log \left (\tanh \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )}{d} + \frac {2 \, b^{2}}{d {\left (e^{\left (-2 \, d x - 2 \, c\right )} - 1\right )}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

a^2*x + 2*a*b*log(tanh(1/2*d*x + 1/2*c))/d + 2*b^2/(d*(e^(-2*d*x - 2*c) - 1))

________________________________________________________________________________________

mupad [B]  time = 1.48, size = 74, normalized size = 2.18 \[ a^2\,x-\frac {2\,b^2}{d\,\left ({\mathrm {e}}^{2\,c+2\,d\,x}-1\right )}-\frac {4\,\mathrm {atan}\left (\frac {a\,b\,{\mathrm {e}}^{d\,x}\,{\mathrm {e}}^c\,\sqrt {-d^2}}{d\,\sqrt {a^2\,b^2}}\right )\,\sqrt {a^2\,b^2}}{\sqrt {-d^2}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

a^2*x - (2*b^2)/(d*(exp(2*c + 2*d*x) - 1)) - (4*atan((a*b*exp(d*x)*exp(c)*(-d^2)^(1/2))/(d*(a^2*b^2)^(1/2)))*(
a^2*b^2)^(1/2))/(-d^2)^(1/2)

________________________________________________________________________________________

sympy [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \left (a + b \operatorname {csch}{\left (c + d x \right )}\right )^{2}\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*csch(d*x+c))**2,x)

[Out]

Integral((a + b*csch(c + d*x))**2, x)

________________________________________________________________________________________