Package org.drip.sequence.random
Class BoxMullerGaussian
java.lang.Object
org.drip.sequence.random.UnivariateSequenceGenerator
org.drip.sequence.random.BoxMullerGaussian
- Direct Known Subclasses:
BoundedGaussian
public class BoxMullerGaussian extends UnivariateSequenceGenerator
BoxMullerGaussian implements the Univariate Gaussian Random Number Generator.
- Module = Numerical Core Module
- Library = Statistical Learning Library
- Project = Sequence
- Package = Random
- Author:
- Lakshmi Krishnamurthy
-
Constructor Summary
Constructors Constructor Description BoxMullerGaussian(double dblMean, double dblVariance)
BoxMullerGaussian Constructor -
Method Summary
Methods inherited from class org.drip.sequence.random.UnivariateSequenceGenerator
sequence, sequence
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
BoxMullerGaussian
public BoxMullerGaussian(double dblMean, double dblVariance) throws java.lang.ExceptionBoxMullerGaussian Constructor- Parameters:
dblMean
- The MeandblVariance
- The Variance- Throws:
java.lang.Exception
- Thrown if the Inputs are Invalid
-
-
Method Details
-
mean
public double mean()Retrieve the Mean of the Box-Muller Gaussian- Returns:
- Mean of the Box-Muller Gaussian
-
variance
public double variance()Retrieve the Variance of the Box-Muller Gaussian- Returns:
- Variance of the Box-Muller Gaussian
-
random
public double random()Description copied from class:UnivariateSequenceGenerator
Generate a Random Number according to the specified rule- Specified by:
random
in classUnivariateSequenceGenerator
- Returns:
- The Random Number
-