jhplot.math.num.random
Class RandomRNG
- java.lang.Object
-
- jhplot.math.num.random.RandomRNG
-
-
Constructor Summary
Constructors Constructor and Description RandomRNG()Create a random number generator using a defaultRandomdelegate.RandomRNG(long seed)Create a random number generator using aRandomdelegate initialized with the given seed.RandomRNG(java.util.Random rng)Create a random number generator using the givenRandomdelegate.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description doublenextRandomNumber()Access the next random number from this generator.
-
-
-
Constructor Detail
-
RandomRNG
public RandomRNG()
Create a random number generator using a defaultRandomdelegate.
-
RandomRNG
public RandomRNG(long seed)
Create a random number generator using aRandomdelegate initialized with the given seed.- Parameters:
seed- the seed used to initialize theRandomdelegate.
-
RandomRNG
public RandomRNG(java.util.Random rng)
Create a random number generator using the givenRandomdelegate.- Parameters:
rng- theRandomdelegate.
-
-
Method Detail
-
nextRandomNumber
public double nextRandomNumber()
Access the next random number from this generator.- Specified by:
nextRandomNumberin interfaceRNG- Returns:
- the next random number.
-
-
DMelt 3.0 © DataMelt by jWork.ORG