Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

One can sample coordinates of the surface of a unit radius $n$-dimensional sphere uniformly using the following method: independently generate a vector of $n$ standard normal random variables $\mathbf{x}=[X_1,\ldots,X_n]$, compute the Euclidean norm of this vector $\|\mathbf{x}\|_2=\sqrt{X_1^2+\ldots+X_n^2}$, then vector $\mathbf{x}/\|\mathbf{x}\|_2$ will contain the uniform sample of a coordinate from the surface of a unit-radius $n$-sphere.

I am wondering if that method can be extended to sampling from an $n$-sphere with arbitrary radius $r>0$. My intuition tells me that multiplying the sample from unit-radius $n$-sphere by $r$ might work, but I haven't seen that mentioned anywhere, which makes me think that either my intuition is wrong or this may be a question with an obvious answer.

So, can someone clarify: is vector $r\mathbf{x}/\|\mathbf{x}\|_2$ a uniform sample from the surface of an $n$-sphere of radius $r$? If it is not, is there a way to use i.i.d. normal variates to obtain such a sample?

share|improve this question
Yes. ${}{}{}{}$ –  Rahul Apr 22 '13 at 8:35
add comment

1 Answer

up vote 1 down vote accepted

Answer: "Yes." – Rahul Narain Apr 22 at 8:35

Additional remark: if you manage to take uniform samples from the unit sphere by whatever method, multiplication by $r$ will do the same for the sphere by radius $r$. This is because the pushforward of the normalized surface measure on the unit sphere by the map $x\mapsto rx$ is the normalized surface measure on the sphere of radius $r$.

share|improve this answer
add comment

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.