# Integrating a probability density function that only depends on the norm

I have a probability density function $f$ on $\mathbb{R}^3$ which only depends on the norm of a vector (that is, it takes the same value for $x,y$ if their length is equal). Let me call a region of $\mathbb{R^3}$ a cone if it is closed under multiplying by a nonnegative number (the intersection of some half spaces through the origin for example).

Now it seems intuitively obvious that for a cone $S$ the number $\int_Sf$ is equal to the relative area of its intersection with the unit sphere (compared to the surface area of the unit sphere). Is there an elegant way to show this?

• Why, yes there is: use spherical coordinates, that is, perform the change of variable $x=ru$ where $x$ is in $\mathbb R^3$, $r$ is some nonnegative real and $u$ is in the unit sphere $S^2$. Then the cone is $S=\{u\in D\}$ for some $D\subseteq S^2$ and $dx=4\pi r^2dr\sigma_2(du)$ where $\sigma_2$ is the uniform probability on $S^2$ hence $$\int_Sf=\int_0^\infty 4\pi r^2f(r)dr\int_D\sigma_2(du)=c(f)\sigma_2(D)$$ for some factor $c(f)$ which does not depend on $S$, qed.
– Did
May 1, 2016 at 10:28

Generally, we could consider the $d$-dimension case. To avoid ambiguity, the "cone" $S$ will be denoted by $C$.
In $\mathbb R^d$, using spherical coordinates transformation $\text d\mathbf x=\text dr\,\mu(\text d\boldsymbol\omega_r)$ (NOT changing variables!), where $r=|\mathbf x|$, $\text d\boldsymbol\omega_r$ denotes as the area element of the $(d−1)$-sphere $S^{d-1}(r)$ with radius $r$, $\mu$ is the Lebesgue measure on $S^{d-1}$; also using the notation $\hat f(|\mathbf x|):=f(\mathbf x)$ which makes sense for the rotational invariance of $f$. Now we have $$\int_{C}f(\mathbf x)\ \text d\mathbf x = \int_0^\infty\int_{C\cap S^{d-1}(r)}\hat{f}(r)\,\mu(\text d\boldsymbol\omega_r)\,\text dr.$$ Change variables $\boldsymbol\omega_r=r\boldsymbol\omega_1$, where $\text d\boldsymbol\omega_1$ is the area element of $S^{d-1}(1)$ with radius $1$. Note that $\boldsymbol\omega_r\in C\cap S^{d-1}(r)$ if and only if $\boldsymbol\omega_1\in C\cap S^{d-1}(1)$ as $C$ is a cone, and that $$\mu(\text d\boldsymbol\omega_r)=\mu(r\text d\boldsymbol\omega_1)=r^{d-1}\mu(\text d\boldsymbol\omega_1).$$ Then we compute \begin{align} \int_0^\infty\int_{C\cap S^{d-1}(r)}\hat{f}(r)\,\mu(\text d\boldsymbol\omega_r)\,\text dr &= \int_0^\infty\int_{C\cap S^{d-1}(1)}r^{d-1}\hat{f}(r)\,\mu(\text d\boldsymbol\omega_1)\,\text dr \\ &= \int_0^\infty\bigg(\int_{C\cap S^{d-1}(1)}\mu(\text d\boldsymbol\omega_1)\bigg)r^{d-1}\hat{f}(r)\,\text dr \\ &= \mu\big(C\cap S^{d-1}(1)\big)\int_0^\infty r^{d-1}\hat{f}(r)\,\text dr. \end{align} Hence, $$\int_{C}f(\mathbf x)\ \text d\mathbf x = \mu\big(C\cap S^{d-1}(1)\big)\int_0^\infty r^{d-1}\hat{f}(r)\,\text dr.$$ QED.