# How to tile a sphere with points at an even density?

I'm writing a bit of code to plot twitter usage across the globe. To do this, I'm searching for users within n km of a certain longitude/latitude (a circular area), at many different lat/lon coordinates. The fact that this is lat/lon coordinates is irrelevant, since this portion is done in cartesian coordinates.

I need to tile the earth (a sphere in this model) with m points, which will serve as the centre of a search radius. The location of each point (x y z) is subject to the constraint that it cannot be within m km of any other point (x' y' z'), so that the search radii do not overlap. Any thoughts? It seems like the kind of problem that has a perfect solution.

-

## 2 Answers

The problem of distributing points on a sphere (as opposed to a circle) does not have a neat solution. There is a lot of information online, but you'll have to see for yourself what you can use. (There is also a common confusion between uniform random distribution and evenly-spaced distribution, which are very different things).

-
thanks for the answer, the links were really useful. after playing around with a few techniques, the most efficient method seems to be the iterative method in the last link. Thanks again :) – RyanGrannell Jul 23 '12 at 18:23

Your question is a bit ambiguous. You seem to have the answer for uniform random distribution which are mostly approximations. But if you want exact, evenly-spaced distributions (without including the malevolent solution of n=1), there are only (and exactly) 6 solutions for a 3-sphere. These correspond to the 5 Platonic solids + the solution of 2 points on opposite sides of each other.

-