home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: sci.math.stat
- Path: sparky!uunet!zaphod.mps.ohio-state.edu!sol.ctr.columbia.edu!The-Star.honeywell.com!umn.edu!charlie
- From: charlie@umnstat.stat.umn.edu (Charles Geyer)
- Subject: Re: Nonrandom Random Numbers?
- Message-ID: <C0rHDD.Exr@news2.cis.umn.edu>
- Sender: news@news2.cis.umn.edu (Usenet News Administration)
- Nntp-Posting-Host: isles.stat.umn.edu
- Organization: School of Statistics, University of Minnesota
- References: <1993Jan12.132319.6437@cbis.ece.drexel.edu> <1993Jan12.140114.620@hnrc.tufts.edu> <dmurdoch.393.726873235@mast.queensu.ca>
- Date: Tue, 12 Jan 1993 22:05:34 GMT
- Lines: 56
-
- In article <dmurdoch.393.726873235@mast.queensu.ca> dmurdoch@mast.queensu.ca (Duncan Murdoch) writes:
- >In article <1993Jan12.140114.620@hnrc.tufts.edu> jerry@hnrc.tufts.edu (Jerry Dallal) writes:
- >>For those who do not have the Times, the article says, " . . . the scientists
- >>showed that five of the most popular computer programs for generating streams
- >>of random numbers produced errors when they were used in a simple mathematical
- >>model of the behavior of atoms in a magnetic crystal."
- >
- >>Unfortunately (and understandably) the article does not identify the 5
- >>algorithms. However, the article cites the original report from Ferrenberg et
- >>al. in the Dec. 7 issue of Physical Review Letters. I would be grateful if
- >>someone with access to PRL would post the five generators.
- >
- >The paper is Ferrenberg, A. M., Landau, D.P., and Wong, Y.J. (1992), Monte
- >Carlo simulations: hidden errors from "good" random number generators,
- >Physical Review Letters 69 no. 23, 3382-3384.
- >
- >The generators tested were:
- >
- >CONG: A linear congruential generator
- > X_n = (16807 X_{n-1}) mod (2^{31} - 1)
- >
- >R250: A shift register algorithm:
- > X_n = X_{n-103} XOR X_{n-250}
- >
- >R1279: Another shift register algorithm:
- > X_n = X_{n-1063} XOR X_{n-1279}
- >
- >In R250 and R1279, "XOR" is a bitwise exclusive OR; it doesn't say how
- >many bits were used, but I'd assume 32 from the context.
- >
- >SWC: A subtract with carry generator (Marsaglia et al, Comput Phys Commun
- >60, p 345, 1990):
- >
- > X_n = X_{n-22} - X_{n-43} - C
- > if X_n >= 0, C=0,
- > if X_n < 0, X_n = X_n + (2^32-5), C=1
- >
- >SWCW: A combined subtract with carry Weyl generator (ibid):
- >
- > Z_n = X_{n-22} - Z_{n-43} - C
- > if Z_n >= 0, C=0
- > if Z_n < 0, Z_n = Z_n+(2^32-5), C=1
- > Y_n = (Y_{n-1} - 362436069) mod 2^32
- > X_n = (Z_n - Y_n) mod 2^32
-
- Trouble is, none of these are "good" generators. For safety, one should
- XOR two "independent" generators as Marsaglia et al. do with the "super-duper"
- and "ultra" generators.
-
- Have any problems ever been reported with either of these?
-
- --
- Charles Geyer
- School of Statistics
- University of Minnesota
- charlie@umnstat.stat.umn.edu
-