agile is hosted by Hepforge, IPPP Durham

FPythia Class Reference

#include <FPythia.hh>

Inheritance diagram for FPythia:
Collaboration diagram for FPythia:

List of all members.

Public Types

enum  Result { SUCCESS = 1, FAILURE = 0 }
 

Really just syntactic sugar for bool returns from setParam.

More...

Public Member Functions

 FPythia ()
 Standard constructor.
virtual ~FPythia ()
 Destructor.
void setGenSpecificInitialState (PdgCode p1=PROTON, double e1=7000.0, PdgCode p2=PROTON, double e2=7000.0)
 Set up initial state from supplied params.
const string getName () const
 Get the generator name.
void makeEvent (HepMC::GenEvent &evt)
 Run the generator for one event.
virtual void setSeed (const int value)
 Set the random number generator seed.
virtual bool setParam (const string &name, const string &value)
 Pass an string parameter to the generator.
string getPDFSet (PdgCode pid)
int getPDFMember (PdgCode pid)
 Get the PDF id number for a given particle.
string getPDFScheme (PdgCode pid) const
 Get the PDF scheme used by the generator (LHAPDF or other).
virtual const double getCrossSection ()
 Return the generated cross section in pb.
virtual const string getVersion ()
 Get the generator version. This implementation is used as a last resort to determine the generator version. Ideally a specific generator will know its own version and overwrite this. Some generators (e.g. FHerwig) don't know this.
void finalize ()
 Tidy up after ourselves.
void setInitialState (int p1=PROTON, double e1=7000.0, int p2=PROTON, double e2=7000.0)
 Define initial state.
virtual const GeneratorStategetState ()
 Get a generator state object.
virtual void setState (const GeneratorState &state)
 Setup the generator from a generator state object.
virtual void setVersion (const std::string &version)
 Set the generator version.
virtual bool setParam (const std::string &name, const int &value)
 Pass an int-valued parameter to the generator.
virtual bool setParam (const std::string &name, const unsigned int &value)
 Pass an int-valued parameter to the generator.
virtual bool setParam (const std::string &name, const long &value)
 Pass an int-valued parameter to the generator.
virtual bool setParam (const std::string &name, const unsigned long &value)
 Pass an int-valued parameter to the generator.
virtual bool setParam (const std::string &name, const double &value)
 Pass a double/float-valued parameter to the generator.
virtual bool setParam (const std::string &name, const float &value)
 Pass a double/float-valued parameter to the generator.
virtual bool setParam (const std::string &name, const bool &value)
 Pass a bool-valued parameter to the generator.
virtual bool setParam (const std::string &name, const std::string &value)
 Pass a string-valued parameter to the generator.

Protected Member Functions

void initialize ()
 Set up default params etc.
void fillEvent (HepMC::GenEvent &evt)
 Fill a HepMC event.
LoggetLog () const
 Get named logger.
virtual void clearEvent (HepMC::GenEvent &evt)
 Clear the supplied event.

Protected Attributes

string _particleName1
 Internal storage of initial state params.
string _particleName2
double _e1
double _e2
int _nevt
 Event counter.
HepMC::IO_HEPEVT _hepevt
 HEPEVT->HepMC converter.
double _crossSection
bool _initialstateset
 Flag for detecting whether the setInitialState method has run.
bool _initialized
 Flag for detecting whether the initialization method has run.
map< PdgCode, std::string > _particleNames
 Collection of translated names for particles.
string _myName
 Generator name.

Detailed Description

Abstract base class for the Fortran-based Pythia 6 generator series

Author:
Andy Buckley

Definition at line 11 of file FPythia.hh.


Member Enumeration Documentation

enum Result [inherited]

Really just syntactic sugar for bool returns from setParam.

Enumerator:
SUCCESS 
FAILURE 

Definition at line 37 of file Generator.hh.

00037 { SUCCESS=1, FAILURE=0 };


Constructor & Destructor Documentation

FPythia (  ) 

Standard constructor.

Pythia uses HEPEVT with 4000/10000 entries and 8-byte floats

Todo:
Also deal with gamma/e- etc. for resolved photoproduction...

