
On Thu, 16 Feb 2006, Matthias Fischmann wrote:
I wrote a module for sampling arbitrary probability distribution, so far including normal (gaussian) and uniform.
http://www.wiwi.hu-berlin.de/~fis/code/
For those who need something like this: feel free to take it, it's BSD. For those who feel like growing their karma:
- There are a few questions in the code (marked with 'XXX').
- There are probably far better way to do this. I am eager to learn.
- There is probably a better implementation out there already. Please point me to it.
In HaskellDSP there are some routines for generating random numbers with specific distributions: http://haskelldsp.sourceforge.net/doc/index.html e.g. http://haskelldsp.sourceforge.net/doc/Numeric.Random.Distribution.Gamma.html