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

I've been trying to solve one simple Integral with Euler substitution several times, but can't find where I'm going wrong. The integral is (+ the answer given here, too):

$$\int\frac{1}{x\sqrt{x^2+x+1}} dx=\log(x)-\log(2\sqrt{x^2+x+1}+x+2)+\text{ constant}$$

The problem is, I cannot get this result. Below is my solution of the problem. I've checked it many times, must be something very obvious that I'm missing:

(original image)

Euler Substituion


Let $\sqrt{x^2+x+1}=t-x$.


$x(1+2t)=t^2-1\implies x=\dfrac{t^2-1}{1+2t}$



$\implies\displaystyle\int\frac{dx}{x\sqrt{x^2+x+1}}=2\int\frac{\frac{t^2+t+1}{(1+2t)^2}\;dt}{\frac{t^2-1}{1+2t}\cdot\frac{t^2+t+1}{1+2t}}=2\int \frac{1}{t^2-1}\,dt$

$\dfrac{1}{t^2-1}=\dfrac{1}{(t+1)(t-1)}=\dfrac{A}{t+1}+\dfrac{B}{t-1}\implies \begin{eqnarray}&&At-A+Bt+B=1\\&&A+B=0\implies A=-B\\ &&B-A=1\implies B=\frac{1}{2},A=-\frac{1}{2}\end{eqnarray}$

$\implies \displaystyle 2\int \frac{1}{2}\frac{1}{2t-1}\,dt-2\int\frac{1}{2}\frac{1}{t+1}\,dt=\int\frac{1}{t-1}\,dt-\int\frac{1}{t+1}\,dt=$


$t-x=\sqrt{x^2+x+1}\implies t=\sqrt{x^2+x+1}+x$

$\implies \ln\left|\dfrac{t-1}{t+1}\right|=\ln\left|\dfrac{\sqrt{x^2+x+1}+x-1}{\sqrt{x^2+x+1}+x+1}\right|$

I'll appreciate any help.

Thanks in advance!

share|cite|improve this question
I've typed your scanned document in LaTeX to ensure readability, but I may have inadvertently introduced changes from the original. If so, I apologize, and feel free to change any errors I made (or anything else for that matter). – Zev Chonoles Jun 24 '12 at 18:43
See here and here for how to format your mathematics expressions with LaTeX, and see here for how to use Markdown formatting. If you need to format more advanced math, there are many excellent LaTeX references on the internet, including Stack Exchange's own TeX.SE site. If you see a piece of LaTeX you want to know the code for on the site, you can right click on it, go to "Show Math As", then choose "TeX Commands". – Zev Chonoles Jun 24 '12 at 18:44
Hi Zev, thanks for the tip. I'll definitely use LaTeX next time. – cypressx Jun 24 '12 at 19:40
up vote 3 down vote accepted

What you have done is correct. All you need to do is to rewrite it a different form. $$\begin{align} \ln \left( \sqrt{x^2+x+1} + x - 1\right) & = \ln \left( \dfrac{\left(\sqrt{x^2+x+1} + x - 1 \right) \left(\sqrt{x^2+x+1} - x + 1 \right)}{\left(\sqrt{x^2+x+1} - x + 1 \right)}\right)\\ & = \ln \left(\left(x^2 + x + 1 - (x^2 - 2x + 1) \right) \right) - \ln \left(\sqrt{x^2+x+1} - x + 1 \right)\\ &= \ln(x) - \ln \left(\sqrt{x^2+x+1} - x + 1 \right) \end{align} $$ Hence, $$\begin{align} \ln \left( \dfrac{\sqrt{x^2+x+1} + x - 1}{\sqrt{x^2+x+1} + x + 1}\right) & = \ln \left( \sqrt{x^2+x+1} + x - 1\right) - \ln \left(\sqrt{x^2+x+1} + x + 1 \right)\\ & = \ln(x) - \ln \left(\sqrt{x^2+x+1} - x + 1 \right) -\ln \left(\sqrt{x^2+x+1} + x + 1 \right)\\ & = \ln(x) - \left(\ln \left(\sqrt{x^2+x+1} - x + 1 \right) +\ln \left(\sqrt{x^2+x+1} + x + 1 \right) \right)\\ & = \ln(x) - \ln \left( \left(\sqrt{x^2+x+1}+1 \right)^2 - x^2\right)\\ & = \ln(x) - \ln \left( x^2 + x + 1 + 1 +2 \sqrt{x^2+x+1} - x^2\right)\\ & = \ln(x) - \ln \left( 2 \sqrt{x^2+x+1} + x + 2\right) \end{align}$$

share|cite|improve this answer
Thanks! I'm wondering, when I have to rewrite the answers - i.e. how do you know the rewriting is enough and the answer is in it's best form. – cypressx Jun 24 '12 at 19:46
@cypressx There is no best form. Your answer is equally "best" as wolframalpha. – user17762 Jun 24 '12 at 19:51

Looks about right. In your expression, multiply top and bottom of the thing inside the log by $\sqrt{x^2+x+1}-(x-1)$.

share|cite|improve this answer

You may use substitution x=1/t, or Euler substitution \sqrt{x^2+x+1}=tx-1

share|cite|improve this answer

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.