#include "TVirtualMC.h"
-#include "TMCProcess.h"
+#include "TMCProcess.h"
//Forward declaration
class TFlukaMCGeometry;
+class TGeoMaterial;
class TFluka : public TVirtualMC {
// set methods
virtual void SetProcess(const char* flagName, Int_t flagValue);
+ virtual void SetProcess(const char* flagName, Int_t flagValue, Int_t imed);
virtual void SetCut(const char* cutName, Double_t cutValue);
+ virtual void SetCut(const char* cutName, Double_t cutValue, Int_t imed);
virtual Double_t Xsec(char*, Double_t, Int_t, Int_t);
// particle table usage
void SetInputFileName(const char* n) {sInputFileName = n;}
// - SetProcess and SetCut
- Int_t GetProcessNb() const {return iNbOfProc;}
- void SetProcessNb(Int_t l) {iNbOfProc = l;}
- Int_t GetCutNb() const {return iNbOfProc;}
- void SetCutNb(Int_t l) {iNbOfCut = l;}
+ Int_t GetProcessNb() const {return fNbOfProc;}
+ void SetProcessNb(Int_t l) {fNbOfProc = l;}
+ Int_t GetCutNb() const {return fNbOfProc;}
+ void SetCutNb(Int_t l) {fNbOfCut = l;}
// - Verbosity level
Int_t GetVerbosityLevel() const {return fVerbosityLevel;}
void SetCurrentFlukaRegion(Int_t reg) {fCurrentFlukaRegion=reg;}
Int_t GetCurrentFlukaRegion() const {return fCurrentFlukaRegion;}
+ void SetDummyBoundary(Int_t mode) {fDummyBoundary = mode;}
+ Int_t GetDummyBoundary() const {return fDummyBoundary;}
+ Bool_t IsDummyBoundary() const {return (fDummyBoundary==0)?kFALSE:kTRUE;}
+ void EnableField(Bool_t flag=kTRUE) {fFieldFlag = flag;}
+ Bool_t IsFieldEnabled() const {return fFieldFlag;}
void SetTrackIsEntering(){fTrackIsEntering = kTRUE; fTrackIsExiting = kFALSE;}
void SetTrackIsExiting() {fTrackIsExiting = kTRUE; fTrackIsEntering = kFALSE;}
void SetTrackIsInside() {fTrackIsExiting = kFALSE; fTrackIsEntering = kFALSE;}
void SetTrackIsNew(Bool_t flag=kTRUE) {fTrackIsNew = flag;}
+ Int_t GetMaterialIndex(Int_t idmat) {return fMaterials[idmat];}
-
private:
TFluka(const TFluka &mc): TVirtualMC(mc) {;}
TFluka & operator=(const TFluka &) {return (*this);}
protected:
+
Int_t fVerbosityLevel; //Verbosity level (0 lowest - 3 highest)
TString sInputFileName; //Name of the real input file (e.g. alice.inp)
Bool_t fTrackIsEntering; // Flag for track entering
Bool_t fTrackIsExiting; // Flag for track exiting
Bool_t fTrackIsNew; // Flag for new track
-
+ Bool_t fFieldFlag; // Flag for magnetic field
+ Int_t fDummyBoundary; // Flag for crossing dummy boundaries
//variables for SetProcess and SetCut
- Int_t iNbOfProc;
- Int_t iProcessValue[100];
- Char_t sProcessFlag[100][5];
- Int_t iNbOfCut;
- Double_t fCutValue[100];
- Char_t sCutFlag[100][7];
+ Int_t fNbOfProc;
+ Int_t fProcessValue[10000];
+ Int_t fProcessMaterial[10000];
+ Char_t fProcessFlag[10000][5];
+ Int_t fNbOfCut;
+ Double_t fCutValue[10000];
+ Char_t fCutFlag[10000][7];
+ Int_t fCutMaterial[10000];
- //Geometry through Geant4 for the time being!!!
- Int_t fNVolumes; //!Current number of volumes
+ //Geometry through TGeo
+ Int_t* fMaterials; //!Array of indices
+ Int_t fNVolumes; //!Current number of volumes
Int_t fCurrentFlukaRegion; //Index of fluka region at each step
TFlukaMCGeometry *fGeom; // TGeo-FLUKA interface