File: EventHandler.h
Description:
The EventHandler class is the main class for handeling
simple events without overlayed collisions. It is derived from the
CollisionHandler class and introduces a
LuminosityFunction to describe the momentum
distribution of incoming particles.
Besides the standard doinit method, the
EventHandler needs to be separately initialized with the
initialize method. In the dofinish method statistics is
written out to the EventGenerators default output
file
See
also:
namespace Pythia7
CLASS
EventHandler:
Base class:
Public members:
EventHandler(const EventHandler &);
EventHandler();
~EventHandler();
Standard ctors and dtor.
virtual void initialize();
Initialize this event handler and all that is needed to generate event.
virtual void statistics(ostream &) const;
Write out accumulated statistics about intergrated cross sections
and stuff.
virtual EventPtr generateEvent();
virtual EventPtr continueEvent();
Generate an event.
inline long maxLoop() const;
Return the maximum number attemts allowed to select a sub-process
for each event.
inline int statLevel() const;
Controlls the amount of statistics written out after each run to
the EventGenerators .out file.
inline bool weighted() const;
Return true if this event handler should produce weightes events
inline bool compensating() const;
Returns true if we are compensating for weight larger than 1.
inline const LuminosityFunction & lumiFn() const;
Access to the luminosity function.
inline int lumiDim() const;
The number of phase space dimensions used by the luminosity
function.
inline int nDim(int bin) const;
The number of dimensions of the basic phase space to generate
sub-processes in for a given bin.
virtual CrossSection dSigDR(const vector<double> & r);
Return the cross section for the chosen phase space point.
virtual void doupdate() throw(UpdateException);
inline virtual void doinit() throw(InitException);
virtual void dofinish();
Standard Interfaced virtual functions.
void persistentOutput(PersistentOStream &) const;
void persistentInput(PersistentIStream &, int);
Standard functions for writing and reading from persistent streams.
static void Init();
Standard Init function used to initialize the interface.
Protected members:
virtual IBPtr clone() const;
Standard clone method.
inline LuminosityFunction & lumiFn();
Access to the luminosity function.
void reject(double weight);
Reject a (partially) generated event.
inline tSamplerPtr sampler();
inline tcSamplerPtr sampler() const;
Return the sampler assigned to this event handler.
Private members:
void lumiFn(LumiFnPtr);
Set the luminosity function
LumiFnPtr theLumiFn;
Pointer to the luminosity function.
bool weightedEvents;
True if this event handler should produce weightes events
long theMaxLoop;
The maximum number of attempts to select a sub-process allowed
per event.
int theStatLevel;
Controlls the amount of statistics written out after each run to
the EventGenerators .out file.
SamplerPtr theSampler;
The phase space sampler responsible for generating phase space
points according to the cross section given by this event
handler.
int theLumiDim;
The number of phase space dimensions used by the luminosity
function.
int theNDim;
The number of dimensions of the basic phase space to generate
sub-processes in.
static ClassDescription<EventHandler> initEventHandler;
Standard Initialization object.
const EventHandler & operator=(const EventHandler &);
Private and non-existent assignment operator.
template <>
STRUCT
BaseClassTrait<EventHandler,1>
Public members:
typedef CollisionHandler NthBase;
template <>
STRUCT
ClassTraits<EventHandler>:
Public members:
static string className() { return "/Pythia7/EventHandler"; }
DEFINED MACROS
INCLUDED FILES
Pythia7/Config/Pythia7.h
Pythia7/Handlers/CollisionHandler.h
Pythia7/Handlers/EventHandler.xh
Pythia7/Repository/Strategy.fh
Pythia7/Handlers/SamplerBase.fh
fstream
EventHandler.icc