Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How to evaluate $$\int \frac{dx}{x \sqrt{(x+a) ^2- b^2}}$$ I tried trigonometric substitution $x + a = b \sec \theta$ and I encountered $$\int \frac{\tan \theta}{ (b - a \cos \theta) \sqrt{\tan^2 \theta}}d\theta$$ how to handle this term $\displaystyle \frac{\tan \theta}{|\tan \theta|}$?

share|cite|improve this question
@MichaelHardy yes sorry – hasExams Jun 5 '13 at 15:43
The expression you should get might depend on whehter $b<a$ or $b>a$. – Michael Hardy Jun 5 '13 at 17:17
up vote 6 down vote accepted

I substituted $x=1/y$ and got

$$-\int \frac{dy}{\sqrt{1+2 a y+(a^2-b^2) y^2}}$$

I then completed the square in the square root to get

$$-\frac{1}{\sqrt{a^2-b^2}} \int \frac{dy}{\displaystyle\sqrt{\left(y+\frac{a}{a^2-b^2}\right)^2-\left(\frac{a}{a^2-b^2}\right)^2}}$$

Now let

$$y=\frac{a}{a^2-b^2} (\cosh{u}-1)$$

Then the integral becomes

$$-\frac{1}{\sqrt{a^2-b^2}} \int du \frac{\sinh{u}}{\sinh{u}} = -\frac{1}{\sqrt{a^2-b^2}} u+C$$

where $C$ is a constant of integration. Back substituting, we get

$$\int \frac{dx}{x \sqrt{(x+a)^2-b^2}} = -\frac{1}{\sqrt{a^2-b^2}}\text{arccosh}{\left(\frac{a^2-b^2}{a x}+1 \right)} + C $$

Use $\text{arccosh}{z} = \log{(z+\sqrt{z^2-1})}$ to express the result in terms of logs.

share|cite|improve this answer

First, examine separately intervals where $\tan\theta>0$ and where $\tan\theta<0$. After that, see if you can express the answer in a way that's less-than-explicitly piecewise (perhaps by using absolute values).

share|cite|improve this answer
let it be $I$ if $\theta>0$, then if $\theta<0$, then my answer is $-I$, but Mathematica gives me something negative of $\log(-x)$ for my original integration $\frac{1}{x \sqrt{(x+a)^2 - b^2}}$ – hasExams Jun 5 '13 at 15:53
mathematica evaluates it to $$ \frac{\log (-x)-\log \left(\sqrt{a^2-b^2} \sqrt{(a+x)^2-b^2}+a (a+x)-b^2\right)}{\sqrt{a^2-b^2}}$$ I can't get this $\log(-x)$ part – hasExams Jun 5 '13 at 16:16
Before checking details, by initial reaction is that $\log|x|$ occurs as the antiderivative of $1/x$, and that's the same as $\log x$ if $x>0$ and it's the same as $\log(-x)$ if $x<0$. – Michael Hardy Jun 5 '13 at 17:12

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.