Click or drag to resize

Ran005 Class

Ran005: congruential with shuffle. Returns an integer random number uniformly distributed within [0,714024].

Notes: - NOT RECOMENDED FOR SERIOUS APPLICATIONS.

Inheritance Hierarchy
SystemObject
  Altaxo.Calc.Probability.OldRandomGenerator
    Altaxo.Calc.Probability.OldRan005

Namespace: Altaxo.Calc.Probability.Old
Assembly: AltaxoCore (in AltaxoCore.dll) Version: 4.8.3179.0 (4.8.3179.0)
Syntax
C#
public class Ran005 : RandomGenerator

The Ran005 type exposes the following members.

Constructors
 NameDescription
Public methodRan005Initializes a new instance of the Ran005 class
Public methodRan005(UInt32)Initializes a new instance of the Ran005 class
Top
Properties
 NameDescription
Public propertyMaximumThe maximum value of the random number which can be returned.
(Inherited from RandomGenerator)
Public propertySeedThe seed value.
(Inherited from RandomGenerator)
Top
Methods
 NameDescription
Public methodEqualsDetermines whether the specified object is equal to the current object.
(Inherited from Object)
Protected methodFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object)
Public methodGetHashCodeServes as the default hash function.
(Inherited from Object)
Public methodGetTypeGets the Type of the current instance.
(Inherited from Object)
Public methodLong
(Overrides RandomGeneratorLong)
Protected methodMemberwiseCloneCreates a shallow copy of the current Object.
(Inherited from Object)
Public methodToStringReturns a string that represents the current object.
(Inherited from Object)
Top
Fields
 NameDescription
Protected fieldmax_valUniform long int values within [0...max_val].
(Inherited from RandomGenerator)
Protected fieldseedThe seed of the random generator.
(Inherited from RandomGenerator)
Top
Remarks
C#
  Just use it for comparison purposes, etc.

     - As you see the spacing of the numbers is very coarse.

- Low order correlations are present.

     - The period is effectively infinite.

     - At least 32 bit long int is required.

     - Corresponds to generator "ran2" of
       W. H. Press, B. P. Flannery, S. A. Teukolsky, W. T. Vetterling,
       Numerical Recipies in C, Cambridge Univ. Press, 1988.

     - The generator is based upon
       D. H. Knuth: The Art of Computer Programming, Vol.2, 2nd ed., 1981.
See Also