Skip to main content

Normal

Base class: Distribution

Normal (Gaussian) distribution parameterized by mean (with default value 0.0) and stddev (with default value 1.0).

The probability density function with μ\mu representing the mean and σ\sigma representing the stddev is given by,

f(x∣μ,σ)=1σ2πexp⁡(−12(x−μσ)2)f(x | \mu, \sigma) = \frac{1}{\sigma\sqrt{2\pi}}\exp\left(-\frac{1}{2}\left(\frac{x-\mu}{\sigma}\right)^2\right)

Constructors​

Normal(const Normal distribution) -> Normal​

Copy constructor for Normal distribution.

Parameters​

  • distribution: Normal distribution to be copied

Symbols​

NameDescription
=Copy assignment operator for Normal distribution.

Members​

NameDescription
maxReturns the maximum possible value from the distribution
meanMean value
minReturns the minimum possible value from the distribution
sampleSample from distribution.
stddevStandard deviation