From: Rick DeNatale Date: 2007-05-23T04:54:14+09:00 Subject: Re: Uniform Random Number Generator On 5/22/07, Roland Mai wrote: > I need a random number generator that generates random numbers with a > uniform distribution. > > I am not sure what rand does in ruby and I can't seem to find it online > either. My initial assumption is that it follows a uniform distribution, but > I can't tell. > > Any ideas? > According to the source code for random.c, Ruby's implementation of rand uses the Mersenne Twister MT19937 which according to: http://en.wikipedia.org/wiki/Mersenne_twister has "a very high order of dimensional equidistribution." HTH -- Rick DeNatale My blog on Ruby http://talklikeaduck.denhaven2.com/