Evaluate $\int \frac{1}{(2x+1)\sqrt {x^2+7}}\,\text{d}x$. How to do this indefinite integral (anti-derivative)?
$$I=\displaystyle\int \dfrac{1}{(2x+1)\sqrt {x^2+7}}\,\text{d}x.$$
I tried doing some substitutions ($x^2+7=t^2$, $2x+1=t$, etc.) but it didn't work out.
 A: Using Euler substitution by setting $t-x=\sqrt{x^2+7}$, we will obtain 
$x=\dfrac{t^2-7}{2t}$ and $dx=\dfrac{t^2+7}{2t^2}\ dt$, then the integral turns out to be
\begin{align}
\int \dfrac{1}{(2x+1)\sqrt {x^2+7}}\ dx&=\int\frac{1}{t^2+t-7}\ dt\\
&=\int\frac{1}{\left(t+\dfrac{\sqrt{29}+1}{2}\right)\left(t-\dfrac{\sqrt{29}-1}{2}\right)}\ dt\\
&=-\int\left[\frac{2}{\sqrt{29}(2t+\sqrt{29}+1)}+\frac{2}{\sqrt{29}(-2t+\sqrt{29}-1)}\right]\ dt.
\end{align}
The rest can be solved by using substitution $u=2t+\sqrt{29}+1$ and $v=-2t+\sqrt{29}-1$.
A: Use Trigonometric substitution,
$$x=\sqrt7\tan\theta$$
Then  $\displaystyle a\sin y+b\cos y=\sqrt{a^2+b^2}\sin\left(y+\arctan \frac ba\right)$ and this
or use  Weierstrass substitution 
A: Let $x=\sqrt{7}\tan{u}\implies dx=\sqrt{7}\sec^2{u}du$
\begin{align}
I
=\int \frac{1}{(2x+1)\sqrt{x^2+7}}dx=\int \frac{\sec{u}}{(1+2\sqrt{7}\tan{u})}du\\
\end{align}
Let $t=\tan{\frac{u}{2}}\implies du=\frac{2}{1+t^2}dt$
\begin{align}
I
=\int\frac{\frac{1+t^2}{1-t^2}}{1+2\sqrt{7}\frac{2t}{1-t^2}}\frac{2}{1+t^2}dt=-2\int \frac{1}{t^2-4\sqrt{7}t-1}dt
\end{align}
Decompose the integrand into partial fractions and integrate.
\begin{align}
I=-2A\ln{(t-2\sqrt{7}-\sqrt{29})}-2B\ln{(t-2\sqrt{7}+\sqrt{29})}+c
\end{align}
where
\begin{align}
A={\rm Res}(f,2\sqrt{7}+\sqrt{29})=\frac{1}{2\sqrt{29}}, B={\rm Res}(f,2\sqrt{7}-\sqrt{29})=-\frac{1}{2\sqrt{29}}
\end{align}
Now express everything in terms of x.
