BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
ExN03PhysicsList Class Reference

#include <ExN03PhysicsList.hh>

Inheritance diagram for ExN03PhysicsList:

Public Member Functions

 ExN03PhysicsList ()
 ~ExN03PhysicsList ()

Protected Member Functions

void ConstructParticle ()
void ConstructProcess ()
void SetCuts ()
void ConstructBosons ()
void ConstructLeptons ()
void ConstructMesons ()
void ConstructBaryons ()
void ConstructGeneral ()
void ConstructEM ()

Detailed Description

Definition at line 40 of file ExN03PhysicsList.hh.

Constructor & Destructor Documentation

◆ ExN03PhysicsList()

ExN03PhysicsList::ExN03PhysicsList ( )

Definition at line 45 of file ExN03PhysicsList.cxx.

45 : G4VUserPhysicsList() {
46 defaultCutValue = 1.0 * mm;
47 SetVerboseLevel( 1 );
48}

◆ ~ExN03PhysicsList()

ExN03PhysicsList::~ExN03PhysicsList ( )

Definition at line 52 of file ExN03PhysicsList.cxx.

52{}

Member Function Documentation

◆ ConstructBaryons()

void ExN03PhysicsList::ConstructBaryons ( )
protected

Definition at line 116 of file ExN03PhysicsList.cxx.

116 {
117 // barions
118 G4Proton::ProtonDefinition();
119 G4AntiProton::AntiProtonDefinition();
120 G4Neutron::NeutronDefinition();
121 G4AntiNeutron::AntiNeutronDefinition();
122}

Referenced by ConstructParticle().

◆ ConstructBosons()

void ExN03PhysicsList::ConstructBosons ( )
protected

Definition at line 70 of file ExN03PhysicsList.cxx.

70 {
71 // pseudo-particles
72 G4Geantino::GeantinoDefinition();
73 G4ChargedGeantino::ChargedGeantinoDefinition();
74
75 // gamma
76 G4Gamma::GammaDefinition();
77
78 // optical photon
79 G4OpticalPhoton::OpticalPhotonDefinition();
80}

Referenced by ConstructParticle().

◆ ConstructEM()

void ExN03PhysicsList::ConstructEM ( )
protected

Definition at line 152 of file ExN03PhysicsList.cxx.