For Pythia, other "normal" particles are: gamma/e-, gamma/e+, gamma/mu-, gamma/mu+, gamma/tau-, gamma/tau+, pi0 Also, with crappy PDF parameterisations and other defects: K+, K-, KS0, KL0, Lambda0, Sigma-, Sigma0, Sigma+, Xi-, Xi0, Omega And, not useable at the moment: pomeron, reggeon

Definition at line 15 of file FPythia.cc.

References Generator::_myName, FPythia::_nevt, Generator::_particleNames, AGILe::ANTIMUON, AGILe::ANTINEUTRON, AGILe::ANTIPROTON, call_pyhepc(), AGILe::ELECTRON, FC_INITPYDATA, FC_PYDAT1, FC_PYJETS, AGILe::MUON, AGILe::NEUTRON, AGILe::NU_E, AGILe::NU_EBAR, AGILe::NU_MU, AGILe::NU_MUBAR, AGILe::NU_TAU, AGILe::NU_TAUBAR, AGILe::PHOTON, AGILe::PIMINUS, AGILe::PIPLUS, AGILe::POSITRON, AGILe::PROTON, and FPythia::setParam().

00015                    {
00016     _myName = "Pythia";
00017 
00019     FC_PYJETS.n = 0; //< Ensure dummyness of the next call
00020     call_pyhepc(1);
00021     HepMC::HEPEVT_Wrapper::set_max_number_entries(FC_PYDAT1.mstu[8-1]);
00022     //HepMC::HEPEVT_Wrapper::set_max_number_entries(10000);
00023     HepMC::HEPEVT_Wrapper::set_sizeof_real(8);
00024 
00025     // Start counting events at 1.
00026     _nevt = 1;
00027 
00028     // Initialize Pythia PYDATA block data as external
00029     FC_INITPYDATA();
00030 
00031     // Write the full shower structure
00032     setParam("MSTP(125)", 2);
00033 
00034     // Tell Pythia not to write multiple copies of particles in event record.
00035     setParam("MSTP(128)", 2);
00036 
00037     // Set up particle names map
00039     _particleNames[ELECTRON]    = "e-";
00040     _particleNames[POSITRON]    = "e+";
00041     _particleNames[PROTON]      = "p+";
00042     _particleNames[ANTIPROTON]  = "pbar-";
00043     _particleNames[NEUTRON]     = "n0";
00044     _particleNames[ANTINEUTRON] = "nbar0";
00045     _particleNames[PHOTON]      = "gamma";
00046     _particleNames[MUON]        = "mu-";
00047     _particleNames[ANTIMUON]    = "mu+";
00048     // TAU, ANTITAU
00049     _particleNames[NU_E]        = "nu_e";
00050     _particleNames[NU_EBAR]     = "nu_ebar";
00051     _particleNames[NU_MU]       = "nu_mu";
00052     _particleNames[NU_MUBAR]    = "nu_mubar";
00053     _particleNames[NU_TAU]      = "nu_tau";
00054     _particleNames[NU_TAUBAR]   = "nu_taubar";
00055     _particleNames[PIPLUS]      = "pi+";
00056     _particleNames[PIMINUS]     = "pi-";
00057     // PIZERO
00058     // PHOTOELECTRON, PHOTOPOSITRON,
00059     // PHOTOMUON,     PHOTOANTIMUON,
00060     // PHOTOTAU,      PHOTOANTITAU,
00067   }

virtual ~FPythia (  )  [inline, virtual]

Destructor.

Definition at line 17 of file FPythia.hh.

00017 { }


Member Function Documentation

virtual void clearEvent ( HepMC::GenEvent &  evt  )  [inline, protected, virtual, inherited]

Clear the supplied event.

Definition at line 275 of file Generator.hh.

Referenced by Generator::makeEvent(), FHerwigJimmy::makeEvent(), and AlpGenFHerwigJimmy::makeEvent().

00275                                                 {
00276       evt.clear();
00277     }

void fillEvent ( HepMC::GenEvent &  evt  )  [protected]

Fill a HepMC event.

Todo:
If reading from LHEF, we need to get the PDF info from LHEF instead?

Definition at line 150 of file FPythia.cc.

References FPythia::_hepevt, FC_PYPARS, AGILe::fixHepMCUnitsFromGeVmm(), FPythia::getCrossSection(), MSG_DEBUG, and xsec.

Referenced by FPythia::makeEvent().

00150                                             {
00151     _hepevt.fill_next_event(&evt);
00152     fixHepMCUnitsFromGeVmm(evt);
00153 
00154     // Set beam particle status = 4
00155     if (evt.valid_beam_particles()) {
00156       evt.beam_particles().first->set_status(4);
00157       evt.beam_particles().second->set_status(4);
00158     }
00159 
00160     // Weight(s)
00161     evt.weights().clear();
00162     if (FC_PYPARS.mstp[141] != 0) {
00163       evt.weights().push_back(FC_PYPARS.pari[9]);
00164     } else {
00165       evt.weights().push_back(1.0);
00166     }
00167 
00168     // Cross-section
00169     #ifdef HEPMC_HAS_CROSS_SECTION
00170     HepMC::GenCrossSection xsec;
00171     const double xsecval = getCrossSection();
00172     const double xsecerr = getCrossSection() / std::sqrt(FC_PYPARS.msti[4]);
00173     MSG_DEBUG("Writing cross-section = " << xsecval << " +- " << xsecerr);
00174     xsec.set_cross_section(xsecval, xsecerr);
00175     evt.set_cross_section(xsec);
00176     #endif
00177 
00178     // PDF weights, using HepMC::PdfInfo object
00180     const int id1 = FC_PYPARS.msti[15-1];
00181     const int id2 = FC_PYPARS.msti[16-1];
00182     const double x1 = FC_PYPARS.pari[33-1];
00183     const double x2 = FC_PYPARS.pari[34-1];
00184     const double q = FC_PYPARS.pari[23-1];
00185     const double pdf1 = FC_PYPARS.pari[29-1]; // x*pdf1
00186     const double pdf2 = FC_PYPARS.pari[30-1]; // x*pdf2
00187     // std::cout << q << ": " << id1 << ", " << x1 << ", " << pdf1 << "; "
00188     //           << id2 << ", " << x2 << ", " << pdf2 << std::endl;
00189     HepMC::PdfInfo pdfi(id1, id2, x1, x2, q, pdf1, pdf2);
00190     evt.set_pdf_info(pdfi);
00191   }

void finalize (  )  [virtual]

Tidy up after ourselves.

Implements Generator.

Definition at line 275 of file FPythia.cc.

References call_pystat(), and MSG_DEBUG.

00275                          {
00276     MSG_DEBUG("Finalising...");
00277     // Print out stats from run
00278     call_pystat(1);
00279   }

const double getCrossSection (  )  [virtual]

Return the generated cross section in pb.

Reimplemented from Generator.

Definition at line 262 of file FPythia.cc.

References Generator::_crossSection, and FC_PYPARS.

Referenced by FPythia::fillEvent().

00262                                        {
00263     // _crossSection = FC_PYINT5.xsec[2][0] * 1e09;
00264     _crossSection = FC_PYPARS.pari[0] * 1e09;
00265     return _crossSection;
00266   }

const string getName (  )  const [inline, virtual]

Get the generator name.

Reimplemented from Generator.

Definition at line 23 of file FPythia.hh.

00023                                  {
00024       return "PYTHIA";
00025     }

int getPDFMember ( PdgCode  pid  )  [virtual]

Get the PDF id number for a given particle.

Reimplemented from Generator.

Definition at line 220 of file FPythia.cc.

References AGILe::ANTIPROTON, AGILe::ELECTRON, FC_PYPARS, AGILe::POSITRON, and AGILe::PROTON.

00220                                        {
00221     switch(pid) {
00222       case PROTON:
00223       case ANTIPROTON:
00224         return FC_PYPARS.mstp[50];
00225         break;
00226       case ELECTRON:
00227       case POSITRON:
00228         return FC_PYPARS.mstp[54];
00229         break;
00230       default:
00231         break;
00232     }
00233     throw runtime_error("Unknown particle for PDF set");
00234   }

