![]() |
HepMC Reference DocumentationHepMC |
#include <fstream>
#include <iostream>
#include "HepMC/PythiaWrapper.h"
#include "HepMC/IO_HEPEVT.h"
#include "HepMC/GenEvent.h"
#include "PythiaHelper.h"
Go to the source code of this file.
Functions | |
void | writePythiaStreamIO () |
void | readPythiaStreamIO () |
int | main () |
int main | ( | ) |
Definition at line 31 of file example_PythiaStreamIO.cc.
References readPythiaStreamIO(), and writePythiaStreamIO().
void readPythiaStreamIO | ( | ) |
Definition at line 103 of file example_PythiaStreamIO.cc.
References HepMC::GenEvent::cross_section(), HepMC::GenEvent::is_valid(), HepMC::GenEvent::read(), HepMC::GenEvent::write(), HepMC::write_HepMC_IO_block_begin(), and HepMC::write_HepMC_IO_block_end().
Referenced by main().
void writePythiaStreamIO | ( | ) |
example of generating events with Pythia using HepMC/PythiaWrapper.h Events are read into the HepMC event record from the FORTRAN HEPEVT common block using the IO_HEPEVT strategy
To Compile: go to the HepMC example directory and type: make example_PythiaStreamIO.exe
This example uses streaming I/O writePythiaStreamIO() sets the cross section in GenRun readPythiaStreamIO() reads the file written by writePythiaStreamIO()
Definition at line 40 of file example_PythiaStreamIO.cc.
References getPythiaCrossSection(), HepMC::Units::GEV, initPythia(), HepMC::Units::MM, pypars, HepMC::IO_BaseClass::read_next_event(), HepMC::GenEvent::set_cross_section(), HepMC::GenEvent::set_event_number(), HepMC::HEPEVT_Wrapper::set_max_number_entries(), HepMC::GenEvent::set_mpi(), HepMC::GenEvent::set_signal_process_id(), HepMC::HEPEVT_Wrapper::set_sizeof_real(), HepMC::GenEvent::use_units(), HepMC::write_HepMC_IO_block_begin(), and HepMC::write_HepMC_IO_block_end().
Referenced by main().