herwig is hosted by Hepforge, IPPP Durham
Herwig  7.1.5
TauDecayer.h
1 // -*- C++ -*-
2 //
3 // TauDecayer.h is a part of Herwig - A multi-purpose Monte Carlo event generator
4 // Copyright (C) 2002-2017 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_TauDecayer_H
10 #define HERWIG_TauDecayer_H
11 // This is the declaration of the TauDecayer class.
12 
13 #include "Herwig/Decay/DecayIntegrator.h"
14 #include "Herwig/Decay/DecayPhaseSpaceMode.h"
15 #include "ThePEG/Helicity/LorentzPolarizationVector.h"
16 #include "Herwig/Decay/WeakCurrents/WeakDecayCurrent.h"
17 #include "ThePEG/Helicity/LorentzSpinor.h"
18 #include "ThePEG/Helicity/LorentzSpinorBar.h"
19 
20 namespace Herwig {
21 using namespace ThePEG;
23 
24 
50 class TauDecayer: public DecayIntegrator {
51 
52 public:
53 
57  TauDecayer() : _polOpt(false), _tauMpol(0.), _tauPpol(0.) {
58  generateIntermediates(true);
59  }
60 
66  virtual bool accept(tcPDPtr parent, const tPDVector & children) const;
67 
74  virtual int modeNumber(bool & cc, tcPDPtr parent,
75  const tPDVector & children) const;
76 
87  virtual double me2(const int ichan, const Particle & part,
88  const ParticleVector & decay,MEOption meopt) const;
89 
93  void dataBaseOutput(ofstream & os,bool header) const;
94 
95 public:
96 
103  void persistentOutput(PersistentOStream & os) const;
104 
110  void persistentInput(PersistentIStream & is, int version);
112 
116  static void Init();
117 
118 protected:
119 
126  virtual IBPtr clone() const {return new_ptr(*this);}
127 
132  virtual IBPtr fullclone() const {return new_ptr(*this);}
134 
135 protected:
136 
139 
145  virtual void doinit();
146 
150  virtual void doinitrun();
152 
153 private:
154 
159 
163  TauDecayer & operator=(const TauDecayer &) = delete;
164 
165 private:
166 
170  vector<unsigned int> _modemap;
171 
175  WeakDecayCurrentPtr _current;
176 
180  vector<int> _wgtloc;
181 
185  vector<double> _wgtmax;
186 
190  vector<double> _weights;
191 
195  mutable vector<LorentzSpinor <SqrtEnergy> > _inspin;
196 
200  mutable vector<LorentzSpinorBar<SqrtEnergy> > _inbar ;
201 
205  mutable RhoDMatrix _rho;
206 
210  mutable vector<unsigned int> _constants;
211 
215  mutable vector<PDT::Spin> _ispin;
216 
220  bool _polOpt;
221 
225  double _tauMpol;
226 
230  double _tauPpol;
231 };
232 
233 }
234 
235 
236 #include "ThePEG/Utilities/ClassTraits.h"
237 
238 namespace ThePEG {
239 
246 template <>
247  struct BaseClassTrait<Herwig::TauDecayer,1> {
249  typedef Herwig::DecayIntegrator NthBase;
250 };
251 
256 template <>
257 struct ClassTraits<Herwig::TauDecayer>
258  : public ClassTraitsBase<Herwig::TauDecayer> {
260  static string className() { return "Herwig::TauDecayer"; }
266  static string library() { return "HwTauDecay.so"; }
267 
268 };
269 
272 }
273 
274 #endif /* THEPEG_TauDecayer_H */
vector< unsigned int > _modemap
mapping of the modes to the currents
Definition: TauDecayer.h:170
vector< double > _weights
The weights for the different channels.
Definition: TauDecayer.h:190
vector< unsigned int > _constants
Maps for the vectors.
Definition: TauDecayer.h:210
ThePEG::Ptr< InterfacedBase >::pointer IBPtr
static ClassDescription< TauDecayer > initTauDecayer
Describe a concrete class with persistent data.
Definition: TauDecayer.h:158
vector< double > _wgtmax
the maximum weight
Definition: TauDecayer.h:185
RhoDMatrix _rho
Rho matrix.
Definition: TauDecayer.h:205
MEOption
Enum for the matrix element option.
vector< LorentzSpinorBar< SqrtEnergy > > _inbar
Barred spinors for the deaying particle.
Definition: TauDecayer.h:200
vector< tPDPtr > tPDVector
Main class for Decayers implementing multi-channel phase space integration.
ThePEG::Ptr< ParticleData >::transient_const_pointer tcPDPtr
TauDecayer()
Default constructor.
Definition: TauDecayer.h:57
vector< int > _wgtloc
location of the weights
Definition: TauDecayer.h:180
The TauDecayer class performs the decay of the .
Definition: TauDecayer.h:50
vector< PDT::Spin > _ispin
Spins of the particles.
Definition: TauDecayer.h:215
virtual IBPtr clone() const
Make a simple clone of this object.
Definition: TauDecayer.h:126
bool _polOpt
Option to force the polarizations of the tau leptons.
Definition: TauDecayer.h:220
-*- C++ -*-
LorentzVector< complex< double > > LorentzPolarizationVector
virtual IBPtr fullclone() const
Make a clone of this object, possibly modifying the cloned object to make it sane.
Definition: TauDecayer.h:132
WeakDecayCurrentPtr _current
the hadronic current
Definition: TauDecayer.h:175
vector< PPtr > ParticleVector
double _tauMpol
Polarization for .
Definition: TauDecayer.h:225
double _tauPpol
Polarization of .
Definition: TauDecayer.h:230
vector< LorentzSpinor< SqrtEnergy > > _inspin
The spinors for the decaying particle.
Definition: TauDecayer.h:195