Xref: utzoo comp.sources.wanted:14315 comp.lang.c:34427 Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!uwm.edu!zaphod.mps.ohio-state.edu!samsung!cs.utexas.edu!yale!cmcl2!kramden.acf.nyu.edu!brnstnd From: brnstnd@kramden.acf.nyu.edu (Dan Bernstein) Newsgroups: comp.sources.wanted,comp.lang.c Subject: Re: Normal distribution random number generator -- WANTED Message-ID: <2478:Dec121:58:4090@kramden.acf.nyu.edu> Date: 1 Dec 90 21:58:40 GMT References: <1015@qusung.queensu.CA> Organization: IR Lines: 13 In article wilf@sce.carleton.ca (Wilf Leblanc) writes: > >I am looking for C source code to generate normal distribution > >random numbers. > Add M random uniform random numbers x (where x is between 0 and > N/M). Using M = 12 to 30, will generate random variables which > are very close to normal, There are many methods available which are not only accurate but also a lot faster than generating and summing thirty numbers. (It's also very dangerous to add successive outputs of a linear congruential sequence.) Look in Knuth chapter 3 to find some good techniques. ---Dan Brought to you by Super Global Mega Corp .com