# Marginal distribution of spherical uniform

For a random vector $\mathbf{X} \in \mathbb{R}^n$ uniformly distributed on the surface of a sphere of radius $r$, the PDF is the inverse of the surface $$f_\mathbf{X}(\mathbf{x}) = 2\pi^{-n/2}\Gamma(n/2)r^{1-n} \tag{1}$$

To derive the marginal distribution, I use the law of total probability. For $\mathbf{X_i} = [X_1 ... X_{n-i}]$, $$f_\mathbf{X_1}(\mathbf{x_1}) = \int_{-r}^{r} f_\mathbf{X}(\mathbf{x}) dx_n = 2\pi^{-n/2}\Gamma(n/2)r^{1-n} \times 2r$$ $$f_\mathbf{X_2}(\mathbf{x_2}) = \int_{-r}^{r} f_\mathbf{X_1}(\mathbf{x_1}) dx_{n-1} = 2\pi^{-n/2}\Gamma(n/2)r^{1-n} \times (2r)^2$$ and go on $$f_{X_1}(x_1) = 2\pi^{-n/2}\Gamma(n/2)r^{1-n} \times (2r)^{n-1} = 2^{n-2}\pi^{-n/2}\Gamma(n/2) \tag{2}$$

Equation (2) shows that the marginal PDF is uniform and does not depend on $r$. This is incorrect.

Could anyone show me where I am wrong?

• The distribution is found at stats.stackexchange.com/questions/85916/…, inter alia. The connection is that the marginal distribution is the scalar product of $X$ with a unit coordinate vector. Your calculations are incorrect because you are not using the correct volume element for a sphere: you are integrating over a cube of side $2r$ and the factor of $r^{1-n}$ is wrong, too. – whuber May 21 '18 at 16:30
• @whuber thanks for answer. Could you tell me which factor $r^{1-n}$ is wrong? The one in (1) or the one in the result of integration because I did not use the correct volume element for a sphere? I mean I don't expect that (1) is wrong because the density should be the inverse of the surface of the sphere, shouldn't it? – Cath Maillon May 21 '18 at 23:04
• I would suggest ignoring $r$ altogether, because it merely establishes the linear unit of measurement. You may therefore take it to equal $1.$ That will help you focus on the essential ideas. – whuber May 22 '18 at 13:18
• @whuber Let me try once more time. I am interested in $f_{X_1,...,X_{n-1}}(x_1,...,x_{n-1})$ and I write $f_\mathbf{X}(\mathbf{x}) = 2\pi^{-n/2}\Gamma(n/2) \delta(\left\lVert \mathbf{x}\right\rVert = 1)$ where $\delta()$ is the delta function. Then $$f_{X_1,...,X_{n-1}}(x_1,...,x_{n-1}) = \int_{-1}^1 f_\mathbf{X}(\mathbf{x}) dx_n \\= 2\pi^{-n/2}\Gamma(n/2) \int_{-1}^1 \delta(x_n^2 = 1 - x_1^2-...-x_{n-1}^2) dx_n = 2\pi^{-n/2}\Gamma(n/2) \times 2$$ because there is 2 points $x_n^2 = \pm\sqrt{1 - x_1^2-...-x_{n-1}^2}$. – Cath Maillon May 24 '18 at 13:54
• This PDF does not depend on $x_i$ either and if I continue like that, the marginal distribution $f_{X_1}(x_1)$ will be something does not depend on $x_1$ which is different from the correct distribution in your link. – Cath Maillon May 24 '18 at 13:55