Therefore, a random shuffle (or multiple random shuffles, depending on the desired cardinality) can be transformed algorithmically into a random numberUnless you enumerate all of the permutations of the set, I don't know how this could possibly work. Even if you are, you're reducing the size of your output number drastically.
There are n! ways to permute a set of n items. There are n**n ways to choose n items from a set of n with replacement. The limit as n tends to zero of n!/n**n is zero. What this means is that compared with the cardinality of just choosing n random numbers from 1 to n, generating a random number with from a random shuffle gets progressively worse for larger n. This would imply (well, to me anyways) that if you're looking for a random number, better to do it directly than to first shuffle and then transform that shuffle into one.
A random number need not necessarily be chosen from an infinite setPoint conceded. I mis-spoke.
thor
Feel the white light, the light within
Be your own disciple, fan the sparks of will
For all of us waiting, your kingdom will come
In reply to Re^7: How to generate different random numbers?
by thor
in thread How to generate distinct random numbers?
by johnnywang
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |