Back to home page

sPhenix code displayed by LXR

 
 

    


File indexing completed on 2025-08-03 08:19:58

0001 /*******************************************************************************
0002  * Copyright (c) The JETSCAPE Collaboration, 2018
0003  *
0004  * Modular, task-based framework for simulating all aspects of heavy-ion collisions
0005  * 
0006  * For the list of contributors see AUTHORS.
0007  *
0008  * Report issues at https://github.com/JETSCAPE/JETSCAPE/issues
0009  *
0010  * or via email to bugs.jetscape@gmail.com
0011  *
0012  * Distributed under the GNU General Public License 3.0 (GPLv3 or later).
0013  * See COPYING for details.
0014  ******************************************************************************/
0015 
0016 #ifndef COLORLESSHADRONIZATION_H
0017 #define COLORLESSHADRONIZATION_H
0018 
0019 #include "HadronizationModule.h"
0020 #include "JetScapeLogger.h"
0021 #include "Pythia8/Pythia.h"
0022 
0023 using namespace Jetscape;
0024 
0025 class ColorlessHadronization
0026     : public HadronizationModule<ColorlessHadronization> {
0027 public:
0028   ColorlessHadronization();
0029   virtual ~ColorlessHadronization();
0030 
0031   void Init();
0032   void DoHadronization(vector<vector<shared_ptr<Parton>>> &shower,
0033                        vector<shared_ptr<Hadron>> &hOut,
0034                        vector<shared_ptr<Parton>> &pOut);
0035   void WriteTask(weak_ptr<JetScapeWriter> w);
0036 
0037 private:
0038   double p_fake;
0039   bool take_recoil;
0040 
0041   // Allows the registration of the module so that it is available to be used by the Jetscape framework.
0042   static RegisterJetScapeModule<ColorlessHadronization> reg;
0043 
0044 protected:
0045   static Pythia8::Pythia pythia;
0046   std::uniform_real_distribution<double> ZeroOneDistribution;
0047 };
0048 
0049 #endif // COLORLESSHADRONIZATION_H