Expected projected length of radial vectors of n-sphere

euclidean-geometrygeometric-probabilityspheresspherical-geometry

Situation

In $n$-dimensional Euclidean space rests a unit $(n-1)$-dimensional sphere that is orthographically projected onto a $(n-1)$-dimensional plane. The topological definition of a sphere is used, i.e. only the surface points belong to a sphere.

Question

What is the expected projected length $\bar{x}_n$ of uniformly distributed radial unit vectors that start at the sphere center?

Solution strategy

One could calculate this by multiple integration using $n$-dimensional spherical coordinates but I hope there is a more elegant method. It seems there is a pattern that could be generalized to $n$ dimensions.

Solutions for $n=2$ and $n=3$

2-space (see drawing)

In 2-space (plane) a unit 1-sphere (circle) is projected onto a 1-plane (line).
The mean projected length from integration over a quadrant is $$\bar{x}_2=\frac{2}{\pi} =\frac{4}{2\pi}\int_{0}^{\frac{\pi}{2} } \sin(\alpha) \mathrm{d}\alpha$$

3-space

If we go 1 dimension higher, we arrive at the usual 2-sphere in 3-space. The radial vector is projected to a 2-plane. By integration over an octand we get for the mean projected length $$\bar{x}_3=\frac{\pi}{4} =\frac{8}{4\pi} \int_{0}^{\frac{\pi}{2} } \int_{0}^{\frac{\pi}{2} } \sin^2(\theta) \mathrm{d\theta} \mathrm{d}\phi$$

enter image description here

Best Answer

Disclaimer: I used Mathematica for part of the problem.


As an expected value, this would be $$\mathbb{E}\left[ \sqrt{x_1^2+x_2^2 + ... + x_{n-1}^2} \right]$$

where $\left(x_1, x_2, ..., x_n\right)$ is a random point on the surface of the sphere. Since it is known that $x_1^2 + x_2^2 + ... + x_n^2 = 1$, this is equivalent to $$\mathbb{E}\left[ \sqrt{1 - x_n^2} \right] = \mathbb{E}\left[ \sqrt{1 - x_1^2} \right]$$

From here, $x_1$ can be chosen as $\frac{y_1}{\sqrt{\sum_{k=1}^n y_k^2}}$, where $y_k$ are chosen from $\mathcal{N}(0, 1)$. The expected value is then $$\mathbb{E}\left[ \sqrt{1 - \frac{y_1^2}{\sum_{k=1}^n y_k^2}} \right]$$

As an integral, this would be $$\int_0^{1} \left(1 - \mathbb{P}\left( \sqrt{1 - \frac{y_1^2}{\sum_{k=1}^n y_k^2}}<x \right)\right) dx$$

That inner probability is equal to $$\mathbb{P}\left( \frac{1-x^2}{x^2}\sum_{k=2}^n y_k^2 < y_1^2 \right)$$

Using the PDF of the chi-square distribution, this would be $$\frac{1}{2^{\frac{n}{2}}\Gamma\left(\frac{n-1}{2}\right)}\frac{1}{\Gamma\left(\frac{1}{2}\right)}\int_{0}^{\infty}\int_{\frac{1-x^2}{x^2}z}^{\infty} z^{(n-1)/2-1}e^{-z/2}y^{1/2-1}e^{-y/2} dydz$$

Then the answer is (after some switching of bounds) $$1-\frac{1}{2^{\frac{n}{2}}\Gamma\left(\frac{n-1}{2}\right)\Gamma\left(\frac{1}{2}\right)}\int_{0}^{\infty}\int_{0}^{\infty}\int_{\sqrt{\frac{z}{y+z}}}^{1}\left(z^{\frac{n-3}{2}}e^{-\frac{z}{2}}y^{-\frac{1}{2}}e^{-\frac{y}{2}}\right)dxdydz$$

This simplifies to $$\frac{1}{2^{\frac{n}{2}}\Gamma\left(\frac{n-1}{2}\right)\Gamma\left(\frac{1}{2}\right)}\int_{0}^{\infty}\int_{0}^{\infty}\left(z^{\frac{n-2}{2}}e^{-\frac{y+z}{2}}y^{-\frac{1}{2}}\right)\sqrt{\frac{1}{y+z}}dydz$$

Mathematica then gives this as $$\frac{\pi^{\frac{3}{2}}}{\Gamma\left(\frac{n-1}{2}\right)\Gamma\left(\frac{1}{2}\right)}\frac{\cos\left(\frac{n\pi}{2}\right)\Gamma\left(1-\frac{n+1}{2}\right)}{\left(\sin\left(\frac{n\pi}{2}\right)\Gamma\left(1-\frac{n}{2}\right)\right)^{2}}$$ for non-integer $n$. Taking the limit as $n$ approaches an integer and using Euler's reflection formula, this simplifies to $$\frac{\Gamma\left(\frac{n}{2}\right)^2}{\Gamma\left(\frac{n-1}{2}\right)\Gamma\left(\frac{n+1}{2}\right)} \approx 1 - \frac{1}{2}n^{-1}-\frac{3}{8}n^{-2} + O(n^{-3})$$

Edit: Using that $\Gamma(k + \frac{1}{2}) = \frac{(2k-1)!!\sqrt{\pi}}{2^k} = \frac{(2k)!\sqrt{\pi}}{4^k}k!$ and $\Gamma(k) = (k-1)!$, splitting by odd and even cases, for odd $n$, it is $$\frac{\pi}{4^{n-1}}\cdot\frac{\left[\left(n-1\right)!\right]^{2}}{\left(\frac{n-3}{2}\right)!\left[\left(\frac{n-1}{2}\right)!\right]^{3}} = \frac{\pi(n-1)}{2^{2n-1}} \binom{n-1}{\frac{n-1}{2}}^2$$ while for even $n$, it is $$\frac{2^{2n-2}}{\pi}\frac{\left(\frac{n}{2}\right)!\left[\left(\frac{n}{2}-1\right)!\right]^{3}}{\left(n-2\right)!\left(n\right)!} = \frac{2^{2n+1}}{\pi}\frac{n-1}{n^{2}}\binom{n}{\frac{n}{2}}^{-2}$$

Related Question