3.1.90 \(\int \frac {\text {csch}(x)}{i+\tanh (x)} \, dx\) [90]

Optimal. Leaf size=33 \[ i \tanh ^{-1}(\cosh (x))-\frac {i \tanh ^{-1}\left (\frac {\cosh (x)+i \sinh (x)}{\sqrt {2}}\right )}{\sqrt {2}} \]

[Out]

I*arctanh(cosh(x))-1/2*I*arctanh(1/2*(cosh(x)+I*sinh(x))*2^(1/2))*2^(1/2)

________________________________________________________________________________________

Rubi [A]
time = 0.07, antiderivative size = 33, normalized size of antiderivative = 1.00, number of steps used = 6, number of rules used = 5, integrand size = 11, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.454, Rules used = {3599, 3189, 3855, 3153, 212} \begin {gather*} i \tanh ^{-1}(\cosh (x))-\frac {i \tanh ^{-1}\left (\frac {\cosh (x)+i \sinh (x)}{\sqrt {2}}\right )}{\sqrt {2}} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[Csch[x]/(I + Tanh[x]),x]

[Out]

I*ArcTanh[Cosh[x]] - (I*ArcTanh[(Cosh[x] + I*Sinh[x])/Sqrt[2]])/Sqrt[2]

Rule 212

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[-b, 2]))*ArcTanh[Rt[-b, 2]*(x/Rt[a, 2])], x]
 /; FreeQ[{a, b}, x] && NegQ[a/b] && (GtQ[a, 0] || LtQ[b, 0])

Rule 3153

Int[(cos[(c_.) + (d_.)*(x_)]*(a_.) + (b_.)*sin[(c_.) + (d_.)*(x_)])^(-1), x_Symbol] :> Dist[-d^(-1), Subst[Int
[1/(a^2 + b^2 - x^2), x], x, b*Cos[c + d*x] - a*Sin[c + d*x]], x] /; FreeQ[{a, b, c, d}, x] && NeQ[a^2 + b^2,
0]

Rule 3189

Int[(cos[(c_.) + (d_.)*(x_)]^(m_.)*sin[(c_.) + (d_.)*(x_)]^(n_.))/(cos[(c_.) + (d_.)*(x_)]*(a_.) + (b_.)*sin[(
c_.) + (d_.)*(x_)]), x_Symbol] :> Int[ExpandTrig[cos[c + d*x]^m*(sin[c + d*x]^n/(a*cos[c + d*x] + b*sin[c + d*
x])), x], x] /; FreeQ[{a, b, c, d, m, n}, x] && IntegersQ[m, n]

Rule 3599

Int[sin[(e_.) + (f_.)*(x_)]^(m_.)*((a_) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(n_.), x_Symbol] :> Int[Sin[e + f*x]^
m*((a*Cos[e + f*x] + b*Sin[e + f*x])^n/Cos[e + f*x]^n), x] /; FreeQ[{a, b, e, f}, x] && IntegerQ[(m - 1)/2] &&
 ILtQ[n, 0] && ((LtQ[m, 5] && GtQ[n, -4]) || (EqQ[m, 5] && EqQ[n, -1]))

Rule 3855

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

Rubi steps

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

________________________________________________________________________________________

Mathematica [A]
time = 0.05, size = 46, normalized size = 1.39 \begin {gather*} -i \left (\sqrt {2} \tanh ^{-1}\left (\frac {1+i \tanh \left (\frac {x}{2}\right )}{\sqrt {2}}\right )-\log \left (\cosh \left (\frac {x}{2}\right )\right )+\log \left (\sinh \left (\frac {x}{2}\right )\right )\right ) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[Csch[x]/(I + Tanh[x]),x]

[Out]

(-I)*(Sqrt[2]*ArcTanh[(1 + I*Tanh[x/2])/Sqrt[2]] - Log[Cosh[x/2]] + Log[Sinh[x/2]])

________________________________________________________________________________________

Maple [A]
time = 0.93, size = 29, normalized size = 0.88

method result size
default \(\sqrt {2}\, \arctan \left (\frac {\left (2 \tanh \left (\frac {x}{2}\right )-2 i\right ) \sqrt {2}}{4}\right )-i \ln \left (\tanh \left (\frac {x}{2}\right )\right )\) \(29\)
risch \(i \ln \left ({\mathrm e}^{x}+1\right )+\frac {i \sqrt {2}\, \ln \left ({\mathrm e}^{x}-\frac {\sqrt {2}}{2}+\frac {i \sqrt {2}}{2}\right )}{2}-\frac {i \sqrt {2}\, \ln \left ({\mathrm e}^{x}+\frac {\sqrt {2}}{2}-\frac {i \sqrt {2}}{2}\right )}{2}-i \ln \left ({\mathrm e}^{x}-1\right )\) \(60\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(csch(x)/(I+tanh(x)),x,method=_RETURNVERBOSE)

[Out]

2^(1/2)*arctan(1/4*(2*tanh(1/2*x)-2*I)*2^(1/2))-I*ln(tanh(1/2*x))

________________________________________________________________________________________

Maxima [A]
time = 0.53, size = 34, normalized size = 1.03 \begin {gather*} -\sqrt {2} \arctan \left (\left (\frac {1}{2} i + \frac {1}{2}\right ) \, \sqrt {2} e^{\left (-x\right )}\right ) + i \, \log \left (e^{\left (-x\right )} + 1\right ) - i \, \log \left (e^{\left (-x\right )} - 1\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csch(x)/(I+tanh(x)),x, algorithm="maxima")

[Out]

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

________________________________________________________________________________________

Fricas [A]
time = 0.38, size = 43, normalized size = 1.30 \begin {gather*} -\frac {1}{2} i \, \sqrt {2} \log \left (-\left (\frac {1}{2} i - \frac {1}{2}\right ) \, \sqrt {2} + e^{x}\right ) + \frac {1}{2} i \, \sqrt {2} \log \left (\left (\frac {1}{2} i - \frac {1}{2}\right ) \, \sqrt {2} + e^{x}\right ) + i \, \log \left (e^{x} + 1\right ) - i \, \log \left (e^{x} - 1\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csch(x)/(I+tanh(x)),x, algorithm="fricas")

[Out]

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

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {\operatorname {csch}{\left (x \right )}}{\tanh {\left (x \right )} + i}\, dx \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csch(x)/(I+tanh(x)),x)

[Out]

Integral(csch(x)/(tanh(x) + I), x)

________________________________________________________________________________________

Giac [A]
time = 0.40, size = 28, normalized size = 0.85 \begin {gather*} \sqrt {2} \arctan \left (-\left (\frac {1}{2} i - \frac {1}{2}\right ) \, \sqrt {2} e^{x}\right ) + i \, \log \left (e^{x} + 1\right ) - i \, \log \left ({\left | e^{x} - 1 \right |}\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csch(x)/(I+tanh(x)),x, algorithm="giac")

[Out]

sqrt(2)*arctan(-(1/2*I - 1/2)*sqrt(2)*e^x) + I*log(e^x + 1) - I*log(abs(e^x - 1))

________________________________________________________________________________________

Mupad [B]
time = 0.46, size = 61, normalized size = 1.85 \begin {gather*} \ln \left (-8\,{\mathrm {e}}^x-8\right )\,1{}\mathrm {i}-\ln \left (8-8\,{\mathrm {e}}^x\right )\,1{}\mathrm {i}-\frac {\sqrt {2}\,\ln \left ({\mathrm {e}}^x\,\left (4-4{}\mathrm {i}\right )-\sqrt {2}\,4{}\mathrm {i}\right )\,1{}\mathrm {i}}{2}+\frac {\sqrt {2}\,\ln \left ({\mathrm {e}}^x\,\left (4-4{}\mathrm {i}\right )+\sqrt {2}\,4{}\mathrm {i}\right )\,1{}\mathrm {i}}{2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(sinh(x)*(tanh(x) + 1i)),x)

[Out]

log(- 8*exp(x) - 8)*1i - log(8 - 8*exp(x))*1i - (2^(1/2)*log(exp(x)*(4 - 4i) - 2^(1/2)*4i)*1i)/2 + (2^(1/2)*lo
g(exp(x)*(4 - 4i) + 2^(1/2)*4i)*1i)/2

________________________________________________________________________________________