Export (0) Print
Expand All


Constructs the distribution.

explicit normal_distribution(RealType mean = 0.0, RealType stddev = 1.0);

explicit normal_distribution(const param_type& parm);


The mean distribution parameter.


The stddev distribution parameter.


The parameter structure used to construct the distribution.

Precondition: 0.0 ≤ stddev

The first constructor constructs an object whose stored mean value holds the value mean and whose stored stddev value holds the value stddev.

The second constructor constructs an object whose stored parameters are initialized from parm. You can obtain and set the current parameters of an existing distribution by calling the param() member function.

Header: <random>

Namespace: std

© 2015 Microsoft