Author neil.g
Recipients aisaac, eli.bendersky, madison.may, mark.dickinson, neil.g, pitrou, rhettinger, serhiy.storchaka, tim.peters, westley.martinez
Date 2013-09-12.02:57:46
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1378954666.54.0.586644776617.issue18844@psf.upfronthosting.co.za>
In-reply-to
Content
Should this really be implemented using the cumulative distribution and binary search algorithm?  Vose's Alias Method has the same initialization and memory usage cost (O(n)), but is constant time to generate each sample.

An excellent tutorial is here: http://www.keithschwarz.com/darts-dice-coins/
History
Date User Action Args
2013-09-12 02:57:46neil.gsetrecipients: + neil.g, tim.peters, rhettinger, mark.dickinson, pitrou, eli.bendersky, aisaac, westley.martinez, serhiy.storchaka, madison.may
2013-09-12 02:57:46neil.gsetmessageid: <1378954666.54.0.586644776617.issue18844@psf.upfronthosting.co.za>
2013-09-12 02:57:46neil.glinkissue18844 messages
2013-09-12 02:57:46neil.gcreate