diff --git a/EvtGenExternal/EvtTauPythia.hh b/EvtGenExternal/EvtTauPythia.hh index a22ddf1..e421113 100644 --- a/EvtGenExternal/EvtTauPythia.hh +++ b/EvtGenExternal/EvtTauPythia.hh @@ -1,30 +1,30 @@ #ifndef EVT_TAUPYTHIA_HH #define EVT_TAUPYTHIA_HH -#include "EvtGenBase/EvtDecayAmp.hh" +#include "EvtGenBase/EvtDecayIncoherent.hh" #include class EvtPythiaEngine; class EvtParticle; -class EvtTauPythia: public EvtDecayAmp { +class EvtTauPythia: public EvtDecayIncoherent { public: EvtTauPythia(); std::string getName() override; EvtDecayBase* clone() override; void decay(EvtParticle *p) override; void init() override; void initProbMax() override; protected: EvtPythiaEngine* _pythiaEngine; private: }; #endif diff --git a/src/EvtGenExternal/EvtTauPythia.cpp b/src/EvtGenExternal/EvtTauPythia.cpp index 1aa314c..15b683c 100644 --- a/src/EvtGenExternal/EvtTauPythia.cpp +++ b/src/EvtGenExternal/EvtTauPythia.cpp @@ -1,87 +1,81 @@ //-------------------------------------------------------------------------- // // Environment: // This software is part of the EvtGen package. If you use all or part // of it, please give an appropriate acknowledgement. // // Copyright Information: See EvtGen/COPYRIGHT // // Module: EvtTauPythia.cpp // // Description: Tau decays using Pythia8 // // Modification history: // // //------------------------------------------------------------------------ // #include "EvtGenExternal/EvtTauPythia.hh" #include "EvtGenBase/EvtDecayBase.hh" #include "EvtGenBase/EvtParticle.hh" #include "EvtGenExternal/EvtExternalGenFactory.hh" #include "EvtGenExternal/EvtPythiaEngine.hh" EvtTauPythia::EvtTauPythia() : _pythiaEngine(0) {} std::string EvtTauPythia::getName() { return "TAUPYTHIA"; } EvtDecayBase* EvtTauPythia::clone() { return new EvtTauPythia(); } void EvtTauPythia::init() { // Check that there are 0 decay file parameter arguments checkNArg(0); // Check number of daughters: 2 or 3? // checkNDaug(2, 3); // Check that the parent is a tau checkSpinParent(EvtSpinType::DIRAC); // Daughter checks? // checkSpinDaughter(0, EvtSpinType::DIRAC); // checkSpinDaughter(2,EvtSpinType::NEUTRINO); } void EvtTauPythia::initProbMax() { setProbMax(1.0); } void EvtTauPythia::decay(EvtParticle* p) { // First retrieve the Pythia engine if (!_pythiaEngine) { _pythiaEngine = dynamic_cast(EvtExternalGenFactory::getInstance()->getGenerator(EvtExternalGenFactory::PythiaGenId)); } // Initialise phase space (or let Pythia do this?) p->initializePhaseSpace(getNDaug(), getDaugs()); // Call the Pythia tau decay model if (_pythiaEngine) { _pythiaEngine->doTauDecay(p); } - // Set amplitude vertex components - EvtComplex amp1(1.0, 0.0), amp2(0.0, 0.0); - - vertex(0, amp1); - vertex(1, amp2); - }