string getPDFScheme ( PdgCode  pid  )  const [virtual]

Get the PDF scheme used by the generator (LHAPDF or other).

Reimplemented from Generator.

Definition at line 237 of file FPythia.cc.

References AGILe::ANTIPROTON, AGILe::ELECTRON, FC_PYPARS, AGILe::POSITRON, and AGILe::PROTON.

00237                                                 {
00238     switch(pid){
00239       case PROTON:
00240       case ANTIPROTON:
00241         if (FC_PYPARS.mstp[51]==1) {
00242           return "PYINTERNAL";
00243         } else if(FC_PYPARS.mstp[51]==2) {
00244           return "LHAPDF";
00245         }
00246         break;
00247       case ELECTRON:
00248       case POSITRON:
00249         if (FC_PYPARS.mstp[55]==1) {
00250           return "PYINTERNAL";
00251         } else if(FC_PYPARS.mstp[55]==2) {
00252           return "LHAPDF";
00253         }
00254         break;
00255       default:
00256         break;
00257     }
00258     throw runtime_error("Unknown particle for PDF set");
00259   }

string getPDFSet ( PdgCode  pid  )  [virtual]

Get the PDF set used by the generator, e.g. HWLHAPDF (for herwig) or one of the default sets.

Reimplemented from Generator.

Definition at line 194 of file FPythia.cc.

References AGILe::ANTIPROTON, AGILe::ELECTRON, FC_PYPARS, AGILe::POSITRON, and AGILe::PROTON.

00194                                        {
00195     switch(pid) {
00196       case PROTON:
00197       case ANTIPROTON:
00198         if (FC_PYPARS.mstp[51] == 1) {
00199           return "PYINTERNAL";
00200         } else if(FC_PYPARS.mstp[51] == 2) {
00201           return "PYLHAPDF";
00202         }
00203         break;
00204 
00205       case ELECTRON:
00206       case POSITRON:
00207         if (FC_PYPARS.mstp[55] == 1) {
00208           return "PYINTERNAL";
00209         } else if(FC_PYPARS.mstp[55] == 2) {
00210           return "PYLHAPDF";
00211         }
00212         break;
00213       default:
00214         break;
00215     }
00216     throw runtime_error("Unknown particle for PDF set");
00217   }

virtual const GeneratorState& getState (  )  [inline, virtual, inherited]

Get a generator state object.

Definition at line 72 of file Generator.hh.

References Generator::_myState, GeneratorState::addPDF(), GeneratorState::getBeams(), Generator::getCrossSection(), Generator::getName(), Generator::getPDFMember(), Generator::getPDFScheme(), Generator::getPDFSet(), Generator::getVersion(), PDF::member, Beam::name, PDF::particleId, PDF::scheme, PDF::set, GeneratorState::setCrossSection(), GeneratorState::setName(), and GeneratorState::setVersion().

00072                                              {
00073       string myName = getName();
00074       _myState.setName(myName);
00075       _myState.setVersion(getVersion());
00076       _myState.setCrossSection(getCrossSection());
00077       PDF pdf;
00078       foreach (Beam b, _myState.getBeams()) {
00079         pdf.particleId = b.name;
00080         pdf.set = getPDFSet(b.name);
00081         pdf.member = getPDFMember(b.name);
00082         pdf.scheme = getPDFScheme(b.name);
00083         _myState.addPDF(pdf);
00084       }
00085       return _myState;
00086     }

const string getVersion (  )  [virtual]

Get the generator version. This implementation is used as a last resort to determine the generator version. Ideally a specific generator will know its own version and overwrite this. Some generators (e.g. FHerwig) don't know this.

Todo:
This getName() doesn't get used polymophically: fix it!

Reimplemented from Generator.

Definition at line 268 of file FPythia.cc.

References FC_PYPARS.

00268                                   {
00269     stringstream s;
00270     s << FC_PYPARS.mstp[180] << "." << FC_PYPARS.mstp[181];
00271     return s.str();
00272   }

void initialize (  )  [protected, virtual]

Set up default params etc.

Reimplemented from Generator.

Definition at line 82 of file FPythia.cc.

