> Thu, 29 Jul 2010 02:40:00 +0200, Sturla Molden wrote: > Want to submit a patch? ;)
I had this in a Matlab MEX file I used for my dissertation. The ziggurat is not hard to program, even for general PDFs. We could even fill in the ziggurat table using numerical integration, and code one for general PDFs (NumPy overhead for the tail fallback could be amortized). There is a timing here claiming ziggurat with mt19937 is 3.9 times faster than Box-Müller: http://seehuhn.de/pages/ziggurat Sturla _______________________________________________ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion