Class Random

java.lang.Object
  |
  +--Random

public class Random
extends java.lang.Object


Constructor Summary
Random()
          Initializes a sequence of uniformly distributed quasi random numbers with a seed based on the system clock.
Random(double left, double right)
          Initializes a sequence of uniformly distributed quasi random numbers on a given half-open interval [left,right) with a seed based on the system clock.
Random(int seed)
          Initializes a sequence of uniformly distributed quasi random numbers with a given seed.
Random(int seed, double left, double right)
          Initializes a sequence of uniformly distributed quasi random numbers with a given seed on a given half-open interval [left,right).
 
Method Summary
 double nextDouble()
          Returns the next random number in the sequence.
 void nextDoubles(double[] x)
          Returns the next N random numbers in the sequence, as a vector.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Random

public Random()
Initializes a sequence of uniformly distributed quasi random numbers with a seed based on the system clock.


Random

public Random(double left,
              double right)
Initializes a sequence of uniformly distributed quasi random numbers on a given half-open interval [left,right) with a seed based on the system clock.


Random

public Random(int seed)
Initializes a sequence of uniformly distributed quasi random numbers with a given seed.


Random

public Random(int seed,
              double left,
              double right)
Initializes a sequence of uniformly distributed quasi random numbers with a given seed on a given half-open interval [left,right).

Method Detail

nextDouble

public final double nextDouble()
Returns the next random number in the sequence.


nextDoubles

public final void nextDoubles(double[] x)
Returns the next N random numbers in the sequence, as a vector.