Lineare Kongruenzmethode

zi+1 = (a * zi + c) mod m
echo (zi+1 mod output)

a: (Multiplikator) b: (Additionskonstante) m: (Modulo-Teiler) output: (Ausgabeintervall) z0: (Startwert) n: (max. Iterationstiefe) Beispiel 1, Beispiel 2

0, 7, 0, 2, 6, 4, 5, 1, 8, 3, 2, 1, 0, 7, 0, 2, 6, 4, 5, 1, 8, 3, 2, 1, 0, 7, 0, 2, 6, 4, 5, 1, 8, 3, 2, 1, 0, 7, 0, 2, 6, 4, 5, 1, 8, 3, 2, 1, 0, 7, 0, 2, 6, 4, 5, 1, 8, 3, 2, 1, 0, 7, 0, 2, 6, 4, 5, 1, 8, 3, 2, 1, 0, 7, 0, 2, 6, 4, 5, 1, 8, 3, 2, 1, 0, 7, 0, 2, 6, 4, 5, 1, 8, 3, 2, 1, 0, 7, 0, 2, 6, 4, ...

Periodenlänge: 12

0 
 
1 
 
2 
 
3 
   
4 
   
5 
   
6 
   
7 
   
8 
   
9