152 {
153 theParticleIterator->reset();
154 while ( ( *theParticleIterator )() )
155 {
156 G4ParticleDefinition* particle = theParticleIterator->value();
157 G4ProcessManager* pmanager = particle->GetProcessManager();
158 G4String particleName = particle->GetParticleName();
159
160 if ( particleName == "gamma" )
161 {
162 // gamma
163 pmanager->AddDiscreteProcess( new G4GammaConversion() );
164 pmanager->AddDiscreteProcess( new G4ComptonScattering() );
165 pmanager->AddDiscreteProcess( new G4PhotoElectricEffect() );
166 }
167 else if ( particleName == "e-" )
168 {
169 // electron
170 G4VProcess* theeminusMultipleScattering = new G4MultipleScattering();
171 G4VProcess* theeminusIonisation = new G4eIonisation();
172 G4VProcess* theeminusBremsstrahlung = new G4eBremsstrahlung();
173 //
174 // add processes
175 pmanager->AddProcess( theeminusMultipleScattering );
176 pmanager->AddProcess( theeminusIonisation );
177 pmanager->AddProcess( theeminusBremsstrahlung );
178 //
179 // set ordering for AlongStepDoIt
180 pmanager->SetProcessOrdering( theeminusMultipleScattering, idxAlongStep, 1 );
181 pmanager->SetProcessOrdering( theeminusIonisation, idxAlongStep, 2 );
182 //
183 // set ordering for PostStepDoIt
184 pmanager->SetProcessOrdering( theeminusMultipleScattering, idxPostStep, 1 );
185 pmanager->SetProcessOrdering( theeminusIonisation, idxPostStep, 2 );
186 pmanager->SetProcessOrdering( theeminusBremsstrahlung, idxPostStep, 3 );
187 }
188 else if ( particleName == "e+" )
189 {
190 // positron
191 G4VProcess* theeplusMultipleScattering = new G4MultipleScattering();
192 G4VProcess* theeplusIonisation = new G4eIonisation();
193 G4VProcess* theeplusBremsstrahlung = new G4eBremsstrahlung();
194 G4VProcess* theeplusAnnihilation = new G4eplusAnnihilation();
195 //
196 // add processes
197 pmanager->AddProcess( theeplusMultipleScattering );
198 pmanager->AddProcess( theeplusIonisation );
199 pmanager->AddProcess( theeplusBremsstrahlung );
200 pmanager->AddProcess( theeplusAnnihilation );
201 //
202 // set ordering for AtRestDoIt
203 pmanager->SetProcessOrderingToFirst( theeplusAnnihilation, idxAtRest );
204 //
205 // set ordering for AlongStepDoIt
206 pmanager->SetProcessOrdering( theeplusMultipleScattering, idxAlongStep, 1 );
207 pmanager->SetProcessOrdering( theeplusIonisation, idxAlongStep, 2 );
208 //
209 // set ordering for PostStepDoIt
210 pmanager->SetProcessOrdering( theeplusMultipleScattering, idxPostStep, 1 );
211 pmanager->SetProcessOrdering( theeplusIonisation, idxPostStep, 2 );
212 pmanager->SetProcessOrdering( theeplusBremsstrahlung, idxPostStep, 3 );
213 pmanager->SetProcessOrdering( theeplusAnnihilation, idxPostStep, 4 );
214 }
215 else if ( particleName == "mu+" || particleName == "mu-" )
216 {
217 // muon
218 G4VProcess* aMultipleScattering = new G4MultipleScattering();
219 G4VProcess* aBremsstrahlung = new G4MuBremsstrahlung();
220 G4VProcess* aPairProduction = new G4MuPairProduction();
221 G4VProcess* anIonisation = new G4MuIonisation();
222 //
223 // add processes
224 pmanager->AddProcess( anIonisation );
225 pmanager->AddProcess( aMultipleScattering );
226 pmanager->AddProcess( aBremsstrahlung );
227 pmanager->AddProcess( aPairProduction );
228 //
229 // set ordering for AlongStepDoIt
230 pmanager->SetProcessOrdering( aMultipleScattering, idxAlongStep, 1 );
231 pmanager->SetProcessOrdering( anIonisation, idxAlongStep, 2 );
232 //
233 // set ordering for PostStepDoIt
234 pmanager->SetProcessOrdering( aMultipleScattering, idxPostStep, 1 );
235 pmanager->SetProcessOrdering( anIonisation, idxPostStep, 2 );
236 pmanager->SetProcessOrdering( aBremsstrahlung, idxPostStep, 3 );
237 pmanager->SetProcessOrdering( aPairProduction, idxPostStep, 4 );
238 }
239 else if ( ( !particle->IsShortLived() ) && ( particle->GetPDGCharge() != 0.0 ) &&
240 ( particle->GetParticleName() != "chargedgeantino" ) )
241 {
242 // all others charged particles except geantino
243 G4VProcess* aMultipleScattering = new G4MultipleScattering();
244 G4VProcess* anIonisation = new G4hIonisation();
245 //
246 // add processes
247 pmanager->AddProcess( anIonisation );
248 pmanager->AddProcess( aMultipleScattering );
249 //
250 // set ordering for AlongStepDoIt
251 pmanager->SetProcessOrdering( aMultipleScattering, idxAlongStep, 1 );
252 pmanager->SetProcessOrdering( anIonisation, idxAlongStep, 2 );
253 //
254 // set ordering for PostStepDoIt
255 pmanager->SetProcessOrdering( aMultipleScattering, idxPostStep, 1 );
256 pmanager->SetProcessOrdering( anIonisation, idxPostStep, 2 );
257 }
258 }
259}

Referenced by ConstructProcess().

◆ ConstructGeneral()

void ExN03PhysicsList::ConstructGeneral ( )
protected

Definition at line 265 of file ExN03PhysicsList.cxx.

265 {
266 // Add Decay Process
267 G4Decay* theDecayProcess = new G4Decay();
268 theParticleIterator->reset();
269 while ( ( *theParticleIterator )() )
270 {
271 G4ParticleDefinition* particle = theParticleIterator->value();
272 G4ProcessManager* pmanager = particle->GetProcessManager();
273 if ( theDecayProcess->IsApplicable( *particle ) )
274 {
275 pmanager->AddProcess( theDecayProcess );
276 // set ordering for PostStepDoIt and AtRestDoIt
277 pmanager->SetProcessOrdering( theDecayProcess, idxPostStep );
278 pmanager->SetProcessOrdering( theDecayProcess, idxAtRest );
279 }
280 }
281}

Referenced by ConstructProcess().

◆ ConstructLeptons()

void ExN03PhysicsList::ConstructLeptons ( )
protected

Definition at line 84 of file ExN03PhysicsList.cxx.

84 {
85 // leptons
86 G4Electron::ElectronDefinition();
87 G4Positron::PositronDefinition();
88 G4MuonPlus::MuonPlusDefinition();
89 G4MuonMinus::MuonMinusDefinition();
90
91 G4NeutrinoE::NeutrinoEDefinition();
92 G4AntiNeutrinoE::AntiNeutrinoEDefinition();
93 G4NeutrinoMu::NeutrinoMuDefinition();
94 G4AntiNeutrinoMu::AntiNeutrinoMuDefinition();
95}

Referenced by ConstructParticle().

◆ ConstructMesons()

void ExN03PhysicsList::ConstructMesons ( )
protected

Definition at line 99 of file ExN03PhysicsList.cxx.

99 {
100 // mesons
101 G4PionPlus::PionPlusDefinition();
102 G4PionMinus::PionMinusDefinition();
103 G4PionZero::PionZeroDefinition();
104 G4Eta::EtaDefinition();
105 G4EtaPrime::EtaPrimeDefinition();
106 G4KaonPlus::KaonPlusDefinition();
107 G4KaonMinus::KaonMinusDefinition();
108 G4KaonZero::KaonZeroDefinition();
109 G4AntiKaonZero::AntiKaonZeroDefinition();
110 G4KaonZeroLong::KaonZeroLongDefinition();
111 G4KaonZeroShort::KaonZeroShortDefinition();
112}

Referenced by ConstructParticle().

◆ ConstructParticle()

void ExN03PhysicsList::ConstructParticle ( )
protected

Definition at line 56 of file ExN03PhysicsList.cxx.

56 {
57 // In this method, static member functions should be called
58 // for all particles which you want to use.
59 // This ensures that objects of these particle types will be
60 // created in the program.
61
66}

◆ ConstructProcess()

void ExN03PhysicsList::ConstructProcess ( )
protected

Definition at line 126 of file ExN03PhysicsList.cxx.

126 {
127 AddTransportation();
128 ConstructEM();
130}

◆ SetCuts()

void ExN03PhysicsList::SetCuts ( )
protected

Definition at line 285 of file ExN03PhysicsList.cxx.

285 {
286 if ( verboseLevel > 0 )
287 {
288 G4cout << "ExN03PhysicsList::SetCuts:";
289 G4cout << "CutLength : " << G4BestUnit( defaultCutValue, "Length" ) << G4endl;
290 }
291
292 // set cut values for gamma at first and for e- second and next for e+,
293 // because some processes for e+/e- need cut values for gamma
294 //
295 SetCutValue( defaultCutValue, "gamma" );
296 SetCutValue( defaultCutValue, "e-" );
297 SetCutValue( defaultCutValue, "e+" );
298
299 if ( verboseLevel > 0 ) DumpCutValuesTable();
300}

The documentation for this class was generated from the following files: