59 double the = 2.*atan(
exp(-eta));
63 double mass = (
fMasterGen->particleData).m0( particleID );
65 double pp = pt /
sin(the);
66 double ee =
sqrt( pp*pp + mass*mass );
68 double px = pt *
cos(phi);
69 double py = pt *
sin(phi);
70 double pz = pp *
cos(the);
72 if ( !((
fMasterGen->particleData).isParticle( particleID )) )
74 particleID = std::fabs(particleID) ;
84 if ( (
fMasterGen->particleData).isParticle( -particleID ) )
98 event().reset(
new HepMC::GenEvent);
edm::GeneratorFilter< gen::Py8PtGun, gen::ExternalDecayDriver > Pythia8PtGun
T getParameter(std::string const &) const
std::auto_ptr< Pythia8::Pythia > fMasterGen
#define DEFINE_FWK_MODULE(type)
Sin< T >::type sin(const T &t)
virtual double flat() override
const char * classname() const override
Cos< T >::type cos(const T &t)
std::vector< int > fPartIDs
std::auto_ptr< HepMC::GenEvent > & event()
P8RndmEngine & randomEngine()
bool generatePartonsAndHadronize() override
Py8PtGun(edm::ParameterSet const &)
HepMC::Pythia8ToHepMC toHepMC