herwig is hosted by Hepforge, IPPP Durham
Herwig  7.2.1
GeneralCurrentDecayer.h
1 // -*- C++ -*-
2 //
3 // GeneralCurrentDecayer.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_GeneralCurrentDecayer_H
10 #define HERWIG_GeneralCurrentDecayer_H
11 //
12 // This is the declaration of the GeneralCurrentDecayer class.
13 //
14 
15 #include "Herwig/Decay/DecayIntegrator.h"
16 #include "Herwig/Decay/WeakCurrents/WeakDecayCurrent.h"
17 #include "Herwig/Decay/DecayPhaseSpaceMode.h"
18 #include "ThePEG/Helicity/Vertex/VertexBase.h"
19 #include "GeneralCurrentDecayer.fh"
20 
21 namespace Herwig {
22 using namespace ThePEG;
23 using Helicity::VertexBasePtr;
24 
32 
33 public:
34 
39  maxmass_(5.*GeV), wgtmax_(0.) {}
40 
49  virtual int modeNumber(bool & cc, tcPDPtr parent,const tPDVector & children) const;
50 
59  virtual double me2(const int ichan, const Particle & part,
60  const ParticleVector & decay, MEOption meopt) const = 0;
61 
68  virtual Energy partialWidth(tPDPtr inpart, tPDPtr outa,
69  vector<tPDPtr> currout) = 0;
71 
75  void setDecayInfo(PDPtr in, PDPtr out, const vector<tPDPtr> & outCurrent,
76  VertexBasePtr vertex, WeakDecayCurrentPtr current,
77  Energy maxmass);
78 
79 public:
80 
87  void persistentOutput(PersistentOStream & os) const;
88 
94  void persistentInput(PersistentIStream & is, int version);
96 
103  static void Init();
104 
105 protected:
106 
114  virtual void doinit();
115 
120  virtual void doinitrun();
122 
123 protected:
124 
130  int modeNumber(bool & cc, vector<long> id) const;
131 
136  unsigned int mode() const { return mode_; }
137 
141  WeakDecayCurrentPtr weakCurrent() const { return current_; }
142 
147  VertexBasePtr vertex() const { return theVertex_; }
148 
149 private:
150 
155  GeneralCurrentDecayer & operator=(const GeneralCurrentDecayer &) = delete;
156 
157 private:
158 
162  VertexBasePtr theVertex_;
163 
168 
173 
177  vector<tPDPtr> currentOut_;
178 
182  WeakDecayCurrentPtr current_;
183 
187  Energy maxmass_;
188 
192  unsigned int mode_;
193 
197  int wgtloc_;
198 
202  double wgtmax_;
203 
207  vector<double> weights_;
208 };
209 
210 }
211 
212 #endif /* HERWIG_GeneralCurrentDecayer_H */
WeakDecayCurrentPtr current_
Pointer to the current.
VertexBasePtr vertex() const
Get vertex pointer.
ThePEG::Ptr< ParticleData >::transient_pointer tPDPtr
PDPtr outpart_
First outgoing particle.
unsigned int mode() const
Access to the map between the number of the mode and the modes in the current.
MEOption
Enum for the matrix element option.
unsigned int mode_
mapping of the modes to the currents
double wgtmax_
the maximum weight
vector< tPDPtr > tPDVector
VertexBasePtr theVertex_
Pointer to vertex set in inheriting class.
PDPtr inpart_
Incoming particle.
Main class for Decayers implementing multi-channel phase space integration.
vector< tPDPtr > currentOut_
Outgoing particles from the current.
ThePEG::Ptr< ParticleData >::transient_const_pointer tcPDPtr
int wgtloc_
location of the weights
Energy maxmass_
Maximum mass difference.
ThePEG::Ptr< ParticleData >::pointer PDPtr
Here is the documentation of the GeneralCurrentDecayer class.
-*- C++ -*-
vector< double > weights_
The weights for the different channels.
WeakDecayCurrentPtr weakCurrent() const
Access to the weak current.
vector< PPtr > ParticleVector
GeneralCurrentDecayer()
The default constructor.