File indexing completed on 2025-01-18 09:58:23
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
0044
0045
0046
0047
0048 #ifndef G4HadronStoppingProcess_h
0049 #define G4HadronStoppingProcess_h 1
0050
0051 #include "globals.hh"
0052 #include "G4HadronicProcess.hh"
0053 #include "G4ParticleDefinition.hh"
0054 #include "G4ElementSelector.hh"
0055 #include "G4HadronicInteraction.hh"
0056 #include "G4Track.hh"
0057 #include "G4Step.hh"
0058 #include "G4ForceCondition.hh"
0059 #include "G4HadronicProcessType.hh"
0060 #include "G4HadFinalState.hh"
0061
0062 class G4HadronStoppingProcess : public G4HadronicProcess
0063 {
0064 public:
0065
0066 explicit G4HadronStoppingProcess(const G4String& name = "hadronCaptureAtRest");
0067
0068 virtual ~G4HadronStoppingProcess();
0069
0070 virtual G4bool IsApplicable(const G4ParticleDefinition&);
0071
0072 virtual void PreparePhysicsTable(const G4ParticleDefinition&);
0073
0074 virtual void BuildPhysicsTable(const G4ParticleDefinition&);
0075
0076 virtual G4double
0077 AtRestGetPhysicalInteractionLength(const G4Track& track,
0078 G4ForceCondition* condition);
0079
0080 virtual G4double
0081 PostStepGetPhysicalInteractionLength(const G4Track& track,
0082 G4double previousStepSize,
0083 G4ForceCondition* condition);
0084
0085 virtual G4VParticleChange* AtRestDoIt(const G4Track&, const G4Step&);
0086
0087 virtual void ProcessDescription(std::ostream& outFile) const;
0088
0089 inline void SetElementSelector(G4ElementSelector* ptr);
0090
0091 inline void SetEmCascade(G4HadronicInteraction* ptr);
0092
0093 inline void SetBoundDecay(G4HadronicInteraction* ptr);
0094
0095 protected:
0096
0097
0098 G4double GetMeanLifeTime(const G4Track& ,
0099 G4ForceCondition* ) { return -1.0; }
0100
0101 private:
0102
0103
0104 G4HadronStoppingProcess& operator=(const G4HadronStoppingProcess &right);
0105 G4HadronStoppingProcess(const G4HadronStoppingProcess& );
0106
0107 G4ElementSelector* fElementSelector;
0108
0109 G4HadronicInteraction* fEmCascade;
0110 G4HadronicInteraction* fBoundDecay;
0111
0112 G4int emcID;
0113 G4int ncID;
0114 G4int dioID;
0115
0116
0117
0118
0119 };
0120
0121 inline void
0122 G4HadronStoppingProcess::SetElementSelector(G4ElementSelector* ptr)
0123 {
0124 if(fElementSelector != ptr) {
0125 delete fElementSelector;
0126 fElementSelector = ptr;
0127 }
0128 }
0129
0130 inline void
0131 G4HadronStoppingProcess::SetEmCascade(G4HadronicInteraction* ptr)
0132 {
0133 fEmCascade = ptr;
0134 }
0135
0136 inline void
0137 G4HadronStoppingProcess::SetBoundDecay(G4HadronicInteraction* ptr)
0138 {
0139 fBoundDecay = ptr;
0140 }
0141
0142 #endif