herwig
is hosted by
Hepforge
,
IPPP Durham
Herwig
7.3.0
MatrixElement
Hadron
MEQCD2to2Fast.h
1
// -*- C++ -*-
2
//
3
// MEQCD2to2Fast.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_MEQCD2to2Fast_H
10
#define HERWIG_MEQCD2to2Fast_H
11
//
12
// This is the declaration of the MEQCD2to2Fast class.
13
//
14
15
#include "Herwig/MatrixElement/HwMEBase.h"
16
#include "ThePEG/Repository/UseRandom.h"
17
18
namespace
Herwig
{
19
using namespace
ThePEG
;
20
using namespace
ThePEG::Helicity
;
21
31
class
MEQCD2to2Fast
:
public
HwMEBase
{
32
33
public
:
34
38
MEQCD2to2Fast
() :
_maxflavour
(5),
_process
(0),
_strictFlavourScheme
(false) {
39
massOption
(vector<unsigned int>(2,0));
40
}
41
48
virtual
unsigned
int
orderInAlphaS
()
const
;
49
54
virtual
unsigned
int
orderInAlphaEW
()
const
;
55
63
virtual
double
me2
()
const
;
64
68
virtual
Energy2
scale
()
const
;
69
73
virtual
void
getDiagrams
()
const
;
74
83
virtual
Selector<DiagramIndex>
diagrams
(
const
DiagramVector
& dv)
const
;
84
92
virtual
Selector<const ColourLines *>
93
colourGeometries
(tcDiagPtr diag)
const
;
95
96
97
public
:
98
105
void
persistentOutput
(
PersistentOStream
& os)
const
;
106
112
void
persistentInput
(
PersistentIStream
& is,
int
version);
114
121
static
void
Init
();
122
123
protected
:
124
132
double
gg2ggME
()
const
{
133
Energy2 u(
uHat
()),t(
tHat
()),s(
sHat
());
134
double
output = 9./4.*(3.-t*u/s/s-s*u/t/t-s*t/u/u);
135
double
flow[3]={(1.-u*t/s/s-s*t/u/u+t*t/s/u),
136
(1.-t*u/s/s-s*u/t/t+u*u/s/t),
137
(1.-t*s/u/u-u*s/t/t+s*s/u/t)};
138
_flow
= 1+
UseRandom::rnd3
(flow[0],flow[1],flow[2]);
139
double
diag[3]={(
sqr
(u)+
sqr
(t))/
sqr
(s),
140
(
sqr
(s)+
sqr
(u))/
sqr
(t),
141
(
sqr
(s)+
sqr
(t))/
sqr
(u)};
142
if
(
_flow
==1) diag[1]=0;
143
else
if
(
_flow
==2) diag[2]=0;
144
else
if
(
_flow
==3) diag[0]=0;
145
_diagram
=1+
UseRandom::rnd3
(diag[0],diag[1],diag[2]);
146
return
output;
147
}
148
152
double
gg2qqbarME
()
const
{
153
Energy2 u(
uHat
()),t(
tHat
()),s(
sHat
());
154
Energy4 u2(
sqr
(u)),t2(
sqr
(t)),s2(
sqr
(s));
155
double
output =(1./6./u/t-3./8./s2)*(t2+u2);
156
double
flow[2]={u2/(u2+t2),t2/(u2+t2)};
157
_flow
= 1+
UseRandom::rnd2
(flow[0],flow[1]);
158
_diagram
=3+
_flow
;
159
return
output;
160
}
161
165
double
qqbar2ggME
()
const
{
166
Energy2 u(
uHat
()),t(
tHat
()),s(
sHat
());
167
Energy4 s2(
sqr
(s)),u2(
sqr
(u)),t2(
sqr
(t));
168
double
output = 0.5*(32./27./u/t-8./3./s2)*(t2+u2);
169
double
flow[2] = {u2/(u2+t2),t2/(t2+u2)};
170
_flow
=1+
UseRandom::rnd2
(flow[0],flow[1]);
171
_diagram
=6+
_flow
;
172
return
output;
173
}
174
178
double
qg2qgME
()
const
{
179
Energy2 u(
uHat
()),t(
tHat
()),s(
sHat
());
180
Energy4 s2(
sqr
(s)),u2(
sqr
(u)),t2(
sqr
(t));
181
double
output = (-4./9./s/u+1./t2)*(s2+u2);
182
double
flow[2]={u2/(s2+u2),s2/(s2+u2)};
183
_flow
=1+
UseRandom::rnd2
(flow[0],flow[1]);
184
_diagram
=9+
_flow
;
185
return
output;
186
}
187
191
double
qbarg2qbargME
()
const
{
192
// scale
193
Energy2 u(
uHat
()),t(
tHat
()),s(
sHat
());
194
Energy4 u2(
sqr
(u)),s2(
sqr
(s));
// t2(sqr(t))
195
double
flow[2]={u2/(s2+u2),s2/(s2+u2)};
196
_flow
=1+
UseRandom::rnd2
(flow[0],flow[1]);
197
_diagram
=12+
_flow
;
198
return
(-4./9./s/u+1./t/t)*(s*s+u*u);
199
}
200
204
double
qq2qqME
()
const
{
205
Energy2 u(
uHat
()),t(
tHat
());
206
Energy4 s2(
sqr
(
sHat
())),u2(
sqr
(u)),t2(
sqr
(t));
207
double
output;
208
if
(
mePartonData
()[0]->
id
()==
mePartonData
()[1]->
id
()) {
209
output = 0.5*(4./9.*((s2+u2)/t2+(s2+t2)/u2)
210
-8./27.*s2/u/t);
211
double
flow[2]={(s2+u2)/t2,(s2+t2)/u2};
212
_flow
=1+
UseRandom::rnd2
(flow[0],flow[1]);
213
}
214
else
{
215
output = 4./9.*(s2+u2)/t2;
216
_flow
=2;
217
}
218
_diagram
= 15+
_flow
;
219
return
output;
220
}
221
225
double
qbarqbar2qbarqbarME
()
const
{
226
Energy2 u(
uHat
()),t(
tHat
());
227
Energy4 u2(
sqr
(u)),t2(
sqr
(t)),s2(
sqr
(
sHat
()));
228
double
output;
229
if
(
mePartonData
()[0]->
id
()==
mePartonData
()[1]->
id
()) {
230
output = 0.5*(4./9.*((s2+u2)/t2+(s2+t2)/u2)
231
-8./27.*s2/u/t);
232
double
flow[2]={(s2+u2)/t2,(s2+t2)/u2};
233
_flow
=1+
UseRandom::rnd2
(flow[0],flow[1]);
234
}
235
else
{
236
output = 4./9.*(s2+u2)/t2;
237
_flow
= 2;
238
}
239
_diagram
= 17+
_flow
;
240
// final part of colour and spin factors
241
return
output;
242
}
243
247
double
qqbar2qqbarME
()
const
{
248
// type of process
249
bool
diagon[2]={
mePartonData
()[0]->id()== -
mePartonData
()[1]->id(),
250
mePartonData
()[0]->id()==
mePartonData
()[2]->id()};
251
// scale
252
Energy2 u(
uHat
()),t(
tHat
()),s(
sHat
());
253
Energy4 s2(
sqr
(s)),t2(
sqr
(t)),u2(
sqr
(u));
254
double
output;
255
if
(diagon[0]&&diagon[1]) {
256
output= (4./9.*((s2+u2)/t2+(u2+t2)/s2)
257
-8./27.*u2/s/t);
258
double
flow[2]={(t2+u2)/s2,(s2+u2)/t2};
259
_flow
=1+
UseRandom::rnd2
(flow[0],flow[1]);
260
}
261
else
if
(diagon[0]) {
262
output = (4./9.*(t2+u2)/s2);
263
_flow
=1;
264
}
265
else
{
266
output = (4./9.*(s2+u2)/t2);
267
_flow
=2;
268
}
269
_diagram
=19+
_flow
;
270
return
output;
271
}
273
274
protected
:
275
282
virtual
IBPtr
clone
()
const
;
283
288
virtual
IBPtr
fullclone
()
const
;
290
291
protected
:
292
298
virtual
void
doinit
();
299
301
302
private
:
303
308
MEQCD2to2Fast
&
operator=
(
const
MEQCD2to2Fast
&) =
delete
;
309
310
private
:
311
315
unsigned
int
_maxflavour
;
316
320
unsigned
int
_process
;
321
325
mutable
unsigned
int
_flow
;
326
330
mutable
unsigned
int
_diagram
;
331
335
bool
_strictFlavourScheme
;
336
337
};
338
339
}
340
341
#endif
/* HERWIG_MEQCD2to2Fast_H */
Herwig::HwMEBase
The HwMEBase class serves a number of purposes.
Definition:
HwMEBase.h:35
Herwig::HwMEBase::uHat
Energy2 uHat() const
Return the of the last set phase space point.
Definition:
HwMEBase.h:176
Herwig::HwMEBase::tHat
Energy2 tHat() const
Return the of the last set phase space point.
Definition:
HwMEBase.h:171
Herwig::HwMEBase::massOption
void massOption(vector< unsigned int > iopt)
Set the treatment of the outgoing masses.
Definition:
HwMEBase.h:206
Herwig::MEQCD2to2Fast
The MEQCD2to2Fast class implements the matrix elements for QCD scattering processes using hard coded...
Definition:
MEQCD2to2Fast.h:31
Herwig::MEQCD2to2Fast::_strictFlavourScheme
bool _strictFlavourScheme
Exclude contributions with massive incominbg quarks.
Definition:
MEQCD2to2Fast.h:335
Herwig::MEQCD2to2Fast::gg2qqbarME
double gg2qqbarME() const
Matrix element for .
Definition:
MEQCD2to2Fast.h:152
Herwig::MEQCD2to2Fast::me2
virtual double me2() const
The matrix element for the kinematical configuration previously provided by the last call to setKinem...
Herwig::MEQCD2to2Fast::qg2qgME
double qg2qgME() const
Matrix element for .
Definition:
MEQCD2to2Fast.h:178
Herwig::MEQCD2to2Fast::qqbar2ggME
double qqbar2ggME() const
Matrix element for .
Definition:
MEQCD2to2Fast.h:165
Herwig::MEQCD2to2Fast::qq2qqME
double qq2qqME() const
Matrix element for .
Definition:
MEQCD2to2Fast.h:204
Herwig::MEQCD2to2Fast::qqbar2qqbarME
double qqbar2qqbarME() const
Matrix element for .
Definition:
MEQCD2to2Fast.h:247
Herwig::MEQCD2to2Fast::_process
unsigned int _process
Processes to include.
Definition:
MEQCD2to2Fast.h:320
Herwig::MEQCD2to2Fast::diagrams
virtual Selector< DiagramIndex > diagrams(const DiagramVector &dv) const
Get diagram selector.
Herwig::MEQCD2to2Fast::scale
virtual Energy2 scale() const
Return the scale associated with the last set phase space point.
Herwig::MEQCD2to2Fast::clone
virtual IBPtr clone() const
Make a simple clone of this object.
Herwig::MEQCD2to2Fast::_diagram
unsigned int _diagram
Diagram.
Definition:
MEQCD2to2Fast.h:330
Herwig::MEQCD2to2Fast::orderInAlphaS
virtual unsigned int orderInAlphaS() const
Return the order in in which this matrix element is given.
Herwig::MEQCD2to2Fast::operator=
MEQCD2to2Fast & operator=(const MEQCD2to2Fast &)=delete
The assignment operator is private and must never be called.
Herwig::MEQCD2to2Fast::gg2ggME
double gg2ggME() const
Members to calculate the matrix elements.
Definition:
MEQCD2to2Fast.h:132
Herwig::MEQCD2to2Fast::persistentInput
void persistentInput(PersistentIStream &is, int version)
Function used to read in object persistently.
Herwig::MEQCD2to2Fast::getDiagrams
virtual void getDiagrams() const
Add all possible diagrams with the add() function.
Herwig::MEQCD2to2Fast::_maxflavour
unsigned int _maxflavour
Maximum numbere of quark flavours to include.
Definition:
MEQCD2to2Fast.h:315
Herwig::MEQCD2to2Fast::colourGeometries
virtual Selector< const ColourLines * > colourGeometries(tcDiagPtr diag) const
Return a Selector with possible colour geometries for the selected diagram weighted by their relative...
Herwig::MEQCD2to2Fast::orderInAlphaEW
virtual unsigned int orderInAlphaEW() const
Return the order in in which this matrix element is given.
Herwig::MEQCD2to2Fast::doinit
virtual void doinit()
Initialize this object after the setup phase before saving an EventGenerator to disk.
Herwig::MEQCD2to2Fast::Init
static void Init()
The standard Init function used to initialize the interfaces.
Herwig::MEQCD2to2Fast::_flow
unsigned int _flow
Colour flow.
Definition:
MEQCD2to2Fast.h:325
Herwig::MEQCD2to2Fast::qbarg2qbargME
double qbarg2qbargME() const
Matrix elements for .
Definition:
MEQCD2to2Fast.h:191
Herwig::MEQCD2to2Fast::MEQCD2to2Fast
MEQCD2to2Fast()
The default constructor.
Definition:
MEQCD2to2Fast.h:38
Herwig::MEQCD2to2Fast::qbarqbar2qbarqbarME
double qbarqbar2qbarqbarME() const
Matrix element for .
Definition:
MEQCD2to2Fast.h:225
Herwig::MEQCD2to2Fast::fullclone
virtual IBPtr fullclone() const
Make a clone of this object, possibly modifying the cloned object to make it sane.
Herwig::MEQCD2to2Fast::persistentOutput
void persistentOutput(PersistentOStream &os) const
Function used to write out object persistently.
ThePEG::LastXCombInfo< StandardXComb >::mePartonData
const cPDVector & mePartonData() const
ThePEG::MEBase::DiagramVector
vector< DiagPtr > DiagramVector
ThePEG::MEBase::sHat
Energy2 sHat() const
ThePEG::PersistentIStream
ThePEG::PersistentOStream
ThePEG::Selector
ThePEG::UseRandom::rnd3
static int rnd3(double p0, double p1, double p2)
ThePEG::UseRandom::rnd2
static int rnd2(double p0, double p1)
Herwig
-*- C++ -*-
Definition:
BasicConsistency.h:17
ThePEG::Helicity
ThePEG
ThePEG::IBPtr
ThePEG::Ptr< InterfacedBase >::pointer IBPtr
ThePEG::sqr
constexpr auto sqr(const T &x) -> decltype(x *x)
Generated on Thu Jun 20 2024 17:50:52 for Herwig by
1.9.6