File indexing completed on 2025-01-18 10:06:27
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010 #ifndef Pythia8_ParticleDecays_H
0011 #define Pythia8_ParticleDecays_H
0012
0013 #include "Pythia8/Basics.h"
0014 #include "Pythia8/Event.h"
0015 #include "Pythia8/FragmentationFlavZpT.h"
0016 #include "Pythia8/Info.h"
0017 #include "Pythia8/ParticleData.h"
0018 #include "Pythia8/PhysicsBase.h"
0019 #include "Pythia8/PythiaStdlib.h"
0020 #include "Pythia8/Settings.h"
0021 #include "Pythia8/TimeShower.h"
0022 #include "Pythia8/TauDecays.h"
0023
0024 namespace Pythia8 {
0025
0026
0027
0028
0029
0030
0031 class DecayHandler {
0032
0033 public:
0034
0035
0036 virtual ~DecayHandler() {}
0037
0038
0039
0040 virtual bool decay(vector<int>& , vector<double>& , vector<Vec4>& ,
0041 int , const Event& ) {return false;}
0042
0043
0044
0045 virtual bool chainDecay(vector<int>& , vector<int>& , vector<double>& ,
0046 vector<Vec4>& , int , const Event& ) {return false;}
0047
0048
0049 virtual vector<int> handledParticles() {return {};}
0050
0051 };
0052
0053
0054
0055
0056
0057 class ParticleDecays : public PhysicsBase {
0058
0059 public:
0060
0061
0062 ParticleDecays() : timesDecPtr(), flavSelPtr(), decayHandlePtr(),
0063 limitTau0(), limitTau(),
0064 limitRadius(), limitCylinder(), limitDecay(), mixB(), doFSRinDecays(),
0065 doGammaRad(), tauMode(), mSafety(), tau0Max(), tauMax(), rMax(), xyMax(),
0066 zMax(), xBdMix(), xBsMix(), sigmaSoft(), multIncrease(),
0067 multIncreaseWeak(), multRefMass(), multGoffset(), colRearrange(),
0068 stopMass(), sRhoDal(), wRhoDal(), hasPartons(), keepPartons(), idDec(),
0069 meMode(), mult(), scale(), decDataPtr() {}
0070
0071
0072 void init(TimeShowerPtr timesDecPtrIn, StringFlav* flavSelPtrIn,
0073 DecayHandlerPtr decayHandlePtrIn, vector<int> handledParticles);
0074
0075
0076 bool decay(int iDec, Event& event);
0077
0078
0079 bool decayAll(Event& event, double minWidth = 0.);
0080
0081
0082 bool moreToDo() const {return hasPartons && keepPartons;}
0083
0084 protected:
0085
0086 virtual void onInitInfoPtr() override {
0087 registerSubObject(tauDecayer); }
0088
0089 private:
0090
0091
0092 static const int NTRYDECAY, NTRYPICK, NTRYMEWT, NTRYDALITZ;
0093 static const double MSAFEDALITZ, WTCORRECTION[11];
0094
0095
0096 TimeShowerPtr timesDecPtr;
0097
0098
0099 StringFlav* flavSelPtr;
0100
0101
0102 DecayHandlerPtr decayHandlePtr;
0103
0104
0105 bool limitTau0, limitTau, limitRadius, limitCylinder, limitDecay,
0106 mixB, doFSRinDecays, doGammaRad;
0107 int tauMode;
0108 double mSafety, tau0Max, tauMax, rMax, xyMax, zMax, xBdMix, xBsMix,
0109 sigmaSoft, multIncrease, multIncreaseWeak, multRefMass, multGoffset,
0110 colRearrange, stopMass, sRhoDal, wRhoDal;
0111
0112
0113 bool hasPartons, keepPartons;
0114 int idDec, meMode, mult;
0115 double scale;
0116 vector<int> iProd, idProd, motherProd, cols, acols, idPartons;
0117 vector<double> mProd, mInv, rndmOrd;
0118 vector<Vec4> pInv, pProd;
0119 vector<FlavContainer> flavEnds;
0120
0121
0122 ParticleDataEntry* decDataPtr;
0123
0124
0125 TauDecays tauDecayer;
0126
0127
0128 bool checkVertex(Particle& decayer);
0129
0130
0131 bool oscillateB(Particle& decayer);
0132
0133
0134 bool oneBody(Event& event);
0135
0136
0137 bool twoBody(Event& event);
0138
0139
0140 bool threeBody(Event& event);
0141
0142
0143 bool mGenerator(Event& event);
0144
0145
0146 bool dalitzMass();
0147
0148
0149 bool dalitzKinematics(Event& event);
0150
0151
0152 bool pickHadrons();
0153
0154
0155 bool setColours(Event& event);
0156
0157 };
0158
0159
0160
0161 }
0162
0163 #endif