Optimal. Leaf size=20 \[ \frac{i x}{2}+\cosh (x)-\frac{1}{2} i \sinh (x) \cosh (x) \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0923256, antiderivative size = 20, normalized size of antiderivative = 1., number of steps used = 5, number of rules used = 5, integrand size = 13, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.385, Rules used = {3872, 2839, 2638, 2635, 8} \[ \frac{i x}{2}+\cosh (x)-\frac{1}{2} i \sinh (x) \cosh (x) \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 3872
Rule 2839
Rule 2638
Rule 2635
Rule 8
Rubi steps
\begin{align*} \int \frac{\cosh ^2(x)}{i+\text{csch}(x)} \, dx &=i \int \frac{\cosh ^2(x) \sinh (x)}{i-\sinh (x)} \, dx\\ &=-\left (i \int \sinh ^2(x) \, dx\right )+\int \sinh (x) \, dx\\ &=\cosh (x)-\frac{1}{2} i \cosh (x) \sinh (x)+\frac{1}{2} i \int 1 \, dx\\ &=\frac{i x}{2}+\cosh (x)-\frac{1}{2} i \cosh (x) \sinh (x)\\ \end{align*}
Mathematica [A] time = 0.0294516, size = 20, normalized size = 1. \[ \frac{i x}{2}-\frac{1}{4} i \sinh (2 x)+\cosh (x) \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] time = 0.033, size = 84, normalized size = 4.2 \begin{align*}{{\frac{i}{2}} \left ( \tanh \left ({\frac{x}{2}} \right ) +1 \right ) ^{-2}}+{\frac{i}{2}}\ln \left ( \tanh \left ({\frac{x}{2}} \right ) +1 \right ) + \left ( \tanh \left ({\frac{x}{2}} \right ) +1 \right ) ^{-1}-{{\frac{i}{2}} \left ( \tanh \left ({\frac{x}{2}} \right ) +1 \right ) ^{-1}}-{\frac{i}{2}}\ln \left ( \tanh \left ({\frac{x}{2}} \right ) -1 \right ) -{{\frac{i}{2}} \left ( \tanh \left ({\frac{x}{2}} \right ) -1 \right ) ^{-2}}- \left ( \tanh \left ({\frac{x}{2}} \right ) -1 \right ) ^{-1}-{{\frac{i}{2}} \left ( \tanh \left ({\frac{x}{2}} \right ) -1 \right ) ^{-1}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [B] time = 1.04373, size = 41, normalized size = 2.05 \begin{align*} \frac{1}{8} \,{\left (4 \, e^{\left (-x\right )} - i\right )} e^{\left (2 \, x\right )} + \frac{1}{2} i \, x + \frac{1}{2} \, e^{\left (-x\right )} + \frac{1}{8} i \, e^{\left (-2 \, x\right )} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] time = 1.89306, size = 89, normalized size = 4.45 \begin{align*} \frac{1}{8} \,{\left (4 i \, x e^{\left (2 \, x\right )} - i \, e^{\left (4 \, x\right )} + 4 \, e^{\left (3 \, x\right )} + 4 \, e^{x} + i\right )} e^{\left (-2 \, x\right )} \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 [B] time = 1.24136, size = 35, normalized size = 1.75 \begin{align*} \frac{1}{8} \,{\left (4 \, e^{x} + i\right )} e^{\left (-2 \, x\right )} + \frac{1}{2} i \, x - \frac{1}{8} i \, e^{\left (2 \, x\right )} + \frac{1}{2} \, e^{x} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]