Geant4 Cross Reference |
1 // 1 // 2 // ******************************************* 2 // ******************************************************************** 3 // * License and Disclaimer 3 // * License and Disclaimer * 4 // * 4 // * * 5 // * The Geant4 software is copyright of th 5 // * The Geant4 software is copyright of the Copyright Holders of * 6 // * the Geant4 Collaboration. It is provided 6 // * the Geant4 Collaboration. It is provided under the terms and * 7 // * conditions of the Geant4 Software License 7 // * conditions of the Geant4 Software License, included in the file * 8 // * LICENSE and available at http://cern.ch/ 8 // * LICENSE and available at http://cern.ch/geant4/license . These * 9 // * include a list of copyright holders. 9 // * include a list of copyright holders. * 10 // * 10 // * * 11 // * Neither the authors of this software syst 11 // * Neither the authors of this software system, nor their employing * 12 // * institutes,nor the agencies providing fin 12 // * institutes,nor the agencies providing financial support for this * 13 // * work make any representation or warran 13 // * work make any representation or warranty, express or implied, * 14 // * regarding this software system or assum 14 // * regarding this software system or assume any liability for its * 15 // * use. Please see the license in the file 15 // * use. Please see the license in the file LICENSE and URL above * 16 // * for the full disclaimer and the limitatio 16 // * for the full disclaimer and the limitation of liability. * 17 // * 17 // * * 18 // * This code implementation is the result 18 // * This code implementation is the result of the scientific and * 19 // * technical work of the GEANT4 collaboratio 19 // * technical work of the GEANT4 collaboration. * 20 // * By using, copying, modifying or distri 20 // * By using, copying, modifying or distributing the software (or * 21 // * any work based on the software) you ag 21 // * any work based on the software) you agree to acknowledge its * 22 // * use in resulting scientific publicati 22 // * use in resulting scientific publications, and indicate your * 23 // * acceptance of all terms of the Geant4 Sof 23 // * acceptance of all terms of the Geant4 Software license. * 24 // ******************************************* 24 // ******************************************************************** 25 // 25 // >> 26 // $Id: G4VEmProcess.hh,v 1.43 2007/10/29 08:38:58 vnivanch Exp $ >> 27 // GEANT4 tag $Name: geant4-09-01 $ >> 28 // 26 // ------------------------------------------- 29 // ------------------------------------------------------------------- 27 // 30 // 28 // GEANT4 Class header file 31 // GEANT4 Class header file 29 // 32 // 30 // 33 // 31 // File name: G4VEmProcess 34 // File name: G4VEmProcess 32 // 35 // 33 // Author: Vladimir Ivanchenko 36 // Author: Vladimir Ivanchenko 34 // 37 // 35 // Creation date: 01.10.2003 38 // Creation date: 01.10.2003 36 // 39 // 37 // Modifications: Vladimir Ivanchenko << 40 // Modifications: >> 41 // 30-06-04 make destructor virtual (V.Ivanchenko) >> 42 // 09-08-04 optimise integral option (V.Ivanchenko) >> 43 // 11-08-04 add protected methods to access cuts (V.Ivanchenko) >> 44 // 09-09-04 Bug fix for the integral mode with 2 peaks (V.Ivanchneko) >> 45 // 16-09-04 Add flag for LambdaTable and method RecalculateLambda (VI) >> 46 // 08-11-04 Migration to new interface of Store/Retrieve tables (V.Ivantchenko) >> 47 // 08-04-05 Major optimisation of internal interfaces (V.Ivantchenko) >> 48 // 18-04-05 Use G4ParticleChangeForGamma (V.Ivantchenko) >> 49 // 09-05-05 Fix problem in logic when path boundary between materials (VI) >> 50 // 11-01-06 add A to parameters of ComputeCrossSectionPerAtom (VI) >> 51 // 01-02-06 put default value A=0. to keep compatibility with v5.2 (mma) >> 52 // 13-05-06 Add method to access model by index (V.Ivanchenko) >> 53 // 12-09-06 add SetModel() (mma) >> 54 // 25-09-07 More accurate handling zero xsect in >> 55 // PostStepGetPhysicalInteractionLength (V.Ivanchenko) >> 56 // 27-10-07 Virtual functions moved to source (V.Ivanchenko) 38 // 57 // 39 // Class Description: 58 // Class Description: 40 // 59 // 41 // It is the base class - EM discrete and rest << 60 // It is the unified Discrete process 42 61 43 // ------------------------------------------- 62 // ------------------------------------------------------------------- 44 // 63 // 45 64 46 #ifndef G4VEmProcess_h 65 #ifndef G4VEmProcess_h 47 #define G4VEmProcess_h 1 66 #define G4VEmProcess_h 1 48 67 49 #include <CLHEP/Units/SystemOfUnits.h> << 50 << 51 #include "G4VDiscreteProcess.hh" 68 #include "G4VDiscreteProcess.hh" 52 #include "globals.hh" 69 #include "globals.hh" 53 #include "G4Material.hh" 70 #include "G4Material.hh" 54 #include "G4MaterialCutsCouple.hh" 71 #include "G4MaterialCutsCouple.hh" 55 #include "G4Track.hh" 72 #include "G4Track.hh" >> 73 #include "G4EmModelManager.hh" 56 #include "G4UnitsTable.hh" 74 #include "G4UnitsTable.hh" 57 #include "G4ParticleDefinition.hh" 75 #include "G4ParticleDefinition.hh" 58 #include "G4ParticleChangeForGamma.hh" 76 #include "G4ParticleChangeForGamma.hh" 59 #include "G4EmParameters.hh" << 60 #include "G4EmDataHandler.hh" << 61 #include "G4EmTableType.hh" << 62 #include "G4EmModelManager.hh" << 63 #include "G4EmSecondaryParticleType.hh" << 64 77 65 class G4Step; 78 class G4Step; 66 class G4VEmModel; 79 class G4VEmModel; 67 class G4DataVector; 80 class G4DataVector; 68 class G4VParticleChange; 81 class G4VParticleChange; 69 class G4PhysicsTable; 82 class G4PhysicsTable; 70 class G4PhysicsVector; 83 class G4PhysicsVector; 71 class G4EmBiasingManager; << 72 class G4LossTableManager; << 73 84 74 //....oooOO0OOooo........oooOO0OOooo........oo 85 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 75 86 76 class G4VEmProcess : public G4VDiscreteProcess 87 class G4VEmProcess : public G4VDiscreteProcess 77 { 88 { 78 public: 89 public: 79 90 80 G4VEmProcess(const G4String& name, G4Process << 91 G4VEmProcess(const G4String& name, >> 92 G4ProcessType type = fElectromagnetic); 81 93 82 ~G4VEmProcess() override; << 94 virtual ~G4VEmProcess(); 83 95 84 //------------------------------------------ 96 //------------------------------------------------------------------------ 85 // Virtual methods to be implemented in conc 97 // Virtual methods to be implemented in concrete processes 86 //------------------------------------------ 98 //------------------------------------------------------------------------ 87 99 88 void ProcessDescription(std::ostream& outFil << 100 virtual G4bool IsApplicable(const G4ParticleDefinition& p) = 0; 89 101 90 protected: << 102 virtual void PrintInfo() = 0; 91 103 92 virtual void StreamProcessInfo(std::ostream& << 104 protected: 93 105 94 virtual void InitialiseProcess(const G4Parti 106 virtual void InitialiseProcess(const G4ParticleDefinition*) = 0; 95 107 96 //------------------------------------------ 108 //------------------------------------------------------------------------ 97 // Implementation of virtual methods common << 109 // Methods with standard implementation; may be overwritten if needed 98 //------------------------------------------ 110 //------------------------------------------------------------------------ 99 111 100 public: << 112 inline G4double RecalculateLambda(G4double kinEnergy, >> 113 const G4MaterialCutsCouple* couple); 101 114 102 // Initialise for build of tables << 115 //------------------------------------------------------------------------ 103 void PreparePhysicsTable(const G4ParticleDef << 116 // Generic methods common to all Discrete processes >> 117 //------------------------------------------------------------------------ 104 118 105 // Build physics table during initialisation << 119 public: 106 void BuildPhysicsTable(const G4ParticleDefin << 107 120 108 // Called before tracking of each new G4Trac << 121 void PrintInfoDefinition(); 109 void StartTracking(G4Track*) override; << 110 122 111 // implementation of virtual method, specifi << 123 G4VParticleChange* PostStepDoIt(const G4Track&, const G4Step&); 112 G4double PostStepGetPhysicalInteractionLengt << 124 113 const G4Track& tr << 125 void PreparePhysicsTable(const G4ParticleDefinition&); 114 G4double previo << 126 // Initialise for build of tables 115 G4ForceCondition* << 116 127 117 // implementation of virtual method, specifi << 128 void BuildPhysicsTable(const G4ParticleDefinition&); 118 G4VParticleChange* PostStepDoIt(const G4Trac << 129 // Build physics table during initialisation 119 130 >> 131 G4bool StorePhysicsTable(const G4ParticleDefinition*, >> 132 const G4String& directory, >> 133 G4bool ascii = false); 120 // Store PhysicsTable in a file. 134 // Store PhysicsTable in a file. 121 // Return false in case of failure at I/O 135 // Return false in case of failure at I/O 122 G4bool StorePhysicsTable(const G4ParticleDef << 123 const G4String& dir << 124 G4bool ascii = fals << 125 136 126 // Retrieve Physics from a file. << 127 // (return true if the Physics Table can be << 128 // (return false if the process has no funct << 129 // File name should is constructed as proces << 130 // should be placed under the directory spec << 131 G4bool RetrievePhysicsTable(const G4Particle 137 G4bool RetrievePhysicsTable(const G4ParticleDefinition*, 132 const G4String& << 138 const G4String& directory, 133 G4bool ascii) ov << 139 G4bool ascii); 134 << 140 // Retrieve Physics from a file. 135 // allowing check process name << 141 // (return true if the Physics Table can be build by using file) 136 virtual G4VEmProcess* GetEmProcess(const G4S << 142 // (return false if the process has no functionality or in case of failure) >> 143 // File name should is constructed as processName+particleName and the >> 144 // should be placed under the directory specifed by the argument. 137 145 138 //------------------------------------------ 146 //------------------------------------------------------------------------ 139 // Specific methods for Discrete EM post ste 147 // Specific methods for Discrete EM post step simulation 140 //------------------------------------------ 148 //------------------------------------------------------------------------ 141 149 142 // The main method to access cross section p << 150 inline G4double MicroscopicCrossSection(G4double kineticEnergy, 143 inline G4double GetLambda(G4double kinEnergy << 151 const G4MaterialCutsCouple* couple); 144 const G4MaterialCu << 152 // It returns the cross section of the process for energy/ material 145 G4double logKinEne << 153 146 << 154 inline G4double ComputeCrossSectionPerAtom(G4double kineticEnergy, 147 // It returns the cross section per volume f << 155 G4double Z, G4double A=0., 148 G4double GetCrossSection(const G4double kinE << 156 G4double cut=0.0); 149 const G4MaterialCut << 150 << 151 // It returns the cross section of the proce 157 // It returns the cross section of the process per atom 152 G4double ComputeCrossSectionPerAtom(G4double << 153 G4double << 154 G4double << 155 158 156 inline G4double MeanFreePath(const G4Track& 159 inline G4double MeanFreePath(const G4Track& track); 157 160 >> 161 virtual G4double PostStepGetPhysicalInteractionLength( >> 162 const G4Track& track, >> 163 G4double previousStepSize, >> 164 G4ForceCondition* condition >> 165 ); >> 166 >> 167 inline G4VEmModel* SelectModelForMaterial(G4double kinEnergy, >> 168 size_t& idxRegion) const; >> 169 >> 170 inline G4double GetLambda(G4double& kinEnergy, >> 171 const G4MaterialCutsCouple* couple); >> 172 // It returns the Lambda of the process >> 173 158 //------------------------------------------ 174 //------------------------------------------------------------------------ 159 // Specific methods to build and access Phys 175 // Specific methods to build and access Physics Tables 160 //------------------------------------------ 176 //------------------------------------------------------------------------ 161 177 >> 178 inline void SetLambdaBinning(G4int nbins); >> 179 inline G4int LambdaBinning() const; 162 // Binning for lambda table 180 // Binning for lambda table 163 void SetLambdaBinning(G4int nbins); << 164 181 >> 182 inline void SetMinKinEnergy(G4double e); >> 183 inline G4double MinKinEnergy() const; 165 // Min kinetic energy for tables 184 // Min kinetic energy for tables 166 void SetMinKinEnergy(G4double e); << 167 << 168 // Min kinetic energy for high energy table << 169 void SetMinKinEnergyPrim(G4double e); << 170 185 >> 186 inline void SetMaxKinEnergy(G4double e); >> 187 inline G4double MaxKinEnergy() const; 171 // Max kinetic energy for tables 188 // Max kinetic energy for tables 172 void SetMaxKinEnergy(G4double e); << 173 189 174 // Cross section table pointers << 190 inline const G4PhysicsTable* LambdaTable() const; 175 inline G4PhysicsTable* LambdaTable() const; << 176 inline G4PhysicsTable* LambdaTablePrim() con << 177 inline void SetLambdaTable(G4PhysicsTable*); << 178 inline void SetLambdaTablePrim(G4PhysicsTabl << 179 << 180 // Integral method type and peak positions << 181 inline std::vector<G4double>* EnergyOfCrossS << 182 inline void SetEnergyOfCrossSectionMax(std:: << 183 inline G4CrossSectionType CrossSectionType() << 184 inline void SetCrossSectionType(G4CrossSecti << 185 191 186 //------------------------------------------ 192 //------------------------------------------------------------------------ 187 // Define and access particle type 193 // Define and access particle type 188 //------------------------------------------ 194 //------------------------------------------------------------------------ 189 195 190 inline const G4ParticleDefinition* Particle( 196 inline const G4ParticleDefinition* Particle() const; 191 inline const G4ParticleDefinition* Secondary 197 inline const G4ParticleDefinition* SecondaryParticle() const; 192 198 193 protected: << 194 << 195 //------------------------------------------ 199 //------------------------------------------------------------------------ 196 // Specific methods to set, access, modify m << 200 // Specific methods to set, access, modify models 197 //------------------------------------------ 201 //------------------------------------------------------------------------ 198 << 199 // Select model in run time << 200 inline G4VEmModel* SelectModel(G4double kinE << 201 << 202 public: << 203 202 204 // Select model by energy and couple index << 203 inline void AddEmModel(G4int, G4VEmModel*, const G4Region* region = 0); 205 inline G4VEmModel* SelectModelForMaterial(G4 << 204 // Add EM model coupled for the region 206 st << 207 205 208 // Add model for region, smaller value of or << 206 inline void SetModel(G4VEmModel*); 209 // model will be selected for a given energy << 207 // Assign a model to a process 210 void AddEmModel(G4int, G4VEmModel*, const G4 << 208 211 << 209 inline G4VEmModel* Model(); 212 // Assign a model to a process local list, t << 210 // return the assigned model 213 // the derived process should execute AddEmM << 211 214 void SetEmModel(G4VEmModel*, G4int index = 0 << 212 inline void UpdateEmModel(const G4String&, G4double, G4double); 215 << 213 // Define new energy range for the model identified by the name 216 inline G4int NumberOfModels() const; << 217 << 218 // return a model from the local list << 219 inline G4VEmModel* EmModel(std::size_t index << 220 << 221 // Access to active model << 222 inline const G4VEmModel* GetCurrentModel() c << 223 214 224 // Access to models 215 // Access to models 225 inline G4VEmModel* GetModelByIndex(G4int idx << 216 inline G4VEmModel* GetModelByIndex(G4int idx = 0); 226 << 227 // Access to the current G4Element << 228 const G4Element* GetCurrentElement() const; << 229 << 230 // Biasing parameters << 231 void SetCrossSectionBiasingFactor(G4double f << 232 inline G4double CrossSectionBiasingFactor() << 233 << 234 // Activate forced interaction << 235 void ActivateForcedInteraction(G4double leng << 236 const G4Strin << 237 G4bool flag = << 238 217 239 void ActivateSecondaryBiasing(const G4String << 218 //------------------------------------------------------------------------ 240 G4double energ << 219 // Get/set parameters used for simulation of energy loss 241 << 220 //------------------------------------------------------------------------ 242 inline void SetEmMasterProcess(const G4VEmPr << 243 << 244 inline void SetBuildTableFlag(G4bool val); << 245 << 246 inline void CurrentSetup(const G4MaterialCut << 247 << 248 inline G4bool UseBaseMaterial() const; << 249 221 250 void BuildLambdaTable(); << 222 inline void ActivateDeexcitation(G4bool, const G4Region* r = 0); 251 223 252 void StreamInfo(std::ostream& outFile, const << 224 inline void SetLambdaFactor(G4double val); 253 G4bool rst=false) const; << 254 225 255 // hide copy constructor and assignment oper << 226 inline void SetIntegral(G4bool val); 256 G4VEmProcess(G4VEmProcess &) = delete; << 227 inline G4bool IsIntegral() const; 257 G4VEmProcess & operator=(const G4VEmProcess << 258 228 259 //------------------------------------------ << 229 inline void SetApplyCuts(G4bool val); 260 // Other generic methods << 261 //------------------------------------------ << 262 230 263 protected: 231 protected: 264 232 265 G4double GetMeanFreePath(const G4Track& trac 233 G4double GetMeanFreePath(const G4Track& track, 266 G4double previousSt << 234 G4double previousStepSize, 267 G4ForceCondition* c << 235 G4ForceCondition* condition); 268 236 269 G4PhysicsVector* LambdaPhysicsVector(const G 237 G4PhysicsVector* LambdaPhysicsVector(const G4MaterialCutsCouple*); 270 238 271 inline void DefineMaterial(const G4MaterialC << 272 << 273 inline G4int LambdaBinning() const; << 274 << 275 inline G4double MinKinEnergy() const; << 276 << 277 inline G4double MaxKinEnergy() const; << 278 << 279 // Single scattering parameters << 280 inline G4double PolarAngleLimit() const; << 281 << 282 inline G4ParticleChangeForGamma* GetParticle << 283 << 284 inline void SetParticle(const G4ParticleDefi 239 inline void SetParticle(const G4ParticleDefinition* p); 285 240 286 inline void SetSecondaryParticle(const G4Par 241 inline void SetSecondaryParticle(const G4ParticleDefinition* p); 287 242 288 inline std::size_t CurrentMaterialCutsCouple << 243 inline G4VEmModel* SelectModel(G4double& kinEnergy); 289 << 290 inline const G4MaterialCutsCouple* MaterialC << 291 244 292 inline G4bool ApplyCuts() const; << 245 inline size_t CurrentMaterialCutsCoupleIndex() const; 293 246 294 inline G4double GetGammaEnergyCut(); 247 inline G4double GetGammaEnergyCut(); 295 248 296 inline G4double GetElectronEnergyCut(); 249 inline G4double GetElectronEnergyCut(); 297 250 298 inline void SetStartFromNullFlag(G4bool val) << 251 inline void SetBuildTableFlag(G4bool val); 299 << 300 inline void SetSplineFlag(G4bool val); << 301 << 302 const G4Element* GetTargetElement() const; << 303 << 304 const G4Isotope* GetTargetIsotope() const; << 305 252 306 // these two methods assume that vectors are << 253 inline void SetStartFromNullFlag(G4bool val); 307 // and idx is within vector length << 308 inline G4int DensityIndex(G4int idx) const; << 309 inline G4double DensityFactor(G4int idx) con << 310 254 311 private: 255 private: 312 256 313 void PrintWarning(G4String tit, G4double val << 257 void Clear(); 314 258 315 void ComputeIntegralLambda(G4double kinEnerg << 259 void BuildLambdaTable(); 316 260 317 inline G4double LogEkin(const G4Track&); << 261 void FindLambdaMax(); 318 262 319 inline G4double GetLambdaFromTable(G4double << 263 inline void InitialiseStep(const G4Track&); 320 264 321 inline G4double GetLambdaFromTable(G4double << 265 inline void DefineMaterial(const G4MaterialCutsCouple* couple); 322 266 323 inline G4double GetLambdaFromTablePrim(G4dou << 267 inline void ComputeIntegralLambda(G4double kinEnergy); 324 268 325 inline G4double GetLambdaFromTablePrim(G4dou << 269 inline G4double GetLambdaFromTable(G4double kinEnergy); 326 270 327 inline G4double GetCurrentLambda(G4double ki 271 inline G4double GetCurrentLambda(G4double kinEnergy); 328 272 329 inline G4double GetCurrentLambda(G4double ki << 330 << 331 inline G4double ComputeCurrentLambda(G4doubl 273 inline G4double ComputeCurrentLambda(G4double kinEnergy); 332 274 333 // ======== pointers ========= << 275 // hide assignment operator 334 << 335 G4EmModelManager* modelManager = << 336 const G4ParticleDefinition* particle = null << 337 const G4ParticleDefinition* currentParticle << 338 const G4ParticleDefinition* theGamma = null << 339 const G4ParticleDefinition* theElectron = n << 340 const G4ParticleDefinition* thePositron = n << 341 const G4ParticleDefinition* secondaryPartic << 342 const G4VEmProcess* masterProc = nu << 343 G4EmDataHandler* theData = nullp << 344 G4VEmModel* currentModel = << 345 G4LossTableManager* lManager = null << 346 G4EmParameters* theParameters = << 347 const G4Material* baseMaterial = << 348 << 349 // ======== tables and vectors ======== << 350 G4PhysicsTable* theLambdaTable << 351 G4PhysicsTable* theLambdaTableP << 352 << 353 const std::vector<G4double>* theCuts = nullp << 354 const std::vector<G4double>* theCutsGamma = << 355 const std::vector<G4double>* theCutsElectron << 356 const std::vector<G4double>* theCutsPositron << 357 << 358 protected: << 359 << 360 // ======== pointers ========= << 361 << 362 const G4MaterialCutsCouple* currentCouple = << 363 const G4Material* currentMaterial << 364 G4EmBiasingManager* biasManager = n << 365 std::vector<G4double>* theEnergyOfCros << 366 << 367 private: << 368 << 369 const std::vector<G4double>* theDensityFacto << 370 const std::vector<G4int>* theDensityIdx = nu << 371 << 372 // ======== parameters ========= << 373 G4double minKinEnergy; << 374 G4double maxKinEnergy; << 375 G4double minKinEnergyPrim = DBL_MAX; << 376 G4double lambdaFactor = 0.8; << 377 G4double invLambdaFactor; << 378 G4double biasFactor = 1.0; << 379 G4double massRatio = 1.0; << 380 G4double fFactor = 1.0; << 381 G4double fLambda = 0.0; << 382 G4double fLambdaEnergy = 0.0; << 383 << 384 protected: << 385 << 386 G4double mfpKinEnergy = DBL_MAX; << 387 G4double preStepKinEnergy = 0.0; << 388 G4double preStepLambda = 0.0; << 389 << 390 private: << 391 276 392 G4CrossSectionType fXSType = fEmNoIntegral; << 277 G4VEmProcess(G4VEmProcess &); >> 278 G4VEmProcess & operator=(const G4VEmProcess &right); 393 279 394 G4int numberOfModels = 0; << 280 // ===================================================================== 395 G4int nLambdaBins = 84; << 396 281 397 protected: 282 protected: 398 283 399 G4int mainSecondaries = 1; << 284 G4ParticleChangeForGamma fParticleChange; 400 G4int secID = _EM; << 401 G4int fluoID = _Fluorescence; << 402 G4int augerID = _AugerElectron; << 403 G4int biasID = _EM; << 404 G4int tripletID = _TripletElectron; << 405 std::size_t currentCoupleIndex = 0; << 406 std::size_t basedCoupleIndex = 0; << 407 std::size_t coupleIdxLambda = 0; << 408 std::size_t idxLambda = 0; << 409 << 410 G4bool isTheMaster = false; << 411 G4bool baseMat = false; << 412 285 413 private: 286 private: 414 287 415 G4bool buildLambdaTable = true; << 416 G4bool applyCuts = false; << 417 G4bool startFromNull = false; << 418 G4bool splineFlag = true; << 419 G4bool actMinKinEnergy = false; << 420 G4bool actMaxKinEnergy = false; << 421 G4bool actBinning = false; << 422 G4bool isIon = false; << 423 G4bool biasFlag = false; << 424 G4bool weightFlag = false; << 425 << 426 protected: << 427 << 428 // ======== particle change ========= << 429 std::vector<G4DynamicParticle*> secParticles 288 std::vector<G4DynamicParticle*> secParticles; 430 G4ParticleChangeForGamma fParticleChange; << 431 289 432 private: << 290 G4EmModelManager* modelManager; >> 291 G4VEmModel* selectedModel; 433 292 434 // ======== local vectors ========= << 293 // tables and vectors 435 std::vector<G4VEmModel*> emModels; << 294 G4PhysicsTable* theLambdaTable; >> 295 G4double* theEnergyOfCrossSectionMax; >> 296 G4double* theCrossSectionMax; >> 297 >> 298 const G4ParticleDefinition* particle; >> 299 const G4ParticleDefinition* secondaryParticle; >> 300 const G4ParticleDefinition* theGamma; >> 301 const G4ParticleDefinition* theElectron; >> 302 const G4ParticleDefinition* thePositron; >> 303 >> 304 const std::vector<G4double>* theCuts; >> 305 const std::vector<G4double>* theCutsGamma; >> 306 const std::vector<G4double>* theCutsElectron; >> 307 const std::vector<G4double>* theCutsPositron; >> 308 >> 309 G4int nLambdaBins; >> 310 >> 311 G4double minKinEnergy; >> 312 G4double maxKinEnergy; >> 313 G4double lambdaFactor; >> 314 >> 315 // cash >> 316 const G4Material* currentMaterial; >> 317 const G4MaterialCutsCouple* currentCouple; >> 318 size_t currentMaterialIndex; >> 319 >> 320 G4double mfpKinEnergy; >> 321 G4double preStepKinEnergy; >> 322 G4double preStepLambda; >> 323 >> 324 G4bool integral; >> 325 G4bool buildLambdaTable; >> 326 G4bool applyCuts; >> 327 G4bool startFromNull; >> 328 >> 329 G4int nRegions; >> 330 std::vector<G4Region*> regions; >> 331 std::vector<G4bool> flagsDeexcitation; 436 332 437 }; 333 }; 438 334 439 // ======== Run time inline methods ========== << 440 << 441 //....oooOO0OOooo........oooOO0OOooo........oo << 442 << 443 inline std::size_t G4VEmProcess::CurrentMateri << 444 { << 445 return currentCoupleIndex; << 446 } << 447 << 448 //....oooOO0OOooo........oooOO0OOooo........oo << 449 << 450 inline const G4MaterialCutsCouple* G4VEmProces << 451 { << 452 return currentCouple; << 453 } << 454 << 455 //....oooOO0OOooo........oooOO0OOooo........oo << 456 << 457 inline G4double G4VEmProcess::GetGammaEnergyCu << 458 { << 459 return (*theCutsGamma)[currentCoupleIndex]; << 460 } << 461 << 462 //....oooOO0OOooo........oooOO0OOooo........oo 335 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 463 << 464 inline G4double G4VEmProcess::GetElectronEnerg << 465 { << 466 return (*theCutsElectron)[currentCoupleIndex << 467 } << 468 << 469 //....oooOO0OOooo........oooOO0OOooo........oo 336 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 470 337 471 inline void G4VEmProcess::DefineMaterial(const 338 inline void G4VEmProcess::DefineMaterial(const G4MaterialCutsCouple* couple) 472 { 339 { 473 if (couple != currentCouple) { << 340 if(couple != currentCouple) { 474 currentCouple = couple; << 341 currentCouple = couple; 475 baseMaterial = currentMaterial = couple->G << 342 currentMaterial = couple->GetMaterial(); 476 basedCoupleIndex = currentCoupleIndex = co << 343 currentMaterialIndex = couple->GetIndex(); 477 fFactor = biasFactor; << 478 mfpKinEnergy = DBL_MAX; 344 mfpKinEnergy = DBL_MAX; 479 if (baseMat) { << 480 basedCoupleIndex = (*theDensityIdx)[curr << 481 if (nullptr != currentMaterial->GetBaseM << 482 baseMaterial = currentMaterial->GetBas << 483 fFactor *= (*theDensityFactor)[currentCo << 484 } << 485 } << 486 } << 487 << 488 //....oooOO0OOooo........oooOO0OOooo........oo << 489 << 490 inline << 491 G4VEmModel* G4VEmProcess::SelectModel(G4double << 492 { << 493 if(1 < numberOfModels) { << 494 currentModel = modelManager->SelectModel(k << 495 } 345 } 496 currentModel->SetCurrentCouple(currentCouple << 497 return currentModel; << 498 } << 499 << 500 //....oooOO0OOooo........oooOO0OOooo........oo << 501 << 502 inline << 503 G4VEmModel* G4VEmProcess::SelectModelForMateri << 504 << 505 { << 506 return modelManager->SelectModel(kinEnergy, << 507 } << 508 << 509 //....oooOO0OOooo........oooOO0OOooo........oo << 510 << 511 inline G4double G4VEmProcess::GetLambdaFromTab << 512 { << 513 return ((*theLambdaTable)[basedCoupleIndex]) << 514 } 346 } 515 347 516 //....oooOO0OOooo........oooOO0OOooo........oo 348 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 517 349 518 inline G4double G4VEmProcess::LogEkin(const G4 << 350 inline void G4VEmProcess::InitialiseStep(const G4Track& track) 519 { 351 { 520 return track.GetDynamicParticle()->GetLogKin << 352 preStepKinEnergy = track.GetKineticEnergy(); >> 353 DefineMaterial(track.GetMaterialCutsCouple()); >> 354 if (theNumberOfInteractionLengthLeft < 0.0) mfpKinEnergy = DBL_MAX; 521 } 355 } 522 356 523 //....oooOO0OOooo........oooOO0OOooo........oo 357 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 524 358 525 inline G4double G4VEmProcess::GetLambdaFromTab << 359 inline G4double G4VEmProcess::GetLambda(G4double& kineticEnergy, >> 360 const G4MaterialCutsCouple* couple) 526 { 361 { 527 return ((*theLambdaTable)[basedCoupleIndex]) << 362 DefineMaterial(couple); >> 363 return GetCurrentLambda(kineticEnergy); 528 } 364 } 529 365 530 //....oooOO0OOooo........oooOO0OOooo........oo 366 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 531 367 532 inline G4double G4VEmProcess::GetLambdaFromTab << 368 inline G4double G4VEmProcess::GetCurrentLambda(G4double e) 533 { 369 { 534 return ((*theLambdaTablePrim)[basedCoupleInd << 370 G4double x = 0.0; >> 371 if(theLambdaTable) x = GetLambdaFromTable(e); >> 372 else x = ComputeCurrentLambda(e); >> 373 return x; 535 } 374 } 536 375 537 //....oooOO0OOooo........oooOO0OOooo........oo 376 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 538 377 539 inline G4double G4VEmProcess::GetLambdaFromTab << 378 inline G4double G4VEmProcess::RecalculateLambda(G4double e, >> 379 const G4MaterialCutsCouple* couple) 540 { 380 { 541 return ((*theLambdaTablePrim)[basedCoupleInd << 381 DefineMaterial(couple); >> 382 return ComputeCurrentLambda(e); 542 } 383 } 543 384 544 //....oooOO0OOooo........oooOO0OOooo........oo 385 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 545 386 546 inline G4double G4VEmProcess::ComputeCurrentLa 387 inline G4double G4VEmProcess::ComputeCurrentLambda(G4double e) 547 { 388 { 548 return currentModel->CrossSectionPerVolume(b << 389 G4VEmModel* currentModel = SelectModel(e); >> 390 G4double x = 0.0; >> 391 if(currentModel) >> 392 x = currentModel->CrossSectionPerVolume(currentMaterial,particle, >> 393 e,(*theCuts)[currentMaterialIndex]); >> 394 return x; 549 } 395 } 550 396 551 //....oooOO0OOooo........oooOO0OOooo........oo 397 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 552 398 553 inline G4double G4VEmProcess::GetCurrentLambda << 399 inline G4double G4VEmProcess::GetLambdaFromTable(G4double e) 554 { 400 { 555 if(currentCoupleIndex != coupleIdxLambda || << 401 G4bool b; 556 coupleIdxLambda = currentCoupleIndex; << 402 return (((*theLambdaTable)[currentMaterialIndex])->GetValue(e, b)); 557 fLambdaEnergy = e; << 558 if(e >= minKinEnergyPrim) { fLambda = GetL << 559 else if(nullptr != theLambdaTable) { fLamb << 560 else { fLambda = ComputeCurrentLambda(e); << 561 fLambda *= fFactor; << 562 } << 563 return fLambda; << 564 } 403 } 565 404 566 //....oooOO0OOooo........oooOO0OOooo........oo 405 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 567 406 568 inline G4double G4VEmProcess::GetCurrentLambda << 407 inline void G4VEmProcess::ComputeIntegralLambda(G4double e) 569 { 408 { 570 if(currentCoupleIndex != coupleIdxLambda || << 409 mfpKinEnergy = theEnergyOfCrossSectionMax[currentMaterialIndex]; 571 coupleIdxLambda = currentCoupleIndex; << 410 if (e <= mfpKinEnergy) { 572 fLambdaEnergy = e; << 411 preStepLambda = GetLambdaFromTable(e); 573 if(e >= minKinEnergyPrim) { fLambda = GetL << 412 574 else if(nullptr != theLambdaTable) { fLamb << 413 } else { 575 else { fLambda = ComputeCurrentLambda(e); << 414 G4double e1 = e*lambdaFactor; 576 fLambda *= fFactor; << 415 if(e1 > mfpKinEnergy) { >> 416 preStepLambda = GetLambdaFromTable(e); >> 417 G4double preStepLambda1 = GetLambdaFromTable(e1); >> 418 if(preStepLambda1 > preStepLambda) { >> 419 mfpKinEnergy = e1; >> 420 preStepLambda = preStepLambda1; >> 421 } >> 422 } else { >> 423 preStepLambda = theCrossSectionMax[currentMaterialIndex]; >> 424 } 577 } 425 } 578 return fLambda; << 579 } 426 } 580 427 581 //....oooOO0OOooo........oooOO0OOooo........oo 428 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 582 429 583 inline void << 430 inline G4double G4VEmProcess::MeanFreePath(const G4Track& track) 584 G4VEmProcess::CurrentSetup(const G4MaterialCut << 585 { 431 { 586 DefineMaterial(couple); << 432 DefineMaterial(track.GetMaterialCutsCouple()); 587 SelectModel(energy*massRatio, currentCoupleI << 433 preStepLambda = GetCurrentLambda(track.GetKineticEnergy()); >> 434 G4double x = DBL_MAX; >> 435 if(DBL_MIN < preStepLambda) x = 1.0/preStepLambda; >> 436 return x; 588 } 437 } 589 438 590 //....oooOO0OOooo........oooOO0OOooo........oo 439 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 591 440 592 inline G4double << 441 inline G4VEmModel* G4VEmProcess::SelectModel(G4double& kinEnergy) 593 G4VEmProcess::GetLambda(G4double kinEnergy, co << 594 G4double logKinEnergy) << 595 { 442 { 596 CurrentSetup(couple, kinEnergy); << 443 return modelManager->SelectModel(kinEnergy, currentMaterialIndex); 597 return GetCurrentLambda(kinEnergy, logKinEne << 598 } 444 } 599 445 600 //....oooOO0OOooo........oooOO0OOooo........oo 446 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 601 447 602 G4double G4VEmProcess::MeanFreePath(const G4Tr << 448 inline G4VEmModel* G4VEmProcess::SelectModelForMaterial( 603 { << 449 G4double kinEnergy, size_t& idxRegion) const 604 const G4double kinEnergy = track.GetKineticE << 605 CurrentSetup(track.GetMaterialCutsCouple(), << 606 const G4double xs = GetCurrentLambda(kinEner << 607 track.GetDynamicP << 608 return (0.0 < xs) ? 1.0/xs : DBL_MAX; << 609 } << 610 << 611 // ======== Get/Set inline methods used at ini << 612 << 613 inline G4bool G4VEmProcess::ApplyCuts() const << 614 { 450 { 615 return applyCuts; << 451 return modelManager->SelectModel(kinEnergy, idxRegion); 616 } 452 } 617 453 618 //....oooOO0OOooo........oooOO0OOooo........oo 454 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 619 455 620 inline G4int G4VEmProcess::LambdaBinning() con << 456 inline const G4ParticleDefinition* G4VEmProcess::Particle() const 621 { 457 { 622 return nLambdaBins; << 458 return particle; 623 } 459 } 624 460 625 //....oooOO0OOooo........oooOO0OOooo........oo 461 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 626 462 627 inline G4double G4VEmProcess::MinKinEnergy() c << 463 inline const G4ParticleDefinition* G4VEmProcess::SecondaryParticle() const 628 { 464 { 629 return minKinEnergy; << 465 return secondaryParticle; 630 } 466 } 631 467 632 //....oooOO0OOooo........oooOO0OOooo........oo 468 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 633 469 634 inline G4double G4VEmProcess::MaxKinEnergy() c << 470 inline G4double G4VEmProcess::GetGammaEnergyCut() 635 { 471 { 636 return maxKinEnergy; << 472 return (*theCutsGamma)[currentMaterialIndex]; 637 } 473 } 638 474 639 //....oooOO0OOooo........oooOO0OOooo........oo 475 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 640 476 641 inline G4double G4VEmProcess::CrossSectionBias << 477 inline G4double G4VEmProcess::GetElectronEnergyCut() 642 { 478 { 643 return biasFactor; << 479 return (*theCutsElectron)[currentMaterialIndex]; 644 } 480 } 645 481 646 //....oooOO0OOooo........oooOO0OOooo........oo 482 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 647 483 648 inline G4PhysicsTable* G4VEmProcess::LambdaTab << 484 inline void G4VEmProcess::SetLambdaFactor(G4double val) 649 { 485 { 650 return theLambdaTable; << 486 if(val > 0.0 && val <= 1.0) lambdaFactor = val; 651 } 487 } 652 488 653 //....oooOO0OOooo........oooOO0OOooo........oo 489 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 654 490 655 inline G4PhysicsTable* G4VEmProcess::LambdaTab << 491 inline G4VEmModel* G4VEmProcess::GetModelByIndex(G4int idx) 656 { 492 { 657 return theLambdaTablePrim; << 493 return modelManager->GetModel(idx); 658 } 494 } 659 495 660 //....oooOO0OOooo........oooOO0OOooo........oo 496 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 661 497 662 inline void G4VEmProcess::SetLambdaTable(G4Phy << 498 inline void G4VEmProcess::SetParticle(const G4ParticleDefinition* p) 663 { 499 { 664 theLambdaTable = ptr; << 500 particle = p; 665 } 501 } 666 502 667 //....oooOO0OOooo........oooOO0OOooo........oo 503 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 668 504 669 inline void G4VEmProcess::SetLambdaTablePrim(G << 505 inline void G4VEmProcess::SetSecondaryParticle(const G4ParticleDefinition* p) 670 { 506 { 671 theLambdaTablePrim = ptr; << 507 secondaryParticle = p; 672 } 508 } 673 509 674 //....oooOO0OOooo........oooOO0OOooo........oo 510 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 675 511 676 inline std::vector<G4double>* G4VEmProcess::En << 512 inline void G4VEmProcess::AddEmModel(G4int order, G4VEmModel* p, >> 513 const G4Region* region) 677 { 514 { 678 return theEnergyOfCrossSectionMax; << 515 G4VEmFluctuationModel* fm = 0; >> 516 modelManager->AddEmModel(order, p, fm, region); >> 517 if(p) p->SetParticleChange(pParticleChange); 679 } 518 } 680 519 681 //....oooOO0OOooo........oooOO0OOooo........oo 520 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 682 521 683 inline void << 522 inline void G4VEmProcess::SetModel(G4VEmModel* model) 684 G4VEmProcess::SetEnergyOfCrossSectionMax(std:: << 685 { 523 { 686 theEnergyOfCrossSectionMax = ptr; << 524 selectedModel = model; 687 } 525 } 688 526 689 //....oooOO0OOooo........oooOO0OOooo........oo 527 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 690 528 691 inline const G4ParticleDefinition* G4VEmProces << 529 inline G4VEmModel* G4VEmProcess::Model() 692 { 530 { 693 return particle; << 531 return selectedModel; 694 } 532 } 695 533 696 //....oooOO0OOooo........oooOO0OOooo........oo 534 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 697 535 698 inline const G4ParticleDefinition* G4VEmProces << 536 inline void G4VEmProcess::UpdateEmModel(const G4String& nam, >> 537 G4double emin, G4double emax) 699 { 538 { 700 return secondaryParticle; << 539 modelManager->UpdateEmModel(nam, emin, emax); 701 } 540 } 702 541 703 //....oooOO0OOooo........oooOO0OOooo........oo 542 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 704 543 705 inline void G4VEmProcess::SetCrossSectionType( << 544 inline G4double G4VEmProcess::ComputeCrossSectionPerAtom( >> 545 G4double kineticEnergy, G4double Z, G4double A, G4double cut) 706 { 546 { 707 fXSType = val; << 547 G4VEmModel* model = SelectModel(kineticEnergy); >> 548 return model->ComputeCrossSectionPerAtom(particle,kineticEnergy,Z,A,cut); 708 } 549 } 709 550 710 //....oooOO0OOooo........oooOO0OOooo........oo 551 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 711 552 712 inline G4CrossSectionType G4VEmProcess::CrossS << 553 inline void G4VEmProcess::SetLambdaBinning(G4int nbins) 713 { 554 { 714 return fXSType; << 555 nLambdaBins = nbins; 715 } 556 } 716 557 717 //....oooOO0OOooo........oooOO0OOooo........oo 558 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 718 559 719 inline void G4VEmProcess::SetBuildTableFlag(G4 << 560 inline G4int G4VEmProcess::LambdaBinning() const 720 { 561 { 721 buildLambdaTable = val; << 562 return nLambdaBins; 722 } 563 } 723 564 724 //....oooOO0OOooo........oooOO0OOooo........oo 565 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 725 566 726 inline G4ParticleChangeForGamma* G4VEmProcess: << 567 inline void G4VEmProcess::SetMinKinEnergy(G4double e) 727 { 568 { 728 return &fParticleChange; << 569 minKinEnergy = e; 729 } 570 } 730 571 731 //....oooOO0OOooo........oooOO0OOooo........oo 572 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 732 573 733 inline void G4VEmProcess::SetParticle(const G4 << 574 inline G4double G4VEmProcess::MinKinEnergy() const 734 { 575 { 735 particle = p; << 576 return minKinEnergy; 736 currentParticle = p; << 737 } 577 } 738 578 739 //....oooOO0OOooo........oooOO0OOooo........oo 579 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 740 580 741 inline void G4VEmProcess::SetSecondaryParticle << 581 inline void G4VEmProcess::SetMaxKinEnergy(G4double e) 742 { 582 { 743 secondaryParticle = p; << 583 maxKinEnergy = e; 744 } 584 } 745 585 746 //....oooOO0OOooo........oooOO0OOooo........oo 586 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 747 587 748 inline void G4VEmProcess::SetStartFromNullFlag << 588 inline G4double G4VEmProcess::MaxKinEnergy() const 749 { 589 { 750 startFromNull = val; << 590 return maxKinEnergy; 751 } 591 } 752 592 753 //....oooOO0OOooo........oooOO0OOooo........oo 593 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 754 594 755 inline void G4VEmProcess::SetSplineFlag(G4bool << 595 inline void G4VEmProcess::ActivateDeexcitation(G4bool, const G4Region*) 756 { << 596 {} 757 splineFlag = val; << 758 } << 759 597 760 //....oooOO0OOooo........oooOO0OOooo........oo 598 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 761 599 762 inline G4int G4VEmProcess::DensityIndex(G4int << 600 inline const G4PhysicsTable* G4VEmProcess::LambdaTable() const 763 { 601 { 764 return (*theDensityIdx)[idx]; << 602 return theLambdaTable; 765 } 603 } 766 604 767 //....oooOO0OOooo........oooOO0OOooo........oo 605 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 768 606 769 inline G4double G4VEmProcess::DensityFactor(G4 << 607 inline void G4VEmProcess::SetIntegral(G4bool val) 770 { 608 { 771 return (*theDensityFactor)[idx]; << 609 if(particle && particle != theGamma) integral = val; >> 610 if(integral) buildLambdaTable = true; 772 } 611 } 773 612 774 //....oooOO0OOooo........oooOO0OOooo........oo 613 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 775 614 776 inline G4bool G4VEmProcess::UseBaseMaterial() << 615 inline G4bool G4VEmProcess::IsIntegral() const 777 { 616 { 778 return baseMat; << 617 return integral; 779 } 618 } 780 619 781 //....oooOO0OOooo........oooOO0OOooo........oo 620 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 782 621 783 inline const G4VEmModel* G4VEmProcess::GetCurr << 622 inline void G4VEmProcess::SetBuildTableFlag(G4bool val) 784 { 623 { 785 return currentModel; << 624 buildLambdaTable = val; 786 } << 625 if(!val) integral = false; 787 << 788 //....oooOO0OOooo........oooOO0OOooo........oo << 789 << 790 inline void G4VEmProcess::SetEmMasterProcess(c << 791 { << 792 masterProc = ptr; << 793 } 626 } 794 627 795 //....oooOO0OOooo........oooOO0OOooo........oo 628 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 796 629 797 inline G4int G4VEmProcess::NumberOfModels() co << 630 inline void G4VEmProcess::SetStartFromNullFlag(G4bool val) 798 { 631 { 799 return numberOfModels; << 632 startFromNull = val; 800 } 633 } 801 634 802 //....oooOO0OOooo........oooOO0OOooo........oo 635 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 803 636 804 inline G4VEmModel* G4VEmProcess::EmModel(std:: << 637 inline void G4VEmProcess::SetApplyCuts(G4bool val) 805 { 638 { 806 return (index < emModels.size()) ? emModels[ << 639 applyCuts = val; 807 } 640 } 808 641 809 //....oooOO0OOooo........oooOO0OOooo........oo 642 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 810 643 811 inline G4VEmModel* G4VEmProcess::GetModelByInd << 644 inline size_t G4VEmProcess::CurrentMaterialCutsCoupleIndex() const 812 { 645 { 813 return modelManager->GetModel(idx, ver); << 646 return currentMaterialIndex; 814 } 647 } 815 648 816 //....oooOO0OOooo........oooOO0OOooo........oo 649 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... 817 650 818 #endif 651 #endif 819 652