Optimal. Leaf size=42 \[ \frac{10 \coth (x)}{3}+2 i \tanh ^{-1}(\cosh (x))-\frac{2 i \coth (x)}{\sinh (x)+i}+\frac{\coth (x)}{3 (\sinh (x)+i)^2} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.117322, antiderivative size = 42, normalized size of antiderivative = 1., number of steps used = 6, number of rules used = 6, integrand size = 13, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.462, Rules used = {2766, 2978, 2748, 3767, 8, 3770} \[ \frac{10 \coth (x)}{3}+2 i \tanh ^{-1}(\cosh (x))-\frac{2 i \coth (x)}{\sinh (x)+i}+\frac{\coth (x)}{3 (\sinh (x)+i)^2} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 2766
Rule 2978
Rule 2748
Rule 3767
Rule 8
Rule 3770
Rubi steps
\begin{align*} \int \frac{\text{csch}^2(x)}{(i+\sinh (x))^2} \, dx &=\frac{\coth (x)}{3 (i+\sinh (x))^2}-\frac{1}{3} \int \frac{\text{csch}^2(x) (4 i-2 \sinh (x))}{i+\sinh (x)} \, dx\\ &=\frac{\coth (x)}{3 (i+\sinh (x))^2}-\frac{2 i \coth (x)}{i+\sinh (x)}+\frac{1}{3} \int \text{csch}^2(x) (-10-6 i \sinh (x)) \, dx\\ &=\frac{\coth (x)}{3 (i+\sinh (x))^2}-\frac{2 i \coth (x)}{i+\sinh (x)}-2 i \int \text{csch}(x) \, dx-\frac{10}{3} \int \text{csch}^2(x) \, dx\\ &=2 i \tanh ^{-1}(\cosh (x))+\frac{\coth (x)}{3 (i+\sinh (x))^2}-\frac{2 i \coth (x)}{i+\sinh (x)}+\frac{10}{3} i \operatorname{Subst}(\int 1 \, dx,x,-i \coth (x))\\ &=2 i \tanh ^{-1}(\cosh (x))+\frac{10 \coth (x)}{3}+\frac{\coth (x)}{3 (i+\sinh (x))^2}-\frac{2 i \coth (x)}{i+\sinh (x)}\\ \end{align*}
Mathematica [B] time = 0.35467, size = 88, normalized size = 2.1 \[ \frac{1}{6} \left (\frac{2}{\sinh (x)+i}+3 \tanh \left (\frac{x}{2}\right )+3 \coth \left (\frac{x}{2}\right )-12 i \log \left (\sinh \left (\frac{x}{2}\right )\right )+12 i \log \left (\cosh \left (\frac{x}{2}\right )\right )-\frac{4 \sinh \left (\frac{x}{2}\right ) (7 \sinh (x)+8 i)}{\left (\sinh \left (\frac{x}{2}\right )+i \cosh \left (\frac{x}{2}\right )\right )^3}\right ) \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.043, size = 58, normalized size = 1.4 \begin{align*}{\frac{1}{2}\tanh \left ({\frac{x}{2}} \right ) }-2\,i\ln \left ( \tanh \left ({\frac{x}{2}} \right ) \right ) +{\frac{1}{2} \left ( \tanh \left ({\frac{x}{2}} \right ) \right ) ^{-1}}-{2\,i \left ( \tanh \left ({\frac{x}{2}} \right ) +i \right ) ^{-2}}-{\frac{4}{3} \left ( \tanh \left ({\frac{x}{2}} \right ) +i \right ) ^{-3}}+6\, \left ( \tanh \left ( x/2 \right ) +i \right ) ^{-1} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [B] time = 1.23921, size = 109, normalized size = 2.6 \begin{align*} \frac{4 \,{\left (12 \, e^{\left (-x\right )} + 11 i \, e^{\left (-2 \, x\right )} - 9 \, e^{\left (-3 \, x\right )} - 3 i \, e^{\left (-4 \, x\right )} - 5 i\right )}}{9 \, e^{\left (-x\right )} + 12 i \, e^{\left (-2 \, x\right )} - 12 \, e^{\left (-3 \, x\right )} - 9 i \, e^{\left (-4 \, x\right )} + 3 \, e^{\left (-5 \, x\right )} - 3 i} + 2 i \, \log \left (e^{\left (-x\right )} + 1\right ) - 2 i \, \log \left (e^{\left (-x\right )} - 1\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] time = 2.04185, size = 404, normalized size = 9.62 \begin{align*} \frac{{\left (6 i \, e^{\left (5 \, x\right )} - 18 \, e^{\left (4 \, x\right )} - 24 i \, e^{\left (3 \, x\right )} + 24 \, e^{\left (2 \, x\right )} + 18 i \, e^{x} - 6\right )} \log \left (e^{x} + 1\right ) +{\left (-6 i \, e^{\left (5 \, x\right )} + 18 \, e^{\left (4 \, x\right )} + 24 i \, e^{\left (3 \, x\right )} - 24 \, e^{\left (2 \, x\right )} - 18 i \, e^{x} + 6\right )} \log \left (e^{x} - 1\right ) - 12 i \, e^{\left (4 \, x\right )} + 36 \, e^{\left (3 \, x\right )} + 44 i \, e^{\left (2 \, x\right )} - 48 \, e^{x} - 20 i}{3 \, e^{\left (5 \, x\right )} + 9 i \, e^{\left (4 \, x\right )} - 12 \, e^{\left (3 \, x\right )} - 12 i \, e^{\left (2 \, x\right )} + 9 \, e^{x} + 3 i} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A] time = 1.32053, size = 62, normalized size = 1.48 \begin{align*} \frac{2}{e^{\left (2 \, x\right )} - 1} - \frac{2 \,{\left (6 i \, e^{\left (2 \, x\right )} - 15 \, e^{x} - 7 i\right )}}{3 \,{\left (e^{x} + i\right )}^{3}} + 2 i \, \log \left (e^{x} + 1\right ) - 2 i \, \log \left ({\left | e^{x} - 1 \right |}\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]