References FPythia::_e1, FPythia::_e2, Generator::_initialized, FPythia::_particleName1, FPythia::_particleName2, call_pygive(), call_pyinit(), FC_PYPARS, and AGILe::fuzzyEquals().

00082                            {
00083     Generator::initialize();
00084     // Make sure that PYINIT does not call PYTUNE (that should happen when the param is set).
00085     call_pygive("MSTP(5)=0");
00086     // Call pythia initialization with stored parameters as set by setGenSpecificInitialState()
00087     if (FC_PYPARS.mstp[142] != 1) {
00088       if (fuzzyEquals(_e1, _e2)) {
00089         call_pyinit("CMS", _particleName1.c_str(), _particleName2.c_str(), _e1+_e2);
00090       } else {
00091         stringstream p13cmd, p23cmd;
00092         p13cmd << "P(1,3) = " << _e1;
00093         p23cmd << "P(2,3) = " << -_e2;
00094         call_pygive("P(1,1) = 0.0");
00095         call_pygive("P(1,2) = 0.0");
00096         call_pygive(p13cmd.str().c_str());
00097         call_pygive("P(2,1) = 0.0");
00098         call_pygive("P(2,2) = 0.0");
00099         call_pygive(p23cmd.str().c_str());
00100         call_pyinit("3MOM", _particleName1.c_str(), _particleName2.c_str(), 0.0);
00101       }
00102     } else {
00103       // User process, parameters taken from LHAPDF initialisation file.
00104       call_pyinit("USER"," "," ", 0.0);
00105     }
00106     _initialized = true;
00107   }

void makeEvent ( HepMC::GenEvent &  evt  )  [virtual]

Run the generator for one event.

Todo:
Allow control of choice of underlying event and shower evolutions via "meta-params".

Reimplemented from Generator.

Definition at line 132 of file FPythia.cc.

References FPythia::_nevt, call_pyevnt(), call_pyhepc(), and FPythia::fillEvent().

00132                                             {
00133     Generator::makeEvent(evt);
00135     // Generate one event.
00136     call_pyevnt();
00137     // Generate one event with new UE and shower.
00138     //call_pyevnw();
00139     // Convert common PYJETS into common HEPEVT.
00140     call_pyhepc(1);
00141     // Increment an event counter (Pythia does not count for itself).
00142     _nevt++;
00143     // fill the event using HepMC
00144     fillEvent(evt);
00145     evt.set_event_number(_nevt);
00146   }

void setGenSpecificInitialState ( PdgCode  p1 = PROTON,
double  e1 = 7000.0,
PdgCode  p2 = PROTON,
double  e2 = 7000.0 
) [virtual]

Set up initial state from supplied params.

Todo:
Get momenta and energies unconfused.

Implements Generator.

Definition at line 70 of file FPythia.cc.

References FPythia::_e1, FPythia::_e2, FPythia::_particleName1, FPythia::_particleName2, Generator::_particleNames, and MSG_DEBUG.

00070                                                                                        {
00071     MSG_DEBUG("Setting initial state...");
00072     // For Pythia, we have to hold on to this state until initialize() is called.
00073     _particleName1 = _particleNames[p1];
00074     _particleName2 = _particleNames[p2];
00076     _e1 = e1;
00077     _e2 = e2;
00078   }

void setInitialState ( int  p1 = PROTON,
double  e1 = 7000.0,
int  p2 = PROTON,
double  e2 = 7000.0 
) [inline, inherited]

Define initial state.

Todo:
Make sure it was successful - exception handling

Definition at line 54 of file Generator.hh.

References Generator::_initialstateset, Generator::_myState, Beam::energy, Beam::name, Beam::position, GeneratorState::setBeams(), and Generator::setGenSpecificInitialState().

Referenced by Generator::initialize().

00056     {
00057       setGenSpecificInitialState(p1, e1, p2, e2);
00059       _initialstateset = true;
00060       Beam beam1, beam2;
00061       beam1.name = p1;
00062       beam2.name = p2;
00063       beam1.energy = e1;
00064       beam2.energy = e2;
00065       beam1.position = 1;
00066       beam2.position = 2;
00067       _myState.setBeams(beam1, beam2);
00068     }

