14 #include "Pythia8/Pythia.h"
15 #include "Pythia8/Pythia8ToHepMC.h"
16 #include "HepMC/GenEvent.h"
17 #include "HepMC/IO_GenEvent.h"
19 using namespace Pythia8;
31 pythia.readString(
"Beams:eCM = 8000.");
32 pythia.readString(
"HardQCD:all = on");
33 pythia.readString(
"PhaseSpace:pTHatMin = 20.");
35 Hist mult(
"charged multiplicity", 100, -0.5, 799.5);
38 for (
int iEvent = 0; iEvent < 100; ++iEvent) {
39 if (!pythia.next())
continue;
43 for (
int i = 0; i < pythia.event.size(); ++i)
44 if (pythia.event[i].isFinal() && pythia.event[i].isCharged())
46 mult.fill( nCharged );
52 ToHepMC.fill_next_event( pythia, hepmcevt );
The GenEvent class is the core of HepMC.
IO_GenEvent also deals with HeavyIon and PdfInfo.