herwig is hosted by Hepforge, IPPP Durham
Herwig 7.3.0
HwDecayerBase.h
1// -*- C++ -*-
2//
3// HwDecayerBase.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_HwDecayerBase_H
10#define HERWIG_HwDecayerBase_H
11//
12// This is the declaration of the HwDecayerBase class.
13//
14
15#include "ThePEG/PDT/Decayer.h"
16#include "Herwig/Shower/RealEmissionProcess.fh"
17#include "HwDecayerBase.fh"
18
19namespace Herwig {
20
21struct Branching;
22
23using namespace ThePEG;
24
37class HwDecayerBase: public Decayer {
38
39public:
40
44 HwDecayerBase() : _initialize(false), _dbOutput(false) {}
45
54 virtual bool accept(const DecayMode & dm) const;
55
62 virtual ParticleVector decay(const DecayMode & dm, const Particle & p) const;
64
65public:
66
72
76 enum POWHEGType {No, ISR, FSR, Both};
77
78
82 virtual POWHEGType hasPOWHEGCorrection() {return No;}
83
84
88 virtual bool hasMECorrection() {return false;}
89
93 virtual void initializeMECorrection(RealEmissionProcessPtr , double & ,
94 double & );
95
99 virtual RealEmissionProcessPtr applyHardMatrixElementCorrection(RealEmissionProcessPtr);
100
113 virtual bool softMatrixElementVeto(PPtr parent,
114 PPtr progenitor,
115 const bool & fs,
116 const Energy & highestpT,
117 const vector<tcPDPtr> & ids,
118 const double & z,
119 const Energy & scale,
120 const Energy & pT);
121
125 virtual RealEmissionProcessPtr generateHardest(RealEmissionProcessPtr);
127
128protected:
129
141 virtual bool accept(tcPDPtr parent, const tPDVector & children) const = 0;
142
149 virtual ParticleVector decay(const Particle & parent,
150 const tPDVector & children) const = 0;
152
153public:
154
162
168 void persistentInput(PersistentIStream & is, int version);
170
177 static void Init();
178
179public:
180
190 virtual void dataBaseOutput(ofstream & os,bool header) const = 0;
191
195 bool initialize() const {return _initialize;}
196
200 bool databaseOutput() const {return _dbOutput;}
202
203protected:
204
208 void fixRho(RhoDMatrix &) const;
209
210protected:
211
218 virtual void dofinish();
220
221private:
222
228
229private:
230
235
240};
241
242}
243
244#endif /* HERWIG_HwDecayerBase_H */
The HwDecayerBase class is the base class for Decayers in Herwig.
Definition: HwDecayerBase.h:37
void persistentOutput(PersistentOStream &os) const
Function used to write out object persistently.
POWHEGType
Virtual members to be overridden by inheriting classes which implement hard corrections.
Definition: HwDecayerBase.h:76
virtual void dataBaseOutput(ofstream &os, bool header) const =0
Functions for the Herwig decayer.
virtual bool accept(tcPDPtr parent, const tPDVector &children) const =0
Check if this decayer can perfom the decay for a particular mode.
bool _initialize
perform initialisation
virtual ParticleVector decay(const Particle &parent, const tPDVector &children) const =0
Perform the decay of the particle to the specified decay products.
virtual POWHEGType hasPOWHEGCorrection()
Has a POWHEG style correction.
Definition: HwDecayerBase.h:82
virtual bool softMatrixElementVeto(PPtr parent, PPtr progenitor, const bool &fs, const Energy &highestpT, const vector< tcPDPtr > &ids, const double &z, const Energy &scale, const Energy &pT)
Apply the soft matrix element correction.
bool initialize() const
Access to the initialize variable.
void fixRho(RhoDMatrix &) const
Set rho to be diagonal if no correlations.
HwDecayerBase()
The default constructor.
Definition: HwDecayerBase.h:44
virtual void initializeMECorrection(RealEmissionProcessPtr, double &, double &)
Initialize the ME correction.
static void Init()
The standard Init function used to initialize the interfaces.
virtual RealEmissionProcessPtr generateHardest(RealEmissionProcessPtr)
Apply the POWHEG style correction.
void persistentInput(PersistentIStream &is, int version)
Function used to read in object persistently.
virtual void dofinish()
Finalize this object.
bool databaseOutput() const
Access the database output variable.
virtual bool hasMECorrection()
Has an old fashioned ME correction.
Definition: HwDecayerBase.h:88
virtual RealEmissionProcessPtr applyHardMatrixElementCorrection(RealEmissionProcessPtr)
Apply the hard matrix element correction to a given hard process or decay.
bool _dbOutput
Print out database
HwDecayerBase & operator=(const HwDecayerBase &)=delete
The assignment operator is private and must never be called.
virtual bool accept(const DecayMode &dm) const
Check if this decayer can perfom the decay specified by the given decay mode.
virtual ParticleVector decay(const DecayMode &dm, const Particle &p) const
Perform a decay for a given DecayMode and a given Particle instance.
-*- C++ -*-
vector< tPDPtr > tPDVector
ThePEG::Ptr< Particle >::pointer PPtr
vector< PPtr > ParticleVector
ThePEG::Ptr< ParticleData >::transient_const_pointer tcPDPtr