3.66 \(\int \frac {1}{(1+\coth (x))^2} \, dx\)

Optimal. Leaf size=26 \[ \frac {x}{4}-\frac {1}{4 (\coth (x)+1)}-\frac {1}{4 (\coth (x)+1)^2} \]

[Out]

1/4*x-1/4/(1+coth(x))^2-1/4/(1+coth(x))

________________________________________________________________________________________

Rubi [A]  time = 0.02, antiderivative size = 26, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 2, integrand size = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.333, Rules used = {3479, 8} \[ \frac {x}{4}-\frac {1}{4 (\coth (x)+1)}-\frac {1}{4 (\coth (x)+1)^2} \]

Antiderivative was successfully verified.

[In]

Int[(1 + Coth[x])^(-2),x]

[Out]

x/4 - 1/(4*(1 + Coth[x])^2) - 1/(4*(1 + Coth[x]))

Rule 8

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

Rule 3479

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

Rubi steps

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

________________________________________________________________________________________

Mathematica [A]  time = 0.06, size = 30, normalized size = 1.15 \[ \frac {1}{16} (4 x-4 \sinh (2 x)+\sinh (4 x)+4 \cosh (2 x)-\cosh (4 x)) \]

Antiderivative was successfully verified.

[In]

Integrate[(1 + Coth[x])^(-2),x]

[Out]

(4*x + 4*Cosh[2*x] - Cosh[4*x] - 4*Sinh[2*x] + Sinh[4*x])/16

________________________________________________________________________________________

fricas [B]  time = 0.38, size = 52, normalized size = 2.00 \[ \frac {{\left (4 \, x - 1\right )} \cosh \relax (x)^{2} + 2 \, {\left (4 \, x + 1\right )} \cosh \relax (x) \sinh \relax (x) + {\left (4 \, x - 1\right )} \sinh \relax (x)^{2} + 4}{16 \, {\left (\cosh \relax (x)^{2} + 2 \, \cosh \relax (x) \sinh \relax (x) + \sinh \relax (x)^{2}\right )}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(1+coth(x))^2,x, algorithm="fricas")

[Out]

1/16*((4*x - 1)*cosh(x)^2 + 2*(4*x + 1)*cosh(x)*sinh(x) + (4*x - 1)*sinh(x)^2 + 4)/(cosh(x)^2 + 2*cosh(x)*sinh
(x) + sinh(x)^2)

________________________________________________________________________________________

giac [A]  time = 0.11, size = 18, normalized size = 0.69 \[ \frac {1}{16} \, {\left (4 \, e^{\left (2 \, x\right )} - 1\right )} e^{\left (-4 \, x\right )} + \frac {1}{4} \, x \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(1+coth(x))^2,x, algorithm="giac")

[Out]

1/16*(4*e^(2*x) - 1)*e^(-4*x) + 1/4*x

________________________________________________________________________________________

maple [A]  time = 0.05, size = 32, normalized size = 1.23 \[ -\frac {\ln \left (\coth \relax (x )-1\right )}{8}-\frac {1}{4 \left (1+\coth \relax (x )\right )^{2}}-\frac {1}{4 \left (1+\coth \relax (x )\right )}+\frac {\ln \left (1+\coth \relax (x )\right )}{8} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(1+coth(x))^2,x)

[Out]

-1/8*ln(coth(x)-1)-1/4/(1+coth(x))^2-1/4/(1+coth(x))+1/8*ln(1+coth(x))

________________________________________________________________________________________

maxima [A]  time = 0.31, size = 16, normalized size = 0.62 \[ \frac {1}{4} \, x + \frac {1}{4} \, e^{\left (-2 \, x\right )} - \frac {1}{16} \, e^{\left (-4 \, x\right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(1+coth(x))^2,x, algorithm="maxima")

[Out]

1/4*x + 1/4*e^(-2*x) - 1/16*e^(-4*x)

________________________________________________________________________________________

mupad [B]  time = 0.05, size = 16, normalized size = 0.62 \[ \frac {x}{4}+\frac {{\mathrm {e}}^{-2\,x}}{4}-\frac {{\mathrm {e}}^{-4\,x}}{16} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(coth(x) + 1)^2,x)

[Out]

x/4 + exp(-2*x)/4 - exp(-4*x)/16

________________________________________________________________________________________

sympy [B]  time = 0.81, size = 88, normalized size = 3.38 \[ \frac {x \tanh ^{2}{\relax (x )}}{4 \tanh ^{2}{\relax (x )} + 8 \tanh {\relax (x )} + 4} + \frac {2 x \tanh {\relax (x )}}{4 \tanh ^{2}{\relax (x )} + 8 \tanh {\relax (x )} + 4} + \frac {x}{4 \tanh ^{2}{\relax (x )} + 8 \tanh {\relax (x )} + 4} + \frac {3 \tanh {\relax (x )}}{4 \tanh ^{2}{\relax (x )} + 8 \tanh {\relax (x )} + 4} + \frac {2}{4 \tanh ^{2}{\relax (x )} + 8 \tanh {\relax (x )} + 4} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(1+coth(x))**2,x)

[Out]

x*tanh(x)**2/(4*tanh(x)**2 + 8*tanh(x) + 4) + 2*x*tanh(x)/(4*tanh(x)**2 + 8*tanh(x) + 4) + x/(4*tanh(x)**2 + 8
*tanh(x) + 4) + 3*tanh(x)/(4*tanh(x)**2 + 8*tanh(x) + 4) + 2/(4*tanh(x)**2 + 8*tanh(x) + 4)

________________________________________________________________________________________