skip to main content
technical-note

Replicated Computational Results (RCR) Report for “Fast Random Integer Generation in an Interval”

Published:24 January 2019Publication History
Skip Abstract Section

Abstract

The article “Fast Random Integer Generation in an Interval” by Lemire (2018) addressed the problem of reducing the cost of machine instructions needed for the random generation of integer values in a generic interval [0,s). The approach taken by the author is the one of exploiting the rejection method (Neumann 1951) to build an algorithm that almost eliminates the need for performing integer division operations—the algorithm still exploits divisions by powers of two, implemented in the form of cheap shift operations. In more details, the likelihood of not requiring an integer division in the proposed algorithm is 2Ls / 2L, where L denotes the number of bits used to represent integer values. The author also presents a comparative experimental study where the new algorithm, and its implementation for x86 processors, are compared with solutions offered by common software libraries for different programming languages.

References

  1. D. E. Knuth. 1969. The Art of Computer Programming, Volume II: Seminumerical Algorithms. Addison-Wesley.Google ScholarGoogle Scholar
  2. D. Lemire. 2018. Fast random integer generation in an interval. ACM Trans. Model. Comput. Simul. 29, 1, Article 3. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. J. V. Neumann. 1951. Various techniques used in connection with random digits. Nat. Bureau Stand. 12, 36--38.Google ScholarGoogle Scholar

Recommendations

Comments

Login options

Check if you have access through your login credentials or your institution to get full access on this article.

Sign in

Full Access

  • Published in

    cover image ACM Transactions on Modeling and Computer Simulation
    ACM Transactions on Modeling and Computer Simulation  Volume 29, Issue 1
    January 2019
    149 pages
    ISSN:1049-3301
    EISSN:1558-1195
    DOI:10.1145/3309768
    Issue’s Table of Contents

    Copyright © 2019 ACM

    Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

    Publisher

    Association for Computing Machinery

    New York, NY, United States

    Publication History

    • Published: 24 January 2019
    • Accepted: 1 July 2018
    • Received: 1 June 2018
    Published in tomacs Volume 29, Issue 1

    Permissions

    Request permissions about this article.

    Request Permissions

    Check for updates

    Qualifiers

    • technical-note
    • Research
    • Refereed limited
  • Article Metrics

    • Downloads (Last 12 months)4
    • Downloads (Last 6 weeks)0

    Other Metrics

PDF Format

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

HTML Format

View this article in HTML Format .

View HTML Format