Optimal. Leaf size=33 \[ -\frac{\tanh ^3(x)}{3 a}+\frac{\tan ^{-1}(\sinh (x))}{2 a}-\frac{\tanh (x) \text{sech}(x)}{2 a} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0797613, antiderivative size = 33, 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 = {2706, 2607, 30, 2611, 3770} \[ -\frac{\tanh ^3(x)}{3 a}+\frac{\tan ^{-1}(\sinh (x))}{2 a}-\frac{\tanh (x) \text{sech}(x)}{2 a} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 2706
Rule 2607
Rule 30
Rule 2611
Rule 3770
Rubi steps
\begin{align*} \int \frac{\tanh ^4(x)}{a+a \cosh (x)} \, dx &=\frac{\int \text{sech}(x) \tanh ^2(x) \, dx}{a}-\frac{\int \text{sech}^2(x) \tanh ^2(x) \, dx}{a}\\ &=-\frac{\text{sech}(x) \tanh (x)}{2 a}-\frac{i \operatorname{Subst}\left (\int x^2 \, dx,x,i \tanh (x)\right )}{a}+\frac{\int \text{sech}(x) \, dx}{2 a}\\ &=\frac{\tan ^{-1}(\sinh (x))}{2 a}-\frac{\text{sech}(x) \tanh (x)}{2 a}-\frac{\tanh ^3(x)}{3 a}\\ \end{align*}
Mathematica [A] time = 0.0593945, size = 46, normalized size = 1.39 \[ \frac{\cosh ^2\left (\frac{x}{2}\right ) \left (6 \tan ^{-1}\left (\tanh \left (\frac{x}{2}\right )\right )+\tanh (x) \left (2 \text{sech}^2(x)-3 \text{sech}(x)-2\right )\right )}{3 a (\cosh (x)+1)} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] time = 0.036, size = 71, normalized size = 2.2 \begin{align*}{\frac{1}{a} \left ( \tanh \left ({\frac{x}{2}} \right ) \right ) ^{5} \left ( \left ( \tanh \left ({\frac{x}{2}} \right ) \right ) ^{2}+1 \right ) ^{-3}}-{\frac{8}{3\,a} \left ( \tanh \left ({\frac{x}{2}} \right ) \right ) ^{3} \left ( \left ( \tanh \left ({\frac{x}{2}} \right ) \right ) ^{2}+1 \right ) ^{-3}}-{\frac{1}{a}\tanh \left ({\frac{x}{2}} \right ) \left ( \left ( \tanh \left ({\frac{x}{2}} \right ) \right ) ^{2}+1 \right ) ^{-3}}+{\frac{1}{a}\arctan \left ( \tanh \left ({\frac{x}{2}} \right ) \right ) } \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [B] time = 1.55904, size = 77, normalized size = 2.33 \begin{align*} -\frac{3 \, e^{\left (-x\right )} + 6 \, e^{\left (-4 \, x\right )} - 3 \, e^{\left (-5 \, x\right )} + 2}{3 \,{\left (3 \, a e^{\left (-2 \, x\right )} + 3 \, a e^{\left (-4 \, x\right )} + a e^{\left (-6 \, x\right )} + a\right )}} - \frac{\arctan \left (e^{\left (-x\right )}\right )}{a} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] time = 1.73557, size = 1031, normalized size = 31.24 \begin{align*} -\frac{3 \, \cosh \left (x\right )^{5} + 3 \,{\left (5 \, \cosh \left (x\right ) - 2\right )} \sinh \left (x\right )^{4} + 3 \, \sinh \left (x\right )^{5} - 6 \, \cosh \left (x\right )^{4} + 6 \,{\left (5 \, \cosh \left (x\right )^{2} - 4 \, \cosh \left (x\right )\right )} \sinh \left (x\right )^{3} + 6 \,{\left (5 \, \cosh \left (x\right )^{3} - 6 \, \cosh \left (x\right )^{2}\right )} \sinh \left (x\right )^{2} - 3 \,{\left (\cosh \left (x\right )^{6} + 6 \, \cosh \left (x\right ) \sinh \left (x\right )^{5} + \sinh \left (x\right )^{6} + 3 \,{\left (5 \, \cosh \left (x\right )^{2} + 1\right )} \sinh \left (x\right )^{4} + 3 \, \cosh \left (x\right )^{4} + 4 \,{\left (5 \, \cosh \left (x\right )^{3} + 3 \, \cosh \left (x\right )\right )} \sinh \left (x\right )^{3} + 3 \,{\left (5 \, \cosh \left (x\right )^{4} + 6 \, \cosh \left (x\right )^{2} + 1\right )} \sinh \left (x\right )^{2} + 3 \, \cosh \left (x\right )^{2} + 6 \,{\left (\cosh \left (x\right )^{5} + 2 \, \cosh \left (x\right )^{3} + \cosh \left (x\right )\right )} \sinh \left (x\right ) + 1\right )} \arctan \left (\cosh \left (x\right ) + \sinh \left (x\right )\right ) + 3 \,{\left (5 \, \cosh \left (x\right )^{4} - 8 \, \cosh \left (x\right )^{3} - 1\right )} \sinh \left (x\right ) - 3 \, \cosh \left (x\right ) - 2}{3 \,{\left (a \cosh \left (x\right )^{6} + 6 \, a \cosh \left (x\right ) \sinh \left (x\right )^{5} + a \sinh \left (x\right )^{6} + 3 \, a \cosh \left (x\right )^{4} + 3 \,{\left (5 \, a \cosh \left (x\right )^{2} + a\right )} \sinh \left (x\right )^{4} + 4 \,{\left (5 \, a \cosh \left (x\right )^{3} + 3 \, a \cosh \left (x\right )\right )} \sinh \left (x\right )^{3} + 3 \, a \cosh \left (x\right )^{2} + 3 \,{\left (5 \, a \cosh \left (x\right )^{4} + 6 \, a \cosh \left (x\right )^{2} + a\right )} \sinh \left (x\right )^{2} + 6 \,{\left (a \cosh \left (x\right )^{5} + 2 \, a \cosh \left (x\right )^{3} + a \cosh \left (x\right )\right )} \sinh \left (x\right ) + a\right )}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F] time = 0., size = 0, normalized size = 0. \begin{align*} \frac{\int \frac{\tanh ^{4}{\left (x \right )}}{\cosh{\left (x \right )} + 1}\, dx}{a} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A] time = 1.18156, size = 53, normalized size = 1.61 \begin{align*} \frac{\arctan \left (e^{x}\right )}{a} - \frac{3 \, e^{\left (5 \, x\right )} - 6 \, e^{\left (4 \, x\right )} - 3 \, e^{x} - 2}{3 \, a{\left (e^{\left (2 \, x\right )} + 1\right )}^{3}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]