Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

UtilIstHEP Namespace Reference


Enumerations

enum  ENeugenIstHEP {
  kNInitial = 0, kNFinal = 1, kNIntermediate = 2, kNDecayed = 3,
  kNTarget = 11, kNDIS = 12, kNRes = 13, kNRescatter = 14
}
enum  EProdMethod {
  kMPrimary, kMMultipleScattering, kMEnergyLoss, kMMagneticFieldL,
  kMDecay, kMPair, kMCompton, kMPhotoelectric,
  kMBrem, kMDeltaRay, kMAnnihilation, kMHadronic,
  kMEvaporation, kMNuclearFission, kMNuclearAbsorption, kMPbarAnnihilation,
  kMNCapture, kMHElastic, kMHInhelastic, kMMuonNuclear,
  kMTOFlimit, kMPhotoFission, kMRayleigh, kMNull,
  kMStop, kMLightAbsorption, kMLightDetection, kMLightScattering,
  kMStepMax, kMCerenkov, kMFeedBackPhoton, kMLightReflection,
  kMLightRefraction, kMSynchrotron, kMTransportation, kMNoProcess,
  kMAnnihilationRest, kMAnnihilationFlight, kMNbarAnnihilation, kMHIElastic,
  kMHCElastic, kMPhotonInhelastic, kMElectronNuclear, kMPositronNuclear,
  kMScintillation, kUnknownProdMethod
}

Functions

const char * AsString (Int_t isthep)
const char * AsString (ENeugenIstHEP isthep)
Int_t GetNeugenIstHEP (const char *isthepname)
EProdMethod GetProdMethod (TMCProcess process)
TMCProcess GetTMCProcess (EProdMethod method)
const char * AsString (EProdMethod method)

Variables

const Int_t kProdMethodOffset = 400
const Int_t kNProdMethod = kUnknownProdMethod


Enumeration Type Documentation

enum ENeugenIstHEP
 

Enumeration values:
kNInitial 
kNFinal 
kNIntermediate 
kNDecayed 
kNTarget 
kNDIS 
kNRes 
kNRescatter 

Definition at line 19 of file UtilIstHEP.h.

Referenced by AsString().

00019                      {
00020     // Status codes are those defined by neugen in $NEUGEN3PATH/inc/fncodes.inc
00021     kNInitial=0,       // Initial (0)
00022     kNFinal=1,         // Final (1)
00023     kNIntermediate=2,  // Intermediate (2)
00024     kNDecayed=3,       // Decayed (3)
00025     kNTarget=11,       // Target (11) 
00026     kNDIS=12,          // DIS (12)
00027     kNRes=13,          // Res (13)
00028     kNRescatter=14     // Rescatter (14)
00029   };

enum EProdMethod
 

Enumeration values:
kMPrimary 
kMMultipleScattering 
kMEnergyLoss 
kMMagneticFieldL 
kMDecay 
kMPair 
kMCompton 
kMPhotoelectric 
kMBrem 
kMDeltaRay 
kMAnnihilation 
kMHadronic 
kMEvaporation 
kMNuclearFission 
kMNuclearAbsorption 
kMPbarAnnihilation 
kMNCapture 
kMHElastic 
kMHInhelastic 
kMMuonNuclear 
kMTOFlimit 
kMPhotoFission 
kMRayleigh 
kMNull 
kMStop 
kMLightAbsorption 
kMLightDetection 
kMLightScattering 
kMStepMax 
kMCerenkov 
kMFeedBackPhoton 
kMLightReflection 
kMLightRefraction 
kMSynchrotron 
kMTransportation 
kMNoProcess 
kMAnnihilationRest 
kMAnnihilationFlight 
kMNbarAnnihilation 
kMHIElastic 
kMHCElastic 
kMPhotonInhelastic 
kMElectronNuclear 
kMPositronNuclear 
kMScintillation 
kUnknownProdMethod 

Definition at line 35 of file UtilIstHEP.h.

Referenced by AsString().

00035                    {  
00036     // Note: The order of the production method codes should be preserved so 
00037     // that the status code stored with the stdhep particle retains 
00038     // meaning even for older versions of the code.  New production method
00039     // codes should be added to the end of the list and associated methods
00040     // (GetProdMethod,etc.) should be updated accordingly.
00041 
00042     kMPrimary,            // Primary interaction
00043 
00044     kMMultipleScattering, // multiple scattering
00045     kMEnergyLoss,         // continuous energy loss
00046     kMMagneticFieldL,     // bending in mag. field
00047     kMDecay,              // particle decay
00048     kMPair,               // photon pair production or
00049                           // muon direct pair production
00050     kMCompton,            // Compton scattering
00051     kMPhotoelectric,      // photoelectric effect
00052     kMBrem,               // bremsstrahlung
00053     kMDeltaRay,           // delta-ray production
00054     kMAnnihilation,       // positron annihilation
00055 
00056     kMHadronic,           // hadronic interaction
00057     kMEvaporation,        // nuclear evaporation
00058     kMNuclearFission,     // nuclear fission
00059     kMNuclearAbsorption,  // nuclear absorption
00060     kMPbarAnnihilation,   // antiproton annihilation
00061     kMNCapture,           // neutron capture
00062     kMHElastic,           // hadronic elastic scattering
00063     kMHInhelastic,        // hadronic inelastic scattering
00064 
00065     kMMuonNuclear,        // muon nuclear interaction
00066 
00067     kMTOFlimit,           // exceeded time of flight cut
00068     kMPhotoFission,       // nuclear photofission
00069 
00070     kMRayleigh,           // Rayleigh scattering
00071 
00072     kMNull,               // no mechanism is active, usually at the entrance
00073                           // of a new volume
00074     kMStop,               // particle has fallen below energy threshold
00075                           // and tracking stops
00076 
00077     kMLightAbsorption,    // Cerenkov photon absorption
00078     kMLightDetection,     // Optical photon detection (absorption + photoelectron production)
00079     kMLightScattering,    // Cerenkov photon reflection/refraction
00080     kMStepMax,            // step limited by STEMAX
00081 
00082     kMCerenkov,           // Cerenkov photon generation
00083     kMFeedBackPhoton,     // Feed back photon in RICH -- ALICE specific
00084     kMLightReflection,    // Cerenkov photon reflection
00085     kMLightRefraction,    // Cerenkov photon refraction
00086     kMSynchrotron,        // synchrotron radiation generation
00087 
00088     kMTransportation,     // Transportation
00089 
00090     kMNoProcess,          // unknown process
00091 
00092     // The set of corresponding TMCProcess codes for the following 
00093     // only appeared in ROOT beginning with v5.17/06
00094     kMAnnihilationRest,   // positron annihilation at rest
00095     kMAnnihilationFlight, // positron annihilation in flight
00096     kMNbarAnnihilation,   // antineutron annihilation
00097     kMHIElastic,          // hadronic elastic incoherent scattering
00098     kMHCElastic,          // hadronic elastic coherent scattering
00099     kMPhotonInhelastic,   // photon inelastic scattering
00100     kMElectronNuclear,    // electron nuclear interaction
00101     kMPositronNuclear,    // positron nuclear interaction
00102     kMScintillation,      // scintillation
00103 
00104     kUnknownProdMethod
00105   };


Function Documentation

const char * UtilIstHEP::AsString EProdMethod  method  ) 
 

Definition at line 304 of file UtilIstHEP.cxx.

References GetTMCProcess().

00304                                                        {
00305   // Purpose: Convert production method status code to a string
00306 
00307   TMCProcess processcode = GetTMCProcess(prodmethod);
00308   return TMCProcessName[processcode];
00309   
00310 }

const char * UtilIstHEP::AsString ENeugenIstHEP  isthep  ) 
 

Definition at line 25 of file UtilIstHEP.cxx.

References kNDecayed, kNDIS, kNFinal, kNInitial, kNIntermediate, kNRes, kNRescatter, kNTarget, and MSG.

00025                                                            {
00026   //  Purpose:  Convert enumerated Neugen IstHEP code to a string.
00027   //  Return:  isthep string. If unknown, returns "Unknown".
00028 
00029   switch ( neugenisthep ) {
00030 
00031     case kNInitial:
00032       return "Initial";
00033     case kNFinal:
00034       return "Final";
00035     case kNIntermediate:
00036       return "Intermediate";
00037     case kNDecayed:
00038       return "Decayed";
00039     case kNTarget:
00040       return "Target";
00041     case kNDIS:
00042       return "DIS";
00043     case kNRes:
00044       return "Res";
00045     case kNRescatter:
00046       return "Rescatter";
00047     default:
00048       MSG("Util",Msg::kWarning) 
00049       << "UtilIstHEP::AsString called with unknown ENeugenIstHEP " 
00050       << (Int_t)neugenisthep << endl;
00051       return "Unknown";
00052 
00053   }//end of switch
00054 
00055 }

const char * UtilIstHEP::AsString Int_t  isthep  ) 
 

Definition at line 313 of file UtilIstHEP.cxx.

References ENeugenIstHEP, EProdMethod, kMDecay, and kProdMethodOffset.

Referenced by MCAppParticle::GetStatusCodeName(), PTSimModule::HandleCommand(), PTSimValidate::TestParticle(), and MCAppValidate::TestParticle().

00313                                              {
00314   //  Purpose:  Convert isthep status code to a string.
00315   //
00316   //  Argument: isthep code.
00317   //
00318   //  Return:  isthep string. If unknown, returns "Unknown".
00319   //
00320   //  Notes: If isthep <  200 => Neugen IstHEP code
00321   //         If isthep >= kProdMethodOffset 
00322   //         && isthep <  kProdMethodOffset + kNProdMethod  
00323   //                          => EProdMethod production method code
00324   //         If isthep == 999 => "Info" 
00325   //         If isthep == kProdMethodOffset + kMDecay + 1000
00326   //                      => "Decay Parent" 
00327   //         Otherwise return "Unknown"
00328 
00329 
00330   if ( isthep < 200 ) {
00331     ENeugenIstHEP neugenisthep = (ENeugenIstHEP)isthep;
00332     return AsString(neugenisthep);
00333   }
00334   else if ( isthep >= kProdMethodOffset 
00335          && isthep <  kProdMethodOffset + kNProdMethod ) {
00336     EProdMethod prodmethod = (EProdMethod)(isthep-kProdMethodOffset);
00337     return AsString(prodmethod);
00338   }
00339   else if ( isthep == 999 ) {
00340     return "Info";
00341   }
00342   else if ( isthep == (kProdMethodOffset + kMDecay + 1000) ) {
00343     return "Decay Parent";
00344   }
00345   else {
00346     //MSG("Util",Msg::kWarning) 
00347     //  << "UtilIstHEP::AsString called with unknown isthep code " 
00348     //  << isthep << endl;
00349     return "Unknown";
00350   }
00351 
00352 }

Int_t UtilIstHEP::GetNeugenIstHEP const char *  isthepname  ) 
 

Definition at line 277 of file UtilIstHEP.cxx.

00277                                                         {
00278   // Purpose: Convert text string isthepname to an enumerated code.
00279   // 
00280   // Argument: isthepname string
00281   //
00282   // Return: returns -1 if no match
00283   //
00284 
00285   TString tmpstr(isthepname);
00286   tmpstr.ToLower();
00287   if ( strcmp(tmpstr.Data(),"initial") == 0 ) return UtilIstHEP::kNInitial;
00288   else if ( strcmp(tmpstr.Data(),"final") == 0 ) return UtilIstHEP::kNFinal;
00289   else if ( strcmp(tmpstr.Data(),"intermediate") == 0 ) 
00290                                            return UtilIstHEP::kNIntermediate;
00291   else if ( strcmp(tmpstr.Data(),"decayed") == 0 ) 
00292                                            return UtilIstHEP::kNDecayed;
00293   else if ( strcmp(tmpstr.Data(),"target") == 0 ) return UtilIstHEP::kNTarget;
00294   else if ( strcmp(tmpstr.Data(),"dis") == 0 ) return UtilIstHEP::kNDIS;
00295   else if ( strcmp(tmpstr.Data(),"res") == 0 ) return UtilIstHEP::kNRes;
00296   else if ( strcmp(tmpstr.Data(),"rescatter") == 0 ) 
00297                                                return UtilIstHEP::kNRescatter;
00298 
00299   return -1;
00300 
00301 }

UtilIstHEP::EProdMethod UtilIstHEP::GetProdMethod TMCProcess  process  ) 
 

Definition at line 58 of file UtilIstHEP.cxx.

References MSG.

Referenced by PTSimStack::PushTrack().

00058                                                                   {
00059   // Purpose: Interpret a TMCProcess as an EProdMethod
00060 
00061   switch (process) {
00062 
00063   case kPPrimary:
00064     return kMPrimary;
00065   case kPMultipleScattering:
00066     return kMMultipleScattering;
00067   case kPEnergyLoss:         
00068     return kMEnergyLoss;
00069   case kPMagneticFieldL:
00070     return kMMagneticFieldL;
00071   case kPDecay:
00072     return kMDecay;
00073   case kPPair:
00074     return kMPair;
00075   case kPCompton:
00076     return kMCompton;
00077   case kPPhotoelectric:
00078     return kMPhotoelectric;
00079   case kPBrem:
00080     return kMBrem;
00081   case kPDeltaRay:
00082     return kMDeltaRay;
00083   case kPAnnihilation:
00084     return kMAnnihilation;
00085   case kPHadronic:
00086     return kMHadronic;
00087   case kPEvaporation:
00088     return kMEvaporation;
00089   case kPNuclearFission:
00090     return kMNuclearFission;
00091   case kPNuclearAbsorption:
00092     return kMNuclearAbsorption;
00093   case kPPbarAnnihilation:
00094     return kMPbarAnnihilation;  
00095   case kPNCapture:
00096     return kMNCapture;
00097   case kPHElastic:
00098     return kMHElastic;
00099   case kPHInhelastic:
00100     return kMHInhelastic;
00101   case kPMuonNuclear:
00102     return kMMuonNuclear;
00103   case kPTOFlimit:
00104     return kMTOFlimit;
00105   case kPPhotoFission:
00106     return kMPhotoFission;
00107   case kPRayleigh:
00108     return kMRayleigh;
00109   case kPNull:
00110     return kMNull;
00111   case kPStop:
00112     return kMStop;
00113   case kPLightAbsorption:
00114     return kMLightAbsorption;
00115   case kPLightDetection:
00116     return kMLightDetection;
00117   case kPLightScattering:
00118     return kMLightScattering;
00119   case kStepMax:
00120     return kMStepMax;
00121   case kPCerenkov:
00122     return kMCerenkov;
00123   case kPFeedBackPhoton:
00124     return kMFeedBackPhoton;
00125   case kPLightReflection:
00126     return kMLightReflection;
00127   case kPLightRefraction:
00128     return kMLightRefraction;
00129   case kPSynchrotron:
00130     return kMSynchrotron;
00131   case kPTransportation:
00132     return kMTransportation;
00133   case kPNoProcess:
00134     return kMNoProcess;
00135 #if ROOT_VERSION_CODE >= ROOT_VERSION(5,17,06)
00136   // These only appeared in TMCProcess beginning with ROOT v5.17/06
00137   case kPAnnihilationRest:
00138     return kMAnnihilationRest;
00139   case kPAnnihilationFlight:
00140     return kMAnnihilationFlight;
00141   case kPNbarAnnihilation:
00142     return kMNbarAnnihilation;
00143   case kPHIElastic:
00144     return kMHIElastic;
00145   case kPHCElastic:
00146     return kMHCElastic;
00147   case kPPhotonInhelastic:
00148     return kMPhotonInhelastic;
00149   case kPElectronNuclear:
00150     return kMElectronNuclear;
00151   case kPPositronNuclear:
00152     return kMPositronNuclear;
00153   case kPScintillation:
00154     return kMScintillation;
00155 #endif
00156   default:
00157     MSG("Util",Msg::kError) << "UtilIstHEP::GetProdMethod for TMCProcess " 
00158                             << process << "/" << TMCProcessName[process] 
00159                             << " failed!\nUpdate UtilIstHEP to include " 
00160                             << "missing process. Abort." << endl;
00161     abort();
00162   }
00163     
00164 }

TMCProcess UtilIstHEP::GetTMCProcess EProdMethod  method  ) 
 

Definition at line 167 of file UtilIstHEP.cxx.

References kMAnnihilation, kMAnnihilationFlight, kMAnnihilationRest, kMBrem, kMCerenkov, kMCompton, kMDecay, kMDeltaRay, kMElectronNuclear, kMEnergyLoss, kMEvaporation, kMFeedBackPhoton, kMHadronic, kMHCElastic, kMHElastic, kMHIElastic, kMHInhelastic, kMLightAbsorption, kMLightDetection, kMLightReflection, kMLightRefraction, kMLightScattering, kMMagneticFieldL, kMMultipleScattering, kMMuonNuclear, kMNbarAnnihilation, kMNCapture, kMNoProcess, kMNuclearAbsorption, kMNuclearFission, kMNull, kMPair, kMPbarAnnihilation, kMPhotoelectric, kMPhotoFission, kMPhotonInhelastic, kMPositronNuclear, kMPrimary, kMRayleigh, kMScintillation, kMStepMax, kMStop, kMSynchrotron, kMTOFlimit, kMTransportation, and MSG.

Referenced by AsString(), and PTSimModule::HandleCommand().

00167                                                            {
00168   // Purpose: Interpret a EProdMethod as a TMCProcess
00169 
00170   switch (prodmethod) {
00171 
00172   case kMPrimary:
00173     return kPPrimary;
00174   case kMMultipleScattering:
00175     return kPMultipleScattering;
00176   case kMEnergyLoss:         
00177     return kPEnergyLoss;
00178   case kMMagneticFieldL:
00179     return kPMagneticFieldL;
00180   case kMDecay:
00181     return kPDecay;
00182   case kMPair:
00183     return kPPair;
00184   case kMCompton:
00185     return kPCompton;
00186   case kMPhotoelectric:
00187     return kPPhotoelectric;
00188   case kMBrem:
00189     return kPBrem;
00190   case kMDeltaRay:
00191     return kPDeltaRay;
00192   case kMAnnihilation:
00193     return kPAnnihilation;
00194   case kMHadronic:
00195     return kPHadronic;
00196   case kMEvaporation:
00197     return kPEvaporation;
00198   case kMNuclearFission:
00199     return kPNuclearFission;
00200   case kMNuclearAbsorption:
00201     return kPNuclearAbsorption;
00202   case kMPbarAnnihilation:
00203     return kPPbarAnnihilation;  
00204   case kMNCapture:
00205     return kPNCapture;
00206   case kMHElastic:
00207     return kPHElastic;
00208   case kMHInhelastic:
00209     return kPHInhelastic;
00210   case kMMuonNuclear:
00211     return kPMuonNuclear;
00212   case kMTOFlimit:
00213     return kPTOFlimit;
00214   case kMPhotoFission:
00215     return kPPhotoFission;
00216   case kMRayleigh:
00217     return kPRayleigh;
00218   case kMNull:
00219     return kPNull;
00220   case kMStop:
00221     return kPStop;
00222   case kMLightAbsorption:
00223     return kPLightAbsorption;
00224   case kMLightDetection:
00225     return kPLightDetection;
00226   case kMLightScattering:
00227     return kPLightScattering;
00228   case kMStepMax:
00229     return kStepMax;
00230   case kMCerenkov:
00231     return kPCerenkov;
00232   case kMFeedBackPhoton:
00233     return kPFeedBackPhoton;
00234   case kMLightReflection:
00235     return kPLightReflection;
00236   case kMLightRefraction:
00237     return kPLightRefraction;
00238   case kMSynchrotron:
00239     return kPSynchrotron;
00240   case kMTransportation:
00241     return kPTransportation;
00242   case kMNoProcess:
00243     return kPNoProcess;
00244 #if ROOT_VERSION_CODE >= ROOT_VERSION(5,17,06)
00245   // These only appeared in TMCProcess beginning with ROOT v5.17/06
00246   case kMAnnihilationRest:
00247     return kPAnnihilationRest;
00248   case kMAnnihilationFlight:
00249     return kPAnnihilationFlight;
00250   case kMNbarAnnihilation:
00251     return kPNbarAnnihilation;
00252   case kMHIElastic:
00253     return kPHIElastic;
00254   case kMHCElastic:
00255     return kPHCElastic;
00256   case kMPhotonInhelastic:
00257     return kPPhotonInhelastic;
00258   case kMElectronNuclear:
00259     return kPElectronNuclear;
00260   case kMPositronNuclear:
00261     return kPPositronNuclear;
00262   case kMScintillation:
00263     return kPScintillation;
00264 #endif
00265   default:
00266     MSG("Util",Msg::kError) << "UtilIstHEP::GetTMCProcess for EProdMethod " 
00267                             << prodmethod
00268                             << " failed!\nUpdate UtilIstHEP to include " 
00269                             << "missing production method. Abort." << endl;
00270     abort();
00271   }
00272     
00273 }


Variable Documentation

const Int_t UtilIstHEP::kNProdMethod = kUnknownProdMethod
 

Definition at line 107 of file UtilIstHEP.h.

const Int_t UtilIstHEP::kProdMethodOffset = 400
 

Definition at line 33 of file UtilIstHEP.h.

Referenced by AsString().


Generated on Mon Jun 16 15:04:24 2008 for loon by  doxygen 1.3.9.1