64 typedef std::vector<G4InuclElementaryParticle>
hadronList;
71 : verboseLevel(verbose), thisFinalState(0), thisHadrons(0),
83 G4cout <<
" >>> G4CascadeCoalescence::FindClusters()" <<
G4endl;
102 G4cout <<
" >>> G4CascadeCoalescence::selectCandidates()" <<
G4endl;
109 for (
size_t idx1=0; idx1<nHad; idx1++) {
111 for (
size_t idx2=idx1+1; idx2<nHad; idx2++) {
113 for (
size_t idx3=idx2+1; idx3<nHad; idx3++) {
115 for (
size_t idx4=idx3+1; idx4<nHad; idx4++) {
136 size_t idx3,
size_t idx4) {
141 G4cout <<
" >>> G4CascadeCoalescence::tryClusters " << idx1 <<
" " << idx2
142 <<
" " << idx3 <<
" " << idx4 <<
G4endl;
170 G4cout <<
" >>> G4CascadeCoalescence::tryClusters " << idx1 <<
" " << idx2
199 G4cout <<
" >>> G4CascadeCoalescence::tryClusters " << idx1 <<
" " << idx2
217 G4cout <<
" >>> G4CascadeCoalescence::createNuclei()" <<
G4endl;
237 G4cout <<
" >>> G4CascadeCoalescence::removeNucleons()" <<
G4endl;
240 std::set<size_t>::reverse_iterator usedIter;
253 for (
size_t i=0; i<aCluster.size(); i++)
268 for (
size_t i=0; i<aCluster.size(); i++) {
272 if ((dp = nucl.
getMomentum().boost(-boost).rho()) > maxDP) maxDP = dp;
286 for (
size_t i=0; i<aCluster.size(); i++) {
299 for (
size_t i=0; i<aCluster.size(); i++) {
300 hash = hash*1000 + aCluster[i];
337 for (
size_t i=0; i<clus.size(); i++)
350 if (clus.size() == 2)
353 if (clus.size() == 3)
357 if (clus.size() == 4)
372 if (aCluster.size()<2)
return false;
374 G4int A = aCluster.size();
378 if (A==2 && type==3) Z = 1;
379 if (A==3 && type==5) Z = 1;
380 if (A==3 && type==4) Z = 2;
381 if (A==4 && type==6) Z = 2;
383 if (Z < 0)
return false;
398 G4cout <<
" >>> G4CascadeCoalescence::" << name <<
" ";
399 std::copy(aCluster.begin(), aCluster.end(),
400 std::ostream_iterator<size_t>(
G4cout,
" "));
404 for (
size_t i=0; i<aCluster.size(); i++)
void fill(G4int a, G4int z, G4double exc=0., Model model=DefaultModel)
const G4double dpMaxTriplet
CLHEP::Hep3Vector G4ThreeVector
bool allNucleons(const ClusterCandidate &clus) const
G4LorentzVector getMomentum() const
size_t clusterHash(const ClusterCandidate &clus) const
std::vector< size_t > ClusterCandidate
void printCollisionOutput(std::ostream &os=G4cout) const
std::set< size_t > triedClusters
std::vector< G4InuclElementaryParticle > hadronList
G4double maxDeltaP(const ClusterCandidate &aCluster) const
const char * name(G4int ptype)
bool makeLightIon(const ClusterCandidate &aCluster)
std::set< size_t > usedNucleons
void reportArgs(const G4String &name, const ClusterCandidate &clus) const
bool goodCluster(const ClusterCandidate &clus) const
std::vector< ClusterCandidate > allClusters
const std::vector< G4InuclElementaryParticle > * thisHadrons
G4CollisionOutput * thisFinalState
const G4InuclElementaryParticle & getHadron(size_t idx) const
G4GLOB_DLL std::ostream G4cout
double A(double temperature)
G4bool nucleon(G4int ityp)
bool nucleonUsed(size_t idx) const
G4int clusterType(const ClusterCandidate &aCluster) const
G4InuclNuclei thisLightIon
void reportResult(const G4String &name, const G4InuclNuclei &nucl) const
bool clusterTried(const ClusterCandidate &clus) const
void removeOutgoingParticle(G4int index)
const G4double dpMaxAlpha
static unsigned long FASTCALL hash(XML_Parser parser, KEY s)
G4CascadeCoalescence(G4int verbose=0)
hadronList::const_iterator hadronIter
void tryClusters(size_t idx1, size_t idx2)
const std::vector< G4InuclElementaryParticle > & getOutgoingParticles() const
ClusterCandidate thisCluster
void addOutgoingNucleus(const G4InuclNuclei &nuclei)
void FindClusters(G4CollisionOutput &finalState)
const G4double dpMaxDoublet
virtual ~G4CascadeCoalescence()
G4LorentzVector getClusterMomentum(const ClusterCandidate &aCluster) const
CLHEP::HepLorentzVector G4LorentzVector
void fillCluster(size_t idx1, size_t idx2)