How to Make a Lumpy Random-Number Generator

نویسنده

  • Michael A. Covington
چکیده

Normally, random-number generators are designed to produce numbers with a uniform distribution. The sum of uniform random variates has a bell-curveshaped distribution. Using bell curves like wavelets, individual uniform random variables can be summed to produce arbitrary nonuniform distributions. The result is a simple, customizable non-uniform random-number generating algorithm that has been prototyped on Plan 9 and is equally suitable for other computing environments, including very small embedded systems. 1. Problem definition Normally, random-number generators produce uniformly distributed values. However, nonuniform random numbers are needed for a number of purposes. In simulation, one often needs random numbers conforming exactly to the observed or theoretical distribution of an input variable, in order to produce an authentic distribution of simulated output [1]. In other situations, the requirements are much less precise, but random numbers with a preference for certain values or ranges are still desired. Examples include equalizing wear on machinery by having a machine return to approximately but not exactly the same position each time; introducing “dither” to avoid unwanted synchronism with external processes; and correcting for nonuniformity in some process downstream from the random number generator. Traditionally, nonuniform distributions are generated by transforming the output of a uniform random-number generator, often using elaborate floating-point computations. In this paper I outline an alternative that is especially suitable for the latter set of cases, where quick computation is more important than hitting a specified distribution exactly.1 2. Approach As Fig. 1 shows, the sum of n uniform random variables is an (n−1)th-degree polynomial approximation to a normal distribution (bell curve) ([2], p. 22). For practical purposes, the curve with n=3 is smooth enough. Thus, one can generate a bell curve distribution by merely generating three random numbers each time, adding them, and dividing by three. Bell curves can be used like wavelets to synthesize more complex curves. For example, the distribution in Fig. 2 was synthesized from a nonzero baseline mixed with three bell curves by the code in Fig. 5. This research was done for CORAID, Inc. (www.coraid.com) while the author was on summer leave from the Institute for Artificial Intelligence, University of Georgia (www.ai.uga.edu). The author thanks Brantley Coile for posing the initial question from which this project arose. Figure 1: Histograms of the sum of n uniform random variables, from 10 000 000 trials.

برای دانلود رایگان متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Occupancy Numbers in Testing Random Number Generators

The classical occupancy problem where n balls are placed in N cells is used for testing of random number generators. We show that the statistics of appropriately chosen occupancy numbers are incompatible with the statistics of many pseudorandom number generators (PRNGs) even if they are truncated. More than that, the incompatibility shows up on relatively small samples long before the period of...

متن کامل

Yarrow-160: Notes on the Design and Analysis of the Yarrow Cryptographic Pseudorandom Number Generator

We describe the design of Yarrow, a family of cryptographic pseudo-random number generators (PRNG). We describe the concept of a PRNG as a separate cryptographic primitive, and the design principles used to develop Yarrow. We then discuss the ways that PRNGs can fail in practice, which motivates our discussion of the components of Yarrow and how they make Yarrow secure. Next, we define a specif...

متن کامل

Software Generation of Practically Strong Random Numbers

Although much thought usually goes into the design of encryption algorithms and protocols, less consideration is often given to equally important issues such as the selection of cryptographically strong random numbers, so that an attacker may find it easier to break the random number generator than the security system it is used with. This paper provides a comprehensive guide to designing and i...

متن کامل

Cryptographically Secure Linear feedback shift

ISSN: 2278 – 1323 All Rights Reserved © 2014 IJARCET 3504  Abstract— True random bit generator requires a naturally occurring source of randomness. Designing a hardware device or software program to exploit this randomness and produce a bit sequence that is free of biases and correlation is difficult task. For most cryptographic applications, the generator must not be subject to observation or...

متن کامل

Limits on the Stretch of Non-adaptive Constructions of Pseudo-Random Generators

The standard approach for constructing a large-stretch pseudorandom generator given a one-way permutation or given a smaller-stretch pseudo-random generator involves repeatedly composing the given primitive with itself. In this paper, we consider whether this approach is necessary, that is, whether there are constructions that do not involve composition. More formally, we consider black-box con...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2009