Re: random numbers in fortran



"The basic statistical property that you should worry about first is the
cycle length. To shuffle cards you want all 52! permutations to have a
chance of happening. With a short cycle length that does not happen.
A rather critical issue if you are going to pretend that the results
have any relevance to real card games."

Would you please elucidate?

The number of permutations of the 52 cards is 52!, which according to Stirling's approximation is about 10^68. So you would need a random number
generator with at least that cycle length to generate all possible patterns.
Not that anybody would care, given that the universe is less than 10^61 Planck times old.

Jan
.



Relevant Pages

  • Re: random numbers in fortran
    ... How, for example, would one set "cycle length" to be sure that each one ... combinations had the same chance of coming up? ... With a short cycle length the PSEUDO random number generator will not ... be able to represent all those permutations. ...
    (comp.lang.fortran)
  • Re: random numbers in fortran
    ... To shuffle cards you want all 52! ... With a short cycle length that does not happen. ... be able to represent all those permutations. ... Even if it had a chance it ...
    (comp.lang.fortran)
  • Re: random numbers in fortran
    ... In words one solution is to generate random permutations (sampling ... A Random number generator with "decent" properties. ... (Cycle lengths of these are documented in the leading comments; ... -|combinations had the same chance of coming up? ...
    (comp.lang.fortran)
  • Re: random numbers in fortran
    ... With a short cycle length that does not happen. ... You are trying to shuffle cards, ... With a short cycle length the PSEUDO random number generator will not ...
    (comp.lang.fortran)
  • Re: LCM of all cycle lengths
    ... Then, without much warning, the third and fourth paragraphs change the subject to "all possible E". ... The set of keys could just be the set of permutations on, ... since every cycle length from 1 to B appears somewhere. ... If I have a chosen-plaintext oracle for AES256, I can decrypt a given ciphertext after an expected 2**127 inquiries. ...
    (sci.crypt)