I am trying to calculate a definite integral of:
$$\int_{-\varphi_\beta}^{2\pi-\varphi_\beta}\sqrt{2-b\cos x}\,dx,\quad 0\leq b\leq 1.$$
To be more precise I am trying to find a double definite integral of: $$\int_0^{2\pi}\int_0^{2\pi}\sqrt{2-2\sqrt{p_\alpha(1-p_\alpha)}\cos (\varphi_\alpha-\varphi_\beta)}\,d\varphi_\alpha\,d\varphi_\beta,\quad 0\leq p\leq 1.$$
But I guess one needs to begin with the first form anyway :(
Thank you all for your helpful comments.
And I apologize everyone for the mistake that I made in my original question. Since my ultimate goal is to calculate the double definite integral above, the limits of the first integral are not from $ 0 $ to $ 2\pi $ but from $ -\varphi_\beta $ to $ 2\pi-\varphi_\beta $. So the first integral in question has a form $ \int_{-\varphi_\beta}^{2\pi-\varphi_\beta}\sqrt{2-b\cos x}\,dx,\quad 0\leq b\leq 1. $ I may not take an advantage of the symmetry then.
Wolfram Dev Platform yields, from the command
Integrate[Sqrt[2-b Cos[x]],{x,0,2 Pi}], the result $$\operatorname{ConditionalExpression}\left[2\left(\sqrt{2-b}\,\operatorname{EllipticE}\left[\frac{2b}{b-2}\right]+\sqrt{2+b}\,\operatorname{EllipticE}\left[\frac{2b}{2+b}\right]\right),-2<\operatorname{Re}[b]<2\right]. $$ TheEllipticEfunction is defined by $$\operatorname{EllipticE}[x]=\int_0^{\pi/2}\sqrt{1-x \sin^2(\theta)}\,d\theta.$$ While this doesn't help you much, it does show that you're not likely to get a closed-form expression in terms of elementary antiderivatives.Also, as an aside: MATLAB is terrific for numerics, but don't expect its symbolic toolbox ever to match Mathematica/Wolfram Language.