Warning, file /include/Geant4/G4ChemReboundTransportation.hh was not indexed
or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).
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 #ifndef TRANSPORTATION_H
0028 #define TRANSPORTATION_H
0029
0030 #include "G4DNABoundingBox.hh"
0031 #include "G4ITReaction.hh"
0032 #include "G4ITTransportation.hh"
0033 #include "G4MolecularConfiguration.hh"
0034
0035 class G4Molecule;
0036 class G4VUserBrownianAction;
0037
0038 class G4ChemReboundTransportation : public G4ITTransportation
0039 {
0040 using MolConf = const G4MolecularConfiguration*;
0041
0042 public:
0043 explicit G4ChemReboundTransportation(const G4String& aName = "ChemReboundTransportation",
0044 const G4DNABoundingBox* = nullptr, G4int verbosityLevel = 0);
0045 ~G4ChemReboundTransportation() override = default;
0046 G4ChemReboundTransportation(const G4ChemReboundTransportation&) = delete;
0047 G4ChemReboundTransportation& operator=(const G4ChemReboundTransportation&) = delete;
0048 void BuildPhysicsTable(const G4ParticleDefinition&) override;
0049 void StartTracking(G4Track* aTrack) override;
0050 void ComputeStep(const G4Track&, const G4Step&, G4double, G4double&) override;
0051 G4double AlongStepGetPhysicalInteractionLength(const G4Track& ,
0052 G4double ,
0053 G4double ,
0054 G4double& ,
0055 G4GPILSelection* ) override;
0056
0057 G4VParticleChange* PostStepDoIt(const G4Track& track, const G4Step&) override;
0058 G4VParticleChange* AlongStepDoIt(const G4Track& track, const G4Step&) override;
0059
0060 inline void SetBoundary(const G4DNABoundingBox*);
0061 static G4double calculateNextCoordinate(G4double nextPos, G4double high, G4double low);
0062 G4double GetTimeToBoundary(const G4Track& track);
0063
0064 protected:
0065
0066
0067 struct G4ITBrownianState : public G4ITTransportationState
0068 {
0069 public:
0070 G4ITBrownianState();
0071 ~G4ITBrownianState() override = default;
0072 G4String GetType() override { return "Rebound"; }
0073
0074 G4bool fTimeStepReachedLimit;
0075 G4double fRandomNumber;
0076 };
0077 G4ITReactionSet* fReactionSet = G4ITReactionSet::Instance();
0078
0079 G4Material* fNistWater = nullptr;
0080 G4double fMaximumTimeStep = 0;
0081 G4double fInternalMinTimeStep;
0082 const G4DNABoundingBox* fpBoundingBox = nullptr;
0083 G4ThreeVector BouncingAction(const G4ThreeVector& nextPosition);
0084 G4double calculateDistanceFromTimeStep(MolConf mol, G4double timeStep);
0085 };
0086
0087 inline void G4ChemReboundTransportation::SetBoundary(const G4DNABoundingBox* pBounding)
0088 {
0089 fpBoundingBox = pBounding;
0090 }
0091
0092 #endif