SSJ
V. 2.6.

umontreal.iro.lecuyer.randvar
Class NormalInverseGaussianIGGen

java.lang.Object
  extended by umontreal.iro.lecuyer.randvar.RandomVariateGen
      extended by umontreal.iro.lecuyer.randvar.NormalInverseGaussianGen
          extended by umontreal.iro.lecuyer.randvar.NormalInverseGaussianIGGen

public class NormalInverseGaussianIGGen
extends NormalInverseGaussianGen

. This class implements a (NIG) random variate generator by using a normal generator (N) and an inverse gaussian generator (IG), as described in the following

Y IG(δ/γ, δ2)  
X | (Y = y) N(μ + βy, y).  

The normal N(μ, σ2) has mean μ and variance σ2, while the inverse gaussian has the parametrization described inInverseGaussianGen. If γ = (α^2 - β^2)1/2 with 0 <= | β| < α and δ > 0, then XNIG(α, β, μ, δ).


Constructor Summary
NormalInverseGaussianIGGen(InverseGaussianGen ig, NormalGen ng, double beta, double mu)
          Creates a random variate generator with parameters α, β = beta, μ = mu and δ, using generators ig and ng, as described above.
 
Method Summary
 double nextDouble()
          Generates a random number from the continuous distribution contained in this object.
static double nextDouble(InverseGaussianGen ig, NormalGen ng, double beta, double mu)
          Generates a new variate from the distribution with parameters α, β = beta, μ = mu and δ, using generators ig and ng, as described in eq..
 
Methods inherited from class umontreal.iro.lecuyer.randvar.NormalInverseGaussianGen
getAlpha, getBeta, getDelta, getMu, nextDouble, setParams
 
Methods inherited from class umontreal.iro.lecuyer.randvar.RandomVariateGen
getDistribution, getStream, nextArrayOfDouble, setStream, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

NormalInverseGaussianIGGen

public NormalInverseGaussianIGGen(InverseGaussianGen ig,
                                  NormalGen ng,
                                  double beta,
                                  double mu)
Creates a random variate generator with parameters α, β = beta, μ = mu and δ, using generators ig and ng, as described above. The parameters α and δ are included in generator ig.

Method Detail

nextDouble

public static double nextDouble(InverseGaussianGen ig,
                                NormalGen ng,
                                double beta,
                                double mu)
Generates a new variate from the distribution with parameters α, β = beta, μ = mu and δ, using generators ig and ng, as described in eq.. The parameters α and δ are included in generator ig.


nextDouble

public double nextDouble()
Description copied from class: RandomVariateGen
Generates a random number from the continuous distribution contained in this object. By default, this method uses inversion by calling the inverseF method of the distribution object. Alternative generating methods are provided in subclasses.

Overrides:
nextDouble in class RandomVariateGen
Returns:
the generated value

SSJ
V. 2.6.

To submit a bug or ask questions, send an e-mail to Pierre L'Ecuyer.