|
BlockFrequencyTest (Block Frequency Random Test) |
|
|
| BlockFrequencyTest Class |
|
|
|
|
Derived class from: BaseRandomTest
Implements the BlockFrequency random test.
The class contains:
Constructors & Destructor
Initializer methods
Class methods
Specific Class methods
Class Constructors & Destructor
|
|
|
BlockFrequencyTest (); |
| |
|
Creates an object of the class, sets the default values for members
and creates the MathematicalFunctions object needed to execute the random test.
|
|
|
|
BlockFrequencyTest (MathematicalFunctions* functions); |
| |
|
|
|
|
|
~BlockFrequencyTest (); |
| |
|
|
|
|
|
void SetAlpha (double alpha); [ Inherited from BaseRandomTest ] |
| |
|
Sets the alpha value for the random test object.
Alpha is the significance level that determines the region of acceptance and rejection.
For example, if alpha is set to >= 0,001 then we are demanding a confidence level of 99,9%.
|
|
|
|
bool IsRandom (BaseCryptoRandomStream* stream); [ Overridden, BaseRandomTest virtual method defined ] |
| |
|
Performs the specific randomness test.
Checks randomness of BaseCryptoRandomStream stream parameter and returns 0 (false randomness) or 1 (true randomness).
|
|
|
|
double GetPValue (void); [ Inherited from BaseRandomTest ]
|
| |
|
Gets PValue of the last checked BaseCryptoRandomStream .
PValue is the probability that a perfect random number generator would have produced a sequence less random than the BaseCryptoRandomStream checked, given the kind of non-randomness assessed by the test.
|
|
|
|
double GetAlpha (void); [ Inherited from BaseRandomTest ]
|
| |
|
Gets the alpha of the random test object.
|
|
|
|
RandomTests GetType (void); [ Overridden, BaseRandomTest virtual method defined ] |
| |
|
Gets the random test type (the algorithm that implements) of the object.
Returns the corresponding RandomTests value.
|
|
|
|
unsigned int GetMinimumLength (void); [ Overridden, BaseRandomTest virtual method defined ] |
| |
|
Gets the minimum length that the BaseCryptoRandomStream must have in order to perform the random test.
|
|
|
|
void SetBlockLength (unsigned int length);
|
| |
|
Sets the block length length. |
|
|
|
unsigned int GetBlockLength (void);
|
| |
|
Gets the block length. |
|
|
|
double GetChiSquared (void);
|
| |
|
Gets chiSquared. |
|
|
|
int GetBlockNumber (void);
|
| |
|
Gets blocks number that has been tested. |
|
|
|
int GetBitsDiscarded (void);
|
| |
|
Gets the number of bits discarded, that has not been not tested. |
You can check the page Used Symbols for an explanation of the symbols near the information.
|
|
|