# Integral that yields ArcTan function rather than ArcSin

When I enter the following Integral problem to Mathematica, $$\int \frac{1}{\sqrt{a^2-x^2}}\textrm{d}x$$ The answer yielded by Mathematica is $$\arctan\left({\frac{x}{\sqrt{a^2-x^2}}}\right)$$ Rather than the more reduced result: $$\arcsin\left(\frac{x}{a}\right).$$ The two results are mathematically equivalent but I think the $$\arcsin$$ result is more typically considered the answer to the integral. At least, every table of integrals that I own plus a few on-line queries always give the $$\arcsin$$ answer.

There must be a way in Mathematica to force the $$\arcsin$$ result as preference to the $$\arctan$$ equivalent but I have not found it. I tried to use Simplify and even used Assumptions on the integral to declare that $$a$$ is real (thinking that might have been an issue).

Question: What do I do in Mathematica to force the result to be the $$\arcsin$$ version of the answer?

Statements I have used include:

Integrate[1/Sqrt[a^2-x^2],x]


and,

Integrate[1/Sqrt[a^2-x^2],x]//Simplify


and,

Integrate[1/Sqrt[a^2-x^2],x,Assumptions->Element[a,Reals]]


Updated

I attempted various other statements and in particular, dealing with the variable $$a$$ being given explicit values. For example,

Integrate[1/Sqrt[a^2-x^2],x,Assumptions->a>0]


Still results in the ArcTan form of the result. However, if I explicitly specify a positive value such as $$a=2$$ then the result is the ArcSin format as shown:

a=2; Integrate[1/Sqrt[a^2-x^2],x]


With result: $$\arcsin\left(\frac{x}{2}\right).$$ Either form has a forbidden zone for $$x>a$$. For the ArcTan, you have Complex values and for the ArcSin you have a situation where the magnitude of the Sin function is greater than 1.

• This explains why it doesn't simplify as you expect. a = 1; Plot[{Re[ArcSin[x/a]], Im[ArcSin[x/a]], Re[ArcTan[x/Sqrt[a^2-x^2]]], Im[ArcTan[x/Sqrt[a^2-x^2]]]}, {x,-2,2}] MMA by default considers complex and not just real.
– Bill
Jun 7, 2018 at 21:41
• My assumption of declaring $a$ to be real as well as I also declared both $a$ and $x$ to be real never altered the solution. Jun 7, 2018 at 21:59
• This seems to be valid only for a>0. Simplify[1/Sqrt[a^2-x^2]-D[ArcSin[x/a],x],Assumptions->a>0] gives zero. But I could not make Intergate gives the simplified result with assumptions that a>0. Maple can do it. int( 1/(sqrt(a^2-x^2)),x) assuming a>0; gives arcsin(x/a) may be someone else can figure how to make Integrate do it. !Mathematica graphics Jun 7, 2018 at 22:02
• Actually, I should have mentioned this but I also tried the Integral with the Assumptions that a > 0. Did not alter the result, still yielded the ArcTan form of the answer. Jun 8, 2018 at 3:13
• No, there is no "forbidden zone". There is a branch point at x==a. ArcSin[x/a] /. x -> 2 a // N yields 1.5708 - 1.31696 I, perfectly sensible. Jun 8, 2018 at 15:37

Try

Integrate[1/(a Sqrt[1 - (x/a)^2]), x]


It works!

## Explanations

From a mathematical point of view, $$\arcsin(\frac{x}{k})$$ and $$\arctan(\frac{x}{\sqrt{k^2-x^2}})$$ are not globally same functions. It is especially easy to see this by analyzing them near the branch point $$x=k$$. For $$k=2$$, we can expand both functions; we see that they are different:

Simplify[Series[{ArcTan[x/Sqrt[2^2 - x^2]], ArcSin[x/2]} /. x -> 2 - ϵ, {ϵ, 0, 1}], ϵ > 0]


$$\left\{\frac{\pi }{2}-\sqrt{\epsilon }+\frac{3 \pi \epsilon }{16}+O\left(\epsilon ^{3/2}\right),\frac{\pi }{2}-\sqrt{\epsilon }+O\left(\epsilon ^{3/2}\right)\right\}$$

The difference is only around the branch points though; for example, for $$k=2$$ case above, we see that we get same series expansion around, say, $$x=1$$:

Simplify[Series[{ArcTan[x/Sqrt[2^2 - x^2]], ArcSin[x/2]} /. x -> 1 - ϵ, {ϵ, 0, 1}], ϵ > 0]


$$\left\{\frac{\pi }{6}-\frac{\epsilon }{\sqrt{3}}+O\left(\epsilon ^2\right),\frac{\pi }{6}-\frac{\epsilon }{\sqrt{3}}+O\left(\epsilon ^2\right)\right\}$$

(Of course, above result only guarantees them to be same upto $$O(\epsilon^2)$$ but one can compare them at arbitrarily high orders)

The fact that these two expressions are not same is why Mathematica does not yield the result $$asin$$ for the given integration. This also explains why neither Reduce nor FullSimplify take them to be same:

{
FullSimplify[ArcTan[x/Sqrt[2^2 - x^2]] == ArcSin[x/2], -2 < x < 2],
Assuming[-2 < x < 2, Reduce[ArcTan[x/Sqrt[2^2 - x^2]] ==ArcSin[x/2]]]
}


$$\left\{\sin ^{-1}\left(\frac{x}{2}\right)=\tan ^{-1}\left(\frac{x}{\sqrt{4-x^2}}\right),\sin ^{-1}\left(\frac{x}{2}\right)=\tan ^{-1}\left(\frac{x}{\sqrt{4-x^2}}\right)\right\}$$

If we restrict ourselves away from the branch points, we can simplify the integrand before we do the actual integration. That is, for the region we are interested in, we have the equality $$\frac{1}{\sqrt{a^2-x^2}}=\frac{1}{a \sqrt{1-\frac{x^2}{a^2}}}$$ since both $$a$$ and $$1-\frac{x^2}{a^2}$$ are positive reals. If we now integrate this, we get what we want:

Integrate[1/(a Sqrt[1 - (x/a)^2]), x]


$$\sin ^{-1}\left(\frac{x}{a}\right)$$ • Which version are you using? I get ArcTan[x/(a Sqrt[1 - x^2/a^2])] on V11.3, not ArcSin[x/a]. Jun 10, 2018 at 0:37
• ArcSin[x/a] on 10.4.1 for Microsoft Windows (64-bit). Jun 10, 2018 at 2:21
• @MichaelE2 On my MMA 11.3 on Windows I get: ArcSin[x/a], :) Jun 10, 2018 at 9:00