herwig
is hosted by
Hepforge
,
IPPP Durham
Herwig
7.3.0
Hadronization
ColourReconnector.h
1
// -*- C++ -*-
2
//
3
// ColourReconnector.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_ColourReconnector_H
10
#define HERWIG_ColourReconnector_H
11
12
#include <ThePEG/Interface/Interfaced.h>
13
#include "CluHadConfig.h"
14
#include "ColourReconnector.fh"
15
16
namespace
Herwig
{
17
18
19
using namespace
ThePEG
;
20
36
class
ColourReconnector
:
public
Interfaced
{
37
38
public
:
39
46
void
rearrange
(
ClusterVector
& clusters);
47
48
using
CluVecIt = ClusterVector::iterator;
49
50
private
:
51
59
Energy2
_clusterMassSum
(
const
PVector
& q,
const
PVector
& aq)
const
;
60
61
62
70
double
_displacement
(
tcPPtr
p,
tcPPtr
q)
const
;
71
72
96
double
_displacementBaryonic
(
tcPPtr
p1,
tcPPtr
p2,
tcPPtr
p3)
const
;
97
98
106
bool
_containsColour8
(
const
ClusterVector
& cv,
const
vector<size_t> & P)
const
;
107
113
void
_doRecoStatistical
(
ClusterVector
& cv)
const
;
114
119
void
_doRecoPlain
(
ClusterVector
& cv)
const
;
120
121
125
void
_doRecoBaryonic
(
ClusterVector
& cv)
const
;
126
127
135
void
_doRecoBaryonicMesonic
(
ClusterVector
& cv)
const
;
136
137
138
139
140
void
_makeBaryonicClusters(ClusterPtr &c1, ClusterPtr &c2, ClusterPtr &c3,
141
ClusterPtr &newcluster1, ClusterPtr &newcluster2)
const
;
142
143
156
CluVecIt
_findRecoPartner
(CluVecIt cl,
ClusterVector
& cv)
const
;
157
158
CluVecIt _findPartnerRapidity(CluVecIt cl,
ClusterVector
& cv)
const
;
159
160
CluVecIt _findPartnerBaryonic(CluVecIt cl,
ClusterVector
& cv,
161
bool
& tetraCand,
162
const
ClusterVector
& a,
163
CluVecIt &baryonic1,
164
CluVecIt &baryonic2 )
const
;
165
176
void
_findbestreconnectionoption
(std::vector<CluVecIt> &cls,
177
const
unsigned
&baryonic,
178
string
&kind_of_reco,
179
int
(&reco_info)[3])
const
;
180
187
pair <ClusterPtr,ClusterPtr>
_reconnect
(ClusterPtr &c1, ClusterPtr &c2)
const
;
188
199
pair <ClusterPtr,ClusterPtr>
_reconnect2Bto2B
(ClusterPtr &c1, ClusterPtr &c2,
const
int
s1,
const
int
s2)
const
;
200
212
std::tuple <ClusterPtr, ClusterPtr, ClusterPtr>
_reconnectBbarBto3M
(ClusterPtr &c1, ClusterPtr &c2,
const
int
s0,
const
int
s1,
const
int
s2 )
const
;
213
225
std::tuple <ClusterPtr, ClusterPtr, ClusterPtr>
_reconnect3Mto3M
(ClusterPtr &c1, ClusterPtr &c2, ClusterPtr &c3,
const
int
infos[3] )
const
;
226
227
243
pair <ClusterPtr, ClusterPtr>
_reconnectMBtoMB
(ClusterPtr &c1, ClusterPtr &c2,
const
int
s0)
const
;
244
245
246
247
261
bool
_clustersFarApart
(
const
std::vector<CluVecIt> & clu )
const
;
262
268
void
_doReco2BeamClusters
(
ClusterVector
& cv)
const
;
269
270
277
void
_2Bto2BreconnectionFinder
(ClusterPtr &c1, ClusterPtr &c2,
int
&bswap1,
int
&bswap2,
double
mindisplsum,
string
&kind_of_reco )
const
;
278
285
void
_BbarBto3MreconnectionFinder
(ClusterPtr &c1, ClusterPtr &c2,
int
&mswap0,
int
&mswap1,
int
&mswap2,
286
double
min_displ_sum,
string
& kind_of_reco)
const
;
287
294
void
_BMtoBMreconnectionfinder
(ClusterPtr &c1, ClusterPtr &c2,
int
&swap,
295
double
min_displ_sum,
string
&kind_of_reco)
const
;
296
303
void
_3MtoXreconnectionfinder
(std::vector<CluVecIt> &cv,
int
&swap0,
int
&swap1,
304
int
&swap2,
double
min_displ_sum,
string
&kind_of_reco)
const
;
305
316
pair <int,int>
317
_shuffle
(
const
PVector
& q,
const
PVector
& aq,
unsigned
maxtries = 10)
const
;
318
319
325
int
_algorithm
= 0;
326
330
int
_clreco
= 0;
331
335
int
_debug
= 0;
336
350
int
_junctionMBCR
= 1;
351
358
double
_initTemp
= 0.01;
359
365
double
_annealingFactor
= 0.21;
366
371
unsigned
int
_annealingSteps
= 10;
372
378
double
_triesPerStepFactor
= 0.66;
379
384
double
_preco
= 0.5;
385
390
double
_precoBaryonic
= 0.5;
391
398
double
_preco3M_3M
= 0.5;
399
405
double
_preco3M_BBbar
= 0.5;
406
412
double
_precoBbarB_3M
= 0.5;
413
420
double
_preco2B_2B
= 0.5;
421
428
double
_precoMB_MB
= 0.5;
429
435
double
_stepFactor
= 5.0;
436
440
double
_mesonToBaryonFactor
= 2.0;
441
446
Length
_maxDistance
= femtometer;
447
452
bool
_isColour8
(
tcPPtr
p,
tcPPtr
q)
const
;
453
457
unsigned
int
_octetOption
= 0;
458
462
int
_cr2BeamClusters
= 0;
463
468
int
_prePlainCR
= 0;
469
474
int
_localCR
= 0;
475
480
int
_causalCR
= 0;
481
482
public
:
483
490
void
persistentOutput
(
PersistentOStream
& os)
const
;
491
497
void
persistentInput
(
PersistentIStream
& is,
int
version);
499
503
static
void
Init
();
504
505
protected
:
506
513
virtual
IBPtr
clone
()
const
;
514
519
virtual
IBPtr
fullclone
()
const
;
521
522
523
private
:
524
528
ColourReconnector
&
operator=
(
const
ColourReconnector
&) =
delete
;
529
530
531
};
532
533
534
}
535
536
#endif
/* HERWIG_ColourReconnector_H */
537
Herwig::ColourReconnector
Class for changing colour reconnections of partons.
Definition:
ColourReconnector.h:36
Herwig::ColourReconnector::_preco
double _preco
Probability that a found reconnection possibility is actually accepted.
Definition:
ColourReconnector.h:384
Herwig::ColourReconnector::_doRecoStatistical
void _doRecoStatistical(ClusterVector &cv) const
A Metropolis-type algorithm which finds a local minimum in the total sum of cluster masses @arguments...
Herwig::ColourReconnector::_doRecoPlain
void _doRecoPlain(ClusterVector &cv) const
Plain colour reconnection as used in Herwig 2.5.0 @arguments cv cluster vector.
Herwig::ColourReconnector::_debug
int _debug
Do we want debug informations?
Definition:
ColourReconnector.h:335
Herwig::ColourReconnector::_causalCR
int _causalCR
Option for colour reconnecting Clusters only if their spacetime difference is bigger than 0.
Definition:
ColourReconnector.h:480
Herwig::ColourReconnector::_annealingSteps
unsigned int _annealingSteps
Statistical Reco: Number of temperature steps in the statistical annealing algorithm.
Definition:
ColourReconnector.h:371
Herwig::ColourReconnector::_isColour8
bool _isColour8(tcPPtr p, tcPPtr q) const
Herwig::ColourReconnector::_reconnect
pair< ClusterPtr, ClusterPtr > _reconnect(ClusterPtr &c1, ClusterPtr &c2) const
Reconnects the constituents of the given clusters to the (only) other possible cluster combination.
Herwig::ColourReconnector::_octetOption
unsigned int _octetOption
Option for handling octets.
Definition:
ColourReconnector.h:457
Herwig::ColourReconnector::_reconnectBbarBto3M
std::tuple< ClusterPtr, ClusterPtr, ClusterPtr > _reconnectBbarBto3M(ClusterPtr &c1, ClusterPtr &c2, const int s0, const int s1, const int s2) const
Reconnects (B,Bbar->3M) the constituents of the given clusters to another possible cluster combinatio...
Herwig::ColourReconnector::fullclone
virtual IBPtr fullclone() const
Make a clone of this object, possibly modifying the cloned object to make it sane.
Herwig::ColourReconnector::_clustersFarApart
bool _clustersFarApart(const std::vector< CluVecIt > &clu) const
Methods for the BaryonicMesonic CR algorithm Find the best reconnection option for the respective clu...
Herwig::ColourReconnector::_3MtoXreconnectionfinder
void _3MtoXreconnectionfinder(std::vector< CluVecIt > &cv, int &swap0, int &swap1, int &swap2, double min_displ_sum, string &kind_of_reco) const
finds the best reconnection option and stores it in swap0, swap1 and swap2 (3M->{3M,...
Herwig::ColourReconnector::operator=
ColourReconnector & operator=(const ColourReconnector &)=delete
Private and non-existent assignment operator.
Herwig::ColourReconnector::_precoMB_MB
double _precoMB_MB
Probability that a found reconnection possibility is actually accepted.
Definition:
ColourReconnector.h:428
Herwig::ColourReconnector::rearrange
void rearrange(ClusterVector &clusters)
Does the colour rearrangement, starting out from the list of particles in the event record and the co...
Herwig::ColourReconnector::_containsColour8
bool _containsColour8(const ClusterVector &cv, const vector< size_t > &P) const
Examines whether the cluster vector (under the given permutation of the antiquarks) contains colour-o...
Herwig::ColourReconnector::_displacementBaryonic
double _displacementBaryonic(tcPPtr p1, tcPPtr p2, tcPPtr p3) const
calculates the "euclidean" distance of a the 3 (anti)quarks (anti)baryonic cluster in the rapdidity-p...
Herwig::ColourReconnector::_displacement
double _displacement(tcPPtr p, tcPPtr q) const
calculates the "euclidean" distance of two quarks in the rapdidity-phi plane @arguments p,...
Herwig::ColourReconnector::_findRecoPartner
CluVecIt _findRecoPartner(CluVecIt cl, ClusterVector &cv) const
Finds the cluster in cv which, if reconnected with the given cluster cl, would result in the smallest...
Herwig::ColourReconnector::_BbarBto3MreconnectionFinder
void _BbarBto3MreconnectionFinder(ClusterPtr &c1, ClusterPtr &c2, int &mswap0, int &mswap1, int &mswap2, double min_displ_sum, string &kind_of_reco) const
finds the best reconnection option and stores it in mswap0 mswap1 and mswap2 (BbarB->3M colour reconn...
Herwig::ColourReconnector::_doReco2BeamClusters
void _doReco2BeamClusters(ClusterVector &cv) const
Does reconnect 2 beam clusters for BaryonicMesonic CR model if option CR2BeamClusters is enabled @arg...
Herwig::ColourReconnector::_initTemp
double _initTemp
Statistical Reco: Factor used to determine the initial temperature according to InitialTemperature = ...
Definition:
ColourReconnector.h:358
Herwig::ColourReconnector::clone
virtual IBPtr clone() const
Make a simple clone of this object.
Herwig::ColourReconnector::_shuffle
pair< int, int > _shuffle(const PVector &q, const PVector &aq, unsigned maxtries=10) const
At random, swap two antiquarks, if not excluded by the constraint that there must not be any colour-o...
Herwig::ColourReconnector::_doRecoBaryonic
void _doRecoBaryonic(ClusterVector &cv) const
Baryonic Colour Reconnection model.
Herwig::ColourReconnector::_stepFactor
double _stepFactor
For the BaryonicMesonic algorithm How many times do suggest cluster for reconnection?...
Definition:
ColourReconnector.h:435
Herwig::ColourReconnector::_maxDistance
Length _maxDistance
Maximium distance for reconnections TODO: remove if issues with anticausality are discussed and resol...
Definition:
ColourReconnector.h:446
Herwig::ColourReconnector::_reconnect2Bto2B
pair< ClusterPtr, ClusterPtr > _reconnect2Bto2B(ClusterPtr &c1, ClusterPtr &c2, const int s1, const int s2) const
Reconnects (2B->2B) the constituents of the given clusters to another possible cluster combination wh...
Herwig::ColourReconnector::persistentInput
void persistentInput(PersistentIStream &is, int version)
Function used to read in object persistently.
Herwig::ColourReconnector::_reconnectMBtoMB
pair< ClusterPtr, ClusterPtr > _reconnectMBtoMB(ClusterPtr &c1, ClusterPtr &c2, const int s0) const
Reconnection method for a Baryonic and a Mesonic Cluster to a Baryonic and a Mesonic Cluster s0 is th...
Herwig::ColourReconnector::_reconnect3Mto3M
std::tuple< ClusterPtr, ClusterPtr, ClusterPtr > _reconnect3Mto3M(ClusterPtr &c1, ClusterPtr &c2, ClusterPtr &c3, const int infos[3]) const
Reconnects (3M->3M) the constituents of the given clusters to another possible cluster combination wh...
Herwig::ColourReconnector::_cr2BeamClusters
int _cr2BeamClusters
Option for colour reconnecting 2 Beam Clusters if no others are present.
Definition:
ColourReconnector.h:462
Herwig::ColourReconnector::persistentOutput
void persistentOutput(PersistentOStream &os) const
Function used to write out object persistently.
Herwig::ColourReconnector::_preco2B_2B
double _preco2B_2B
Probability that a found reconnection possibility is actually accepted.
Definition:
ColourReconnector.h:420
Herwig::ColourReconnector::_precoBbarB_3M
double _precoBbarB_3M
Probability that a found reconnection possibility is actually accepted.
Definition:
ColourReconnector.h:412
Herwig::ColourReconnector::_doRecoBaryonicMesonic
void _doRecoBaryonicMesonic(ClusterVector &cv) const
BaryonicMesonic colour reconnection model @arguments cv cluster vector BaryonicMesonic Colour Reconne...
Herwig::ColourReconnector::_clusterMassSum
Energy2 _clusterMassSum(const PVector &q, const PVector &aq) const
PRIVATE MEMBER FUNCTIONS.
Herwig::ColourReconnector::_junctionMBCR
int _junctionMBCR
Junction-like model for BaryonicMesonic model Do we want to use the junction-like model for computing...
Definition:
ColourReconnector.h:350
Herwig::ColourReconnector::_precoBaryonic
double _precoBaryonic
Probability that a found reconnection possibility is actually accepted.
Definition:
ColourReconnector.h:390
Herwig::ColourReconnector::_preco3M_3M
double _preco3M_3M
Probability that a found reconnection possibility is actually accepted.
Definition:
ColourReconnector.h:398
Herwig::ColourReconnector::Init
static void Init()
Standard Init function used to initialize the interfaces.
Herwig::ColourReconnector::_BMtoBMreconnectionfinder
void _BMtoBMreconnectionfinder(ClusterPtr &c1, ClusterPtr &c2, int &swap, double min_displ_sum, string &kind_of_reco) const
finds the best reconnection option and stores it in swap (BM->BM colour reconnection) @arguments c1 a...
Herwig::ColourReconnector::_triesPerStepFactor
double _triesPerStepFactor
Statistical Reco: The number of tries per temperature steps is the number of clusters times this fact...
Definition:
ColourReconnector.h:378
Herwig::ColourReconnector::_algorithm
int _algorithm
DATA MEMBERS.
Definition:
ColourReconnector.h:325
Herwig::ColourReconnector::_localCR
int _localCR
Option for colour reconnecting Clusters only if their vertex 3-distance is less than _maxDistance.
Definition:
ColourReconnector.h:474
Herwig::ColourReconnector::_clreco
int _clreco
Do we do colour reconnections?
Definition:
ColourReconnector.h:330
Herwig::ColourReconnector::_findbestreconnectionoption
void _findbestreconnectionoption(std::vector< CluVecIt > &cls, const unsigned &baryonic, string &kind_of_reco, int(&reco_info)[3]) const
Finds best CR option for the BaryonicMesonic CR model @arguments cls vector of selected clusters,...
Herwig::ColourReconnector::_mesonToBaryonFactor
double _mesonToBaryonFactor
Factor for comparing mesonic clusters to baryonic clusters.
Definition:
ColourReconnector.h:440
Herwig::ColourReconnector::_annealingFactor
double _annealingFactor
Statistical Reco: The annealing factor is the ratio of two successive temperature steps: T_n = anneal...
Definition:
ColourReconnector.h:365
Herwig::ColourReconnector::_preco3M_BBbar
double _preco3M_BBbar
Probability that a found reconnection possibility is actually accepted.
Definition:
ColourReconnector.h:405
Herwig::ColourReconnector::_2Bto2BreconnectionFinder
void _2Bto2BreconnectionFinder(ClusterPtr &c1, ClusterPtr &c2, int &bswap1, int &bswap2, double mindisplsum, string &kind_of_reco) const
finds the best reconnection option and stores it in bswap1 and bswap2 (2B->2B colour reconnection) @a...
Herwig::ColourReconnector::_prePlainCR
int _prePlainCR
Option for performing Plain colour reconnection before the Statistical, Baryonic or BaryonicMesonic a...
Definition:
ColourReconnector.h:468
ThePEG::Interfaced
ThePEG::PersistentIStream
ThePEG::PersistentOStream
Herwig::ClusterVector
vector< ClusterPtr > ClusterVector
This file contains the typedef declarations used in Hadronization.
Definition:
CluHadConfig.h:38
Herwig
-*- C++ -*-
Definition:
BasicConsistency.h:17
ThePEG
ThePEG::IBPtr
ThePEG::Ptr< InterfacedBase >::pointer IBPtr
ThePEG::tcPPtr
ThePEG::Ptr< Particle >::transient_const_pointer tcPPtr
ThePEG::PVector
vector< PPtr > PVector
Generated on Thu Jun 20 2024 17:50:52 for Herwig by
1.9.6