38 typedef std::vector<G4SPPartonInfo *>::const_iterator iter;
40 for(i = thePartonInfo.begin(); i!=thePartonInfo.end(); i++)
42 if (std::abs((*i)->GetDiQuark()) == std::abs(diQuark))
44 running += (*i)->GetProbability();
45 if (running/sum >= random)
47 Quark = (*i)->GetQuark();
58 typedef std::vector<G4SPPartonInfo *>::const_iterator iter;
60 for(i = thePartonInfo.begin(); i!=thePartonInfo.end(); i++)
62 if (std::abs((*i)->GetDiQuark()) == std::abs(diQuark))
64 sum += (*i)->GetProbability();
73 typedef std::vector<G4SPPartonInfo *>::const_iterator iter;
77 for(i = thePartonInfo.begin(); i!=thePartonInfo.end(); i++)
82 for(i = thePartonInfo.begin(); i!=thePartonInfo.end(); i++)
85 if(random/total<running)
87 result = (*i)->GetQuark();
88 aDiQuark = (*i)->GetDiQuark();
97 typedef std::vector<G4SPPartonInfo *>::const_iterator iter;
101 for(i=thePartonInfo.begin() ; i!=thePartonInfo.end(); i++)
103 sum += (*i)->GetProbability();
108 quark = (*i)->GetDiQuark();
109 diQuark = (*i)->GetQuark();
111 quark = (*i)->GetQuark();
112 diQuark = (*i)->GetDiQuark();
121 typedef std::vector<G4SPPartonInfo *>::const_iterator iter;
124 for(i=thePartonInfo.begin() ; i!=thePartonInfo.end(); i++)
126 if (std::abs((*i)->GetQuark()) == std::abs(quark))
128 sum += (*i)->GetProbability();
133 for(i=thePartonInfo.begin() ; i!=thePartonInfo.end(); i++)
135 if (std::abs((*i)->GetQuark()) == std::abs(quark))
137 running += (*i)->GetProbability();
138 if (running/sum >= random)
140 diQuark = (*i)->GetDiQuark();
150 theDefinition = aProton;
158 theDefinition = aAntiProton;
166 theDefinition = aNeutron;
174 theDefinition = aAntiNeutron;
182 theDefinition = aLambda;
192 theDefinition = aAntiLambda;
202 theDefinition = aSigmaPlus;
210 theDefinition = aAntiSigmaPlus;
218 theDefinition = aSigmaZero;
228 theDefinition = aAntiSigmaZero;
238 theDefinition = aSigmaMinus;
246 theDefinition = aAntiSigmaMinus;
254 theDefinition = aXiMinus;
262 theDefinition = aAntiXiMinus;
270 theDefinition = aXiZero;
278 theDefinition = aAntiXiZero;
286 theDefinition = anOmegaMinus;
292 theDefinition = anAntiOmegaMinus;
299 theDefinition = aDefinition;
392 for(
unsigned int i=0;i<thePartonInfo.size(); i++)
delete thePartonInfo[i];
G4double G4ParticleHPJENDLHEData::G4double result
G4int MatchDiQuarkAndGetQuark(const G4SPBaryon &aBaryon, G4int &aDiQuark) const
void SampleQuarkAndDiquark(G4int &quark, G4int &diQuark) const
void FindDiquark(G4int quark, G4int &diQuark) const
G4int GetPDGEncoding() const
G4int FindQuark(G4int diQuark) const
G4double GetProbability(G4int diQuark) const
G4SPBaryon(G4Proton *aProton)
G4double total(Particle const *const p1, Particle const *const p2)
static G4ParticleTable * GetParticleTable()