Geant4 9.6.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4QPDGToG4Particle Class Reference

#include <G4QPDGToG4Particle.hh>

Public Member Functions

 ~G4QPDGToG4Particle ()
 
G4ParticleDefinitionGetParticleDefinition (G4int PDGCode)
 
void DefineAllParticles ()
 

Static Public Member Functions

static G4QPDGToG4ParticleGet ()
 

Protected Member Functions

 G4QPDGToG4Particle ()
 

Detailed Description

Definition at line 48 of file G4QPDGToG4Particle.hh.

Constructor & Destructor Documentation

◆ G4QPDGToG4Particle()

G4QPDGToG4Particle::G4QPDGToG4Particle ( )
protected

Definition at line 47 of file G4QPDGToG4Particle.cc.

48{
49 G4HadronicDeprecate("G4QPDGToG4Particle");
50}
#define G4HadronicDeprecate(name)

◆ ~G4QPDGToG4Particle()

G4QPDGToG4Particle::~G4QPDGToG4Particle ( )

Definition at line 52 of file G4QPDGToG4Particle.cc.

53{
54}

Member Function Documentation

◆ DefineAllParticles()

void G4QPDGToG4Particle::DefineAllParticles ( )

Definition at line 360 of file G4QPDGToG4Particle.cc.

361{
362 //=---------= LEPTONS =---------------=
376 //=--------------= MESONS =---------------=
401 // =---------= BARYONS =-----------=
434}
static G4AntiBMesonZero * AntiBMesonZeroDefinition()
static G4AntiBsMesonZero * AntiBsMesonZeroDefinition()
static G4AntiDMesonZero * AntiDMesonZeroDefinition()
static G4AntiKaonZero * AntiKaonZeroDefinition()
static G4AntiLambda * AntiLambdaDefinition()
static G4AntiLambdacPlus * AntiLambdacPlusDefinition()
static G4AntiNeutrinoE * AntiNeutrinoEDefinition()
static G4AntiNeutrinoMu * AntiNeutrinoMuDefinition()
static G4AntiNeutrinoTau * AntiNeutrinoTauDefinition()
static G4AntiNeutron * AntiNeutronDefinition()
static G4AntiOmegaMinus * AntiOmegaMinusDefinition()
static G4AntiOmegacZero * AntiOmegacZeroDefinition()
static G4AntiProton * AntiProtonDefinition()
Definition: G4AntiProton.cc:88
static G4AntiSigmaMinus * AntiSigmaMinusDefinition()
static G4AntiSigmaPlus * AntiSigmaPlusDefinition()
static G4AntiSigmaZero * AntiSigmaZeroDefinition()
static G4AntiSigmacPlusPlus * AntiSigmacPlusPlusDefinition()
static G4AntiSigmacPlus * AntiSigmacPlusDefinition()
static G4AntiSigmacZero * AntiSigmacZeroDefinition()
static G4AntiXiMinus * AntiXiMinusDefinition()
static G4AntiXiZero * AntiXiZeroDefinition()
static G4AntiXicPlus * AntiXicPlusDefinition()
static G4AntiXicZero * AntiXicZeroDefinition()
static G4BMesonMinus * BMesonMinusDefinition()
static G4BMesonPlus * BMesonPlusDefinition()
Definition: G4BMesonPlus.cc:79
static G4BMesonZero * BMesonZeroDefinition()
Definition: G4BMesonZero.cc:79
static G4BsMesonZero * BsMesonZeroDefinition()
static G4DMesonMinus * DMesonMinusDefinition()
static G4DMesonPlus * DMesonPlusDefinition()
Definition: G4DMesonPlus.cc:80
static G4DMesonZero * DMesonZeroDefinition()
Definition: G4DMesonZero.cc:79
static G4DsMesonMinus * DsMesonMinusDefinition()
static G4DsMesonPlus * DsMesonPlusDefinition()
static G4Electron * ElectronDefinition()
Definition: G4Electron.cc:89
static G4EtaPrime * EtaPrimeDefinition()
Definition: G4EtaPrime.cc:100
static G4Eta * EtaDefinition()
Definition: G4Eta.cc:104
static G4Gamma * GammaDefinition()
Definition: G4Gamma.cc:81
static G4JPsi * JPsiDefinition()
Definition: G4JPsi.cc:79
static G4KaonMinus * KaonMinusDefinition()
Definition: G4KaonMinus.cc:108
static G4KaonPlus * KaonPlusDefinition()
Definition: G4KaonPlus.cc:108
static G4KaonZeroLong * KaonZeroLongDefinition()
static G4KaonZeroShort * KaonZeroShortDefinition()
static G4KaonZero * KaonZeroDefinition()
Definition: G4KaonZero.cc:99
static G4Lambda * LambdaDefinition()
Definition: G4Lambda.cc:103
static G4LambdacPlus * LambdacPlusDefinition()
static G4MuonMinus * MuonMinusDefinition()
Definition: G4MuonMinus.cc:95
static G4MuonPlus * MuonPlusDefinition()
Definition: G4MuonPlus.cc:94
static G4NeutrinoE * NeutrinoEDefinition()
Definition: G4NeutrinoE.cc:80
static G4NeutrinoMu * NeutrinoMuDefinition()
Definition: G4NeutrinoMu.cc:80
static G4NeutrinoTau * NeutrinoTauDefinition()
static G4Neutron * NeutronDefinition()
Definition: G4Neutron.cc:99
static G4OmegaMinus * OmegaMinusDefinition()
static G4OmegacZero * OmegacZeroDefinition()
Definition: G4OmegacZero.cc:83
static G4PionMinus * PionMinusDefinition()
Definition: G4PionMinus.cc:93
static G4PionPlus * PionPlusDefinition()
Definition: G4PionPlus.cc:93
static G4PionZero * PionZeroDefinition()
Definition: G4PionZero.cc:99
static G4Positron * PositronDefinition()
Definition: G4Positron.cc:89
static G4Proton * ProtonDefinition()
Definition: G4Proton.cc:88
static G4SigmaMinus * SigmaMinusDefinition()
static G4SigmaPlus * SigmaPlusDefinition()
Definition: G4SigmaPlus.cc:103
static G4SigmaZero * SigmaZeroDefinition()
Definition: G4SigmaZero.cc:94
static G4SigmacPlusPlus * SigmacPlusPlusDefinition()
static G4SigmacPlus * SigmacPlusDefinition()
Definition: G4SigmacPlus.cc:95
static G4SigmacZero * SigmacZeroDefinition()
Definition: G4SigmacZero.cc:95
static G4TauMinus * TauMinusDefinition()
Definition: G4TauMinus.cc:130
static G4TauPlus * TauPlusDefinition()
Definition: G4TauPlus.cc:129
static G4XiMinus * XiMinusDefinition()
Definition: G4XiMinus.cc:101
static G4XiZero * XiZeroDefinition()
Definition: G4XiZero.cc:101
static G4XicPlus * XicPlusDefinition()
Definition: G4XicPlus.cc:83
static G4XicZero * XicZeroDefinition()
Definition: G4XicZero.cc:83

◆ Get()

G4QPDGToG4Particle * G4QPDGToG4Particle::Get ( )
static

Definition at line 57 of file G4QPDGToG4Particle.cc.

58{
59 static G4QPDGToG4Particle theMap; // *** Static body of the G4QPDGToG4Particle ***
60 return &theMap;
61}

Referenced by G4QCaptureAtRest::AtRestDoIt(), G4QAtomicElectronScattering::PostStepDoIt(), and G4QInelastic::PostStepDoIt().

◆ GetParticleDefinition()

G4ParticleDefinition * G4QPDGToG4Particle::GetParticleDefinition ( G4int  PDGCode)

Definition at line 63 of file G4QPDGToG4Particle.cc.

64{
65 if(!PDG) return 0;
66 else if(PDG>0) // Positive PDG Code
67 {
68 if(PDG<100)
69 {
70 if(PDG==22) return G4Gamma::Gamma();
71 else if(PDG>10 && PDG<17)
72 {
73 if(PDG<13)
74 {
75 if(PDG==11) return G4Electron::Electron();
76 else return G4NeutrinoE::NeutrinoE();
77 }
78 else
79 {
80 if(PDG<15)
81 {
82 if(PDG==13) return G4MuonMinus::MuonMinus();
83 else return G4NeutrinoMu::NeutrinoMu();
84 }
85 else
86 {
87 if(PDG==15) return G4TauMinus::TauMinus();
88 else return G4NeutrinoTau::NeutrinoTau();
89 }
90 }
91 }
92 else return 0; // @@ Warning can be added
93 } // End of the Lepton definition
94 else if(PDG<1000)
95 {
96 if(PDG<420)
97 {
98 if(PDG<320)
99 {
100 if(PDG==211) return G4PionPlus::PionPlus();
101 else if(PDG==111) return G4PionZero::PionZero();
102 else if(PDG==130) return G4KaonZeroLong::KaonZeroLong();
103 else if(PDG==221) return G4Eta::Eta();
104 else if(PDG==311) return G4KaonZero::KaonZero();
105 else return 0; // @@ Warning can be added
106 }
107 else
108 {
109 if(PDG==321) return G4KaonPlus::KaonPlus();
110 else if(PDG==331) return G4EtaPrime::EtaPrime();
111 else if(PDG==310) return G4KaonZeroShort::KaonZeroShort();
112 else if(PDG==411) return G4DMesonPlus::DMesonPlus();
113 else return 0; // @@ Warning can be added
114 }
115 }
116 else
117 {
118 if(PDG<500)
119 {
120 if(PDG==421) return G4DMesonZero::DMesonZero();
121 else if(PDG==431) return G4DsMesonPlus::DsMesonPlus();
122 else if(PDG==443) return G4JPsi::JPsi();
123 else return 0; // @@ Warning can be added
124 }
125 else
126 {
127 if(PDG==521) return G4BMesonPlus::BMesonPlus();
128 else if(PDG==511) return G4BMesonZero::BMesonZero();
129 else if(PDG==531) return G4BsMesonZero::BsMesonZero();
130 else return 0; // @@ Warning can be added
131 }
132 }
133 } // Emd of the Meson definition
134 else
135 {
136 if(PDG<3333)
137 {
138 if(PDG<3211)
139 {
140 if(PDG<3111)
141 {
142 if(PDG==2112) return G4Neutron::Neutron();
143 else if(PDG==2212) return G4Proton::Proton();
144 else return 0; // @@ Warning can be added
145 }
146 else
147 {
148 if(PDG==3112) return G4SigmaMinus::SigmaMinus();
149 else if(PDG==3122) return G4Lambda::Lambda();
150 else return 0; // @@ Warning can be added
151 }
152 }
153 else
154 {
155 if(PDG<3311)
156 {
157 if(PDG==3222) return G4SigmaPlus::SigmaPlus();
158 else if(PDG==3212) return G4SigmaZero::SigmaZero();
159 else return 0; // @@ Warning can be added
160 }
161 else
162 {
163 if(PDG==3312) return G4XiMinus::XiMinus();
164 else if(PDG==3322) return G4XiZero::XiZero();
165 else return 0; // @@ Warning can be added
166 }
167 }
168 }
169 else
170 {
171 if(PDG<4221)
172 {
173 if(PDG<4121)
174 {
175 if(PDG==3334) return G4OmegaMinus::OmegaMinus();
176 else if(PDG==4112) return G4SigmacZero::SigmacZero();
177 else return 0; // @@ Warning can be added
178 }
179 else
180 {
181 if(PDG==4122) return G4LambdacPlus::LambdacPlus();
182 else if(PDG==4212) return G4SigmacPlus::SigmacPlus();
183 else return 0; // @@ Warning can be added
184 }
185 }
186 else
187 {
188 if(PDG<4231)
189 {
190 if(PDG==4222) return G4SigmacPlusPlus::SigmacPlusPlus();
191 else if(PDG==4232) return G4XicPlus::XicPlus();
192 else return 0; // @@ Warning can be added
193 }
194 else
195 {
196 if(PDG==4132) return G4XicZero::XicZero();
197 else if(PDG==4332) return G4OmegacZero::OmegacZero();
198 else return 0; // @@ Warning can be added
199 }
200 }
201 }
202 } // End of Baryon definition
203 }
204 else // Negative PDG Code
205 {
206 G4int aPDG=-PDG;
207#ifdef pdebug
208 G4cout<<"G4QPDGToG4Particle:Antiparticle PDG="<<PDG<<G4endl;
209#endif
210 if(aPDG<100)
211 {
212 if(aPDG>10 && aPDG<17)
213 {
214 if(aPDG<13)
215 {
216 if(aPDG==11) return G4Positron::Positron();
217 else return G4AntiNeutrinoE::AntiNeutrinoE();
218 }
219 else
220 {
221 if(aPDG<15)
222 {
223 if(aPDG==13) return G4MuonPlus::MuonPlus();
225 }
226 else
227 {
228 if(aPDG==15) return G4TauPlus::TauPlus();
230 }
231 }
232 }
233 else return 0; // @@ Warning can be added
234 } // End of the Anti-Lepton definition
235 else if(aPDG<1000)
236 {
237#ifdef pdebug
238 G4cout<<"G4QPDGToG4Particle:AntiMesons aPDG="<<aPDG<<G4endl;
239#endif
240 if(aPDG<420)
241 {
242#ifdef pdebug
243 G4cout<<"G4QPDGToG4Particle:AntiSU(3)Mesons aPDG="<<aPDG<<G4endl;
244#endif
245 if(aPDG<320)
246 {
247#ifdef pdebug
248 G4cout<<"G4QPDGToG4Particle:AntiPi&KMesons aPDG="<<aPDG<<G4endl;
249#endif
250 if(aPDG==211) return G4PionMinus::PionMinus();
251 else if(aPDG==311) return G4AntiKaonZero::AntiKaonZero();
252 else return 0; // @@ Warning can be added
253 }
254 else
255 {
256#ifdef pdebug
257 G4cout<<"G4QPDGToG4Particle:AntiK&DMesons aPDG="<<aPDG<<G4endl;
258#endif
259 if(aPDG==321)
260 {
261#ifdef pdebug
262 G4cout<<"G4QPDGToG4Particle:KaonMinus aPDG="<<aPDG<<G4endl;
263#endif
264 return G4KaonMinus::KaonMinus();
265 }
266 else if(aPDG==411) return G4DMesonMinus::DMesonMinus();
267 else return 0; // @@ Warning can be added
268 }
269 }
270 else
271 {
272 if(aPDG<500)
273 {
274 if(aPDG==421) return G4AntiDMesonZero::AntiDMesonZero();
275 else if(aPDG==431) return G4DsMesonMinus::DsMesonMinus();
276 else return 0; // @@ Warning can be added
277 }
278 else
279 {
280 if(aPDG==521) return G4BMesonMinus::BMesonMinus();
281 else if(aPDG==511) return G4AntiBMesonZero::AntiBMesonZero();
282 else if(aPDG==531) return G4AntiBsMesonZero::AntiBsMesonZero();
283 else return 0; // @@ Warning can be added
284 }
285 }
286 } // Emd of the Anti-Meson definition
287 else
288 {
289 if(aPDG<3333)
290 {
291 if(aPDG<3211)
292 {
293 if(aPDG<3111)
294 {
295 if(aPDG==2112) return G4AntiNeutron::AntiNeutron();
296 else if(aPDG==2212) return G4AntiProton::AntiProton();
297 else return 0; // @@ Warning can be added
298 }
299 else
300 {
301 if(aPDG==3112) return G4AntiSigmaMinus::AntiSigmaMinus();
302 else if(aPDG==3122) return G4AntiLambda::AntiLambda();
303 else return 0; // @@ Warning can be added
304 }
305 }
306 else
307 {
308 if(aPDG<3311)
309 {
310 if(aPDG==3222) return G4AntiSigmaPlus::AntiSigmaPlus();
311 else if(aPDG==3212) return G4AntiSigmaZero::AntiSigmaZero();
312 else return 0; // @@ Warning can be added
313 }
314 else
315 {
316 if(aPDG==3312) return G4AntiXiMinus::AntiXiMinus();
317 else if(aPDG==3322) return G4AntiXiZero::AntiXiZero();
318 else return 0; // @@ Warning can be added
319 }
320 }
321 }
322 else
323 {
324 if(aPDG<4221)
325 {
326 if(aPDG<4121)
327 {
328 if(aPDG==3334) return G4AntiOmegaMinus::AntiOmegaMinus();
329 else if(aPDG==4112) return G4AntiSigmacZero::AntiSigmacZero();
330 else return 0; // @@ Warning can be added
331 }
332 else
333 {
334 if(aPDG==4122) return G4AntiLambdacPlus::AntiLambdacPlus();
335 else if(aPDG==4212) return G4AntiSigmacPlus::AntiSigmacPlus();
336 else return 0; // @@ Warning can be added
337 }
338 }
339 else
340 {
341 if(aPDG<4231)
342 {
343 if(aPDG==4222) return G4AntiSigmacPlusPlus::AntiSigmacPlusPlus();
344 else if(aPDG==4232) return G4AntiXicPlus::AntiXicPlus();
345 else return 0; // @@ Warning can be added
346 }
347 else
348 {
349 if(aPDG==4132) return G4AntiXicZero::AntiXicZero();
350 else if(aPDG==4332) return G4AntiOmegacZero::AntiOmegacZero();
351 else return 0; // @@ Warning can be added
352 }
353 }
354 }
355 } // End of Anti-Baryon definition
356 } // End of Anti-particle definition
357 return 0;
358}
int G4int
Definition: G4Types.hh:66
#define G4endl
Definition: G4ios.hh:52
G4DLLIMPORT std::ostream G4cout
static G4AntiBMesonZero * AntiBMesonZero()
static G4AntiBsMesonZero * AntiBsMesonZero()
static G4AntiDMesonZero * AntiDMesonZero()
static G4AntiKaonZero * AntiKaonZero()
static G4AntiLambda * AntiLambda()
static G4AntiLambdacPlus * AntiLambdacPlus()
static G4AntiNeutrinoE * AntiNeutrinoE()
static G4AntiNeutrinoMu * AntiNeutrinoMu()
static G4AntiNeutrinoTau * AntiNeutrinoTau()
static G4AntiNeutron * AntiNeutron()
static G4AntiOmegaMinus * AntiOmegaMinus()
static G4AntiOmegacZero * AntiOmegacZero()
static G4AntiProton * AntiProton()
Definition: G4AntiProton.cc:93
static G4AntiSigmaMinus * AntiSigmaMinus()
static G4AntiSigmaPlus * AntiSigmaPlus()
static G4AntiSigmaZero * AntiSigmaZero()
static G4AntiSigmacPlusPlus * AntiSigmacPlusPlus()
static G4AntiSigmacPlus * AntiSigmacPlus()
static G4AntiSigmacZero * AntiSigmacZero()
static G4AntiXiMinus * AntiXiMinus()
static G4AntiXiZero * AntiXiZero()
static G4AntiXicPlus * AntiXicPlus()
static G4AntiXicZero * AntiXicZero()
static G4BMesonMinus * BMesonMinus()
static G4BMesonPlus * BMesonPlus()
Definition: G4BMesonPlus.cc:84
static G4BMesonZero * BMesonZero()
Definition: G4BMesonZero.cc:84
static G4BsMesonZero * BsMesonZero()
static G4DMesonMinus * DMesonMinus()
static G4DMesonPlus * DMesonPlus()
Definition: G4DMesonPlus.cc:85
static G4DMesonZero * DMesonZero()
Definition: G4DMesonZero.cc:84
static G4DsMesonMinus * DsMesonMinus()
static G4DsMesonPlus * DsMesonPlus()
static G4Electron * Electron()
Definition: G4Electron.cc:94
static G4EtaPrime * EtaPrime()
Definition: G4EtaPrime.cc:105
static G4Eta * Eta()
Definition: G4Eta.cc:109
static G4Gamma * Gamma()
Definition: G4Gamma.cc:86
static G4JPsi * JPsi()
Definition: G4JPsi.cc:84
static G4KaonMinus * KaonMinus()
Definition: G4KaonMinus.cc:113
static G4KaonPlus * KaonPlus()
Definition: G4KaonPlus.cc:113
static G4KaonZeroLong * KaonZeroLong()
static G4KaonZeroShort * KaonZeroShort()
static G4KaonZero * KaonZero()
Definition: G4KaonZero.cc:104
static G4Lambda * Lambda()
Definition: G4Lambda.cc:108
static G4LambdacPlus * LambdacPlus()
static G4MuonMinus * MuonMinus()
Definition: G4MuonMinus.cc:100
static G4MuonPlus * MuonPlus()
Definition: G4MuonPlus.cc:99
static G4NeutrinoE * NeutrinoE()
Definition: G4NeutrinoE.cc:85
static G4NeutrinoMu * NeutrinoMu()
Definition: G4NeutrinoMu.cc:85
static G4NeutrinoTau * NeutrinoTau()
static G4Neutron * Neutron()
Definition: G4Neutron.cc:104
static G4OmegaMinus * OmegaMinus()
static G4OmegacZero * OmegacZero()
Definition: G4OmegacZero.cc:88
static G4PionMinus * PionMinus()
Definition: G4PionMinus.cc:98
static G4PionPlus * PionPlus()
Definition: G4PionPlus.cc:98
static G4PionZero * PionZero()
Definition: G4PionZero.cc:104
static G4Positron * Positron()
Definition: G4Positron.cc:94
static G4Proton * Proton()
Definition: G4Proton.cc:93
static G4SigmaMinus * SigmaMinus()
static G4SigmaPlus * SigmaPlus()
Definition: G4SigmaPlus.cc:108
static G4SigmaZero * SigmaZero()
Definition: G4SigmaZero.cc:99
static G4SigmacPlusPlus * SigmacPlusPlus()
static G4SigmacPlus * SigmacPlus()
static G4SigmacZero * SigmacZero()
static G4TauMinus * TauMinus()
Definition: G4TauMinus.cc:135
static G4TauPlus * TauPlus()
Definition: G4TauPlus.cc:134
static G4XiMinus * XiMinus()
Definition: G4XiMinus.cc:106
static G4XiZero * XiZero()
Definition: G4XiZero.cc:106
static G4XicPlus * XicPlus()
Definition: G4XicPlus.cc:88
static G4XicZero * XicZero()
Definition: G4XicZero.cc:88

Referenced by G4QCaptureAtRest::AtRestDoIt(), G4QAtomicElectronScattering::PostStepDoIt(), and G4QInelastic::PostStepDoIt().


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