3.1.36 \(\int e^{-i \text {ArcTan}(a x)} x^2 \, dx\) [36]

Optimal. Leaf size=75 \[ \frac {i \sqrt {1+a^2 x^2}}{a^3}+\frac {x \sqrt {1+a^2 x^2}}{2 a^2}-\frac {i \left (1+a^2 x^2\right )^{3/2}}{3 a^3}-\frac {\sinh ^{-1}(a x)}{2 a^3} \]

[Out]

-1/3*I*(a^2*x^2+1)^(3/2)/a^3-1/2*arcsinh(a*x)/a^3+I*(a^2*x^2+1)^(1/2)/a^3+1/2*x*(a^2*x^2+1)^(1/2)/a^2

________________________________________________________________________________________

Rubi [A]
time = 0.03, antiderivative size = 75, normalized size of antiderivative = 1.00, number of steps used = 7, number of rules used = 5, integrand size = 14, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.357, Rules used = {5168, 811, 655, 201, 221} \begin {gather*} -\frac {\sinh ^{-1}(a x)}{2 a^3}+\frac {x \sqrt {a^2 x^2+1}}{2 a^2}-\frac {i \left (a^2 x^2+1\right )^{3/2}}{3 a^3}+\frac {i \sqrt {a^2 x^2+1}}{a^3} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[x^2/E^(I*ArcTan[a*x]),x]

[Out]

(I*Sqrt[1 + a^2*x^2])/a^3 + (x*Sqrt[1 + a^2*x^2])/(2*a^2) - ((I/3)*(1 + a^2*x^2)^(3/2))/a^3 - ArcSinh[a*x]/(2*
a^3)

Rule 201

Int[((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Simp[x*((a + b*x^n)^p/(n*p + 1)), x] + Dist[a*n*(p/(n*p + 1)),
 Int[(a + b*x^n)^(p - 1), x], x] /; FreeQ[{a, b}, x] && IGtQ[n, 0] && GtQ[p, 0] && (IntegerQ[2*p] || (EqQ[n, 2
] && IntegerQ[4*p]) || (EqQ[n, 2] && IntegerQ[3*p]) || LtQ[Denominator[p + 1/n], Denominator[p]])

Rule 221

Int[1/Sqrt[(a_) + (b_.)*(x_)^2], x_Symbol] :> Simp[ArcSinh[Rt[b, 2]*(x/Sqrt[a])]/Rt[b, 2], x] /; FreeQ[{a, b},
 x] && GtQ[a, 0] && PosQ[b]

Rule 655

Int[((d_) + (e_.)*(x_))*((a_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Simp[e*((a + c*x^2)^(p + 1)/(2*c*(p + 1))),
x] + Dist[d, Int[(a + c*x^2)^p, x], x] /; FreeQ[{a, c, d, e, p}, x] && NeQ[p, -1]

Rule 811

Int[(x_)^2*((f_) + (g_.)*(x_))*((a_) + (c_.)*(x_)^2)^(p_), x_Symbol] :> Dist[1/c, Int[(f + g*x)*(a + c*x^2)^(p
 + 1), x], x] - Dist[a/c, Int[(f + g*x)*(a + c*x^2)^p, x], x] /; FreeQ[{a, c, f, g, p}, x] && EqQ[a*g^2 + f^2*
c, 0]

Rule 5168

Int[E^(ArcTan[(a_.)*(x_)]*(n_))*(x_)^(m_.), x_Symbol] :> Int[x^m*((1 - I*a*x)^((I*n + 1)/2)/((1 + I*a*x)^((I*n
 - 1)/2)*Sqrt[1 + a^2*x^2])), x] /; FreeQ[{a, m}, x] && IntegerQ[(I*n - 1)/2]

Rubi steps

\begin {align*} \int e^{-i \tan ^{-1}(a x)} x^2 \, dx &=\int \frac {x^2 (1-i a x)}{\sqrt {1+a^2 x^2}} \, dx\\ &=-\frac {\int \frac {1-i a x}{\sqrt {1+a^2 x^2}} \, dx}{a^2}+\frac {\int (1-i a x) \sqrt {1+a^2 x^2} \, dx}{a^2}\\ &=\frac {i \sqrt {1+a^2 x^2}}{a^3}-\frac {i \left (1+a^2 x^2\right )^{3/2}}{3 a^3}-\frac {\int \frac {1}{\sqrt {1+a^2 x^2}} \, dx}{a^2}+\frac {\int \sqrt {1+a^2 x^2} \, dx}{a^2}\\ &=\frac {i \sqrt {1+a^2 x^2}}{a^3}+\frac {x \sqrt {1+a^2 x^2}}{2 a^2}-\frac {i \left (1+a^2 x^2\right )^{3/2}}{3 a^3}-\frac {\sinh ^{-1}(a x)}{a^3}+\frac {\int \frac {1}{\sqrt {1+a^2 x^2}} \, dx}{2 a^2}\\ &=\frac {i \sqrt {1+a^2 x^2}}{a^3}+\frac {x \sqrt {1+a^2 x^2}}{2 a^2}-\frac {i \left (1+a^2 x^2\right )^{3/2}}{3 a^3}-\frac {\sinh ^{-1}(a x)}{2 a^3}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.02, size = 46, normalized size = 0.61 \begin {gather*} \frac {\left (4 i+3 a x-2 i a^2 x^2\right ) \sqrt {1+a^2 x^2}-3 \sinh ^{-1}(a x)}{6 a^3} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[x^2/E^(I*ArcTan[a*x]),x]

[Out]

((4*I + 3*a*x - (2*I)*a^2*x^2)*Sqrt[1 + a^2*x^2] - 3*ArcSinh[a*x])/(6*a^3)

________________________________________________________________________________________

Maple [B] Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 166 vs. \(2 (61 ) = 122\).
time = 0.08, size = 167, normalized size = 2.23

method result size
risch \(-\frac {i \left (2 a^{2} x^{2}+3 i a x -4\right ) \sqrt {a^{2} x^{2}+1}}{6 a^{3}}-\frac {\ln \left (\frac {a^{2} x}{\sqrt {a^{2}}}+\sqrt {a^{2} x^{2}+1}\right )}{2 a^{2} \sqrt {a^{2}}}\) \(67\)
default \(-\frac {i \left (a^{2} x^{2}+1\right )^{\frac {3}{2}}}{3 a^{3}}+\frac {\frac {x \sqrt {a^{2} x^{2}+1}}{2}+\frac {\ln \left (\frac {a^{2} x}{\sqrt {a^{2}}}+\sqrt {a^{2} x^{2}+1}\right )}{2 \sqrt {a^{2}}}}{a^{2}}+\frac {i \left (\sqrt {\left (x -\frac {i}{a}\right )^{2} a^{2}+2 i a \left (x -\frac {i}{a}\right )}+\frac {i a \ln \left (\frac {i a +\left (x -\frac {i}{a}\right ) a^{2}}{\sqrt {a^{2}}}+\sqrt {\left (x -\frac {i}{a}\right )^{2} a^{2}+2 i a \left (x -\frac {i}{a}\right )}\right )}{\sqrt {a^{2}}}\right )}{a^{3}}\) \(167\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x^2/(1+I*a*x)*(a^2*x^2+1)^(1/2),x,method=_RETURNVERBOSE)

[Out]

-1/3*I*(a^2*x^2+1)^(3/2)/a^3+1/a^2*(1/2*x*(a^2*x^2+1)^(1/2)+1/2*ln(a^2*x/(a^2)^(1/2)+(a^2*x^2+1)^(1/2))/(a^2)^
(1/2))+I/a^3*(((x-I/a)^2*a^2+2*I*a*(x-I/a))^(1/2)+I*a*ln((I*a+(x-I/a)*a^2)/(a^2)^(1/2)+((x-I/a)^2*a^2+2*I*a*(x
-I/a))^(1/2))/(a^2)^(1/2))

________________________________________________________________________________________

Maxima [A]
time = 0.48, size = 59, normalized size = 0.79 \begin {gather*} \frac {\sqrt {a^{2} x^{2} + 1} x}{2 \, a^{2}} - \frac {i \, {\left (a^{2} x^{2} + 1\right )}^{\frac {3}{2}}}{3 \, a^{3}} - \frac {\operatorname {arsinh}\left (a x\right )}{2 \, a^{3}} + \frac {i \, \sqrt {a^{2} x^{2} + 1}}{a^{3}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^2/(1+I*a*x)*(a^2*x^2+1)^(1/2),x, algorithm="maxima")

[Out]

1/2*sqrt(a^2*x^2 + 1)*x/a^2 - 1/3*I*(a^2*x^2 + 1)^(3/2)/a^3 - 1/2*arcsinh(a*x)/a^3 + I*sqrt(a^2*x^2 + 1)/a^3

________________________________________________________________________________________

Fricas [A]
time = 2.05, size = 51, normalized size = 0.68 \begin {gather*} \frac {\sqrt {a^{2} x^{2} + 1} {\left (-2 i \, a^{2} x^{2} + 3 \, a x + 4 i\right )} + 3 \, \log \left (-a x + \sqrt {a^{2} x^{2} + 1}\right )}{6 \, a^{3}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^2/(1+I*a*x)*(a^2*x^2+1)^(1/2),x, algorithm="fricas")

[Out]

1/6*(sqrt(a^2*x^2 + 1)*(-2*I*a^2*x^2 + 3*a*x + 4*I) + 3*log(-a*x + sqrt(a^2*x^2 + 1)))/a^3

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} - i \int \frac {x^{2} \sqrt {a^{2} x^{2} + 1}}{a x - i}\, dx \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x**2/(1+I*a*x)*(a**2*x**2+1)**(1/2),x)

[Out]

-I*Integral(x**2*sqrt(a**2*x**2 + 1)/(a*x - I), x)

________________________________________________________________________________________

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]

integrate(x^2/(1+I*a*x)*(a^2*x^2+1)^(1/2),x, algorithm="giac")

[Out]

Exception raised: TypeError >> An error occurred running a Giac command:INPUT:sage2:=int(sage0,sageVARx):;OUTP
UT:sym2poly/r2sym(const gen & e,const index_m & i,const vecteur & l) Error: Bad Argument Value

________________________________________________________________________________________

Mupad [B]
time = 0.42, size = 71, normalized size = 0.95 \begin {gather*} \frac {\sqrt {a^2\,x^2+1}\,\left (\frac {x\,\sqrt {a^2}}{2\,a^2}+\frac {a\,2{}\mathrm {i}}{3\,{\left (a^2\right )}^{3/2}}-\frac {a^3\,x^2\,1{}\mathrm {i}}{3\,{\left (a^2\right )}^{3/2}}\right )}{\sqrt {a^2}}-\frac {\mathrm {asinh}\left (x\,\sqrt {a^2}\right )}{2\,a^2\,\sqrt {a^2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((x^2*(a^2*x^2 + 1)^(1/2))/(a*x*1i + 1),x)

[Out]

((a^2*x^2 + 1)^(1/2)*((a*2i)/(3*(a^2)^(3/2)) - (a^3*x^2*1i)/(3*(a^2)^(3/2)) + (x*(a^2)^(1/2))/(2*a^2)))/(a^2)^
(1/2) - asinh(x*(a^2)^(1/2))/(2*a^2*(a^2)^(1/2))

________________________________________________________________________________________