public interface PseudoRandomStream
| Modifier and Type | Method and Description |
|---|---|
DoubleStream |
beta(double alpha,
double beta)
Returns an effectively unlimited stream of pseudorandomly chosen
Beta-distributed variates with shape parameters
alpha and
beta. |
DoubleStream |
beta(long streamSize,
double alpha,
double beta)
Returns a stream producing the given
streamSize number of
pseudorandomly chosen Beta-distributed variates with shape parameters
alpha and beta. |
DoubleStream |
cauchy(double location,
double scale)
Returns an effectively unlimited stream of pseudorandomly chosen
Cauchy-distributed variates with location parameter
location and
scale parameter scale. |
DoubleStream |
cauchy(long streamSize,
double location,
double scale)
Returns a stream producing the given
streamSize number of
pseudorandomly chosen Cauchy-distributed variates with location parameter
location and scale parameter scale. |
DoubleStream |
chiSquare(double k)
Returns an effectively unlimited stream of pseudorandomly chosen
Chi-squared distributed variates with
k degrees of freedom. |
DoubleStream |
chiSquare(long streamSize,
double k)
Returns a stream producing the given
streamSize number of
pseudorandomly chosen Chi-squared distributed variates with k
degrees of freedom. |
DoubleStream |
doubles()
Returns an effectively unlimited stream of pseudorandomly chosen
double values. |
DoubleStream |
doubles(double min,
double max)
Returns an effectively unlimited stream of pseudorandomly chosen
double values, where each value is between the specified min
(inclusive) and the specified max (inclusive). |
DoubleStream |
doubles(long streamSize)
Returns a stream producing the given
streamSize number of
pseudorandomly chosen double values. |
DoubleStream |
doubles(long streamSize,
double min,
double max)
Returns a stream producing the given
streamSize number of
pseudorandomly chosen double values, where each value is between
the specified min (inclusive) and the specified max (inclusive). |
DoubleStream |
exponential(double lambda)
Returns an effectively unlimited stream of pseudorandomly chosen
exponentially distributed variates with rate parameter
lambda. |
DoubleStream |
exponential(long streamSize,
double lambda)
Returns a stream producing the given
streamSize number of
exponentially distributed variates with rate parameter lambda. |
DoubleStream |
gamma(double k,
double theta)
Returns an effectively unlimited stream of pseudorandomly chosen
Gamma-distributed variates with shape parameter
k and scale
parameter theta. |
DoubleStream |
gamma(long streamSize,
double k,
double theta)
Returns a stream producing the given
streamSize number of
pseudorandomly chosen Gamma-distributed variates with shape parameter
k and scale parameter theta. |
IntStream |
ints()
Returns an effectively unlimited stream of pseudorandomly chosen
int values. |
IntStream |
ints(int min,
int max)
Returns an effectively unlimited stream of pseudorandomly chosen
int values, where each value is between the specified min
(inclusive) and the specified max (inclusive). |
IntStream |
ints(long streamSize)
Returns a stream producing the given
streamSize number of
pseudorandomly chosen int values. |
IntStream |
ints(long streamSize,
int min,
int max)
Returns a stream producing the given
streamSize number of
pseudorandomly chosen int values, where each value is between the
specified min (inclusive) and the specified max (inclusive). |
DoubleStream |
logNormal(double mu,
double sigma)
Returns an effectively unlimited stream of pseudorandomly chosen
Log-normal variates whose natural logarithm has expectation
mu
and standard deviation sigma. |
DoubleStream |
logNormal(long streamSize,
double mu,
double sigma)
Returns a stream producing the given
streamSize number of
pseudorandomly chosen Log-normal variates whose natural logarithm has
expectation mu and standard deviation sigma. |
LongStream |
longs()
Returns an effectively unlimited stream of pseudorandomly chosen
long values. |
LongStream |
longs(long streamSize)
Returns a stream producing the given
streamSize number of
pseudorandomly chosen long values. |
LongStream |
longs(long min,
long max)
Returns an effectively unlimited stream of pseudorandomly chosen
long values, where each value is between the specified min
(inclusive) and the specified max (inclusive). |
LongStream |
longs(long streamSize,
long min,
long max)
Returns a stream producing the given
streamSize number of
pseudorandomly chosen long values, where each value is between
the specified min (inclusive) and the specified max (inclusive). |
DoubleStream |
normal(double mu,
double sigma)
Returns an effectively unlimited stream of pseudorandomly chosen normal
variates with expectation
mu and standard deviation
sigma. |
DoubleStream |
normal(long streamSize,
double mu,
double sigma)
Returns a stream producing the given
streamSize number of
pseudorandomly chosen normal variates with expectation mu and
standard deviation sigma. |
DoubleStream |
studentT(double df)
Returns an effectively unlimited stream of pseudorandomly chosen StudentT
distributed variates with
df degrees of freedom. |
DoubleStream |
studentT(long streamSize,
double df)
Returns a stream producing the given
streamSize number of
pseudorandomly chosen StudentT distributed variates with df
degrees of freedom. |
DoubleStream |
weibull(double scale,
double shape)
Returns an effectively unlimited stream of pseudorandomly chosen Weibull
distributed variates with parameters
scale and shape. |
DoubleStream |
weibull(long streamSize,
double scale,
double shape)
Returns a stream producing the given
streamSize number of
pseudorandomly chosen Weibull distributed variates with parameters
scale and shape. |
IntStream ints()
int values.int valuesIntStream ints(long streamSize)
streamSize number of
pseudorandomly chosen int values.streamSize - the number of values to generateint valuesIllegalArgumentException - if streamSize is less than zeroIntStream ints(long streamSize, int min, int max)
streamSize number of
pseudorandomly chosen int values, where each value is between the
specified min (inclusive) and the specified max (inclusive).streamSize - the number of values to generatemin - the smallest value that can be producedmax - the largest value that can be producedint values, each
between the specified min (inclusive) and the specified max
(inclusive)IllegalArgumentException - if streamSize is less than zero, or min is
greater than maxIntStream ints(int min, int max)
int values, where each value is between the specified min
(inclusive) and the specified max (inclusive).min - the smallest value that can be producedmax - the largest value that can be producedint values, each
between the specified min (inclusive) and the specified max
(inclusive)IllegalArgumentException - if min is greater than maxLongStream longs()
long values.long valuesLongStream longs(long streamSize)
streamSize number of
pseudorandomly chosen long values.streamSize - the number of values to generatelong valuesIllegalArgumentException - if streamSize is less than zeroLongStream longs(long streamSize, long min, long max)
streamSize number of
pseudorandomly chosen long values, where each value is between
the specified min (inclusive) and the specified max (inclusive).streamSize - the number of values to generatemin - the smallest value that can be producedmax - the largest value that can be producedlong values, each
between the specified min (inclusive) and the specified max
(inclusive)IllegalArgumentException - if streamSize is less than zero, or min is
greater than maxLongStream longs(long min, long max)
long values, where each value is between the specified min
(inclusive) and the specified max (inclusive).min - the smallest value that can be producedmax - the largest value that can be producedlong values, each
between the specified min (inclusive) and the specified max
(inclusive)IllegalArgumentException - if min is greater than maxDoubleStream doubles()
double values.double valuesDoubleStream doubles(long streamSize)
streamSize number of
pseudorandomly chosen double values.streamSize - the number of values to generatedouble valuesIllegalArgumentException - if streamSize is less than zeroDoubleStream doubles(long streamSize, double min, double max)
streamSize number of
pseudorandomly chosen double values, where each value is between
the specified min (inclusive) and the specified max (inclusive).streamSize - the number of values to generatemin - the smallest value that can be producedmax - the largest value that can be produceddouble values, each
between the specified min and the specified maxIllegalArgumentException - if streamSize is less than zero, or min is
not finite, or max is not finite, or min is
greater than maxDoubleStream doubles(double min, double max)
double values, where each value is between the specified min
(inclusive) and the specified max (inclusive).min - the smallest value that can be producedmax - the largest value that can be produceddouble values, each
between the specified min and the specified maxIllegalArgumentException - if min is not finite, or max is not finite,
or min is greater than maxDoubleStream normal(double mu, double sigma)
mu and standard deviation
sigma.mu - the expectation of the normal variatesigma - the standard deviation of the normal variateIllegalArgumentException - if sigma is not greater than zeroDoubleStream normal(long streamSize, double mu, double sigma)
streamSize number of
pseudorandomly chosen normal variates with expectation mu and
standard deviation sigma.streamSize - the number of values to generatemu - the expectation of the normal variatesigma - the standard deviation of the normal variateIllegalArgumentException - if streamSize is less than zero, or sigma is
not greater than zeroDoubleStream cauchy(double location, double scale)
location and
scale parameter scale.location - the location parameter of the Cauchy distributionscale - the scale parameter of the Cauchy distributionIllegalArgumentException - if scale is not greater than zeroDoubleStream cauchy(long streamSize, double location, double scale)
streamSize number of
pseudorandomly chosen Cauchy-distributed variates with location parameter
location and scale parameter scale.streamSize - the number of values to generatelocation - the location parameter of the Cauchy distributionscale - the scale parameter of the Cauchy distributionIllegalArgumentException - if streamSize is less than zero, or scale is
not greater than zeroDoubleStream exponential(double lambda)
lambda.lambda - the rate parameter lambda of the Exponential
distributionlambdaIllegalArgumentException - if lambda is not greater than zeroDoubleStream exponential(long streamSize, double lambda)
streamSize number of
exponentially distributed variates with rate parameter lambda.streamSize - the number of values to generatelambda - the rate parameter lambda of the Exponential
distributionlambdaIllegalArgumentException - if streamSize is less than zero, or lambda is
not greater than zeroDoubleStream gamma(double k, double theta)
k and scale
parameter theta.k - the shape parameter of the Gamma distributiontheta - the scale parameter of the Gamma distributionk and scale parameter thetaIllegalArgumentException - if k is not greater than zero, or theta is
not greater than zeroDoubleStream gamma(long streamSize, double k, double theta)
streamSize number of
pseudorandomly chosen Gamma-distributed variates with shape parameter
k and scale parameter theta.streamSize - the number of values to generatek - the shape parameter of the Gamma distributiontheta - the scale parameter of the Gamma distributionk and scale parameter thetaIllegalArgumentException - if streamSize is less than zero, or k is not
greater than zero, or theta is not greater than zeroDoubleStream beta(double alpha, double beta)
alpha and
beta.alpha - the shape parameter alpha of the Beta distributionbeta - the shape parameter beta of the Beta distributionalpha and betaIllegalArgumentException - if alpha is not greater than zero, or beta is
not greater than zeroDoubleStream beta(long streamSize, double alpha, double beta)
streamSize number of
pseudorandomly chosen Beta-distributed variates with shape parameters
alpha and beta.streamSize - the number of values to generatealpha - the shape parameter alpha of the Beta distributionbeta - the shape parameter beta of the Beta distributionalpha and betaIllegalArgumentException - if streamSize is less than zero, or alpha is
not greater than zero, or beta is not greater than
zeroDoubleStream chiSquare(double k)
k degrees of freedom.k - the number of degrees of freedomk degrees of freedomIllegalArgumentException - if k is not greater than zeroDoubleStream chiSquare(long streamSize, double k)
streamSize number of
pseudorandomly chosen Chi-squared distributed variates with k
degrees of freedom.streamSize - the number of values to generatek - the number of degrees of freedomk degrees of freedomIllegalArgumentException - if streamSize is less than zero, or k is not
greater than zeroDoubleStream logNormal(double mu, double sigma)
mu
and standard deviation sigma.mu - the expectation of the natural logarithm of the Log-normal
variatesigma - the standard deviation of the natural logarithm of the
Log-normal variateIllegalArgumentException - if sigma is not greater than zeroDoubleStream logNormal(long streamSize, double mu, double sigma)
streamSize number of
pseudorandomly chosen Log-normal variates whose natural logarithm has
expectation mu and standard deviation sigma.streamSize - the number of values to generatemu - the expectation of the natural logarithm of the Log-normal
variatesigma - the standard deviation of the natural logarithm of the
Log-normal variateIllegalArgumentException - if streamSize is less than zero, or sigma is
not greater than zeroDoubleStream studentT(double df)
df degrees of freedom.df - degrees of freedomdf degrees of freedomIllegalArgumentException - if df is not greater than zeroDoubleStream studentT(long streamSize, double df)
streamSize number of
pseudorandomly chosen StudentT distributed variates with df
degrees of freedom.streamSize - the number of values to generatedf - degrees of freedomdf degrees of freedomIllegalArgumentException - if streamSize is less than zero, or df is not
greater than zeroDoubleStream weibull(double scale, double shape)
scale and shape.scale - the scale parameter of the Weibull distributionshape - the shape parameter of the Weibull distributionscale and shapeIllegalArgumentException - if scale and shape are not greater than zeroDoubleStream weibull(long streamSize, double scale, double shape)
streamSize number of
pseudorandomly chosen Weibull distributed variates with parameters
scale and shape.streamSize - the number of values to generatescale - the scale parameter of the Weibull distributionshape - the shape parameter of the Weibull distributionscale and shapeIllegalArgumentException - if streamSize is less than zero, or scale and
shape are not greater than zeroCopyright © 2022. All rights reserved.