00001 #include "DsPhysConsEM.h"
00002
00003 #include "G4ProcessManager.hh"
00004
00006
00007 #include "G4MultipleScattering.hh"
00008
00009 #include "G4eIonisation.hh"
00010 #include "G4eBremsstrahlung.hh"
00011 #include "G4eplusAnnihilation.hh"
00012
00013 #include "G4MuIonisation.hh"
00014 #include "G4MuBremsstrahlung.hh"
00015 #include "G4MuPairProduction.hh"
00016 #include "G4MuonMinusCaptureAtRest.hh"
00017
00019
00020 #include "G4LowEnergyRayleigh.hh"
00021 #include "G4LowEnergyPhotoElectric.hh"
00022 #include "G4LowEnergyCompton.hh"
00023 #include "G4LowEnergyGammaConversion.hh"
00024
00025 #include "G4LowEnergyIonisation.hh"
00026 #include "G4LowEnergyBremsstrahlung.hh"
00027
00028 #include "G4hLowEnergyIonisation.hh"
00029 #include "G4EnergyLossTables.hh"
00030
00031
00032 DsPhysConsEM::DsPhysConsEM(const std::string& type,
00033 const std::string& name,
00034 const IInterface* parent)
00035 : GiGaPhysConstructorBase(type,name,parent)
00036 {
00037 declareProperty("FluorCut",m_fluorCut=250*eV,
00038 "Cut for fluorescence from photons, "
00039 "electrons and bremsstrahlung photons");
00040 }
00041 DsPhysConsEM::~DsPhysConsEM()
00042 {
00043 }
00044
00045
00046 void DsPhysConsEM::ConstructParticle()
00047 {
00048 }
00049
00050 void DsPhysConsEM::ConstructProcess()
00051 {
00052 G4LowEnergyPhotoElectric* lowePhot = new G4LowEnergyPhotoElectric();
00053 G4LowEnergyIonisation* loweIon = new G4LowEnergyIonisation();
00054 G4LowEnergyBremsstrahlung* loweBrem = new G4LowEnergyBremsstrahlung();
00055
00056
00057
00058
00059
00060
00061
00062 lowePhot->SetCutForLowEnSecPhotons(m_fluorCut);
00063 loweIon->SetCutForLowEnSecPhotons(m_fluorCut);
00064 loweBrem->SetCutForLowEnSecPhotons(m_fluorCut);
00065
00066 theParticleIterator->reset();
00067 while((*theParticleIterator)()) {
00068 G4ParticleDefinition* particle = theParticleIterator->value();
00069 G4ProcessManager* pmanager = particle->GetProcessManager();
00070 G4String particleName = particle->GetParticleName();
00071 if(particleName =="gamma") {
00072
00073 pmanager->AddDiscreteProcess(new G4LowEnergyRayleigh());
00074 pmanager->AddDiscreteProcess(lowePhot);
00075 pmanager->AddDiscreteProcess(new G4LowEnergyCompton());
00076 pmanager->AddDiscreteProcess(new G4LowEnergyGammaConversion());
00077 }
00078 else if(particleName=="e-") {
00079
00080
00081
00082 pmanager->AddProcess(new G4MultipleScattering(),-1, 1, 1);
00083 pmanager->AddProcess(loweIon, -1, 2, 2);
00084 pmanager->AddProcess(loweBrem, -1, -1, 3);
00085 }
00086 else if(particleName=="e+") {
00087
00088 pmanager->AddProcess(new G4MultipleScattering(),-1,1,1);
00089 pmanager->AddProcess(new G4eIonisation(), -1,2,2);
00090 pmanager->AddProcess(new G4eBremsstrahlung(), -1,-1,3);
00091 pmanager->AddProcess(new G4eplusAnnihilation(), 0,-1,4);
00092 }
00093 else if(particleName == "mu+" ||particleName == "mu-") {
00094
00095
00096 pmanager->AddProcess(new G4MultipleScattering(),-1, 1, 1);
00097 pmanager->AddProcess(new G4MuIonisation(), -1, 2, 2);
00098 pmanager->AddProcess(new G4MuBremsstrahlung(), -1, 3, 3);
00099 pmanager->AddProcess(new G4MuPairProduction(), -1, 4, 4);
00100
00101 if( particleName == "mu-" )
00102 pmanager->AddProcess(new G4MuonMinusCaptureAtRest(), 0,-1,-1);
00103 }
00104 else if ( !(particle->IsShortLived())&&
00105 (particle->GetPDGCharge() != 0.0) &&
00106 (particle->GetParticleName() != "chargedgeantino")) {
00107
00108 G4MultipleScattering* aMultipleScattering = new G4MultipleScattering();
00109 G4hLowEnergyIonisation* ahadronLowEIon = new G4hLowEnergyIonisation();
00110 pmanager->AddProcess(aMultipleScattering,-1,1,1);
00111 pmanager->AddProcess(ahadronLowEIon,-1,2,2);
00112
00113 ahadronLowEIon->SetFluorescence(false);
00114 }
00115 }
00116 }
00117
00118