13 #ifndef ROOT_Math_StdEngine 14 #define ROOT_Math_StdEngine 26 template<
class Generator>
28 static std::string
Name() {
return "std_random_eng";}
32 static std::string
Name() {
return "std_minstd_rand";}
36 static std::string
Name() {
return "std_mt19937";}
40 static std::string
Name() {
return "std_mt19937_64";}
44 static std::string
Name() {
return "std_ranlux24";}
48 static std::string
Name() {
return "std_ranlux48";}
52 static std::string
Name() {
return "std_knuth_b";}
56 static std::string
Name() {
return "std_random_device";}
73 template <
class Generator>
80 typedef typename Generator::result_type
Result_t;
83 fCONS = 1./fGen.max();
87 void SetSeed(Result_t seed) { fGen.seed(seed);}
90 Result_t rndm = fGen();
91 if (rndm != 0)
return fCONS*rndm;
99 double operator() () {
107 static uint64_t
MaxInt() {
return Generator::max(); }
Namespace for new ROOT classes and functions.
static std::string Name()
static std::string Name()
static std::string Name()
static std::string Name()
static std::string Name()
static std::string Name()
static std::string Name()
Class to wrap engines fron the C++ standard random library in the ROOT Random interface.
Namespace for new Math classes and functions.
void SetSeed(Result_t seed)
static std::string Name()
Generator::result_type Result_t
static std::string Name()