solving integral by substitution by $y=a(1-\cos\theta)$ $$x=\int \sqrt{\frac{y}{2a-y}}dy$$
According to my textbook, it says that the substitution by $y=a(1-\cos\theta)$ will easily solve the intergral. Why does this work?
 A: Let me try to answer this.  First thing I'd do is try to rewrite the integral as
$$\int\sqrt{\frac{2a}{2a-y}-1}dy$$
From here, I'd attempt to eliminate the square root by letting
$$\frac{2a}{2a-y}=\sec^2\theta$$
$$2a=2a\sec^2\theta-y\sec^2\theta$$
$$y=\frac{2a(\sec^2\theta-1)}{\sec^2\theta}=2a\tan^2\theta\cos^2\theta=2a\sin^2\theta$$
Using a trigonometric identity, this can also be rewritten as
$$2a(\frac{1-\cos2\theta}{2})=a(1-\cos2\theta)$$
As for how to use the substitution as your book has it, though, you'll need to multiply numerator and denominator by $1-\cos\theta$.  Continuing from where DonAntonio left off
$$\int\sqrt\frac{(1-\cos\theta)^2}{1-\cos^2\theta}a\sin\theta d\theta=\int\frac{1-\cos\theta}{\sin\theta}a\sin\theta d\theta=a\int (1-\cos\theta)d\theta$$
A: Find $\frac{dy}{d\theta}$ and then do the necessary replacement into the integral
A: $$y=a(1-\cos\theta)\Longrightarrow dy=a\sin\theta\,d\theta\Longrightarrow$$
$$\int\sqrt{\frac{y}{2a-y}}\,dy=\int\sqrt{\frac{a(1-\cos\theta)}{a(1+\cos\theta)}}\,a\sin\theta\,d\theta$$
But I can't see an easy way to solve the above, which according to WA is a rather ugly expression which, assuming positivity of everybody, equals $\,x+\sin x+C\,$, which would make the integrand equal to $\,1+\cos x\,$ . I can't see it right away but I guess there must be some trigonometric identity somewhere there (I already got the equality but not in a nice way).
