Random sampling with a reservoir
ACM Transactions on Mathematical Software (TOMS)
Computational geometry: an introduction
Computational geometry: an introduction
The complexity of generating an exponentially distributed variate
Journal of Algorithms
Maintaining Discrete Probability Distributions Optimally
ICALP '93 Proceedings of the 20th International Colloquium on Automata, Languages and Programming
COCOON'10 Proceedings of the 16th annual international conference on Computing and combinatorics
Succinct sampling from discrete distributions
Proceedings of the forty-fifth annual ACM symposium on Theory of computing
Hi-index | 0.00 |
We study the fundamental problem of the exact and efficient generation of random values from a finite and discrete probability distribution. Suppose that we are given n distinct events with associated probabilities p1, …, pn. We consider the problem of sampling a subset, which includes the ith event independently with probability pi, and the problem of sampling from the distribution, where the ith event has a probability proportional to pi. For both problems, we present on two different classes of inputs --- sorted and general probabilities --- efficient preprocessing algorithms that allow for asymptotically optimal querying, and prove almost matching lower bounds for their complexity.