Integrate $\int \frac{dx}{\sqrt{x^2-9}}$ by trig substitution $$
\begin{align}
x = 3\sec\theta, dx &= 3\sec\theta\tan\theta d\theta\\\\
\int \frac{dx}{\sqrt{x^2-9}} &= \int \frac{3\sec\theta\tan\theta d\theta}{\sqrt{(3\sec\theta)^2 - 3^2}} \\\\
& = \int \frac{3\sec\theta\tan\theta d\theta}{\sqrt{3^2(\sec^2\theta -1)}} \\\\
&= \int \frac{3\sec\theta\tan\theta d\theta}{\sqrt{3^2\tan^2\theta}} = \int \sec\theta\\\\
&= \ln|\sec\theta + \tan\theta| + C = \ln| \frac{x}{3} + \frac{\sqrt{x^2-9}}{3}|
\end{align}
$$
However, wolphram alpha says the answer is $\ln |x+ \sqrt{x^2-9}$
I am wondering how did it get rid of the 3 in the denominator? This is pretty much how I got my answer:
$$
x = 3\sec\theta \\
\frac{x}{3} = \sec\theta \\
\frac{\sqrt{x^2-9}}{3} = \tan\theta
$$

The indefinite integral of $f$, i.e. $\int f$ is not a function, but a set of functions:
$$\int f := \{g| g'=f \}$$
But we usually denote the set with one of it's element $+C$:
$$\int f = g + C \tag{1}$$
Or simply without the $+C$. Clearly, the $=$ sign in $(1)$ is not the same you'd write in $1=1$, for example. A really precise mathematician would use a different symbol, for example:
$$\int f \color{blue}{=} g$$
with $\color{blue}{=}$ means that $a\color{blue}{=}b$ iff $a'=b'$. So they would write:
$$\int x \mathrm{d}x \color{blue}{=} \frac{x^2}{2} \color{blue}{=} \frac{x^2}{2}+3$$
But we are lazy, and usually the meaning of $=$ is clear from the context.
