VMC Examples Version 6.6
|
Implementation of the TVirtualMCApplication. More...
#include <Ex03cMCApplication.h>
Public Member Functions | |
Ex03cMCApplication (const char *name, const char *title, Bool_t isMulti=kFALSE, Bool_t splitSimulation=kFALSE) | |
Ex03cMCApplication () | |
virtual | ~Ex03cMCApplication () |
void | InitMC (const char *setup) |
void | InitMC (std::initializer_list< const char * > setupMacros) |
void | InitMC () |
void | RunMC (Int_t nofEvents) |
void | FinishRun () |
void | ReadEvent (Int_t i) |
virtual TVirtualMCApplication * | CloneForWorker () const |
virtual void | InitOnWorker () |
virtual void | FinishRunOnWorker () |
virtual void | ConstructGeometry () |
virtual void | InitGeometry () |
virtual void | AddParticles () |
virtual void | AddIons () |
virtual void | GeneratePrimaries () |
virtual void | BeginEvent () |
virtual void | BeginPrimary () |
virtual void | PreTrack () |
virtual void | Stepping () |
virtual void | PostTrack () |
virtual void | FinishPrimary () |
virtual void | FinishEvent () |
void | SetPrintModulo (Int_t value) |
void | SetVerboseLevel (Int_t verboseLevel) |
void | SetControls (Bool_t isConstrols) |
void | SetField (Double_t bz) |
void | SetDebug (Int_t debug) |
Set debug option for multiple run. | |
Ex03cDetectorConstruction * | GetDetectorConstruction () const |
Ex03cCalorimeterSD * | GetCalorimeterSD () const |
Ex03PrimaryGenerator * | GetPrimaryGenerator () const |
void | SetOldGeometry (Bool_t oldGeometry=kTRUE) |
Private Member Functions | |
Ex03cMCApplication (const Ex03cMCApplication &origin) | |
void | RegisterStack () const |
Private Attributes | |
TMCRootManager * | fRootManager |
Root manager. | |
Int_t | fPrintModulo |
The event modulus number to be printed. | |
Int_t | fEventNo |
Event counter. | |
TMCVerbose | fVerbose |
VMC verbose helper. | |
Ex03cMCStack * | fStack |
VMC stack. | |
Ex03cDetectorConstruction * | fDetConstruction |
Dector construction. | |
Ex03cCalorimeterSD * | fCalorimeterSD |
Calorimeter SD. | |
Ex03PrimaryGenerator * | fPrimaryGenerator |
Primary generator. | |
TGeoUniformMagField * | fMagField |
Magnetic field. | |
Bool_t | fOldGeometry |
Option for geometry definition. | |
Bool_t | fIsControls |
Option to activate special controls. | |
Bool_t | fIsMaster |
If is on master thread. | |
Bool_t | fIsMultiRun |
Flag if having multiple engines. | |
Bool_t | fSplitSimulation |
Split geometry given user criteria. | |
Int_t | fG3Id |
engine ID of Geant3 | |
Int_t | fG4Id |
engine ID of Geant4 | |
Int_t | fDebug |
debug option for multiple run | |
Implementation of the TVirtualMCApplication.
A variant of the Ex03MCApplication class updated for multiple engine runs.
Definition at line 45 of file Ex03cMCApplication.h.
Ex03cMCApplication::Ex03cMCApplication | ( | const char * | name, |
const char * | title, | ||
Bool_t | isMulti = kFALSE, | ||
Bool_t | splitSimulation = kFALSE ) |
Standard constructor
name | The MC application name |
title | The MC application description |
Definition at line 48 of file Ex03cMCApplication.cxx.
Ex03cMCApplication::Ex03cMCApplication | ( | ) |
Default constructor
Definition at line 147 of file Ex03cMCApplication.cxx.
|
virtual |
Destructor
Definition at line 170 of file Ex03cMCApplication.cxx.
|
private |
Copy constructor for cloning application on workers (in multithreading mode)
origin | The source MC application |
Definition at line 107 of file Ex03cMCApplication.cxx.
void Ex03cMCApplication::InitMC | ( | const char * | setup | ) |
Initialize MC. The selection (and creation) of the concrete MC is done in the macro. If no macro is provided, the MC must be created before calling this function.
setup | The name of the configuration macro. |
Definition at line 209 of file Ex03cMCApplication.cxx.
void Ex03cMCApplication::InitMC | ( | std::initializer_list< const char * > | setupMacros | ) |
Initialize MC. New function for initialization with multiple engines.
setupMacros | The names of the configuration macros. |
Definition at line 254 of file Ex03cMCApplication.cxx.
void Ex03cMCApplication::InitMC | ( | ) |
Initialize MC. New function for initialization with multiple engines. The MCs must be created before calling this function.
Definition at line 284 of file Ex03cMCApplication.cxx.
void Ex03cMCApplication::RunMC | ( | Int_t | nofEvents | ) |
Run MC.
nofEvents | Number of events to be processed |
Definition at line 327 of file Ex03cMCApplication.cxx.
void Ex03cMCApplication::FinishRun | ( | ) |
Finish MC run.
Definition at line 372 of file Ex03cMCApplication.cxx.
void Ex03cMCApplication::ReadEvent | ( | Int_t | i | ) |
Read i -th event and prints hits.
i | The number of event to be read |
Definition at line 417 of file Ex03cMCApplication.cxx.
|
virtual |
Definition at line 385 of file Ex03cMCApplication.cxx.
|
virtual |
Definition at line 391 of file Ex03cMCApplication.cxx.
|
virtual |
Definition at line 407 of file Ex03cMCApplication.cxx.
|
virtual |
Construct geometry using detector contruction class. The detector contruction class is using TGeo functions or TVirtualMC functions (if oldGeometry is selected)
Definition at line 428 of file Ex03cMCApplication.cxx.
|
virtual |
Initialize geometry
Definition at line 446 of file Ex03cMCApplication.cxx.
|
virtual |
Example of user defined particle with user defined decay mode
Definition at line 460 of file Ex03cMCApplication.cxx.
|
virtual |
Example of user defined ion
Definition at line 507 of file Ex03cMCApplication.cxx.
|
virtual |
Fill the user stack (derived from TVirtualMCStack) with primary particles.
Definition at line 516 of file Ex03cMCApplication.cxx.
|
virtual |
User actions at beginning of event
Definition at line 529 of file Ex03cMCApplication.cxx.
|
virtual |
User actions at beginning of a primary track. If test for user defined decay is activated, the primary track ID is printed on the screen.
Definition at line 553 of file Ex03cMCApplication.cxx.
|
virtual |
User actions at beginning of each track If test for user defined decay is activated, the decay products of the primary track (K0Short) are printed on the screen.
Definition at line 567 of file Ex03cMCApplication.cxx.
|
virtual |
User actions at each step
Definition at line 594 of file Ex03cMCApplication.cxx.
|
virtual |
User actions after finishing of each track
Definition at line 635 of file Ex03cMCApplication.cxx.
|
virtual |
User actions after finishing of a primary track
Definition at line 642 of file Ex03cMCApplication.cxx.
|
virtual |
User actions after finishing of an event
Definition at line 654 of file Ex03cMCApplication.cxx.
|
inline |
Set the event modulus number to be printed
value | The new event modulus number value |
Definition at line 127 of file Ex03cMCApplication.h.
|
inline |
Set verbosity
verboseLevel | The new verbose level value |
Definition at line 134 of file Ex03cMCApplication.h.
|
inline |
Switch on/off special process controls
isControls | If true, special process controls setting is activated |
Definition at line 177 of file Ex03cMCApplication.h.
|
inline |
Set magnetic field
bz | The new field value in z |
Definition at line 141 of file Ex03cMCApplication.h.
|
inline |
Set debug option for multiple run.
Definition at line 147 of file Ex03cMCApplication.h.
|
inline |
Definition at line 151 of file Ex03cMCApplication.h.
|
inline |
Definition at line 157 of file Ex03cMCApplication.h.
|
inline |
Definition at line 163 of file Ex03cMCApplication.h.
|
inline |
Switch on/off the old geometry definition (via VMC functions)
oldGeometry | If true, geometry definition via VMC functions |
Definition at line 170 of file Ex03cMCApplication.h.
|
private |
Register stack in the Root manager.
Definition at line 194 of file Ex03cMCApplication.cxx.
|
mutableprivate |
Root manager.
Definition at line 99 of file Ex03cMCApplication.h.
|
private |
The event modulus number to be printed.
Definition at line 100 of file Ex03cMCApplication.h.
|
private |
Event counter.
Definition at line 101 of file Ex03cMCApplication.h.
|
private |
VMC verbose helper.
Definition at line 102 of file Ex03cMCApplication.h.
|
private |
VMC stack.
Definition at line 103 of file Ex03cMCApplication.h.
|
private |
Dector construction.
Definition at line 104 of file Ex03cMCApplication.h.
|
private |
Calorimeter SD.
Definition at line 105 of file Ex03cMCApplication.h.
|
private |
Primary generator.
Definition at line 106 of file Ex03cMCApplication.h.
|
private |
Magnetic field.
Definition at line 107 of file Ex03cMCApplication.h.
|
private |
Option for geometry definition.
Definition at line 108 of file Ex03cMCApplication.h.
|
private |
Option to activate special controls.
Definition at line 109 of file Ex03cMCApplication.h.
|
private |
If is on master thread.
Definition at line 110 of file Ex03cMCApplication.h.
|
private |
Flag if having multiple engines.
Definition at line 111 of file Ex03cMCApplication.h.
|
private |
Split geometry given user criteria.
Definition at line 112 of file Ex03cMCApplication.h.
|
private |
engine ID of Geant3
Definition at line 113 of file Ex03cMCApplication.h.
|
private |
engine ID of Geant4
Definition at line 114 of file Ex03cMCApplication.h.
|
private |
debug option for multiple run
Definition at line 115 of file Ex03cMCApplication.h.