00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043 #ifndef G4MuElecInelasticModel_h
00044 #define G4MuElecInelasticModel_h 1
00045
00046
00047 #include "globals.hh"
00048 #include "G4VEmModel.hh"
00049 #include "G4ParticleChangeForGamma.hh"
00050 #include "G4ProductionCutsTable.hh"
00051
00052 #include "G4MuElecCrossSectionDataSet.hh"
00053 #include "G4Electron.hh"
00054 #include "G4Proton.hh"
00055 #include "G4GenericIon.hh"
00056 #include "G4ParticleDefinition.hh"
00057
00058 #include "G4LogLogInterpolation.hh"
00059
00060 #include "G4MuElecSiStructure.hh"
00061 #include "G4VAtomDeexcitation.hh"
00062 #include "G4NistManager.hh"
00063
00064 class G4MuElecInelasticModel : public G4VEmModel
00065 {
00066
00067 public:
00068
00069 G4MuElecInelasticModel(const G4ParticleDefinition* p = 0,
00070 const G4String& nam = "MuElecInelasticModel");
00071
00072 virtual ~G4MuElecInelasticModel();
00073
00074 virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&);
00075
00076 virtual G4double CrossSectionPerVolume( const G4Material* material,
00077 const G4ParticleDefinition* p,
00078 G4double ekin,
00079 G4double emin,
00080 G4double emax);
00081
00082 virtual void SampleSecondaries(std::vector<G4DynamicParticle*>*,
00083 const G4MaterialCutsCouple*,
00084 const G4DynamicParticle*,
00085 G4double tmin,
00086 G4double maxEnergy);
00087
00088 double DifferentialCrossSection(G4ParticleDefinition * aParticleDefinition, G4double k, G4double energyTransfer, G4int shell);
00089
00090 protected:
00091
00092 G4ParticleChangeForGamma* fParticleChangeForGamma;
00093
00094 private:
00095
00096
00097 G4VAtomDeexcitation* fAtomDeexcitation;
00098
00099 G4Material* nistSi;
00100
00101 std::map<G4String,G4double,std::less<G4String> > lowEnergyLimit;
00102 std::map<G4String,G4double,std::less<G4String> > highEnergyLimit;
00103
00104 G4bool isInitialised;
00105 G4int verboseLevel;
00106
00107
00108
00109 typedef std::map<G4String,G4String,std::less<G4String> > MapFile;
00110 MapFile tableFile;
00111
00112 typedef std::map<G4String,G4MuElecCrossSectionDataSet*,std::less<G4String> > MapData;
00113 MapData tableData;
00114
00115
00116
00117 G4MuElecSiStructure SiStructure;
00118
00119 G4double RandomizeEjectedElectronEnergy(G4ParticleDefinition * aParticleDefinition, G4double incomingParticleEnergy, G4int shell) ;
00120
00121 void RandomizeEjectedElectronDirection(G4ParticleDefinition * aParticleDefinition, G4double incomingParticleEnergy, G4double
00122 outgoingParticleEnergy, G4double & cosTheta, G4double & phi );
00123
00124 G4double LogLogInterpolate(G4double e1, G4double e2, G4double e, G4double xs1, G4double xs2);
00125
00126 G4double QuadInterpolator( G4double e11,
00127 G4double e12,
00128 G4double e21,
00129 G4double e22,
00130 G4double x11,
00131 G4double x12,
00132 G4double x21,
00133 G4double x22,
00134 G4double t1,
00135 G4double t2,
00136 G4double t,
00137 G4double e);
00138
00139 typedef std::map<double, std::map<double, double> > TriDimensionMap;
00140 TriDimensionMap eDiffCrossSectionData[7];
00141 TriDimensionMap pDiffCrossSectionData[7];
00142 std::vector<double> eTdummyVec;
00143 std::vector<double> pTdummyVec;
00144
00145 typedef std::map<double, std::vector<double> > VecMap;
00146 VecMap eVecm;
00147 VecMap pVecm;
00148
00149
00150
00151 G4int RandomSelect(G4double energy,const G4String& particle );
00152
00153
00154
00155 G4MuElecInelasticModel & operator=(const G4MuElecInelasticModel &right);
00156 G4MuElecInelasticModel(const G4MuElecInelasticModel&);
00157
00158 };
00159
00160
00161
00162 #endif