44 fCurrentTrack ( nullptr ),
45 fPreviousStepSize (-1.0), fCurrentMinimumStep( -1.0 ), fProposedSafety ( -1.0),
46 fOccurenceBiasingOperation( nullptr ), fFinalStateBiasingOperation( nullptr ), fNonPhysicsBiasingOperation( nullptr ),
47 fPreviousOccurenceBiasingOperation( nullptr ), fPreviousFinalStateBiasingOperation( nullptr ), fPreviousNonPhysicsBiasingOperation( nullptr ),
48 fResetWrappedProcessInteractionLength( true ),
49 fWrappedProcess ( nullptr ),
50 fIsPhysicsBasedBiasing ( false ),
51 fWrappedProcessIsAtRest ( false ),
52 fWrappedProcessIsAlong ( false ),
53 fWrappedProcessIsPost ( false ),
54 fWrappedProcessPostStepGPIL ( -1.0 ),
55 fBiasingPostStepGPIL ( -1.0 ),
56 fWrappedProcessInteractionLength ( -1.0 ),
57 fWrappedProcessForceCondition (
NotForced ),
59 fWrappedProcessAlongStepGPIL ( -1.0 ),
60 fBiasingAlongStepGPIL ( -1.0 ),
63 fBiasingInteractionLaw ( nullptr ),
64 fPreviousBiasingInteractionLaw ( nullptr ),
65 fPhysicalInteractionLaw ( nullptr ),
66 fOccurenceBiasingParticleChange ( nullptr ),
67 fDummyParticleChange ( nullptr ),
68 fIamFirstGPIL ( false ),
69 fProcessManager ( nullptr ),
70 fSharedData ( nullptr )
72 for (
G4int i = 0 ; i < 8 ; i++) fFirstLastFlags[i] =
false;
73 fResetInteractionLaws.
Put(
true );
74 fCommonStart.
Put(
true);
76 fDoCommonConfigure.
Put(
true);
83 :
G4VProcess( useThisName !=
"" ? useThisName :
"biasWrapper("+wrappedProcess->GetProcessName()+
")",
84 wrappedProcess->GetProcessType()),
85 fCurrentTrack ( nullptr ),
86 fPreviousStepSize (-1.0), fCurrentMinimumStep( -1.0 ), fProposedSafety ( -1.0),
87 fOccurenceBiasingOperation( nullptr ), fFinalStateBiasingOperation( nullptr ), fNonPhysicsBiasingOperation( nullptr ),
88 fPreviousOccurenceBiasingOperation( nullptr ), fPreviousFinalStateBiasingOperation( nullptr ), fPreviousNonPhysicsBiasingOperation( nullptr ),
89 fResetWrappedProcessInteractionLength ( false ),
90 fWrappedProcess ( wrappedProcess ),
91 fIsPhysicsBasedBiasing ( true ),
92 fWrappedProcessIsAtRest ( wrappedIsAtRest ),
93 fWrappedProcessIsAlong ( wrappedIsAlongStep ),
94 fWrappedProcessIsPost ( wrappedIsPostStep ),
95 fWrappedProcessPostStepGPIL ( -1.0 ),
96 fBiasingPostStepGPIL ( -1.0 ),
97 fWrappedProcessInteractionLength ( -1.0 ),
98 fWrappedProcessForceCondition (
NotForced ),
100 fWrappedProcessAlongStepGPIL ( -1.0 ),
101 fBiasingAlongStepGPIL ( -1.0 ),
104 fBiasingInteractionLaw ( nullptr ),
105 fPreviousBiasingInteractionLaw ( nullptr ),
106 fPhysicalInteractionLaw ( nullptr ),
107 fOccurenceBiasingParticleChange ( nullptr ),
108 fIamFirstGPIL ( false ),
109 fProcessManager ( nullptr ),
110 fSharedData ( nullptr )
112 for (
G4int i = 0 ; i < 8 ; i++) fFirstLastFlags[i] =
false;
113 fResetInteractionLaws.
Put(
true );
114 fCommonStart.
Put(
true);
115 fCommonEnd.
Put(
true);
116 fDoCommonConfigure.
Put(
true);
132 if ( fPhysicalInteractionLaw != 0 )
delete fPhysicalInteractionLaw;
133 if ( fOccurenceBiasingParticleChange )
delete fOccurenceBiasingParticleChange;
134 if ( fDummyParticleChange )
delete fDummyParticleChange;
142 if ( itr != G4BiasingProcessSharedData::fSharedDataMap.End( ) )
144 return (*itr).second;
152 fCurrentTrack = track;
153 if ( fIsPhysicsBasedBiasing ) fWrappedProcess->
StartTracking(fCurrentTrack);
154 fOccurenceBiasingOperation = 0;
155 fPreviousOccurenceBiasingOperation = 0;
156 fFinalStateBiasingOperation = 0;
157 fPreviousFinalStateBiasingOperation = 0;
158 fNonPhysicsBiasingOperation = 0;
159 fPreviousNonPhysicsBiasingOperation = 0;
160 fBiasingInteractionLaw = 0;
161 fPreviousBiasingInteractionLaw = 0;
163 fPreviousStepSize = -1.0;
165 fResetWrappedProcessInteractionLength =
false;
167 if ( fCommonStart.
Get() )
169 fCommonStart.
Put(
false );
170 fCommonEnd.
Put(
true);
172 fSharedData-> fCurrentBiasingOperator = 0;
173 fSharedData->fPreviousBiasingOperator = 0;
186 if ( fIsPhysicsBasedBiasing ) fWrappedProcess->
EndTracking();
187 if ( fSharedData->fCurrentBiasingOperator) (fSharedData->fCurrentBiasingOperator)->ExitingBiasing( fCurrentTrack,
this );
188 fBiasingInteractionLaw = 0;
191 if ( fCommonEnd.
Get() )
193 fCommonEnd.
Put(
false );
194 fCommonStart.
Put(
true );
222 fSharedData->fPreviousBiasingOperator = fSharedData->fCurrentBiasingOperator;
223 fSharedData->fIsNewOperator =
false;
224 fSharedData->fLeavingPreviousOperator =
false;
228 G4bool firstStepInParallelVolume =
false;
229 if ( fSharedData->fParallelGeometriesLimiterProcess )
233 size_t iParallel = 0;
234 for (
auto wasLimiting : fSharedData->fParallelGeometriesLimiterProcess->
GetWasLimiting() )
236 if ( firstStep || wasLimiting )
238 firstStepInParallelVolume =
true;
241 ->GetLogicalVolume() );
242 if ( newParallelOperator )
244 if ( tmpParallelOperator )
247 ed <<
" Several biasing operators are defined at the same place in parallel geometries ! Found:\n";
248 ed <<
" - `" << newParallelOperator->
GetName() <<
"' and \n";
249 ed <<
" - `" << tmpParallelOperator->GetName() <<
"'.\n";
250 ed <<
" Keeping `" << newParallelOperator->
GetName() <<
"'. Behavior not guaranteed ! Please consider having only one operator at a place. " <<
G4endl;
251 G4Exception(
" G4BiasingProcessInterface::PostStepGetPhysicalInteractionLength(...)",
257 else newParallelOperator = tmpParallelOperator;
261 fSharedData->fParallelGeometryOperator = newParallelOperator;
269 if ( firstStepInVolume )
272 fSharedData->fMassGeometryOperator = newOperator;
273 if ( ( newOperator !=
nullptr ) && ( fSharedData->fParallelGeometryOperator != nullptr ) )
276 ed <<
" Biasing operators are defined at the same place in mass and parallel geometries ! Found:\n";
277 ed <<
" - `" << fSharedData->fParallelGeometryOperator->
GetName() <<
"' in parallel geometry and \n";
278 ed <<
" - `" << newOperator->
GetName() <<
"' in mass geometry.\n";
279 ed <<
" Keeping `" << fSharedData->fParallelGeometryOperator->
GetName() <<
"'. Behavior not guaranteed ! Please consider having only one operator at a place. " <<
G4endl;
280 G4Exception(
" G4BiasingProcessInterface::PostStepGetPhysicalInteractionLength(...)",
288 if ( firstStepInVolume || firstStepInParallelVolume )
291 if ( newOperator ==
nullptr ) newOperator = fSharedData->fMassGeometryOperator;
293 fSharedData->fCurrentBiasingOperator = newOperator ;
295 if ( newOperator != fSharedData->fPreviousBiasingOperator )
297 fSharedData->fLeavingPreviousOperator = ( fSharedData->fPreviousBiasingOperator != nullptr ) ;
298 fSharedData->fIsNewOperator = ( newOperator != nullptr );
310 if ( fSharedData->fCurrentBiasingOperator !=
nullptr )
312 for (
size_t i = 0 ; i < (fSharedData->fPhysicsBiasingProcessInterfaces).size(); i++ )
313 (fSharedData->fPhysicsBiasingProcessInterfaces)[i]->InvokeWrappedProcessPostStepGPIL( track, previousStepSize, condition );
322 if ( ( fSharedData->fPreviousBiasingOperator != 0 ) ||
323 ( fSharedData->fCurrentBiasingOperator != 0 ) )
325 fPreviousOccurenceBiasingOperation = fOccurenceBiasingOperation;
326 fPreviousFinalStateBiasingOperation = fFinalStateBiasingOperation;
327 fPreviousNonPhysicsBiasingOperation = fNonPhysicsBiasingOperation;
328 fPreviousBiasingInteractionLaw = fBiasingInteractionLaw;
330 fOccurenceBiasingOperation = 0;
331 fFinalStateBiasingOperation = 0;
332 fNonPhysicsBiasingOperation = 0;
333 fBiasingInteractionLaw = 0;
336 fBiasingPostStepGPIL =
DBL_MAX;
340 fWrappedProcessAlongStepGPIL =
DBL_MAX;
341 fBiasingAlongStepGPIL =
DBL_MAX;
345 fPreviousStepSize = previousStepSize;
351 G4double usedPreviousStepSize = previousStepSize;
356 if ( fSharedData->fLeavingPreviousOperator )
358 (fSharedData->fPreviousBiasingOperator)->ExitingBiasing( &track,
this );
360 if ( fSharedData->fCurrentBiasingOperator == 0 )
362 ResetForUnbiasedTracking();
363 if ( fIsPhysicsBasedBiasing )
366 if ( fResetWrappedProcessInteractionLength )
368 fResetWrappedProcessInteractionLength =
false;
371 usedPreviousStepSize = 0.0;
381 if ( fSharedData->fCurrentBiasingOperator == 0 )
401 if ( !fIsPhysicsBasedBiasing )
403 fNonPhysicsBiasingOperation = (fSharedData->fCurrentBiasingOperator)->GetProposedNonPhysicsBiasingOperation( &track,
this );
404 if ( fNonPhysicsBiasingOperation == 0 )
416 fOccurenceBiasingOperation = (fSharedData->fCurrentBiasingOperator)->GetProposedOccurenceBiasingOperation( &track,
this );
420 if ( fOccurenceBiasingOperation == 0 )
422 *condition = fWrappedProcessForceCondition;
423 return fWrappedProcessPostStepGPIL;
428 fResetWrappedProcessInteractionLength =
true;
436 fBiasingForceCondition = fWrappedProcessForceCondition;
442 *condition = fBiasingForceCondition;
443 return fBiasingPostStepGPIL;
456 if ( fSharedData->fCurrentBiasingOperator == 0 )
return fWrappedProcess->
PostStepDoIt(track, step);
461 if ( !fIsPhysicsBasedBiasing )
464 (fSharedData->fCurrentBiasingOperator)->ReportOperationApplied(
this,
BAC_NonPhysics, fNonPhysicsBiasingOperation, particleChange );
465 return particleChange;
485 fFinalStateBiasingOperation = (fSharedData->fCurrentBiasingOperator)->GetProposedFinalStateBiasingOperation( &track,
this );
488 G4bool forceBiasedFinalState =
false;
489 if ( fFinalStateBiasingOperation != 0 )
491 finalStateParticleChange = fFinalStateBiasingOperation->
ApplyFinalStateBiasing(
this, &track, &step, forceBiasedFinalState );
496 finalStateParticleChange = fWrappedProcess->
PostStepDoIt(track, step);
501 if ( fOccurenceBiasingOperation == 0 )
503 (fSharedData->fCurrentBiasingOperator)->ReportOperationApplied(
this, BAC, fFinalStateBiasingOperation, finalStateParticleChange );
504 return finalStateParticleChange;
508 if ( forceBiasedFinalState )
510 (fSharedData->fCurrentBiasingOperator)->ReportOperationApplied(
this, BAC, fFinalStateBiasingOperation, finalStateParticleChange );
511 return finalStateParticleChange;
516 G4double weightForInteraction = 1.0;
517 if ( !fBiasingInteractionLaw->
IsSingular() ) weightForInteraction =
519 fBiasingInteractionLaw ->ComputeEffectiveCrossSectionAt(step.
GetStepLength());
526 ed <<
"Internal inconsistency in cross-section handling. Please report !" <<
G4endl;
527 G4Exception(
" G4BiasingProcessInterface::PostStepDoIt(...)",
537 if ( weightForInteraction <= 0. )
540 ed <<
" Negative interaction weight : w_I = "
541 << weightForInteraction <<
545 " Interaction law = `" << fBiasingInteractionLaw <<
"'" <<
547 G4Exception(
" G4BiasingProcessInterface::PostStepDoIt(...)",
554 (fSharedData->fCurrentBiasingOperator)->ReportOperationApplied(
this, BAC,
555 fOccurenceBiasingOperation, weightForInteraction,
556 fFinalStateBiasingOperation, finalStateParticleChange );
566 return fOccurenceBiasingParticleChange;
580 fCurrentMinimumStep = currentMinimumStep;
581 fProposedSafety = proposedSafety;
585 fWrappedProcessAlongStepGPIL =
DBL_MAX;
590 if ( fSharedData->fCurrentBiasingOperator == 0 )
592 if ( fWrappedProcessIsAlong ) fWrappedProcessAlongStepGPIL =
598 return fWrappedProcessAlongStepGPIL;
604 if ( !fIsPhysicsBasedBiasing )
return fWrappedProcessAlongStepGPIL;
609 if ( fOccurenceBiasingOperation == 0 )
611 if ( fWrappedProcessIsAlong ) fWrappedProcessAlongStepGPIL =
617 return fWrappedProcessAlongStepGPIL;
626 G4double minimumStep = fBiasingAlongStepGPIL < currentMinimumStep ? fBiasingAlongStepGPIL : currentMinimumStep ;
629 if ( fWrappedProcessIsAlong )
636 fWrappedProcessGPILSelection = *selection;
637 fBiasingGPILSelection = fOccurenceBiasingOperation->
ProposeGPILSelection( fWrappedProcessGPILSelection );
642 fWrappedProcessAlongStepGPIL = fBiasingAlongStepGPIL;
645 *selection = fBiasingGPILSelection;
647 return fWrappedProcessAlongStepGPIL;
658 if ( fSharedData->fCurrentBiasingOperator == 0 )
660 if ( fWrappedProcessIsAlong )
return fWrappedProcess->
AlongStepDoIt(track, step);
664 return fDummyParticleChange;
677 G4double weightForNonInteraction (1.0);
678 if ( fBiasingInteractionLaw != 0 )
680 weightForNonInteraction =
682 fBiasingInteractionLaw ->ComputeNonInteractionProbabilityAt(step.
GetStepLength());
684 fOccurenceBiasingOperation->
AlongMoveBy(
this, &step, weightForNonInteraction );
686 if ( weightForNonInteraction <= 0. )
689 ed <<
" Negative non interaction weight : w_NI = " << weightForNonInteraction <<
691 " p_NI(bias) = " << fBiasingInteractionLaw ->ComputeNonInteractionProbabilityAt(step.
GetStepLength()) <<
693 " biasing interaction law = `" << fBiasingInteractionLaw->
GetName() <<
"'" <<
G4endl;
694 G4Exception(
" G4BiasingProcessInterface::AlongStepDoIt(...)",
704 return fOccurenceBiasingParticleChange;
717 return fWrappedProcess->
AtRestDoIt(track, step);
723 if ( fWrappedProcess != 0 )
return fWrappedProcess->
IsApplicable(pd);
733 if ( fWrappedProcess != 0 )
752 if ( fWrappedProcess != 0 )
761 ReorderBiasingVectorAsGPIL();
765 if ( fDoCommonConfigure.
Get() )
769 fDoCommonConfigure.
Put(
false);
782 SetUpFirstLastFlags();
783 if ( fWrappedProcess != 0 )
810 if ( G4BiasingProcessSharedData::fSharedDataMap.Find(mgr) == G4BiasingProcessSharedData::fSharedDataMap.End() )
813 G4BiasingProcessSharedData::fSharedDataMap[mgr] = fSharedData;
815 else fSharedData = G4BiasingProcessSharedData::fSharedDataMap[mgr] ;
817 fSharedData-> fBiasingProcessInterfaces.push_back(
this );
818 fSharedData-> fPublicBiasingProcessInterfaces.push_back(
this );
819 if ( fIsPhysicsBasedBiasing )
821 fSharedData-> fPhysicsBiasingProcessInterfaces.push_back(
this );
822 fSharedData-> fPublicPhysicsBiasingProcessInterfaces.push_back(
this );
826 fSharedData-> fNonPhysicsBiasingProcessInterfaces.push_back(
this );
827 fSharedData-> fPublicNonPhysicsBiasingProcessInterfaces.push_back(
this );
830 fProcessManager = mgr;
848 if ( fWrappedProcess != 0 )
857 ReorderBiasingVectorAsGPIL();
861 if ( fDoCommonConfigure.
Get() )
865 fDoCommonConfigure.
Put(
false);
876 SetUpFirstLastFlags();
878 if ( fWrappedProcess != 0 )
893 G4int iPhys = ( physOnly ) ? 1 : 0;
894 return fFirstLastFlags[IdxFirstLast( 1, 1, iPhys)];
900 G4int iPhys = ( physOnly ) ? 1 : 0;
901 return fFirstLastFlags[IdxFirstLast( 0, 1, iPhys)];
907 G4int iPhys = ( physOnly ) ? 1 : 0;
908 return fFirstLastFlags[IdxFirstLast( 1, 0, iPhys)];
914 G4int iPhys = ( physOnly ) ? 1 : 0;
915 return fFirstLastFlags[IdxFirstLast( 0, 0, iPhys)];
924 for (
G4int i = 0; i < pv->
size(); i++ )
if ( (*pv)(i) ==
this ) { thisIdx = i;
break; }
925 for (
size_t i = 0; i < (fSharedData->fBiasingProcessInterfaces).size(); i++ )
927 if ( (fSharedData->fBiasingProcessInterfaces)[i]->fIsPhysicsBasedBiasing || !physOnly )
930 for (
G4int j = 0; j < pv->
size(); j++ )
if ( (*pv)(j) == (fSharedData->fBiasingProcessInterfaces)[i] ) { thatIdx = j;
break; }
931 if ( thisIdx > thatIdx )
947 for (
G4int i = 0; i < pv->
size(); i++ )
if ( (*pv)(i) ==
this ) { thisIdx = i;
break; }
948 for (
size_t i = 0; i < (fSharedData->fBiasingProcessInterfaces).size(); i++ )
950 if ( (fSharedData->fBiasingProcessInterfaces)[i]->fIsPhysicsBasedBiasing || !physOnly )
953 for (
G4int j = 0; j < pv->
size(); j++ )
if ( (*pv)(j) == (fSharedData->fBiasingProcessInterfaces)[i] ) { thatIdx = j;
break; }
954 if ( thisIdx < thatIdx )
970 for (
G4int i = 0; i < pv->
size(); i++ )
if ( (*pv)(i) ==
this ) { thisIdx = i;
break; }
971 for (
size_t i = 0; i < (fSharedData->fBiasingProcessInterfaces).size(); i++ )
973 if ( (fSharedData->fBiasingProcessInterfaces)[i]->fIsPhysicsBasedBiasing || !physOnly )
976 for (
G4int j = 0; j < pv->
size(); j++ )
if ( (*pv)(j) == (fSharedData->fBiasingProcessInterfaces)[i] ) { thatIdx = j;
break; }
977 if ( thisIdx > thatIdx )
993 for (
G4int i = 0; i < pv->
size(); i++ )
if ( (*pv)(i) ==
this ) { thisIdx = i;
break; }
994 for (
size_t i = 0; i < (fSharedData->fBiasingProcessInterfaces).size(); i++ )
996 if ( (fSharedData->fBiasingProcessInterfaces)[i]->fIsPhysicsBasedBiasing || !physOnly )
999 for (
G4int j = 0; j < pv->
size(); j++ )
if ( (*pv)(j) == (fSharedData->fBiasingProcessInterfaces)[i] ) { thatIdx = j;
break; }
1000 if ( thisIdx < thatIdx )
1011 void G4BiasingProcessInterface::SetUpFirstLastFlags()
1013 for (
G4int iPhys = 0; iPhys < 2; iPhys++ )
1015 G4bool physOnly = ( iPhys == 1 );
1027 void G4BiasingProcessInterface::ResetForUnbiasedTracking()
1029 fOccurenceBiasingOperation = 0;
1030 fFinalStateBiasingOperation = 0;
1031 fNonPhysicsBiasingOperation = 0;
1032 fBiasingInteractionLaw = 0;
1036 void G4BiasingProcessInterface::InvokeWrappedProcessPostStepGPIL(
const G4Track& track,
1040 G4double usedPreviousStepSize = previousStepSize;
1047 if ( fResetWrappedProcessInteractionLength )
1049 fResetWrappedProcessInteractionLength =
false;
1052 usedPreviousStepSize = 0.0;
1056 fWrappedProcessForceCondition = *
condition;
1062 void G4BiasingProcessInterface::ReorderBiasingVectorAsGPIL()
1065 std::vector < G4BiasingProcessInterface* > tmpProcess ( fSharedData->fBiasingProcessInterfaces );
1066 ( fSharedData -> fBiasingProcessInterfaces ) . clear();
1067 ( fSharedData -> fPhysicsBiasingProcessInterfaces ) . clear();
1068 ( fSharedData -> fNonPhysicsBiasingProcessInterfaces ) . clear();
1069 ( fSharedData -> fPublicBiasingProcessInterfaces ) . clear();
1070 ( fSharedData -> fPublicPhysicsBiasingProcessInterfaces ) . clear();
1071 ( fSharedData -> fPublicNonPhysicsBiasingProcessInterfaces ) . clear();
1076 for (
size_t j = 0; j < tmpProcess.size(); j++ )
1078 if ( (*pv)(i) == tmpProcess[j] )
1080 ( fSharedData -> fBiasingProcessInterfaces ) . push_back( tmpProcess[j] );
1081 ( fSharedData -> fPublicBiasingProcessInterfaces ) . push_back( tmpProcess[j] );
1082 if ( tmpProcess[j] -> fIsPhysicsBasedBiasing )
1084 ( fSharedData -> fPhysicsBiasingProcessInterfaces ) . push_back( tmpProcess[j] );
1085 ( fSharedData -> fPublicPhysicsBiasingProcessInterfaces ) . push_back( tmpProcess[j] );
1089 ( fSharedData -> fNonPhysicsBiasingProcessInterfaces ) . push_back( tmpProcess[j] );
1090 ( fSharedData -> fPublicNonPhysicsBiasingProcessInterfaces ) . push_back( tmpProcess[j] );
virtual void SetMasterProcess(G4VProcess *masterP)
virtual void Initialize(const G4Track &track)
G4double condition(const G4ErrorSymMatrix &m)
const G4VProcess * GetMasterProcess() const
virtual void BuildWorkerPhysicsTable(const G4ParticleDefinition &pd)
G4bool IsLastPostStepGPILInterface(G4bool physOnly=true) const
virtual void PreparePhysicsTable(const G4ParticleDefinition &pd)
virtual G4VParticleChange * AtRestDoIt(const G4Track &, const G4Step &)
virtual G4double ComputeNonInteractionProbabilityAt(G4double length) const
virtual G4double AtRestGetPhysicalInteractionLength(const G4Track &track, G4ForceCondition *condition)=0
virtual void SetProcessManager(const G4ProcessManager *)
void SetWrappedParticleChange(G4VParticleChange *wpc)
virtual G4double PostStepGetPhysicalInteractionLength(const G4Track &track, G4double previousStepSize, G4ForceCondition *condition)=0
virtual G4bool StorePhysicsTable(const G4ParticleDefinition *pd, const G4String &s, G4bool f)
std::ostringstream G4ExceptionDescription
G4double GetStepLength() const
virtual void BuildPhysicsTable(const G4ParticleDefinition &pd)
virtual G4VParticleChange * ApplyFinalStateBiasing(const G4BiasingProcessInterface *, const G4Track *, const G4Step *, G4bool &)=0
virtual void PrepareWorkerPhysicsTable(const G4ParticleDefinition &pd)
virtual G4VParticleChange * AlongStepDoIt(const G4Track &track, const G4Step &step)
G4StepStatus GetStepStatus() const
const std::vector< const G4VPhysicalVolume * > & GetCurrentVolumes() const
G4TrackStatus GetTrackStatus() const
virtual G4VParticleChange * PostStepDoIt(const G4Track &track, const G4Step &step)
virtual void SetProcessManager(const G4ProcessManager *)
virtual G4double ComputeEffectiveCrossSectionAt(G4double length) const =0
virtual void ResetNumberOfInteractionLengthLeft()
void SetOccurenceWeightForNonInteraction(G4double w)
const G4Step * GetStep() const
virtual G4double ProposeAlongStepLimit(const G4BiasingProcessInterface *)
G4VProcess * GetWrappedProcess() const
virtual void BuildWorkerPhysicsTable(const G4ParticleDefinition &part)
G4bool GetIsFirstPostStepGPILInterface(G4bool physOnly=true) const
G4StepPoint * GetPreStepPoint() const
virtual void StartTracking(G4Track *)
void SetSecondaryWeightByProcess(G4bool)
G4int GetCurrentStepNumber() const
G4bool GetIsLastPostStepDoItInterface(G4bool physOnly=true) const
G4bool GetIsLastPostStepGPILInterface(G4bool physOnly=true) const
virtual void PreparePhysicsTable(const G4ParticleDefinition &)
virtual G4double ComputeEffectiveCrossSectionAt(G4double length) const
G4bool GetIsFirstPostStepDoItInterface(G4bool physOnly=true) const
G4double GetCurrentInteractionLength() const
void SetProcessSubType(G4int)
void SetPhysicalCrossSection(G4double crossSection)
void SetOccurenceWeightForInteraction(G4double w)
virtual G4double PostStepGetPhysicalInteractionLength(const G4Track &track, G4double previousStepSize, G4ForceCondition *condition)
virtual G4bool RetrievePhysicsTable(const G4ParticleDefinition *, const G4String &, G4bool)
const G4String & GetProcessName() const
const std::vector< G4bool > & GetWasLimiting() const
virtual G4VParticleChange * GenerateBiasingFinalState(const G4Track *, const G4Step *)=0
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *comments)
virtual G4bool IsApplicable(const G4ParticleDefinition &pd)
virtual const G4ProcessManager * GetProcessManager()
static G4VBiasingOperator * GetBiasingOperator(const G4LogicalVolume *)
virtual G4bool IsSingular() const
virtual const G4ProcessManager * GetProcessManager()
iterator Find(const key_type &k)
G4LogicalVolume * GetLogicalVolume() const
virtual void BuildPhysicsTable(const G4ParticleDefinition &)
virtual G4VParticleChange * AlongStepDoIt(const G4Track &track, const G4Step &stepData)=0
G4bool IsFirstPostStepGPILInterface(G4bool physOnly=true) const
virtual void SetMasterProcess(G4VProcess *masterP)
G4BiasingProcessInterface(G4String name="biasWrapper(0)")
virtual G4bool RetrievePhysicsTable(const G4ParticleDefinition *pd, const G4String &s, G4bool f)
virtual G4GPILSelection ProposeGPILSelection(const G4GPILSelection wrappedProcessSelection)
G4VPhysicalVolume * GetVolume() const
virtual G4double AlongStepGetPhysicalInteractionLength(const G4Track &track, G4double previousStepSize, G4double currentMinimumStep, G4double &proposedSafety, G4GPILSelection *selection)=0
G4double GetSampledInteractionLength() const
static const std::vector< G4VBiasingOperator * > & GetBiasingOperators()
const G4String & GetName() const
virtual G4bool StorePhysicsTable(const G4ParticleDefinition *, const G4String &, G4bool)
virtual G4bool IsEffectiveCrossSectionInfinite() const
G4TrackStatus GetTrackStatus() const
G4bool IsFirstPostStepDoItInterface(G4bool physOnly=true) const
virtual const G4VBiasingInteractionLaw * ProvideOccurenceBiasingInteractionLaw(const G4BiasingProcessInterface *, G4ForceCondition &)=0
virtual void AlongMoveBy(const G4BiasingProcessInterface *, const G4Step *, G4double)
virtual void ResetNumberOfInteractionLengthLeft()
virtual void PrepareWorkerPhysicsTable(const G4ParticleDefinition &)
void ProposeTrackStatus(G4TrackStatus status)
virtual void EndTracking()
virtual G4VParticleChange * PostStepDoIt(const G4Track &track, const G4Step &stepData)=0
G4bool IsLastPostStepDoItInterface(G4bool physOnly=true) const
void Put(const value_type &val) const
G4int GetProcessSubType() const
void StartTracking(G4Track *track)
virtual G4double DistanceToApplyOperation(const G4Track *, G4double, G4ForceCondition *)=0
virtual G4bool IsApplicable(const G4ParticleDefinition &)
virtual G4double AlongStepGetPhysicalInteractionLength(const G4Track &track, G4double previousStepSize, G4double currentMinimumStep, G4double &proposedSafety, G4GPILSelection *selection)
virtual G4double AtRestGetPhysicalInteractionLength(const G4Track &, G4ForceCondition *)
const G4String GetName() const
~G4BiasingProcessInterface()
virtual G4VParticleChange * AtRestDoIt(const G4Track &track, const G4Step &stepData)=0
G4ProcessVector * GetPostStepProcessVector(G4ProcessVectorTypeIndex typ=typeGPIL) const
const G4BiasingProcessSharedData * GetSharedData() const