Jump to content

Talk:Alias method

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia

optimizing

[edit]

I wonder whether there's literature on building the table to maximize , i.e., minimize the probability of consulting K. —Tamfang (talk) 21:03, 24 November 2018 (UTC)[reply]

Oops, there it is: Doing this optimally turns out to be NP hard, but a “Robin Hoodheuristic comes reasonably close: rob from the richest and give to the poorest. Cute, but I'll add a link to greedy algorithm. —Tamfang (talk) 19:59, 26 September 2019 (UTC)[reply]