virtual bool setParam ( const std::string &  name,
const std::string &  value 
) [inline, virtual, inherited]

Pass a string-valued parameter to the generator.

Definition at line 224 of file Generator.hh.

References Generator::_initialized, Generator::_myState, MSG_ERROR, and GeneratorState::setParam().

00224                                                                          {
00225       if (_initialized) {
00226         MSG_ERROR("Can't set parameter " << name << ": generator has already been initialized");
00227         throw runtime_error("Tried to set param after generator initialization");
00228       }
00229       _myState.setParam(name, value);
00230       return true;
00231     }

virtual bool setParam ( const std::string &  name,
const bool &  value 
) [inline, virtual, inherited]

Pass a bool-valued parameter to the generator.

Definition at line 214 of file Generator.hh.

References Generator::_initialized, MSG_ERROR, Generator::setParam(), and AGILe::toString().

00214                                                                     {
00215       if (_initialized) {
00216         MSG_ERROR("Can't set parameter " << name << ": generator has already been initialized");
00217         throw runtime_error("Tried to set param after generator initialization");
00218       }
00219       return setParam(name, toString(value));
00220     }

virtual bool setParam ( const std::string &  name,
const float &  value 
) [inline, virtual, inherited]

Pass a double/float-valued parameter to the generator.

Definition at line 204 of file Generator.hh.

References Generator::_initialized, MSG_ERROR, Generator::setParam(), and AGILe::toString().

00204                                                                      {
00205       if (_initialized) {
00206         MSG_ERROR("Can't set parameter " << name << ": generator has already been initialized");
00207         throw runtime_error("Tried to set param after generator initialization");
00208       }
00209       return setParam(name, toString(value));
00210     }

virtual bool setParam ( const std::string &  name,
const double &  value 
) [inline, virtual, inherited]

Pass a double/float-valued parameter to the generator.

Definition at line 194 of file Generator.hh.

References Generator::_initialized, MSG_ERROR, Generator::setParam(), and AGILe::toString().

00194                                                                       {
00195       if (_initialized) {
00196         MSG_ERROR("Can't set parameter " << name << ": generator has already been initialized");
00197         throw runtime_error("Tried to set param after generator initialization.");
00198       }
00199       return setParam(name, toString(value));
00200     }

virtual bool setParam ( const std::string &  name,
const unsigned long &  value 
) [inline, virtual, inherited]

Pass an int-valued parameter to the generator.

Definition at line 184 of file Generator.hh.

References Generator::_initialized, MSG_ERROR, Generator::setParam(), and AGILe::toString().

00184                                                                              {
00185       if (_initialized) {
00186         MSG_ERROR("Can't set parameter " << name << ": generator has already been initialized");
00187       throw runtime_error("Tried to set param after generator initialization");
00188       }
00189       return setParam(name, toString(value));
00190     }

virtual bool setParam ( const std::string &  name,
const long &  value 
) [inline, virtual, inherited]

Pass an int-valued parameter to the generator.

Definition at line 174 of file Generator.hh.

References Generator::_initialized, MSG_ERROR, Generator::setParam(), and AGILe::toString().

00174                                                                     {
00175       if (_initialized) {
00176         MSG_ERROR("Can't set parameter " << name << ": generator has already been initialized");
00177         throw runtime_error("Tried to set param after generator initialization");
00178       }
00179       return setParam(name, toString(value));
00180     }

virtual bool setParam ( const std::string &  name,
const unsigned int &  value 
) [inline, virtual, inherited]

Pass an int-valued parameter to the generator.

Definition at line 164 of file Generator.hh.

References Generator::_initialized, MSG_ERROR, Generator::setParam(), and AGILe::toString().

00164                                                                             {
00165       if (_initialized) {
00166         MSG_ERROR("Can't set parameter " << name << ": generator has already been initialized");
00167         throw runtime_error("Tried to set param after generator initialization");
00168       }
00169       return setParam(name, toString(value));
00170     }

virtual bool setParam ( const std::string &  name,
const int &  value 
) [inline, virtual, inherited]

Pass an int-valued parameter to the generator.

