Optimal. Leaf size=89 \[ -\frac{8 a \tanh ^{-1}\left (\frac{b-2 a \tanh (c+d x)}{\sqrt{4 a^2+b^2}}\right )}{d \left (4 a^2+b^2\right )^{3/2}}-\frac{2 b \cosh (2 c+2 d x)}{d \left (4 a^2+b^2\right ) (2 a+b \sinh (2 c+2 d x))} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.103961, antiderivative size = 89, normalized size of antiderivative = 1., number of steps used = 6, number of rules used = 6, integrand size = 18, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.333, Rules used = {2666, 2664, 12, 2660, 618, 204} \[ -\frac{8 a \tanh ^{-1}\left (\frac{b-2 a \tanh (c+d x)}{\sqrt{4 a^2+b^2}}\right )}{d \left (4 a^2+b^2\right )^{3/2}}-\frac{2 b \cosh (2 c+2 d x)}{d \left (4 a^2+b^2\right ) (2 a+b \sinh (2 c+2 d x))} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 2666
Rule 2664
Rule 12
Rule 2660
Rule 618
Rule 204
Rubi steps
\begin{align*} \int \frac{1}{(a+b \cosh (c+d x) \sinh (c+d x))^2} \, dx &=\int \frac{1}{\left (a+\frac{1}{2} b \sinh (2 c+2 d x)\right )^2} \, dx\\ &=-\frac{2 b \cosh (2 c+2 d x)}{\left (4 a^2+b^2\right ) d (2 a+b \sinh (2 c+2 d x))}+\frac{4 \int \frac{a}{a+\frac{1}{2} b \sinh (2 c+2 d x)} \, dx}{4 a^2+b^2}\\ &=-\frac{2 b \cosh (2 c+2 d x)}{\left (4 a^2+b^2\right ) d (2 a+b \sinh (2 c+2 d x))}+\frac{(4 a) \int \frac{1}{a+\frac{1}{2} b \sinh (2 c+2 d x)} \, dx}{4 a^2+b^2}\\ &=-\frac{2 b \cosh (2 c+2 d x)}{\left (4 a^2+b^2\right ) d (2 a+b \sinh (2 c+2 d x))}-\frac{(4 i a) \operatorname{Subst}\left (\int \frac{1}{a-i b x+a x^2} \, dx,x,\tan \left (\frac{1}{2} (2 i c+2 i d x)\right )\right )}{\left (4 a^2+b^2\right ) d}\\ &=-\frac{2 b \cosh (2 c+2 d x)}{\left (4 a^2+b^2\right ) d (2 a+b \sinh (2 c+2 d x))}+\frac{(8 i a) \operatorname{Subst}\left (\int \frac{1}{-4 a^2-b^2-x^2} \, dx,x,-i b+2 a \tan \left (\frac{1}{2} (2 i c+2 i d x)\right )\right )}{\left (4 a^2+b^2\right ) d}\\ &=-\frac{8 a \tanh ^{-1}\left (\frac{b-2 a \tanh (c+d x)}{\sqrt{4 a^2+b^2}}\right )}{\left (4 a^2+b^2\right )^{3/2} d}-\frac{2 b \cosh (2 c+2 d x)}{\left (4 a^2+b^2\right ) d (2 a+b \sinh (2 c+2 d x))}\\ \end{align*}
Mathematica [A] time = 0.336885, size = 90, normalized size = 1.01 \[ \frac{2 \left (-\frac{4 a \tan ^{-1}\left (\frac{b-2 a \tanh (c+d x)}{\sqrt{-4 a^2-b^2}}\right )}{\left (-4 a^2-b^2\right )^{3/2}}-\frac{b \cosh (2 (c+d x))}{\left (4 a^2+b^2\right ) (2 a+b \sinh (2 (c+d x)))}\right )}{d} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] time = 0.119, size = 469, normalized size = 5.3 \begin{align*} 2\,{\frac{{b}^{2} \left ( \tanh \left ( 1/2\,dx+c/2 \right ) \right ) ^{3}}{d \left ( \left ( \tanh \left ( 1/2\,dx+c/2 \right ) \right ) ^{4}a+2\,b \left ( \tanh \left ( 1/2\,dx+c/2 \right ) \right ) ^{3}-2\, \left ( \tanh \left ( 1/2\,dx+c/2 \right ) \right ) ^{2}a+2\,b\tanh \left ( 1/2\,dx+c/2 \right ) +a \right ) a \left ( 4\,{a}^{2}+{b}^{2} \right ) }}-8\,{\frac{ \left ( \tanh \left ( 1/2\,dx+c/2 \right ) \right ) ^{2}b}{d \left ( \left ( \tanh \left ( 1/2\,dx+c/2 \right ) \right ) ^{4}a+2\,b \left ( \tanh \left ( 1/2\,dx+c/2 \right ) \right ) ^{3}-2\, \left ( \tanh \left ( 1/2\,dx+c/2 \right ) \right ) ^{2}a+2\,b\tanh \left ( 1/2\,dx+c/2 \right ) +a \right ) \left ( 4\,{a}^{2}+{b}^{2} \right ) }}+2\,{\frac{{b}^{2}\tanh \left ( 1/2\,dx+c/2 \right ) }{d \left ( \left ( \tanh \left ( 1/2\,dx+c/2 \right ) \right ) ^{4}a+2\,b \left ( \tanh \left ( 1/2\,dx+c/2 \right ) \right ) ^{3}-2\, \left ( \tanh \left ( 1/2\,dx+c/2 \right ) \right ) ^{2}a+2\,b\tanh \left ( 1/2\,dx+c/2 \right ) +a \right ) a \left ( 4\,{a}^{2}+{b}^{2} \right ) }}+16\,{\frac{{a}^{3}\ln \left ( \left ( \tanh \left ( 1/2\,dx+c/2 \right ) \right ) ^{2}a+\sqrt{4\,{a}^{2}+{b}^{2}}\tanh \left ( 1/2\,dx+c/2 \right ) +b\tanh \left ( 1/2\,dx+c/2 \right ) +a \right ) }{d \left ( 4\,{a}^{2}+{b}^{2} \right ) ^{5/2}}}+4\,{\frac{a\ln \left ( \left ( \tanh \left ( 1/2\,dx+c/2 \right ) \right ) ^{2}a+\sqrt{4\,{a}^{2}+{b}^{2}}\tanh \left ( 1/2\,dx+c/2 \right ) +b\tanh \left ( 1/2\,dx+c/2 \right ) +a \right ){b}^{2}}{d \left ( 4\,{a}^{2}+{b}^{2} \right ) ^{5/2}}}-4\,{\frac{a\ln \left ( - \left ( \tanh \left ( 1/2\,dx+c/2 \right ) \right ) ^{2}a+\sqrt{4\,{a}^{2}+{b}^{2}}\tanh \left ( 1/2\,dx+c/2 \right ) -b\tanh \left ( 1/2\,dx+c/2 \right ) -a \right ) }{d \left ( 4\,{a}^{2}+{b}^{2} \right ) ^{3/2}}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F(-2)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: ValueError} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] time = 2.16257, size = 1895, normalized size = 21.29 \begin{align*} \text{result too large to display} \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.19051, size = 208, normalized size = 2.34 \begin{align*} -\frac{4 \, a \log \left (\frac{{\left | -2 \, b e^{\left (2 \, d x + 2 \, c\right )} - 4 \, a - 2 \, \sqrt{4 \, a^{2} + b^{2}} \right |}}{{\left | -2 \, b e^{\left (2 \, d x + 2 \, c\right )} - 4 \, a + 2 \, \sqrt{4 \, a^{2} + b^{2}} \right |}}\right )}{{\left (4 \, a^{2} d + b^{2} d\right )} \sqrt{4 \, a^{2} + b^{2}}} + \frac{4 \,{\left (2 \, a e^{\left (2 \, d x + 2 \, c\right )} - b\right )}}{{\left (4 \, a^{2} d + b^{2} d\right )}{\left (b e^{\left (4 \, d x + 4 \, c\right )} + 4 \, a e^{\left (2 \, d x + 2 \, c\right )} - b\right )}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]