Find this follow integral $$F(t)=\int_{0}^{\pi}\dfrac{2t+2\cos{x}}{t^2+2t\cos{x}+1}dx$$ where $t\in R$
my try: $$F(t)=\int_{0}^{\frac{\pi}{2}}\dfrac{2t+2\cos{x}}{t^2+2t\cos{x}+1}dx+\int_{\frac{\pi}{2}}^{\pi}\dfrac{2t+2\cos{x}}{t^2+2t\cos{x}+1}dx=I_{1}+I_{2}$$ where $$I_{2}=\int_{0}^{\frac{\pi}{2}}\dfrac{2t-2\cos{x}}{t^2-2t\cos{x}+1}dx$$ then \begin{align*}I_{1}+I_{2}&=2\int_{0}^{\frac{\pi}{2}}\dfrac{(t+\cos{x})(t^2-2t\cos{x}+1)+(t-\cos{x})(t^2+2t\cos{x}+1)}{(t^2+1)^2-(2t\cos{x})^2}dx\\ &=4t\int_{0}^{\frac{\pi}{2}}\dfrac{t^2-2\cos^2{x}+1}{-4t^2\cos^2{x}+(t^2+1)^2}dt \end{align*} then I fell very ugly, have other methods? Thank you