Definition at line 154 of file Generator.hh.

References Generator::_initialized, MSG_ERROR, and AGILe::toString().

Referenced by Generator::setParam().

00154                                                                    {
00155       if (_initialized) {
00156         MSG_ERROR("Can't set parameter " << name << ": generator has already been initialized");
00157         throw runtime_error("Tried to set param after generator initialization");
00158       }
00159       return setParam(name, toString(value));
00160     }

bool setParam ( const string &  name,
const string &  value 
) [virtual]

Pass an string parameter to the generator.

Reimplemented in AlpGenFPythia, and CharybdisFPythia.

Definition at line 111 of file FPythia.cc.

References AGILe::asInt(), call_lhefopen(), call_pygive(), call_pytune(), MSG_INFO, Generator::SUCCESS, and AGILe::toUpper().

Referenced by FPythia::FPythia(), and FPythia::setSeed().

00111                                                                 {
00112     Generator::setParam(name, value);
00113     const string NAME = toUpper(name);
00114     if (NAME == "PYTUNE" || NAME == "MSTP(5)") {
00115       const int tunenumber = asInt(value);
00116       MSG_INFO("MSTP(5) param or PYTUNE meta-param has been set: calling PYTUNE *now*");
00117       call_pytune(tunenumber);
00118     } else if (NAME == "LHEF") {
00119       MSG_INFO("LHEF meta-param has been set: calling OPEN *now* for LHE file = " << value);
00120       call_lhefopen(value.c_str());
00121       setParam("MSTP(161)", 88);
00122       setParam("MSTP(162)", 88);
00123     } else {
00124       const string pygive_input(name + "=" + value);
00125       call_pygive(pygive_input.c_str());
00126     }
00127     return SUCCESS;
00128   }

virtual void setSeed ( const int  value  )  [inline, virtual]

Set the random number generator seed.

Reimplemented from Generator.

Definition at line 33 of file FPythia.hh.

References FPythia::setParam().

00033                                           {
00034       setParam("MRPY(1)", value);
00035     }

virtual void setState ( const GeneratorState state  )  [inline, virtual, inherited]

Setup the generator from a generator state object.

Definition at line 90 of file Generator.hh.

00090                                                        {
00091       throw runtime_error("This ain't ready yet, it's just here as an interface placeholder. Sorry.");
00092     }

virtual void setVersion ( const std::string &  version  )  [inline, virtual, inherited]

Set the generator version.

Definition at line 102 of file Generator.hh.

References Generator::_myVersion, and Generator::_versionSet.

Referenced by AGILe::Loader::createGen().

00102                                                       {
00103       _myVersion = version;
00104       _versionSet = true;
00105     }


Member Data Documentation

double _e1 [protected]

Definition at line 66 of file FPythia.hh.

Referenced by FPythia::initialize(), and FPythia::setGenSpecificInitialState().

double _e2 [protected]

Definition at line 66 of file FPythia.hh.

Referenced by FPythia::initialize(), and FPythia::setGenSpecificInitialState().

HepMC::IO_HEPEVT _hepevt [protected]

HEPEVT->HepMC converter.

Definition at line 72 of file FPythia.hh.

Referenced by FPythia::fillEvent().

bool _initialized [protected, inherited]
bool _initialstateset [protected, inherited]

Flag for detecting whether the setInitialState method has run.

Definition at line 285 of file Generator.hh.

Referenced by Generator::initialize(), and Generator::setInitialState().

int _nevt [protected]

Event counter.

Definition at line 69 of file FPythia.hh.

Referenced by FPythia::FPythia(), and FPythia::makeEvent().

string _particleName1 [protected]

Internal storage of initial state params.

Definition at line 65 of file FPythia.hh.

Referenced by FPythia::initialize(), and FPythia::setGenSpecificInitialState().

string _particleName2 [protected]

Definition at line 65 of file FPythia.hh.

Referenced by FPythia::initialize(), and FPythia::setGenSpecificInitialState().


The documentation for this class was generated from the following files:
Generated on Tue Mar 6 10:39:40 2012 for AGILe - A Generator Interface Library (+ executable) by  doxygen 1.6.3