umontreal.iro.lecuyer.rng
Class MRG32k3aL
- java.lang.Object
-
- umontreal.iro.lecuyer.rng.RandomStreamBase
-
- umontreal.iro.lecuyer.rng.MRG32k3aL
-
- All Implemented Interfaces:
- java.io.Serializable, java.lang.Cloneable, CloneableRandomStream, RandomStream
public class MRG32k3aL extends RandomStreamBase
The same generator asMRG32k3a, except here it is implemented with type long instead of double. (SeeMRG32k3afor more information.)- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor and Description MRG32k3aL()MRG32k3aL(java.lang.String name)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method and Description MRG32k3aLclone()Clones the current generator and return its copy.long[]getState()voidresetNextSubstream()Reinitializes the stream to the beginning of its next substream: Ng is computed, and Cg and Bg are set to Ng.voidresetStartStream()Reinitializes the stream to its initial state Ig: Cg and Bg are set to Ig.voidresetStartSubstream()Reinitializes the stream to the beginning of its current substream: Cg is set to Bg.static voidsetPackageSeed(long[] seed)voidsetSeed(long[] seed)java.lang.StringtoString()Returns a string containing the current state of this stream.java.lang.StringtoStringFull()-
Methods inherited from class umontreal.iro.lecuyer.rng.RandomStreamBase
formatState, formatStateFull, increasedPrecision, nextArrayOfDouble, nextArrayOfInt, nextDouble, nextInt
-
-
-
-
Constructor Detail
-
MRG32k3aL
public MRG32k3aL()
-
MRG32k3aL
public MRG32k3aL(java.lang.String name)
- Parameters:
name- name of the stream
-
-
Method Detail
-
setPackageSeed
public static void setPackageSeed(long[] seed)
- Parameters:
seed- array of 6 elements representing the seed
-
setSeed
public void setSeed(long[] seed)
- Parameters:
seed- array of 6 integers representing the new seed
-
resetStartStream
public void resetStartStream()
Description copied from interface:RandomStreamReinitializes the stream to its initial state Ig: Cg and Bg are set to Ig.- Specified by:
resetStartStreamin interfaceRandomStream- Specified by:
resetStartStreamin classRandomStreamBase
-
resetStartSubstream
public void resetStartSubstream()
Description copied from interface:RandomStreamReinitializes the stream to the beginning of its current substream: Cg is set to Bg.- Specified by:
resetStartSubstreamin interfaceRandomStream- Specified by:
resetStartSubstreamin classRandomStreamBase
-
resetNextSubstream
public void resetNextSubstream()
Description copied from interface:RandomStreamReinitializes the stream to the beginning of its next substream: Ng is computed, and Cg and Bg are set to Ng.- Specified by:
resetNextSubstreamin interfaceRandomStream- Specified by:
resetNextSubstreamin classRandomStreamBase
-
getState
public long[] getState()
- Returns:
- the current state of the generator
-
toString
public java.lang.String toString()
Description copied from interface:RandomStreamReturns a string containing the current state of this stream.- Specified by:
toStringin interfaceRandomStream- Specified by:
toStringin classRandomStreamBase- Returns:
- the state of the generator, formated as a string
-
toStringFull
public java.lang.String toStringFull()
- Returns:
- the detailed state of the generator, formatted as a string
-
clone
public MRG32k3aL clone()
Description copied from class:RandomStreamBaseClones the current generator and return its copy.- Specified by:
clonein interfaceCloneableRandomStream- Overrides:
clonein classRandomStreamBase- Returns:
- A deep copy of the current generator
-
-
DMelt 3.0 © DataMelt by jWork.ORG