herwig
is hosted by
Hepforge
,
IPPP Durham
Herwig
7.2.1
MatrixElement
Matchbox
Phasespace
MatchboxRambo.h
1
// -*- C++ -*-
2
//
3
// MatchboxRambo.h is a part of Herwig - A multi-purpose Monte Carlo event generator
4
// Copyright (C) 2002-2019 The Herwig Collaboration
5
//
6
// Herwig is licenced under version 3 of the GPL, see COPYING for details.
7
// Please respect the MCnet academic guidelines, see GUIDELINES for details.
8
//
9
#ifndef Herwig_MatchboxRambo_H
10
#define Herwig_MatchboxRambo_H
11
//
12
// This is the declaration of the MatchboxRambo class.
13
//
14
15
#include "Herwig/MatrixElement/Matchbox/Phasespace/MatchboxPhasespace.h"
16
17
namespace
Herwig
{
18
19
using namespace
ThePEG
;
20
28
class
MatchboxRambo
:
public
MatchboxPhasespace
{
29
30
public
:
31
37
MatchboxRambo
();
38
42
virtual
~
MatchboxRambo
();
44
45
public
:
46
50
virtual
void
setXComb(tStdXCombPtr);
51
55
virtual
double
generateTwoToNKinematics(
const
double
*,
56
vector<Lorentz5Momentum>& momenta);
57
62
virtual
int
nDimPhasespace
(
int
nFinal)
const
{
63
if
( nFinal == 1 )
64
return
1;
65
return
4*nFinal;
66
}
67
68
protected
:
69
74
struct
ReshuffleEquation
{
75
76
typedef
double
ArgType;
77
typedef
Energy ValType;
78
79
static
double
aUnit() {
return
1.; }
80
static
Energy vUnit() {
return
1.*GeV; }
81
82
Energy operator() (
double
xi)
const
;
83
84
Energy w;
85
cPDVector::const_iterator dataBegin;
86
cPDVector::const_iterator dataEnd;
87
vector<Lorentz5Momentum>::const_iterator momentaBegin;
88
vector<Lorentz5Momentum>::const_iterator momentaEnd;
89
90
ReshuffleEquation
(Energy q,
91
cPDVector::const_iterator dBegin,
92
cPDVector::const_iterator dEnd,
93
vector<Lorentz5Momentum>::const_iterator mBegin,
94
vector<Lorentz5Momentum>::const_iterator mEnd)
95
: w(q),
96
dataBegin(dBegin), dataEnd(dEnd),
97
momentaBegin(mBegin),
98
momentaEnd(mEnd) {}
99
100
};
101
102
public
:
103
110
void
persistentOutput(
PersistentOStream
& os)
const
;
111
117
void
persistentInput(
PersistentIStream
& is,
int
version);
119
126
static
void
Init();
127
128
protected
:
129
136
virtual
IBPtr
clone()
const
;
137
142
virtual
IBPtr
fullclone()
const
;
144
145
146
// If needed, insert declarations of virtual function defined in the
147
// InterfacedBase class here (using ThePEG-interfaced-decl in Emacs).
148
149
150
private
:
151
156
MatchboxRambo
& operator=(
const
MatchboxRambo
&) =
delete
;
157
161
bool
needToReshuffle
;
162
167
bool
theMakeReferenceSample
;
168
172
map<cPDVector,ofstream*>
referenceSamples
;
173
177
ofstream*
referenceSample
;
178
182
void
dumpReference(
const
vector<Lorentz5Momentum>&,
double
)
const
;
183
184
};
185
186
}
187
188
#endif
/* Herwig_MatchboxRambo_H */
ThePEG::PersistentIStream
Herwig::MatchboxRambo::nDimPhasespace
virtual int nDimPhasespace(int nFinal) const
Return the number of random numbers required to produce a given multiplicity final state...
Definition:
MatchboxRambo.h:62
ThePEG::PersistentOStream
ThePEG::IBPtr
ThePEG::Ptr< InterfacedBase >::pointer IBPtr
Herwig::MatchboxRambo::theMakeReferenceSample
bool theMakeReferenceSample
True, if a reference sample of phasespace points should be generated.
Definition:
MatchboxRambo.h:167
Herwig::MatchboxPhasespace
MatchboxPhasespace defines an abstract interface to a phase space generator.
Definition:
MatchboxPhasespace.h:79
ThePEG
Herwig::MatchboxRambo::referenceSample
ofstream * referenceSample
The stream to fill for the reference sample.
Definition:
MatchboxRambo.h:177
Herwig::MatchboxRambo::referenceSamples
map< cPDVector, ofstream * > referenceSamples
Map processes to streams for reference samples.
Definition:
MatchboxRambo.h:172
Herwig::MatchboxRambo::needToReshuffle
bool needToReshuffle
Whether or not we need to reshuffle.
Definition:
MatchboxRambo.h:161
Herwig
-*- C++ -*-
Definition:
BasicConsistency.h:17
Herwig::MatchboxRambo::ReshuffleEquation
The function object defining the equation to be solved.
Definition:
MatchboxRambo.h:74
Herwig::MatchboxRambo
MatchboxRambo implements RAMBO phase space generation.
Definition:
MatchboxRambo.h:28
Generated on Sat Apr 11 2020 14:50:30 for Herwig by
1.8.13