Random number generators#
Several interfaces to external algorithms are provided in the core and CepGenAddOns
libraries for the generation of random number according to some distributions of interests, and easily steerable through the randomGenerator
sequential block (in Python cards).
All modules are derived from a common cepgen::utils::RandomGenerator object, described below:
A full list of the algorithms and their parameters can be found here.
-
class RandomGenerator : public NamedModule<RandomGenerator>#
Subclassed by GSLRandomGenerator, STLRandomGenerator, RandomGenerator
Detailed description
-
class RandomGenerator : public NamedModule<RandomGenerator>
A random number generator.
- Author
L. Forthomme laurent.forthomme@cern.ch
- Date
Nov 2023
Subclassed by GSLRandomGenerator, STLRandomGenerator, RandomGenerator
Public Functions
-
explicit RandomGenerator(const ParametersList&)
Default constructor.
-
template<typename T>
inline T *engine() Retrieve the engine object.
-
inline const std::string &name() const
Module unique indexing name.
-
inline bool operator==(const SteeredObject &oth) const
Equality operator.
-
inline bool operator!=(const SteeredObject &oth) const
Inequality operator.
-
inline virtual const ParametersList ¶meters() const override
Module user-defined parameters.
-
inline virtual void setParameters(const ParametersList ¶ms) override
Set module parameters.
-
inline void setDescribedParameters(const ParametersList ¶ms_orig)
Set (documented) module parameters.
GSL random number generator#
Added in version 1.2.0.
-
class GSLRandomGenerator : public RandomGenerator#
ROOT random number generator#
Added in version 1.2.0.
-
class RandomGenerator : public RandomGenerator#
STL random number generator#
Added in version 1.2.0.
-
class STLRandomGenerator : public RandomGenerator#