Re: [commons RNG] link to benchmark page from user guide gives 404.

Alex Herbert <[email protected]>
Newsgroups gmane.comp.jakarta.commons.user
Message-ID <CAJxH-uptganuXcce5+-PShAapJmN=9zjAKhrhQ-_-r_23oKnag@mail.gmail.com>
On Wed, 13 Dec 2023 at 11:50, r.c.hoekstra <[email protected]> wrote:
>
> Hi,
>
>
> I need to choose a fast PRNG, but the apache commons RNG user guide has
> a broken link to the page with benchmarks (the user guide page is here:
> https://commons.apache.org/proper/commons-rng/userguide/rng.html#a4._Performance)

This is the correct place. Scroll down and you can see tables of
results for all the RNGs in the library.

Choosing a PRNG is a trade off between the period of the RNG and the
speed. Within a family of RNGs the larger the state size the larger
the period and the slower the RNG. For single thread applications a
128-bit state size will be adequate. If you are using multiple
concurrent RNGs then a larger period will ensure that you reduce the
chance of sequence collision (i.e. overlap).

Also look at the quality of the output:

https://commons.apache.org/proper/commons-rng/userguide/rng.html#a5._Quality

Ideally you should choose a RNG that passes TestU01 (BigCrush) and PractRand.

> The 404 points to here:
> https://commons.apache.org/proper/commons-rng/commons-rng-examples/examples-jmh/apidocs/org/apache/commons/rng/jmh/package-summary.html

This link may have been for an old javadoc location. You can find the
javadoc here:
https://commons.apache.org/proper/commons-rng/commons-rng-examples/commons-rng-examples-jmh/apidocs/index.html

I do not think it is very useful but at least it does show what we
have benchmarked. I will fix the link in the source.

Regards,

Alex
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.