next up previous

3.1 Approach     continued...

The appearance of randomness is provided by performing modulo arithmetic or remaindering. For example, the nonnegative integers modulo 3 are . Note that the next result, , depends upon only the previous integer, . This is a characteristic of linear, congruential generators which minimizes storage requirements, but at the same time, imposes restrictions on the period.

With determined, we generate a corresponding real number as follows:

When dividing by m, the values are then distributed on [0,1). If we desire to be distributed on [0, 1], then we would divide by . We desire uniformity, where any particular is just as likely to appear as any other , and the average of the is very close to 0.5.