diff --git a/montecarlo/vmc/inc/TGeoMCGeometry.h b/montecarlo/vmc/inc/TGeoMCGeometry.h index 34a3b2899545479b4537c8d03ce0364f60871ebd..0277833eafa5847785bbbbdda3716bf6210ac11d 100644 --- a/montecarlo/vmc/inc/TGeoMCGeometry.h +++ b/montecarlo/vmc/inc/TGeoMCGeometry.h @@ -140,10 +140,10 @@ private: Double_t* CreateDoubleArray(Float_t* array, Int_t size) const; void Vname(const char *name, char *vname) const; - Bool_t fG3CompatibleVolumeNames; // option to convert volumes names to - // be compatible with G3 + /// Option to convert volumes names to be compatible with G3 + Bool_t fG3CompatibleVolumeNames; - static TGeoMCGeometry* fgInstance; // singleton instance + static TGeoMCGeometry* fgInstance; ///< Singleton instance ClassDef(TGeoMCGeometry,2) // VMC TGeo Geometry builder }; diff --git a/montecarlo/vmc/inc/TMCOptical.h b/montecarlo/vmc/inc/TMCOptical.h index 0f53e6c1a76dbe8d06c88aa8c3730c1de79993a8..f80db4ea68c540311443e14eb01d9420acbf5f8e 100644 --- a/montecarlo/vmc/inc/TMCOptical.h +++ b/montecarlo/vmc/inc/TMCOptical.h @@ -17,28 +17,31 @@ // #include "Rtypes.h" +/// Optical surface models enum EMCOpSurfaceModel { - kGlisur, // original GEANT3 model - kUnified // UNIFIED model + kGlisur, ///< original GEANT3 model + kUnified ///< UNIFIED model }; +/// Optical surface types enum EMCOpSurfaceType { - kDielectric_metal, // dielectric-metal interface - kDielectric_dielectric, // dielectric-dielectric interface - kFirsov, // for Firsov Process - kXray // for x-ray mirror process + kDielectric_metal, ///< dielectric-metal interface + kDielectric_dielectric, ///< dielectric-dielectric interface + kFirsov, ///< for Firsov Process + kXray ///< for x-ray mirror process }; +/// Optical surface finish types enum EMCOpSurfaceFinish { - kPolished, // smooth perfectly polished surface - kPolishedfrontpainted, // smooth top-layer (front) paint - kPolishedbackpainted, // same is 'polished' but with a back-paint - kGround, // rough surface - kGroundfrontpainted, // rough top-layer (front) paint - kGroundbackpainted // same as 'ground' but with a back-paint + kPolished, ///< smooth perfectly polished surface + kPolishedfrontpainted, ///< smooth top-layer (front) paint + kPolishedbackpainted, ///< same is 'polished' but with a back-paint + kGround, ///< rough surface + kGroundfrontpainted, ///< rough top-layer (front) paint + kGroundbackpainted ///< same as 'ground' but with a back-paint }; #endif //ROOT_TMCOPtical diff --git a/montecarlo/vmc/inc/TMCParticleType.h b/montecarlo/vmc/inc/TMCParticleType.h index a27387a506a1c3482ddc84541a2eb23a11530bde..1e2d8cfe5cfb3b301dc9f303afda5e9300360ff0 100644 --- a/montecarlo/vmc/inc/TMCParticleType.h +++ b/montecarlo/vmc/inc/TMCParticleType.h @@ -20,18 +20,19 @@ #include "Rtypes.h" +/// VMC particle type codes enum TMCParticleType { - kPTGamma, // particle tracked as gamma - kPTElectron, // particle tracked as electron - kPTNeutron, // particle tracked as neutron - kPTHadron, // particle tracked as hadron - kPTMuon, // particle tracked as muon - kPTGeantino, // particle tracked as geantino - kPTChargedGeantino,// particle tracked as charged geantino - kPTOpticalPhoton, // particle tracked as light photon - kPTIon, // particle tracked as heavy ion - kPTUndefined // unknown particle type + kPTGamma, ///< particle tracked as gamma + kPTElectron, ///< particle tracked as electron + kPTNeutron, ///< particle tracked as neutron + kPTHadron, ///< particle tracked as hadron + kPTMuon, ///< particle tracked as muon + kPTGeantino, ///< particle tracked as geantino + kPTChargedGeantino,///< particle tracked as charged geantino + kPTOpticalPhoton, ///< particle tracked as light photon + kPTIon, ///< particle tracked as heavy ion + kPTUndefined ///< unknown particle type }; #endif diff --git a/montecarlo/vmc/inc/TMCProcess.h b/montecarlo/vmc/inc/TMCProcess.h index e87e7898b269c5dc78decf46288fcc38ff95aeac..3122e1370e48f642e867ed274e5ad358dd871d1c 100644 --- a/montecarlo/vmc/inc/TMCProcess.h +++ b/montecarlo/vmc/inc/TMCProcess.h @@ -19,71 +19,72 @@ const Int_t kMaxMCProcess = 49; +/// VMC physics process codes enum TMCProcess { - kPPrimary = 0, // Primary interaction - - kPMultipleScattering = 1, // multiple scattering - kPCoulombScattering = 45, // single Coulomb scattering - kPEnergyLoss = 2, // continuous energy loss - kPMagneticFieldL = 3, // bending in mag. field - kPDecay = 4, // particle decay - kPPair = 5, // photon pair production or - // muon direct pair production - kPCompton = 6, // Compton scattering - kPPhotoelectric = 7, // photoelectric effect - kPBrem = 8, // bremsstrahlung - kPDeltaRay = 9, // delta-ray production - kPAnnihilation = 10, // positron annihilation - kPAnnihilationRest = 11, // positron annihilation at rest - kPAnnihilationFlight = 12, // positron annihilation in flight - - kPHadronic = 13, // hadronic interaction - kPEvaporation = 14, // nuclear evaporation - kPNuclearFission = 15, // nuclear fission - kPNuclearAbsorption = 16, // nuclear absorption - kPPbarAnnihilation = 17, // antiproton annihilation - kPNbarAnnihilation = 18, // antineutron annihilation - kPNCapture = 19, // neutron capture - kPHElastic = 20, // hadronic elastic scattering - kPHIElastic = 21, // hadronic elastic incoherent scattering - kPHCElastic = 22, // hadronic elastic coherent scattering - kPHInhelastic = 23, // hadronic inelastic scattering - kPPhotonInhelastic = 24, // photon inelastic scattering - - kPMuonNuclear = 25, // muon nuclear interaction - kPElectronNuclear = 26, // electron nuclear interaction - kPPositronNuclear = 27, // positron nuclear interaction - kPPhotoNuclear = 46, // photo nuclear interaction - - kPTOFlimit = 28, // exceeded time of flight cut - kPPhotoFission = 29, // nuclear photofission - - kPRayleigh = 30, // Rayleigh scattering - - kPNull = 31, // no mechanism is active, usually at the entrance - // of a new volume - kPStop = 32, // particle has fallen below energy threshold - // and tracking stops - - kPLightAbsorption = 33, // Cerenkov photon absorption - kPLightDetection = 34, // Optical photon detection (absorption + photoelectron production) - kPLightScattering = 35, // Cerenkov photon reflection/refraction - kPLightWLShifting = 48, // Optical photon wavelength shifting - kStepMax = 36, // step limited by STEMAX - - kPCerenkov = 37, // Cerenkov photon generation - kPFeedBackPhoton = 38, // Feed back photon in RICH -- ALICE specific - kPLightReflection = 39, // Cerenkov photon reflection - kPLightRefraction = 40, // Cerenkov photon refraction or - // dichroic mirror transmission - kPSynchrotron = 41, // synchrotron radiation generation - kPScintillation = 42, // scintillation - - kPTransportation = 43, // Transportation - kPUserDefined = 47, // User defined process - - kPNoProcess = 44 // unknown process + kPPrimary = 0, ///< Primary interaction + + kPMultipleScattering = 1, ///< multiple scattering + kPCoulombScattering = 45, ///< single Coulomb scattering + kPEnergyLoss = 2, ///< continuous energy loss + kPMagneticFieldL = 3, ///< bending in mag. field + kPDecay = 4, ///< particle decay + kPPair = 5, ///< photon pair production or + ///< muon direct pair production + kPCompton = 6, ///< Compton scattering + kPPhotoelectric = 7, ///< photoelectric effect + kPBrem = 8, ///< bremsstrahlung + kPDeltaRay = 9, ///< delta-ray production + kPAnnihilation = 10, ///< positron annihilation + kPAnnihilationRest = 11, ///< positron annihilation at rest + kPAnnihilationFlight = 12, ///< positron annihilation in flight + + kPHadronic = 13, ///< hadronic interaction + kPEvaporation = 14, ///< nuclear evaporation + kPNuclearFission = 15, ///< nuclear fission + kPNuclearAbsorption = 16, ///< nuclear absorption + kPPbarAnnihilation = 17, ///< antiproton annihilation + kPNbarAnnihilation = 18, ///< antineutron annihilation + kPNCapture = 19, ///< neutron capture + kPHElastic = 20, ///< hadronic elastic scattering + kPHIElastic = 21, ///< hadronic elastic incoherent scattering + kPHCElastic = 22, ///< hadronic elastic coherent scattering + kPHInhelastic = 23, ///< hadronic inelastic scattering + kPPhotonInhelastic = 24, ///< photon inelastic scattering + + kPMuonNuclear = 25, ///< muon nuclear interaction + kPElectronNuclear = 26, ///< electron nuclear interaction + kPPositronNuclear = 27, ///< positron nuclear interaction + kPPhotoNuclear = 46, ///< photo nuclear interaction + + kPTOFlimit = 28, ///< exceeded time of flight cut + kPPhotoFission = 29, ///< nuclear photofission + + kPRayleigh = 30, ///< Rayleigh scattering + + kPNull = 31, ///< no mechanism is active, usually at the entrance + ///< of a new volume + kPStop = 32, ///< particle has fallen below energy threshold + ///< and tracking stops + + kPLightAbsorption = 33, ///< Cerenkov photon absorption + kPLightDetection = 34, ///< Optical photon detection (absorption + photoelectron production) + kPLightScattering = 35, ///< Cerenkov photon reflection/refraction + kPLightWLShifting = 48, ///< Optical photon wavelength shifting + kStepMax = 36, ///< step limited by STEMAX + + kPCerenkov = 37, ///< Cerenkov photon generation + kPFeedBackPhoton = 38, ///< Feed back photon in RICH -- ALICE specific + kPLightReflection = 39, ///< Cerenkov photon reflection + kPLightRefraction = 40, ///< Cerenkov photon refraction or + /// dichroic mirror transmission + kPSynchrotron = 41, ///< synchrotron radiation generation + kPScintillation = 42, ///< scintillation + + kPTransportation = 43, ///< Transportation + kPUserDefined = 47, ///< User defined process + + kPNoProcess = 44 ///< unknown process }; static const char * const TMCProcessName[kMaxMCProcess] = { diff --git a/montecarlo/vmc/inc/TMCVerbose.h b/montecarlo/vmc/inc/TMCVerbose.h index 277043fccbee1e1b0f3b1ff5db8406d71982d077..9869ed0a50dece91109020be43843841a82ab181 100644 --- a/montecarlo/vmc/inc/TMCVerbose.h +++ b/montecarlo/vmc/inc/TMCVerbose.h @@ -16,7 +16,7 @@ // // Class TMCVerbose // ---------------- -// Class for printing detailed info from MC application. +// Class for printing a detailed infomation from MC application. // Defined levels: // 0 no output // 1 info up to event level @@ -63,8 +63,8 @@ private: void PrintStepHeader() const; // data members - Int_t fLevel; // verbose level - Int_t fStepNumber; // current step number + Int_t fLevel; ///< Verbose level + Int_t fStepNumber; ///< Current step number ClassDef(TMCVerbose,1) //Verbose class for MC application }; diff --git a/montecarlo/vmc/inc/TVirtualMC.h b/montecarlo/vmc/inc/TVirtualMC.h index f45f2a8eea742514ab1f3fbc4d861080299a7ad5..0f869ece570f35ccf0dcc9652ec7dfbb6722402f 100644 --- a/montecarlo/vmc/inc/TVirtualMC.h +++ b/montecarlo/vmc/inc/TVirtualMC.h @@ -41,19 +41,20 @@ class TArrayD; class TVirtualMC : public TNamed { public: - // Standard constructor - // isRootGeometrySupported = True if implementation of TVirtualMC - // supports geometry defined with TGeo + /// Standard constructor + /// + /// isRootGeometrySupported = True if implementation of TVirtualMC + /// supports geometry defined with TGeo TVirtualMC(const char *name, const char *title, Bool_t isRootGeometrySupported = kFALSE); - // Default constructor + /// Default constructor TVirtualMC(); - // Destructor + /// Destructor virtual ~TVirtualMC(); - // Static access method + /// Static access method static TVirtualMC* GetMC(); // @@ -62,7 +63,7 @@ public: // ------------------------------------------------ // - // Info about supporting geometry defined via Root + /// Info about supporting geometry defined via Root virtual Bool_t IsRootGeometrySupported() const = 0; // @@ -70,99 +71,99 @@ public: // ------------------------------------------------ // - // Define a material - // kmat number assigned to the material - // name material name - // a atomic mass in au - // z atomic number - // dens density in g/cm3 - // absl absorption length in cm; - // if >=0 it is ignored and the program - // calculates it, if <0. -absl is taken - // radl radiation length in cm - // if >=0 it is ignored and the program - // calculates it, if <0. -radl is taken - // buf pointer to an array of user words - // nwbuf number of user words + /// Define a material + /// - kmat number assigned to the material + /// - name material name + /// - a atomic mass in au + /// - z atomic number + /// - dens density in g/cm3 + /// - absl absorption length in cm; + /// if >=0 it is ignored and the program + /// calculates it, if <0. -absl is taken + /// - radl radiation length in cm + /// if >=0 it is ignored and the program + /// calculates it, if <0. -radl is taken + /// - buf pointer to an array of user words + /// - nwbuf number of user words virtual void Material(Int_t& kmat, const char* name, Double_t a, Double_t z, Double_t dens, Double_t radl, Double_t absl, Float_t* buf, Int_t nwbuf) = 0; - // The same as previous but in double precision + /// The same as previous but in double precision virtual void Material(Int_t& kmat, const char* name, Double_t a, Double_t z, Double_t dens, Double_t radl, Double_t absl, Double_t* buf, Int_t nwbuf) = 0; - // Define mixture or compound - // with a number kmat composed by the basic nlmat materials defined - // by arrays a, z and wmat - // - // If nlmat > 0 then wmat contains the proportion by - // weights of each basic material in the mixture. - // - // If nlmat < 0 then wmat contains the number of atoms - // of a given kind into the molecule of the compound. - // In this case, wmat in output is changed to relative - // weights. + /// Define a mixture or a compound + /// with a number kmat composed by the basic nlmat materials defined + /// by arrays a, z and wmat + /// + /// If nlmat > 0 then wmat contains the proportion by + /// weights of each basic material in the mixture. + /// + /// If nlmat < 0 then wmat contains the number of atoms + /// of a given kind into the molecule of the compound. + /// In this case, wmat in output is changed to relative + /// weights. virtual void Mixture(Int_t& kmat, const char *name, Float_t *a, Float_t *z, Double_t dens, Int_t nlmat, Float_t *wmat) = 0; - // The same as previous but in double precision + /// The same as previous but in double precision virtual void Mixture(Int_t& kmat, const char *name, Double_t *a, Double_t *z, Double_t dens, Int_t nlmat, Double_t *wmat) = 0; - // Define a medium. - // kmed tracking medium number assigned - // name tracking medium name - // nmat material number - // isvol sensitive volume flag - // ifield magnetic field: - // - ifield = 0 if no magnetic field; - // - ifield = -1 if user decision in guswim; - // - ifield = 1 if tracking performed with g3rkuta; - // - ifield = 2 if tracking performed with g3helix; - // - ifield = 3 if tracking performed with g3helx3. - // fieldm max. field value (kilogauss) - // tmaxfd max. angle due to field (deg/step) - // stemax max. step allowed - // deemax max. fraction of energy lost in a step - // epsil tracking precision (cm) - // stmin min. step due to continuous processes (cm) - // ubuf pointer to an array of user words - // nbuf number of user words + /// Define a medium. + /// - kmed tracking medium number assigned + /// - name tracking medium name + /// - nmat material number + /// - isvol sensitive volume flag + /// - ifield magnetic field: + /// - ifield = 0 if no magnetic field; + /// - ifield = -1 if user decision in guswim; + /// - ifield = 1 if tracking performed with g3rkuta; + /// - ifield = 2 if tracking performed with g3helix; + /// - ifield = 3 if tracking performed with g3helx3. + /// - fieldm max. field value (kilogauss) + /// - tmaxfd max. angle due to field (deg/step) + /// - stemax max. step allowed + /// - deemax max. fraction of energy lost in a step + /// - epsil tracking precision (cm) + /// - stmin min. step due to continuous processes (cm) + /// - ubuf pointer to an array of user words + /// - nbuf number of user words virtual void Medium(Int_t& kmed, const char *name, Int_t nmat, Int_t isvol, Int_t ifield, Double_t fieldm, Double_t tmaxfd, Double_t stemax, Double_t deemax, Double_t epsil, Double_t stmin, Float_t* ubuf, Int_t nbuf) = 0; - // The same as previous but in double precision + /// The same as previous but in double precision virtual void Medium(Int_t& kmed, const char *name, Int_t nmat, Int_t isvol, Int_t ifield, Double_t fieldm, Double_t tmaxfd, Double_t stemax, Double_t deemax, Double_t epsil, Double_t stmin, Double_t* ubuf, Int_t nbuf) = 0; - // Define a rotation matrix - // krot rotation matrix number assigned - // thetaX polar angle for axis X - // phiX azimuthal angle for axis X - // thetaY polar angle for axis Y - // phiY azimuthal angle for axis Y - // thetaZ polar angle for axis Z - // phiZ azimuthal angle for axis Z + /// Define a rotation matrix + /// - krot rotation matrix number assigned + /// - thetaX polar angle for axis X + /// - phiX azimuthal angle for axis X + /// - thetaY polar angle for axis Y + /// - phiY azimuthal angle for axis Y + /// - thetaZ polar angle for axis Z + /// - phiZ azimuthal angle for axis Z virtual void Matrix(Int_t& krot, Double_t thetaX, Double_t phiX, Double_t thetaY, Double_t phiY, Double_t thetaZ, Double_t phiZ) = 0; - // Change the value of cut or mechanism param - // to a new value parval for tracking medium itmed. - // In Geant3, the data structure JTMED contains the standard tracking - // parameters (CUTS and flags to control the physics processes) which - // are used by default for all tracking media. - // It is possible to redefine individually with this function any of these - // parameters for a given tracking medium. - // itmed tracking medium number - // param is a character string (variable name) - // parval must be given as a floating point. + /// Change the value of cut or mechanism param + /// to a new value parval for tracking medium itmed. + /// In Geant3, the data structure JTMED contains the standard tracking + /// parameters (CUTS and flags to control the physics processes) which + /// are used by default for all tracking media. + /// It is possible to redefine individually with this function any of these + /// parameters for a given tracking medium. + /// - itmed tracking medium number + /// - param is a character string (variable name) + /// - parval must be given as a floating point. virtual void Gstpar(Int_t itmed, const char *param, Double_t parval) = 0; // @@ -170,109 +171,109 @@ public: // ------------------------------------------------ // - // Create a new volume - // name Volume name - // shape Volume type - // nmed Tracking medium number - // np Number of shape parameters - // upar Vector containing shape parameters + /// Create a new volume + /// - name Volume name + /// - shape Volume type + /// - nmed Tracking medium number + /// - np Number of shape parameters + /// - upar Vector containing shape parameters virtual Int_t Gsvolu(const char *name, const char *shape, Int_t nmed, Float_t *upar, Int_t np) = 0; - // The same as previous but in double precision + /// The same as previous but in double precision virtual Int_t Gsvolu(const char *name, const char *shape, Int_t nmed, Double_t *upar, Int_t np) = 0; - // Create a new volume by dividing an existing one. - // It divides a previously defined volume - // name Volume name - // mother Mother volume name - // ndiv Number of divisions - // iaxis Axis value: - // X,Y,Z of CAXIS will be translated to 1,2,3 for IAXIS. + /// Create a new volume by dividing an existing one. + /// It divides a previously defined volume + /// - name Volume name + /// - mother Mother volume name + /// - ndiv Number of divisions + /// - iaxis Axis value: + /// X,Y,Z of CAXIS will be translated to 1,2,3 for IAXIS. virtual void Gsdvn(const char *name, const char *mother, Int_t ndiv, Int_t iaxis) = 0; - // Create a new volume by dividing an existing one. - // Divide mother into ndiv divisions called name - // along axis iaxis starting at coordinate value c0i. - // The new volume created will be medium number numed. + /// Create a new volume by dividing an existing one. + /// Divide mother into ndiv divisions called name + /// along axis iaxis starting at coordinate value c0i. + /// The new volume created will be medium number numed. virtual void Gsdvn2(const char *name, const char *mother, Int_t ndiv, Int_t iaxis, Double_t c0i, Int_t numed) = 0; - // Create a new volume by dividing an existing one - // Divide mother into divisions called name along - // axis iaxis in steps of step. If not exactly divisible - // will make as many as possible and will center them - // with respect to the mother. Divisions will have medium - // number numed. If numed is 0, numed of mother is taken. - // ndvmx is the expected maximum number of divisions - // (If 0, no protection tests are performed in Geant3) + /// Create a new volume by dividing an existing one + /// Divide mother into divisions called name along + /// axis iaxis in steps of step. If not exactly divisible + /// will make as many as possible and will center them + /// with respect to the mother. Divisions will have medium + /// number numed. If numed is 0, numed of mother is taken. + /// ndvmx is the expected maximum number of divisions + /// (If 0, no protection tests are performed in Geant3) virtual void Gsdvt(const char *name, const char *mother, Double_t step, Int_t iaxis, Int_t numed, Int_t ndvmx) = 0; - // Create a new volume by dividing an existing one - // Divides mother into divisions called name along - // axis iaxis starting at coordinate value c0 with step - // size step. - // The new volume created will have medium number numed. - // If numed is 0, numed of mother is taken. - // ndvmx is the expected maximum number of divisions - // (If 0, no protection tests are performed in Geant3) + /// Create a new volume by dividing an existing one + /// Divides mother into divisions called name along + /// axis iaxis starting at coordinate value c0 with step + /// size step. + /// The new volume created will have medium number numed. + /// If numed is 0, numed of mother is taken. + /// ndvmx is the expected maximum number of divisions + /// (If 0, no protection tests are performed in Geant3) virtual void Gsdvt2(const char *name, const char *mother, Double_t step, Int_t iaxis, Double_t c0, Int_t numed, Int_t ndvmx) = 0; - // Flag volume name whose contents will have to be ordered - // along axis iax, by setting the search flag to -iax - // (Geant3 only) + /// Flag volume name whose contents will have to be ordered + /// along axis iax, by setting the search flag to -iax + /// (Geant3 only) virtual void Gsord(const char *name, Int_t iax) = 0; - // Position a volume into an existing one. - // It positions a previously defined volume in the mother. - // name Volume name - // nr Copy number of the volume - // mother Mother volume name - // x X coord. of the volume in mother ref. sys. - // y Y coord. of the volume in mother ref. sys. - // z Z coord. of the volume in mother ref. sys. - // irot Rotation matrix number w.r.t. mother ref. sys. - // konly ONLY/MANY flag + /// Position a volume into an existing one. + /// It positions a previously defined volume in the mother. + /// - name Volume name + /// - nr Copy number of the volume + /// - mother Mother volume name + /// - x X coord. of the volume in mother ref. sys. + /// - y Y coord. of the volume in mother ref. sys. + /// - z Z coord. of the volume in mother ref. sys. + /// - irot Rotation matrix number w.r.t. mother ref. sys. + /// - konly ONLY/MANY flag virtual void Gspos(const char *name, Int_t nr, const char *mother, Double_t x, Double_t y, Double_t z, Int_t irot, const char *konly="ONLY") = 0; - // Place a copy of generic volume name with user number - // nr inside mother, with its parameters upar(1..np) + /// Place a copy of generic volume name with user number + /// nr inside mother, with its parameters upar(1..np) virtual void Gsposp(const char *name, Int_t nr, const char *mother, Double_t x, Double_t y, Double_t z, Int_t irot, const char *konly, Float_t *upar, Int_t np) = 0; - // The same as previous but in double precision + /// The same as previous but in double precision virtual void Gsposp(const char *name, Int_t nr, const char *mother, Double_t x, Double_t y, Double_t z, Int_t irot, const char *konly, Double_t *upar, Int_t np) = 0; - // Helper function for resolving MANY. - // Specify the ONLY volume that overlaps with the - // specified MANY and has to be substracted. - // (Geant4 only) + /// Helper function for resolving MANY. + /// Specify the ONLY volume that overlaps with the + /// specified MANY and has to be substracted. + /// (Geant4 only) virtual void Gsbool(const char* onlyVolName, const char* manyVolName) = 0; - // Define the tables for UV photon tracking in medium itmed. - // Please note that it is the user's responsibility to - // provide all the coefficients: - // itmed Tracking medium number - // npckov Number of bins of each table - // ppckov Value of photon momentum (in GeV) - // absco Absorption coefficients - // dielectric: absorption length in cm - // metals : absorption fraction (0<=x<=1) - // effic Detection efficiency for UV photons - // rindex Refraction index (if=0 metal) + /// Define the tables for UV photon tracking in medium itmed. + /// Please note that it is the user's responsibility to + /// provide all the coefficients: + /// - itmed Tracking medium number + /// - npckov Number of bins of each table + /// - ppckov Value of photon momentum (in GeV) + /// - absco Absorption coefficients + /// - dielectric: absorption length in cm + /// - metals : absorption fraction (0<=x<=1) + /// - effic Detection efficiency for UV photons + /// - rindex Refraction index (if=0 metal) virtual void SetCerenkov(Int_t itmed, Int_t npckov, Float_t *ppckov, Float_t *absco, Float_t *effic, Float_t *rindex) = 0; - // The same as previous but in double precision + /// The same as previous but in double precision virtual void SetCerenkov(Int_t itmed, Int_t npckov, Double_t *ppckov, Double_t *absco, Double_t *effic, Double_t *rindex) = 0; @@ -282,68 +283,68 @@ public: // ------------------------------------------------ // - // Define the optical surface - // name surface name - // model selection of model (see #EMCOpSurfaceModel values) - // surfaceType surface type (see #EMCOpSurfaceType values) - // surfaceFinish surface quality (see #EMCOpSurfaceType values) - // sigmaAlpha an unified model surface parameter - // (Geant4 only) + /// Define the optical surface + /// - name surface name + /// - model selection of model (see #EMCOpSurfaceModel values) + /// - surfaceType surface type (see #EMCOpSurfaceType values) + /// - surfaceFinish surface quality (see #EMCOpSurfaceType values) + /// - sigmaAlpha an unified model surface parameter + /// (Geant4 only) virtual void DefineOpSurface(const char* name, EMCOpSurfaceModel model, EMCOpSurfaceType surfaceType, EMCOpSurfaceFinish surfaceFinish, Double_t sigmaAlpha) = 0; - // Define the optical surface border - // name border surface name - // vol1Name first volume name - // vol1CopyNo first volume copy number - // vol2Name second volume name - // vol2CopyNo second volume copy number - // opSurfaceName name of optical surface which this border belongs to - // (Geant4 only) + /// Define the optical surface border + /// - name border surface name + /// - vol1Name first volume name + /// - vol1CopyNo first volume copy number + /// - vol2Name second volume name + /// - vol2CopyNo second volume copy number + /// - opSurfaceName name of optical surface which this border belongs to + /// (Geant4 only) virtual void SetBorderSurface(const char* name, const char* vol1Name, int vol1CopyNo, const char* vol2Name, int vol2CopyNo, const char* opSurfaceName) = 0; - // Define the optical skin surface - // name skin surface name - // volName volume name - // opSurfaceName name of optical surface which this border belongs to - // (Geant4 only) + /// Define the optical skin surface + /// - name skin surface name + /// - volName volume name + /// - opSurfaceName name of optical surface which this border belongs to + /// (Geant4 only) virtual void SetSkinSurface(const char* name, const char* volName, const char* opSurfaceName) = 0; - // Define material property via a table of values - // itmed tracking medium id - // propertyName property name - // np number of bins of the table - // pp value of photon momentum (in GeV) - // values property values - // (Geant4 only) + /// Define material property via a table of values + /// - itmed tracking medium id + /// - propertyName property name + /// - np number of bins of the table + /// - pp value of photon momentum (in GeV) + /// - values property values + /// (Geant4 only) virtual void SetMaterialProperty( Int_t itmed, const char* propertyName, Int_t np, Double_t* pp, Double_t* values) = 0; - // Define material property via a value - // itmed tracking medium id - // propertyName property name - // value property value - // (Geant4 only) + /// Define material property via a value + /// - itmed tracking medium id + /// - propertyName property name + /// - value property value + /// (Geant4 only) virtual void SetMaterialProperty( Int_t itmed, const char* propertyName, Double_t value) = 0; - // Define optical surface property via a table of values - // surfaceName optical surface name - // propertyName property name - // np number of bins of the table - // pp value of photon momentum (in GeV) - // values property values - // (Geant4 only) + /// Define optical surface property via a table of values + /// - surfaceName optical surface name + /// - propertyName property name + /// - np number of bins of the table + /// - pp value of photon momentum (in GeV) + /// - values property values + /// (Geant4 only) virtual void SetMaterialProperty( const char* surfaceName, const char* propertyName, Int_t np, Double_t* pp, Double_t* values) = 0; @@ -353,31 +354,31 @@ public: // ------------------------------------------------ // - // Return the transformation matrix between the volume specified by - // the path volumePath and the top or master volume. + /// Return the transformation matrix between the volume specified by + /// the path volumePath and the top or master volume. virtual Bool_t GetTransformation(const TString& volumePath, TGeoHMatrix& matrix) = 0; - // Return the name of the shape (shapeType) and its parameters par - // for the volume specified by the path volumePath . + /// Return the name of the shape (shapeType) and its parameters par + /// for the volume specified by the path volumePath . virtual Bool_t GetShape(const TString& volumePath, TString& shapeType, TArrayD& par) = 0; - // Return the material parameters for the material specified by - // the material Id + /// Return the material parameters for the material specified by + /// the material Id virtual Bool_t GetMaterial(Int_t imat, TString& name, Double_t& a, Double_t& z, Double_t& density, Double_t& radl, Double_t& inter, TArrayD& par) = 0; - // Return the material parameters for the volume specified by - // the volumeName. + /// Return the material parameters for the volume specified by + /// the volumeName. virtual Bool_t GetMaterial(const TString& volumeName, TString& name, Int_t& imat, Double_t& a, Double_t& z, Double_t& density, Double_t& radl, Double_t& inter, TArrayD& par) = 0; - // Return the medium parameters for the volume specified by the - // volumeName. + /// Return the medium parameters for the volume specified by the + /// volumeName. virtual Bool_t GetMedium(const TString& volumeName, TString& name, Int_t& imed, Int_t& nmat, Int_t& isvol, Int_t& ifield, @@ -385,24 +386,24 @@ public: Double_t& deemax, Double_t& epsil, Double_t& stmin, TArrayD& par) = 0; - // Write out the geometry of the detector in EUCLID file format - // filnam file name - will be with the extension .euc * - // topvol volume name of the starting node - // number copy number of topvol (relevant for gsposp) - // nlevel number of levels in the tree structure - // to be written out, starting from topvol - // (Geant3 only) - // Deprecated + /// Write out the geometry of the detector in EUCLID file format + /// - filnam file name - will be with the extension .euc * + /// - topvol volume name of the starting node + /// - number copy number of topvol (relevant for gsposp) + /// - nlevel number of levels in the tree structure + /// to be written out, starting from topvol + /// (Geant3 only) + /// Deprecated virtual void WriteEuclid(const char* filnam, const char* topvol, Int_t number, Int_t nlevel) = 0; - // Set geometry from Root (built via TGeo) + /// Set geometry from Root (built via TGeo) virtual void SetRootGeometry() = 0; - // Activate the parameters defined in tracking media - // (DEEMAX, STMIN, STEMAX), which are, be default, ignored. - // In Geant4 case, only STEMAX is taken into account. - // In FLUKA, all tracking media parameters are ignored. + /// Activate the parameters defined in tracking media + /// (DEEMAX, STMIN, STEMAX), which are, be default, ignored. + /// In Geant4 case, only STEMAX is taken into account. + /// In FLUKA, all tracking media parameters are ignored. virtual void SetUserParameters(Bool_t isUserParameters) = 0; // @@ -410,28 +411,28 @@ public: // ------------------------------------------------ // - // Return the unique numeric identifier for volume name volName + /// Return the unique numeric identifier for volume name volName virtual Int_t VolId(const char* volName) const = 0; - // Return the volume name for a given volume identifier id + /// Return the volume name for a given volume identifier id virtual const char* VolName(Int_t id) const = 0; - // Return the unique numeric identifier for medium name mediumName + /// Return the unique numeric identifier for medium name mediumName virtual Int_t MediumId(const char* mediumName) const = 0; - // Return total number of volumes in the geometry + /// Return total number of volumes in the geometry virtual Int_t NofVolumes() const = 0; - // Return material number for a given volume id + /// Return material number for a given volume id virtual Int_t VolId2Mate(Int_t id) const = 0; - // Return number of daughters of the volume specified by volName + /// Return number of daughters of the volume specified by volName virtual Int_t NofVolDaughters(const char* volName) const = 0; - // Return the name of i-th daughter of the volume specified by volName + /// Return the name of i-th daughter of the volume specified by volName virtual const char* VolDaughterName(const char* volName, Int_t i) const = 0; - // Return the copyNo of i-th daughter of the volume specified by volName + /// Return the copyNo of i-th daughter of the volume specified by volName virtual Int_t VolDaughterCopyNo(const char* volName, Int_t i) const = 0; // @@ -445,66 +446,66 @@ public: // ------------------------------------------------ // - // Set transport cuts for particles + /// Set transport cuts for particles virtual Bool_t SetCut(const char* cutName, Double_t cutValue) = 0; - // Set process control + /// Set process control virtual Bool_t SetProcess(const char* flagName, Int_t flagValue) = 0; - // Set a user defined particle - // Function is ignored if particle with specified pdg - // already exists and error report is printed. - // pdg PDG encoding - // name particle name - // mcType VMC Particle type - // mass mass [GeV] - // charge charge [eplus] - // lifetime time of life [s] - // pType particle type as in Geant4 - // width width [GeV] - // iSpin spin - // iParity parity - // iConjugation conjugation - // iIsospin isospin - // iIsospinZ isospin - #rd component - // gParity gParity - // lepton lepton number - // baryon baryon number - // stable stability - // shortlived is shorlived? - // subType particle subType as in Geant4 - // antiEncoding anti encoding - // magMoment magnetic moment - // excitation excitation energy [GeV] + /// Set a user defined particle + /// Function is ignored if particle with specified pdg + /// already exists and error report is printed. + /// - pdg PDG encoding + /// - name particle name + /// - mcType VMC Particle type + /// - mass mass [GeV] + /// - charge charge [eplus] + /// - lifetime time of life [s] + /// - pType particle type as in Geant4 + /// - width width [GeV] + /// - iSpin spin + /// - iParity parity + /// - iConjugation conjugation + /// - iIsospin isospin + /// - iIsospinZ isospin - #rd component + /// - gParity gParity + /// - lepton lepton number + /// - baryon baryon number + /// - stable stability + /// - shortlived is shorlived? + /// - subType particle subType as in Geant4 + /// - antiEncoding anti encoding + /// - magMoment magnetic moment + /// - excitation excitation energy [GeV] virtual Bool_t DefineParticle(Int_t pdg, const char* name, TMCParticleType mcType, Double_t mass, Double_t charge, Double_t lifetime) = 0; - // Set a user defined particle - // Function is ignored if particle with specified pdg - // already exists and error report is printed. - // pdg PDG encoding - // name particle name - // mcType VMC Particle type - // mass mass [GeV] - // charge charge [eplus] - // lifetime time of life [s] - // pType particle type as in Geant4 - // width width [GeV] - // iSpin spin - // iParity parity - // iConjugation conjugation - // iIsospin isospin - // iIsospinZ isospin - #rd component - // gParity gParity - // lepton lepton number - // baryon baryon number - // stable stability - // shortlived is shorlived? - // subType particle subType as in Geant4 - // antiEncoding anti encoding - // magMoment magnetic moment - // excitation excitation energy [GeV] + /// Set a user defined particle + /// Function is ignored if particle with specified pdg + /// already exists and error report is printed. + /// - pdg PDG encoding + /// - name particle name + /// - mcType VMC Particle type + /// - mass mass [GeV] + /// - charge charge [eplus] + /// - lifetime time of life [s] + /// - pType particle type as in Geant4 + /// - width width [GeV] + /// - iSpin spin + /// - iParity parity + /// - iConjugation conjugation + /// - iIsospin isospin + /// - iIsospinZ isospin - #rd component + /// - gParity gParity + /// - lepton lepton number + /// - baryon baryon number + /// - stable stability + /// - shortlived is shorlived? + /// - subType particle subType as in Geant4 + /// - antiEncoding anti encoding + /// - magMoment magnetic moment + /// - excitation excitation energy [GeV] virtual Bool_t DefineParticle(Int_t pdg, const char* name, TMCParticleType mcType, Double_t mass, Double_t charge, Double_t lifetime, @@ -517,27 +518,27 @@ public: Int_t antiEncoding = 0, Double_t magMoment = 0.0, Double_t excitation = 0.0) = 0; - // Set a user defined ion. - // name ion name - // Z atomic number - // A atomic mass - // Q charge [eplus} - // excitation excitation energy [GeV] - // mass mass [GeV] (if not specified by user, approximative - // mass is calculated) + /// Set a user defined ion. + /// - name ion name + /// - Z atomic number + /// - A atomic mass + /// - Q charge [eplus} + /// - excitation excitation energy [GeV] + /// - mass mass [GeV] (if not specified by user, approximative + /// mass is calculated) virtual Bool_t DefineIon(const char* name, Int_t Z, Int_t A, Int_t Q, Double_t excEnergy, Double_t mass = 0.) = 0; - // Set a user phase space decay for a particle - // pdg particle PDG encoding - // bratios the array with branching ratios (in %) - // mode[6][3] the array with daughters particles PDG codes for each - // decay channel + /// Set a user phase space decay for a particle + /// - pdg particle PDG encoding + /// - bratios the array with branching ratios (in %) + /// - mode[6][3] the array with daughters particles PDG codes for each + /// decay channel virtual Bool_t SetDecayMode(Int_t pdg, Float_t bratio[6], Int_t mode[6][3]) = 0; - // Calculate X-sections - // (Geant3 only) - // Deprecated + /// Calculate X-sections + /// (Geant3 only) + /// Deprecated virtual Double_t Xsec(char*, Double_t, Int_t, Int_t) = 0; // @@ -545,10 +546,10 @@ public: // ------------------------------------------------ // - // Return MC specific code from a PDG and pseudo ENDF code (pdg) + /// Return MC specific code from a PDG and pseudo ENDF code (pdg) virtual Int_t IdFromPDG(Int_t pdg) const =0; - // Return PDG code and pseudo ENDF code from MC specific code (id) + /// Return PDG code and pseudo ENDF code from MC specific code (id) virtual Int_t PDGFromId(Int_t id) const =0; // @@ -556,19 +557,19 @@ public: // ------------------------------------------------ // - // Return name of the particle specified by pdg. + /// Return name of the particle specified by pdg. virtual TString ParticleName(Int_t pdg) const = 0; - // Return mass of the particle specified by pdg. + /// Return mass of the particle specified by pdg. virtual Double_t ParticleMass(Int_t pdg) const = 0; - // Return charge (in e units) of the particle specified by pdg. + /// Return charge (in e units) of the particle specified by pdg. virtual Double_t ParticleCharge(Int_t pdg) const = 0; - // Return life time of the particle specified by pdg. + /// Return life time of the particle specified by pdg. virtual Double_t ParticleLifeTime(Int_t pdg) const = 0; - // Return VMC type of the particle specified by pdg. + /// Return VMC type of the particle specified by pdg. virtual TMCParticleType ParticleMCType(Int_t pdg) const = 0; // // ------------------------------------------------ @@ -581,13 +582,13 @@ public: // ------------------------------------------------ // - // Stop the transport of the current particle and skip to the next + /// Stop the transport of the current particle and skip to the next virtual void StopTrack() = 0; - // Stop simulation of the current event and skip to the next + /// Stop simulation of the current event and skip to the next virtual void StopEvent() = 0; - // Stop simulation of the current event and set the abort run flag to true + /// Stop simulation of the current event and set the abort run flag to true virtual void StopRun() = 0; // @@ -595,17 +596,17 @@ public: // ------------------------------------------------ // - // Set the maximum step allowed till the particle is in the current medium + /// Set the maximum step allowed till the particle is in the current medium virtual void SetMaxStep(Double_t) = 0; - // Set the maximum number of steps till the particle is in the current medium + /// Set the maximum number of steps till the particle is in the current medium virtual void SetMaxNStep(Int_t) = 0; - // Force the decays of particles to be done with Pythia - // and not with the Geant routines. + /// Force the decays of particles to be done with Pythia + /// and not with the Geant routines. virtual void SetUserDecay(Int_t pdg) = 0; - // Force the decay time of the current particle + /// Force the decay time of the current particle virtual void ForceDecayTime(Float_t) = 0; // @@ -613,68 +614,68 @@ public: // ------------------------------------------------ // - // Return the current volume ID and copy number + /// Return the current volume ID and copy number virtual Int_t CurrentVolID(Int_t& copyNo) const =0; - // Return the current volume off upward in the geometrical tree - // ID and copy number + /// Return the current volume off upward in the geometrical tree + /// ID and copy number virtual Int_t CurrentVolOffID(Int_t off, Int_t& copyNo) const =0; - // Return the current volume name + /// Return the current volume name virtual const char* CurrentVolName() const =0; - // Return the current volume off upward in the geometrical tree - // name and copy number' - // if name=0 no name is returned + /// Return the current volume off upward in the geometrical tree + /// name and copy number' + /// if name=0 no name is returned virtual const char* CurrentVolOffName(Int_t off) const =0; - // Return the path in geometry tree for the current volume + /// Return the path in geometry tree for the current volume virtual const char* CurrentVolPath() = 0; - // If track is on a geometry boundary, fill the normal vector of the crossing - // volume surface and return true, return false otherwise + /// If track is on a geometry boundary, fill the normal vector of the crossing + /// volume surface and return true, return false otherwise virtual Bool_t CurrentBoundaryNormal( Double_t &x, Double_t &y, Double_t &z) const = 0; - // Return the parameters of the current material during transport + /// Return the parameters of the current material during transport virtual Int_t CurrentMaterial(Float_t &a, Float_t &z, Float_t &dens, Float_t &radl, Float_t &absl) const =0; - // Return the number of the current medium + //// Return the number of the current medium virtual Int_t CurrentMedium() const = 0; // new function (to replace GetMedium() const) - // Return the number of the current event + /// Return the number of the current event virtual Int_t CurrentEvent() const =0; - // Computes coordinates xd in daughter reference system - // from known coordinates xm in mother reference system. - // xm coordinates in mother reference system (input) - // xd coordinates in daughter reference system (output) - // iflag - // - IFLAG = 1 convert coordinates - // - IFLAG = 2 convert direction cosines + /// Computes coordinates xd in daughter reference system + /// from known coordinates xm in mother reference system. + /// - xm coordinates in mother reference system (input) + /// - xd coordinates in daughter reference system (output) + /// - iflag + /// - IFLAG = 1 convert coordinates + /// - IFLAG = 2 convert direction cosines virtual void Gmtod(Float_t* xm, Float_t* xd, Int_t iflag) = 0; - // The same as previous but in double precision + /// The same as previous but in double precision virtual void Gmtod(Double_t* xm, Double_t* xd, Int_t iflag) = 0; - // Computes coordinates xm in mother reference system - // from known coordinates xd in daughter reference system. - // xd coordinates in daughter reference system (input) - // xm coordinates in mother reference system (output) - // iflag - // - IFLAG = 1 convert coordinates - // - IFLAG = 2 convert direction cosines + /// Computes coordinates xm in mother reference system + /// from known coordinates xd in daughter reference system. + /// - xd coordinates in daughter reference system (input) + /// - xm coordinates in mother reference system (output) + /// - iflag + /// - IFLAG = 1 convert coordinates + /// - IFLAG = 2 convert direction cosines virtual void Gdtom(Float_t* xd, Float_t* xm, Int_t iflag)= 0 ; - // The same as previous but in double precision + /// The same as previous but in double precision virtual void Gdtom(Double_t* xd, Double_t* xm, Int_t iflag)= 0 ; - // Return the maximum step length in the current medium + /// Return the maximum step length in the current medium virtual Double_t MaxStep() const =0; - // Return the maximum number of steps allowed in the current medium + /// Return the maximum number of steps allowed in the current medium virtual Int_t GetMaxNStep() const = 0; // @@ -684,32 +685,32 @@ public: // ------------------------------------------------ // - // Return the current position in the master reference frame of the - // track being transported + /// Return the current position in the master reference frame of the + /// track being transported virtual void TrackPosition(TLorentzVector& position) const =0; - // Return the current position in the master reference frame of the - // track being transported + /// Return the current position in the master reference frame of the + /// track being transported virtual void TrackPosition(Double_t &x, Double_t &y, Double_t &z) const =0; - // Return the direction and the momentum (GeV/c) of the track - // currently being transported + /// Return the direction and the momentum (GeV/c) of the track + /// currently being transported virtual void TrackMomentum(TLorentzVector& momentum) const =0; - // Return the direction and the momentum (GeV/c) of the track - // currently being transported + /// Return the direction and the momentum (GeV/c) of the track + /// currently being transported virtual void TrackMomentum(Double_t &px, Double_t &py, Double_t &pz, Double_t &etot) const =0; - // Return the length in centimeters of the current step (in cm) + /// Return the length in centimeters of the current step (in cm) virtual Double_t TrackStep() const =0; - // Return the length of the current track from its origin (in cm) + /// Return the length of the current track from its origin (in cm) virtual Double_t TrackLength() const =0; - // Return the current time of flight of the track being transported + /// Return the current time of flight of the track being transported virtual Double_t TrackTime() const =0; - // Return the energy lost in the current step + /// Return the energy lost in the current step virtual Double_t Edep() const =0; // @@ -719,16 +720,16 @@ public: // ------------------------------------------------ // - // Return the PDG of the particle transported + /// Return the PDG of the particle transported virtual Int_t TrackPid() const =0; - // Return the charge of the track currently transported + /// Return the charge of the track currently transported virtual Double_t TrackCharge() const =0; - // Return the mass of the track currently transported + /// Return the mass of the track currently transported virtual Double_t TrackMass() const =0; - // Return the total energy of the current track + /// Return the total energy of the current track virtual Double_t Etot() const =0; // @@ -736,31 +737,31 @@ public: // ------------------------------------------------ // - // Return true when the track performs the first step + /// Return true when the track performs the first step virtual Bool_t IsNewTrack() const =0; - // Return true if the track is not at the boundary of the current volume + /// Return true if the track is not at the boundary of the current volume virtual Bool_t IsTrackInside() const =0; - // Return true if this is the first step of the track in the current volume + /// Return true if this is the first step of the track in the current volume virtual Bool_t IsTrackEntering() const =0; - // Return true if this is the last step of the track in the current volume + /// Return true if this is the last step of the track in the current volume virtual Bool_t IsTrackExiting() const =0; - // Return true if the track is out of the setup + /// Return true if the track is out of the setup virtual Bool_t IsTrackOut() const =0; - // Return true if the current particle has disappeared - // either because it decayed or because it underwent - // an inelastic collision + /// Return true if the current particle has disappeared + /// either because it decayed or because it underwent + /// an inelastic collision virtual Bool_t IsTrackDisappeared() const =0; - // Return true if the track energy has fallen below the threshold + /// Return true if the track energy has fallen below the threshold virtual Bool_t IsTrackStop() const =0; - // Return true if the current particle is alive and will continue to be - // transported + /// Return true if the current particle is alive and will continue to be + /// transported virtual Bool_t IsTrackAlive() const=0; // @@ -768,23 +769,23 @@ public: // ------------------------------------------------ // - // Return the number of secondary particles generated in the current step + /// Return the number of secondary particles generated in the current step virtual Int_t NSecondaries() const=0; - // Return the parameters of the secondary track number isec produced - // in the current step + /// Return the parameters of the secondary track number isec produced + /// in the current step virtual void GetSecondary(Int_t isec, Int_t& particleId, TLorentzVector& position, TLorentzVector& momentum) =0; - // Return the VMC code of the process that has produced the secondary - // particles in the current step + /// Return the VMC code of the process that has produced the secondary + /// particles in the current step virtual TMCProcess ProdProcess(Int_t isec) const =0; - // Return the array of the VMC code of the processes active in the current - // step + /// Return the array of the VMC code of the processes active in the current + /// step virtual Int_t StepProcesses(TArrayI &proc) const = 0; - // Return the information about the transport order needed by the stack + /// Return the information about the transport order needed by the stack virtual Bool_t SecondariesAreOrdered() const = 0; @@ -794,30 +795,30 @@ public: // ------------------------------------------------ // - // Initialize MC + /// Initialize MC virtual void Init() = 0; - // Initialize MC physics + /// Initialize MC physics virtual void BuildPhysics() = 0; - // Process one event - // Deprecated + /// Process one event + /// Deprecated virtual void ProcessEvent() = 0; - // Process one run and return true if run has finished successfully, - // return false in other cases (run aborted by user) + /// Process one run and return true if run has finished successfully, + /// return false in other cases (run aborted by user) virtual Bool_t ProcessRun(Int_t nevent) = 0; - // Set switches for lego transport + /// Set switches for lego transport virtual void InitLego() = 0; - // (In)Activate collecting TGeo tracks + /// (In)Activate collecting TGeo tracks virtual void SetCollectTracks(Bool_t collectTracks) = 0; - // Return the info if collecting tracks is activated + /// Return the info if collecting tracks is activated virtual Bool_t IsCollectTracks() const = 0; - // Return the info if multi-threading is supported/activated + /// Return the info if multi-threading is supported/activated virtual Bool_t IsMT() const { return kFALSE; } // @@ -826,16 +827,16 @@ public: // ------------------------------------------------ // - // Set the particle stack + /// Set the particle stack virtual void SetStack(TVirtualMCStack* stack); - // Set the external decayer + /// Set the external decayer virtual void SetExternalDecayer(TVirtualMCDecayer* decayer); - // Set the random number generator + /// Set the random number generator virtual void SetRandom(TRandom* random); - // Set the magnetic field + /// Set the magnetic field virtual void SetMagField(TVirtualMagField* field); // @@ -844,35 +845,35 @@ public: // ------------------------------------------------ // - // Return the particle stack + /// Return the particle stack virtual TVirtualMCStack* GetStack() const { return fStack; } - // Return the external decayer + /// Return the external decayer virtual TVirtualMCDecayer* GetDecayer() const { return fDecayer; } - // Return the random number generator + /// Return the random number generator virtual TRandom* GetRandom() const { return fRandom; } - // Return the magnetic field + /// Return the magnetic field virtual TVirtualMagField* GetMagField() const { return fMagField; } protected: - TVirtualMCApplication* fApplication; //! User MC application + TVirtualMCApplication* fApplication; //!< User MC application private: TVirtualMC(const TVirtualMC &mc); TVirtualMC & operator=(const TVirtualMC &); #if !defined(__CINT__) - static TMCThreadLocal TVirtualMC* fgMC; // Monte Carlo singleton instance + static TMCThreadLocal TVirtualMC* fgMC; ///< Monte Carlo singleton instance #else - static TVirtualMC* fgMC; // Monte Carlo singleton instance + static TVirtualMC* fgMC; ///< Monte Carlo singleton instance #endif - TVirtualMCStack* fStack; //! Particles stack - TVirtualMCDecayer* fDecayer; //! External decayer - TRandom* fRandom; //! Random number generator - TVirtualMagField* fMagField;//! Magnetic field + TVirtualMCStack* fStack; //!< Particles stack + TVirtualMCDecayer* fDecayer; //!< External decayer + TRandom* fRandom; //!< Random number generator + TVirtualMagField* fMagField;//!< Magnetic field ClassDef(TVirtualMC,1) //Interface to Monte Carlo }; diff --git a/montecarlo/vmc/inc/TVirtualMCApplication.h b/montecarlo/vmc/inc/TVirtualMCApplication.h index ed17365cd667d36c0412e2006a256beeab117f56..2f292e41dc11e7ea9eb50d6b85b2feb183a550ea 100644 --- a/montecarlo/vmc/inc/TVirtualMCApplication.h +++ b/montecarlo/vmc/inc/TVirtualMCApplication.h @@ -30,90 +30,95 @@ class TVirtualMCApplication : public TNamed { public: - // Standard constructor + /// Standard constructor TVirtualMCApplication(const char *name, const char *title); - // Default constructor + /// Default constructor TVirtualMCApplication(); - // Destructor + /// Destructor virtual ~TVirtualMCApplication(); - // Static access method + /// Static access method static TVirtualMCApplication* Instance(); // // methods // - // Construct user geometry + /// Construct user geometry virtual void ConstructGeometry() = 0; - // Misalign user geometry (optional) + /// Misalign user geometry (optional) virtual Bool_t MisalignGeometry() {return kFALSE;} - // Define parameters for optical processes (optional) + /// Define parameters for optical processes (optional) virtual void ConstructOpGeometry() {} - // Initialize geometry - // (Usually used to define sensitive volumes IDs) + /// Initialize geometry + /// (Usually used to define sensitive volumes IDs) virtual void InitGeometry() = 0; - // Add user defined particles (optional) + /// Add user defined particles (optional) virtual void AddParticles() {} - // Add user defined ions (optional) + /// Add user defined ions (optional) virtual void AddIons() {} - // Generate primary particles + /// Generate primary particles virtual void GeneratePrimaries() = 0; - // Define actions at the beginning of the event + /// Define actions at the beginning of the event virtual void BeginEvent() = 0; - // Define actions at the beginning of the primary track + /// Define actions at the beginning of the primary track virtual void BeginPrimary() = 0; - // Define actions at the beginning of each track + /// Define actions at the beginning of each track virtual void PreTrack() = 0; - // Define action at each step + /// Define action at each step virtual void Stepping() = 0; - // Define actions at the end of each track + /// Define actions at the end of each track virtual void PostTrack() = 0; - // Define actions at the end of the primary track + /// Define actions at the end of the primary track virtual void FinishPrimary() = 0; - // Define actions at the end of the event + /// Define actions at the end of the event virtual void FinishEvent() = 0; - // Define maximum radius for tracking (optional) + /// Define maximum radius for tracking (optional) virtual Double_t TrackingRmax() const { return DBL_MAX; } - // Define maximum z for tracking (optional) + /// Define maximum z for tracking (optional) virtual Double_t TrackingZmax() const { return DBL_MAX; } - // Calculate user field \a b at point \a x + /// Calculate user field \a b at point \a x virtual void Field(const Double_t* x, Double_t* b) const; - // Define action at each step for Geane + /// Define action at each step for Geane virtual void GeaneStepping() {;} // New functions for multi-threading applications + /// Clone MC application on worker virtual TVirtualMCApplication* CloneForWorker() const { return 0;} + /// Initialize MC application on worker virtual void InitForWorker() const {} + /// Define actions at the beginning of the worker run if needed virtual void BeginWorkerRun() const {} + /// Define actions at the end of the worker run if needed virtual void FinishWorkerRun() const {} + /// Merge the data accumulated on workers to the master if needed virtual void Merge(TVirtualMCApplication* /*localMCApplication*/) {} private: // static data members #if !defined(__CINT__) - static TMCThreadLocal TVirtualMCApplication* fgInstance; // singleton instance + static TMCThreadLocal TVirtualMCApplication* fgInstance; ///< Singleton instance #else - static TVirtualMCApplication* fgInstance; // singleton instance + static TVirtualMCApplication* fgInstance; ///< Singleton instance #endif ClassDef(TVirtualMCApplication,1) //Interface to MonteCarlo application diff --git a/montecarlo/vmc/inc/TVirtualMCGeometry.h b/montecarlo/vmc/inc/TVirtualMCGeometry.h index 00905aae7a8d3854a4ad6ff401fd5575a0c870f7..e6dbbf5aa54bf24ac15c7b6e7a0a81c24f01960a 100644 --- a/montecarlo/vmc/inc/TVirtualMCGeometry.h +++ b/montecarlo/vmc/inc/TVirtualMCGeometry.h @@ -42,85 +42,85 @@ public: // ------------------------------------------------ // - // Define a material - // kmat number assigned to the material - // name material name - // a atomic mass in au - // z atomic number - // dens density in g/cm3 - // absl absorption length in cm; - // if >=0 it is ignored and the program - // calculates it, if <0. -absl is taken - // radl radiation length in cm - // if >=0 it is ignored and the program - // calculates it, if <0. -radl is taken - // buf pointer to an array of user words - // nwbuf number of user words + /// Define a material + /// - kmat number assigned to the material + /// - name material name + /// - a atomic mass in au + /// - z atomic number + /// - dens density in g/cm3 + /// - absl absorption length in cm; + /// if >=0 it is ignored and the program + /// calculates it, if <0. -absl is taken + /// - radl radiation length in cm + /// if >=0 it is ignored and the program + /// calculates it, if <0. -radl is taken + /// - buf pointer to an array of user words + /// - nwbuf number of user words virtual void Material(Int_t& kmat, const char* name, Double_t a, Double_t z, Double_t dens, Double_t radl, Double_t absl, Float_t* buf, Int_t nwbuf) = 0; - // The same as previous but in double precision + /// The same as previous but in double precision virtual void Material(Int_t& kmat, const char* name, Double_t a, Double_t z, Double_t dens, Double_t radl, Double_t absl, Double_t* buf, Int_t nwbuf) = 0; - // Define mixture or compound - // with a number kmat composed by the basic nlmat materials defined - // by arrays a, z and wmat + /// Define mixture or compound + /// with a number kmat composed by the basic nlmat materials defined + /// by arrays a, z and wmat // - // If nlmat > 0 then wmat contains the proportion by - // weights of each basic material in the mixture. + /// If nlmat > 0 then wmat contains the proportion by + /// weights of each basic material in the mixture. // - // If nlmat < 0 then wmat contains the number of atoms - // of a given kind into the molecule of the compound. - // In this case, wmat in output is changed to relative - // weights. + /// If nlmat < 0 then wmat contains the number of atoms + /// of a given kind into the molecule of the compound. + /// In this case, wmat in output is changed to relative + /// weights. virtual void Mixture(Int_t& kmat, const char *name, Float_t *a, Float_t *z, Double_t dens, Int_t nlmat, Float_t *wmat) = 0; - // The same as previous but in double precision + /// The same as previous but in double precision virtual void Mixture(Int_t& kmat, const char *name, Double_t *a, Double_t *z, Double_t dens, Int_t nlmat, Double_t *wmat) = 0; - // Define a medium. - // kmed tracking medium number assigned - // name tracking medium name - // nmat material number - // isvol sensitive volume flag - // ifield magnetic field: - // - ifield = 0 if no magnetic field; - // - ifield = -1 if user decision in guswim; - // - ifield = 1 if tracking performed with g3rkuta; - // - ifield = 2 if tracking - // fieldm max. field value (kilogauss) - // tmaxfd max. angle due to field (deg/step) - // stemax max. step allowed - // deemax max. fraction of energy lost in a step - // epsil tracking precision (cm) - // stmin min. step due to continuous processes (cm) - // ubuf pointer to an array of user words - // nbuf number of user words - // performed with g3helix; ifield = 3 if tracking performed with g3helx3. + /// Define a medium. + /// - kmed tracking medium number assigned + /// - name tracking medium name + /// - nmat material number + /// - isvol sensitive volume flag + /// - ifield magnetic field: + /// - ifield = 0 if no magnetic field; + /// - ifield = -1 if user decision in guswim; + /// - ifield = 1 if tracking performed with g3rkuta; + /// - ifield = 2 if tracking performed with g3helix; + /// - ifield = 3 if tracking performed with g3helx3. + /// - fieldm max. field value (kilogauss) + /// - tmaxfd max. angle due to field (deg/step) + /// - stemax max. step allowed + /// - deemax max. fraction of energy lost in a step + /// - epsil tracking precision (cm) + /// - stmin min. step due to continuous processes (cm) + /// - ubuf pointer to an array of user words + /// - nbuf number of user words virtual void Medium(Int_t& kmed, const char *name, Int_t nmat, Int_t isvol, Int_t ifield, Double_t fieldm, Double_t tmaxfd, Double_t stemax, Double_t deemax, Double_t epsil, Double_t stmin, Float_t* ubuf, Int_t nbuf) = 0; - // The same as previous but in double precision + /// The same as previous but in double precision virtual void Medium(Int_t& kmed, const char *name, Int_t nmat, Int_t isvol, Int_t ifield, Double_t fieldm, Double_t tmaxfd, Double_t stemax, Double_t deemax, Double_t epsil, Double_t stmin, Double_t* ubuf, Int_t nbuf) = 0; - // Define a rotation matrix - // krot rotation matrix number assigned - // thetaX polar angle for axis X - // phiX azimuthal angle for axis X - // thetaY polar angle for axis Y - // phiY azimuthal angle for axis Y - // thetaZ polar angle for axis Z - // phiZ azimuthal angle for axis Z + /// Define a rotation matrix + /// - krot rotation matrix number assigned + /// - thetaX polar angle for axis X + /// - phiX azimuthal angle for axis X + /// - thetaY polar angle for axis Y + /// - phiY azimuthal angle for axis Y + /// - thetaZ polar angle for axis Z + /// - phiZ azimuthal angle for axis Z virtual void Matrix(Int_t& krot, Double_t thetaX, Double_t phiX, Double_t thetaY, Double_t phiY, Double_t thetaZ, Double_t phiZ) = 0; @@ -130,92 +130,92 @@ public: // ------------------------------------------------ // - // Create a new volume - // name Volume name - // shape Volume type - // nmed Tracking medium number - // np Number of shape parameters - // upar Vector containing shape parameters + /// Create a new volume + /// - name Volume name + /// - shape Volume type + /// - nmed Tracking medium number + /// - np Number of shape parameters + /// - upar Vector containing shape parameters virtual Int_t Gsvolu(const char *name, const char *shape, Int_t nmed, Float_t *upar, Int_t np) = 0; - // The same as previous but in double precision + /// The same as previous but in double precision virtual Int_t Gsvolu(const char *name, const char *shape, Int_t nmed, Double_t *upar, Int_t np) = 0; - // Create a new volume by dividing an existing one. - // It divides a previously defined volume - // name Volume name - // mother Mother volume name - // ndiv Number of divisions - // iaxis Axis value: - // X,Y,Z of CAXIS will be translated to 1,2,3 for IAXIS. + /// Create a new volume by dividing an existing one. + /// It divides a previously defined volume + /// - name Volume name + /// - mother Mother volume name + /// - ndiv Number of divisions + /// - iaxis Axis value: + /// X,Y,Z of CAXIS will be translated to 1,2,3 for IAXIS. virtual void Gsdvn(const char *name, const char *mother, Int_t ndiv, Int_t iaxis) = 0; - // Create a new volume by dividing an existing one. - // Divide mother into ndiv divisions called name - // along axis iaxis starting at coordinate value c0i. - // The new volume created will be medium number numed. + /// Create a new volume by dividing an existing one. + /// Divide mother into ndiv divisions called name + /// along axis iaxis starting at coordinate value c0i. + /// The new volume created will be medium number numed. virtual void Gsdvn2(const char *name, const char *mother, Int_t ndiv, Int_t iaxis, Double_t c0i, Int_t numed) = 0; - // Create a new volume by dividing an existing one - // Divide mother into divisions called name along - // axis iaxis in steps of step. If not exactly divisible - // will make as many as possible and will center them - // with respect to the mother. Divisions will have medium - // number numed. If numed is 0, numed of mother is taken. - // ndvmx is the expected maximum number of divisions - // (If 0, no protection tests are performed in Geant3) + /// Create a new volume by dividing an existing one + /// Divide mother into divisions called name along + /// axis iaxis in steps of step. If not exactly divisible + /// will make as many as possible and will center them + /// with respect to the mother. Divisions will have medium + /// number numed. If numed is 0, numed of mother is taken. + /// ndvmx is the expected maximum number of divisions + /// (If 0, no protection tests are performed in Geant3) virtual void Gsdvt(const char *name, const char *mother, Double_t step, Int_t iaxis, Int_t numed, Int_t ndvmx) = 0; - // Create a new volume by dividing an existing one - // Divides mother into divisions called name along - // axis iaxis starting at coordinate value c0 with step - // size step. - // The new volume created will have medium number numed. - // If numed is 0, numed of mother is taken. - // ndvmx is the expected maximum number of divisions - // (If 0, no protection tests are performed in Geant3) + /// Create a new volume by dividing an existing one + /// Divides mother into divisions called name along + /// axis iaxis starting at coordinate value c0 with step + /// size step. + /// The new volume created will have medium number numed. + /// If numed is 0, numed of mother is taken. + /// ndvmx is the expected maximum number of divisions + /// (If 0, no protection tests are performed in Geant3) virtual void Gsdvt2(const char *name, const char *mother, Double_t step, Int_t iaxis, Double_t c0, Int_t numed, Int_t ndvmx) = 0; - // Flag volume name whose contents will have to be ordered - // along axis iax, by setting the search flag to -iax - // (Geant3 only) + /// Flag volume name whose contents will have to be ordered + /// along axis iax, by setting the search flag to -iax + /// (Geant3 only) virtual void Gsord(const char *name, Int_t iax) = 0; - // Position a volume into an existing one. - // It positions a previously defined volume in the mother. - // name Volume name - // nr Copy number of the volume - // mother Mother volume name - // x X coord. of the volume in mother ref. sys. - // y Y coord. of the volume in mother ref. sys. - // z Z coord. of the volume in mother ref. sys. - // irot Rotation matrix number w.r.t. mother ref. sys. - // konly ONLY/MANY flag + /// Position a volume into an existing one. + /// It positions a previously defined volume in the mother. + /// - name Volume name + /// - nr Copy number of the volume + /// - mother Mother volume name + /// - x X coord. of the volume in mother ref. sys. + /// - y Y coord. of the volume in mother ref. sys. + /// - z Z coord. of the volume in mother ref. sys. + /// - irot Rotation matrix number w.r.t. mother ref. sys. + /// - konly ONLY/MANY flag virtual void Gspos(const char *name, Int_t nr, const char *mother, Double_t x, Double_t y, Double_t z, Int_t irot, const char *konly="ONLY") = 0; - // Place a copy of generic volume name with user number - // nr inside mother, with its parameters upar(1..np) + /// Place a copy of generic volume name with user number + /// nr inside mother, with its parameters upar(1..np) virtual void Gsposp(const char *name, Int_t nr, const char *mother, Double_t x, Double_t y, Double_t z, Int_t irot, const char *konly, Float_t *upar, Int_t np) = 0; - // The same as previous but in double precision + /// The same as previous but in double precision virtual void Gsposp(const char *name, Int_t nr, const char *mother, Double_t x, Double_t y, Double_t z, Int_t irot, const char *konly, Double_t *upar, Int_t np) = 0; - // Helper function for resolving MANY. - // Specify the ONLY volume that overlaps with the - // specified MANY and has to be substracted. - // (Geant4 only) + /// Helper function for resolving MANY. + /// Specify the ONLY volume that overlaps with the + /// specified MANY and has to be substracted. + /// (Geant4 only) virtual void Gsbool(const char* onlyVolName, const char* manyVolName) = 0; // @@ -223,25 +223,25 @@ public: // ------------------------------------------------ // - // Return the transformation matrix between the volume specified by - // the path volumePath and the top or master volume. + /// Return the transformation matrix between the volume specified by + /// the path volumePath and the top or master volume. virtual Bool_t GetTransformation(const TString& volumePath, TGeoHMatrix& matrix) = 0; - // Return the name of the shape (shapeType) and its parameters par - // for the volume specified by the path volumePath . + /// Return the name of the shape (shapeType) and its parameters par + /// for the volume specified by the path volumePath . virtual Bool_t GetShape(const TString& volumePath, TString& shapeType, TArrayD& par) = 0; - // Return the material parameters for the volume specified by - // the volumeName. + /// Return the material parameters for the volume specified by + /// the volumeName. virtual Bool_t GetMaterial(const TString& volumeName, TString& name, Int_t& imat, Double_t& a, Double_t& z, Double_t& density, Double_t& radl, Double_t& inter, TArrayD& par) = 0; - // Return the medium parameters for the volume specified by the - // volumeName. + /// Return the medium parameters for the volume specified by the + /// volumeName. virtual Bool_t GetMedium(const TString& volumeName, TString& name, Int_t& imed, Int_t& nmat, Int_t& isvol, Int_t& ifield, @@ -265,28 +265,28 @@ public: // - // Return the unique numeric identifier for volume name volName + /// Return the unique numeric identifier for volume name volName virtual Int_t VolId(const char* volName) const = 0; - // Return the volume name for a given volume identifier id + /// Return the volume name for a given volume identifier id virtual const char* VolName(Int_t id) const = 0; - // Return the unique numeric identifier for medium name mediumName + /// Return the unique numeric identifier for medium name mediumName virtual Int_t MediumId(const char* mediumName) const = 0; - // Return total number of volumes in the geometry + /// Return total number of volumes in the geometry virtual Int_t NofVolumes() const = 0; - // Return number of daughters of the volume specified by volName + /// Return number of daughters of the volume specified by volName virtual Int_t NofVolDaughters(const char* volName) const = 0; - // Return the name of i-th daughter of the volume specified by volName + /// Return the name of i-th daughter of the volume specified by volName virtual const char* VolDaughterName(const char* volName, Int_t i) const = 0; - // Return the copyNo of i-th daughter of the volume specified by volName + /// Return the copyNo of i-th daughter of the volume specified by volName virtual Int_t VolDaughterCopyNo(const char* volName, Int_t i) const = 0; - // Return material number for a given volume id + /// Return material number for a given volume id virtual Int_t VolId2Mate(Int_t id) const = 0; protected: diff --git a/montecarlo/vmc/inc/TVirtualMCStack.h b/montecarlo/vmc/inc/TVirtualMCStack.h index 9bc7b9a988c9a281dd1431bf59730847e3fcfb2a..7a85dbda80f74b99e10c5c4e17cce67707e09e50 100644 --- a/montecarlo/vmc/inc/TVirtualMCStack.h +++ b/montecarlo/vmc/inc/TVirtualMCStack.h @@ -36,19 +36,19 @@ public: // Methods for stacking // - // Create a new particle and push into stack; - // toBeDone - 1 if particles should go to tracking, 0 otherwise - // parent - number of the parent track, -1 if track is primary - // pdg - PDG encoding - // px, py, pz - particle momentum [GeV/c] - // e - total energy [GeV] - // vx, vy, vz - position [cm] - // tof - time of flight [s] - // polx, poly, polz - polarization - // mech - creator process VMC code - // ntr - track number (is filled by the stack - // weight - particle weight - // is - generation status code + /// Create a new particle and push into stack; + /// - toBeDone - 1 if particles should go to tracking, 0 otherwise + /// - parent - number of the parent track, -1 if track is primary + /// - pdg - PDG encoding + /// - px, py, pz - particle momentum [GeV/c] + /// - e - total energy [GeV] + /// - vx, vy, vz - position [cm] + /// - tof - time of flight [s] + /// - polx, poly, polz - polarization + /// - mech - creator process VMC code + /// - ntr - track number (is filled by the stack + /// - weight - particle weight + /// - is - generation status code virtual void PushTrack(Int_t toBeDone, Int_t parent, Int_t pdg, Double_t px, Double_t py, Double_t pz, Double_t e, Double_t vx, Double_t vy, Double_t vz, Double_t tof, @@ -56,40 +56,40 @@ public: TMCProcess mech, Int_t& ntr, Double_t weight, Int_t is) = 0; - // The stack has to provide two pop mechanisms: - // The first pop mechanism required. - // Pop all particles with toBeDone = 1, both primaries and seconadies + /// The stack has to provide two pop mechanisms: + /// The first pop mechanism required. + /// Pop all particles with toBeDone = 1, both primaries and seconadies virtual TParticle* PopNextTrack(Int_t& itrack) = 0; - // The second pop mechanism required. - // Pop only primary particles with toBeDone = 1, stacking of secondaries - // is done by MC + /// The second pop mechanism required. + /// Pop only primary particles with toBeDone = 1, stacking of secondaries + /// is done by MC virtual TParticle* PopPrimaryForTracking(Int_t i) = 0; // // Set methods // - // Set the current track number + /// Set the current track number virtual void SetCurrentTrack(Int_t trackNumber) = 0; // // Get methods // - // Total number of tracks + /// Total number of tracks virtual Int_t GetNtrack() const = 0; - // Total number of primary tracks + /// Total number of primary tracks virtual Int_t GetNprimary() const = 0; - // Current track particle + /// Current track particle virtual TParticle* GetCurrentTrack() const= 0; - // Current track number + /// Current track number virtual Int_t GetCurrentTrackNumber() const = 0; - // Number of the parent of the current track + /// Number of the parent of the current track virtual Int_t GetCurrentParentTrackNumber() const = 0; ClassDef(TVirtualMCStack,1) //Interface to a particles stack diff --git a/montecarlo/vmc/src/TGeoMCGeometry.cxx b/montecarlo/vmc/src/TGeoMCGeometry.cxx index ba6136c4063236d99c011c442f7fce6fbd1446d6..11ee7c76b7bafedef535e2fc55b70a050432fda5 100644 --- a/montecarlo/vmc/src/TGeoMCGeometry.cxx +++ b/montecarlo/vmc/src/TGeoMCGeometry.cxx @@ -11,11 +11,11 @@ *************************************************************************/ -//______________________________________________________________________________ -// -// Implementation of the TVirtualMCGeometry interface -// for building TGeo geometry. -//______________________________________________________________________________ +/** \class TGeoMCGeometry + +Implementation of the TVirtualMCGeometry interface +for building TGeo geometry. +*/ #include <ctype.h> #include "TError.h" @@ -91,9 +91,8 @@ TGeoManager* TGeoMCGeometry::GetTGeoManager() const } //////////////////////////////////////////////////////////////////////////////// -/// Converts Float_t* array to Double_t*, +/// Convert Float_t* array to Double_t*, /// !! The new array has to be deleted by user. -/// --- Double_t* TGeoMCGeometry::CreateDoubleArray(Float_t* array, Int_t size) const { @@ -110,7 +109,7 @@ Double_t* TGeoMCGeometry::CreateDoubleArray(Float_t* array, Int_t size) const //////////////////////////////////////////////////////////////////////////////// /// -/// convert name to upper case. Make vname at least 4 chars +/// Convert name to upper case. Make vname at least 4 chars /// void TGeoMCGeometry::Vname(const char *name, char *vname) const @@ -136,22 +135,21 @@ void TGeoMCGeometry::Vname(const char *name, char *vname) const //////////////////////////////////////////////////////////////////////////////// /// -/// Defines a Material -/// -/// kmat number assigned to the material -/// name material name -/// a atomic mass in au -/// z atomic number -/// dens density in g/cm3 -/// absl absorbtion length in cm -/// if >=0 it is ignored and the program -/// calculates it, if <0. -absl is taken -/// radl radiation length in cm -/// if >=0 it is ignored and the program -/// calculates it, if <0. -radl is taken -/// buf pointer to an array of user words -/// nbuf number of user words -/// +/// Define a material +/// +/// - kmat number assigned to the material +/// - name material name +/// - a atomic mass in au +/// - z atomic number +/// - dens density in g/cm3 +/// - absl absorption length in cm; +/// if >=0 it is ignored and the program +/// calculates it, if <0. -absl is taken +/// - radl radiation length in cm +/// if >=0 it is ignored and the program +/// calculates it, if <0. -radl is taken +/// - buf pointer to an array of user words +/// - nwbuf number of user words void TGeoMCGeometry::Material(Int_t& kmat, const char* name, Double_t a, Double_t z, Double_t dens, Double_t radl, Double_t absl, Float_t* buf, @@ -164,22 +162,21 @@ void TGeoMCGeometry::Material(Int_t& kmat, const char* name, Double_t a, Double_ //////////////////////////////////////////////////////////////////////////////// /// -/// Defines a Material -/// -/// kmat number assigned to the material -/// name material name -/// a atomic mass in au -/// z atomic number -/// dens density in g/cm3 -/// absl absorbtion length in cm -/// if >=0 it is ignored and the program -/// calculates it, if <0. -absl is taken -/// radl radiation length in cm -/// if >=0 it is ignored and the program -/// calculates it, if <0. -radl is taken -/// buf pointer to an array of user words -/// nbuf number of user words -/// +/// Define a material +/// +/// - kmat number assigned to the material +/// - name material name +/// - a atomic mass in au +/// - z atomic number +/// - dens density in g/cm3 +/// - absl absorption length in cm; +/// if >=0 it is ignored and the program +/// calculates it, if <0. -absl is taken +/// - radl radiation length in cm +/// if >=0 it is ignored and the program +/// calculates it, if <0. -radl is taken +/// - buf pointer to an array of user words +/// - nwbuf number of user words void TGeoMCGeometry::Material(Int_t& kmat, const char* name, Double_t a, Double_t z, Double_t dens, Double_t radl, Double_t absl, Double_t* /*buf*/, @@ -190,17 +187,17 @@ void TGeoMCGeometry::Material(Int_t& kmat, const char* name, Double_t a, Double_ //////////////////////////////////////////////////////////////////////////////// /// -/// Defines mixture OR COMPOUND IMAT as composed by -/// THE BASIC NLMAT materials defined by arrays A,Z and WMAT +/// Define a mixture or a compound +/// with a number kmat composed by the basic nlmat materials defined +/// by arrays a, z and wmat /// -/// If NLMAT > 0 then wmat contains the proportion by +/// If nlmat > 0 then wmat contains the proportion by /// weights of each basic material in the mixture. /// -/// If nlmat < 0 then WMAT contains the number of atoms -/// of a given kind into the molecule of the COMPOUND -/// In this case, WMAT in output is changed to relative -/// weigths. -/// +/// If nlmat < 0 then wmat contains the number of atoms +/// of a given kind into the molecule of the compound. +/// In this case, wmat in output is changed to relative +/// weights. void TGeoMCGeometry::Mixture(Int_t& kmat, const char* name, Float_t* a, Float_t* z, Double_t dens, Int_t nlmat, Float_t* wmat) @@ -221,17 +218,17 @@ void TGeoMCGeometry::Mixture(Int_t& kmat, const char* name, Float_t* a, Float_t* //////////////////////////////////////////////////////////////////////////////// /// -/// Defines mixture OR COMPOUND IMAT as composed by -/// THE BASIC NLMAT materials defined by arrays A,Z and WMAT +/// Define a mixture or a compound +/// with a number kmat composed by the basic nlmat materials defined +/// by arrays a, z and wmat /// -/// If NLMAT > 0 then wmat contains the proportion by +/// If nlmat > 0 then wmat contains the proportion by /// weights of each basic material in the mixture. /// -/// If nlmat < 0 then WMAT contains the number of atoms -/// of a given kind into the molecule of the COMPOUND -/// In this case, WMAT in output is changed to relative -/// weigths. -/// +/// If nlmat < 0 then wmat contains the number of atoms +/// of a given kind into the molecule of the compound. +/// In this case, wmat in output is changed to relative +/// weights. void TGeoMCGeometry::Mixture(Int_t& kmat, const char* name, Double_t* a, Double_t* z, Double_t dens, Int_t nlmat, Double_t* wmat) @@ -252,22 +249,26 @@ void TGeoMCGeometry::Mixture(Int_t& kmat, const char* name, Double_t* a, Double_ //////////////////////////////////////////////////////////////////////////////// /// -/// kmed tracking medium number assigned -/// name tracking medium name -/// nmat material number -/// isvol sensitive volume flag -/// ifield magnetic field -/// fieldm max. field value (kilogauss) -/// tmaxfd max. angle due to field (deg/step) -/// stemax max. step allowed -/// deemax max. fraction of energy lost in a step -/// epsil tracking precision (cm) -/// stmin min. step due to continuous processes (cm) -/// -/// ifield = 0 if no magnetic field; ifield = -1 if user decision in guswim; -/// ifield = 1 if tracking performed with g3rkuta; ifield = 2 if tracking -/// performed with g3helix; ifield = 3 if tracking performed with g3helx3. -/// +/// Define a medium. +/// +/// - kmed tracking medium number assigned +/// - name tracking medium name +/// - nmat material number +/// - isvol sensitive volume flag +/// - ifield magnetic field: +/// - ifield = 0 if no magnetic field; +/// - ifield = -1 if user decision in guswim; +/// - ifield = 1 if tracking performed with g3rkuta; +/// - ifield = 2 if tracking performed with g3helix; +/// - ifield = 3 if tracking performed with g3helx3. +/// - fieldm max. field value (kilogauss) +/// - tmaxfd max. angle due to field (deg/step) +/// - stemax max. step allowed +/// - deemax max. fraction of energy lost in a step +/// - epsil tracking precision (cm) +/// - stmin min. step due to continuous processes (cm) +/// - ubuf pointer to an array of user words +/// - nbuf number of user words void TGeoMCGeometry::Medium(Int_t& kmed, const char* name, Int_t nmat, Int_t isvol, Int_t ifield, Double_t fieldm, Double_t tmaxfd, @@ -283,22 +284,26 @@ void TGeoMCGeometry::Medium(Int_t& kmed, const char* name, Int_t nmat, Int_t isv //////////////////////////////////////////////////////////////////////////////// /// -/// kmed tracking medium number assigned -/// name tracking medium name -/// nmat material number -/// isvol sensitive volume flag -/// ifield magnetic field -/// fieldm max. field value (kilogauss) -/// tmaxfd max. angle due to field (deg/step) -/// stemax max. step allowed -/// deemax max. fraction of energy lost in a step -/// epsil tracking precision (cm) -/// stmin min. step due to continuos processes (cm) -/// -/// ifield = 0 if no magnetic field; ifield = -1 if user decision in guswim; -/// ifield = 1 if tracking performed with g3rkuta; ifield = 2 if tracking -/// performed with g3helix; ifield = 3 if tracking performed with g3helx3. -/// +/// Define a medium. +/// +/// - kmed tracking medium number assigned +/// - name tracking medium name +/// - nmat material number +/// - isvol sensitive volume flag +/// - ifield magnetic field: +/// - ifield = 0 if no magnetic field; +/// - ifield = -1 if user decision in guswim; +/// - ifield = 1 if tracking performed with g3rkuta; +/// - ifield = 2 if tracking performed with g3helix; +/// - ifield = 3 if tracking performed with g3helx3. +/// - fieldm max. field value (kilogauss) +/// - tmaxfd max. angle due to field (deg/step) +/// - stemax max. step allowed +/// - deemax max. fraction of energy lost in a step +/// - epsil tracking precision (cm) +/// - stmin min. step due to continuous processes (cm) +/// - ubuf pointer to an array of user words +/// - nbuf number of user words void TGeoMCGeometry::Medium(Int_t& kmed, const char* name, Int_t nmat, Int_t isvol, Int_t ifield, Double_t fieldm, Double_t tmaxfd, @@ -310,16 +315,15 @@ void TGeoMCGeometry::Medium(Int_t& kmed, const char* name, Int_t nmat, Int_t isv //////////////////////////////////////////////////////////////////////////////// /// -/// krot rotation matrix number assigned -/// theta1 polar angle for axis i -/// phi1 azimuthal angle for axis i -/// theta2 polar angle for axis ii -/// phi2 azimuthal angle for axis ii -/// theta3 polar angle for axis iii -/// phi3 azimuthal angle for axis iii -/// -/// it defines the rotation matrix number irot. +/// Define a rotation matrix /// +/// - krot rotation matrix number assigned +/// - thetaX polar angle for axis X +/// - phiX azimuthal angle for axis X +/// - thetaY polar angle for axis Y +/// - phiY azimuthal angle for axis Y +/// - thetaZ polar angle for axis Z +/// - phiZ azimuthal angle for axis Z void TGeoMCGeometry::Matrix(Int_t& krot, Double_t thex, Double_t phix, Double_t they, Double_t phiy, Double_t thez, Double_t phiz) @@ -330,14 +334,13 @@ void TGeoMCGeometry::Matrix(Int_t& krot, Double_t thex, Double_t phix, Double_t //////////////////////////////////////////////////////////////////////////////// /// -/// NAME Volume name -/// SHAPE Volume type -/// NUMED Tracking medium number -/// NPAR Number of shape parameters -/// UPAR Vector containing shape parameters -/// -/// It creates a new volume in the JVOLUM data structure. +/// Create a new volume /// +/// - name Volume name +/// - shape Volume type +/// - nmed Tracking medium number +/// - np Number of shape parameters +/// - upar Vector containing shape parameters Int_t TGeoMCGeometry::Gsvolu(const char *name, const char *shape, Int_t nmed, Float_t *upar, Int_t npar) @@ -350,14 +353,13 @@ Int_t TGeoMCGeometry::Gsvolu(const char *name, const char *shape, Int_t nmed, //////////////////////////////////////////////////////////////////////////////// /// -/// NAME Volume name -/// SHAPE Volume type -/// NUMED Tracking medium number -/// NPAR Number of shape parameters -/// UPAR Vector containing shape parameters -/// -/// It creates a new volume in the JVOLUM data structure. +/// Create a new volume /// +/// - name Volume name +/// - shape Volume type +/// - nmed Tracking medium number +/// - np Number of shape parameters +/// - upar Vector containing shape parameters Int_t TGeoMCGeometry::Gsvolu(const char *name, const char *shape, Int_t nmed, Double_t *upar, Int_t npar) @@ -379,14 +381,12 @@ Int_t TGeoMCGeometry::Gsvolu(const char *name, const char *shape, Int_t nmed, /// /// Create a new volume by dividing an existing one /// -/// NAME Volume name -/// MOTHER Mother volume name -/// NDIV Number of divisions -/// IAXIS Axis value -/// -/// X,Y,Z of CAXIS will be translated to 1,2,3 for IAXIS. -/// It divides a previously defined volume. -/// +/// It divides a previously defined volume +/// - name Volume name +/// - mother Mother volume name +/// - ndiv Number of divisions +/// - iaxis Axis value: +/// X,Y,Z of CAXIS will be translated to 1,2,3 for IAXIS. void TGeoMCGeometry::Gsdvn(const char *name, const char *mother, Int_t ndiv, Int_t iaxis) @@ -403,10 +403,9 @@ void TGeoMCGeometry::Gsdvn(const char *name, const char *mother, Int_t ndiv, /// /// Create a new volume by dividing an existing one /// -/// Divides mother into ndiv divisions called name +/// Divide mother into ndiv divisions called name /// along axis iaxis starting at coordinate value c0. /// the new volume created will be medium number numed. -/// void TGeoMCGeometry::Gsdvn2(const char *name, const char *mother, Int_t ndiv, Int_t iaxis, Double_t c0i, Int_t numed) @@ -422,14 +421,13 @@ void TGeoMCGeometry::Gsdvn2(const char *name, const char *mother, Int_t ndiv, /// /// Create a new volume by dividing an existing one /// -/// Divides MOTHER into divisions called NAME along -/// axis IAXIS in steps of STEP. If not exactly divisible -/// will make as many as possible and will centre them -/// with respect to the mother. Divisions will have medium -/// number NUMED. If NUMED is 0, NUMED of MOTHER is taken. -/// NDVMX is the expected maximum number of divisions -/// (If 0, no protection tests are performed) -/// +/// Divide mother into divisions called name along +/// axis iaxis in steps of step. If not exactly divisible +/// will make as many as possible and will center them +/// with respect to the mother. Divisions will have medium +/// number numed. If numed is 0, numed of mother is taken. +/// ndvmx is the expected maximum number of divisions +/// (If 0, no protection tests are performed in Geant3) void TGeoMCGeometry::Gsdvt(const char *name, const char *mother, Double_t step, Int_t iaxis, Int_t numed, Int_t /*ndvmx*/) @@ -446,14 +444,13 @@ void TGeoMCGeometry::Gsdvt(const char *name, const char *mother, Double_t step, /// /// Create a new volume by dividing an existing one /// -/// Divides MOTHER into divisions called NAME along -/// axis IAXIS starting at coordinate value C0 with step -/// size STEP. -/// The new volume created will have medium number NUMED. -/// If NUMED is 0, NUMED of mother is taken. -/// NDVMX is the expected maximum number of divisions -/// (If 0, no protection tests are performed) -/// +/// Divides mother into divisions called name along +/// axis iaxis starting at coordinate value c0 with step +/// size step. +/// The new volume created will have medium number numed. +/// If numed is 0, numed of mother is taken. +/// ndvmx is the expected maximum number of divisions +/// (If 0, no protection tests are performed in Geant3) void TGeoMCGeometry::Gsdvt2(const char *name, const char *mother, Double_t step, Int_t iaxis, Double_t c0, Int_t numed, Int_t /*ndvmx*/) @@ -468,18 +465,19 @@ void TGeoMCGeometry::Gsdvt2(const char *name, const char *mother, Double_t step //////////////////////////////////////////////////////////////////////////////// /// -/// Flags volume CHNAME whose contents will have to be ordered -/// along axis IAX, by setting the search flag to -IAX -/// IAX = 1 X axis -/// IAX = 2 Y axis -/// IAX = 3 Z axis -/// IAX = 4 Rxy (static ordering only -> GTMEDI) -/// IAX = 14 Rxy (also dynamic ordering -> GTNEXT) -/// IAX = 5 Rxyz (static ordering only -> GTMEDI) -/// IAX = 15 Rxyz (also dynamic ordering -> GTNEXT) -/// IAX = 6 PHI (PHI=0 => X axis) -/// IAX = 7 THETA (THETA=0 => Z axis) -/// +/// Flag volume name whose contents will have to be ordered +/// along axis iax, by setting the search flag to -iax +/// (Geant3 only) +/// - IAX = 1 X axis +/// - IAX = 2 Y axis +/// - IAX = 3 Z axis +/// - IAX = 4 Rxy (static ordering only -> GTMEDI) +/// - IAX = 14 Rxy (also dynamic ordering -> GTNEXT) +/// - IAX = 5 Rxyz (static ordering only -> GTMEDI) +/// - IAX = 15 Rxyz (also dynamic ordering -> GTNEXT) +/// - IAX = 6 PHI (PHI=0 => X axis) +/// - IAX = 7 THETA (THETA=0 => Z axis) +/// Nothing to be done for TGeo //xx void TGeoMCGeometry::Gsord(const char * /*name*/, Int_t /*iax*/) { @@ -491,17 +489,15 @@ void TGeoMCGeometry::Gsord(const char * /*name*/, Int_t /*iax*/) /// /// Position a volume into an existing one /// -/// NAME Volume name -/// NUMBER Copy number of the volume -/// MOTHER Mother volume name -/// X X coord. of the volume in mother ref. sys. -/// Y Y coord. of the volume in mother ref. sys. -/// Z Z coord. of the volume in mother ref. sys. -/// IROT Rotation matrix number w.r.t. mother ref. sys. -/// ONLY ONLY/MANY flag -/// -/// It positions a previously defined volume in the mother. -/// +/// It positions a previously defined volume in the mother. +/// - name Volume name +/// - nr Copy number of the volume +/// - mother Mother volume name +/// - x X coord. of the volume in mother ref. sys. +/// - y Y coord. of the volume in mother ref. sys. +/// - z Z coord. of the volume in mother ref. sys. +/// - irot Rotation matrix number w.r.t. mother ref. sys. +/// - konly ONLY/MANY flag void TGeoMCGeometry::Gspos(const char *name, Int_t nr, const char *mother, Double_t x, Double_t y, Double_t z, Int_t irot, const char *konly) @@ -521,9 +517,8 @@ void TGeoMCGeometry::Gspos(const char *name, Int_t nr, const char *mother, Doub //////////////////////////////////////////////////////////////////////////////// /// -/// Place a copy of generic volume NAME with user number -/// NR inside MOTHER, with its parameters UPAR(1..NP) -/// +/// Place a copy of generic volume name with user number +/// nr inside mother, with its parameters upar(1..np) void TGeoMCGeometry::Gsposp(const char *name, Int_t nr, const char *mother, Double_t x, Double_t y, Double_t z, Int_t irot, @@ -536,9 +531,8 @@ void TGeoMCGeometry::Gsposp(const char *name, Int_t nr, const char *mother, //////////////////////////////////////////////////////////////////////////////// /// -/// Place a copy of generic volume NAME with user number -/// NR inside MOTHER, with its parameters UPAR(1..NP) -/// +/// Place a copy of generic volume name with user number +/// nr inside mother, with its parameters upar(1..np) void TGeoMCGeometry::Gsposp(const char *name, Int_t nr, const char *mother, Double_t x, Double_t y, Double_t z, Int_t irot, @@ -559,7 +553,6 @@ void TGeoMCGeometry::Gsposp(const char *name, Int_t nr, const char *mother, //////////////////////////////////////////////////////////////////////////////// /// /// Return the unique numeric identifier for volume name -/// Int_t TGeoMCGeometry::VolId(const char *name) const { @@ -574,7 +567,6 @@ Int_t TGeoMCGeometry::VolId(const char *name) const //////////////////////////////////////////////////////////////////////////////// /// /// Return the unique numeric identifier for medium name -/// Int_t TGeoMCGeometry::MediumId(const char *name) const { @@ -588,7 +580,6 @@ Int_t TGeoMCGeometry::MediumId(const char *name) const //////////////////////////////////////////////////////////////////////////////// /// /// Return the volume name given the volume identifier -/// const char* TGeoMCGeometry::VolName(Int_t id) const { @@ -603,7 +594,6 @@ const char* TGeoMCGeometry::VolName(Int_t id) const //////////////////////////////////////////////////////////////////////////////// /// /// Return total number of volumes in the geometry -/// Int_t TGeoMCGeometry::NofVolumes() const { @@ -613,7 +603,6 @@ Int_t TGeoMCGeometry::NofVolumes() const //////////////////////////////////////////////////////////////////////////////// /// Return number of daughters of the volume specified by volName /// According to A. Morsch' G3toRoot class (by A. Morsch) -/// --- Int_t TGeoMCGeometry::NofVolDaughters(const char* volName) const { @@ -630,7 +619,6 @@ Int_t TGeoMCGeometry::NofVolDaughters(const char* volName) const //////////////////////////////////////////////////////////////////////////////// /// Return the name of i-th daughters of the volume specified by volName /// According to A. Morsch' G3toRoot class. -/// --- const char* TGeoMCGeometry::VolDaughterName(const char* volName, Int_t i) const { @@ -654,11 +642,9 @@ const char* TGeoMCGeometry::VolDaughterName(const char* volName, Int_t i) const //////////////////////////////////////////////////////////////////////////////// /// Return the copyNo of i-th daughters of the volume specified by volName /// According to A. Morsch' G3toRoot class. -/// --- Int_t TGeoMCGeometry::VolDaughterCopyNo(const char* volName, Int_t i) const { - // Get volume TGeoVolume* volume = GetTGeoManager()->GetVolume(volName); if (!volume) { @@ -679,7 +665,6 @@ Int_t TGeoMCGeometry::VolDaughterCopyNo(const char* volName, Int_t i) const //////////////////////////////////////////////////////////////////////////////// /// /// Return material number for a given volume id -/// Int_t TGeoMCGeometry::VolId2Mate(Int_t id) const { @@ -694,24 +679,25 @@ Int_t TGeoMCGeometry::VolId2Mate(Int_t id) const } //////////////////////////////////////////////////////////////////////////////// -/// Returns the Transformation matrix between the volume specified -/// by the path volumePath and the Top or mater volume. The format -/// of the path volumePath is as follows (assuming ALIC is the Top volume) +/// Return the transformation matrix between the volume specified +/// by the path volumePath and the Top or mater volume. +/// +/// The format of the path volumePath is as follows (assuming ALIC is the Top volume) /// "/ALIC_1/DDIP_1/S05I_2/S05H_1/S05G_3". Here ALIC is the top most /// or master volume which has only 1 instance of. Of all of the daughter /// volumes of ALICE, DDIP volume copy #1 is indicated. Similarly for /// the daughter volume of DDIP is S05I copy #2 and so on. -/// Inputs: -/// TString& volumePath The volume path to the specific volume -/// for which you want the matrix. Volume name -/// hierarchy is separated by "/" while the -/// copy number is appended using a "_". -/// Outputs: -/// TGeoHMatrix &mat A matrix with its values set to those -/// appropriate to the Local to Master transformation -/// Return: -/// A logical value if kFALSE then an error occurred and no change to -/// mat was made. +/// - Inputs: +/// - TString& volumePath The volume path to the specific volume +/// for which you want the matrix. Volume name +/// hierarchy is separated by "/" while the +/// copy number is appended using a "_". +/// - Outputs: +/// - TGeoHMatrix &mat A matrix with its values set to those +/// appropriate to the Local to Master transformation +/// - Return: +/// - A logical value if kFALSE then an error occurred and no change to +/// mat was made. Bool_t TGeoMCGeometry::GetTransformation(const TString &volumePath,TGeoHMatrix &mat) { @@ -728,15 +714,15 @@ Bool_t TGeoMCGeometry::GetTransformation(const TString &volumePath,TGeoHMatrix & //////////////////////////////////////////////////////////////////////////////// /// Returns the shape and its parameters for the volume specified /// by volumeName. -/// Inputs: -/// TString& volumeName The volume name -/// Outputs: -/// TString &shapeType Shape type -/// TArrayD &par A TArrayD of parameters with all of the -/// parameters of the specified shape. -/// Return: -/// A logical indicating whether there was an error in getting this -/// information +/// - Inputs: +/// - TString& volumeName The volume name +/// - Outputs: +/// - TString &shapeType Shape type +/// - TArrayD &par A TArrayD of parameters with all of the +/// parameters of the specified shape. +/// - Return: +/// - A logical indicating whether there was an error in getting this +/// information Bool_t TGeoMCGeometry::GetShape(const TString &volumePath,TString &shapeType, TArrayD &par) @@ -987,22 +973,23 @@ Bool_t TGeoMCGeometry::GetShape(const TString &volumePath,TString &shapeType, //////////////////////////////////////////////////////////////////////////////// /// Returns the Material and its parameters for the volume specified /// by volumeName. +/// /// Note, Geant3 stores and uses mixtures as an element with an effective /// Z and A. Consequently, if the parameter Z is not integer, then /// this material represents some sort of mixture. -/// Inputs: -/// TString& volumeName The volume name -/// Outputs: -/// TSrting &name Material name -/// Int_t &imat Material index number -/// Double_t &a Average Atomic mass of material -/// Double_t &z Average Atomic number of material -/// Double_t &dens Density of material [g/cm^3] -/// Double_t &radl Average radiation length of material [cm] -/// Double_t &inter Average interaction length of material [cm] -/// TArrayD &par A TArrayD of user defined parameters. -/// Return: -/// kTRUE if no errors +/// - Inputs: +/// - TString& volumeName The volume name +/// - Outputs: +/// - TSrting &name Material name +/// - Int_t &imat Material index number +/// - Double_t &a Average Atomic mass of material +/// - Double_t &z Average Atomic number of material +/// - Double_t &dens Density of material [g/cm^3] +/// - Double_t &radl Average radiation length of material [cm] +/// - Double_t &inter Average interaction length of material [cm] +/// - TArrayD &par A TArrayD of user defined parameters. +/// - Return: +/// - kTRUE if no errors Bool_t TGeoMCGeometry::GetMaterial(const TString &volumeName, TString &name,Int_t &imat, @@ -1029,25 +1016,26 @@ Bool_t TGeoMCGeometry::GetMaterial(const TString &volumeName, //////////////////////////////////////////////////////////////////////////////// /// Returns the Medium and its parameters for the volume specified /// by volumeName. -/// Inputs: -/// TString& volumeName The volume name. -/// Outputs: -/// TString &name Medium name -/// Int_t &nmat Material number defined for this medium -/// Int_t &imed The medium index number -/// Int_t &isvol volume number defined for this medium -/// Int_t &iflield Magnetic field flag -/// Double_t &fieldm Magnetic field strength -/// Double_t &tmaxfd Maximum angle of deflection per step -/// Double_t &stemax Maximum step size -/// Double_t &deemax Maximum fraction of energy allowed to be lost -/// to continuous process. -/// Double_t &epsil Boundary crossing precision -/// Double_t &stmin Minimum step size allowed -/// TArrayD &par A TArrayD of user parameters with all of the -/// parameters of the specified medium. -/// Return: -/// kTRUE if there where no errors +/// +/// - Inputs: +/// - TString& volumeName The volume name. +/// - Outputs: +/// - TString &name Medium name +/// - Int_t &nmat Material number defined for this medium +/// - Int_t &imed The medium index number +/// - Int_t &isvol volume number defined for this medium +/// - Int_t &iflield Magnetic field flag +/// - Double_t &fieldm Magnetic field strength +/// - Double_t &tmaxfd Maximum angle of deflection per step +/// - Double_t &stemax Maximum step size +/// - Double_t &deemax Maximum fraction of energy allowed to be lost +/// - to continuous process. +/// - Double_t &epsil Boundary crossing precision +/// - Double_t &stmin Minimum step size allowed +/// - TArrayD &par A TArrayD of user parameters with all of the +/// parameters of the specified medium. +/// - Return: +/// - kTRUE if there where no errors Bool_t TGeoMCGeometry::GetMedium(const TString &volumeName,TString &name, Int_t &imed,Int_t &nmat,Int_t &isvol,Int_t &ifield, diff --git a/montecarlo/vmc/src/TMCVerbose.cxx b/montecarlo/vmc/src/TMCVerbose.cxx index 2f4adea02331cd0eb65e3e1b86b57771c95ece61..aecf94cfb8a45bec6fc4a6e6c229cb8c7f92dc3b 100644 --- a/montecarlo/vmc/src/TMCVerbose.cxx +++ b/montecarlo/vmc/src/TMCVerbose.cxx @@ -19,22 +19,20 @@ #include "TMCVerbose.h" -//______________________________________________________________________________ -// -// Class for printing detailed info from MC application. -// Defined levels: -// 0 no output -// 1 info up to event level -// 2 info up to tracking level -// 3 detailed info for each step -//______________________________________________________________________________ +/** \class TMCVerbose +Class for printing a detailed infomation from MC application. +Defined levels: +- 0 no output +- 1 info up to event level +- 2 info up to tracking level +- 3 detailed info for each step +*/ ClassImp(TMCVerbose) //////////////////////////////////////////////////////////////////////////////// /// Standard constructor -/// --- TMCVerbose::TMCVerbose(Int_t level) : TObject(), @@ -45,7 +43,6 @@ TMCVerbose::TMCVerbose(Int_t level) //////////////////////////////////////////////////////////////////////////////// /// Default constructor -/// --- TMCVerbose::TMCVerbose() : TObject(), @@ -56,7 +53,6 @@ TMCVerbose::TMCVerbose() //////////////////////////////////////////////////////////////////////////////// /// Destructor -/// --- TMCVerbose::~TMCVerbose() { @@ -68,7 +64,6 @@ TMCVerbose::~TMCVerbose() //////////////////////////////////////////////////////////////////////////////// /// Prints banner for track information -/// --- void TMCVerbose::PrintBanner() const { @@ -79,7 +74,6 @@ void TMCVerbose::PrintBanner() const //////////////////////////////////////////////////////////////////////////////// /// Prints track information -/// --- void TMCVerbose::PrintTrackInfo() const { @@ -103,7 +97,6 @@ void TMCVerbose::PrintTrackInfo() const //////////////////////////////////////////////////////////////////////////////// /// Prints the header for stepping information -/// --- void TMCVerbose::PrintStepHeader() const { @@ -126,7 +119,6 @@ void TMCVerbose::PrintStepHeader() const //////////////////////////////////////////////////////////////////////////////// /// Initialize MC info. -/// --- void TMCVerbose::InitMC() { @@ -136,7 +128,6 @@ void TMCVerbose::InitMC() //////////////////////////////////////////////////////////////////////////////// /// MC run info. -/// --- void TMCVerbose::RunMC(Int_t nofEvents) { @@ -146,7 +137,6 @@ void TMCVerbose::RunMC(Int_t nofEvents) //////////////////////////////////////////////////////////////////////////////// /// Finish MC run info. -/// --- void TMCVerbose::FinishRun() { @@ -156,7 +146,6 @@ void TMCVerbose::FinishRun() //////////////////////////////////////////////////////////////////////////////// /// Construct geometry info -/// --- void TMCVerbose::ConstructGeometry() { @@ -166,7 +155,6 @@ void TMCVerbose::ConstructGeometry() //////////////////////////////////////////////////////////////////////////////// /// Construct geometry for optical physics info -/// --- void TMCVerbose::ConstructOpGeometry() { @@ -176,7 +164,6 @@ void TMCVerbose::ConstructOpGeometry() //////////////////////////////////////////////////////////////////////////////// /// Initialize geometry info -/// --- void TMCVerbose::InitGeometry() { @@ -186,7 +173,6 @@ void TMCVerbose::InitGeometry() //////////////////////////////////////////////////////////////////////////////// /// Add particles info -/// --- void TMCVerbose::AddParticles() { @@ -196,7 +182,6 @@ void TMCVerbose::AddParticles() //////////////////////////////////////////////////////////////////////////////// /// Add ions info -/// --- void TMCVerbose::AddIons() { @@ -206,7 +191,6 @@ void TMCVerbose::AddIons() //////////////////////////////////////////////////////////////////////////////// /// Generate primaries info -/// --- void TMCVerbose::GeneratePrimaries() { @@ -216,7 +200,6 @@ void TMCVerbose::GeneratePrimaries() //////////////////////////////////////////////////////////////////////////////// /// Begin event info -/// --- void TMCVerbose::BeginEvent() { @@ -226,7 +209,6 @@ void TMCVerbose::BeginEvent() //////////////////////////////////////////////////////////////////////////////// /// Begin of a primary track info -/// --- void TMCVerbose::BeginPrimary() { @@ -236,7 +218,6 @@ void TMCVerbose::BeginPrimary() //////////////////////////////////////////////////////////////////////////////// /// Begin of each track info -/// --- void TMCVerbose::PreTrack() { @@ -257,7 +238,6 @@ void TMCVerbose::PreTrack() //////////////////////////////////////////////////////////////////////////////// /// Stepping info -/// --- void TMCVerbose::Stepping() { @@ -318,7 +298,6 @@ void TMCVerbose::Stepping() //////////////////////////////////////////////////////////////////////////////// /// Finish of each track info -/// --- void TMCVerbose::PostTrack() { @@ -328,7 +307,6 @@ void TMCVerbose::PostTrack() //////////////////////////////////////////////////////////////////////////////// /// Finish of a primary track info -/// --- void TMCVerbose::FinishPrimary() { @@ -338,7 +316,6 @@ void TMCVerbose::FinishPrimary() //////////////////////////////////////////////////////////////////////////////// /// Finish of an event info -/// --- void TMCVerbose::FinishEvent() { diff --git a/montecarlo/vmc/src/TVirtualMC.cxx b/montecarlo/vmc/src/TVirtualMC.cxx index 07fd6dc2d42c3d2a2c4ec172fe3ffed30c3691d4..8c569afd1ee9b749917225e9a03a55370a724c44 100644 --- a/montecarlo/vmc/src/TVirtualMC.cxx +++ b/montecarlo/vmc/src/TVirtualMC.cxx @@ -12,17 +12,20 @@ #include "TVirtualMC.h" -//______________________________________________________________________________ -// Virtual MC provides a virtual interface to Monte Carlo. -// It enables the user to build a virtual Monte Carlo application -// independent of any actual underlying Monte Carlo implementation itself. -// -// A user will have to implement a class derived from the abstract -// Monte Carlo application class, and provide functions like -// ConstructGeometry(), BeginEvent(), FinishEvent(), ... . -// The concrete Monte Carlo (Geant3, Geant4) is selected at run time - -// when processing a ROOT macro where the concrete Monte Carlo is instantiated. -//______________________________________________________________________________ +/** \class TVirtualMC + +Abstract Monte Carlo interface + +Virtual MC provides a virtual interface to Monte Carlo. +It enables the user to build a virtual Monte Carlo application +independent of any actual underlying Monte Carlo implementation itself. + +A user will have to implement a class derived from the abstract +Monte Carlo application class, and provide functions like +ConstructGeometry(), BeginEvent(), FinishEvent(), ... . +The concrete Monte Carlo (Geant3, Geant4) is selected at run time - +when processing a ROOT macro where the concrete Monte Carlo is instantiated. +*/ ClassImp(TVirtualMC) diff --git a/montecarlo/vmc/src/TVirtualMCApplication.cxx b/montecarlo/vmc/src/TVirtualMCApplication.cxx index d3143d086d1c9e57b2b3492d031f9bb849c68b97..8da1e6b8a3e9382544ad911e742ada1ddcd2f2fb 100644 --- a/montecarlo/vmc/src/TVirtualMCApplication.cxx +++ b/montecarlo/vmc/src/TVirtualMCApplication.cxx @@ -13,10 +13,11 @@ #include "TVirtualMCApplication.h" #include "TError.h" -//______________________________________________________________________________ -// -// Interface to a user Monte Carlo application. -//______________________________________________________________________________ +/** \class TVirtualMCApplication + +Interface to a user Monte Carlo application. + +*/ ClassImp(TVirtualMCApplication) diff --git a/montecarlo/vmc/src/TVirtualMCGeometry.cxx b/montecarlo/vmc/src/TVirtualMCGeometry.cxx index 3dd51e507087031733d5c7b684ab482badb9f67a..9c309d69fb38663b0666f31194af54db4ccc8038 100644 --- a/montecarlo/vmc/src/TVirtualMCGeometry.cxx +++ b/montecarlo/vmc/src/TVirtualMCGeometry.cxx @@ -12,10 +12,13 @@ #include "TVirtualMCGeometry.h" -//______________________________________________________________________________ -// Virtual MCGeometry provides a virtual interface to Monte Carlo -// geometry construction. -//______________________________________________________________________________ +/** \class TVirtualMCGeometry + +Interface to Monte Carlo geometry construction. + +This class has been separated from VirtualMC and it is used +internally in TVirtualMC implementations. +*/ ClassImp(TVirtualMCGeometry) diff --git a/montecarlo/vmc/src/TVirtualMCStack.cxx b/montecarlo/vmc/src/TVirtualMCStack.cxx index 68e8706457b0eeec86b5e4b4ca2a96f6e67f60f6..28f3cae6d5d31b85aa98504697e48deded60cd04 100644 --- a/montecarlo/vmc/src/TVirtualMCStack.cxx +++ b/montecarlo/vmc/src/TVirtualMCStack.cxx @@ -12,20 +12,22 @@ #include "TVirtualMCStack.h" -//______________________________________________________________________________ -// -// Interface to a user defined particles stack. -//______________________________________________________________________________ +/** \class TVirtualMCStack + +Interface to a user defined particles stack. +*/ ClassImp(TVirtualMCStack) //////////////////////////////////////////////////////////////////////////////// +/// Default constructor TVirtualMCStack::TVirtualMCStack() : TObject() {} //////////////////////////////////////////////////////////////////////////////// +/// Destructor TVirtualMCStack::~TVirtualMCStack() {}