Optimal. Leaf size=109 \[ -\frac {b \left (a^2-2 b^2\right ) \tanh ^{-1}(\cosh (x))}{2 a^4}-\frac {2 b^4 \tanh ^{-1}\left (\frac {b-a \tanh \left (\frac {x}{2}\right )}{\sqrt {a^2+b^2}}\right )}{a^4 \sqrt {a^2+b^2}}+\frac {\left (2 a^2-3 b^2\right ) \coth (x)}{3 a^3}+\frac {b \coth (x) \text {csch}(x)}{2 a^2}-\frac {\coth (x) \text {csch}^2(x)}{3 a} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.35, antiderivative size = 109, normalized size of antiderivative = 1.00, number of steps
used = 8, number of rules used = 7, integrand size = 13, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.538, Rules used = {2881, 3134,
3080, 3855, 2739, 632, 212} \begin {gather*} \frac {b \coth (x) \text {csch}(x)}{2 a^2}-\frac {b \left (a^2-2 b^2\right ) \tanh ^{-1}(\cosh (x))}{2 a^4}-\frac {2 b^4 \tanh ^{-1}\left (\frac {b-a \tanh \left (\frac {x}{2}\right )}{\sqrt {a^2+b^2}}\right )}{a^4 \sqrt {a^2+b^2}}+\frac {\left (2 a^2-3 b^2\right ) \coth (x)}{3 a^3}-\frac {\coth (x) \text {csch}^2(x)}{3 a} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 212
Rule 632
Rule 2739
Rule 2881
Rule 3080
Rule 3134
Rule 3855
Rubi steps
\begin {align*} \int \frac {\text {csch}^4(x)}{a+b \sinh (x)} \, dx &=-\frac {\coth (x) \text {csch}^2(x)}{3 a}+\frac {i \int \frac {\text {csch}^3(x) \left (3 i b+2 i a \sinh (x)+2 i b \sinh ^2(x)\right )}{a+b \sinh (x)} \, dx}{3 a}\\ &=\frac {b \coth (x) \text {csch}(x)}{2 a^2}-\frac {\coth (x) \text {csch}^2(x)}{3 a}-\frac {\int \frac {\text {csch}^2(x) \left (2 \left (2 a^2-3 b^2\right )+a b \sinh (x)-3 b^2 \sinh ^2(x)\right )}{a+b \sinh (x)} \, dx}{6 a^2}\\ &=\frac {\left (2 a^2-3 b^2\right ) \coth (x)}{3 a^3}+\frac {b \coth (x) \text {csch}(x)}{2 a^2}-\frac {\coth (x) \text {csch}^2(x)}{3 a}-\frac {i \int \frac {\text {csch}(x) \left (3 i b \left (a^2-2 b^2\right )+3 i a b^2 \sinh (x)\right )}{a+b \sinh (x)} \, dx}{6 a^3}\\ &=\frac {\left (2 a^2-3 b^2\right ) \coth (x)}{3 a^3}+\frac {b \coth (x) \text {csch}(x)}{2 a^2}-\frac {\coth (x) \text {csch}^2(x)}{3 a}+\frac {b^4 \int \frac {1}{a+b \sinh (x)} \, dx}{a^4}+\frac {\left (b \left (a^2-2 b^2\right )\right ) \int \text {csch}(x) \, dx}{2 a^4}\\ &=-\frac {b \left (a^2-2 b^2\right ) \tanh ^{-1}(\cosh (x))}{2 a^4}+\frac {\left (2 a^2-3 b^2\right ) \coth (x)}{3 a^3}+\frac {b \coth (x) \text {csch}(x)}{2 a^2}-\frac {\coth (x) \text {csch}^2(x)}{3 a}+\frac {\left (2 b^4\right ) \text {Subst}\left (\int \frac {1}{a+2 b x-a x^2} \, dx,x,\tanh \left (\frac {x}{2}\right )\right )}{a^4}\\ &=-\frac {b \left (a^2-2 b^2\right ) \tanh ^{-1}(\cosh (x))}{2 a^4}+\frac {\left (2 a^2-3 b^2\right ) \coth (x)}{3 a^3}+\frac {b \coth (x) \text {csch}(x)}{2 a^2}-\frac {\coth (x) \text {csch}^2(x)}{3 a}-\frac {\left (4 b^4\right ) \text {Subst}\left (\int \frac {1}{4 \left (a^2+b^2\right )-x^2} \, dx,x,2 b-2 a \tanh \left (\frac {x}{2}\right )\right )}{a^4}\\ &=-\frac {b \left (a^2-2 b^2\right ) \tanh ^{-1}(\cosh (x))}{2 a^4}-\frac {2 b^4 \tanh ^{-1}\left (\frac {b-a \tanh \left (\frac {x}{2}\right )}{\sqrt {a^2+b^2}}\right )}{a^4 \sqrt {a^2+b^2}}+\frac {\left (2 a^2-3 b^2\right ) \coth (x)}{3 a^3}+\frac {b \coth (x) \text {csch}(x)}{2 a^2}-\frac {\coth (x) \text {csch}^2(x)}{3 a}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.66, size = 186, normalized size = 1.71 \begin {gather*} \frac {\frac {48 b^4 \text {ArcTan}\left (\frac {b-a \tanh \left (\frac {x}{2}\right )}{\sqrt {-a^2-b^2}}\right )}{\sqrt {-a^2-b^2}}+4 a \left (2 a^2-3 b^2\right ) \coth \left (\frac {x}{2}\right )+3 a^2 b \text {csch}^2\left (\frac {x}{2}\right )+12 a^2 b \log \left (\tanh \left (\frac {x}{2}\right )\right )-24 b^3 \log \left (\tanh \left (\frac {x}{2}\right )\right )+3 a^2 b \text {sech}^2\left (\frac {x}{2}\right )+8 a^3 \text {csch}^3(x) \sinh ^4\left (\frac {x}{2}\right )-\frac {1}{2} a^3 \text {csch}^4\left (\frac {x}{2}\right ) \sinh (x)+8 a^3 \tanh \left (\frac {x}{2}\right )-12 a b^2 \tanh \left (\frac {x}{2}\right )}{24 a^4} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.62, size = 151, normalized size = 1.39
method | result | size |
default | \(-\frac {\frac {\left (\tanh ^{3}\left (\frac {x}{2}\right )\right ) a^{2}}{3}+a b \left (\tanh ^{2}\left (\frac {x}{2}\right )\right )-3 a^{2} \tanh \left (\frac {x}{2}\right )+4 b^{2} \tanh \left (\frac {x}{2}\right )}{8 a^{3}}+\frac {2 b^{4} \arctanh \left (\frac {2 a \tanh \left (\frac {x}{2}\right )-2 b}{2 \sqrt {a^{2}+b^{2}}}\right )}{a^{4} \sqrt {a^{2}+b^{2}}}-\frac {1}{24 a \tanh \left (\frac {x}{2}\right )^{3}}-\frac {-3 a^{2}+4 b^{2}}{8 a^{3} \tanh \left (\frac {x}{2}\right )}+\frac {b}{8 a^{2} \tanh \left (\frac {x}{2}\right )^{2}}+\frac {b \left (a^{2}-2 b^{2}\right ) \ln \left (\tanh \left (\frac {x}{2}\right )\right )}{2 a^{4}}\) | \(151\) |
risch | \(-\frac {-3 a b \,{\mathrm e}^{5 x}+6 b^{2} {\mathrm e}^{4 x}+12 a^{2} {\mathrm e}^{2 x}-12 b^{2} {\mathrm e}^{2 x}+3 b \,{\mathrm e}^{x} a -4 a^{2}+6 b^{2}}{3 a^{3} \left ({\mathrm e}^{2 x}-1\right )^{3}}-\frac {b \ln \left ({\mathrm e}^{x}+1\right )}{2 a^{2}}+\frac {b^{3} \ln \left ({\mathrm e}^{x}+1\right )}{a^{4}}+\frac {b^{4} \ln \left ({\mathrm e}^{x}+\frac {a \sqrt {a^{2}+b^{2}}-a^{2}-b^{2}}{\sqrt {a^{2}+b^{2}}\, b}\right )}{\sqrt {a^{2}+b^{2}}\, a^{4}}-\frac {b^{4} \ln \left ({\mathrm e}^{x}+\frac {a \sqrt {a^{2}+b^{2}}+a^{2}+b^{2}}{\sqrt {a^{2}+b^{2}}\, b}\right )}{\sqrt {a^{2}+b^{2}}\, a^{4}}+\frac {b \ln \left ({\mathrm e}^{x}-1\right )}{2 a^{2}}-\frac {b^{3} \ln \left ({\mathrm e}^{x}-1\right )}{a^{4}}\) | \(221\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.50, size = 194, normalized size = 1.78 \begin {gather*} \frac {b^{4} \log \left (\frac {b e^{\left (-x\right )} - a - \sqrt {a^{2} + b^{2}}}{b e^{\left (-x\right )} - a + \sqrt {a^{2} + b^{2}}}\right )}{\sqrt {a^{2} + b^{2}} a^{4}} - \frac {3 \, a b e^{\left (-x\right )} - 6 \, b^{2} e^{\left (-4 \, x\right )} - 3 \, a b e^{\left (-5 \, x\right )} + 4 \, a^{2} - 6 \, b^{2} - 12 \, {\left (a^{2} - b^{2}\right )} e^{\left (-2 \, x\right )}}{3 \, {\left (3 \, a^{3} e^{\left (-2 \, x\right )} - 3 \, a^{3} e^{\left (-4 \, x\right )} + a^{3} e^{\left (-6 \, x\right )} - a^{3}\right )}} - \frac {{\left (a^{2} b - 2 \, b^{3}\right )} \log \left (e^{\left (-x\right )} + 1\right )}{2 \, a^{4}} + \frac {{\left (a^{2} b - 2 \, b^{3}\right )} \log \left (e^{\left (-x\right )} - 1\right )}{2 \, a^{4}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 1676 vs.
\(2 (97) = 194\).
time = 0.56, size = 1676, normalized size = 15.38 \begin {gather*} \text {Too large to display} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {\operatorname {csch}^{4}{\left (x \right )}}{a + b \sinh {\left (x \right )}}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.44, size = 171, normalized size = 1.57 \begin {gather*} \frac {b^{4} \log \left (\frac {{\left | 2 \, b e^{x} + 2 \, a - 2 \, \sqrt {a^{2} + b^{2}} \right |}}{{\left | 2 \, b e^{x} + 2 \, a + 2 \, \sqrt {a^{2} + b^{2}} \right |}}\right )}{\sqrt {a^{2} + b^{2}} a^{4}} - \frac {{\left (a^{2} b - 2 \, b^{3}\right )} \log \left (e^{x} + 1\right )}{2 \, a^{4}} + \frac {{\left (a^{2} b - 2 \, b^{3}\right )} \log \left ({\left | e^{x} - 1 \right |}\right )}{2 \, a^{4}} + \frac {3 \, a b e^{\left (5 \, x\right )} - 6 \, b^{2} e^{\left (4 \, x\right )} - 12 \, a^{2} e^{\left (2 \, x\right )} + 12 \, b^{2} e^{\left (2 \, x\right )} - 3 \, a b e^{x} + 4 \, a^{2} - 6 \, b^{2}}{3 \, a^{3} {\left (e^{\left (2 \, x\right )} - 1\right )}^{3}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.88, size = 694, normalized size = 6.37 \begin {gather*} \frac {8}{3\,\left (a-3\,a\,{\mathrm {e}}^{2\,x}+3\,a\,{\mathrm {e}}^{4\,x}-a\,{\mathrm {e}}^{6\,x}\right )}-\frac {4}{a-2\,a\,{\mathrm {e}}^{2\,x}+a\,{\mathrm {e}}^{4\,x}}-\frac {2\,b^2}{a^3\,{\mathrm {e}}^{2\,x}-a^3}+\frac {b\,\ln \left (4\,a^4+24\,b^4-20\,a^2\,b^2-4\,a^4\,{\mathrm {e}}^x-24\,b^4\,{\mathrm {e}}^x+20\,a^2\,b^2\,{\mathrm {e}}^x\right )}{2\,a^2}-\frac {b\,\ln \left (4\,a^4+24\,b^4-20\,a^2\,b^2+4\,a^4\,{\mathrm {e}}^x+24\,b^4\,{\mathrm {e}}^x-20\,a^2\,b^2\,{\mathrm {e}}^x\right )}{2\,a^2}-\frac {b^3\,\ln \left (4\,a^4+24\,b^4-20\,a^2\,b^2-4\,a^4\,{\mathrm {e}}^x-24\,b^4\,{\mathrm {e}}^x+20\,a^2\,b^2\,{\mathrm {e}}^x\right )}{a^4}+\frac {b^3\,\ln \left (4\,a^4+24\,b^4-20\,a^2\,b^2+4\,a^4\,{\mathrm {e}}^x+24\,b^4\,{\mathrm {e}}^x-20\,a^2\,b^2\,{\mathrm {e}}^x\right )}{a^4}+\frac {2\,b\,{\mathrm {e}}^x}{a^2\,{\mathrm {e}}^{4\,x}-2\,a^2\,{\mathrm {e}}^{2\,x}+a^2}+\frac {b\,{\mathrm {e}}^x}{a^2\,{\mathrm {e}}^{2\,x}-a^2}+\frac {b^4\,\ln \left (16\,a^5\,b^2-48\,a\,b^6-32\,a^3\,b^4-24\,b^6\,\sqrt {a^2+b^2}+24\,b^7\,{\mathrm {e}}^x-40\,a^2\,b^4\,\sqrt {a^2+b^2}+16\,a^4\,b^2\,\sqrt {a^2+b^2}-32\,a^6\,b\,{\mathrm {e}}^x+112\,a^2\,b^5\,{\mathrm {e}}^x+56\,a^4\,b^3\,{\mathrm {e}}^x+72\,a\,b^5\,{\mathrm {e}}^x\,\sqrt {a^2+b^2}-32\,a^5\,b\,{\mathrm {e}}^x\,\sqrt {a^2+b^2}+72\,a^3\,b^3\,{\mathrm {e}}^x\,\sqrt {a^2+b^2}\right )\,\sqrt {a^2+b^2}}{a^6+a^4\,b^2}-\frac {b^4\,\ln \left (24\,b^6\,\sqrt {a^2+b^2}-48\,a\,b^6-32\,a^3\,b^4+16\,a^5\,b^2+24\,b^7\,{\mathrm {e}}^x+40\,a^2\,b^4\,\sqrt {a^2+b^2}-16\,a^4\,b^2\,\sqrt {a^2+b^2}-32\,a^6\,b\,{\mathrm {e}}^x+112\,a^2\,b^5\,{\mathrm {e}}^x+56\,a^4\,b^3\,{\mathrm {e}}^x-72\,a\,b^5\,{\mathrm {e}}^x\,\sqrt {a^2+b^2}+32\,a^5\,b\,{\mathrm {e}}^x\,\sqrt {a^2+b^2}-72\,a^3\,b^3\,{\mathrm {e}}^x\,\sqrt {a^2+b^2}\right )\,\sqrt {a^2+b^2}}{a^6+a^4\,b^2} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________