1. ## tricky integral

I'm having trouble with this integral:

$\displaystyle \int{\frac{x}{\sqrt{x^2 + x + 1}}}$

I don't see an obvious way to use u-substitution, integration by parts, or trig substitution.

Could someone show me the first few steps?

2. Originally Posted by centenial
I'm having trouble with this integral:

$\displaystyle \int{\frac{x}{\sqrt{x^2 + x + 1}}}$

I don't see an obvious way to use u-substitution, integration by parts, or trig substitution.

Could someone show me the first few steps?
Wolfram shows that it's rather nasty ...

integrate x&#47;sqrt&#40;x&#94;2&#43;x&#43;1&#41; - Wolfram|Alpha

click on "show steps"

3. It's the third time I solve this integral in the forum, where is it coming from?

Start by rewriting the integral as:

$\displaystyle \displaystyle I = \int\frac{x}{\sqrt{x^2+x+1}}\;{dx} = \int\frac{\frac{1}{2}(2x+1)+x-\frac{1}{2}(2x+1)}{\sqrt{x^2+x+1}}\;{dx}$

$\displaystyle \displaystyle \Rightarrow I = \int\frac{\frac{1}{2}(2x+1)}{\sqrt{x^2+x+1}}\;{dx} +\frac{1}{2}\int\frac{2x-(2x+1)}{\sqrt{x^2+x+1}}\;{dx}$

$\displaystyle \displaystyle \Rightarrow I = \underbrace{\int\frac{\frac{1}{2}(2x+1)}{\sqrt{x^2 +x+1}}\;{dx}}_{I_{1}}-\underbrace{\frac{1}{2}\int\frac{1}{\sqrt{x^2+x+1} }\;{dx}}_{I_{2}}$

We can see that $\displaystyle I_{1}$ is of the form $\displaystyle \int\frac{\frac{1}{2}f'(x)}{\sqrt{f(x)}}\;{dx} = \sqrt{f(x)}+C$
(or we can just let $\displaystyle u = \sqrt{x^2+x+1}$). Thus $\displaystyle I_{1} = \sqrt{x^2+x+1}+k_{1}$

For $\displaystyle I_{2}$ complete the square $\displaystyle x^2+x+1 = \left(x+\frac{1}{2}\right)^2+\frac{3}{4}.$
Then let $\displaystyle x+\frac{1}{2} = \frac{\sqrt{3}}{2}\sinh{\varphi}$, then $\displaystyle dx = \frac{\sqrt{3}}{2}\cosh{\varphi} \;{d\varphi}$.

$\displaystyle \displaystyle \therefore ~ I_{2} = \frac{1}{2}\int\frac{1}{\sqrt{x^2+x+1}}\;{dx} = \frac{1}{2}\int\frac{1}{\sqrt{\left(x+\frac{1}{2}\ right)^2+\frac{3}{4}}}\;{dx}$

$\displaystyle \displaystyle \Rightarrow ~ I_{2} = \frac{1}{2}\int\frac{\frac{\sqrt{3}}{2}\cosh{\varp hi}}{\sqrt{\left(\frac{\sqrt{3}}{2}\sinh{\varphi}\ right)^2+\frac{3}{4}}}\;{d\varphi} = \frac{1}{2}\int\frac{\frac{\sqrt{3}}{2}\cosh{\varp hi}}{\sqrt{\frac{3}{4}\sinh^2{\varphi}+\frac{3}{4} }}\;{d\varphi}$

$\displaystyle \displaystyle\Rightarrow ~ I_{2} = \frac{1}{2}\int\frac{\frac{\sqrt{3}}{2}\cosh{\varp hi}}{\sqrt{\frac{3}{4}\cosh^2{\varphi}}}\;{d\varph i} = \frac{1}{2}\int\frac{\frac{\sqrt{3}}{2}\cosh{\varp hi}}{\frac{\sqrt{3}}{2}\cosh{\varphi}}\;{d\varphi}$

$\displaystyle \displaystyle \Rightarrow ~ I_{2} = \frac{1}{2}\int\;{d\varphi} = \frac{1}{2}\varphi+k_{2} = \frac{1}{2}\sinh^{-1}\left(\frac{2x+1}{\sqrt{3}}\right)+k_{2}$

Therefore $\displaystyle \displaystyle I = I_{1}-I_{2} = \sqrt{x^2+x+1}-\frac{1}{2}\sinh^{-1}\left(\frac{2x+1}{\sqrt{3}}\right)+k$.