File indexing completed on 2025-02-23 09:20:26
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021
0022
0023
0024
0025
0026
0027
0028
0029 #include "STCyclotronPhysicsList.hh"
0030 #include "G4Proton.hh"
0031 #include "G4Neutron.hh"
0032 #include "G4Electron.hh"
0033 #include "G4Positron.hh"
0034 #include "G4Gamma.hh"
0035 #include "G4Deuteron.hh"
0036
0037
0038 #include "G4EmStandardPhysics_option3.hh"
0039 #include "G4DecayPhysics.hh"
0040 #include "G4Decay.hh"
0041 #include "G4StepLimiter.hh"
0042 #include "G4LossTableManager.hh"
0043 #include "G4UnitsTable.hh"
0044 #include "G4SystemOfUnits.hh"
0045 #include "G4ProcessManager.hh"
0046 #include "G4Region.hh"
0047 #include "G4RegionStore.hh"
0048
0049 #include "G4EmExtraPhysics.hh"
0050 #include "G4EmParameters.hh"
0051 #include "G4NuclideTable.hh"
0052
0053 #include "G4HadronPhysicsQGSP_BERT.hh"
0054 #include "G4HadronPhysicsQGSP_BIC.hh"
0055 #include "G4HadronPhysicsQGSP_BIC_HP.hh"
0056 #include "G4HadronPhysicsQGSP_BIC_AllHP.hh"
0057 #include "G4RadioactiveDecayPhysics.hh"
0058
0059 #include "G4PhysListFactory.hh"
0060 #include "G4DeexPrecoParameters.hh"
0061 #include "G4NuclideTable.hh"
0062
0063 STCyclotronPhysicsList::STCyclotronPhysicsList(STCyclotronDetectorConstruction* det)
0064 : G4VModularPhysicsList()
0065 {
0066
0067
0068
0069 G4NuclideTable::GetInstance()->SetThresholdOfHalfLife(0.1*second);
0070 G4NuclideTable::GetInstance()->SetLevelTolerance(1.0*eV);
0071
0072
0073 fDetector = det;
0074
0075 G4LossTableManager::Instance();
0076
0077 defaultCutValue = 0.1*mm;
0078 fCutForGamma = defaultCutValue;
0079 fCutForElectron = defaultCutValue;
0080 fCutForPositron = defaultCutValue;
0081
0082 fThickness_foil = defaultCutValue;
0083 fThickness_target = defaultCutValue;
0084
0085 fCutTargetProton = fThickness_target;
0086 fCutTargetElectron = fThickness_target;
0087 fCutTargetPositron = fThickness_target;
0088 fCutTargetGamma = fThickness_target;
0089
0090 fCutFoilProton = fThickness_foil;
0091 fCutFoilElectron = fThickness_foil;
0092 fCutFoilPositron = fThickness_foil;
0093 fCutFoilGamma = fThickness_foil;
0094
0095
0096 fEmPhysicsList = new G4EmStandardPhysics_option3(0);
0097 fEmName = G4String("emstandard_opt3");
0098
0099
0100 fDecPhysicsList = new G4DecayPhysics(0);
0101 fRaddecayList = new G4RadioactiveDecayPhysics(0);
0102
0103
0104 fHadPhysicsList = new G4HadronPhysicsQGSP_BIC_AllHP(0);
0105
0106
0107
0108
0109
0110
0111 }
0112
0113 STCyclotronPhysicsList::~STCyclotronPhysicsList()
0114 {
0115
0116 delete fEmPhysicsList ;
0117 delete fDecPhysicsList;
0118 delete fRaddecayList;
0119 delete fHadPhysicsList;
0120
0121
0122 }
0123
0124 void STCyclotronPhysicsList::ConstructParticle()
0125 {
0126
0127 G4Proton::ProtonDefinition();
0128 G4Gamma::GammaDefinition();
0129 G4Electron::ElectronDefinition();
0130 G4Positron::PositronDefinition();
0131 G4Neutron::NeutronDefinition();
0132 G4Deuteron::DeuteronDefinition();
0133
0134 fDecPhysicsList->ConstructParticle();
0135
0136
0137 }
0138
0139 void STCyclotronPhysicsList::ConstructProcess()
0140 {
0141
0142
0143
0144 AddTransportation();
0145
0146
0147 fEmPhysicsList->ConstructProcess();
0148
0149
0150
0151 fDecPhysicsList->ConstructProcess();
0152 fRaddecayList->ConstructProcess();
0153
0154
0155 fHadPhysicsList->ConstructProcess();
0156
0157
0158 fThickness_foil = fDetector->GetFoilThickness()*mm;
0159 fThickness_target = fDetector->GetTargetThickness()*mm;
0160
0161
0162
0163
0164 SetCutTarget(0.01,fThickness_target/2.,fThickness_target/2.,fThickness_target/2.);
0165
0166
0167
0168 }
0169
0170 void STCyclotronPhysicsList::SetCuts()
0171 {
0172
0173 if (verboseLevel >0){
0174 G4cout << "PhysicsList::SetCuts:";
0175 G4cout << "CutLength : " << G4BestUnit(defaultCutValue,"Length") << G4endl;
0176 }
0177
0178
0179
0180 SetCutValue(fCutForGamma, "gamma");
0181 SetCutValue(fCutForElectron, "e-");
0182 SetCutValue(fCutForPositron, "e+");
0183
0184
0185 SetCutFoil(0.1,fThickness_foil/2.,fThickness_foil/2.,fThickness_foil/2.);
0186 SetCutTarget(0.01,fThickness_target/2.,fThickness_target/2.,fThickness_target/2.);
0187 if (verboseLevel>0) DumpCutValuesTable();
0188 }
0189
0190 void STCyclotronPhysicsList::SetCutForGamma(G4double cut)
0191 {
0192 fCutForGamma = cut;
0193 SetParticleCuts(fCutForGamma, G4Gamma::Gamma());
0194 }
0195
0196 void STCyclotronPhysicsList::SetCutForElectron(G4double cut)
0197 {
0198 fCutForElectron = cut;
0199 SetParticleCuts(fCutForElectron, G4Electron::Electron());
0200 }
0201
0202 void STCyclotronPhysicsList::SetCutForPositron(G4double cut)
0203 {
0204 fCutForPositron = cut;
0205 SetParticleCuts(fCutForPositron, G4Positron::Positron());
0206 }
0207
0208 void STCyclotronPhysicsList::SetCutTarget(G4double cutProton, G4double cutElectron, G4double cutPositron, G4double cutGamma){
0209
0210 fCutTargetProton = cutProton*mm;
0211 fCutTargetElectron = cutElectron*mm;
0212 fCutTargetPositron = cutPositron*mm;
0213 fCutTargetGamma = cutGamma*mm;
0214
0215 G4String regionNameTarget = "Target";
0216 G4Region* regionTarget = G4RegionStore::GetInstance()->GetRegion(regionNameTarget);
0217
0218 G4ProductionCuts* cutsTarget = new G4ProductionCuts ;
0219 cutsTarget -> SetProductionCut(fCutTargetGamma,"gamma");
0220 cutsTarget -> SetProductionCut(fCutTargetElectron,"e-");
0221 cutsTarget -> SetProductionCut(fCutTargetPositron,"e+");
0222 cutsTarget -> SetProductionCut(fCutTargetProton,"proton");
0223
0224 regionTarget -> SetProductionCuts(cutsTarget);
0225
0226 }
0227
0228 void STCyclotronPhysicsList::SetCutFoil(G4double cutProton, G4double cutElectron, G4double cutPositron, G4double cutGamma){
0229
0230 fCutFoilProton = cutProton*mm;
0231 fCutFoilElectron = cutElectron*mm;
0232 fCutFoilPositron = cutPositron*mm;
0233 fCutFoilGamma = cutGamma*mm;
0234
0235 G4RegionStore::GetInstance()->GetRegion("Foil");
0236 G4String regionNameFoil = "Foil";
0237 G4Region* regionFoil = G4RegionStore::GetInstance()->GetRegion(regionNameFoil);
0238
0239 G4ProductionCuts* cutsFoil = new G4ProductionCuts ;
0240 cutsFoil -> SetProductionCut(fCutFoilGamma,"gamma");
0241 cutsFoil -> SetProductionCut(fCutFoilElectron,"e-");
0242 cutsFoil -> SetProductionCut(fCutFoilPositron,"e+");
0243 cutsFoil -> SetProductionCut(fCutFoilProton,"proton");
0244
0245 regionFoil -> SetProductionCuts(cutsFoil);
0246
0247 }
0248