3.54 \(\int x \cos ^{-1}(\frac{a}{x}) \, dx\)

Optimal. Leaf size=34 \[ \frac{1}{2} x^2 \sec ^{-1}\left (\frac{x}{a}\right )-\frac{1}{2} a x \sqrt{1-\frac{a^2}{x^2}} \]

[Out]

-(a*Sqrt[1 - a^2/x^2]*x)/2 + (x^2*ArcSec[x/a])/2

________________________________________________________________________________________

Rubi [A]  time = 0.0165922, antiderivative size = 34, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 3, integrand size = 8, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.375, Rules used = {4833, 5220, 191} \[ \frac{1}{2} x^2 \sec ^{-1}\left (\frac{x}{a}\right )-\frac{1}{2} a x \sqrt{1-\frac{a^2}{x^2}} \]

Antiderivative was successfully verified.

[In]

Int[x*ArcCos[a/x],x]

[Out]

-(a*Sqrt[1 - a^2/x^2]*x)/2 + (x^2*ArcSec[x/a])/2

Rule 4833

Int[ArcCos[(c_.)/((a_.) + (b_.)*(x_)^(n_.))]^(m_.)*(u_.), x_Symbol] :> Int[u*ArcSec[a/c + (b*x^n)/c]^m, x] /;
FreeQ[{a, b, c, n, m}, x]

Rule 5220

Int[((a_.) + ArcSec[(c_.)*(x_)]*(b_.))*((d_.)*(x_))^(m_.), x_Symbol] :> Simp[((d*x)^(m + 1)*(a + b*ArcSec[c*x]
))/(d*(m + 1)), x] - Dist[(b*d)/(c*(m + 1)), Int[(d*x)^(m - 1)/Sqrt[1 - 1/(c^2*x^2)], x], x] /; FreeQ[{a, b, c
, d, m}, x] && NeQ[m, -1]

Rule 191

Int[((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Simp[(x*(a + b*x^n)^(p + 1))/a, x] /; FreeQ[{a, b, n, p}, x] &
& EqQ[1/n + p + 1, 0]

Rubi steps

\begin{align*} \int x \cos ^{-1}\left (\frac{a}{x}\right ) \, dx &=\int x \sec ^{-1}\left (\frac{x}{a}\right ) \, dx\\ &=\frac{1}{2} x^2 \sec ^{-1}\left (\frac{x}{a}\right )-\frac{1}{2} a \int \frac{1}{\sqrt{1-\frac{a^2}{x^2}}} \, dx\\ &=-\frac{1}{2} a \sqrt{1-\frac{a^2}{x^2}} x+\frac{1}{2} x^2 \sec ^{-1}\left (\frac{x}{a}\right )\\ \end{align*}

Mathematica [A]  time = 0.021294, size = 33, normalized size = 0.97 \[ \frac{1}{2} \left (x^2 \cos ^{-1}\left (\frac{a}{x}\right )-a x \sqrt{1-\frac{a^2}{x^2}}\right ) \]

Antiderivative was successfully verified.

[In]

Integrate[x*ArcCos[a/x],x]

[Out]

(-(a*Sqrt[1 - a^2/x^2]*x) + x^2*ArcCos[a/x])/2

________________________________________________________________________________________

Maple [A]  time = 0.004, size = 39, normalized size = 1.2 \begin{align*} -{a}^{2} \left ( -{\frac{{x}^{2}}{2\,{a}^{2}}\arccos \left ({\frac{a}{x}} \right ) }+{\frac{x}{2\,a}\sqrt{1-{\frac{{a}^{2}}{{x}^{2}}}}} \right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x*arccos(a/x),x)

[Out]

-a^2*(-1/2/a^2*x^2*arccos(a/x)+1/2*(1-a^2/x^2)^(1/2)/a*x)

________________________________________________________________________________________

Maxima [A]  time = 1.44162, size = 38, normalized size = 1.12 \begin{align*} \frac{1}{2} \, x^{2} \arccos \left (\frac{a}{x}\right ) - \frac{1}{2} \, a x \sqrt{-\frac{a^{2}}{x^{2}} + 1} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*arccos(a/x),x, algorithm="maxima")

[Out]

1/2*x^2*arccos(a/x) - 1/2*a*x*sqrt(-a^2/x^2 + 1)

________________________________________________________________________________________

Fricas [A]  time = 2.56326, size = 73, normalized size = 2.15 \begin{align*} \frac{1}{2} \, x^{2} \arccos \left (\frac{a}{x}\right ) - \frac{1}{2} \, a x \sqrt{-\frac{a^{2} - x^{2}}{x^{2}}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*arccos(a/x),x, algorithm="fricas")

[Out]

1/2*x^2*arccos(a/x) - 1/2*a*x*sqrt(-(a^2 - x^2)/x^2)

________________________________________________________________________________________

Sympy [A]  time = 2.68407, size = 49, normalized size = 1.44 \begin{align*} - \frac{a \left (\begin{cases} a \sqrt{-1 + \frac{x^{2}}{a^{2}}} & \text{for}\: \frac{\left |{x^{2}}\right |}{\left |{a^{2}}\right |} > 1 \\i a \sqrt{1 - \frac{x^{2}}{a^{2}}} & \text{otherwise} \end{cases}\right )}{2} + \frac{x^{2} \operatorname{acos}{\left (\frac{a}{x} \right )}}{2} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*acos(a/x),x)

[Out]

-a*Piecewise((a*sqrt(-1 + x**2/a**2), Abs(x**2)/Abs(a**2) > 1), (I*a*sqrt(1 - x**2/a**2), True))/2 + x**2*acos
(a/x)/2

________________________________________________________________________________________

Giac [A]  time = 1.24789, size = 58, normalized size = 1.71 \begin{align*} \frac{1}{2} \, x^{2} \arccos \left (\frac{a}{x}\right ) + \frac{1}{2} \,{\left (\sqrt{-a^{2}} \mathrm{sgn}\left (x\right ) - \frac{\sqrt{-a^{2} + x^{2}}}{\mathrm{sgn}\left (x\right )}\right )} a \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*arccos(a/x),x, algorithm="giac")

[Out]

1/2*x^2*arccos(a/x) + 1/2*(sqrt(-a^2)*sgn(x) - sqrt(-a^2 + x^2)/sgn(x))*a