An Automatic Code Generator for Nonuniform Random Variate Generation

Josef Leydold, Gerhard Derflinger, Günter Tirler, and Wolfgang Hörmann


There exists a vast literature on nonuniform random variate generators. Most of these generators are especially designed for a particular distribution. However in pratice only a few of these are available to practioners. Moreover for problems as (e.g.) sampling from the truncated normal distribution or sampling from fairly uncommon distributions there are often no algorithms available. In the last decade so called universal methods have been developed for these cases. The resulting algorithms are fast and have properties that make them attractive even for standard distributions.

In this contribution we describe the concept of Automatic random variate generation where these methods are used to produce a single piece of code in a high level programming language. Using a web-based front-end to such a program this is an easy-to-use source for researchers and programmers for high quality generators for a large class of distributions. Using our UNURAN library we have implemented such a system, which is accessable at http://statistik.wu-wien.ac.at/anuran.

Mathematics Subject Classification: 65C10 (Random Number Generation)

CR Categories and Subject Descriptors: G.3 [Probability and Statistics]: Random number generation

General Terms: Algorithms

Key Words: nonuniform random variate generation, universal algorithm, automatic code generator, transformed density rejection, continuous distribution

Download Preprint