Parameterise the ziggurat sampler test
authorAlex Herbert <aherbert@apache.org>
Fri, 27 Aug 2021 13:17:48 +0000 (14:17 +0100)
committerAlex Herbert <aherbert@apache.org>
Fri, 27 Aug 2021 14:02:58 +0000 (15:02 +0100)
commitc53aa0cc92595ca81ebfe67e7cc4284d6b9a3233
treed62e4f628d5ce6751fe8f775f236cddc086891db
parent10614f7c9b5ebc50c1ff0b4b6d01dc7fec28604c
Parameterise the ziggurat sampler test

Duplicate the test in the JMH module. This ensures all variations
correctly sample the distribution, i.e. changes do not introduce errors
in the algorithm.

This identified an error in ModifiedZigguratExponentialSamplerRecursion.
commons-rng-examples/examples-jmh/pom.xml
commons-rng-examples/examples-jmh/src/main/java/org/apache/commons/rng/examples/jmh/sampling/distribution/ZigguratSamplerPerformance.java
commons-rng-examples/examples-jmh/src/test/java/org/apache/commons/rng/examples/jmh/sampling/distribution/ZigguratSamplerTest.java [new file with mode: 0644]
commons-rng-sampling/src/test/java/org/apache/commons/rng/sampling/distribution/ZigguratSamplerTest.java