Is there a way to generate individual uniformly distributed points on a sphere from a fixed amount of random real numbers per point?

The Lambert cylindrical equal area projection maps the sphere to a cylinder, area to equal area. It is easy to generate a uniform distribution on a cylinder. Simply map it back to the sphere.

For $(u_1,u_2)$ uniform on $[0,1]^2$, either

$\mathrm{lat}=\arcsin(2u_1-1),\mathrm{lon}=2\pi u_2$

or

$z=2u_1-1,x=\sqrt{1-z^2}\cos(2\pi u_2),y=\sqrt{1-z^2}\sin(2\pi u_2)$


Your method, even though it doesn't finish in a fixed number of times, is a reasonable way to do it. Each trial succeeds with probability $\frac\pi6$, which is better than $\frac12$: the average number of trials is less than $2$.

Another standard method is to use the normal distribution. Generate $x, y, z$ independently from a standard normal distribution, then take the point $(x,y,z)$ and divide it by $\sqrt{x^2+y^2+z^2}$ as you did for points inside the cube. The multivariate normal distribution is rotationally symmetric, so this will get you evenly distributed points on the sphere.

(The Box–Muller transform is one way to generate normally distributed random numbers, and some versions of it do not use rejection sampling, so they can be done with a "fixed amount" of randomness.)


Is there a way to generate uniformly distributed points on a sphere from a fixed amount of random real numbers per point?

This Stack Overflow answer mentions the Fibonacci sphere algorithm, and the currently unanswered Math SE question Is the Fibonacci lattice the very best way to evenly distribute N points on a sphere? So far it seems that it is the best? contains several excellent links in the question and in comments.

The method is deterministic, using either zero or one random number, no matter the number of points generated.

Florida State University's John Burkardt's web page Fibonacci Spiral Grid on a Sphere provides some references and examples of code implementations.

Edward Saff, Arno Kuijlaars, Distributing Many Points on a Sphere, The Mathematical Intelligencer, Volume 19, Number 1, 1997, pages 5-11.

Richard Swinbank, James Purser, Fibonacci grids: A novel approach to global modelling, Quarterly Journal of the Royal Meteorological Society, Volume 132, Number 619, July 2006 Part B, pages 1769-1793.

Extreme Learning's Evenly distributing points on a sphere addresses several criteria for judging the level of uniformity provided by different solutions, and describes the process of first generating a Fibonacci grid and then transforming it to a sphere.

An example of these Fibonacci Grids is shown below. These points sets can be transformed to a well-known Fibonacci spirals via the transformation

enter image description here

I can't be sure it will be sufficiently uniform for you, but it certainly looks nice!

enter image description here Source

Tags:

Geometry