hej
is hosted by
Hepforge
,
IPPP Durham
HEJ 2
2.0
High energy resummation for hadron colliders
Main Page
Related Pages
Namespaces
Namespace List
Namespace Members
All
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
r
s
t
u
v
w
z
Functions
a
f
g
h
i
j
l
m
n
o
p
r
s
t
Variables
Typedefs
Enumerations
Enumerator
b
c
d
e
f
g
h
l
m
n
p
s
t
u
w
z
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
a
b
c
d
e
f
h
i
j
l
m
n
o
p
r
s
t
u
v
w
~
Functions
a
c
d
e
f
h
i
j
l
m
n
o
p
r
s
t
u
v
w
~
Variables
a
b
c
d
e
f
h
i
j
l
m
n
o
p
r
s
t
u
v
w
Related Functions
Files
File List
File Members
All
c
h
j
m
o
Functions
c
j
m
o
Typedefs
Macros
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
include
HEJ
RNG.hh
Go to the documentation of this file.
1
12
#pragma once
13
14
#include <limits>
15
16
namespace
HEJ
{
17
19
struct
RNG
{
21
virtual
double
flat
() = 0;
22
24
virtual
unsigned
min
()
const
= 0;
26
virtual
unsigned
max
()
const
= 0;
28
virtual
unsigned
operator()
() = 0;
29
30
virtual
~RNG
() =
default
;
31
};
32
34
struct
DefaultRNG
:
virtual
RNG
{
35
unsigned
min
()
const override
{
36
return
0
u
;
37
}
38
unsigned
max
()
const override
{
39
return
std::numeric_limits<unsigned>::max() - 1;
40
}
41
unsigned
operator()
()
override
{
42
return
flat
()*std::numeric_limits<unsigned int>::max();
43
}
44
};
45
}
HEJ::pid::u
@ u
Definition:
PDG_codes.hh:26
HEJ
Main HEJ 2 Namespace.
Definition:
mainpage.dox:1
HEJ::DefaultRNG
Helper struct with default implementations.
Definition:
RNG.hh:34
HEJ::DefaultRNG::max
unsigned max() const override
Maximum number that can be generated.
Definition:
RNG.hh:38
HEJ::DefaultRNG::operator()
unsigned operator()() override
Generate random number in [min(), max()].
Definition:
RNG.hh:41
HEJ::DefaultRNG::min
unsigned min() const override
Minimum number that can be generated.
Definition:
RNG.hh:35
HEJ::RNG
Interface for random number generator.
Definition:
RNG.hh:19
HEJ::RNG::~RNG
virtual ~RNG()=default
HEJ::RNG::flat
virtual double flat()=0
Generate random number in (0,1].
HEJ::RNG::min
virtual unsigned min() const =0
Minimum number that can be generated.
HEJ::RNG::operator()
virtual unsigned operator()()=0
Generate random number in [min(), max()].
HEJ::RNG::max
virtual unsigned max() const =0
Maximum number that can be generated.
Generated by
1.9.1