43 :theProjectile(projectile)
82 G4int numberOfIsos(0);
86 if(numberOfIsos!=0)
break;
90 for(i=0;i<numberOfIsos; i++)
92 if(i!=0) running[i] = running[i-1];
105 G4int isotope=nChannels-1;
107 for(i=0;i<numberOfIsos; i++)
111 if(running[numberOfIsos-1] != 0)
if(random<running[i]/running[numberOfIsos-1])
break;
122 if(i!=0) running[i] = running[i-1];
139 if ( running[nChannels-1] == 0 )
142 if ( targA == -1 && targZ == -1 ) {
143 throw G4HadronicException(__FILE__, __LINE__,
"ParticleHP model encounter lethal discrepancy with cross section data");
147 G4cout <<
"Warning from NeutronHP: could not find proper reaction channel. This may cause by inconsistency between cross section and model. Unchanged final states are returned." <<
G4endl;
170 if(running[nChannels-1] != 0)
if(random<running[i]/running[nChannels-1])
break;
174 if( getenv(
"G4ParticleHPDebug") )
G4cout <<
" G4ParticleHPChannelList SELECTED ISOTOPE " << isotope <<
" SELECTED CHANNEL " << lChan <<
G4endl;
225 G4cout<<
"================================================================"<<
G4endl;
232 G4cout<<
"----------------------------------------------------------------"<<
G4endl;
234 G4cout<<
"----------------------------------------------------------------"<<
G4endl;
237 G4cout<<
"================================================================"<<
G4endl;
G4HadFinalState unChanged
static G4ParticleHPManager * GetInstance()
void Init(G4Element *theElement, const G4String dirName)
void Register(G4ParticleHPFinalState *theFS, const G4String &aName)
CLHEP::Hep3Vector G4ThreeVector
static G4IonTable * GetIonTable()
const G4String & GetName() const
void SetMomentumChange(const G4ThreeVector &aV)
G4double GetThermalEnergy(const G4HadProjectile &aP, const G4Element *anE, G4double aT)
const G4String & GetParticleName() const
void AddSecondary(G4DynamicParticle *aP, G4int mod=-1)
G4double GetWeightedXsec(G4double energy, G4int isoNumber)
void SetEnergyChange(G4double anEnergy)
const G4Material * GetMaterial() const
G4double GetFSCrossSection(G4double energy, G4int isoNumber)
G4ParticleHPReactionWhiteBoard * GetReactionWhiteBoard()
G4ParticleHPChannelList()
G4bool HasDataInAnyFinalState()
~G4ParticleHPChannelList()
const G4LorentzVector & Get4Momentum() const
G4HadFinalState * ApplyYourself(const G4Element *theElement, const G4HadProjectile &aTrack)
G4double GetKineticEnergy() const
static G4ThreadLocal G4int trycounter
G4ParticleDefinition * theProjectile
static G4Neutron * Neutron()
G4bool Register(G4ParticleHPFinalState *theFS)
G4GLOB_DLL std::ostream G4cout
G4ParticleHPChannel ** theChannels
G4ParticleDefinition * GetIon(G4int Z, G4int A, G4int lvl=0)
G4bool allChannelsCreated
G4double GetTemperature() const
G4HadFinalState * ApplyYourself(const G4HadProjectile &theTrack, G4int isoNumber=-1)