in reply to Re^8: Algorithm RFC: fast (pseudo-)random shuffle with no repetition
in thread Algorithm RFC: fast (pseudo-)random shuffle with no repetition
But you have 8 identical 1 which would always create 8! duplicates for each solution by swapping 1s (well rather symmetries or congruence classes)
hence 15!/8!
WP has nice graphics visualizing it
https://en.wikipedia.org/wiki/Permutation#Permutations_of_multisets
Cheers Rolf
(addicted to the Perl Programming Language :)
see Wikisyntax for the Monastery
|
---|