Optimal. Leaf size=64 \[ -\frac {b x}{a^2-b^2}+\frac {a \log (\sinh (x))}{a^2-b^2}+\frac {a^3 \log (a+b \coth (x))}{b^2 \left (a^2-b^2\right )}-\frac {\coth (x)}{b} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.13, antiderivative size = 64, normalized size of antiderivative = 1.00, 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 = {3566, 3626, 3617, 31, 3475} \[ -\frac {b x}{a^2-b^2}+\frac {a \log (\sinh (x))}{a^2-b^2}+\frac {a^3 \log (a+b \coth (x))}{b^2 \left (a^2-b^2\right )}-\frac {\coth (x)}{b} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 31
Rule 3475
Rule 3566
Rule 3617
Rule 3626
Rubi steps
\begin {align*} \int \frac {\coth ^3(x)}{a+b \coth (x)} \, dx &=-\frac {\coth (x)}{b}-\frac {\int \frac {-a-b \coth (x)+a \coth ^2(x)}{a+b \coth (x)} \, dx}{b}\\ &=-\frac {b x}{a^2-b^2}-\frac {\coth (x)}{b}+\frac {a \int \coth (x) \, dx}{a^2-b^2}+\frac {a^3 \int \frac {1-\coth ^2(x)}{a+b \coth (x)} \, dx}{b \left (a^2-b^2\right )}\\ &=-\frac {b x}{a^2-b^2}-\frac {\coth (x)}{b}+\frac {a \log (\sinh (x))}{a^2-b^2}+\frac {a^3 \operatorname {Subst}\left (\int \frac {1}{a+x} \, dx,x,b \coth (x)\right )}{b^2 \left (a^2-b^2\right )}\\ &=-\frac {b x}{a^2-b^2}-\frac {\coth (x)}{b}+\frac {a^3 \log (a+b \coth (x))}{b^2 \left (a^2-b^2\right )}+\frac {a \log (\sinh (x))}{a^2-b^2}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.14, size = 64, normalized size = 1.00 \[ \frac {a^3 (-\log (a \sinh (x)+b \cosh (x)))+b \left (a^2-b^2\right ) \coth (x)+a \left (a^2-b^2\right ) \log (\sinh (x))+b^3 x}{b^2 (b-a) (a+b)} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [B] time = 0.45, size = 271, normalized size = 4.23 \[ \frac {{\left (a b^{2} + b^{3}\right )} x \cosh \relax (x)^{2} + 2 \, {\left (a b^{2} + b^{3}\right )} x \cosh \relax (x) \sinh \relax (x) + {\left (a b^{2} + b^{3}\right )} x \sinh \relax (x)^{2} + 2 \, a^{2} b - 2 \, b^{3} - {\left (a b^{2} + b^{3}\right )} x - {\left (a^{3} \cosh \relax (x)^{2} + 2 \, a^{3} \cosh \relax (x) \sinh \relax (x) + a^{3} \sinh \relax (x)^{2} - a^{3}\right )} \log \left (\frac {2 \, {\left (b \cosh \relax (x) + a \sinh \relax (x)\right )}}{\cosh \relax (x) - \sinh \relax (x)}\right ) - {\left (a^{3} - a b^{2} - {\left (a^{3} - a b^{2}\right )} \cosh \relax (x)^{2} - 2 \, {\left (a^{3} - a b^{2}\right )} \cosh \relax (x) \sinh \relax (x) - {\left (a^{3} - a b^{2}\right )} \sinh \relax (x)^{2}\right )} \log \left (\frac {2 \, \sinh \relax (x)}{\cosh \relax (x) - \sinh \relax (x)}\right )}{a^{2} b^{2} - b^{4} - {\left (a^{2} b^{2} - b^{4}\right )} \cosh \relax (x)^{2} - 2 \, {\left (a^{2} b^{2} - b^{4}\right )} \cosh \relax (x) \sinh \relax (x) - {\left (a^{2} b^{2} - b^{4}\right )} \sinh \relax (x)^{2}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.12, size = 76, normalized size = 1.19 \[ \frac {a^{3} \log \left ({\left | a e^{\left (2 \, x\right )} + b e^{\left (2 \, x\right )} - a + b \right |}\right )}{a^{2} b^{2} - b^{4}} - \frac {x}{a - b} - \frac {a \log \left ({\left | e^{\left (2 \, x\right )} - 1 \right |}\right )}{b^{2}} - \frac {2}{b {\left (e^{\left (2 \, x\right )} - 1\right )}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.07, size = 67, normalized size = 1.05 \[ -\frac {\coth \relax (x )}{b}-\frac {\ln \left (\coth \relax (x )-1\right )}{2 b +2 a}-\frac {\ln \left (1+\coth \relax (x )\right )}{2 a -2 b}+\frac {a^{3} \ln \left (a +b \coth \relax (x )\right )}{b^{2} \left (a +b \right ) \left (a -b \right )} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.31, size = 82, normalized size = 1.28 \[ \frac {a^{3} \log \left (-{\left (a - b\right )} e^{\left (-2 \, x\right )} + a + b\right )}{a^{2} b^{2} - b^{4}} + \frac {x}{a + b} - \frac {a \log \left (e^{\left (-x\right )} + 1\right )}{b^{2}} - \frac {a \log \left (e^{\left (-x\right )} - 1\right )}{b^{2}} + \frac {2}{b e^{\left (-2 \, x\right )} - b} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 1.51, size = 74, normalized size = 1.16 \[ -\frac {2}{b\,\left ({\mathrm {e}}^{2\,x}-1\right )}-\frac {x}{a-b}-\frac {a^3\,\ln \left (b-a+a\,{\mathrm {e}}^{2\,x}+b\,{\mathrm {e}}^{2\,x}\right )}{b^4-a^2\,b^2}-\frac {a\,\ln \left ({\mathrm {e}}^{2\,x}-1\right )}{b^2} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 2.40, size = 636, normalized size = 9.94 \[ \text {result too large to display} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________