64 aResult = & theResult;
77 G4int targetPDGCode = 90000000 + 1000*targetZ + (targetA-targetZ);
87 G4double fractionOfSingleQuasiFreeNucleons = 0.4;
88 G4double fractionOfPairedQuasiFreeNucleons = 0.0;
89 if(targetA>27) fractionOfPairedQuasiFreeNucleons = 0.04;
92 G4double halfTheStrangenessOfSee = 0.1;
99 fractionOfPairedQuasiFreeNucleons,
100 clusteringCoefficient);
102 halfTheStrangenessOfSee,
112 projHV.push_back(iH);
125 while ( retry && retryes < maxretries )
137 G4cerr <<
"***WARNING*** Exception thrown passing through G4ChiralInvariantPhaseSpace "<<
G4endl;
139 G4cerr <<
" Dumping the information in the pojectile list"<<
G4endl;
140 for(
size_t i=0; i< projHV.size(); i++)
142 G4cerr <<
" Incoming 4-momentum and PDG code of "<<i<<
"'th hadron: "
143 <<
" "<< projHV[i]->Get4Momentum()<<
" "<<projHV[i]->GetPDGCode()<<
G4endl;
150 if ( retryes >= maxretries )
152 G4cerr <<
"***ERROR*** Maximum number of retries ("<<maxretries<<
") reached for G4QEnvironment::Fragment(), exception is being thrown" <<
G4endl;
153 throw G4HadronicException(__FILE__,__LINE__,
"G4ChiralInvariantPhaseSpace::ApplyYourself(...) - Maximum number of re-tries reached, abandon interaction");
159 G4cout <<
"G4ChiralInvariantPhaseSpace: NEW EVENT #ofHadrons="
164 unsigned int particle;
165 for( particle = 0; particle < output->size(); particle++)
167 if(output->operator[](particle)->GetNFragments() != 0)
169 delete output->operator[](particle);
173 G4int pdgCode = output->operator[](particle)->GetPDGCode();
175 G4cout <<
"G4ChiralInvariantPhaseSpace: h#"<<particle
176 <<
", PDG="<<pdgCode<<
G4endl;
186 G4int aZ = (pdgCode-90000000)/1000;
187 G4int anN = pdgCode-90000000-1000*aZ;
192 else if ( pdgCode == 90000000 && output->operator[](particle)->Get4Momentum().m()<1*MeV )
204 ->
FindParticle(output->operator[](particle)->GetPDGCode());
210 if ( theDefinition == NULL )
214 G4cerr<<
"**WARNING*** G4ChiralInvariantPhaseSpace::ApplyYourself(...) : G4QEnvironment::Fragment() returns an invalid fragment\n with fourMom(MeV)=";
215 G4cerr<<output->operator[](particle)->Get4Momentum()<<
" and mass(MeV)="<<output->operator[](particle)->Get4Momentum().m();
216 G4cerr<<
". Offending PDG is:"<<pdgCode<<
" abandon interaction. \n Taget PDG was:"<<targetPDGCode<<
" \n Dumping the information in the projectile list:\n";
217 for(
size_t i=0; i< projHV.size(); i++)
219 G4cerr <<
" Incoming 4-momentum and PDG code of "<<i<<
"'th hadron: "
220 <<
" "<< projHV[i]->Get4Momentum()<<
" "<<projHV[i]->GetPDGCode()<<
"\n";
222 G4cerr<<
"\n Please report as bug \n***END OF MESSAGE***"<<
G4endl;
224 for (
unsigned int cparticle=0 ; cparticle<output->size();++cparticle)
225 delete output->operator[](cparticle);
227 std::for_each(projHV.begin(), projHV.end(),
DeleteQHadron());
240 theSec->
SetMomentum(output->operator[](particle)->Get4Momentum().vect());
242 delete output->operator[](particle);
245 std::for_each(projHV.begin(), projHV.end(),
DeleteQHadron());
std::vector< G4QHadron * > G4QHadronVector
G4DLLIMPORT std::ostream G4cerr
G4DLLIMPORT std::ostream G4cout
G4HadFinalState * ApplyYourself(const G4HadProjectile &aTrack, G4Nucleus &aTargetNucleus, G4HadFinalState *aChange=0)
G4ChiralInvariantPhaseSpace()
~G4ChiralInvariantPhaseSpace()
void SetDefinition(const G4ParticleDefinition *aParticleDefinition)
void SetMomentum(const G4ThreeVector &momentum)
void SetStatusChange(G4HadFinalStateStatus aS)
void AddSecondary(G4DynamicParticle *aP)
void SetEnergyChange(G4double anEnergy)
void SetMomentumChange(const G4ThreeVector &aV)
const G4ParticleDefinition * GetDefinition() const
G4double GetKineticEnergy() const
const G4LorentzVector & Get4Momentum() const
G4double GetIonMass(G4int Z, G4int A, G4int L=0) const
!! Only ground states are supported now
static G4Neutron * Neutron()
G4int GetPDGEncoding() const
G4ParticleDefinition * FindIon(G4int atomicNumber, G4int atomicMass, G4double excitationEnergy)
G4ParticleDefinition * FindParticle(G4int PDGEncoding)
static G4ParticleTable * GetParticleTable()
G4IonTable * GetIonTable()
static G4QCHIPSWorld * Get()
G4QParticleVector * GetParticles(G4int nOfParts=0)
G4QHadronVector * Fragment()
static void SetParameters(G4double fN=.1, G4double fD=.05, G4double cP=4., G4double mR=1., G4double nD=.8 *CLHEP::fermi)
static void SetParameters(G4double temper=180., G4double ssin2g=.3, G4double etaetap=.3)