<s>[INST] Prove that $\int^{\pi}_0 \ln \left(\frac{b-\cos x}{a- \cos x}\right)dx=\pi \ln (\frac{b+\sqrt{b^2-1}}{a+\sqrt{a^2-1}})$ Given for $\alpha>1$
$$\int^{\pi}_0 \frac{dx}{\alpha-\cos x}=\frac{\pi}{\sqrt{\alpha^2-1}}$$
Prove that $$\int^{\pi}_0 \ln \left(\frac{b-\cos x}{a- \cos x}\right)dx=\pi \left(\frac{b+\sqrt{b^2-1}}{a+\sqrt{a^2-1}}\right)$$
if $a, b>1$
 [/INST] First, notice the integrand can be written as
$$
\begin{align}
\ln (\frac{b-\cos x}{a- \cos x}) &=\ln(b-\cos x)-\ln(a-\cos x)\\
& =\ln(y-\cos x)|^{y=b}_{y=a}\\
& =\int^b_a\frac{1}{y-\cos x}dy
\end{align}
$$
So the integration equals 
$$
\begin{align}
\int^{\pi}_0 \ln (\frac{b-\cos x}{a- \cos x})dx &=\int^{\pi}_0 [ \int^b_a\frac{1}{y-\cos x}dy]dx \\ 
&=\int^b_a [\int^{\pi}_0 \frac{1}{y-\cos x}dx ] dy\\
& =\int^b_a(\frac{\pi}{\sqrt{y^2-1}})dy
\end{align}
$$
Let $$y=\sec t$$
so 
$$dy=\sec t\tan t dt$$
So the integrantion becomes
$$
\begin{align}
\pi \int^{acrsec b}_{arcsec a}\frac{\sec t\tan t}{\tan t}dt &=\pi \int^{acrsec b}_{arcsec a}\sec t dt\\ & = \pi \ln |\sec t+\tan t|^{arcsec b}_{arcsec a}\\ & = \pi [\ln(b+\sqrt{b^2-1})-\ln(a+\sqrt{a^2-1})] \\ & =\pi \ln (\frac{b+\sqrt{b^2-1}}{a+\sqrt{a^2-1}})
\end{align} 
$$
</s>