3.109 \(\int \frac {\coth (x)}{a+a \text {sech}(x)} \, dx\)

Optimal. Leaf size=40 \[ \frac {1}{2 a (\cosh (x)+1)}+\frac {\log (1-\cosh (x))}{4 a}+\frac {3 \log (\cosh (x)+1)}{4 a} \]

[Out]

1/2/a/(1+cosh(x))+1/4*ln(1-cosh(x))/a+3/4*ln(1+cosh(x))/a

________________________________________________________________________________________

Rubi [A]  time = 0.06, antiderivative size = 40, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 2, integrand size = 11, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.182, Rules used = {3879, 88} \[ \frac {1}{2 a (\cosh (x)+1)}+\frac {\log (1-\cosh (x))}{4 a}+\frac {3 \log (\cosh (x)+1)}{4 a} \]

Antiderivative was successfully verified.

[In]

Int[Coth[x]/(a + a*Sech[x]),x]

[Out]

1/(2*a*(1 + Cosh[x])) + Log[1 - Cosh[x]]/(4*a) + (3*Log[1 + Cosh[x]])/(4*a)

Rule 88

Int[((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.)*((e_.) + (f_.)*(x_))^(p_.), x_Symbol] :> Int[ExpandI
ntegrand[(a + b*x)^m*(c + d*x)^n*(e + f*x)^p, x], x] /; FreeQ[{a, b, c, d, e, f, p}, x] && IntegersQ[m, n] &&
(IntegerQ[p] || (GtQ[m, 0] && GeQ[n, -1]))

Rule 3879

Int[cot[(c_.) + (d_.)*(x_)]^(m_.)*(csc[(c_.) + (d_.)*(x_)]*(b_.) + (a_))^(n_.), x_Symbol] :> Dist[1/(a^(m - n
- 1)*b^n*d), Subst[Int[((a - b*x)^((m - 1)/2)*(a + b*x)^((m - 1)/2 + n))/x^(m + n), x], x, Sin[c + d*x]], x] /
; FreeQ[{a, b, c, d}, x] && IntegerQ[(m - 1)/2] && EqQ[a^2 - b^2, 0] && IntegerQ[n]

Rubi steps

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

________________________________________________________________________________________

Mathematica [A]  time = 0.05, size = 44, normalized size = 1.10 \[ \frac {\text {sech}(x) \left (2 \cosh ^2\left (\frac {x}{2}\right ) \left (\log \left (\sinh \left (\frac {x}{2}\right )\right )+3 \log \left (\cosh \left (\frac {x}{2}\right )\right )\right )+1\right )}{2 a (\text {sech}(x)+1)} \]

Antiderivative was successfully verified.

[In]

Integrate[Coth[x]/(a + a*Sech[x]),x]

[Out]

((1 + 2*Cosh[x/2]^2*(3*Log[Cosh[x/2]] + Log[Sinh[x/2]]))*Sech[x])/(2*a*(1 + Sech[x]))

________________________________________________________________________________________

fricas [B]  time = 0.39, size = 136, normalized size = 3.40 \[ -\frac {2 \, x \cosh \relax (x)^{2} + 2 \, x \sinh \relax (x)^{2} + 2 \, {\left (2 \, x - 1\right )} \cosh \relax (x) - 3 \, {\left (\cosh \relax (x)^{2} + 2 \, {\left (\cosh \relax (x) + 1\right )} \sinh \relax (x) + \sinh \relax (x)^{2} + 2 \, \cosh \relax (x) + 1\right )} \log \left (\cosh \relax (x) + \sinh \relax (x) + 1\right ) - {\left (\cosh \relax (x)^{2} + 2 \, {\left (\cosh \relax (x) + 1\right )} \sinh \relax (x) + \sinh \relax (x)^{2} + 2 \, \cosh \relax (x) + 1\right )} \log \left (\cosh \relax (x) + \sinh \relax (x) - 1\right ) + 2 \, {\left (2 \, x \cosh \relax (x) + 2 \, x - 1\right )} \sinh \relax (x) + 2 \, x}{2 \, {\left (a \cosh \relax (x)^{2} + a \sinh \relax (x)^{2} + 2 \, a \cosh \relax (x) + 2 \, {\left (a \cosh \relax (x) + a\right )} \sinh \relax (x) + a\right )}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(coth(x)/(a+a*sech(x)),x, algorithm="fricas")

[Out]

-1/2*(2*x*cosh(x)^2 + 2*x*sinh(x)^2 + 2*(2*x - 1)*cosh(x) - 3*(cosh(x)^2 + 2*(cosh(x) + 1)*sinh(x) + sinh(x)^2
 + 2*cosh(x) + 1)*log(cosh(x) + sinh(x) + 1) - (cosh(x)^2 + 2*(cosh(x) + 1)*sinh(x) + sinh(x)^2 + 2*cosh(x) +
1)*log(cosh(x) + sinh(x) - 1) + 2*(2*x*cosh(x) + 2*x - 1)*sinh(x) + 2*x)/(a*cosh(x)^2 + a*sinh(x)^2 + 2*a*cosh
(x) + 2*(a*cosh(x) + a)*sinh(x) + a)

________________________________________________________________________________________

giac [A]  time = 0.12, size = 56, normalized size = 1.40 \[ \frac {3 \, \log \left (e^{\left (-x\right )} + e^{x} + 2\right )}{4 \, a} + \frac {\log \left (e^{\left (-x\right )} + e^{x} - 2\right )}{4 \, a} - \frac {3 \, e^{\left (-x\right )} + 3 \, e^{x} + 2}{4 \, a {\left (e^{\left (-x\right )} + e^{x} + 2\right )}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(coth(x)/(a+a*sech(x)),x, algorithm="giac")

[Out]

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

________________________________________________________________________________________

maple [A]  time = 0.16, size = 47, normalized size = 1.18 \[ -\frac {\tanh ^{2}\left (\frac {x}{2}\right )}{4 a}-\frac {\ln \left (\tanh \left (\frac {x}{2}\right )-1\right )}{a}-\frac {\ln \left (\tanh \left (\frac {x}{2}\right )+1\right )}{a}+\frac {\ln \left (\tanh \left (\frac {x}{2}\right )\right )}{2 a} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(coth(x)/(a+a*sech(x)),x)

[Out]

-1/4/a*tanh(1/2*x)^2-1/a*ln(tanh(1/2*x)-1)-1/a*ln(tanh(1/2*x)+1)+1/2/a*ln(tanh(1/2*x))

________________________________________________________________________________________

maxima [A]  time = 0.49, size = 52, normalized size = 1.30 \[ \frac {x}{a} + \frac {e^{\left (-x\right )}}{2 \, a e^{\left (-x\right )} + a e^{\left (-2 \, x\right )} + a} + \frac {3 \, \log \left (e^{\left (-x\right )} + 1\right )}{2 \, a} + \frac {\log \left (e^{\left (-x\right )} - 1\right )}{2 \, a} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(coth(x)/(a+a*sech(x)),x, algorithm="maxima")

[Out]

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

________________________________________________________________________________________

mupad [B]  time = 1.37, size = 65, normalized size = 1.62 \[ \frac {\ln \left ({\mathrm {e}}^{2\,x}-1\right )}{a}-\frac {x}{a}-\frac {1}{a+2\,a\,{\mathrm {e}}^x+a\,{\mathrm {e}}^{2\,x}}+\frac {\mathrm {atan}\left (\frac {{\mathrm {e}}^x\,\sqrt {-a^2}}{a}\right )}{\sqrt {-a^2}}+\frac {1}{a+a\,{\mathrm {e}}^x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(coth(x)/(a + a/cosh(x)),x)

[Out]

log(exp(2*x) - 1)/a - x/a - 1/(a + 2*a*exp(x) + a*exp(2*x)) + atan((exp(x)*(-a^2)^(1/2))/a)/(-a^2)^(1/2) + 1/(
a + a*exp(x))

________________________________________________________________________________________

sympy [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \frac {\int \frac {\coth {\relax (x )}}{\operatorname {sech}{\relax (x )} + 1}\, dx}{a} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(coth(x)/(a+a*sech(x)),x)

[Out]

Integral(coth(x)/(sech(x) + 1), x)/a

________________________________________________________________________________________