Create list of random numbers without repeats? [closed]
I need a list of 210 random numbers in Calc, whether integers or otherwise doesn't matter, as long as none of the numbers repeat i.e there are no duplicate numbers in the list.
I read a tutorial that the RAND() function was the one to use to do this, and have used the function accordingly. However I have found repetitions of certain numbers in my results- how do I prevent this from happening? I must admit I have very little knowledge of how the randomisation process works...
Attached is a document containing two columns, 1 with the list of numbers generated using RAND(), the other confirming duplicates of the first list.
Thanks.
EDIT: @PKG here is the referent list with highlighted duplicates that I mentioned: C:\fakepath\16054316544219107 (2).ods
@dscheikey Here is the referent screenshot I mentioned: C:\fakepath\Screen Shot 2020-11-16 at 6.55.13 PM.png
The pseudo-random-number generator works with the best known algorithm for general purposes which is mathematically proven to have an extremely long period (>10^6001). Working with integers basically,it requires that a conversion take place finally, and the standard numbers (IEEE 754 Double) used by Calc can "only" represent about 4.51E15 different values in the range from 0 through 1. In addition the arithmetic comparison for "=" does (for good reasons) accept a few different bits of low significance. Thus it isn't completely impossible to get repetitions reported by COUNTIF() for RAND() sequences. I never heard of a proven case, and wouldn't expect to ever get one.
Your example document always shows 210 unique results for me.
What version of LibO are you using?
Are you sure about your system and the LibO install?
I think you "hit the nail on the head" with the Lib install; after installing new version (choosing to replace old version when prompted), I found no repeats of RAND numbers. Thanks- you saved me a great deal of time there I think.