Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!uwm.edu!rpi!uupsi!sunic!lth.se!newsuser From: ben@dit.lth.se (Ben Smeets) Newsgroups: comp.unix.questions Subject: random number generator random() questionable!!!? Message-ID: <1990Sep5.130637.12930@lth.se> Date: 5 Sep 90 13:06:37 GMT Sender: newsuser@lth.se (LTH network news server) Organization: Dep. of Information Theory, Lund Institute of Technology, Sweden Lines: 20 Reply-To:ben@dit.lth.se Hi: After doing some simulations I got suspicious about the UNIX random number generator random() available on the SUN3-xx machines (ver 4.1). I measured the distribution of the intervals in which the random numbers lie above 0.045 times the total range of the generated numbers. The distributionI obtained is not at all what one should expect if the random numbers are really uniformly distributed in [0..2^31-1] and are independent. So my questions are: 1) How does random() really work?(I do not know it) 2) Has anybody else noted some stange things with this random number generator.? 3) Are the people who can provide me with a good random number generator? Thanks for your cooperation. Ben Smeets