Optimal. Leaf size=92 \[ -\frac {(1-i a x)^{3/4} \sqrt [4]{1+i a x}}{x}-i a \text {ArcTan}\left (\frac {\sqrt [4]{1+i a x}}{\sqrt [4]{1-i a x}}\right )-i a \tanh ^{-1}\left (\frac {\sqrt [4]{1+i a x}}{\sqrt [4]{1-i a x}}\right ) \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.02, antiderivative size = 92, normalized size of antiderivative = 1.00, number of steps
used = 6, number of rules used = 6, integrand size = 16, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.375, Rules used = {5170, 96, 95,
218, 212, 209} \begin {gather*} -i a \text {ArcTan}\left (\frac {\sqrt [4]{1+i a x}}{\sqrt [4]{1-i a x}}\right )-\frac {(1-i a x)^{3/4} \sqrt [4]{1+i a x}}{x}-i a \tanh ^{-1}\left (\frac {\sqrt [4]{1+i a x}}{\sqrt [4]{1-i a x}}\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 95
Rule 96
Rule 209
Rule 212
Rule 218
Rule 5170
Rubi steps
\begin {align*} \int \frac {e^{\frac {1}{2} i \tan ^{-1}(a x)}}{x^2} \, dx &=\int \frac {\sqrt [4]{1+i a x}}{x^2 \sqrt [4]{1-i a x}} \, dx\\ &=-\frac {(1-i a x)^{3/4} \sqrt [4]{1+i a x}}{x}+\frac {1}{2} (i a) \int \frac {1}{x \sqrt [4]{1-i a x} (1+i a x)^{3/4}} \, dx\\ &=-\frac {(1-i a x)^{3/4} \sqrt [4]{1+i a x}}{x}+(2 i a) \text {Subst}\left (\int \frac {1}{-1+x^4} \, dx,x,\frac {\sqrt [4]{1+i a x}}{\sqrt [4]{1-i a x}}\right )\\ &=-\frac {(1-i a x)^{3/4} \sqrt [4]{1+i a x}}{x}-(i a) \text {Subst}\left (\int \frac {1}{1-x^2} \, dx,x,\frac {\sqrt [4]{1+i a x}}{\sqrt [4]{1-i a x}}\right )-(i a) \text {Subst}\left (\int \frac {1}{1+x^2} \, dx,x,\frac {\sqrt [4]{1+i a x}}{\sqrt [4]{1-i a x}}\right )\\ &=-\frac {(1-i a x)^{3/4} \sqrt [4]{1+i a x}}{x}-i a \tan ^{-1}\left (\frac {\sqrt [4]{1+i a x}}{\sqrt [4]{1-i a x}}\right )-i a \tanh ^{-1}\left (\frac {\sqrt [4]{1+i a x}}{\sqrt [4]{1-i a x}}\right )\\ \end {align*}
________________________________________________________________________________________
Mathematica [C] Result contains higher order function than in optimal. Order 5 vs. order 3 in
optimal.
time = 0.01, size = 71, normalized size = 0.77 \begin {gather*} -\frac {i (1-i a x)^{3/4} \left (-3 i+3 a x+2 a x \, _2F_1\left (\frac {3}{4},1;\frac {7}{4};\frac {i+a x}{i-a x}\right )\right )}{3 x (1+i a x)^{3/4}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [F]
time = 0.01, size = 0, normalized size = 0.00 \[\int \frac {\sqrt {\frac {i a x +1}{\sqrt {a^{2} x^{2}+1}}}}{x^{2}}\, dx\]
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 [B] Both result and optimal contain complex but leaf count of result is larger than twice
the leaf count of optimal. 151 vs. \(2 (64) = 128\).
time = 3.08, size = 151, normalized size = 1.64 \begin {gather*} \frac {-i \, a x \log \left (\sqrt {\frac {i \, \sqrt {a^{2} x^{2} + 1}}{a x + i}} + 1\right ) + a x \log \left (\sqrt {\frac {i \, \sqrt {a^{2} x^{2} + 1}}{a x + i}} + i\right ) - a x \log \left (\sqrt {\frac {i \, \sqrt {a^{2} x^{2} + 1}}{a x + i}} - i\right ) + i \, a x \log \left (\sqrt {\frac {i \, \sqrt {a^{2} x^{2} + 1}}{a x + i}} - 1\right ) - 2 \, {\left (-i \, a x + 1\right )} \sqrt {\frac {i \, \sqrt {a^{2} x^{2} + 1}}{a x + i}}}{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 {\sqrt {\frac {i \left (a x - i\right )}{\sqrt {a^{2} x^{2} + 1}}}}{x^{2}}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: TypeError} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {\sqrt {\frac {1+a\,x\,1{}\mathrm {i}}{\sqrt {a^2\,x^2+1}}}}{x^2} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________