Daniel R. Sheldon
Adaptive rejection sampling (ARS) is an algorithm by Gilks and Wild for drawing samples from a continuous log-concave probability distribution with only black-box access to a function that computes the (unnormalized) density function. The ideas extend in a straightforward way to discrete log-concave distributions, but some details of the extension and its implementation can be tricky. The technical report and code below provide the details of a discrete ARS algorithm and a companion implementation in C with a MATLAB interface.
Please cite as:
Daniel Sheldon. Discrete Adaptive Rejection Sampling. Technical Report UM-CS-2013-012, School of Computer Science, University of Massachusetts, Amherst, May 2013.