File indexing completed on 2025-01-18 09:57:59
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021
0022
0023
0024
0025
0026
0027
0028
0029
0030
0031
0032
0033
0034
0035
0036
0037
0038
0039
0040
0041
0042
0043 #ifndef G4BOptrForceCollision_hh
0044 #define G4BOptrForceCollision_hh 1
0045
0046 #include "G4VBiasingOperator.hh"
0047 class G4BOptnForceFreeFlight;
0048 class G4BOptnForceCommonTruncatedExp;
0049 class G4BOptnCloning;
0050 class G4VProcess;
0051 class G4BiasingProcessInterface;
0052 class G4ParticleDefinition;
0053 #include <vector>
0054 #include <map>
0055 #include "G4ThreeVector.hh"
0056 class G4BOptrForceCollisionTrackData;
0057
0058 class G4BOptrForceCollision : public G4VBiasingOperator {
0059 public:
0060 G4BOptrForceCollision(G4String particleToForce, G4String name="ForceCollision");
0061 G4BOptrForceCollision(const G4ParticleDefinition* particleToForce, G4String name="ForceCollision");
0062 ~G4BOptrForceCollision();
0063
0064 private:
0065
0066 virtual G4VBiasingOperation* ProposeNonPhysicsBiasingOperation(const G4Track* track, const G4BiasingProcessInterface* callingProcess) final;
0067 virtual G4VBiasingOperation* ProposeOccurenceBiasingOperation(const G4Track* track, const G4BiasingProcessInterface* callingProcess) final;
0068 virtual G4VBiasingOperation* ProposeFinalStateBiasingOperation(const G4Track* track, const G4BiasingProcessInterface* callingProcess) final;
0069
0070 public:
0071 virtual void Configure() final;
0072 virtual void ConfigureForWorker() final;
0073 virtual void StartRun() final;
0074 virtual void StartTracking( const G4Track* track ) final;
0075 virtual void ExitBiasing( const G4Track*, const G4BiasingProcessInterface* ) final {};
0076 virtual void EndTracking() final;
0077
0078
0079 void OperationApplied( const G4BiasingProcessInterface* callingProcess, G4BiasingAppliedCase biasingCase,
0080 G4VBiasingOperation* operationApplied, const G4VParticleChange* particleChangeProduced ) final;
0081 void OperationApplied( const G4BiasingProcessInterface* callingProcess, G4BiasingAppliedCase biasingCase,
0082 G4VBiasingOperation* occurenceOperationApplied, G4double weightForOccurenceInteraction,
0083 G4VBiasingOperation* finalStateOperationApplied, const G4VParticleChange* particleChangeProduced ) final;
0084
0085
0086 private:
0087 G4int fForceCollisionModelID;
0088 const G4Track* fCurrentTrack;
0089 G4BOptrForceCollisionTrackData* fCurrentTrackData;
0090 std::map< const G4BiasingProcessInterface*, G4BOptnForceFreeFlight* > fFreeFlightOperations;
0091 G4BOptnForceCommonTruncatedExp* fSharedForceInteractionOperation;
0092 G4BOptnCloning* fCloningOperation;
0093 G4double fInitialTrackWeight;
0094 G4bool fSetup;
0095 const G4ParticleDefinition* fParticleToBias;
0096 };
0097
0098 #endif