News for hackers. Stuff that matters.
Re:Generating random points inside a sphere by cs_ on Saturday August 04, 2018 @11:12PM (#17689466)
A quick test with C++'s <random> library agrees. For n = 100,000,000 points, the rejection method beat out the improved spherical by 7.8%. Using the normal distribution was even slower.

  XYZ: 16.418057 seconds
  Gauss: 23.415560 seconds
  Spherical: 17.705553 seconds
Re:Generating random points inside a sphere by charmides on Sunday August 05, 2018 @12:00AM (#17689593)
Those results are surprisingly close.
Re:Generating random points inside a sphere by dmurray on Sunday August 05, 2018 @05:41AM (#17690522)
Youll get a different result if random number generation is made more expensive, e.g. if you need to use a hardware RNG instead of a PRNG.
Re:Generating random points inside a sphere by blattimwind on Sunday August 05, 2018 @08:50AM (#17691072)
But why would you do that?