Changeset 961 for trunk/source/processes/electromagnetic/standard/include
- Timestamp:
- Apr 6, 2009, 12:21:12 PM (16 years ago)
- Location:
- trunk/source/processes/electromagnetic/standard/include
- Files:
-
- 40 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/processes/electromagnetic/standard/include/G4ASTARStopping.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4ASTARStopping.hh,v 1. 5 2006/06/29 19:49:58 gunterExp $27 // GEANT4 tag $Name: $26 // $Id: G4ASTARStopping.hh,v 1.6 2008/11/13 12:04:37 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 29 29 #ifndef G4ASTARStopping_h … … 86 86 G4double e[74][78], kinE[78]; 87 87 G4double effZ[74]; 88 G4int Znum[74];89 88 }; 90 89 -
trunk/source/processes/electromagnetic/standard/include/G4BetheBlochModel.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4BetheBlochModel.hh,v 1. 9 2007/05/22 17:34:36vnivanch Exp $27 // GEANT4 tag $Name: geant4-09-0 1-patch-02 $26 // $Id: G4BetheBlochModel.hh,v 1.17 2009/02/20 12:06:37 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 45 45 // 12-11-03 Fix for GenericIons (V.Ivanchenko) 46 46 // 24-03-05 Add G4EmCorrections (V.Ivanchenko) 47 // 11-04-05 Major optimisation of internal interfaces (V.Ivan tchenko)47 // 11-04-05 Major optimisation of internal interfaces (V.Ivanchenko) 48 48 // 11-04-04 Move MaxSecondaryEnergy to models (V.Ivanchenko) 49 49 // 11-02-06 ComputeCrossSectionPerElectron, ComputeCrossSectionPerAtom (mma) 50 // 12-08-08 Added methods GetParticleCharge, GetChargeSquareRatio, 51 // CorrectionsAlongStep needed for ions(V.Ivanchenko) 50 52 51 53 // … … 65 67 class G4EmCorrections; 66 68 class G4ParticleChangeForLoss; 69 class G4NistManager; 70 67 71 68 72 class G4BetheBlochModel : public G4VEmModel … … 78 82 virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&); 79 83 80 G4double MinEnergyCut(const G4ParticleDefinition*,81 const G4MaterialCutsCouple*);84 virtual G4double MinEnergyCut(const G4ParticleDefinition*, 85 const G4MaterialCutsCouple*); 82 86 83 87 virtual G4double ComputeCrossSectionPerElectron( … … 105 109 G4double cutEnergy); 106 110 111 virtual G4double GetChargeSquareRatio(const G4ParticleDefinition* p, 112 const G4Material* mat, 113 G4double kineticEnergy); 114 115 virtual G4double GetParticleCharge(const G4ParticleDefinition* p, 116 const G4Material* mat, 117 G4double kineticEnergy); 118 119 virtual void CorrectionsAlongStep(const G4MaterialCutsCouple*, 120 const G4DynamicParticle*, 121 G4double& eloss, 122 G4double& niel, 123 G4double length); 124 107 125 virtual void SampleSecondaries(std::vector<G4DynamicParticle*>*, 108 126 const G4MaterialCutsCouple*, … … 113 131 protected: 114 132 115 G4double MaxSecondaryEnergy(const G4ParticleDefinition*,116 G4double kinEnergy);133 virtual G4double MaxSecondaryEnergy(const G4ParticleDefinition*, 134 G4double kinEnergy); 117 135 118 136 private: … … 125 143 126 144 const G4ParticleDefinition* particle; 145 const G4Material* currentMaterial; 127 146 G4ParticleDefinition* theElectron; 128 147 G4EmCorrections* corr; 129 148 G4ParticleChangeForLoss* fParticleChange; 149 G4NistManager* nist; 130 150 131 151 G4double mass; 132 152 G4double tlimit; 133 153 G4double spin; 154 G4double magMoment2; 134 155 G4double chargeSquare; 135 156 G4double ratio; 157 G4double formfact; 136 158 G4double twoln10; 137 159 G4double bg2lim; 138 160 G4double taulim; 161 G4double corrFactor; 139 162 G4bool isIon; 163 G4bool isInitialised; 140 164 }; 141 165 142 166 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 143 167 144 inline G4double G4BetheBlochModel::MaxSecondaryEnergy(145 const G4ParticleDefinition* pd,146 G4double kinEnergy)147 {148 if(isIon) SetParticle(pd);149 G4double tau = kinEnergy/mass;150 G4double tmax = 2.0*electron_mass_c2*tau*(tau + 2.) /151 (1. + 2.0*(tau + 1.)*ratio + ratio*ratio);152 return std::min(tmax,tlimit);153 }154 155 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....156 157 inline void G4BetheBlochModel::SetParticle(const G4ParticleDefinition* p)158 {159 if(particle != p) {160 particle = p;161 mass = particle->GetPDGMass();162 spin = particle->GetPDGSpin();163 G4double q = particle->GetPDGCharge()/eplus;164 chargeSquare = q*q;165 ratio = electron_mass_c2/mass;166 if(mass > 120.*MeV) tlimit = 51.2*GeV*std::pow(proton_mass_c2/mass,0.66667);167 }168 }169 170 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....171 172 168 #endif -
trunk/source/processes/electromagnetic/standard/include/G4BetheHeitlerModel.hh
r819 r961 25 25 // 26 26 // $Id: G4BetheHeitlerModel.hh,v 1.6 2007/05/22 17:34:36 vnivanch Exp $ 27 // GEANT4 tag $Name: $27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- -
trunk/source/processes/electromagnetic/standard/include/G4BohrFluctuations.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4BohrFluctuations.hh,v 1. 3 2007/09/27 13:53:11vnivanch Exp $27 // GEANT4 tag $Name: $26 // $Id: G4BohrFluctuations.hh,v 1.4 2009/02/19 19:17:50 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 79 79 void InitialiseMe(const G4ParticleDefinition*); 80 80 81 protected:82 83 81 private: 84 82 … … 103 101 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 104 102 105 106 inline G4double G4BohrFluctuations::Dispersion(107 const G4Material* material,108 const G4DynamicParticle* dp,109 G4double& tmax,110 G4double& length)111 {112 if(!particle) InitialiseMe(dp->GetDefinition());113 114 G4double electronDensity = material->GetElectronDensity();115 kineticEnergy = dp->GetKineticEnergy();116 G4double etot = kineticEnergy + particleMass;117 beta2 = kineticEnergy*(kineticEnergy + 2.0*particleMass)/(etot*etot);118 G4double siga = (1.0/beta2 - 0.5) * twopi_mc2_rcl2 * tmax * length119 * electronDensity * chargeSquare;120 121 return siga;122 }123 124 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....125 126 103 #endif 127 104 -
trunk/source/processes/electromagnetic/standard/include/G4BraggIonModel.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4BraggIonModel.hh,v 1. 8 2007/05/22 17:34:36vnivanch Exp $27 // GEANT4 tag $Name: $26 // $Id: G4BraggIonModel.hh,v 1.12 2009/02/20 12:06:37 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 43 43 // 15-02-06 ComputeCrossSectionPerElectron, ComputeCrossSectionPerAtom (mma) 44 44 // 25-04-06 Add stopping data from ASTAR (V.Ivanchenko) 45 // 12-08-08 Added methods GetParticleCharge, GetChargeSquareRatio, 46 // CorrectionsAlongStep needed for ions(V.Ivanchenko) 45 47 46 48 // … … 48 50 // 49 51 // Implementation of energy loss and delta-electron production 50 // by heavy slow charged particles using eveluated data 52 // by heavy slow charged particles using ICRU'49 and NIST evaluated data 53 // for He4 ions 51 54 52 55 // ------------------------------------------------------------------- … … 60 63 61 64 class G4ParticleChangeForLoss; 65 class G4EmCorrections; 62 66 63 67 class G4BraggIonModel : public G4VEmModel … … 73 77 virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&); 74 78 75 G4double MinEnergyCut(const G4ParticleDefinition*,76 const G4MaterialCutsCouple*);79 virtual G4double MinEnergyCut(const G4ParticleDefinition*, 80 const G4MaterialCutsCouple*); 77 81 78 82 virtual G4double ComputeCrossSectionPerElectron( … … 106 110 G4double maxEnergy); 107 111 112 // Compute ion charge 113 virtual G4double GetChargeSquareRatio(const G4ParticleDefinition*, 114 const G4Material*, 115 G4double kineticEnergy); 116 117 virtual G4double GetParticleCharge(const G4ParticleDefinition* p, 118 const G4Material* mat, 119 G4double kineticEnergy); 120 121 // add correction to energy loss and ompute non-ionizing energy loss 122 virtual void CorrectionsAlongStep(const G4MaterialCutsCouple*, 123 const G4DynamicParticle*, 124 G4double& eloss, 125 G4double& niel, 126 G4double length); 127 108 128 protected: 109 129 110 G4double MaxSecondaryEnergy(const G4ParticleDefinition*,111 G4double kinEnergy);130 virtual G4double MaxSecondaryEnergy(const G4ParticleDefinition*, 131 G4double kinEnergy); 112 132 113 133 private: … … 133 153 G4double DEDX(const G4Material* material, G4double kineticEnergy); 134 154 155 G4EmCorrections* corr; 156 135 157 const G4ParticleDefinition* particle; 136 158 G4ParticleDefinition* theElectron; … … 144 166 G4double massRate; 145 167 G4double ratio; 146 G4double highKinEnergy;147 G4double lowKinEnergy;148 168 G4double lowestKinEnergy; 149 169 G4double HeMass; 150 170 G4double massFactor; 171 G4double corrFactor; 151 172 G4double rateMassHe2p; 152 173 G4double theZieglerFactor; … … 154 175 G4int iMolecula; // index in the molecula's table 155 176 G4bool isIon; 177 G4bool isInitialised; 156 178 }; 157 158 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......159 160 inline G4double G4BraggIonModel::MaxSecondaryEnergy(161 const G4ParticleDefinition* pd,162 G4double kinEnergy)163 {164 if(pd != particle) SetParticle(pd);165 G4double tau = kinEnergy/mass;166 G4double tmax = 2.0*electron_mass_c2*tau*(tau + 2.) /167 (1. + 2.0*(tau + 1.)*ratio + ratio*ratio);168 return tmax;169 }170 179 171 180 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... -
trunk/source/processes/electromagnetic/standard/include/G4BraggModel.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4BraggModel.hh,v 1.1 0 2007/05/22 17:34:36vnivanch Exp $27 // GEANT4 tag $Name: $26 // $Id: G4BraggModel.hh,v 1.13 2009/02/20 12:06:37 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 45 45 // 11-04-05 Major optimisation of internal interfaces (V.Ivantchenko) 46 46 // 15-02-06 ComputeCrossSectionPerElectron, ComputeCrossSectionPerAtom (mma) 47 // 25-04-06 Add stopping data from PSTAR (V.Ivanchenko) 47 // 25-04-06 Added stopping data from PSTAR (V.Ivanchenko) 48 // 12-08-08 Added methods GetParticleCharge, GetChargeSquareRatio, 49 // CorrectionsAlongStep needed for ions(V.Ivanchenko) 48 50 49 51 // … … 51 53 // 52 54 // Implementation of energy loss and delta-electron production 53 // by heavy slow charged particles using eveluated data 55 // by heavy slow charged particles using ICRU'49 and NIST evaluated data 56 // for protons 54 57 55 58 // ------------------------------------------------------------------- … … 63 66 64 67 class G4ParticleChangeForLoss; 68 class G4EmCorrections; 65 69 66 70 class G4BraggModel : public G4VEmModel … … 76 80 virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&); 77 81 78 G4double MinEnergyCut(const G4ParticleDefinition*,79 const G4MaterialCutsCouple*);82 virtual G4double MinEnergyCut(const G4ParticleDefinition*, 83 const G4MaterialCutsCouple*); 80 84 81 85 virtual G4double ComputeCrossSectionPerElectron( … … 109 113 G4double maxEnergy); 110 114 115 // Compute ion charge 116 virtual G4double GetChargeSquareRatio(const G4ParticleDefinition*, 117 const G4Material*, 118 G4double kineticEnergy); 119 120 virtual G4double GetParticleCharge(const G4ParticleDefinition* p, 121 const G4Material* mat, 122 G4double kineticEnergy); 123 124 // add correction to energy loss and compute non-ionizing energy loss 125 virtual void CorrectionsAlongStep(const G4MaterialCutsCouple*, 126 const G4DynamicParticle*, 127 G4double& eloss, 128 G4double& niel, 129 G4double length); 130 111 131 protected: 112 132 113 G4double MaxSecondaryEnergy(const G4ParticleDefinition*,114 G4double kinEnergy);133 virtual G4double MaxSecondaryEnergy(const G4ParticleDefinition*, 134 G4double kinEnergy); 115 135 116 136 private: 117 137 118 void SetParticle(const G4ParticleDefinition* p);138 inline void SetParticle(const G4ParticleDefinition* p); 119 139 120 140 G4bool HasMaterial(const G4Material* material); … … 139 159 G4BraggModel & operator=(const G4BraggModel &right); 140 160 G4BraggModel(const G4BraggModel&); 161 162 163 G4EmCorrections* corr; 141 164 142 165 const G4ParticleDefinition* particle; … … 150 173 G4double massRate; 151 174 G4double ratio; 152 G4double highKinEnergy;153 G4double lowKinEnergy;154 175 G4double lowestKinEnergy; 155 176 G4double protonMassAMU; … … 159 180 G4int iMolecula; // index in the molecula's table 160 181 G4bool isIon; 182 G4bool isInitialised; 161 183 }; 162 163 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......164 165 inline G4double G4BraggModel::MaxSecondaryEnergy(166 const G4ParticleDefinition* pd,167 G4double kinEnergy)168 {169 if(pd != particle) SetParticle(pd);170 G4double tau = kinEnergy/mass;171 G4double tmax = 2.0*electron_mass_c2*tau*(tau + 2.) /172 (1. + 2.0*(tau + 1.)*ratio + ratio*ratio);173 return tmax;174 }175 184 176 185 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... -
trunk/source/processes/electromagnetic/standard/include/G4ComptonScattering.hh
r819 r961 25 25 // 26 26 // 27 // $Id: G4ComptonScattering.hh,v 1.2 0 2007/05/23 08:47:34vnivanch Exp $28 // GEANT4 tag $Name: $27 // $Id: G4ComptonScattering.hh,v 1.21 2009/02/20 12:06:37 vnivanch Exp $ 28 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 29 29 // 30 30 //------------------ G4ComptonScattering physics process ----------------------- … … 82 82 83 83 // true for Gamma only. 84 G4bool IsApplicable(const G4ParticleDefinition&);84 virtual G4bool IsApplicable(const G4ParticleDefinition&); 85 85 86 86 // Print few lines of informations about the process: validity range, 87 87 virtual void PrintInfo(); 88 89 88 90 89 protected: … … 97 96 }; 98 97 99 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....100 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....101 102 inline103 G4bool G4ComptonScattering::IsApplicable(const G4ParticleDefinition& p)104 {105 return (&p == G4Gamma::Gamma());106 }107 108 98 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 109 99 -
trunk/source/processes/electromagnetic/standard/include/G4ComptonScattering52.hh
r819 r961 26 26 // 27 27 // $Id: G4ComptonScattering52.hh,v 1.4 2007/05/16 14:00:56 vnivanch Exp $ 28 // GEANT4 tag $Name: $28 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 29 29 // 30 30 //------------------ G4ComptonScattering52 physics process ----------------------- -
trunk/source/processes/electromagnetic/standard/include/G4CoulombScattering.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4CoulombScattering.hh,v 1. 8 2007/07/31 17:24:04vnivanch Exp $27 // GEANT4 tag $Name: $26 // $Id: G4CoulombScattering.hh,v 1.12 2009/02/20 12:06:37 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 65 65 virtual G4bool IsApplicable(const G4ParticleDefinition& p); 66 66 67 void SetThetaMin(G4double);67 inline void SetThetaMin(G4double); 68 68 69 void SetThetaMax(G4double);69 inline void SetThetaMax(G4double); 70 70 71 void SetQ2Max(G4double); 71 inline void SetQ2Max(G4double); 72 73 // Set energy above which high energy model will be used 74 inline void SetHEModelLimit(G4double); 72 75 73 76 // obsolete method to be removed 74 void SetBuildTableFlag(G4bool);77 inline void SetBuildTableFlag(G4bool); 75 78 76 79 // Print out of the class parameters … … 101 104 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 102 105 103 inline G4bool G4CoulombScattering::IsApplicable(const G4ParticleDefinition& p)104 {105 return (p.GetPDGCharge() != 0.0 && !p.IsShortLived());106 }107 108 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....109 110 106 inline void G4CoulombScattering::SetThetaMin(G4double val) 111 107 { … … 132 128 {} 133 129 130 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 131 132 inline void G4CoulombScattering::SetHEModelLimit(G4double val) 133 { 134 thEnergy = val; 135 thEnergyElec = val; 136 } 137 134 138 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 135 139 -
trunk/source/processes/electromagnetic/standard/include/G4CoulombScatteringModel.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4CoulombScatteringModel.hh,v 1.1 1 2007/10/09 08:16:29vnivanch Exp $27 // GEANT4 tag $Name: geant4-09-0 1-patch-02 $26 // $Id: G4CoulombScatteringModel.hh,v 1.15 2008/07/31 13:11:34 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 44 44 // 19.10.06 V.Ivanchenko use inheritance from G4eCoulombScatteringModel 45 45 // 09.10.07 V.Ivanchenko reorganized methods, add cut dependence in scattering off e- 46 // 09.06.08 V.Ivanchenko SelectIsotope is moved to the base class 46 47 // 47 48 // Class Description: … … 64 65 #include "globals.hh" 65 66 66 class G4ParticleTable;67 class G4NistManager;68 69 67 class G4CoulombScatteringModel : public G4eCoulombScatteringModel 70 68 { … … 72 70 public: 73 71 74 G4CoulombScatteringModel(G4double thetaMin = 0.0, G4double thetaMax = pi, 75 G4bool build = false, G4double tlim = TeV*TeV, 76 const G4String& nam = "CoulombScattering"); 72 G4CoulombScatteringModel(const G4String& nam = "CoulombScattering"); 77 73 78 74 virtual ~G4CoulombScatteringModel(); … … 94 90 private: 95 91 96 G4double SelectIsotope(const G4Element*);97 98 92 // hide assignment operator 99 93 G4CoulombScatteringModel & operator=(const G4CoulombScatteringModel &right); 100 94 G4CoulombScatteringModel(const G4CoulombScatteringModel&); 101 95 102 G4ParticleTable* theParticleTable;103 const G4NistManager* theMatManager;104 96 }; 105 97 -
trunk/source/processes/electromagnetic/standard/include/G4GammaConversion.hh
r819 r961 25 25 // 26 26 // 27 // $Id: G4GammaConversion.hh,v 1.2 2 2007/05/23 08:47:34vnivanch Exp $28 // GEANT4 tag $Name: $27 // $Id: G4GammaConversion.hh,v 1.23 2009/02/20 12:06:37 vnivanch Exp $ 28 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 29 29 // 30 30 // … … 85 85 86 86 // true for Gamma only. 87 G4bool IsApplicable(const G4ParticleDefinition&);87 virtual G4bool IsApplicable(const G4ParticleDefinition&); 88 88 89 89 // Print few lines of informations about the process: validity range, … … 99 99 }; 100 100 101 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....102 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....103 104 inline G4bool G4GammaConversion::IsApplicable(const G4ParticleDefinition& p)105 {106 return (&p == G4Gamma::Gamma());107 }108 109 101 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 110 102 -
trunk/source/processes/electromagnetic/standard/include/G4InitXscPAI.hh
r819 r961 26 26 // 27 27 // $Id: G4InitXscPAI.hh,v 1.8 2006/06/29 19:50:22 gunter Exp $ 28 // GEANT4 tag $Name: $28 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 29 29 // 30 30 // -
trunk/source/processes/electromagnetic/standard/include/G4IonFluctuations.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4IonFluctuations.hh,v 1. 3 2007/09/27 13:53:11vnivanch Exp $27 // GEANT4 tag $Name: $26 // $Id: G4IonFluctuations.hh,v 1.9 2009/02/19 19:17:50 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 41 41 // 42 42 // 16-10-03 Changed interface to Initialisation (V.Ivanchenko) 43 // 01-06-08 Added initialisation of effective charge prestep (V.Ivanchenko) 43 44 // 44 45 // Class Description: … … 54 55 55 56 #include "G4VEmFluctuationModel.hh" 57 #include "G4ParticleDefinition.hh" 58 #include "G4UniversalFluctuation.hh" 56 59 57 60 class G4IonFluctuations : public G4VEmFluctuationModel … … 64 67 virtual ~G4IonFluctuations(); 65 68 69 // Sample fluctuations 66 70 G4double SampleFluctuations(const G4Material*, 67 71 const G4DynamicParticle*, 68 G4double&,69 G4double&,70 G4double&);72 G4double& tmax, 73 G4double& length, 74 G4double& meanLoss); 71 75 72 G4double Dispersion( const G4Material*, 73 const G4DynamicParticle*, 74 G4double&, 75 G4double&); 76 // Compute dispertion 77 G4double Dispersion(const G4Material*, 78 const G4DynamicParticle*, 79 G4double& tmax, 80 G4double& length); 76 81 82 // Initialisation prerun 77 83 void InitialiseMe(const G4ParticleDefinition*); 84 85 // Initialisation prestep 86 void SetParticleAndCharge(const G4ParticleDefinition*, G4double q2); 78 87 79 88 private: 80 89 81 G4double CoeffitientA(G4double&); 82 G4double CoeffitientB(const G4Material*, G4double&); 83 G4double RelativisticFactor(const G4Material*, G4double&); 90 G4double Factor(const G4Material*, G4double Zeff); 91 G4double RelativisticFactor(const G4Material*, G4double Zeff); 84 92 85 93 // hide assignment operator … … 87 95 G4IonFluctuations(const G4IonFluctuations&); 88 96 97 G4UniversalFluctuation uniFluct; 89 98 const G4ParticleDefinition* particle; 90 99 … … 92 101 G4double charge; 93 102 G4double chargeSquare; 94 G4double chargeSqRatio;103 G4double effChargeSquare; 95 104 96 105 // data members to speed up the fluctuation calculation 106 G4double parameter; 97 107 G4double minNumberInteractionsBohr; 98 108 G4double theBohrBeta2; -
trunk/source/processes/electromagnetic/standard/include/G4KleinNishinaCompton.hh
r819 r961 25 25 // 26 26 // $Id: G4KleinNishinaCompton.hh,v 1.9 2007/05/22 17:34:36 vnivanch Exp $ 27 // GEANT4 tag $Name: $27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- -
trunk/source/processes/electromagnetic/standard/include/G4MollerBhabhaModel.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4MollerBhabhaModel.hh,v 1. 19 2007/05/22 17:34:36vnivanch Exp $27 // GEANT4 tag $Name: $26 // $Id: G4MollerBhabhaModel.hh,v 1.20 2009/02/20 12:06:37 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 74 74 virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&); 75 75 76 G4double MinEnergyCut(const G4ParticleDefinition*,77 const G4MaterialCutsCouple*);76 virtual G4double MinEnergyCut(const G4ParticleDefinition*, 77 const G4MaterialCutsCouple*); 78 78 79 79 virtual G4double ComputeCrossSectionPerElectron( … … 109 109 protected: 110 110 111 G4double MaxSecondaryEnergy(const G4ParticleDefinition*,112 G4double kinEnergy);111 virtual G4double MaxSecondaryEnergy(const G4ParticleDefinition*, 112 G4double kinEnergy); 113 113 114 void SetParticle(const G4ParticleDefinition* p);114 inline void SetParticle(const G4ParticleDefinition* p); 115 115 116 116 const G4ParticleDefinition* particle; … … 127 127 G4MollerBhabhaModel & operator=(const G4MollerBhabhaModel &right); 128 128 G4MollerBhabhaModel(const G4MollerBhabhaModel&); 129 130 G4bool isInitialised; 131 129 132 }; 130 133 131 134 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 132 135 133 inline G4double G4MollerBhabhaModel::MaxSecondaryEnergy( 134 const G4ParticleDefinition*, 135 G4double kinEnergy) 136 inline void G4MollerBhabhaModel::SetParticle(const G4ParticleDefinition* p) 136 137 { 137 G4double tmax = kinEnergy; 138 if(isElectron) tmax *= 0.5; 139 return tmax; 138 particle = p; 139 if(p != theElectron) isElectron = false; 140 140 } 141 141 -
trunk/source/processes/electromagnetic/standard/include/G4MscModel71.hh
r819 r961 25 25 // 26 26 // $Id: G4MscModel71.hh,v 1.5 2007/05/22 17:34:36 vnivanch Exp $ 27 // GEANT4 tag $Name: $27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- -
trunk/source/processes/electromagnetic/standard/include/G4MultipleScattering.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4MultipleScattering.hh,v 1.3 5 2007/05/18 18:43:32vnivanch Exp $27 // GEANT4 tag $Name: geant4-09-0 1-patch-02 $26 // $Id: G4MultipleScattering.hh,v 1.36 2008/03/10 10:39:21 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ----------------------------------------------------------------------------- … … 100 100 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 101 101 102 class G4 UrbanMscModel;102 class G4VMscModel; 103 103 104 104 class G4MultipleScattering : public G4VMultipleScattering … … 133 133 private: // data members 134 134 135 G4 UrbanMscModel* mscUrban;135 G4VMscModel* mscUrban; 136 136 137 137 G4double lambdalimit; -
trunk/source/processes/electromagnetic/standard/include/G4MultipleScattering71.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4MultipleScattering71.hh,v 1. 5 2007/05/22 17:34:36vnivanch Exp $27 // GEANT4 tag $Name: $26 // $Id: G4MultipleScattering71.hh,v 1.6 2008/07/16 11:27:41 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // … … 58 58 //------------------------------------------------------------------------------ 59 59 // 60 // $Id: G4MultipleScattering71.hh,v 1. 5 2007/05/22 17:34:36vnivanch Exp $61 // GEANT4 tag $Name: $60 // $Id: G4MultipleScattering71.hh,v 1.6 2008/07/16 11:27:41 vnivanch Exp $ 61 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 62 62 63 63 // class description … … 180 180 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 181 181 182 inline G4double G4MultipleScattering71::GetContinuousStepLimit(183 const G4Track& track,184 G4double,185 G4double currentMinimalStep,186 G4double&)187 {188 DefineMaterial(track.GetMaterialCutsCouple());189 const G4MaterialCutsCouple* couple = CurrentMaterialCutsCouple();190 G4double e = track.GetKineticEnergy();191 model = dynamic_cast<G4MscModel71*>(SelectModel(e));192 const G4ParticleDefinition* p = track.GetDefinition();193 G4double lambda0 = GetLambda(p, e);194 range = G4LossTableManager::Instance()->GetRangeFromRestricteDEDX(p,e,couple);195 if(range < currentMinimalStep) currentMinimalStep = range;196 truePathLength = TruePathLengthLimit(track,lambda0,currentMinimalStep);197 // G4cout << "StepLimit: tpl= " << truePathLength << " lambda0= "198 // << lambda0 << " range= " << currentRange199 // << " currentMinStep= " << currentMinimalStep << G4endl;200 if (truePathLength < currentMinimalStep) valueGPILSelectionMSC = CandidateForSelection;201 geomPathLength = model->GeomPathLength(LambdaTable(),couple,202 p,e,lambda0,range,truePathLength);203 if(geomPathLength > lambda0) geomPathLength = lambda0;204 return geomPathLength;205 }206 207 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....208 209 182 inline G4VParticleChange* G4MultipleScattering71::AlongStepDoIt( 210 183 const G4Track&, -
trunk/source/processes/electromagnetic/standard/include/G4PAIModel.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4PAIModel.hh,v 1.22 2009/02/19 19:17:50 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 26 28 // 27 29 // ------------------------------------------------------------------- … … 75 77 virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&); 76 78 77 virtual void InitialiseMe(const G4ParticleDefinition*) {};78 79 virtual G4double ComputeDEDX (const G4MaterialCutsCouple*,79 virtual void InitialiseMe(const G4ParticleDefinition*); 80 81 virtual G4double ComputeDEDXPerVolume(const G4Material*, 80 82 const G4ParticleDefinition*, 81 83 G4double kineticEnergy, 82 84 G4double cutEnergy); 83 85 84 virtual G4double CrossSection (const G4MaterialCutsCouple*,86 virtual G4double CrossSectionPerVolume(const G4Material*, 85 87 const G4ParticleDefinition*, 86 88 G4double kineticEnergy, … … 118 120 119 121 void SetVerboseLevel(G4int verbose){fVerbose=verbose;}; 120 121 122 122 123 123 protected: … … 192 192 }; 193 193 194 /////////////////////////////////////////////////////////////////////195 196 inline G4double G4PAIModel::MaxSecondaryEnergy( const G4ParticleDefinition* p,197 G4double kinEnergy)198 {199 G4double tmax = kinEnergy;200 if(p == fElectron) tmax *= 0.5;201 else if(p != fPositron) {202 G4double mass = p->GetPDGMass();203 G4double ratio= electron_mass_c2/mass;204 G4double gamma= kinEnergy/mass + 1.0;205 tmax = 2.0*electron_mass_c2*(gamma*gamma - 1.) /206 (1. + 2.0*gamma*ratio + ratio*ratio);207 }208 return tmax;209 }210 211 ///////////////////////////////////////////////////////////////212 213 inline void G4PAIModel::DefineForRegion(const G4Region* r)214 {215 fPAIRegionVector.push_back(r);216 }217 218 194 #endif 219 195 -
trunk/source/processes/electromagnetic/standard/include/G4PAIPhotonModel.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4PAIPhotonModel.hh,v 1.12 2009/02/19 19:17:50 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 26 28 // 27 29 // ------------------------------------------------------------------- … … 68 70 public: 69 71 70 G4PAIPhotonModel(const G4ParticleDefinition* p = 0, const G4String& nam = "PAI ");72 G4PAIPhotonModel(const G4ParticleDefinition* p = 0, const G4String& nam = "PAIPhoton"); 71 73 72 74 virtual ~G4PAIPhotonModel(); … … 74 76 virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&); 75 77 76 virtual void InitialiseMe(const G4ParticleDefinition*) {};77 78 virtual G4double ComputeDEDX (const G4MaterialCutsCouple*,79 80 81 82 83 virtual G4double CrossSection (const G4MaterialCutsCouple*,84 const G4ParticleDefinition*,85 G4double kineticEnergy,86 G4double cutEnergy,87 G4double maxEnergy);78 virtual void InitialiseMe(const G4ParticleDefinition*); 79 80 virtual G4double ComputeDEDXPerVolume(const G4Material*, 81 const G4ParticleDefinition*, 82 G4double kineticEnergy, 83 G4double cutEnergy); 84 85 virtual G4double CrossSectionPerVolume(const G4Material*, 86 const G4ParticleDefinition*, 87 G4double kineticEnergy, 88 G4double cutEnergy, 89 G4double maxEnergy); 88 90 89 91 virtual void SampleSecondaries(std::vector<G4DynamicParticle*>*, … … 122 124 G4double position, G4int iTransfer ); 123 125 124 125 126 126 protected: 127 127 128 128 G4double MaxSecondaryEnergy(const G4ParticleDefinition*, 129 129 G4double kinEnergy); 130 130 131 131 private: … … 145 145 G4int fVerbose; 146 146 G4PhysicsLogVector* fProtonEnergyVector ; 147 148 149 147 150 148 // vectors … … 204 202 }; 205 203 206 /////////////////////////////////////////////////////////////////////207 208 inline G4double G4PAIPhotonModel::MaxSecondaryEnergy( const G4ParticleDefinition* p,209 G4double kinEnergy)210 {211 G4double tmax = kinEnergy;212 if(p == fElectron) tmax *= 0.5;213 else if(p != fPositron) {214 G4double mass = p->GetPDGMass();215 G4double ratio= electron_mass_c2/mass;216 G4double gamma= kinEnergy/mass + 1.0;217 tmax = 2.0*electron_mass_c2*(gamma*gamma - 1.) /218 (1. + 2.0*gamma*ratio + ratio*ratio);219 }220 return tmax;221 }222 223 ///////////////////////////////////////////////////////////////224 225 inline void G4PAIPhotonModel::DefineForRegion(const G4Region* r)226 {227 fPAIRegionVector.push_back(r);228 }229 230 204 #endif 231 205 -
trunk/source/processes/electromagnetic/standard/include/G4PAIxSection.hh
r819 r961 25 25 // 26 26 // 27 // $Id: G4PAIxSection.hh,v 1.1 2 2006/06/29 19:50:44 gunterExp $28 // GEANT4 tag $Name: $27 // $Id: G4PAIxSection.hh,v 1.15 2008/05/30 16:04:40 grichine Exp $ 28 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 29 29 // 30 30 // … … 74 74 75 75 G4PAIxSection( G4int materialIndex, 76 G4double maxEnergyTransfer ) 76 G4double maxEnergyTransfer ); 77 77 78 78 G4PAIxSection( G4int materialIndex, // for proton loss table 79 79 G4double maxEnergyTransfer, 80 80 G4double betaGammaSq , 81 G4double** photoAbsCof, G4int intNumber ) 81 G4double** photoAbsCof, G4int intNumber ); 82 82 83 83 G4PAIxSection( G4int materialIndex, // test constructor 84 84 G4double maxEnergyTransfer, 85 G4double betaGammaSq ) 86 87 // G4PAIxSection(const G4PAIxSection& right) 85 G4double betaGammaSq ); 86 87 // G4PAIxSection(const G4PAIxSection& right); 88 88 89 89 // Destructor 90 90 91 ~G4PAIxSection() 91 ~G4PAIxSection(); 92 92 93 93 // Operators 94 // G4PAIxSection& operator=(const G4PAIxSection& right) 95 // G4int operator==(const G4PAIxSection& right)const 96 // G4int operator!=(const G4PAIxSection& right)const 94 // G4PAIxSection& operator=(const G4PAIxSection& right); 95 // G4int operator==(const G4PAIxSection& right)const; 96 // G4int operator!=(const G4PAIxSection& right)const; 97 97 98 98 // Methods … … 100 100 // General control functions 101 101 102 void InitPAI() 103 104 void NormShift( G4double betaGammaSq ) 105 106 void SplainPAI( G4double betaGammaSq ) 102 void InitPAI(); 103 104 void NormShift( G4double betaGammaSq ); 105 106 void SplainPAI( G4double betaGammaSq ); 107 107 108 108 // Physical methods … … 111 111 G4double RutherfordIntegral( G4int intervalNumber, 112 112 G4double limitLow, 113 G4double limitHigh ) 113 G4double limitHigh ); 114 114 115 115 G4double ImPartDielectricConst( G4int intervalNumber, 116 G4double energy ) ; 117 118 G4double RePartDielectricConst(G4double energy) ; 116 G4double energy ); 117 118 G4double GetPhotonRange( G4double energy ); 119 G4double GetElectronRange( G4double energy ); 120 121 G4double RePartDielectricConst(G4double energy); 119 122 120 123 G4double DifPAIxSection( G4int intervalNumber, 121 G4double betaGammaSq ) 124 G4double betaGammaSq ); 122 125 123 126 G4double PAIdNdxCerenkov( G4int intervalNumber, 124 G4double betaGammaSq ) ; 127 G4double betaGammaSq ); 128 G4double PAIdNdxMM( G4int intervalNumber, 129 G4double betaGammaSq ); 125 130 126 131 G4double PAIdNdxPlasmon( G4int intervalNumber, 127 G4double betaGammaSq ) ; 128 129 void IntegralPAIxSection() ; 130 void IntegralCerenkov() ; 131 void IntegralPlasmon() ; 132 133 G4double SumOverInterval(G4int intervalNumber) ; 134 G4double SumOverIntervaldEdx(G4int intervalNumber) ; 135 G4double SumOverInterCerenkov(G4int intervalNumber) ; 136 G4double SumOverInterPlasmon(G4int intervalNumber) ; 132 G4double betaGammaSq ); 133 134 G4double PAIdNdxResonance( G4int intervalNumber, 135 G4double betaGammaSq ); 136 137 void IntegralPAIxSection(); 138 void IntegralCerenkov(); 139 void IntegralMM(); 140 void IntegralPlasmon(); 141 void IntegralResonance(); 142 143 G4double SumOverInterval(G4int intervalNumber); 144 G4double SumOverIntervaldEdx(G4int intervalNumber); 145 G4double SumOverInterCerenkov(G4int intervalNumber); 146 G4double SumOverInterMM(G4int intervalNumber); 147 G4double SumOverInterPlasmon(G4int intervalNumber); 148 G4double SumOverInterResonance(G4int intervalNumber); 137 149 138 150 G4double SumOverBorder( G4int intervalNumber, 139 G4double energy ) 151 G4double energy ); 140 152 G4double SumOverBorderdEdx( G4int intervalNumber, 141 G4double energy ) 153 G4double energy ); 142 154 G4double SumOverBordCerenkov( G4int intervalNumber, 143 G4double energy ) ; 155 G4double energy ); 156 G4double SumOverBordMM( G4int intervalNumber, 157 G4double energy ); 144 158 G4double SumOverBordPlasmon( G4int intervalNumber, 145 G4double energy ) ; 146 147 G4double GetStepEnergyLoss( G4double step ) ; 148 G4double GetStepCerenkovLoss( G4double step ) ; 149 G4double GetStepPlasmonLoss( G4double step ) ; 159 G4double energy ); 160 G4double SumOverBordResonance( G4int intervalNumber, 161 G4double energy ); 162 163 G4double GetStepEnergyLoss( G4double step ); 164 G4double GetStepCerenkovLoss( G4double step ); 165 G4double GetStepMMLoss( G4double step ); 166 G4double GetStepPlasmonLoss( G4double step ); 167 G4double GetStepResonanceLoss( G4double step ); 168 169 G4double GetEnergyTransfer(); 170 G4double GetCerenkovEnergyTransfer(); 171 G4double GetMMEnergyTransfer(); 172 G4double GetPlasmonEnergyTransfer(); 173 G4double GetResonanceEnergyTransfer(); 174 G4double GetRutherfordEnergyTransfer(); 150 175 151 176 // Inline access functions 152 177 153 G4int GetNumberOfGammas() const { return fNumberOfGammas ; } 154 155 G4int GetSplineSize() const { return fSplineNumber ; } 156 157 G4int GetIntervalNumber() const { return fIntervalNumber ; } 158 159 G4double GetEnergyInterval(G4int i){ return fEnergyInterval[i] ; } 160 161 G4double GetDifPAIxSection(G4int i){ return fDifPAIxSection[i] ; } 162 G4double GetPAIdNdxCrenkov(G4int i){ return fdNdxCerenkov[i] ; } 163 G4double GetPAIdNdxPlasmon(G4int i){ return fdNdxPlasmon[i] ; } 164 165 G4double GetMeanEnergyLoss() const {return fIntegralPAIxSection[0] ; } 166 G4double GetMeanCerenkovLoss() const {return fIntegralCerenkov[0] ; } 167 G4double GetMeanPlasmonLoss() const {return fIntegralPlasmon[0] ; } 168 169 G4double GetNormalizationCof() const { return fNormalizationCof ; } 178 G4int GetNumberOfGammas() const { return fNumberOfGammas; } 179 180 G4int GetSplineSize() const { return fSplineNumber; } 181 182 G4int GetIntervalNumber() const { return fIntervalNumber; } 183 184 G4double GetEnergyInterval(G4int i){ return fEnergyInterval[i]; } 185 186 G4double GetDifPAIxSection(G4int i){ return fDifPAIxSection[i]; } 187 G4double GetPAIdNdxCerenkov(G4int i){ return fdNdxCerenkov[i]; } 188 G4double GetPAIdNdxMM(G4int i){ return fdNdxMM[i]; } 189 G4double GetPAIdNdxPlasmon(G4int i){ return fdNdxPlasmon[i]; } 190 G4double GetPAIdNdxResonance(G4int i){ return fdNdxResonance[i]; } 191 192 G4double GetMeanEnergyLoss() const {return fIntegralPAIxSection[0]; } 193 G4double GetMeanCerenkovLoss() const {return fIntegralCerenkov[0]; } 194 G4double GetMeanMMLoss() const {return fIntegralMM[0]; } 195 G4double GetMeanPlasmonLoss() const {return fIntegralPlasmon[0]; } 196 G4double GetMeanResonanceLoss() const {return fIntegralResonance[0]; } 197 198 G4double GetNormalizationCof() const { return fNormalizationCof; } 170 199 171 inline G4double GetPAItable(G4int i,G4int j) const 172 173 inline G4double GetLorentzFactor(G4int i) const;200 inline G4double GetPAItable(G4int i,G4int j) const; 201 202 inline G4double GetLorentzFactor(G4int i) const; 174 203 175 inline G4double GetSplineEnergy(G4int i) const ; 176 177 inline G4double GetIntegralPAIxSection(G4int i) const ; 178 inline G4double GetIntegralPAIdEdx(G4int i) const ; 179 inline G4double GetIntegralCerenkov(G4int i) const ; 180 inline G4double GetIntegralPlasmon(G4int i) const ; 204 inline G4double GetSplineEnergy(G4int i) const; 205 206 inline G4double GetIntegralPAIxSection(G4int i) const; 207 inline G4double GetIntegralPAIdEdx(G4int i) const; 208 inline G4double GetIntegralCerenkov(G4int i) const; 209 inline G4double GetIntegralMM(G4int i) const; 210 inline G4double GetIntegralPlasmon(G4int i) const; 211 inline G4double GetIntegralResonance(G4int i) const; 181 212 182 213 protected : … … 186 217 // Local class constants 187 218 188 static const G4double fDelta 189 static const G4double fError 190 191 static G4int fNumberOfGammas ; // = 111;192 static const G4double fLorentzFactor[112] 219 static const G4double fDelta; // energy shift from interval border = 0.001 220 static const G4double fError; // error in lin-log approximation = 0.005 221 222 static G4int fNumberOfGammas; // = 111; 223 static const G4double fLorentzFactor[112]; // static gamma array 193 224 194 225 static 195 const G4int fRefGammaNumber ; // The number of gamma for creation of spline (15) 196 197 G4int fIntervalNumber ; // The number of energy intervals 198 G4double fNormalizationCof ; // Normalization cof for PhotoAbsorptionXsection 199 200 // G4double fBetaGammaSq ; // (beta*gamma)^2 201 202 G4double fDensity ; // Current density 203 G4double fElectronDensity ; // Current electron (number) density 204 G4int fSplineNumber ; // Current size of spline 226 const G4int fRefGammaNumber ; // The number of gamma for creation of spline (15) 227 228 G4int fIntervalNumber ; // The number of energy intervals 229 G4double fNormalizationCof; // Normalization cof for PhotoAbsorptionXsection 230 231 // G4double fBetaGammaSq; // (beta*gamma)^2 232 233 G4int fMaterialIndex; // current material index 234 G4double fDensity; // Current density 235 G4double fElectronDensity; // Current electron (number) density 236 G4int fSplineNumber; // Current size of spline 205 237 206 238 // Arrays of Sandia coefficients … … 209 241 G4SandiaTable* fSandia; 210 242 211 G4double* fEnergyInterval 212 G4double* fA1 213 G4double* fA2 214 G4double* fA3 215 G4double* fA4 243 G4double* fEnergyInterval; 244 G4double* fA1; 245 G4double* fA2; 246 G4double* fA3; 247 G4double* fA4; 216 248 217 249 static 218 const G4int fMaxSplineSize 250 const G4int fMaxSplineSize ; // Max size of output splain arrays = 500 219 251 220 252 /* ****************** 221 G4double* fSplineEnergy 222 G4double* fRePartDielectricConst 223 G4double* fImPartDielectricConst 224 G4double* fIntegralTerm 225 G4double* fDifPAIxSection 226 G4double* fIntegralPAIxSection 253 G4double* fSplineEnergy; // energy points of splain 254 G4double* fRePartDielectricConst; // Real part of dielectric const 255 G4double* fImPartDielectricConst; // Imaginary part of dielectric const 256 G4double* fIntegralTerm; // Integral term in PAI cross section 257 G4double* fDifPAIxSection; // Differential PAI cross section 258 G4double* fIntegralPAIxSection; // Integral PAI cross section ? 227 259 */ /////////////// 228 260 229 261 230 G4double fSplineEnergy[500] ; // energy points of splain 231 G4double fRePartDielectricConst[500] ; // Real part of dielectric const 232 G4double fImPartDielectricConst[500] ; // Imaginary part of dielectric const 233 G4double fIntegralTerm[500] ; // Integral term in PAI cross section 234 G4double fDifPAIxSection[500] ; // Differential PAI cross section 235 G4double fdNdxCerenkov[500] ; // dNdx of Cerenkov collisions 236 G4double fdNdxPlasmon[500] ; // dNdx of Plasmon collisions 237 238 G4double fIntegralPAIxSection[500] ; // Integral PAI cross section ? 239 G4double fIntegralPAIdEdx[500] ; // Integral PAI dEdx ? 240 G4double fIntegralCerenkov[500] ; // Integral Cerenkov N>omega ? 241 G4double fIntegralPlasmon[500] ; // Integral Plasmon N>omega ? 242 243 G4double fPAItable[500][112] ; // Output array 244 245 } ; 262 G4double fSplineEnergy[500]; // energy points of splain 263 G4double fRePartDielectricConst[500]; // Real part of dielectric const 264 G4double fImPartDielectricConst[500]; // Imaginary part of dielectric const 265 G4double fIntegralTerm[500]; // Integral term in PAI cross section 266 G4double fDifPAIxSection[500]; // Differential PAI cross section 267 G4double fdNdxCerenkov[500]; // dNdx of Cerenkov collisions 268 G4double fdNdxMM[500]; // dNdx of MM-Cerenkov collisions 269 G4double fdNdxPlasmon[500]; // dNdx of Plasmon collisions 270 G4double fdNdxResonance[500]; // dNdx of resonance collisions 271 272 G4double fIntegralPAIxSection[500]; // Integral PAI cross section ? 273 G4double fIntegralPAIdEdx[500]; // Integral PAI dEdx ? 274 G4double fIntegralCerenkov[500]; // Integral Cerenkov N>omega ? 275 G4double fIntegralMM[500]; // Integral MM-Cerenkov N>omega ? 276 G4double fIntegralPlasmon[500]; // Integral Plasmon N>omega ? 277 G4double fIntegralResonance[500]; // Integral resonance N>omega ? 278 279 G4double fPAItable[500][112]; // Output array 280 281 }; 246 282 247 283 //////////////// Inline methods ////////////////////////////////// … … 251 287 inline G4double G4PAIxSection::GetPAItable(G4int i, G4int j) const 252 288 { 253 return fPAItable[i][j] 289 return fPAItable[i][j]; 254 290 } 255 291 256 292 inline G4double G4PAIxSection::GetLorentzFactor(G4int j) const 257 293 { 258 return fLorentzFactor[j] 294 return fLorentzFactor[j]; 259 295 } 260 296 … … 265 301 G4Exception("Invalid argument in G4PAIxSection::GetSplineEnergy"); 266 302 } 267 return fSplineEnergy[i] 303 return fSplineEnergy[i]; 268 304 } 269 305 … … 274 310 G4Exception("Invalid argument in G4PAIxSection::GetIntegralPAIxSection"); 275 311 } 276 return fIntegralPAIxSection[i] 312 return fIntegralPAIxSection[i]; 277 313 } 278 314 … … 283 319 G4Exception("Invalid argument in G4PAIxSection::GetIntegralPAIxSection"); 284 320 } 285 return fIntegralPAIdEdx[i] 321 return fIntegralPAIdEdx[i]; 286 322 } 287 323 … … 292 328 G4Exception("Invalid argument in G4PAIxSection::GetIntegralCerenkov"); 293 329 } 294 return fIntegralCerenkov[i] ; 330 return fIntegralCerenkov[i]; 331 } 332 333 inline G4double G4PAIxSection::GetIntegralMM(G4int i) const 334 { 335 if(i < 1 || i > fSplineNumber) 336 { 337 G4Exception("Invalid argument in G4PAIxSection::GetIntegralMM"); 338 } 339 return fIntegralMM[i]; 295 340 } 296 341 … … 301 346 G4Exception("Invalid argument in G4PAIxSection::GetIntegralPlasmon"); 302 347 } 303 return fIntegralPlasmon[i] ; 348 return fIntegralPlasmon[i]; 349 } 350 351 inline G4double G4PAIxSection::GetIntegralResonance(G4int i) const 352 { 353 if(i < 1 || i > fSplineNumber) 354 { 355 G4Exception("Invalid argument in G4PAIxSection::GetIntegralResonance"); 356 } 357 return fIntegralResonance[i]; 304 358 } 305 359 -
trunk/source/processes/electromagnetic/standard/include/G4PAIySection.hh
r819 r961 26 26 // 27 27 // $Id: G4PAIySection.hh,v 1.1 2007/10/01 17:45:14 vnivanch Exp $ 28 // GEANT4 tag $Name: $28 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 29 29 // 30 30 // -
trunk/source/processes/electromagnetic/standard/include/G4PEEffectModel.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4PEEffectModel.hh,v 1. 6 2007/05/22 17:34:36vnivanch Exp $27 // GEANT4 tag $Name: $26 // $Id: G4PEEffectModel.hh,v 1.7 2009/02/20 12:06:37 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 41 41 // 42 42 // 06.02.2006 : added ComputeMeanFreePath() (mma) 43 // 20.02.2009 : move virtual inline to .cc, substitute 44 // ComputeMeanFreePath() by CrossSectionPerVolume (VI) 43 45 // 44 46 // Class Description: … … 70 72 virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&); 71 73 72 G4double ComputeCrossSectionPerAtom(const G4ParticleDefinition*,73 74 75 76 74 virtual G4double ComputeCrossSectionPerAtom(const G4ParticleDefinition*, 75 G4double kinEnergy, 76 G4double Z, 77 G4double A, 78 G4double, G4double); 77 79 78 G4double ComputeMeanFreePath( const G4ParticleDefinition*, 79 G4double kinEnergy, 80 const G4Material* material, 81 G4double, G4double); 80 virtual G4double CrossSectionPerVolume(const G4Material*, 81 const G4ParticleDefinition*, 82 G4double kineticEnergy, 83 G4double cutEnergy, 84 G4double maxEnergy); 82 85 83 86 virtual void SampleSecondaries(std::vector<G4DynamicParticle*>*, … … 100 103 }; 101 104 102 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....103 104 inline G4double G4PEEffectModel::ComputeCrossSectionPerAtom(105 const G4ParticleDefinition*,106 G4double energy,107 G4double Z, G4double,108 G4double, G4double)109 {110 G4double* SandiaCof = G4SandiaTable::GetSandiaCofPerAtom((G4int)Z, energy);111 112 G4double energy2 = energy*energy, energy3 = energy*energy2,113 energy4 = energy2*energy2;114 115 return SandiaCof[0]/energy + SandiaCof[1]/energy2 +116 SandiaCof[2]/energy3 + SandiaCof[3]/energy4;117 }118 119 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....120 121 inline G4double G4PEEffectModel::ComputeMeanFreePath(122 const G4ParticleDefinition*,123 G4double energy,124 const G4Material* material,125 G4double, G4double)126 {127 G4double* SandiaCof = material->GetSandiaTable()128 ->GetSandiaCofForMaterial(energy);129 130 G4double energy2 = energy*energy, energy3 = energy*energy2,131 energy4 = energy2*energy2;132 133 G4double cross = SandiaCof[0]/energy + SandiaCof[1]/energy2 +134 SandiaCof[2]/energy3 + SandiaCof[3]/energy4;135 136 G4double mfp = DBL_MAX;137 if (cross > 0.) mfp = 1./cross;138 return mfp;139 }140 141 105 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 142 106 -
trunk/source/processes/electromagnetic/standard/include/G4PSTARStopping.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4PSTARStopping.hh,v 1. 4 2006/06/29 19:50:48 gunterExp $27 // GEANT4 tag $Name: $26 // $Id: G4PSTARStopping.hh,v 1.5 2008/11/13 12:04:37 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 29 29 #ifndef G4PSTARStopping_h … … 85 85 G4double currentE, res; 86 86 G4double e[74][60], kinE[60]; 87 G4int Znum[74];88 87 }; 89 88 -
trunk/source/processes/electromagnetic/standard/include/G4PhotoElectricEffect.hh
r819 r961 25 25 // 26 26 // 27 // $Id: G4PhotoElectricEffect.hh,v 1.2 4 2007/05/23 08:47:34vnivanch Exp $28 // GEANT4 tag $Name: $27 // $Id: G4PhotoElectricEffect.hh,v 1.25 2009/02/20 12:06:37 vnivanch Exp $ 28 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 29 29 // 30 30 // … … 91 91 92 92 // true for Gamma only. 93 G4bool IsApplicable(const G4ParticleDefinition&);93 virtual G4bool IsApplicable(const G4ParticleDefinition&); 94 94 95 95 // Print few lines of informations about the process: validity range, 96 v oid PrintInfo();96 virtual void PrintInfo(); 97 97 98 98 protected: 99 99 100 v oid InitialiseProcess(const G4ParticleDefinition*);100 virtual void InitialiseProcess(const G4ParticleDefinition*); 101 101 102 102 private: … … 105 105 }; 106 106 107 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....108 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....109 110 inline111 G4bool G4PhotoElectricEffect::IsApplicable(const G4ParticleDefinition& p)112 {113 return (&p == G4Gamma::Gamma());114 }115 116 107 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 117 108 -
trunk/source/processes/electromagnetic/standard/include/G4PolarizedComptonScattering.hh
r819 r961 26 26 // 27 27 // $Id: G4PolarizedComptonScattering.hh,v 1.9 2006/06/29 19:51:14 gunter Exp $ 28 // GEANT4 tag $Name: $28 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 29 29 // 30 30 // --------- G4PolarizedComptonScattering physics process ---------------------- -
trunk/source/processes/electromagnetic/standard/include/G4UniversalFluctuation.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4UniversalFluctuation.hh,v 1. 5 2007/04/03 11:08:36 urbanExp $27 // GEANT4 tag $Name: $26 // $Id: G4UniversalFluctuation.hh,v 1.8 2009/02/19 19:17:50 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 59 59 60 60 #include "G4VEmFluctuationModel.hh" 61 #include "G4ParticleDefinition.hh" 61 62 62 63 class G4UniversalFluctuation : public G4VEmFluctuationModel … … 69 70 virtual ~G4UniversalFluctuation(); 70 71 71 G4double SampleFluctuations(const G4Material*,72 73 74 75 72 virtual G4double SampleFluctuations(const G4Material*, 73 const G4DynamicParticle*, 74 G4double&, 75 G4double&, 76 G4double&); 76 77 77 G4double Dispersion( const G4Material*,78 79 80 78 virtual G4double Dispersion( const G4Material*, 79 const G4DynamicParticle*, 80 G4double&, 81 G4double&); 81 82 82 void InitialiseMe(const G4ParticleDefinition*); 83 // Initialisation before the run 84 virtual void InitialiseMe(const G4ParticleDefinition*); 83 85 84 protected: 86 // Initialisation prestep 87 virtual void SetParticleAndCharge(const G4ParticleDefinition*, G4double q2); 85 88 86 89 private: -
trunk/source/processes/electromagnetic/standard/include/G4UrbanMscModel.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4UrbanMscModel.hh,v 1.3 1 2007/10/29 08:42:43vnivanch Exp $27 // GEANT4 tag $Name: geant4-09-0 1-patch-02 $26 // $Id: G4UrbanMscModel.hh,v 1.33 2008/03/10 10:39:21 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 91 91 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 92 92 93 #include "G4V EmModel.hh"93 #include "G4VMscModel.hh" 94 94 #include "G4PhysicsTable.hh" 95 95 #include "G4MscStepLimitType.hh" … … 101 101 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 102 102 103 class G4UrbanMscModel : public G4V EmModel103 class G4UrbanMscModel : public G4VMscModel 104 104 { 105 105 106 106 public: 107 107 108 G4UrbanMscModel(G4double facrange, G4double dtrl, G4double lambdalimit, 109 G4double facgeom,G4double skin, 110 G4bool samplez, G4MscStepLimitType stepAlg, 111 const G4String& nam = "UrbanMscUni"); 108 G4UrbanMscModel(const G4String& nam = "UrbanMscUni"); 112 109 113 110 virtual ~G4UrbanMscModel(); 114 111 115 v irtual void Initialise(const G4ParticleDefinition*, const G4DataVector&);116 112 void Initialise(const G4ParticleDefinition*, const G4DataVector&); 113 117 114 G4double ComputeCrossSectionPerAtom(const G4ParticleDefinition* particle, 118 115 G4double KineticEnergy, … … 142 139 G4double KineticEnergy); 143 140 144 void SetStepLimitType(G4MscStepLimitType);145 146 void SetLateralDisplasmentFlag(G4bool val);147 148 void SetRangeFactor(G4double);149 150 void SetGeomFactor(G4double);151 152 void SetSkin(G4double);153 154 141 private: 155 142 … … 160 147 G4double LatCorrelation(); 161 148 162 G4double GetLambda(G4double kinEnergy);163 164 149 void GeomLimit(const G4Track& track); 165 150 166 void SetParticle(const G4ParticleDefinition* p); 151 inline G4double GetLambda(G4double kinEnergy); 152 153 inline void SetParticle(const G4ParticleDefinition*); 167 154 168 155 // hide assignment operator … … 178 165 G4LossTableManager* theManager; 179 166 180 181 167 G4double mass; 182 168 G4double charge; … … 188 174 G4double taulim; 189 175 G4double currentTau; 190 G4double dtrl;191 192 G4double lambdalimit;193 G4double facrange;194 176 G4double frscaling1,frscaling2; 195 177 G4double tlimit; … … 201 183 G4double geommin; 202 184 G4double geomlimit; 203 G4double facgeom;204 G4double skin;205 185 G4double skindepth; 206 186 G4double smallstep; 207 187 208 188 G4double presafety; 209 G4double facsafety;210 189 211 190 G4double lambda0; … … 213 192 G4double tPathLength; 214 193 G4double zPathLength; 215 G4double par1,par2,par3 216 217 G4double stepmin 194 G4double par1,par2,par3; 195 196 G4double stepmin; 218 197 219 198 G4double currentKinEnergy; … … 225 204 G4int currentMaterialIndex; 226 205 227 G4MscStepLimitType steppingAlgorithm;228 229 G4bool samplez;230 G4bool latDisplasment;231 206 G4bool isInitialized; 232 233 207 G4bool inside; 234 208 G4bool insideskin; 235 209 236 210 }; 237 238 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......239 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......240 241 inline242 void G4UrbanMscModel::SetLateralDisplasmentFlag(G4bool val)243 {244 latDisplasment = val;245 }246 247 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......248 249 inline250 void G4UrbanMscModel::SetSkin(G4double val)251 {252 skin = val;253 stepmin = tlimitminfix;254 skindepth = skin*stepmin;255 }256 257 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......258 259 inline260 void G4UrbanMscModel::SetRangeFactor(G4double val)261 {262 facrange = val;263 }264 265 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......266 267 inline268 void G4UrbanMscModel::SetGeomFactor(G4double val)269 {270 facgeom = val;271 }272 273 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......274 275 inline276 void G4UrbanMscModel::SetStepLimitType(G4MscStepLimitType val)277 {278 steppingAlgorithm = val;279 }280 211 281 212 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... -
trunk/source/processes/electromagnetic/standard/include/G4UrbanMscModel90.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4UrbanMscModel90.hh,v 1. 1 2007/12/07 17:35:52vnivanch Exp $27 // GEANT4 tag $Name: geant4-09-0 1-patch-02 $26 // $Id: G4UrbanMscModel90.hh,v 1.4 2008/10/29 14:15:30 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 55 55 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 56 56 57 #include "G4V EmModel.hh"57 #include "G4VMscModel.hh" 58 58 #include "G4PhysicsTable.hh" 59 59 #include "G4MscStepLimitType.hh" … … 65 65 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 66 66 67 class G4UrbanMscModel90 : public G4V EmModel67 class G4UrbanMscModel90 : public G4VMscModel 68 68 { 69 69 70 70 public: 71 71 72 G4UrbanMscModel90(G4double facrange, G4double dtrl, G4double lambdalimit, 73 G4double facgeom,G4double skin, 74 G4bool samplez, G4MscStepLimitType stepAlg, 75 const G4String& nam = "UrbanMscUni"); 72 G4UrbanMscModel90(const G4String& nam = "UrbanMscUni90"); 76 73 77 74 virtual ~G4UrbanMscModel90(); 78 75 79 v irtual void Initialise(const G4ParticleDefinition*, const G4DataVector&);76 void Initialise(const G4ParticleDefinition*, const G4DataVector&); 80 77 81 78 G4double ComputeCrossSectionPerAtom(const G4ParticleDefinition* particle, … … 106 103 G4double KineticEnergy); 107 104 108 void SetStepLimitType(G4MscStepLimitType);109 110 void SetLateralDisplasmentFlag(G4bool val);111 112 void SetRangeFactor(G4double);113 114 void SetGeomFactor(G4double);115 116 void SetSkin(G4double);117 118 105 private: 119 106 … … 124 111 G4double LatCorrelation(); 125 112 126 G4double GetLambda(G4double kinEnergy);127 128 113 void GeomLimit(const G4Track& track); 129 114 130 void SetParticle(const G4ParticleDefinition* p); 115 inline G4double GetLambda(G4double kinEnergy); 116 117 inline void SetParticle(const G4ParticleDefinition*); 131 118 132 119 // hide assignment operator … … 142 129 G4LossTableManager* theManager; 143 130 144 145 131 G4double mass; 146 132 G4double charge; … … 152 138 G4double taulim; 153 139 G4double currentTau; 154 G4double dtrl;155 156 G4double lambdalimit;157 G4double facrange;158 140 G4double frscaling1,frscaling2; 159 141 G4double tlimit; … … 165 147 G4double geommin; 166 148 G4double geomlimit; 167 G4double facgeom;168 G4double skin;169 149 G4double skindepth; 170 150 G4double smallstep; 171 151 172 152 G4double presafety; 173 G4double facsafety;174 153 175 154 G4double lambda0; … … 177 156 G4double tPathLength; 178 157 G4double zPathLength; 179 G4double par1,par2,par3 180 181 G4double stepmin 158 G4double par1,par2,par3; 159 160 G4double stepmin; 182 161 183 162 G4double currentKinEnergy; … … 189 168 G4int currentMaterialIndex; 190 169 191 G4MscStepLimitType steppingAlgorithm;192 193 G4bool samplez;194 G4bool latDisplasment;195 170 G4bool isInitialized; 196 197 171 G4bool inside; 198 172 G4bool insideskin; 199 173 200 174 }; 201 202 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......203 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......204 205 inline206 void G4UrbanMscModel90::SetLateralDisplasmentFlag(G4bool val)207 {208 latDisplasment = val;209 }210 211 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......212 213 inline214 void G4UrbanMscModel90::SetSkin(G4double val)215 {216 skin = val;217 stepmin = tlimitminfix;218 skindepth = skin*stepmin;219 }220 221 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......222 223 inline224 void G4UrbanMscModel90::SetRangeFactor(G4double val)225 {226 facrange = val;227 }228 229 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......230 231 inline232 void G4UrbanMscModel90::SetGeomFactor(G4double val)233 {234 facgeom = val;235 }236 237 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......238 239 inline240 void G4UrbanMscModel90::SetStepLimitType(G4MscStepLimitType val)241 {242 steppingAlgorithm = val;243 }244 175 245 176 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... -
trunk/source/processes/electromagnetic/standard/include/G4WaterStopping.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4WaterStopping.hh,v 1. 2 2006/06/29 19:51:56 gunterExp $27 // GEANT4 tag $Name: $26 // $Id: G4WaterStopping.hh,v 1.6 2008/09/09 09:30:58 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 29 29 #ifndef G4WaterStopping_h … … 60 60 public: 61 61 62 G4WaterStopping(G4EmCorrections* corr = 0 );62 G4WaterStopping(G4EmCorrections* corr = 0, G4bool splineFlag = true); 63 63 64 64 ~G4WaterStopping(); … … 70 70 void Initialise(G4EmCorrections*); 71 71 72 void AddData(G4double* energy, G4double* stoppower, G4double factor); 73 72 74 // hide assignment operator 73 75 G4WaterStopping & operator=(const G4WaterStopping &right); 74 76 G4WaterStopping(const G4WaterStopping&); 75 77 76 G4int Z[8]; 77 G4int A[8]; 78 G4bool spline; 79 G4int Z[16]; 80 G4double A[16]; 78 81 std::vector<G4LPhysicsFreeVector*> dedx; 79 82 }; -
trunk/source/processes/electromagnetic/standard/include/G4eBremsstrahlung.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4eBremsstrahlung.hh,v 1.3 6 2007/05/23 08:47:34vnivanch Exp $27 // GEANT4 tag $Name: $26 // $Id: G4eBremsstrahlung.hh,v 1.37 2009/02/20 12:06:37 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 89 89 virtual ~G4eBremsstrahlung(); 90 90 91 G4bool IsApplicable(const G4ParticleDefinition& p);91 virtual G4bool IsApplicable(const G4ParticleDefinition& p); 92 92 93 93 // Print out of the class parameters … … 111 111 112 112 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 113 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....114 115 inline G4bool G4eBremsstrahlung::IsApplicable(const G4ParticleDefinition& p)116 {117 return (&p == G4Electron::Electron() || &p == G4Positron::Positron());118 }119 120 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....121 113 122 114 #endif -
trunk/source/processes/electromagnetic/standard/include/G4eBremsstrahlungModel.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4eBremsstrahlungModel.hh,v 1.2 2 2007/05/23 08:47:34vnivanch Exp $27 // GEANT4 tag $Name: $26 // $Id: G4eBremsstrahlungModel.hh,v 1.26 2009/02/20 12:06:37 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 69 69 70 70 G4eBremsstrahlungModel(const G4ParticleDefinition* p = 0, 71 const G4String& nam = " StandBrem");71 const G4String& nam = "eBrem"); 72 72 73 73 virtual ~G4eBremsstrahlungModel(); … … 75 75 virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&); 76 76 77 G4double MinEnergyCut(const G4ParticleDefinition*,78 const G4MaterialCutsCouple*);77 virtual G4double MinEnergyCut(const G4ParticleDefinition*, 78 const G4MaterialCutsCouple*); 79 79 80 80 virtual G4double ComputeDEDXPerVolume(const G4Material*, … … 101 101 G4double maxEnergy); 102 102 103 inline void SetLPMflag(G4bool val);104 inline G4bool LPMflag() const;105 106 inline void SetEnergyThreshold(G4double val);107 inline G4double EnergyThreshold() const;108 109 103 protected: 110 111 inline G4double MaxSecondaryEnergy(const G4ParticleDefinition*,112 G4double kineticEnergy);113 104 114 105 const G4Element* SelectRandomAtom(const G4MaterialCutsCouple* couple); … … 154 145 G4double MigdalConstant; 155 146 G4double LPMconstant; 156 G4double highEnergyTh;157 G4bool theLPMflag;158 147 G4bool isInitialised; 159 148 … … 199 188 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 200 189 201 inline202 G4double G4eBremsstrahlungModel::MaxSecondaryEnergy(203 const G4ParticleDefinition*,204 G4double kineticEnergy)205 {206 return kineticEnergy;207 }208 209 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....210 211 inline212 void G4eBremsstrahlungModel::SetLPMflag(G4bool val)213 {214 theLPMflag = val;215 }216 217 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....218 219 inline220 G4bool G4eBremsstrahlungModel::LPMflag() const221 {222 return theLPMflag;223 }224 225 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....226 227 inline228 void G4eBremsstrahlungModel::SetEnergyThreshold(G4double val)229 {230 highEnergyTh = val;231 }232 233 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....234 235 inline236 G4double G4eBremsstrahlungModel::EnergyThreshold() const237 {238 return highEnergyTh;239 }240 241 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....242 243 190 #endif -
trunk/source/processes/electromagnetic/standard/include/G4eCoulombScatteringModel.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4eCoulombScatteringModel.hh,v 1. 20 2007/10/24 10:42:05vnivanch Exp $27 // GEANT4 tag $Name: geant4-09-0 1-patch-02 $26 // $Id: G4eCoulombScatteringModel.hh,v 1.36 2008/08/04 08:49:09 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 45 45 // make some members protected 46 46 // 09.10.07 V.Ivanchenko reorganized methods, add cut dependence in scattering off e- 47 // 09.06.08 V.Ivanchenko add SelectIsotope and sampling of the recoil ion 47 48 // 48 49 // Class Description: … … 75 76 public: 76 77 77 G4eCoulombScatteringModel(G4double thetaMin = 0.0, G4double thetaMax = pi, 78 G4bool build = false, G4double tlim = TeV*TeV, 79 const G4String& nam = "eCoulombScattering"); 78 G4eCoulombScatteringModel(const G4String& nam = "eCoulombScattering"); 80 79 81 80 virtual ~G4eCoulombScatteringModel(); … … 97 96 G4double maxEnergy); 98 97 98 inline void SetRecoilThreshold(G4double eth); 99 99 100 protected: 100 101 101 G4double ComputeElectronXSectionPerAtom( 102 const G4ParticleDefinition*, 103 G4double kinEnergy, 104 G4double Z, 105 G4double A, 106 G4double cut); 107 108 virtual G4double CalculateCrossSectionPerAtom( 109 const G4ParticleDefinition*, 110 G4double kinEnergy, 111 G4double Z, G4double A); 102 G4double CrossSectionPerAtom(); 103 104 G4double SampleCosineTheta(); 105 106 inline void DefineMaterial(const G4MaterialCutsCouple*); 112 107 113 108 inline void SetupParticle(const G4ParticleDefinition*); 114 109 115 inline void SetupKinematic(G4double kinEnergy );110 inline void SetupKinematic(G4double kinEnergy, G4double cut); 116 111 117 inline void SetupTarget(G4double Z, G4double A, G4doublekinEnergy);112 inline void SetupTarget(G4double Z, G4double kinEnergy); 118 113 119 114 private: 115 116 void ComputeMaxElectronScattering(G4double cut); 120 117 121 118 // hide assignment operator … … 124 121 125 122 protected: 126 123 127 124 const G4ParticleDefinition* theProton; 128 125 const G4ParticleDefinition* theElectron; 129 126 const G4ParticleDefinition* thePositron; 130 127 128 G4ParticleTable* theParticleTable; 131 129 G4ParticleChangeForGamma* fParticleChange; 132 130 G4NistManager* fNistManager; 131 const G4DataVector* currentCuts; 132 133 const G4MaterialCutsCouple* currentCouple; 134 const G4Material* currentMaterial; 135 const G4Element* currentElement; 136 G4int currentMaterialIndex; 133 137 134 138 G4double coeff; … … 136 140 G4double cosThetaMin; 137 141 G4double cosThetaMax; 142 G4double cosTetMinNuc; 138 143 G4double cosTetMaxNuc; 144 G4double cosTetMaxNuc2; 139 145 G4double cosTetMaxElec; 146 G4double cosTetMaxElec2; 140 147 G4double q2Limit; 148 G4double recoilThreshold; 141 149 G4double elecXSection; 142 150 G4double nucXSection; … … 152 160 G4double mom2; 153 161 G4double invbeta2; 162 G4double etag; 163 G4double lowEnergyLimit; 154 164 155 165 // target 156 166 G4double targetZ; 157 G4double targetA;158 167 G4double screenZ; 159 168 G4double formfactA; 169 G4int idxelm; 160 170 161 171 private: 162 172 163 G4PhysicsTable* theCrossSectionTable;164 165 173 G4double a0; 166 G4double lowKEnergy;167 G4double highKEnergy;168 174 G4double alpha2; 169 175 G4double faclim; 170 171 G4int nbins; 172 G4int nmax; 173 G4int index[100]; 174 175 G4bool buildTable; 176 G4double FF[100]; 177 176 178 G4bool isInitialised; 177 179 }; 180 181 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 182 183 inline 184 void G4eCoulombScatteringModel::DefineMaterial(const G4MaterialCutsCouple* cup) 185 { 186 if(cup != currentCouple) { 187 currentCouple = cup; 188 currentMaterial = cup->GetMaterial(); 189 currentMaterialIndex = currentCouple->GetIndex(); 190 } 191 } 178 192 179 193 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... … … 190 204 chargeSquare = q*q; 191 205 tkin = 0.0; 206 lowEnergyLimit = keV*mass/electron_mass_c2; 192 207 } 193 208 } … … 195 210 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 196 211 197 inline void G4eCoulombScatteringModel::SetupKinematic(G4double ekin) 198 { 199 if(ekin != tkin) { 200 tkin = ekin; 201 mom2 = tkin*(tkin + 2.0*mass); 212 inline void G4eCoulombScatteringModel::SetupKinematic(G4double ekin, 213 G4double cut) 214 { 215 if(ekin != tkin || ecut != cut) { 216 tkin = ekin; 217 mom2 = tkin*(tkin + 2.0*mass); 202 218 invbeta2 = 1.0 + mass*mass/mom2; 203 } 219 cosTetMinNuc = cosThetaMin; 220 cosTetMaxNuc = cosThetaMax; 221 if(ekin <= 10.*cut && mass < MeV && cosThetaMin < 1.0) { 222 cosTetMinNuc = ekin*(cosThetaMin + 1.0)/(10.*cut) - 1.0; 223 } 224 ComputeMaxElectronScattering(cut); 225 } 204 226 } 205 227 206 228 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 207 229 208 inline void G4eCoulombScatteringModel::SetupTarget(G4double Z, G4double A,209 G4double e) 210 {211 if(e != tkin || Z != targetZ || A != targetA) {230 inline void G4eCoulombScatteringModel::SetupTarget(G4double Z, G4double e) 231 { 232 if(Z != targetZ || e != etag) { 233 etag = e; 212 234 targetZ = Z; 213 targetA = A; 214 SetupKinematic(e); 215 cosTetMaxNuc = std::max(cosThetaMax, 1.0 - 0.5*q2Limit/mom2); 216 G4double x = fNistManager->GetZ13(Z); 217 screenZ = a0*x*x*(1.13 + 3.76*invbeta2*Z*Z*chargeSquare*alpha2)/mom2; 218 if(particle == theProton && A < 1.5 && cosTetMaxNuc < 0.0) 219 cosTetMaxNuc = 0.0; 235 G4int iz= G4int(Z); 236 if(iz > 99) iz = 99; 237 G4double x = fNistManager->GetZ13(iz); 238 screenZ = a0*x*x/mom2; 239 if(iz > 1) screenZ *=(1.13 + 3.76*invbeta2*Z*Z*chargeSquare*alpha2); 240 //screenZ = a0*x*x*(1.13 + 3.76*Z*Z*chargeSquare*alpha2)/mom2; 220 241 // A.V. Butkevich et al., NIM A 488 (2002) 282 221 x = fNistManager->GetLOGA(A); 222 formfactA = mom2*constn*std::exp(0.54*x); 242 formfactA = FF[iz]; 243 if(formfactA == 0.0) { 244 x = fNistManager->GetA27(iz); 245 formfactA = constn*x*x; 246 FF[iz] = formfactA; 247 } 248 formfactA *= mom2; 249 cosTetMaxNuc2 = cosTetMaxNuc; 250 if(particle == theProton && 1 == iz && cosTetMaxNuc2 < 0.0) { 251 cosTetMaxNuc2 = 0.0; 252 } 253 /* 254 G4double ee = 10.*eV*Z; 255 if(1 == iz) ee *= 2.0; 256 G4double z = std::min(cosTetMaxElec, 1.0 - std::max(ecut,ee)*amu_c2 257 *fNistManager->GetAtomicMassAmu(iz)/mom2); 258 cosTetMaxElec2 = std::max(cosTetMaxNuc2, z); 259 */ 260 cosTetMaxElec2 = cosTetMaxElec; 223 261 } 224 262 } … … 226 264 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 227 265 266 inline void G4eCoulombScatteringModel::SetRecoilThreshold(G4double eth) 267 { 268 recoilThreshold = eth; 269 } 270 271 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 272 228 273 #endif -
trunk/source/processes/electromagnetic/standard/include/G4eIonisation.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4eIonisation.hh,v 1.3 5 2007/05/23 08:47:34vnivanch Exp $27 // GEANT4 tag $Name: $26 // $Id: G4eIonisation.hh,v 1.36 2009/02/20 12:06:37 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 88 88 virtual ~G4eIonisation(); 89 89 90 G4bool IsApplicable(const G4ParticleDefinition& p);90 virtual G4bool IsApplicable(const G4ParticleDefinition& p); 91 91 92 92 // Print out of the class parameters … … 98 98 const G4ParticleDefinition*); 99 99 100 G4double MinPrimaryEnergy(const G4ParticleDefinition*,101 const G4Material*, G4double cut);100 virtual G4double MinPrimaryEnergy(const G4ParticleDefinition*, 101 const G4Material*, G4double cut); 102 102 103 103 private: … … 114 114 }; 115 115 116 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....117 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....118 119 inline G4double G4eIonisation::MinPrimaryEnergy(const G4ParticleDefinition*,120 const G4Material*,121 G4double cut)122 {123 G4double x = cut;124 if(isElectron) x += cut;125 return x;126 }127 128 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....129 130 inline G4bool G4eIonisation::IsApplicable(const G4ParticleDefinition& p)131 {132 return (&p == G4Electron::Electron() || &p == G4Positron::Positron());133 }134 135 116 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 136 117 -
trunk/source/processes/electromagnetic/standard/include/G4eeToTwoGammaModel.hh
r819 r961 25 25 // 26 26 // $Id: G4eeToTwoGammaModel.hh,v 1.14 2007/05/23 08:47:34 vnivanch Exp $ 27 // GEANT4 tag $Name: $27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- -
trunk/source/processes/electromagnetic/standard/include/G4eplusAnnihilation.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4eplusAnnihilation.hh,v 1.2 3 2007/05/23 08:47:34vnivanch Exp $27 // GEANT4 tag $Name: $26 // $Id: G4eplusAnnihilation.hh,v 1.24 2009/02/20 12:06:37 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 73 73 virtual ~G4eplusAnnihilation(); 74 74 75 G4bool IsApplicable(const G4ParticleDefinition& p);75 virtual G4bool IsApplicable(const G4ParticleDefinition& p); 76 76 77 77 virtual G4VParticleChange* AtRestDoIt( … … 79 79 const G4Step& stepData); 80 80 81 G4double AtRestGetPhysicalInteractionLength(81 virtual G4double AtRestGetPhysicalInteractionLength( 82 82 const G4Track& track, 83 83 G4ForceCondition* condition … … 96 96 }; 97 97 98 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....99 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....100 101 inline G4bool G4eplusAnnihilation::IsApplicable(const G4ParticleDefinition& p)102 {103 return (&p == G4Positron::Positron());104 }105 106 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....107 108 inline109 G4double G4eplusAnnihilation::AtRestGetPhysicalInteractionLength(110 const G4Track&, G4ForceCondition* condition)111 {112 *condition = NotForced;113 return 0.0;114 }115 116 98 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 117 99 -
trunk/source/processes/electromagnetic/standard/include/G4hIonisation.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4hIonisation.hh,v 1. 38 2008/01/14 11:59:45vnivanch Exp $27 // GEANT4 tag $Name: geant4-09-0 1-patch-02 $26 // $Id: G4hIonisation.hh,v 1.42 2009/02/20 12:06:37 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 63 63 // 08-04-05 Major optimisation of internal interfaces (V.Ivantchenko) 64 64 // 11-04-04 Move MaxSecondaryEnergy to models (V.Ivanchenko) 65 // 12-09-08 Removed CorrectionsAlongStep (VI) 65 66 // 66 67 // Class Description: … … 80 81 #include "G4Positron.hh" 81 82 #include "globals.hh" 82 #include "G4VEmModel.hh"83 #include "G4EmCorrections.hh"84 83 85 84 class G4Material; … … 94 93 virtual ~G4hIonisation(); 95 94 96 G4bool IsApplicable(const G4ParticleDefinition& p);95 virtual G4bool IsApplicable(const G4ParticleDefinition& p); 97 96 98 G4double MinPrimaryEnergy(const G4ParticleDefinition* p,99 const G4Material*, G4double cut);97 virtual G4double MinPrimaryEnergy(const G4ParticleDefinition* p, 98 const G4Material*, G4double cut); 100 99 101 100 // Print out of the class parameters … … 105 104 106 105 protected: 107 108 void CorrectionsAlongStep(109 const G4MaterialCutsCouple*,110 const G4DynamicParticle*,111 G4double& eloss,112 G4double& length);113 106 114 107 virtual void InitialiseEnergyLossProcess(const G4ParticleDefinition*, … … 121 114 G4hIonisation(const G4hIonisation&); 122 115 116 G4bool isInitialised; 117 G4bool nuclearStopping; 118 123 119 G4double mass; 124 120 G4double ratio; 125 126 const G4ParticleDefinition* theParticle; 127 const G4ParticleDefinition* theBaseParticle; 128 G4EmCorrections* corr; 129 130 G4bool isInitialised; 131 G4bool nuclearStopping; 132 133 G4double eth; 134 G4double ethnuc; 135 G4double massratio; 136 121 G4double eth; 137 122 }; 138 139 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....140 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....141 142 inline G4bool G4hIonisation::IsApplicable(const G4ParticleDefinition& p)143 {144 return (p.GetPDGCharge() != 0.0 && p.GetPDGMass() > 10.0*MeV &&145 !p.IsShortLived());146 }147 148 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....149 150 inline G4double G4hIonisation::MinPrimaryEnergy(const G4ParticleDefinition*,151 const G4Material*,152 G4double cut)153 {154 G4double x = 0.5*cut/electron_mass_c2;155 G4double y = electron_mass_c2/mass;156 G4double g = x*y + std::sqrt((1. + x)*(1. + x*y*y));157 return mass*(g - 1.0);158 }159 123 160 124 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... -
trunk/source/processes/electromagnetic/standard/include/G4hMultipleScattering.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4hMultipleScattering.hh,v 1. 4 2007/12/07 17:35:52vnivanch Exp $27 // GEANT4 tag $Name: geant4-09-0 1-patch-02 $26 // $Id: G4hMultipleScattering.hh,v 1.6 2008/05/09 08:23:44 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ----------------------------------------------------------------------------- … … 60 60 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 61 61 62 class G4 UrbanMscModel90;62 class G4VMscModel; 63 63 64 64 class G4hMultipleScattering : public G4VMultipleScattering … … 86 86 void SetLambdalimit(G4double value) { lambdalimit = value;}; 87 87 88 // The function overloads the corresponding function of the base 89 // class.It limits the step near to boundaries only 90 // and invokes the method GetMscContinuousStepLimit at every step. 91 G4double AlongStepGetPhysicalInteractionLength( 92 const G4Track&, 93 G4double previousStepSize, 94 G4double currentMinimalStep, 95 G4double& currentSafety, 96 G4GPILSelection* selection); 97 88 98 protected: 89 99 … … 93 103 private: // data members 94 104 95 G4 UrbanMscModel90* mscUrban;105 G4VMscModel* mscUrban; 96 106 97 107 G4double lambdalimit; … … 100 110 G4bool samplez; 101 111 G4bool isInitialized; 112 G4bool isIon; 102 113 103 114 }; -
trunk/source/processes/electromagnetic/standard/include/G4ionGasIonisation.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4ionGasIonisation.hh,v 1. 2 2007/08/13 06:13:30vnivanch Exp $27 // GEANT4 tag $Name: geant4-09-0 1-patch-02 $26 // $Id: G4ionGasIonisation.hh,v 1.4 2008/09/12 16:26:34 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 55 55 #include "G4ionIonisation.hh" 56 56 57 class G4Material;58 59 57 class G4ionGasIonisation : public G4ionIonisation 60 58 { … … 65 63 virtual ~G4ionGasIonisation(); 66 64 67 virtual void PrintInfo();68 69 protected:70 71 // Initialise process before run72 virtual void InitialiseEnergyLossProcess(73 const G4ParticleDefinition*,74 const G4ParticleDefinition*);75 76 // Initialise dynamic charge before step77 virtual void InitialiseMassCharge(const G4Track&);78 79 // Apply correction after step and modify dynamic charge80 virtual void CorrectionsAlongStep(81 const G4MaterialCutsCouple*,82 const G4DynamicParticle*,83 G4double& eloss,84 G4double& length);85 86 65 private: 87 88 // Sample change of charge of the projectile ion89 G4double SampleChargeAfterStep(G4double qeff, G4double xeff);90 66 91 67 // hide assignment operator 92 68 G4ionGasIonisation & operator=(const G4ionGasIonisation &right); 93 69 G4ionGasIonisation(const G4ionGasIonisation&); 94 95 const G4ParticleDefinition* currParticle;96 const G4ParticleDefinition* baseParticle;97 98 G4double basePartMass;99 G4double currMassRatio;100 G4double atomXS;101 G4double preStepKinEnergy;102 103 G4int currentIonZ;104 G4int ionZ;105 106 G4bool initialised;107 108 70 }; 109 71 -
trunk/source/processes/electromagnetic/standard/include/G4ionIonisation.hh
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4ionIonisation.hh,v 1.5 0 2007/11/09 11:45:45vnivanch Exp $27 // GEANT4 tag $Name: geant4-09-0 1-patch-02 $26 // $Id: G4ionIonisation.hh,v 1.57 2009/02/20 12:06:37 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 57 57 // 22-07-06 Remove obsolete method (V.Ivantchenko) 58 58 // 07-11-07 Moved CorrectionsAlongStep to cc (V.Ivantchenko) 59 // 12-09-08 Removed InitialiseMassCharge and CorrectionsAlongStep (VI) 59 60 // 60 61 // Class Description: … … 72 73 73 74 #include "G4VEnergyLossProcess.hh" 74 #include "G4ionEffectiveCharge.hh"75 #include "G4VEmModel.hh"76 #include "G4EmCorrections.hh"77 75 78 76 class G4Material; 79 class G4PhysicsVector; 80 class G4BraggIonModel; 77 class G4EmCorrections; 81 78 82 79 class G4ionIonisation : public G4VEnergyLossProcess … … 88 85 virtual ~G4ionIonisation(); 89 86 90 inlineG4bool IsApplicable(const G4ParticleDefinition& p);87 virtual G4bool IsApplicable(const G4ParticleDefinition& p); 91 88 92 89 // Print out of the class parameters … … 94 91 95 92 void AddStoppingData(G4int Z, G4int A, const G4String& materialName, 96 G4PhysicsVector &dVector);93 G4PhysicsVector* dVector); 97 94 98 95 void ActivateStoppingData(G4bool); … … 105 102 const G4ParticleDefinition*); 106 103 107 virtual void CorrectionsAlongStep(const G4MaterialCutsCouple*, 108 const G4DynamicParticle*, 109 G4double& eloss, 110 G4double& length); 111 112 inline void InitialiseMassCharge(const G4Track&); 113 114 inline G4double MinPrimaryEnergy(const G4ParticleDefinition* p, 104 virtual G4double MinPrimaryEnergy(const G4ParticleDefinition* p, 115 105 const G4Material*, G4double cut); 116 106 … … 118 108 119 109 inline G4bool NuclearStoppingFlag(); 120 121 // protected pointers122 G4ionEffectiveCharge* effCharge;123 G4EmCorrections* corr;124 110 125 111 private: … … 129 115 G4ionIonisation(const G4ionIonisation&); 130 116 131 // cash 132 const G4Material* curMaterial; 133 const G4ParticleDefinition* curParticle; 117 G4EmCorrections* corr; 118 134 119 const G4ParticleDefinition* theParticle; 135 const G4ParticleDefinition* theBaseParticle;136 120 137 G4double preKinEnergy;121 G4double eth; 138 122 139 G4double eth; 140 G4double baseMass; 141 G4double massRatio; 142 G4double massFactor; 143 G4double charge2; 144 145 G4bool isInitialised; 146 G4bool stopDataActive; 147 G4bool nuclearStopping; 123 G4bool isInitialised; 124 G4bool stopDataActive; 125 G4bool nuclearStopping; 148 126 }; 149 127 150 128 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 151 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....152 153 inline G4bool G4ionIonisation::IsApplicable(const G4ParticleDefinition& p)154 {155 return (p.GetPDGCharge() != 0.0 && !p.IsShortLived() &&156 p.GetParticleType() == "nucleus");157 }158 159 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....160 161 inline G4double G4ionIonisation::MinPrimaryEnergy(162 const G4ParticleDefinition*, const G4Material*, G4double cut)163 {164 G4double x = 0.5*cut/electron_mass_c2;165 G4double g = std::sqrt(1. + x);166 return proton_mass_c2*(g - 1.0);167 }168 169 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....170 171 inline void G4ionIonisation::InitialiseMassCharge(const G4Track& track)172 {173 preKinEnergy = track.GetKineticEnergy();174 massRatio = baseMass/track.GetDynamicParticle()->GetMass();175 charge2 = effCharge->EffectiveChargeSquareRatio(track.GetDefinition(),176 track.GetMaterial(),177 preKinEnergy);178 SetDynamicMassCharge(massRatio, charge2);179 }180 181 129 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 182 130
Note: See TracChangeset
for help on using the changeset viewer.