Ada Reference ManualLegal Information
Contents   Index   References   Search   Previous   Next 

G.2.5 Performance Requirements for Random Number Generation

1
In the strict mode, the performance of Numerics.Float_Random and Numerics.Discrete_Random shall be as specified here. 

Implementation Requirements

2
Two different calls to the time-dependent Reset procedure shall reset the generator to different states, provided that the calls are separated in time by at least one second and not more than fifty years.
3
The implementation's representations of generator states and its algorithms for generating random numbers shall yield a period of at least 231–2; much longer periods are desirable but not required.
4
The implementations of Numerics.Float_Random.Random and Numerics.Discrete_Random.Random shall pass at least 85% of the individual trials in a suite of statistical tests. For Numerics.Float_Random, the tests are applied directly to the floating point values generated (i.e., they are not converted to integers first), while for Numerics.Discrete_Random they are applied to the generated values of various discrete types. Each test suite performs 6 different tests, with each test repeated 10 times, yielding a total of 60 individual trials. An individual trial is deemed to pass if the chi-square value (or other statistic) calculated for the observed counts or distribution falls within the range of values corresponding to the 2.5 and 97.5 percentage points for the relevant degrees of freedom (i.e., it shall be neither too high nor too low). For the purpose of determining the degrees of freedom, measurement categories are combined whenever the expected counts are fewer than 5. 

Contents   Index   References   Search   Previous   Next 
Ada-Europe Sponsored by Ada-Europe