Integral with inverse trigonometric function How do I integrate $$\int \cot^{-1}\sqrt{x^2+x+1}\ dx$$
I don't understand how to proceed?
I did try the question using integration by parts, but it didn’t help.

A solution without using hyperbolic functions
Integration by parts gives 
$$x\cot^{-1}\left( \sqrt{x^2+x+1} \right)+\frac{1}{2}\int \frac{x(2x+1)}{\sqrt{x^2+x+1}(x^2+x+2)}\,dx$$
i can split the integrated on the right as
$$
\begin{align}
  & =2\int{\frac{1}{\sqrt{{{x}^{2}}+x+1}}dx}-\int{\frac{1+2x}{2\sqrt{{{x}^{2}}+x+1}\left( {{x}^{2}}+x+2 \right)}dx}-\frac{7}{2}\int{\frac{1}{\sqrt{1+x+{{x}^{2}}}\left( {{x}^{2}}+x+2 \right)}dx} \\ 
 & =2A-B-\frac{7}{2}C \\ 
\end{align}
$$
to calculate $A$  notice that ${{x}^{2}}+x+1={{\left( x+\frac{1}{2} \right)}^{2}}+{{\left( \frac{\sqrt{3}}{2} \right)}^{2}}$ and using $x+\frac{1}{2}=\frac{\sqrt{3}}{2}u$
$$A=\int{\frac{1}{\sqrt{{{u}^{2}}+1}}du}=\ln \left( u+\sqrt{{{u}^{2}}+1} \right)=\ln \left( \frac{2x+1}{\sqrt{3}}+\sqrt{{{\left( \frac{2x+1}{\sqrt{3}} \right)}^{2}}+1} \right)$$
that’s because i accept the fact that  ${{\left( \ln \left( u+\sqrt{{{u}^{2}}+1} \right) \right)}^{\prime }}=\frac{1}{\sqrt{{{u}^{2}}+1}}$
for $B$ we have
$$\frac{1+2x}{2\sqrt{1+x+{{x}^{2}}}\left( 2+x+{{x}^{2}} \right)}=\frac{{{\left( \sqrt{1+x+{{x}^{2}}} \right)}^{\prime }}}{\left( 1+{{\left( \sqrt{1+x+{{x}^{2}}} \right)}^{2}} \right)}\Rightarrow B={{\tan }^{-1}}\left( \sqrt{1+x+{{x}^{2}}} \right)$$
for $C$ use $u=\frac{2x+1}{\sqrt{{{x}^{2}}+x+1}}$ hence $du=\frac{3}{2{{\left( \sqrt{{{x}^{2}}+x+1} \right)}^{3}}}dx$ also 
$${{u}^{2}}-7=\frac{4{{x}^{2}}+4x+1}{{{x}^{2}}+x+1}-\frac{7{{x}^{2}}+7x+7}{{{x}^{2}}+x+1}=\frac{-3{{x}^{2}}-3x-6}{{{x}^{2}}+x+1}=-3\left( \frac{{{x}^{2}}+x+2}{{{x}^{2}}+x+1} \right)$$
$$\begin{align}
  & C=\frac{2}{3}\int{\frac{1}{\sqrt{{{x}^{2}}+x+1}\left( {{x}^{2}}+x+2 \right)}{{\left( \sqrt{{{x}^{2}}+x+1} \right)}^{3}}du} \\ 
 & \quad =\frac{2}{3}\int{\frac{{{x}^{2}}+x+1}{{{x}^{2}}+x+2}du} \\ 
 & \quad =-2\int{\frac{1}{{{u}^{2}}-7}du}=\frac{1}{\sqrt{7}}\ln \left( \frac{\sqrt{7}+u}{\sqrt{7}-u} \right)=\frac{1}{\sqrt{7}}\ln \left( \frac{\sqrt{7}+\frac{2x+1}{\sqrt{{{x}^{2}}+x+1}}}{\sqrt{7}-\frac{2x+1}{\sqrt{{{x}^{2}}+x+1}}} \right) \\ 
\end{align}$$
finally,
$$
\int \cot^{-1}\left( \sqrt{x^2+x+1} \right) \, dx=x\cot^{-1}\left( \sqrt{{{x}^{2}}+x+1} \right)+\ln \left( \frac{2x+1}{\sqrt{3}}+\sqrt{{{\left( \frac{2x+1}{\sqrt{3}} \right)}^{2}}+1} \right)-\frac{1}{2}{{\tan }^{-1}}\left( \sqrt{1+x+{{x}^{2}}} \right)-\frac{\sqrt{7}}{4}\ln \left( \frac{\sqrt{7}+\frac{2x+1}{\sqrt{{{x}^{2}}+x+1}}}{\sqrt{7}-\frac{2x+1}{\sqrt{{{x}^{2}}+x+1}}} \right)
$$
