generating random tuples in python

Robert Kern robert.kern at
Tue Apr 21 21:30:36 CEST 2009

On 2009-04-20 23:04, per wrote:

> to be more formal by very different, i would be happy if they were
> maximally distant in ordinary euclidean space... so if you just plot
> the 3-tuples on x, y, z i want them to all be very different from each
> other.  i realize this is obviously biased and that the tuples are not
> uniformly distributed -- that's exactly what i want...
> any ideas on how to go about this?

Perhaps it would help if you told us what application you are going to use them 
for? You can straightforwardly make a regular tetrahedral grid of points that 
fit in your box at whatever density you like. Which is more important: maximal 
(average) distance between neighbors or avoiding regularity? If you need to 
strike a balance between them, then you may want to look into low-discrepancy 

Robert Kern

"I have come to believe that the whole world is an enigma, a harmless enigma
  that is made terrible by our own mad attempt to interpret it as though it had
  an underlying truth."
   -- Umberto Eco

More information about the Python-list mailing list