00001 #ifndef AMPTHadronizer_h 00002 #define AMPTHadronizer_h 00003 00004 #include "FWCore/ParameterSet/interface/ParameterSet.h" 00005 #include "GeneratorInterface/Core/interface/BaseHadronizer.h" 00006 #include "CLHEP/Random/RandomEngine.h" 00007 00008 #include <map> 00009 #include <string> 00010 #include <vector> 00011 #include <math.h> 00012 00013 namespace HepMC { 00014 class GenEvent; 00015 class GenParticle; 00016 class GenVertex; 00017 } 00018 00019 extern CLHEP::HepRandomEngine* _amptRandomEngine; 00020 00021 namespace gen 00022 { 00023 00024 extern "C" { 00025 double ranart_(int*); 00026 } 00027 00028 extern "C" { 00029 double ran1_(int*); 00030 } 00031 00032 class AMPTHadronizer : public BaseHadronizer { 00033 public: 00034 AMPTHadronizer(const edm::ParameterSet &); 00035 virtual ~AMPTHadronizer(); 00036 00037 bool generatePartonsAndHadronize(); 00038 bool hadronize(); 00039 bool decay(); 00040 bool residualDecay(); 00041 bool initializeForExternalPartons(); 00042 bool initializeForInternalPartons(); 00043 bool declareStableParticles( const std::vector<int> ); 00044 bool declareSpecialSettings( const std::vector<std::string> ) { return true; } 00045 00046 void finalizeEvent(); 00047 void statistics(); 00048 const char* classname() const; 00049 00050 private: 00051 00052 void add_heavy_ion_rec(HepMC::GenEvent *evt); 00053 HepMC::GenParticle* build_ampt( int index, int barcode ); 00054 HepMC::GenVertex* build_ampt_vertex(int i, int id); 00055 bool get_particles(HepMC::GenEvent* evt); 00056 bool ampt_init(const edm::ParameterSet &pset); 00057 bool call_amptset(double efrm, std::string frame, std::string proj, std::string targ, int iap, int izp, int iat, int izt); 00058 // inline double nuclear_radius() const; 00059 void rotateEvtPlane(); 00060 00061 HepMC::GenEvent *evt; 00062 edm::ParameterSet pset_; 00063 double bmax_; // max impact param; 00064 // units of nucl radius 00065 double bmin_; // min impact param; 00066 // units of nucl radius 00067 double efrm_; // collision energy 00068 std::string frame_; 00069 std::string proj_; 00070 std::string targ_; 00071 int iap_; 00072 int izp_; 00073 int iat_; 00074 int izt_; 00075 int amptmode_; 00076 int ntmax_; 00077 double dt_; 00078 double stringFragA_; 00079 double stringFragB_; 00080 bool popcornmode_; 00081 double popcornpar_; 00082 bool shadowingmode_; 00083 bool quenchingmode_; 00084 double quenchingpar_; 00085 double pthard_; 00086 double mu_; 00087 int izpc_; 00088 double alpha_; 00089 double dpcoal_; 00090 double drcoal_; 00091 bool ks0decay_; 00092 bool phidecay_; 00093 int deuteronmode_; 00094 int deuteronfactor_; 00095 int deuteronxsec_; 00096 double minijetpt_; 00097 int maxmiss_; 00098 int doInitialAndFinalRadiation_; 00099 int ktkick_; 00100 int diquarkembedding_; 00101 double diquarkpx_; 00102 double diquarkpy_; 00103 double diquarkx_; 00104 double diquarky_; 00105 int nsembd_; 00106 double psembd_; 00107 double tmaxembd_; 00108 bool shadowingmodflag_; 00109 double shadowingfactor_; 00110 double phi0_; // Event plane angle 00111 double sinphi0_; 00112 double cosphi0_; 00113 bool rotate_; // Switch to rotate event plane 00114 }; 00115 } /*end namespace*/ 00116 00117 #endif