# Evaluate the following integral:

Question:

Evaluate the following integral:

$\int \frac{x^{2}}{(x-1) \sqrt{x+2}} d x$

Solution:

re-writing the given equation as

$\int \frac{\left(x^{2}-1\right)+1}{(x-1) \sqrt{x+2}} d x$

$\int \frac{\left(x^{2}-1\right)}{(x-1) \sqrt{x+2}} d x+\int \frac{1}{(x-1) \sqrt{x+2}} d x$

$\int \frac{(x+1)}{\sqrt{x+2}} d x+\int \frac{1}{(x-1) \sqrt{x+2}} d x$

$\int \frac{(1)}{\sqrt{x+2}} d x+\int \sqrt{x+2} d x+\int \frac{1}{(x-1) \sqrt{x+2}} d x$

For the first- and second-part using identity $\int x^{n} d x=\frac{x^{n+1}}{n+1}$

$\frac{2}{3}(x+2)^{\frac{3}{2}}+2 \sqrt{x+2}$

For the second part

assume $x+2=t^{2}$

$d x=2 t d t$

$\int \frac{4 d t}{\left(t^{2}-3\right)}$

Using identity $\int \frac{\mathrm{dz}}{(\mathrm{z})^{2}-1}=\frac{1}{2} \log \left|\frac{\mathrm{z}-1}{\mathrm{z}+1}\right|+\mathrm{c}$

$\frac{2}{\sqrt{3}} \log \left|\frac{t-\sqrt{3}}{t+\sqrt{3}}\right|+c$

$\frac{2}{\sqrt{3}} \log \left|\frac{\sqrt{(x+2)}-\sqrt{3}}{\sqrt{x+2}+\sqrt{3}}\right|+c$

Hence integral is

$\frac{2}{3}(x+2)^{\frac{3}{2}}+2 \sqrt{x+2}+\frac{2}{\sqrt{3}} \log \left|\frac{\sqrt{(x+2)}-\sqrt{3}}{\sqrt{x+2}+\sqrt{3}}\right|+c$