File indexing completed on 2025-01-18 09:58:52
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 #ifndef G4ParticleHPIsoData_h
0030 #define G4ParticleHPIsoData_h 1
0031
0032
0033
0034
0035
0036 #include "G4ios.hh"
0037 #include "globals.hh"
0038 #include "G4ParticleHPNames.hh"
0039 #include "G4ParticleHPVector.hh"
0040
0041 class G4ParticleDefinition;
0042
0043 class G4ParticleHPIsoData
0044 {
0045 public:
0046 G4ParticleHPIsoData() = default;
0047
0048 ~G4ParticleHPIsoData() { delete theChannelData; }
0049
0050 inline G4double GetXsec(G4double energy)
0051 {
0052 return std::max(0., theChannelData->GetXsec(energy));
0053 }
0054
0055 G4bool Init(G4int A, G4int Z, G4double abun, G4String dirName, G4String aFSType)
0056 {
0057 return Init(A, Z, 0, abun, dirName, aFSType);
0058 };
0059
0060 G4bool Init(G4int A, G4int Z, G4int M, G4double abun, G4String dirName, G4String aFSType);
0061
0062 void Init(G4int A, G4int Z, G4double abun, G4ParticleDefinition* projectile,
0063 const char* dataDirVariable)
0064 {
0065 Init(A, Z, 0, abun, projectile, dataDirVariable);
0066 }
0067
0068 void Init(G4int A, G4int Z, G4int M, G4double abun, G4ParticleDefinition* projectile,
0069 const char* dataDirVariable);
0070
0071 G4ParticleHPVector* MakeElasticData() { return theElasticData; }
0072 G4ParticleHPVector* MakeFissionData() { return theFissionData; }
0073 G4ParticleHPVector* MakeCaptureData() { return theCaptureData; }
0074 G4ParticleHPVector* MakeInelasticData() { return theInelasticData; }
0075 G4ParticleHPVector* MakeChannelData() { return theChannelData; }
0076
0077 G4String GetName(G4int A, G4int Z, G4String base, G4String rest);
0078
0079 void FillChannelData(G4ParticleHPVector* aBuffer);
0080
0081 void ThinOut(G4double precision)
0082 {
0083 if (theFissionData != nullptr) theFissionData->ThinOut(precision);
0084 if (theCaptureData != nullptr) theCaptureData->ThinOut(precision);
0085 if (theElasticData != nullptr) theElasticData->ThinOut(precision);
0086 if (theInelasticData != nullptr) theInelasticData->ThinOut(precision);
0087 }
0088
0089 G4ParticleHPIsoData& operator=(const G4ParticleHPIsoData& right) = delete;
0090 G4ParticleHPIsoData(const G4ParticleHPIsoData&) = delete;
0091
0092 private:
0093 G4ParticleHPVector* theFissionData{nullptr};
0094 G4ParticleHPVector* theCaptureData{nullptr};
0095 G4ParticleHPVector* theElasticData{nullptr};
0096 G4ParticleHPVector* theInelasticData{nullptr};
0097 G4ParticleHPVector* theChannelData{nullptr};
0098
0099 G4String theFileName;
0100 G4ParticleHPNames theNames;
0101 };
0102
0103 #endif