# Integrate $\int \frac{dx}{\sqrt{x^2-9}}$ by trig substitution [duplicate]

This question already has an answer here:

\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$$

## marked as duplicate by Dylan, mau, John Omielan, Eevee Trainer, eyeballfrogMar 14 at 2:59

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

## 3 Answers

Note that $$\ln\left| \frac{x}{3} + \frac{\sqrt{x^2-9}}{3}\right| = \ln\left|x+\sqrt{x^2-9}\right|-\ln 3$$

and $$\ln3$$ is a constant. Since $$C$$ is an arbitrary constant, you can define a new constant $$C_1 = C - \ln3$$ and the answer is

$$\ln\left|x+\sqrt{x^2-9}\right| + C_1$$

• So my answer wouldn't be incorrect, it just wouldn't be fully simplified? – Evan Kim Mar 13 at 13:14
• @EvanKim Yes, that is true. – Haris Gušić Mar 13 at 13:35

Another approach:

$$I=\int\frac{dx}{\sqrt{x^2-9}}=\frac{1}{3}\int\frac{dx}{\sqrt{\left(\frac{x}{3}\right)^2-1}}$$

Let $$u=\frac{x}{3}\implies3du=dx\implies$$ $$I=\int\frac{du}{\sqrt{u^2-1}}=\text{arccosh}(u)+C=\text{arccosh}\left(\frac{x}{3}\right)+C$$

But recall the identity for $$x\in[1,\infty)$$ $$\text{arccosh}(x)=\ln\left(x+\sqrt{x^2-1}\right)$$

So $$\text{arccosh}\left(\frac{x}{3}\right)+C=\ln\left(\frac{x}{3}+\sqrt{\frac{x^2}{9}-1}\right)$$

Let $$C=-\ln(3)$$ and we have the Wolfram approach.

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.