### 3.105 $$\int \cosh ^2(a+b x) \coth (a+b x) \, dx$$

Optimal. Leaf size=27 $\frac{\sinh ^2(a+b x)}{2 b}+\frac{\log (\sinh (a+b x))}{b}$

[Out]

Log[Sinh[a + b*x]]/b + Sinh[a + b*x]^2/(2*b)

________________________________________________________________________________________

Rubi [A]  time = 0.0236637, antiderivative size = 27, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 2, integrand size = 15, $$\frac{\text{number of rules}}{\text{integrand size}}$$ = 0.133, Rules used = {2590, 14} $\frac{\sinh ^2(a+b x)}{2 b}+\frac{\log (\sinh (a+b x))}{b}$

Antiderivative was successfully veriﬁed.

[In]

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

[Out]

Log[Sinh[a + b*x]]/b + Sinh[a + b*x]^2/(2*b)

Rule 2590

Int[sin[(e_.) + (f_.)*(x_)]^(m_.)*tan[(e_.) + (f_.)*(x_)]^(n_.), x_Symbol] :> -Dist[f^(-1), Subst[Int[(1 - x^2
)^((m + n - 1)/2)/x^n, x], x, Cos[e + f*x]], x] /; FreeQ[{e, f}, x] && IntegersQ[m, n, (m + n - 1)/2]

Rule 14

Int[(u_)*((c_.)*(x_))^(m_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*u, x], x] /; FreeQ[{c, m}, x] && SumQ[u]
&&  !LinearQ[u, x] &&  !MatchQ[u, (a_) + (b_.)*(v_) /; FreeQ[{a, b}, x] && InverseFunctionQ[v]]

Rubi steps

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

Mathematica [A]  time = 0.0212238, size = 25, normalized size = 0.93 $\frac{\sinh ^2(a+b x)+2 \log (\sinh (a+b x))}{2 b}$

Antiderivative was successfully veriﬁed.

[In]

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

[Out]

(2*Log[Sinh[a + b*x]] + Sinh[a + b*x]^2)/(2*b)

________________________________________________________________________________________

Maple [A]  time = 0.017, size = 26, normalized size = 1. \begin{align*}{\frac{ \left ( \cosh \left ( bx+a \right ) \right ) ^{2}}{2\,b}}+{\frac{\ln \left ( \sinh \left ( bx+a \right ) \right ) }{b}} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/2*cosh(b*x+a)^2/b+ln(sinh(b*x+a))/b

________________________________________________________________________________________

Maxima [B]  time = 1.08088, size = 95, normalized size = 3.52 \begin{align*} \frac{b x + a}{b} + \frac{e^{\left (2 \, b x + 2 \, a\right )}}{8 \, b} + \frac{e^{\left (-2 \, b x - 2 \, a\right )}}{8 \, b} + \frac{\log \left (e^{\left (-b x - a\right )} + 1\right )}{b} + \frac{\log \left (e^{\left (-b x - a\right )} - 1\right )}{b} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Fricas [B]  time = 1.79296, size = 552, normalized size = 20.44 \begin{align*} -\frac{8 \, b x \cosh \left (b x + a\right )^{2} - \cosh \left (b x + a\right )^{4} - 4 \, \cosh \left (b x + a\right ) \sinh \left (b x + a\right )^{3} - \sinh \left (b x + a\right )^{4} + 2 \,{\left (4 \, b x - 3 \, \cosh \left (b x + a\right )^{2}\right )} \sinh \left (b x + a\right )^{2} - 8 \,{\left (\cosh \left (b x + a\right )^{2} + 2 \, \cosh \left (b x + a\right ) \sinh \left (b x + a\right ) + \sinh \left (b x + a\right )^{2}\right )} \log \left (\frac{2 \, \sinh \left (b x + a\right )}{\cosh \left (b x + a\right ) - \sinh \left (b x + a\right )}\right ) + 4 \,{\left (4 \, b x \cosh \left (b x + a\right ) - \cosh \left (b x + a\right )^{3}\right )} \sinh \left (b x + a\right ) - 1}{8 \,{\left (b \cosh \left (b x + a\right )^{2} + 2 \, b \cosh \left (b x + a\right ) \sinh \left (b x + a\right ) + b \sinh \left (b x + a\right )^{2}\right )}} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-1/8*(8*b*x*cosh(b*x + a)^2 - cosh(b*x + a)^4 - 4*cosh(b*x + a)*sinh(b*x + a)^3 - sinh(b*x + a)^4 + 2*(4*b*x -
3*cosh(b*x + a)^2)*sinh(b*x + a)^2 - 8*(cosh(b*x + a)^2 + 2*cosh(b*x + a)*sinh(b*x + a) + sinh(b*x + a)^2)*lo
g(2*sinh(b*x + a)/(cosh(b*x + a) - sinh(b*x + a))) + 4*(4*b*x*cosh(b*x + a) - cosh(b*x + a)^3)*sinh(b*x + a) -
1)/(b*cosh(b*x + a)^2 + 2*b*cosh(b*x + a)*sinh(b*x + a) + b*sinh(b*x + a)^2)

________________________________________________________________________________________

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

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

Exception raised: TypeError

________________________________________________________________________________________

Giac [B]  time = 1.16251, size = 81, normalized size = 3. \begin{align*} -\frac{8 \, b x -{\left (4 \, e^{\left (2 \, b x + 2 \, a\right )} + 1\right )} e^{\left (-2 \, b x - 2 \, a\right )} - e^{\left (2 \, b x + 2 \, a\right )} - 8 \, \log \left ({\left | e^{\left (2 \, b x + 2 \, a\right )} - 1 \right |}\right )}{8 \, b} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-1/8*(8*b*x - (4*e^(2*b*x + 2*a) + 1)*e^(-2*b*x - 2*a) - e^(2*b*x + 2*a) - 8*log(abs(e^(2*b*x + 2*a) - 1)))/b