Optimal. Leaf size=62 \[ -\frac {\sqrt {1-a^2 x^2}}{x}-\frac {4 a \sqrt {1-a^2 x^2}}{1+a x}+3 a \tanh ^{-1}\left (\sqrt {1-a^2 x^2}\right ) \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.48, antiderivative size = 62, normalized size of antiderivative = 1.00, number of steps
used = 8, number of rules used = 7, integrand size = 12, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.583, Rules used = {6259, 6874,
270, 272, 65, 214, 665} \begin {gather*} -\frac {4 a \sqrt {1-a^2 x^2}}{a x+1}-\frac {\sqrt {1-a^2 x^2}}{x}+3 a \tanh ^{-1}\left (\sqrt {1-a^2 x^2}\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 65
Rule 214
Rule 270
Rule 272
Rule 665
Rule 6259
Rule 6874
Rubi steps
\begin {align*} \int \frac {e^{-3 \tanh ^{-1}(a x)}}{x^2} \, dx &=\int \frac {(1-a x)^2}{x^2 (1+a x) \sqrt {1-a^2 x^2}} \, dx\\ &=\int \left (\frac {1}{x^2 \sqrt {1-a^2 x^2}}-\frac {3 a}{x \sqrt {1-a^2 x^2}}+\frac {4 a^2}{(1+a x) \sqrt {1-a^2 x^2}}\right ) \, dx\\ &=-\left ((3 a) \int \frac {1}{x \sqrt {1-a^2 x^2}} \, dx\right )+\left (4 a^2\right ) \int \frac {1}{(1+a x) \sqrt {1-a^2 x^2}} \, dx+\int \frac {1}{x^2 \sqrt {1-a^2 x^2}} \, dx\\ &=-\frac {\sqrt {1-a^2 x^2}}{x}-\frac {4 a \sqrt {1-a^2 x^2}}{1+a x}-\frac {1}{2} (3 a) \text {Subst}\left (\int \frac {1}{x \sqrt {1-a^2 x}} \, dx,x,x^2\right )\\ &=-\frac {\sqrt {1-a^2 x^2}}{x}-\frac {4 a \sqrt {1-a^2 x^2}}{1+a x}+\frac {3 \text {Subst}\left (\int \frac {1}{\frac {1}{a^2}-\frac {x^2}{a^2}} \, dx,x,\sqrt {1-a^2 x^2}\right )}{a}\\ &=-\frac {\sqrt {1-a^2 x^2}}{x}-\frac {4 a \sqrt {1-a^2 x^2}}{1+a x}+3 a \tanh ^{-1}\left (\sqrt {1-a^2 x^2}\right )\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.04, size = 57, normalized size = 0.92 \begin {gather*} \sqrt {1-a^2 x^2} \left (-\frac {1}{x}-\frac {4 a}{1+a x}\right )-3 a \log (x)+3 a \log \left (1+\sqrt {1-a^2 x^2}\right ) \end {gather*}
Warning: Unable to verify antiderivative.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(463\) vs.
\(2(56)=112\).
time = 0.79, size = 464, normalized size = 7.48
method | result | size |
risch | \(\frac {a^{2} x^{2}-1}{x \sqrt {-a^{2} x^{2}+1}}-a \left (-3 \arctanh \left (\frac {1}{\sqrt {-a^{2} x^{2}+1}}\right )+\frac {4 \sqrt {-a^{2} \left (x +\frac {1}{a}\right )^{2}+2 a \left (x +\frac {1}{a}\right )}}{a \left (x +\frac {1}{a}\right )}\right )\) | \(81\) |
default | \(9 a \left (\frac {\left (-a^{2} \left (x +\frac {1}{a}\right )^{2}+2 a \left (x +\frac {1}{a}\right )\right )^{\frac {3}{2}}}{3}+a \left (-\frac {\left (-2 a^{2} \left (x +\frac {1}{a}\right )+2 a \right ) \sqrt {-a^{2} \left (x +\frac {1}{a}\right )^{2}+2 a \left (x +\frac {1}{a}\right )}}{4 a^{2}}+\frac {\arctan \left (\frac {\sqrt {a^{2}}\, x}{\sqrt {-a^{2} \left (x +\frac {1}{a}\right )^{2}+2 a \left (x +\frac {1}{a}\right )}}\right )}{2 \sqrt {a^{2}}}\right )\right )+\frac {-\frac {\left (-a^{2} \left (x +\frac {1}{a}\right )^{2}+2 a \left (x +\frac {1}{a}\right )\right )^{\frac {5}{2}}}{a \left (x +\frac {1}{a}\right )^{3}}-2 a \left (\frac {\left (-a^{2} \left (x +\frac {1}{a}\right )^{2}+2 a \left (x +\frac {1}{a}\right )\right )^{\frac {5}{2}}}{a \left (x +\frac {1}{a}\right )^{2}}+3 a \left (\frac {\left (-a^{2} \left (x +\frac {1}{a}\right )^{2}+2 a \left (x +\frac {1}{a}\right )\right )^{\frac {3}{2}}}{3}+a \left (-\frac {\left (-2 a^{2} \left (x +\frac {1}{a}\right )+2 a \right ) \sqrt {-a^{2} \left (x +\frac {1}{a}\right )^{2}+2 a \left (x +\frac {1}{a}\right )}}{4 a^{2}}+\frac {\arctan \left (\frac {\sqrt {a^{2}}\, x}{\sqrt {-a^{2} \left (x +\frac {1}{a}\right )^{2}+2 a \left (x +\frac {1}{a}\right )}}\right )}{2 \sqrt {a^{2}}}\right )\right )\right )}{a}+\frac {2 \left (-a^{2} \left (x +\frac {1}{a}\right )^{2}+2 a \left (x +\frac {1}{a}\right )\right )^{\frac {5}{2}}}{a \left (x +\frac {1}{a}\right )^{2}}-\frac {\left (-a^{2} x^{2}+1\right )^{\frac {5}{2}}}{x}-4 a^{2} \left (\frac {\left (-a^{2} x^{2}+1\right )^{\frac {3}{2}} x}{4}+\frac {3 x \sqrt {-a^{2} x^{2}+1}}{8}+\frac {3 \arctan \left (\frac {\sqrt {a^{2}}\, x}{\sqrt {-a^{2} x^{2}+1}}\right )}{8 \sqrt {a^{2}}}\right )-3 a \left (\frac {\left (-a^{2} x^{2}+1\right )^{\frac {3}{2}}}{3}+\sqrt {-a^{2} x^{2}+1}-\arctanh \left (\frac {1}{\sqrt {-a^{2} x^{2}+1}}\right )\right )\) | \(464\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.34, size = 75, normalized size = 1.21 \begin {gather*} -\frac {4 \, a^{2} x^{2} + 4 \, a x + 3 \, {\left (a^{2} x^{2} + a x\right )} \log \left (\frac {\sqrt {-a^{2} x^{2} + 1} - 1}{x}\right ) + \sqrt {-a^{2} x^{2} + 1} {\left (5 \, a x + 1\right )}}{a x^{2} + x} \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 {\left (- \left (a x - 1\right ) \left (a x + 1\right )\right )^{\frac {3}{2}}}{x^{2} \left (a x + 1\right )^{3}}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 150 vs.
\(2 (56) = 112\).
time = 0.41, size = 150, normalized size = 2.42 \begin {gather*} \frac {3 \, a^{2} \log \left (\frac {{\left | -2 \, \sqrt {-a^{2} x^{2} + 1} {\left | a \right |} - 2 \, a \right |}}{2 \, a^{2} {\left | x \right |}}\right )}{{\left | a \right |}} + \frac {{\left (a^{2} + \frac {17 \, {\left (\sqrt {-a^{2} x^{2} + 1} {\left | a \right |} + a\right )}}{x}\right )} a^{2} x}{2 \, {\left (\sqrt {-a^{2} x^{2} + 1} {\left | a \right |} + a\right )} {\left (\frac {\sqrt {-a^{2} x^{2} + 1} {\left | a \right |} + a}{a^{2} x} + 1\right )} {\left | a \right |}} - \frac {\sqrt {-a^{2} x^{2} + 1} {\left | a \right |} + a}{2 \, x {\left | a \right |}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.80, size = 81, normalized size = 1.31 \begin {gather*} 3\,a\,\mathrm {atanh}\left (\sqrt {1-a^2\,x^2}\right )-\frac {\sqrt {1-a^2\,x^2}}{x}+\frac {4\,a^2\,\sqrt {1-a^2\,x^2}}{\left (x\,\sqrt {-a^2}+\frac {\sqrt {-a^2}}{a}\right )\,\sqrt {-a^2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________