Simulation and modeling - Old Questions
7. Explain the congruence method of generating random numbers.
Answer
AI is thinking...
The congruence method (linear congruential method) produces a sequence of integers X1, X2, X3,.......between zero and m-1 according to the following recursive relationship:
- The initial value X0 is called the seed;
- a is called the constant multiplier;
- c is the increment
- m is the modulus
The selection of a, c, m and X0 drastically affects the statistical properties such as mean and variance, and the cycle length.
Case 1:
When , the form is called the mixed congruential method.
Case 2:
When c = 0, the form is known as the multiplicative congruential method.
Case 3:
When a = 1, the form is known as additive congruential method.
The random numbers corresponding to each random integer can be obtained as:
Ri = Xi/m, for i = 0, 1, 2, 3, …………..