#include "AAPhysicsList.hh" #include "G4ParticleTypes.hh" #include "G4LeptonConstructor.hh" #include "G4ComptonScattering.hh" #include "G4PhysicsListHelper.hh" #include "G4ComptonScattering.hh" #include "G4GammaConversion.hh" #include "G4PhotoElectricEffect.hh" #include "G4eMultipleScattering.hh" #include "G4eIonisation.hh" #include "G4eBremsstrahlung.hh" #include "G4eplusAnnihilation.hh" #include "G4MuMultipleScattering.hh" #include "G4MuIonisation.hh" #include "G4MuBremsstrahlung.hh" #include "G4MuPairProduction.hh" #include "G4hMultipleScattering.hh" #include "G4hIonisation.hh" #include "G4hBremsstrahlung.hh" #include "G4hPairProduction.hh" #include "G4ionIonisation.hh" #include "G4BosonConstructor.hh" #include "G4LeptonConstructor.hh" #include "G4MesonConstructor.hh" #include "G4BosonConstructor.hh" #include "G4BaryonConstructor.hh" #include "G4IonConstructor.hh" #include "G4VUserPhysicsList.hh" #include using namespace std; using namespace CLHEP; void AAPhysicsList::ConstructParticle() { G4BosonConstructor::ConstructParticle(); G4LeptonConstructor::ConstructParticle(); G4MesonConstructor::ConstructParticle(); G4BaryonConstructor::ConstructParticle(); G4IonConstructor::ConstructParticle(); // G4LeptonConstructor::ConstructParticle(); // Construct all leptons // G4Proton::ProtonDefinition(); } void AAPhysicsList::ConstructProcess() { // Define transportation process AddTransportation(); ConstructEM(); } void AAPhysicsList::ConstructEM() { G4PhysicsListHelper* ph = G4PhysicsListHelper::GetPhysicsListHelper(); auto theParticleIterator = GetParticleIterator(); theParticleIterator->reset(); while( (*theParticleIterator)() ) { G4ParticleDefinition* particle = theParticleIterator->value(); G4String particleName = particle->GetParticleName(); if (particleName == "gamma") { ph->RegisterProcess(new G4PhotoElectricEffect, particle); ph->RegisterProcess(new G4ComptonScattering, particle); ph->RegisterProcess(new G4GammaConversion, particle); } else if (particleName == "e-") { ph->RegisterProcess(new G4eMultipleScattering, particle); ph->RegisterProcess(new G4eIonisation, particle); ph->RegisterProcess(new G4eBremsstrahlung, particle); } else if (particleName == "e+") { ph->RegisterProcess(new G4eMultipleScattering, particle); ph->RegisterProcess(new G4eIonisation, particle); ph->RegisterProcess(new G4eBremsstrahlung, particle); ph->RegisterProcess(new G4eplusAnnihilation, particle); } else if( particleName == "mu+" || particleName == "mu-" ) { ph->RegisterProcess(new G4MuMultipleScattering, particle); ph->RegisterProcess(new G4MuIonisation, particle); ph->RegisterProcess(new G4MuBremsstrahlung, particle); ph->RegisterProcess(new G4MuPairProduction, particle); } else if( particleName == "proton" || particleName == "pi-" || particleName == "pi+" ) { ph->RegisterProcess(new G4hMultipleScattering, particle); ph->RegisterProcess(new G4hIonisation, particle); ph->RegisterProcess(new G4hBremsstrahlung, particle); ph->RegisterProcess(new G4hPairProduction, particle); } else if( particleName == "alpha" || particleName == "He3" ) { ph->RegisterProcess(new G4hMultipleScattering, particle); ph->RegisterProcess(new G4ionIonisation, particle); } else if( particleName == "GenericIon" ) { ph->RegisterProcess(new G4hMultipleScattering, particle); ph->RegisterProcess(new G4ionIonisation, particle); } else if ((!particle->IsShortLived()) && (particle->GetPDGCharge() != 0.0) && (particle->GetParticleName() != "chargedgeantino")) { ph->RegisterProcess(new G4hMultipleScattering, particle); ph->RegisterProcess(new G4hIonisation, particle); } }// particle loop } void AAPhysicsList::SetCuts() { double defaultCutValue = 0.1 * m; SetCutValue(defaultCutValue, "gamma"); SetCutValue(defaultCutValue, "e-"); SetCutValue(defaultCutValue, "e+"); // uppress error messages even in case e/gamma/proton do not exist G4int temp = GetVerboseLevel(); SetVerboseLevel(0); cout << "AAPhysicsList::SetCuts() " << endl; DumpCutValuesTable(); // " G4VUserPhysicsList::SetCutsWithDefault" method sets // the default cut value for all particle types // SetCutsWithDefault(); // Retrieve verbose level SetVerboseLevel(temp); }