Geant4  v4-10.4-release
 모두 클래스 네임스페이스들 파일들 함수 변수 타입정의 열거형 타입 열거형 멤버 Friends 매크로 그룹들 페이지들
G4MuPairProductionModel.hh
이 파일의 문서화 페이지로 가기
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 // $Id: G4MuPairProductionModel.hh 103220 2017-03-22 11:35:04Z gcosmo $
27 //
28 // -------------------------------------------------------------------
29 //
30 // GEANT4 Class header file
31 //
32 //
33 // File name: G4MuPairProductionModel
34 //
35 // Author: Vladimir Ivanchenko on base of Laszlo Urban code
36 //
37 // Creation date: 18.05.2002
38 //
39 // Modifications:
40 //
41 // 23-12-02 Change interface in order to move to cut per region (V.Ivanchenko)
42 // 27-01-03 Make models region aware (V.Ivanchenko)
43 // 13-02-03 Add name (V.Ivanchenko)
44 // 10-02-04 Update parameterisation using R.Kokoulin model (V.Ivanchenko)
45 // 10-02-04 Add lowestKinEnergy (V.Ivanchenko)
46 // 13-02-06 Add ComputeCrossSectionPerAtom (mma)
47 // 12-05-06 Add parameter to SelectRandomAtom (A.Bogdanov)
48 // 11-10-07 Add ignoreCut flag (V.Ivanchenko)
49 // 28-02-08 Reorganized protected methods and members (V.Ivanchenko)
50 
51 //
52 // Class Description:
53 //
54 // Implementation of e+e- pair production by muons
55 //
56 
57 // -------------------------------------------------------------------
58 //
59 
60 #ifndef G4MuPairProductionModel_h
61 #define G4MuPairProductionModel_h 1
62 
63 #include "G4VEmModel.hh"
64 #include "G4NistManager.hh"
65 #include "G4ElementData.hh"
66 #include "G4Physics2DVector.hh"
67 #include <vector>
68 
69 class G4Element;
72 
74 {
75 public:
76 
77  explicit G4MuPairProductionModel(const G4ParticleDefinition* p = nullptr,
78  const G4String& nam = "muPairProd");
79 
80  virtual ~G4MuPairProductionModel();
81 
82  virtual void Initialise(const G4ParticleDefinition*,
83  const G4DataVector&) override;
84 
85  virtual void InitialiseLocal(const G4ParticleDefinition*,
86  G4VEmModel* masterModel) override;
87 
89  const G4ParticleDefinition*,
92  G4double cutEnergy,
93  G4double maxEnergy) override;
94 
96  const G4ParticleDefinition*,
97  G4double kineticEnergy,
98  G4double cutEnergy) override;
99 
100  virtual void SampleSecondaries(std::vector<G4DynamicParticle*>*,
101  const G4MaterialCutsCouple*,
102  const G4DynamicParticle*,
103  G4double tmin,
104  G4double maxEnergy) override;
105 
106  virtual G4double MinPrimaryEnergy(const G4Material*,
107  const G4ParticleDefinition*,
108  G4double) override;
109 
110  inline void SetLowestKineticEnergy(G4double e);
111 
112  inline void SetParticle(const G4ParticleDefinition*);
113 
114 protected:
115 
117  G4double tmax);
118 
120  G4double Z,
121  G4double cut);
122 
123  virtual G4double
125  G4double pairEnergy);
126 
127  inline G4double MaxSecondaryEnergyForElement(G4double kineticEnergy,
128  G4double Z);
129 
130 private:
131 
132  void MakeSamplingTables();
133 
134  void DataCorrupted(G4int Z, G4double logTkin);
135 
136  inline G4double FindScaledEnergy(G4int Z, G4double rand, G4double logTkin,
137  G4double yymin, G4double yymax);
138 
139  // hide assignment operator
142 
143 protected:
144 
147 
155 
156  static const G4double xgi[8],wgi[8];
157 
161 
164 
166 
167  // gamma energy bins
169  size_t nbiny;
170  size_t nbine;
175 };
176 
177 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
178 
180 {
181  lowestKinEnergy = e;
182 }
183 
184 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
185 
186 inline
188 {
189  if(!particle) {
190  particle = p;
192  }
193 }
194 
195 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
196 
197 inline G4double
199  G4double ZZ)
200 {
201  G4int Z = G4lrint(ZZ);
202  if(Z != currentZ) {
203  currentZ = Z;
204  z13 = nist->GetZ13(Z);
205  z23 = z13*z13;
206  lnZ = nist->GetLOGZ(Z);
207  }
208  return kineticEnergy + particleMass*(1.0 - 0.75*sqrte*z13);
209 }
210 
211 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
212 
213 inline G4double
215  G4double logTkin,
216  G4double yymin, G4double yymax)
217 {
218  G4double res = yymin;
220  if(!pv) {
221  DataCorrupted(Z, logTkin);
222  } else {
223  G4double pmin = pv->Value(yymin, logTkin);
224  G4double pmax = pv->Value(yymax, logTkin);
225  G4double p0 = pv->Value(0.0, logTkin);
226  if(p0 <= 0.0) { DataCorrupted(Z, logTkin); }
227  else { res = pv->FindLinearX((pmin + rand*(pmax - pmin))/p0, logTkin); }
228  }
229  return res;
230 }
231 
232 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
233 
234 #endif
virtual G4double MinPrimaryEnergy(const G4Material *, const G4ParticleDefinition *, G4double) override
virtual void SampleSecondaries(std::vector< G4DynamicParticle * > *, const G4MaterialCutsCouple *, const G4DynamicParticle *, G4double tmin, G4double maxEnergy) override
G4double FindScaledEnergy(G4int Z, G4double rand, G4double logTkin, G4double yymin, G4double yymax)
const char * p
Definition: xmltok.h:285
G4ParticleChangeForLoss * fParticleChange
G4ElementData * fElementData
Definition: G4VEmModel.hh:430
virtual void InitialiseLocal(const G4ParticleDefinition *, G4VEmModel *masterModel) override
G4MuPairProductionModel & operator=(const G4MuPairProductionModel &right)=delete
G4double GetLOGZ(G4int Z) const
virtual G4double ComputeDEDXPerVolume(const G4Material *, const G4ParticleDefinition *, G4double kineticEnergy, G4double cutEnergy) override
G4double ComputMuPairLoss(G4double Z, G4double tkin, G4double cut, G4double tmax)
G4double GetPDGMass() const
Float_t Z
double G4double
Definition: G4Types.hh:76
G4double FindLinearX(G4double rand, G4double y, size_t &lastidy) const
G4Physics2DVector * GetElement2DData(G4int Z)
double A(double temperature)
G4double MaxSecondaryEnergyForElement(G4double kineticEnergy, G4double Z)
G4double ComputeMicroscopicCrossSection(G4double tkin, G4double Z, G4double cut)
virtual void Initialise(const G4ParticleDefinition *, const G4DataVector &) override
G4double Value(G4double x, G4double y, size_t &lastidx, size_t &lastidy) const
int G4lrint(double ad)
Definition: templates.hh:151
int G4int
Definition: G4Types.hh:78
static const G4double wgi[8]
const G4ParticleDefinition * particle
void SetParticle(const G4ParticleDefinition *)
G4MuPairProductionModel(const G4ParticleDefinition *p=nullptr, const G4String &nam="muPairProd")
G4double GetZ13(G4double Z) const
virtual G4double ComputeCrossSectionPerAtom(const G4ParticleDefinition *, G4double kineticEnergy, G4double Z, G4double A, G4double cutEnergy, G4double maxEnergy) override
G4ParticleDefinition * theElectron
void DataCorrupted(G4int Z, G4double logTkin)
G4ParticleDefinition * thePositron
static const G4double xgi[8]
virtual G4double ComputeDMicroscopicCrossSection(G4double tkin, G4double Z, G4double pairEnergy)