Average height of a semicircle. Why are these different answers?

In my mind, there are two approaches to finding the average height of a semicircle. Integrating Cartesianally:

$$y_{av}=\frac{1}{2r}\int_{-r}^r\sqrt{r^2-x^2}dx=\frac{\pi r}{4}$$

Or integrating polar:

$$y_{av}=\frac{1}{\pi}\int_{0}^\pi r\sin(\theta)d\theta=\frac{2r}{\pi}$$

Both of these seem intuative as you are integrating the height of all possible inputs, then dividing by the range of inputs to give you the average height of all inputs. Yet, we get different results from each.

Which is the correct average height, and why are they different? Or are they correct in their own manner, and why?

• Briefly, the inputs are weighted differently. – peterwhy Oct 6 '18 at 2:43
• finding the average height Define what average you want to calculate. First one draws an arbitrary vertical, second one draws a radius at an arbitrary angle. The two define different distributions for the point on the semicircle. – dxiv Oct 6 '18 at 2:45
• For a simple closed curve around the origin, the enclosed area in polar coordinates is given by $\int_{0}^{2\pi}\frac{1}{2}\rho(\theta)^2\,d\theta$. If $\rho(\theta)$ constantly equals $r$, such integral is $\pi r^2$ as expected. Also, if you enforce the substitution $x\mapsto r\sin\theta$ in $\frac{1}{r}\int_{0}^{r}\sqrt{r^2-x^2}\,dx$ you end with $$r\int_{0}^{\pi/2}\cos^2(\theta)\,d\theta=\frac{\pi r}{4}$$ due to the Jacobian $d\sin\theta=\cos(\theta)d\theta$. Your formula for the area in polar coordinates is essentially assuming that $\sin\theta$ is constant, which is clearly not the case. – Jack D'Aurizio Oct 6 '18 at 2:53
• @Graviton For the centroid of a semicircle arc see 1, 2. For why it is important to fully state what is being asked see Bertrand's paradox. – dxiv Oct 6 '18 at 3:01
• @dxiv Thank you. Yes, lesson learnt. – Graviton Oct 6 '18 at 3:03