\(\int x \coth (x) \text {csch}(x) \, dx\) [71]

   Optimal result
   Rubi [A] (verified)
   Mathematica [B] (verified)
   Maple [B] (verified)
   Fricas [B] (verification not implemented)
   Sympy [B] (verification not implemented)
   Maxima [B] (verification not implemented)
   Giac [B] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 6, antiderivative size = 11 \[ \int x \coth (x) \text {csch}(x) \, dx=-\text {arctanh}(\cosh (x))-x \text {csch}(x) \]

[Out]

-arctanh(cosh(x))-x*csch(x)

Rubi [A] (verified)

Time = 0.02 (sec) , antiderivative size = 11, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.333, Rules used = {5527, 3855} \[ \int x \coth (x) \text {csch}(x) \, dx=-\text {arctanh}(\cosh (x))-x \text {csch}(x) \]

[In]

Int[x*Coth[x]*Csch[x],x]

[Out]

-ArcTanh[Cosh[x]] - x*Csch[x]

Rule 3855

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

Rule 5527

Int[Coth[(a_.) + (b_.)*(x_)^(n_.)]^(q_.)*Csch[(a_.) + (b_.)*(x_)^(n_.)]^(p_.)*(x_)^(m_.), x_Symbol] :> Simp[(-
x^(m - n + 1))*(Csch[a + b*x^n]^p/(b*n*p)), x] + Dist[(m - n + 1)/(b*n*p), Int[x^(m - n)*Csch[a + b*x^n]^p, x]
, x] /; FreeQ[{a, b, p}, x] && RationalQ[m] && IntegerQ[n] && GeQ[m - n, 0] && EqQ[q, 1]

Rubi steps \begin{align*} \text {integral}& = -x \text {csch}(x)+\int \text {csch}(x) \, dx \\ & = -\text {arctanh}(\cosh (x))-x \text {csch}(x) \\ \end{align*}

Mathematica [B] (verified)

Leaf count is larger than twice the leaf count of optimal. \(39\) vs. \(2(11)=22\).

Time = 0.01 (sec) , antiderivative size = 39, normalized size of antiderivative = 3.55 \[ \int x \coth (x) \text {csch}(x) \, dx=-\frac {1}{2} x \coth \left (\frac {x}{2}\right )-\log \left (\cosh \left (\frac {x}{2}\right )\right )+\log \left (\sinh \left (\frac {x}{2}\right )\right )+\frac {1}{2} x \tanh \left (\frac {x}{2}\right ) \]

[In]

Integrate[x*Coth[x]*Csch[x],x]

[Out]

-1/2*(x*Coth[x/2]) - Log[Cosh[x/2]] + Log[Sinh[x/2]] + (x*Tanh[x/2])/2

Maple [B] (verified)

Leaf count of result is larger than twice the leaf count of optimal. \(26\) vs. \(2(11)=22\).

Time = 0.20 (sec) , antiderivative size = 27, normalized size of antiderivative = 2.45

method result size
risch \(-\frac {2 x \,{\mathrm e}^{x}}{{\mathrm e}^{2 x}-1}+\ln \left ({\mathrm e}^{x}-1\right )-\ln \left ({\mathrm e}^{x}+1\right )\) \(27\)

[In]

int(x*cosh(x)/sinh(x)^2,x,method=_RETURNVERBOSE)

[Out]

-2*x*exp(x)/(exp(2*x)-1)+ln(exp(x)-1)-ln(exp(x)+1)

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 80 vs. \(2 (11) = 22\).

Time = 0.23 (sec) , antiderivative size = 80, normalized size of antiderivative = 7.27 \[ \int x \coth (x) \text {csch}(x) \, dx=-\frac {2 \, x \cosh \left (x\right ) + {\left (\cosh \left (x\right )^{2} + 2 \, \cosh \left (x\right ) \sinh \left (x\right ) + \sinh \left (x\right )^{2} - 1\right )} \log \left (\cosh \left (x\right ) + \sinh \left (x\right ) + 1\right ) - {\left (\cosh \left (x\right )^{2} + 2 \, \cosh \left (x\right ) \sinh \left (x\right ) + \sinh \left (x\right )^{2} - 1\right )} \log \left (\cosh \left (x\right ) + \sinh \left (x\right ) - 1\right ) + 2 \, x \sinh \left (x\right )}{\cosh \left (x\right )^{2} + 2 \, \cosh \left (x\right ) \sinh \left (x\right ) + \sinh \left (x\right )^{2} - 1} \]

[In]

integrate(x*cosh(x)/sinh(x)^2,x, algorithm="fricas")

[Out]

-(2*x*cosh(x) + (cosh(x)^2 + 2*cosh(x)*sinh(x) + sinh(x)^2 - 1)*log(cosh(x) + sinh(x) + 1) - (cosh(x)^2 + 2*co
sh(x)*sinh(x) + sinh(x)^2 - 1)*log(cosh(x) + sinh(x) - 1) + 2*x*sinh(x))/(cosh(x)^2 + 2*cosh(x)*sinh(x) + sinh
(x)^2 - 1)

Sympy [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 22 vs. \(2 (10) = 20\).

Time = 0.22 (sec) , antiderivative size = 22, normalized size of antiderivative = 2.00 \[ \int x \coth (x) \text {csch}(x) \, dx=\frac {x \tanh {\left (\frac {x}{2} \right )}}{2} - \frac {x}{2 \tanh {\left (\frac {x}{2} \right )}} + \log {\left (\tanh {\left (\frac {x}{2} \right )} \right )} \]

[In]

integrate(x*cosh(x)/sinh(x)**2,x)

[Out]

x*tanh(x/2)/2 - x/(2*tanh(x/2)) + log(tanh(x/2))

Maxima [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 26 vs. \(2 (11) = 22\).

Time = 0.23 (sec) , antiderivative size = 26, normalized size of antiderivative = 2.36 \[ \int x \coth (x) \text {csch}(x) \, dx=-\frac {2 \, x e^{x}}{e^{\left (2 \, x\right )} - 1} - \log \left (e^{x} + 1\right ) + \log \left (e^{x} - 1\right ) \]

[In]

integrate(x*cosh(x)/sinh(x)^2,x, algorithm="maxima")

[Out]

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

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 49 vs. \(2 (11) = 22\).

Time = 0.28 (sec) , antiderivative size = 49, normalized size of antiderivative = 4.45 \[ \int x \coth (x) \text {csch}(x) \, dx=-\frac {2 \, x e^{x} + e^{\left (2 \, x\right )} \log \left (e^{x} + 1\right ) - e^{\left (2 \, x\right )} \log \left (e^{x} - 1\right ) - \log \left (e^{x} + 1\right ) + \log \left (e^{x} - 1\right )}{e^{\left (2 \, x\right )} - 1} \]

[In]

integrate(x*cosh(x)/sinh(x)^2,x, algorithm="giac")

[Out]

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

Mupad [B] (verification not implemented)

Time = 0.10 (sec) , antiderivative size = 30, normalized size of antiderivative = 2.73 \[ \int x \coth (x) \text {csch}(x) \, dx=\ln \left (2-2\,{\mathrm {e}}^x\right )-\ln \left (-2\,{\mathrm {e}}^x-2\right )-\frac {2\,x\,{\mathrm {e}}^x}{{\mathrm {e}}^{2\,x}-1} \]

[In]

int((x*cosh(x))/sinh(x)^2,x)

[Out]

log(2 - 2*exp(x)) - log(- 2*exp(x) - 2) - (2*x*exp(x))/(exp(2*x) - 1)