44 std::vector<double> scalarMesonMix,
45 std::vector<double> vectorMesonMix)
60 return Barion(black,white,spin);
66 return Meson(black,white,spin);
104 if (std::abs(charge) > 2 || std::abs(3.*charge - 3*
G4int(charge*1.001)) >
perCent )
107 G4cerr <<
" Invalid total charge found for on input: "
109 G4cerr <<
" PGDcode input quark1/quark2 : " <<
119 if ( std::abs(id1) < std::abs(id2) )
126 if (std::abs(id1) > 3 )
127 throw G4HadronicException(__FILE__, __LINE__,
"G4HadronBuilder::Meson : Illegal Quark content as input");
131 if (id1 + id2 == 0) {
133 G4int imix = 2*std::abs(id1) - 1;
144 PDGEncoding = 100 * std::abs(id1) + 10 * std::abs(id2) + theSpin;
145 G4bool IsUp = (std::abs(id1)&1) == 0;
147 if( (IsUp && IsAnti ) || (!IsUp && !IsAnti ) )
148 PDGEncoding = - PDGEncoding;
155 if (MesonDef == 0 ) {
156 G4cerr <<
" G4HadronBuilder - Warning: No particle for PDGcode= "
160 G4cerr <<
" G4HadronBuilder - Warning: Incorrect Charge : "
181 if (std::abs(charge) > 2 || std::abs(3.*charge - 3*
G4int(charge*1.001)) >
perCent )
184 G4cerr <<
" Invalid total charge found for on input: "
186 G4cerr <<
" PGDcode input quark1/quark2 : " <<
194 if ( std::abs(id1) < std::abs(id2) )
201 if (std::abs(id1) < 1000 || std::abs(id2) > 3 )
202 throw G4HadronicException(__FILE__, __LINE__,
"G4HadronBuilder::Barion: Illegal quark content as input");
204 G4int ifl1= std::abs(id1)/1000;
205 G4int ifl2 = (std::abs(id1) - ifl1 * 1000)/100;
206 G4int diquarkSpin = std::abs(id1)%10;
214 G4int kfla = std::abs(ifl1);
215 G4int kflb = std::abs(ifl2);
216 G4int kflc = std::abs(ifl3);
223 G4int kfle = kfla + kflb + kflc - kfld - kflf;
226 theSpin = (kfla == kflb && kflb == kflc)?
SpinThreeHalf : theSpin;
229 if(theSpin ==
SpinHalf && kfld > kfle && kfle > kflf) {
234 if(diquarkSpin == 1 ) {
241 if(diquarkSpin == 3 && kfla != kfld)
247 PDGEncoding = 1000 * kfld + 100 * kflf + 10 * kfle + theSpin;
249 PDGEncoding = 1000 * kfld + 100 * kfle + 10 * kflf + theSpin;
252 PDGEncoding = -PDGEncoding;
258 if (BarionDef == 0 ) {
259 G4cerr <<
" G4HadronBuilder - Warning: No particle for PDGcode= "
263 G4cerr <<
" G4HadronBuilder - Warning: Incorrect Charge : "
264 <<
" DiQuark/Quark = "
G4ParticleDefinition * BuildHighSpin(G4ParticleDefinition *black, G4ParticleDefinition *white)
std::vector< double > scalarMesonMixings
G4ParticleDefinition * FindParticle(G4int PDGEncoding)
std::vector< double > vectorMesonMixings
G4ParticleDefinition * BuildLowSpin(G4ParticleDefinition *black, G4ParticleDefinition *white)
G4ParticleDefinition * Build(G4ParticleDefinition *black, G4ParticleDefinition *white)
G4ParticleDefinition * Barion(G4ParticleDefinition *black, G4ParticleDefinition *white, Spin spin)
G4int GetPDGEncoding() const
const G4String & GetParticleSubType() const
const G4String & GetParticleName() const
G4ParticleDefinition * Meson(G4ParticleDefinition *black, G4ParticleDefinition *white, Spin spin)
static const double perCent
static G4ParticleTable * GetParticleTable()
T max(const T t1, const T t2)
brief Return the largest of the two arguments
T min(const T t1, const T t2)
brief Return the smallest of the two arguments
G4double GetPDGCharge() const
G4GLOB_DLL std::ostream G4cerr