TY - JOUR

T1 - MergeShuffle

T2 - 11th International Conference on Random and Exhaustive Generation of Combinatorial Structures, GASCom 2018

AU - Bacher, Axel

AU - Bodini, Olivier

AU - Hollender, Alexandros

AU - Lumbroso, Jérémie

N1 - Funding Information:
This research was partially supported by the ANR MetACOnc project ANR-15-CE40-0014.
Publisher Copyright:
© 2018 Copyright by the paper's authors.
Copyright:
Copyright 2018 Elsevier B.V., All rights reserved.

PY - 2018

Y1 - 2018

N2 - This article introduces an algorithm, MERGESHUFFLE, which is an extremely efficient algorithm to generate random permutations (or to randomly permute an existing array). It is easy to implement, runs in nlog2 n+ O(1) time, is in-place, uses nlog2 n+ Θ(n) random bits, and can be parallelized across any number of processes, in a shared-memory PRAM model. Finally, our preliminary simulations using OpenMP1suggest it is more efficient than the Rao-Sandelius algorithm, one of the fastest existing random permutation algorithms. We also show how it is possible to further reduce the number of random bits consumed, by introducing a second algorithm BALANCEDSHUFFLE, a variant of the Rao-Sandelius algorithm which is more conservative in the way it recursively partitions arrays to be shuffled. While this algorithm is of lesser practical interest, we believe it may be of theoretical value.

AB - This article introduces an algorithm, MERGESHUFFLE, which is an extremely efficient algorithm to generate random permutations (or to randomly permute an existing array). It is easy to implement, runs in nlog2 n+ O(1) time, is in-place, uses nlog2 n+ Θ(n) random bits, and can be parallelized across any number of processes, in a shared-memory PRAM model. Finally, our preliminary simulations using OpenMP1suggest it is more efficient than the Rao-Sandelius algorithm, one of the fastest existing random permutation algorithms. We also show how it is possible to further reduce the number of random bits consumed, by introducing a second algorithm BALANCEDSHUFFLE, a variant of the Rao-Sandelius algorithm which is more conservative in the way it recursively partitions arrays to be shuffled. While this algorithm is of lesser practical interest, we believe it may be of theoretical value.

UR - http://www.scopus.com/inward/record.url?scp=85049070396&partnerID=8YFLogxK

UR - http://www.scopus.com/inward/citedby.url?scp=85049070396&partnerID=8YFLogxK

M3 - Conference article

AN - SCOPUS:85049070396

VL - 2113

SP - 43

EP - 52

JO - CEUR Workshop Proceedings

JF - CEUR Workshop Proceedings

SN - 1613-0073

Y2 - 18 June 2018 through 20 June 2018

ER -