CMS 3D CMS Logo

EmissionVetoHook1.h
Go to the documentation of this file.
2 
3 class EmissionVetoHook1 : public Pythia8::UserHooks {
4 
5 public:
6 
7  // Constructor and destructor.
8  EmissionVetoHook1(int nFinalIn, bool vetoOnIn, int vetoCountIn,
9  int pThardModeIn, int pTemtModeIn, int emittedModeIn,
10  int pTdefModeIn, bool MPIvetoOnIn, int QEDvetoModeIn,
11  int nFinalModeIn, int VerbosityIn) :
12  nFinalExt(nFinalIn),
13  vetoOn(vetoOnIn), vetoCount(vetoCountIn),
14  pThardMode(pThardModeIn), pTemtMode(pTemtModeIn),
15  emittedMode(emittedModeIn), pTdefMode(pTdefModeIn),
16  MPIvetoOn(MPIvetoOnIn), QEDvetoMode(QEDvetoModeIn),
17  nFinalMode(nFinalModeIn), nISRveto(0), nFSRveto(0),
18  Verbosity(VerbosityIn) {}
19  ~EmissionVetoHook1() override {
20  std::cout << "Number of ISR vetoed = " << nISRveto << std::endl;
21  std::cout << "Number of FSR vetoed = " << nFSRveto << std::endl;
22  }
23 
24 //--------------------------------------------------------------------------
25 
26  bool canVetoMPIStep() override { return true; }
27  int numberVetoMPIStep() override { return 1; }
28  bool doVetoMPIStep(int nMPI, const Pythia8::Event &e) override;
29 
30  bool canVetoISREmission() override { return vetoOn; }
31  bool doVetoISREmission(int, const Pythia8::Event &e, int iSys) override;
32 
33  bool canVetoFSREmission() override { return vetoOn; }
34  bool doVetoFSREmission(int, const Pythia8::Event &e, int iSys, bool) override;
35 
36  bool canVetoMPIEmission() override { return MPIvetoOn; }
37  bool doVetoMPIEmission(int, const Pythia8::Event &e) override;
38 
39  void fatalEmissionVeto(std::string message);
40 
41  double pTpythia(const Pythia8::Event &e, int RadAfterBranch,
42  int EmtAfterBranch, int RecAfterBranch, bool FSR);
43 
44  double pTpowheg(const Pythia8::Event &e, int i, int j, bool FSR);
45 
46  double pTcalc(const Pythia8::Event &e, int i, int j, int k, int r, int xSRin);
47 
48 //--------------------------------------------------------------------------
49 
50 private:
53  int nFinal;
54  double pThard, pTMPI;
55  bool accepted, isEmt;
56  // The number of accepted emissions (in a row)
58  // Statistics on vetos
59  unsigned long int nISRveto, nFSRveto;
60  int Verbosity;
61 };
bool canVetoISREmission() override
bool doVetoFSREmission(int, const Pythia8::Event &e, int iSys, bool) override
bool doVetoISREmission(int, const Pythia8::Event &e, int iSys) override
unsigned long int nISRveto
int numberVetoMPIStep() override
double pTpowheg(const Pythia8::Event &e, int i, int j, bool FSR)
int k[5][pyjets_maxn]
bool doVetoMPIStep(int nMPI, const Pythia8::Event &e) override
bool canVetoMPIEmission() override
bool canVetoFSREmission() override
unsigned long int nFSRveto
double pTcalc(const Pythia8::Event &e, int i, int j, int k, int r, int xSRin)
EmissionVetoHook1(int nFinalIn, bool vetoOnIn, int vetoCountIn, int pThardModeIn, int pTemtModeIn, int emittedModeIn, int pTdefModeIn, bool MPIvetoOnIn, int QEDvetoModeIn, int nFinalModeIn, int VerbosityIn)
double pTpythia(const Pythia8::Event &e, int RadAfterBranch, int EmtAfterBranch, int RecAfterBranch, bool FSR)
~EmissionVetoHook1() override
bool canVetoMPIStep() override
void fatalEmissionVeto(std::string message)
bool doVetoMPIEmission(int, const Pythia8::Event &e) override