public class AgentLocalRandom
extends java.util.Random
| Constructor and Description |
|---|
AgentLocalRandom() |
| Modifier and Type | Method and Description |
|---|---|
static AgentLocalRandom |
current()
Returns the current agent's AgentLocalRandom.
|
double |
nextDouble(double min,
double max)
Generates a random double.
|
double |
nextExp()
Generates an exponentially distributed random number with unit mean.
|
double |
nextExp(double lambda)
Generates an exponentially distributed random number with mean 1/lambda.
|
double |
nextGaussian(double mu,
double sigma2)
Generates a Gaussian distributed random number.
|
double |
nextRayleigh(double sigma)
Generates a Rayleigh distributed random number.
|
double |
nextRician(double nu,
double sigma)
Generates a Rician distributed random number.
|
static void |
setRootSeed(long seed)
Sets root random number generator seed.
|
public static AgentLocalRandom current()
public static void setRootSeed(long seed)
seed - random number seed.public double nextDouble(double min,
double max)
min - minimum value to generate.max - maximum value to generate.public double nextExp(double lambda)
lambda - rate parameter.public double nextExp()
public double nextGaussian(double mu,
double sigma2)
mu - mean of the distribution.sigma2 - variance of the distribution.public double nextRayleigh(double sigma)
sigma - scale parameter.public double nextRician(double nu,
double sigma)
nu - location parameter.sigma - scale parameter.