AMPTHadronizer

Macros

Line Code
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120
#ifndef AMPTHadronizer_h
#define AMPTHadronizer_h

#include "FWCore/ParameterSet/interface/ParameterSet.h"
#include "GeneratorInterface/Core/interface/BaseHadronizer.h"

#include <map>
#include <string>
#include <vector>
#include <cmath>

namespace HepMC {
  class GenEvent;
  class GenParticle;
  class GenVertex;
}  // namespace HepMC

namespace CLHEP {
  class HepRandomEngine;
}

namespace gen {

  extern "C" {
  float ranart_(int*);
  }

  extern "C" {
  float ran1_(int*);
  }

  class AMPTHadronizer : public BaseHadronizer {
  public:
    AMPTHadronizer(const edm::ParameterSet&);
    ~AMPTHadronizer() override;

    bool generatePartonsAndHadronize();
    bool hadronize();
    bool decay();
    bool residualDecay();
    bool readSettings(int) { return true; }
    bool initializeForExternalPartons();
    bool initializeForInternalPartons();
    bool declareStableParticles(const std::vector<int>&);
    bool declareSpecialSettings(const std::vector<std::string>&) { return true; }

    void finalizeEvent();
    void statistics();
    const char* classname() const;

  private:
    void doSetRandomEngine(CLHEP::HepRandomEngine* v) override;

    void add_heavy_ion_rec(HepMC::GenEvent* evt);
    HepMC::GenParticle* build_ampt(int index, int barcode);
    HepMC::GenVertex* build_ampt_vertex(int i, int id);
    bool get_particles(HepMC::GenEvent* evt);
    bool ampt_init(const edm::ParameterSet& pset);
    bool call_amptset(
        double efrm, std::string frame, std::string proj, std::string targ, int iap, int izp, int iat, int izt);
    //    inline double			        nuclear_radius() const;
    void rotateEvtPlane();

    HepMC::GenEvent* evt;
    edm::ParameterSet pset_;
    double bmax_;  // max impact param;
                   // units of nucl radius
    double bmin_;  // min impact param;
                   // units of nucl radius
    double efrm_;  // collision energy
    std::string frame_;
    std::string proj_;
    std::string targ_;
    int iap_;
    int izp_;
    int iat_;
    int izt_;
    int amptmode_;
    int ntmax_;
    double dt_;
    double stringFragA_;
    double stringFragB_;
    bool popcornmode_;
    double popcornpar_;
    bool shadowingmode_;
    bool quenchingmode_;
    double quenchingpar_;
    double pthard_;
    double mu_;
    int izpc_;
    double alpha_;
    double dpcoal_;
    double drcoal_;
    bool ks0decay_;
    bool phidecay_;
    int deuteronmode_;
    int deuteronfactor_;
    int deuteronxsec_;
    double minijetpt_;
    int maxmiss_;
    int doInitialAndFinalRadiation_;
    int ktkick_;
    int diquarkembedding_;
    double diquarkpx_;
    double diquarkpy_;
    double diquarkx_;
    double diquarky_;
    int nsembd_;
    double psembd_;
    double tmaxembd_;
    bool shadowingmodflag_;
    double shadowingfactor_;
    double phi0_;  // Event plane angle
    double sinphi0_;
    double cosphi0_;
    bool rotate_;  // Switch to rotate event plane
  };
}  // namespace gen

#endif