Salvato in:
Dettagli Bibliografici
Autori principali: Brackett-Rozinsky, Nevin, Lemire, Daniel
Natura: Preprint
Pubblicazione: 2024
Soggetti:
Accesso online:https://arxiv.org/abs/2408.06213
Tags: Aggiungi Tag
Nessun Tag, puoi essere il primo ad aggiungerne!!
_version_ 1866910904717672448
author Brackett-Rozinsky, Nevin
Lemire, Daniel
author_facet Brackett-Rozinsky, Nevin
Lemire, Daniel
contents Pseudorandom values are often generated as 64-bit binary words. These random words need to be converted into ranged values without statistical bias. We present an efficient algorithm to generate multiple independent uniformly-random bounded integers from a single uniformly-random binary word, without any bias. In the common case, our method uses one multiplication and no division operations per value produced. In practice, our algorithm can more than double the speed of unbiased random shuffling for small to moderately large arrays.
format Preprint
id arxiv_https___arxiv_org_abs_2408_06213
institution arXiv
publishDate 2024
record_format arxiv
spellingShingle Batched Ranged Random Integer Generation
Brackett-Rozinsky, Nevin
Lemire, Daniel
Data Structures and Algorithms
Pseudorandom values are often generated as 64-bit binary words. These random words need to be converted into ranged values without statistical bias. We present an efficient algorithm to generate multiple independent uniformly-random bounded integers from a single uniformly-random binary word, without any bias. In the common case, our method uses one multiplication and no division operations per value produced. In practice, our algorithm can more than double the speed of unbiased random shuffling for small to moderately large arrays.
title Batched Ranged Random Integer Generation
topic Data Structures and Algorithms
url https://arxiv.org/abs/2408.06213