Warning, file /include/Geant4/G4ParticleHPManager.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 G4ParticleHPManager_h
0028 #define G4ParticleHPManager_h 1
0029
0030
0031
0032
0033
0034 #include "G4ParticleHPReactionWhiteBoard.hh"
0035 #include "globals.hh"
0036
0037 #include <map>
0038 #include <vector>
0039
0040 class G4ParticleDefinition;
0041 class G4ParticleHPChannel;
0042 class G4ParticleHPChannelList;
0043 class G4ParticleHPMessenger;
0044 class G4ParticleHPVector;
0045 class G4ParticleHPIsoProbabilityTable;
0046 class G4PhysicsTable;
0047
0048 struct E_isoAng;
0049 struct E_P_E_isoAng;
0050
0051 class G4ParticleHPManager
0052 {
0053 public:
0054
0055 static G4ParticleHPManager* GetInstance();
0056 ~G4ParticleHPManager();
0057
0058 G4ParticleHPReactionWhiteBoard* GetReactionWhiteBoard();
0059 void OpenReactionWhiteBoard();
0060 void CloseReactionWhiteBoard();
0061
0062 void GetDataStream(const G4String&, std::istringstream& iss);
0063 void GetDataStream2(const G4String&, std::istringstream& iss);
0064 void SetVerboseLevel(G4int i);
0065 G4int GetVerboseLevel() const { return verboseLevel; }
0066
0067 void DumpDataSource() const;
0068
0069 G4bool GetUseOnlyPhotoEvaporation() const { return USE_ONLY_PHOTONEVAPORATION; }
0070 G4bool GetSkipMissingIsotopes() const { return SKIP_MISSING_ISOTOPES; }
0071 G4bool GetNeglectDoppler() const { return NEGLECT_DOPPLER; }
0072 G4bool GetDoNotAdjustFinalState() const { return DO_NOT_ADJUST_FINAL_STATE; }
0073 G4bool GetProduceFissionFragments() const { return PRODUCE_FISSION_FRAGMENTS; }
0074 G4bool GetUseWendtFissionModel() const { return USE_WENDT_FISSION_MODEL; }
0075 G4bool GetUseNRESP71Model() const { return USE_NRESP71_MODEL; }
0076 G4bool GetUseDBRC() const { return USE_DBRC; }
0077 G4bool GetCheckHPNames() const { return CHECK_HP_NAMES; }
0078 G4bool GetPHPCheck() const { return PHP_CHECK; }
0079 G4bool GetPHCUsePoisson() const { return PHP_USE_POISSON; }
0080 G4bool GetDEBUG() const { return DEBUG; }
0081
0082 const G4String& GetNeutronHPPath() const { return fDataPath[0]; };
0083 const G4String& GetParticleHPPath(const G4ParticleDefinition*) const;
0084 G4int GetPHPIndex(const G4ParticleDefinition*) const;
0085
0086 void SetUseOnlyPhotoEvaporation(G4bool val) { USE_ONLY_PHOTONEVAPORATION = val; }
0087 void SetSkipMissingIsotopes(G4bool val) { SKIP_MISSING_ISOTOPES = val; }
0088 void SetNeglectDoppler(G4bool val) { NEGLECT_DOPPLER = val; }
0089 void SetDoNotAdjustFinalState(G4bool val) { DO_NOT_ADJUST_FINAL_STATE = val; }
0090 void SetProduceFissionFragments(G4bool val)
0091 {
0092
0093 PRODUCE_FISSION_FRAGMENTS = USE_WENDT_FISSION_MODEL ? false : val;
0094 }
0095 void SetUseWendtFissionModel(G4bool val)
0096 {
0097 USE_WENDT_FISSION_MODEL = val;
0098
0099 if (USE_WENDT_FISSION_MODEL) PRODUCE_FISSION_FRAGMENTS = false;
0100 }
0101 void SetUseNRESP71Model(G4bool val) { USE_NRESP71_MODEL = val; }
0102 void SetUseDBRC(G4bool val) { USE_DBRC = val; }
0103
0104 void DumpSetting();
0105
0106 void RegisterElasticCrossSections(G4PhysicsTable* val) { theElasticCrossSections = val; }
0107 G4PhysicsTable* GetElasticCrossSections() const { return theElasticCrossSections; }
0108 void RegisterCaptureCrossSections(G4PhysicsTable* val) { theCaptureCrossSections = val; }
0109 G4PhysicsTable* GetCaptureCrossSections() const { return theCaptureCrossSections; }
0110 void RegisterInelasticCrossSections(const G4ParticleDefinition* part, G4PhysicsTable* ptr)
0111 {
0112 theInelasticCrossSections[GetPHPIndex(part)] = ptr;
0113 }
0114 G4PhysicsTable* GetInelasticCrossSections(const G4ParticleDefinition* part) const
0115 {
0116 return theInelasticCrossSections[GetPHPIndex(part)];
0117 }
0118 void RegisterFissionCrossSections(G4PhysicsTable* val) { theFissionCrossSections = val; }
0119 G4PhysicsTable* GetFissionCrossSections() const { return theFissionCrossSections; }
0120
0121 std::vector<G4ParticleHPChannel*>* GetElasticFinalStates() const { return theElasticFSs; }
0122 void RegisterElasticFinalStates(std::vector<G4ParticleHPChannel*>* val)
0123 {
0124 theElasticFSs = val;
0125 }
0126
0127 std::vector<G4ParticleHPChannelList*>*
0128 GetInelasticFinalStates(const G4ParticleDefinition* part) const
0129 {
0130 return theInelasticFSs[GetPHPIndex(part)];
0131 }
0132 void RegisterInelasticFinalStates(const G4ParticleDefinition* part,
0133 std::vector<G4ParticleHPChannelList*>* ptr)
0134 {
0135 theInelasticFSs[GetPHPIndex(part)] = ptr;
0136 }
0137
0138 std::vector<G4ParticleHPChannel*>* GetCaptureFinalStates() const { return theCaptureFSs; }
0139 void RegisterCaptureFinalStates(std::vector<G4ParticleHPChannel*>* val)
0140 {
0141 theCaptureFSs = val;
0142 }
0143 std::vector<G4ParticleHPChannel*>* GetFissionFinalStates() const { return theFissionFSs; }
0144 void RegisterFissionFinalStates(std::vector<G4ParticleHPChannel*>* val)
0145 {
0146 theFissionFSs = val;
0147 }
0148
0149 std::map<G4int, std::map<G4double, G4ParticleHPVector*>*>*
0150 GetThermalScatteringCoherentCrossSections() const
0151 {
0152 return theTSCoherentCrossSections;
0153 }
0154 void RegisterThermalScatteringCoherentCrossSections(
0155 std::map<G4int, std::map<G4double, G4ParticleHPVector*>*>* val)
0156 {
0157 theTSCoherentCrossSections = val;
0158 }
0159 std::map<G4int, std::map<G4double, G4ParticleHPVector*>*>*
0160 GetThermalScatteringIncoherentCrossSections() const
0161 {
0162 return theTSIncoherentCrossSections;
0163 }
0164 void RegisterThermalScatteringIncoherentCrossSections(
0165 std::map<G4int, std::map<G4double, G4ParticleHPVector*>*>* val)
0166 {
0167 theTSIncoherentCrossSections = val;
0168 }
0169 std::map<G4int, std::map<G4double, G4ParticleHPVector*>*>*
0170 GetThermalScatteringInelasticCrossSections() const
0171 {
0172 return theTSInelasticCrossSections;
0173 }
0174 void RegisterThermalScatteringInelasticCrossSections(
0175 std::map<G4int, std::map<G4double, G4ParticleHPVector*>*>* val)
0176 {
0177 theTSInelasticCrossSections = val;
0178 }
0179
0180 std::map<G4int, std::map<G4double, std::vector<std::pair<G4double, G4double>*>*>*>*
0181 GetThermalScatteringCoherentFinalStates() const
0182 {
0183 return theTSCoherentFinalStates;
0184 }
0185 void RegisterThermalScatteringCoherentFinalStates(
0186 std::map<G4int, std::map<G4double, std::vector<std::pair<G4double, G4double>*>*>*>* val)
0187 {
0188 theTSCoherentFinalStates = val;
0189 }
0190 std::map<G4int, std::map<G4double, std::vector<E_isoAng*>*>*>*
0191 GetThermalScatteringIncoherentFinalStates() const
0192 {
0193 return theTSIncoherentFinalStates;
0194 }
0195 void RegisterThermalScatteringIncoherentFinalStates(
0196 std::map<G4int, std::map<G4double, std::vector<E_isoAng*>*>*>* val)
0197 {
0198 theTSIncoherentFinalStates = val;
0199 }
0200 std::map<G4int, std::map<G4double, std::vector<E_P_E_isoAng*>*>*>*
0201 GetThermalScatteringInelasticFinalStates() const
0202 {
0203 return theTSInelasticFinalStates;
0204 }
0205 void RegisterThermalScatteringInelasticFinalStates(
0206 std::map<G4int, std::map<G4double, std::vector<E_P_E_isoAng*>*>*>* val)
0207 {
0208 theTSInelasticFinalStates = val;
0209 }
0210
0211 std::vector< std::map< G4int, G4ParticleHPIsoProbabilityTable* > >* GetProbabilityTables() const
0212 { return theProbabilityTables; }
0213 void RegisterProbabilityTables( std::vector< std::map< G4int, G4ParticleHPIsoProbabilityTable* > >* val )
0214 { theProbabilityTables = val; }
0215
0216 std::vector< std::pair< G4double, G4double > >* GetURRlimits() const { return theURRlimits; }
0217 void RegisterURRlimits( std::vector< std::pair< G4double, G4double > >* val ) { theURRlimits = val; }
0218
0219 G4double GetMinADBRC() const { return theMinADBRC; }
0220 G4double GetMinEnergyDBRC() const { return theMinEnergyDBRC; }
0221 G4double GetMaxEnergyDBRC() const { return theMaxEnergyDBRC; }
0222 G4double GetMaxEnergyDoppler() const { return theMaxEnergyDoppler; }
0223
0224 void SetMinADBRC(G4double val) { theMinADBRC = val; }
0225 void SetMinEnergyDBRC(G4double val) { theMinEnergyDBRC = val; }
0226 void SetMaxEnergyDBRC(G4double val) { theMaxEnergyDBRC = val; }
0227 void SetMaxEnergyDoppler(G4double val) { theMaxEnergyDoppler = val; }
0228
0229 G4ParticleHPManager(G4ParticleHPManager &) = delete;
0230 G4ParticleHPManager & operator=(const G4ParticleHPManager &right) = delete;
0231
0232 private:
0233
0234 G4ParticleHPManager();
0235 void register_data_file(const G4String&, const G4String&);
0236
0237 static G4ParticleHPManager* instance;
0238
0239 std::map<G4String, G4String> mDataEvaluation;
0240
0241 G4int verboseLevel{1};
0242
0243 G4ParticleHPMessenger* messenger;
0244 G4bool USE_ONLY_PHOTONEVAPORATION{false};
0245 G4bool SKIP_MISSING_ISOTOPES{false};
0246 G4bool NEGLECT_DOPPLER{false};
0247 G4bool DO_NOT_ADJUST_FINAL_STATE{false};
0248 G4bool PRODUCE_FISSION_FRAGMENTS{false};
0249 G4bool USE_WENDT_FISSION_MODEL{false};
0250 G4bool USE_NRESP71_MODEL{false};
0251 G4bool USE_DBRC{false};
0252 G4bool CHECK_HP_NAMES{false};
0253 G4bool PHP_CHECK{true};
0254 G4bool PHP_USE_POISSON{false};
0255 G4bool DEBUG{false};
0256 G4bool isPrinted{false};
0257
0258 G4PhysicsTable* theElasticCrossSections{nullptr};
0259 G4PhysicsTable* theCaptureCrossSections{nullptr};
0260 G4PhysicsTable* theInelasticCrossSections[6]{nullptr};
0261 G4PhysicsTable* theFissionCrossSections{nullptr};
0262
0263 std::vector<G4ParticleHPChannel*>* theElasticFSs{nullptr};
0264 std::vector<G4ParticleHPChannelList*>* theInelasticFSs[6]{nullptr};
0265 std::vector<G4ParticleHPChannel*>* theCaptureFSs{nullptr};
0266 std::vector<G4ParticleHPChannel*>* theFissionFSs{nullptr};
0267
0268 std::map<G4int, std::map<G4double, G4ParticleHPVector*>*>* theTSCoherentCrossSections{nullptr};
0269 std::map<G4int, std::map<G4double, G4ParticleHPVector*>*>* theTSIncoherentCrossSections{nullptr};
0270 std::map<G4int, std::map<G4double, G4ParticleHPVector*>*>* theTSInelasticCrossSections{nullptr};
0271
0272 std::map<G4int, std::map<G4double, std::vector<std::pair<G4double, G4double>*>*>*>*
0273 theTSCoherentFinalStates{nullptr};
0274 std::map<G4int, std::map<G4double, std::vector<E_isoAng*>*>*>* theTSIncoherentFinalStates{nullptr};
0275 std::map<G4int, std::map<G4double, std::vector<E_P_E_isoAng*>*>*>* theTSInelasticFinalStates{nullptr};
0276
0277 G4double theMinADBRC{200.};
0278 G4double theMinEnergyDBRC;
0279 G4double theMaxEnergyDBRC;
0280 G4double theMaxEnergyDoppler;
0281
0282 G4String fDataPath[6]{""};
0283
0284 std::vector< std::map< G4int, G4ParticleHPIsoProbabilityTable* > >* theProbabilityTables{nullptr};
0285 std::vector< std::pair< G4double, G4double > >* theURRlimits{nullptr};
0286
0287 };
0288 #endif