Geant4 Cross Reference |
1 // 1 // 2 // ******************************************* 2 // ******************************************************************** 3 // * License and Disclaimer 3 // * License and Disclaimer * 4 // * 4 // * * 5 // * The Geant4 software is copyright of th 5 // * The Geant4 software is copyright of the Copyright Holders of * 6 // * the Geant4 Collaboration. It is provided 6 // * the Geant4 Collaboration. It is provided under the terms and * 7 // * conditions of the Geant4 Software License 7 // * conditions of the Geant4 Software License, included in the file * 8 // * LICENSE and available at http://cern.ch/ 8 // * LICENSE and available at http://cern.ch/geant4/license . These * 9 // * include a list of copyright holders. 9 // * include a list of copyright holders. * 10 // * 10 // * * 11 // * Neither the authors of this software syst 11 // * Neither the authors of this software system, nor their employing * 12 // * institutes,nor the agencies providing fin 12 // * institutes,nor the agencies providing financial support for this * 13 // * work make any representation or warran 13 // * work make any representation or warranty, express or implied, * 14 // * regarding this software system or assum 14 // * regarding this software system or assume any liability for its * 15 // * use. Please see the license in the file 15 // * use. Please see the license in the file LICENSE and URL above * 16 // * for the full disclaimer and the limitatio 16 // * for the full disclaimer and the limitation of liability. * 17 // * 17 // * * 18 // * This code implementation is the result 18 // * This code implementation is the result of the scientific and * 19 // * technical work of the GEANT4 collaboratio 19 // * technical work of the GEANT4 collaboration. * 20 // * By using, copying, modifying or distri 20 // * By using, copying, modifying or distributing the software (or * 21 // * any work based on the software) you ag 21 // * any work based on the software) you agree to acknowledge its * 22 // * use in resulting scientific publicati 22 // * use in resulting scientific publications, and indicate your * 23 // * acceptance of all terms of the Geant4 Sof 23 // * acceptance of all terms of the Geant4 Software license. * 24 // ******************************************* 24 // ******************************************************************** 25 // 25 // 26 // Created by Z. Francis, S. Incerti 2010 << 26 // $Id: G4DNARuddIonisationExtendedModel.hh,v 1.1 2010-11-03 10:44:26 sincerti Exp $ 27 // << 27 // GEANT4 tag $Name: not supported by cvs2svn $ 28 // Modified for inverse rudd function sampling << 29 // Rewitten by V.Ivanchenko 21.05.2023 << 30 // 28 // 31 29 32 #ifndef G4DNARuddIonisationExtendedModel_h 30 #ifndef G4DNARuddIonisationExtendedModel_h 33 #define G4DNARuddIonisationExtendedModel_h 1 31 #define G4DNARuddIonisationExtendedModel_h 1 34 32 35 #include "G4VEmModel.hh" 33 #include "G4VEmModel.hh" 36 #include "G4ParticleChangeForGamma.hh" 34 #include "G4ParticleChangeForGamma.hh" 37 #include "G4ProductionCutsTable.hh" 35 #include "G4ProductionCutsTable.hh" 38 36 39 #include "G4EmCorrections.hh" << 40 #include "G4DNAGenericIonsManager.hh" 37 #include "G4DNAGenericIonsManager.hh" 41 #include "G4DNACrossSectionDataSet.hh" 38 #include "G4DNACrossSectionDataSet.hh" 42 #include "G4Electron.hh" 39 #include "G4Electron.hh" 43 #include "G4Proton.hh" 40 #include "G4Proton.hh" 44 #include "G4LogLogInterpolation.hh" 41 #include "G4LogLogInterpolation.hh" 45 42 46 #include "G4DNAWaterIonisationStructure.hh" << 43 #include "G4WaterIonisationStructure.hh" 47 #include "G4VAtomDeexcitation.hh" 44 #include "G4VAtomDeexcitation.hh" 48 #include "G4NistManager.hh" 45 #include "G4NistManager.hh" 49 #include <vector> << 50 46 51 class G4DNARuddIonisationExtendedModel : publi 47 class G4DNARuddIonisationExtendedModel : public G4VEmModel 52 { 48 { >> 49 53 public: 50 public: 54 51 55 explicit G4DNARuddIonisationExtendedModel(co << 52 G4DNARuddIonisationExtendedModel(const G4ParticleDefinition* p = 0, 56 const G4String& nam = "DNARuddI 53 const G4String& nam = "DNARuddIonisationExtendedModel"); 57 54 58 ~G4DNARuddIonisationExtendedModel() override << 55 virtual ~G4DNARuddIonisationExtendedModel(); 59 56 60 void Initialise(const G4ParticleDefinition*, << 57 virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&); 61 58 62 G4double CrossSectionPerVolume(const G4Mater << 59 virtual G4double CrossSectionPerVolume( const G4Material* material, 63 const G4Parti << 60 const G4ParticleDefinition* p, 64 G4double ekin, << 61 G4double ekin, 65 G4double emin, << 62 G4double emin, 66 G4double emax) override; << 63 G4double emax); 67 << 64 68 void SampleSecondaries(std::vector<G4Dynamic << 65 virtual void SampleSecondaries(std::vector<G4DynamicParticle*>*, 69 const G4MaterialCutsCouple*, << 66 const G4MaterialCutsCouple*, 70 const G4DynamicParticle*, << 67 const G4DynamicParticle*, 71 G4double tmin, << 68 G4double tmin, 72 G4double maxEnergy) override; << 69 G4double maxEnergy); 73 << 74 void SelectStationary(G4bool val) { statCode << 75 << 76 // method for unit tests << 77 G4double ComputeProbabilityFunction(const G4 << 78 G4double << 79 << 80 G4DNARuddIonisationExtendedModel & operator= << 81 (const G4DNARuddIonisationExtendedModel &ri << 82 G4DNARuddIonisationExtendedModel(const G4DNA << 83 70 84 private: << 71 protected: 85 72 86 void LoadData(); << 73 G4ParticleChangeForGamma* fParticleChangeForGamma; 87 << 88 void SetParticle(const G4ParticleDefinition* << 89 74 90 G4int SelectShell(G4double energy); << 75 private: 91 76 92 G4double MaxEnergy(G4double kine, G4int shel << 77 //deexcitation manager to produce fluo photns and e- >> 78 G4VAtomDeexcitation* fAtomDeexcitation; >> 79 G4Material* nistwater; >> 80 >> 81 std::map<G4String,G4double,std::less<G4String> > lowEnergyLimit; >> 82 std::map<G4String,G4double,std::less<G4String> > highEnergyLimit; >> 83 // ZF 26-10-2010 >> 84 std::map<G4double,G4double> lowEnergyLimitForA, lowEnergyLimitOfModelForA, killBelowEnergyForA; 93 85 94 G4double SampleElectronEnergy(G4double kine, << 86 G4bool isInitialised; >> 87 G4int verboseLevel; >> 88 >> 89 // Cross section 95 90 96 G4double ProbabilityFunction(G4double kine, << 91 typedef std::map<G4String,G4String,std::less<G4String> > MapFile; >> 92 MapFile tableFile; 97 93 98 G4double S_1s(G4double t, << 94 typedef std::map<G4String,G4DNACrossSectionDataSet*,std::less<G4String> > MapData; 99 G4double energyTransferred, << 95 MapData tableData; 100 G4double slaterEffectiveChg, << 96 101 G4double shellNumber); << 97 // Final state >> 98 >> 99 G4WaterIonisationStructure waterStructure; 102 100 103 G4double S_2s(G4double t, << 101 G4double RandomizeEjectedElectronEnergy(G4ParticleDefinition* particleDefinition, 104 G4double energyTransferred, << 102 G4double incomingParticleEnergy, 105 G4double slaterEffectiveChg, << 103 G4int shell); >> 104 >> 105 void RandomizeEjectedElectronDirection(G4ParticleDefinition* particleDefinition, >> 106 G4double incomingParticleEnergy, >> 107 G4double outgoingParticleEnergy, >> 108 G4double & cosTheta, >> 109 G4double & phi, G4int shell); >> 110 >> 111 G4double RejectionFunction(G4ParticleDefinition* particle, >> 112 G4double k, >> 113 G4double proposed_ws, >> 114 G4int ionizationLevelIndex); >> 115 >> 116 G4double ProposedSampledEnergy(G4ParticleDefinition* particle, >> 117 G4double k, >> 118 G4int ionizationLevelIndex); >> 119 >> 120 G4double CorrectionFactor(G4ParticleDefinition* particleDefinition, G4double k, G4int shell); >> 121 >> 122 G4double S_1s(G4double t, >> 123 G4double energyTransferred, >> 124 G4double slaterEffectiveChg, 106 G4double shellNumber); 125 G4double shellNumber); 107 126 108 << 127 G4double S_2s(G4double t, 109 G4double S_2p(G4double t, << 128 G4double energyTransferred, 110 G4double energyTransferred, << 129 G4double slaterEffectiveChg, 111 G4double slaterEffectiveChg, << 112 G4double shellNumber); 130 G4double shellNumber); 113 131 114 G4double Rh(G4double t, << 115 G4double energyTransferred, << 116 G4double slaterEffectiveChg, << 117 G4double shellNumber); << 118 << 119 G4double CorrectionFactor(G4double kine, G4i << 120 << 121 protected: << 122 132 123 G4ParticleChangeForGamma* fParticleChangeFor << 133 G4double S_2p(G4double t, >> 134 G4double energyTransferred, >> 135 G4double slaterEffectiveChg, >> 136 G4double shellNumber); 124 137 125 private: << 138 G4double R(G4double t, >> 139 G4double energyTransferred, >> 140 G4double slaterEffectiveChg, >> 141 G4double shellNumber) ; 126 142 127 // idx = 0 - hydrogen << 143 G4double slaterEffectiveCharge[3]; 128 // idx = 1 - proton << 144 G4double sCoefficient[3]; 129 // idx = 2%26 - ions idx=Z << 145 130 // idx = -1 - alpha+ << 146 // Partial cross section 131 // idx = -1 - helium << 147 132 static const G4int RUDDZMAX = 27; << 148 G4double PartialCrossSection(const G4Track& track); 133 static G4DNACrossSectionDataSet* xsdata[RUDD << 149 134 static G4DNACrossSectionDataSet* xsalphaplus << 150 G4double Sum(G4double energy, const G4String& particle); 135 static G4DNACrossSectionDataSet* xshelium; << 151 136 << 152 G4int RandomSelect(G4double energy,const G4String& particle ); 137 // Water density table << 153 138 static const std::vector<G4double>* fpWaterD << 154 // 139 << 155 140 G4DNACrossSectionDataSet* xscurrent{nullptr} << 156 G4DNARuddIonisationExtendedModel & operator=(const G4DNARuddIonisationExtendedModel &right); 141 const G4ParticleDefinition* fParticle{nullpt << 157 G4DNARuddIonisationExtendedModel(const G4DNARuddIonisationExtendedModel&); 142 G4EmCorrections* fEmCorrections; << 143 G4Pow* fGpow; << 144 << 145 //deexcitation manager to produce fluo photo << 146 G4VAtomDeexcitation* fAtomDeexcitation{nullp << 147 << 148 // tracking cut and low-energy limit of prot << 149 G4double fLowestEnergy; << 150 // scaled low-energy limit of ion x-section << 151 G4double fLimitEnergy; << 152 << 153 G4double fMass{0.0}; << 154 G4double fMassRate{1.0}; << 155 G4double fElow{0.0}; << 156 << 157 G4double F1{0.0}; << 158 G4double F2{0.0}; << 159 G4double alphaConst{0.0}; << 160 G4double bEnergy{0.0}; << 161 G4double u{0.0}; << 162 G4double v{0.0}; << 163 G4double wc{0.0}; << 164 << 165 G4double slaterEffectiveCharge[3] = {0.0}; << 166 G4double sCoefficient[3] = {0.0}; << 167 G4double fTemp[5] = {0.0}; << 168 << 169 G4int idx{-1}; << 170 G4int verbose{0}; << 171 << 172 G4bool isInitialised{false}; << 173 G4bool isIon{false}; << 174 G4bool isFirst{false}; << 175 G4bool isHelium{false}; << 176 G4bool statCode{false}; << 177 G4bool useDNAWaterStructure{true}; << 178 158 179 // energy levels of water molecule << 180 G4DNAWaterIonisationStructure waterStructure << 181 }; 159 }; 182 160 183 //....oooOO0OOooo........oooOO0OOooo........oo 161 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 184 162 185 #endif 163 #endif 186 164