Geant4 Cross Reference |
1 // 2 // ******************************************************************** 3 // * License and Disclaimer * 4 // * * 5 // * The Geant4 software is copyright of the Copyright Holders of * 6 // * the Geant4 Collaboration. It is provided under the terms and * 7 // * conditions of the Geant4 Software License, included in the file * 8 // * LICENSE and available at http://cern.ch/geant4/license . These * 9 // * include a list of copyright holders. * 10 // * * 11 // * Neither the authors of this software system, nor their employing * 12 // * institutes,nor the agencies providing financial support for this * 13 // * work make any representation or warranty, express or implied, * 14 // * regarding this software system or assume any liability for its * 15 // * use. Please see the license in the file LICENSE and URL above * 16 // * for the full disclaimer and the limitation of liability. * 17 // * * 18 // * This code implementation is the result of the scientific and * 19 // * technical work of the GEANT4 collaboration. * 20 // * By using, copying, modifying or distributing the software (or * 21 // * any work based on the software) you agree to acknowledge its * 22 // * use in resulting scientific publications, and indicate your * 23 // * acceptance of all terms of the Geant4 Software license. * 24 // ******************************************************************** 25 // 26 // Created on 2016/01/18 27 // 28 // Authors: D. Sakata, S. Incerti 29 // 30 // Based on a recent release of the ELSEPA code 31 // developed and provided kindly by F. Salvat et al. 32 // See 33 // Computer Physics Communications, 165(2), 157-190. (2005) 34 // http://dx.doi.org/10.1016/j.cpc.2004.09.006 35 // 36 37 #ifndef G4DNAELSEPAElasticModel_h 38 #define G4DNAELSEPAElasticModel_h 1 39 40 #include <map> 41 #include "G4DNACrossSectionDataSet.hh" 42 #include "G4VEmModel.hh" 43 #include "G4Electron.hh" 44 #include "G4ParticleChangeForGamma.hh" 45 #include "G4LogLogInterpolation.hh" 46 #include "G4ProductionCutsTable.hh" 47 #include "G4NistManager.hh" 48 49 class G4DNAELSEPAElasticModel : public G4VEmModel 50 { 51 52 public: 53 54 G4DNAELSEPAElasticModel(const G4ParticleDefinition* particle = nullptr, 55 const G4String& nam = "DNAELSEPAElasticModel"); 56 57 ~G4DNAELSEPAElasticModel() override; 58 59 G4DNAELSEPAElasticModel & operator=(const G4DNAELSEPAElasticModel &right) = delete; 60 G4DNAELSEPAElasticModel(const G4DNAELSEPAElasticModel&) = delete; 61 62 void Initialise( 63 const G4ParticleDefinition* particle, const G4DataVector&) override; 64 65 G4double CrossSectionPerVolume(const G4Material* material, 66 const G4ParticleDefinition* particle, 67 G4double ekin, 68 G4double emin, 69 G4double emax) override; 70 71 void SampleSecondaries(std::vector<G4DynamicParticle*>*, 72 const G4MaterialCutsCouple*, 73 const G4DynamicParticle*, 74 G4double tmin, 75 G4double maxEnergy) override; 76 77 void SetMaximumEnergy (G4double input) 78 {fhighEnergyLimit = input; SetHighEnergyLimit(input);}; 79 80 void SetKillBelowThreshold (G4double threshold); 81 82 G4double GetKillBelowThreshold() {return fkillBelowEnergy_Au;} 83 84 protected: 85 86 G4ParticleChangeForGamma* fParticleChangeForGamma; 87 88 private: 89 90 const std::vector<G4double>* fpMolDensity=nullptr; 91 std::vector <G4double> kIntersectionEnergySR; 92 93 G4double fkillBelowEnergy_Au=0.; 94 G4double flowEnergyLimit=0.; 95 G4double fhighEnergyLimit=0.; 96 97 G4bool isInitialised=false; 98 G4int verboseLevel=0; 99 100 G4DNACrossSectionDataSet* fpData_Au=nullptr; 101 G4DNACrossSectionDataSet* fpData_H2O=nullptr; 102 103 G4double Theta(G4int Z, G4ParticleDefinition * aParticleDefinition, 104 G4double k, 105 G4double integrDiff); 106 107 G4double LinLinInterpolate(G4double e1, 108 G4double e2, 109 G4double e, 110 G4double xs1, 111 G4double xs2); 112 113 G4double LinLogInterpolate(G4double e1, 114 G4double e2, 115 G4double e, 116 G4double xs1, 117 G4double xs2); 118 119 G4double LogLinInterpolate(G4double e1, 120 G4double e2, 121 G4double e, 122 G4double xs1, 123 G4double xs2); 124 125 G4double LogLogInterpolate(G4double e1, 126 G4double e2, 127 G4double e, 128 G4double xs1, 129 G4double xs2); 130 131 G4double QuadInterpolator(G4double e11, 132 G4double e12, 133 G4double e21, 134 G4double e22, 135 G4double x11, 136 G4double x12, 137 G4double x21, 138 G4double x22, 139 G4double t1, 140 G4double t2, 141 G4double t, 142 G4double e); 143 144 G4double RandomizeCosTheta(G4int Z, G4double k); 145 146 using TriDimensionMapZ = std::map<G4int, std::map<G4double, std::map<G4double, G4double>>>; 147 TriDimensionMapZ fAngleDataZ; 148 149 std::map <G4int, std::vector<G4double> > eEdummyVecZ; 150 151 using VecMap = std::map<G4double, std::vector<G4double>>; 152 VecMap eCum_Au; 153 VecMap eCum_H2O; 154 155 using TriDimensionMap = std::map<G4double, std::map<G4double, G4double>>; 156 TriDimensionMap fAngleData_Au; 157 TriDimensionMap fAngleData_H2O; 158 159 std::vector<G4double> eEdummyVec_Au; 160 std::vector<G4double> eEdummyVec_H2O; 161 162 G4Material* fpBaseWater; 163 164 }; 165 166 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 167 168 #endif 169