Does $\int_0^{2\pi} \sqrt{(1-a\cos x)^2 + b} \mathrm{d}x$ evaluate in terms of elliptic integrals? Consider the integral
$$\int_0^{2\pi} \mathrm{d}x \sqrt{(1-a\cos x)^2 + b}$$
with $a,b>0$. I believe I can somehow evaluate this integral by incomplete elliptic integrals. This would be obvious, for example, if $a=1$. But, in the general case, this integral appears rather challenging. Mathematica, and SymPy have not been useful. And the Weierstrass substitution returns polynomials of 4th degree.

If you make the $z=tan(x/2)$ substitution, Mathematica quickly evaluates the indefinite integral, with this horrible expression:
$$\frac{1}{2} z \sqrt{\frac{\left(a
   \left(z^2-1\right)+z^2+1\right)^2}{\left(z^2+1\right)^2}+b}-\frac{i \left(z^2+1\right)
   \sqrt{1-\frac{z^2 \left(a-i \sqrt{b}+1\right)}{a+i \sqrt{b}-1}} \sqrt{1-\frac{z^2
   \left(a+i \sqrt{b}+1\right)}{a-i \sqrt{b}-1}} \sqrt{\frac{\left(a
   \left(z^2-1\right)+z^2+1\right)^2}{\left(z^2+1\right)^2}+b} \left(2 \left(-i a
   \sqrt{b}+a+b+1\right) F\left(i \sinh ^{-1}\left(\sqrt{\frac{a+i \sqrt{b}+1}{-a+i
   \sqrt{b}+1}} z\right)|\frac{-a^2+2 i \sqrt{b} a+b+1}{-a^2-2 i \sqrt{b}
   a+b+1}\right)+\left(a^2+2 i a \sqrt{b}-b-1\right) E\left(i \sinh
   ^{-1}\left(\sqrt{\frac{a+i \sqrt{b}+1}{-a+i \sqrt{b}+1}} z\right)|\frac{-a^2+2 i
   \sqrt{b} a+b+1}{-a^2-2 i \sqrt{b} a+b+1}\right)-4 a \Pi \left(\frac{-a+i
   \sqrt{b}+1}{a+i \sqrt{b}+1};i \sinh ^{-1}\left(\sqrt{\frac{a+i \sqrt{b}+1}{-a+i
   \sqrt{b}+1}} z\right)|\frac{-a^2+2 i \sqrt{b} a+b+1}{-a^2-2 i \sqrt{b}
   a+b+1}\right)\right)}{2 \sqrt{\frac{a+i \sqrt{b}+1}{-a+i \sqrt{b}+1}} \left(a^2
   \left(z^2-1\right)^2+2 a \left(z^4-1\right)+(b+1) \left(z^2+1\right)^2\right)}$$
