openmc.stats.Univariate

class openmc.stats.Univariate[source]

Probability distribution of a single random variable.

The Univariate class is an abstract class that can be derived to implement a specific probability distribution.

abstract sample(seed=None)[source]

Sample the univariate distribution

Parameters
  • n_samples (int) – Number of sampled values to generate

  • seed (int or None) – Initial random number seed.

Returns

A 1-D array of sampled values

Return type

numpy.ndarray