Lehmer Random Number Generator - Relation To LCG

Relation To LCG

While the Lehmer RNG can be viewed as a particular case of the linear congruential generator with c=0, it is a special case that implies certain restrictions and properties. In particular, for the Lehmer RNG, the initial seed X0 must be coprime to the modulus n that is not required for LCGs in general. The choice of the modulus n and the multiplier g is also more restrictive for the Lehmer RNG. In contrast to LCG, the maximum period of the Lehmer RNG equals n−1 and it is such when n is prime and g is a primitive root modulo n.

On the other hand, the discrete logarithms (to base g or any primitive root modulo n) of Xk in represent linear congruential sequence modulo Euler totient .

Read more about this topic:  Lehmer Random Number Generator

Famous quotes containing the words relation to and/or relation:

    You see, I am alive, I am alive
    I stand in good relation to the earth
    I stand in good relation to the gods
    I stand in good relation to all that is beautiful
    I stand in good relation to the daughter of Tsen-tainte
    You see, I am alive, I am alive
    N. Scott Momaday (b. 1934)

    We must get back into relation, vivid and nourishing relation to the cosmos and the universe. The way is through daily ritual, and is an affair of the individual and the household, a ritual of dawn and noon and sunset, the ritual of the kindling fire and pouring water, the ritual of the first breath, and the last.
    —D.H. (David Herbert)