Question: Consider a simple linear congruential generator ( LCG ) with the following parameters: Xn + 1 = ( a . Xn + c ) mod

Consider a simple linear congruential generator (LCG) with the following parameters:
Xn+1=(a . Xn + c) mod m
The PRNG is defined as follows
a=5
c=3
m=16
X0=2(the seed)
a. Calculate the first four values generated by the LCG. Show the step-by-step calculations. (4 points)
b. Analyze the sequence of generated numbers and determine the period of the PRNG. Explain how you arrived at this conclusion. (3 points)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!