39 for (
G4int i=0; i<nTurn; ++i)
41 G4cerr << stacks[i]->GetNTrack() <<
" ";
42 G4cerr << stacks[i]->getTotalEnergy() <<
" ";
49 for(
G4int i=0; i<nTurn; ++i)
58 for (
auto* sp : stacks)
66 for (
auto* sp : stacks)
68 sp->TransferTo(aStack);
83 aStackedTrack = stacks[fTurn]->PopFromStack();
89 fTurn = (fTurn+1) % nTurn;
122 stacks[iDest]->PushToStack(aStackedTrack);
126 G4long dy1 = stacks[iDest]->GetNTrack() - stacks[iDest]->GetSafetyValue1();
127 G4long dy2 = stacks[fTurn]->GetNTrack() - stacks[fTurn]->GetSafetyValue2();
129 if (dy1 > 0 || dy1 > dy2 ||
131 stacks[iDest]->
GetNTrack() < 50 && energies[iDest] < energies[fTurn]))
136 if (nTracks > maxNTracks) maxNTracks = nTracks;
141 for (
G4int i = 0; i < nTurn; ++i)
152 for (
G4int i = 0; i < nTurn; ++i)
154 stacks[i]->clearAndDestroy();
G4GLOB_DLL std::ostream G4cerr
G4double GetTotalEnergy() const
void TransferTo(G4TrackStack *aStack)
void PushToStack(const G4StackedTrack &aStackedTrack)
G4StackedTrack PopFromStack()
G4Track * GetTrack() const
const G4DynamicParticle * GetDynamicParticle() const
G4int GetParentID() const