44 HepMC::GenVertex* Vtx =
new HepMC::GenVertex(HepMC::FourVector(0., 0., 0.));
54 int py6PID = HepPID::translatePDTtoPythia(particleID);
57 double pt = 0, y = 0, u = 0, ee = 0, the = 0;
68 pyjets.p[4][ip - 1] =
mass;
70 ee = 0.5 *
std::sqrt(mass * mass + pt * pt) * (u * u + 1) / u;
72 double pz =
std::sqrt(ee * ee - pt * pt - mass * mass);
82 py1ent_(ip, py6PID, ee, the, phi);
88 double px = pyjets.p[0][ip - 1];
89 double py = pyjets.p[1][ip - 1];
90 pz = pyjets.p[2][ip - 1];
92 HepMC::FourVector
p(px, py, pz, ee);
94 Part->suggest_barcode(ip);
95 Vtx->add_particle_out(Part);
100 fEvt->add_vertex(Vtx);
T getParameter(std::string const &) const
~Pythia6PtYDistGun() override
double firePt(CLHEP::HepRandomEngine *)
void generateEvent(CLHEP::HepRandomEngine *) override
double fireY(CLHEP::HepRandomEngine *)
#define DEFINE_FWK_MODULE(type)
PtYDistributor * fPtYGenerator
std::vector< int > fPartIDs
void py1ent_(int &ip, int &kf, double &pe, double &the, double &phi)
Pythia6Service * fPy6Service