org.apache.mahout.math.jet.random.engine
Class MersenneTwister

java.lang.Object
  extended by org.apache.mahout.math.PersistentObject
      extended by org.apache.mahout.math.jet.random.engine.RandomEngine
          extended by org.apache.mahout.math.jet.random.engine.MersenneTwister
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, DoubleFunction, IntFunction, UnaryFunction
Direct Known Subclasses:
MersenneTwister64

Deprecated. until unit tests are in place. Until this time, this class/interface is unsupported.

@Deprecated
public class MersenneTwister
extends RandomEngine

See Also:
Serialized Form

Constructor Summary
MersenneTwister()
          Deprecated. Constructs and returns a random number generator with a default seed, which is a constant.
MersenneTwister(java.util.Date d)
          Deprecated. Constructs and returns a random number generator seeded with the given date.
MersenneTwister(int seed)
          Deprecated. Constructs and returns a random number generator with the given seed.
 
Method Summary
 java.lang.Object clone()
          Deprecated. Returns a copy of the receiver; the copy will produce identical sequences.
protected  void nextBlock()
          Deprecated. Generates N words at one time.
 int nextInt()
          Deprecated. Returns a 32 bit uniformly distributed random number in the closed interval [Integer.MIN_VALUE,Integer.MAX_VALUE] (including Integer.MIN_VALUE and Integer.MAX_VALUE).
protected  void setSeed(int seed)
          Deprecated. Sets the receiver's seed.
 
Methods inherited from class org.apache.mahout.math.jet.random.engine.RandomEngine
apply, apply, makeDefault, nextDouble, nextFloat, nextLong, raw
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MersenneTwister

public MersenneTwister()
Deprecated. 
Constructs and returns a random number generator with a default seed, which is a constant. Thus using this constructor will yield generators that always produce exactly the same sequence. This method is mainly intended to ease testing and debugging.


MersenneTwister

public MersenneTwister(int seed)
Deprecated. 
Constructs and returns a random number generator with the given seed.


MersenneTwister

public MersenneTwister(java.util.Date d)
Deprecated. 
Constructs and returns a random number generator seeded with the given date.

Parameters:
d - typically new Date()
Method Detail

clone

public java.lang.Object clone()
Deprecated. 
Returns a copy of the receiver; the copy will produce identical sequences. After this call has returned, the copy and the receiver have equal but separate state.

Overrides:
clone in class PersistentObject
Returns:
a copy of the receiver.

nextBlock

protected void nextBlock()
Deprecated. 
Generates N words at one time.


nextInt

public int nextInt()
Deprecated. 
Returns a 32 bit uniformly distributed random number in the closed interval [Integer.MIN_VALUE,Integer.MAX_VALUE] (including Integer.MIN_VALUE and Integer.MAX_VALUE).

Specified by:
nextInt in class RandomEngine

setSeed

protected void setSeed(int seed)
Deprecated. 
Sets the receiver's seed. This method resets the receiver's entire internal state.



Copyright © 2008-2010 The Apache Software Foundation. All Rights Reserved.