<s>[INST] Integrating $\frac 1 {\sqrt{x^2 - a^2}}$ I'm trying to understand how to integrate:
$$\frac 1 {\sqrt{x^2 - a^2}}$$
I tried substituting $t$ as $\sqrt{x^2 - a^2}$, but I can't get an answer that way, and I don't know any other way to integrate other than by parts, which I don't think can be used here. How should I integrate this?
 [/INST] $$\begin{align}
\text{Integrating} &\int \frac {1\cdot dx}{\sqrt {(x^2-a^2)}}\\\\
\text{Put x} &= a \cdot \cosh (\theta)\\
\Rightarrow \theta &= \cosh^{-1} \left(\frac {x}{a} \right)\\
\text{Therefore}\\ dx &= a \cdot \sinh(\theta) \cdot d\theta\\\\
\text{Now}\\
&\int \frac {a \cdot \sinh (\theta) \cdot d \theta}{\sqrt {a^2\cdot(\cosh^2(\theta)-1)}}\\\\
&\Rightarrow \frac {a \cdot \sinh (\theta) \cdot d \theta}{\sqrt {a^2\cdot \sinh ^2(\theta)}}\\
&\Rightarrow \int \frac{a \cdot \sinh (\theta) \cdot  d\theta}{a \cdot \sinh (\theta)}\\
&\Rightarrow \int 1 \cdot d\theta\\
&\Rightarrow \theta + c\\
&\Rightarrow \cosh^{-1} \left(\frac {x}{a} \right) +c
\end{align}$$
</s>