59 fDecayType(fgkDefaultDecayType),
60 fDecayProductsArray(0)
95 particleDefinition = particleTable->
FindParticle(pdgEncoding);
97 if ( particleDefinition == 0 && warn) {
99 <<
"G4Pythia6Decayer: GetParticleDefinition: " << std::endl
100 <<
"G4ParticleTable::FindParticle() for particle with PDG = "
102 <<
" failed." << std::endl;
105 return particleDefinition;
118 if ( ! particleDefinition )
return 0;
126 return dynamicParticle;
164 for (
G4int i=1; i<=5; i++ )
187 for (
G4int channel= ifirst; channel <= ilast; channel++) {
211 for (
G4int channel = ifirst; channel <= ilast; channel++) {
229 const G4int kNHadrons = 4;
231 G4int hadron[kNHadrons] = {411, 421, 431, 4112};
235 G4int iKstarbar0 = -313;
237 G4int iKMinus = -321;
239 G4int iPiMinus = -211;
241 G4int products[2] = {iKPlus, iPiMinus}, mult[2] = {1, 1};
248 G4int decayP1[kNHadrons][3] = {
249 {iKMinus, iPiPlus, iPiPlus},
250 {iKMinus, iPiPlus, 0 },
251 {iKPlus , iKstarbar0, 0 },
254 G4int decayP2[kNHadrons][3] = {
255 {iKstarbar0, iPiPlus, 0 },
257 {iPhi , iPiPlus, 0 },
262 for (
G4int ihadron = 0; ihadron < kNHadrons; ihadron++ ) {
268 for (channel = ifirst; channel <= ilast; channel++) {
269 if ((pythia6->
GetKFDP(channel,1) == decayP1[ihadron][0] &&
270 pythia6->
GetKFDP(channel,2) == decayP1[ihadron][1] &&
271 pythia6->
GetKFDP(channel,3) == decayP1[ihadron][2] &&
272 pythia6->
GetKFDP(channel,4) == 0) ||
273 (pythia6->
GetKFDP(channel,1) == decayP2[ihadron][0] &&
274 pythia6->
GetKFDP(channel,2) == decayP2[ihadron][1] &&
275 pythia6->
GetKFDP(channel,3) == decayP2[ihadron][2] &&
276 pythia6->
GetKFDP(channel,4) == 0)) {
293 G4int iLambda0 = 3122;
294 G4int iKMinus = -321;
301 for (
G4int channel = ifirst; channel <= ilast; channel++) {
302 if (pythia6->
GetKFDP(channel,1) == iLambda0 &&
303 pythia6->
GetKFDP(channel,2) == iKMinus &&
304 pythia6->
GetKFDP(channel,3) == 0)
327 switch ( decayType ) {
332 products[2] = 100443;
416 products[1] = 100443;
546 p[0] = momentum.
x() /
GeV;
547 p[1] = momentum.
y() /
GeV;
548 p[2] = momentum.
z() /
GeV;
560 Decay(pdgEncoding, p);
573 for (
G4int i=0; i<nofParticles; i++) {
580 if ( status>0 && status<11 &&
581 std::abs(pdg)!=12 && std::abs(pdg)!=14 && std::abs(pdg)!=16 ) {
586 G4cout <<
" " << i <<
"th particle PDG: " << pdg <<
" ";
593 if (dynamicParticle) {
596 G4cout <<
" G4 particle name: "
609 G4cout <<
"nofParticles for tracking: " << counter <<
G4endl;
612 return decayProducts;
G4ParticleDefinition * FindParticle(G4int PDGEncoding)
void ForceDecayType(EDecayType decayType)
G4int PushProducts(G4DynamicParticle *aParticle)
EDecayType fDecayType
selected decay type
CLHEP::Hep3Vector G4ThreeVector
G4ThreeVector GetParticlePosition(const Pythia6Particle *particle) const
static G4ParticleTable * GetParticleTable()
virtual ~G4Pythia6Decayer()
ParticleVector * fDecayProductsArray
array of decay products
void SetMDME(int i, int j, int m)
Structure for Pythia6 particle properties.
void Decay(G4int pdg, const CLHEP::HepLorentzVector &p)
const G4String & GetParticleName() const
static const EDecayType fgkDefaultDecayType
default decay type
G4DynamicParticle * CreateDynamicParticle(const Pythia6Particle *p) const
Definition of the Pythia6 class.
G4ParticleDefinition * GetDefinition() const
G4ThreeVector GetMomentum() const
G4ParticleDefinition * GetDefinition() const
G4ThreeVector GetParticleMomentum(const Pythia6Particle *particle) const
G4ParticleDefinition * GetParticleDefinition(const Pythia6Particle *p, G4bool warn=true) const
virtual G4DecayProducts * ImportDecayProducts(const G4Track &track)
G4GLOB_DLL std::ostream G4cerr
void SetMDCY(int i, int j, int m)
static Pythia6 * Instance()
G4int CountProducts(G4int channel, G4int particle)
void Py1ent(int line, int kf, double pe, double theta, double phi)
void ForceDecay(EDecayType decayType)
int GetMDCY(int i, int j)
G4int GetPDGEncoding() const
G4GLOB_DLL std::ostream G4cout
static constexpr double cm
std::vector< Pythia6Particle * > ParticleVector
void ForceParticleDecay(G4int particle, G4int product, G4int mult)
int GetKFDP(int i, int j)
G4int ImportParticles(ParticleVector *particles)
ParticleVector * ImportParticles()
G4double GetTotalEnergy() const
Definition of the G4Pythia6Decayer class.
static constexpr double GeV
const G4DynamicParticle * GetDynamicParticle() const
G4int fVerboseLevel
verbose level
void SetMSTJ(int i, int m)