|
SSJ V. 2.6. |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object umontreal.iro.lecuyer.randvar.RandomVariateGen umontreal.iro.lecuyer.randvar.NormalGen umontreal.iro.lecuyer.randvar.NormalInverseFromDensityGen
public class NormalInverseFromDensityGen
This class implements normal random variate generators
using numerical inversion of the normal density
as described in. It makes use of the class
InverseDistFromDensity
.
A set of tables are precomputed to speed up the generation of normal random
variables by numerical inversion. This will be useful if one
wants to generate a large number of random variables.
Constructor Summary | |
---|---|
NormalInverseFromDensityGen(RandomStream stream,
double mu,
double sigma,
double ueps,
int order)
Creates a normal random variate generator with parameters μ = mu and σ = sigma, using stream stream. |
|
NormalInverseFromDensityGen(RandomStream stream,
InverseDistFromDensity dist)
Creates a new normal generator using the normal distribution dist and stream stream. |
|
NormalInverseFromDensityGen(RandomStream stream,
NormalDist dist,
double ueps,
int order)
Similar to the first constructor, with the normal distribution dist. |
Method Summary | |
---|---|
int |
getOrder()
Returns the order of the interpolating polynomial. |
double |
getUepsilon()
Returns the u-resolution ueps. |
Methods inherited from class umontreal.iro.lecuyer.randvar.NormalGen |
---|
getMu, getSigma, nextDouble |
Methods inherited from class umontreal.iro.lecuyer.randvar.RandomVariateGen |
---|
getDistribution, getStream, nextArrayOfDouble, nextDouble, setStream, toString |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public NormalInverseFromDensityGen(RandomStream stream, double mu, double sigma, double ueps, int order)
public NormalInverseFromDensityGen(RandomStream stream, NormalDist dist, double ueps, int order)
public NormalInverseFromDensityGen(RandomStream stream, InverseDistFromDensity dist)
getDistribution
,
after using one of the other constructors to create the
precomputed tables. This is useful when one needs many generators
using the same normal distribution.
Precomputing tables for numerical inversion is
costly; thus using only one set of tables for many generators
is more efficient. The first NormalInverseFromDensityGen
generator
using the other constructors creates the precomputed tables.
Then all other streams use this constructor with the same set of tables.
Method Detail |
---|
public double getUepsilon()
public int getOrder()
|
SSJ V. 2.6. |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |