By far, the most widely used technique for pseudorandom number generation is the linear congruential method. The

Question:

By far, the most widely used technique for pseudorandom number generation is the linear congruential method. The algorithm is parameterized with four numbers, as follows:

m the modulus m 7 0 a the multiplier 0 … a 6 m c the increment 0 … c 6 m X0 the starting value, or seed 0 … X0 6 m The sequence of pseudorandom numbers {Xn} is obtained via the following iterative equation:

Xn+1 = (aXn +

c) mod m If m,

a, c, and X0 are integers, then this technique will produce a sequence of integers with each integer in the range 0 … Xn 6 m. An essential characteristic of a pseudorandom number generator is that the generated sequence should appear random.

Although the sequence is not random, because it is generated deterministically, there is a variety of statistical tests that can be used to assess the degree to which a sequence exhibits randomness. Another desirable characteristic is that the function should be a full-period generating function. That is, the function should generate all the numbers between 0 and m before repeating.

With the linear congruential algorithm, a choice of parameters that provides a full period does not necessarily provide a good randomization. For example, consider the two generators:
Xn+1 = (6Xn) mod 13 Xn+1 = (7Xn) mod 13 Write out the two sequences to show that both are full period. Which one appears more random to you?

Fantastic news! We've Found the answer you've been seeking!

Step by Step Answer:

Related Book For  book-img-for-question
Question Posted: