Import Geant4 8.1.0 source tree
This commit is contained in:
@@ -1,27 +1,30 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * DISCLAIMER *
|
||||
// * License and Disclaimer *
|
||||
// * *
|
||||
// * The following disclaimer summarizes all the specific disclaimers *
|
||||
// * of contributors to this software. The specific disclaimers,which *
|
||||
// * govern, are listed with their locations in: *
|
||||
// * http://cern.ch/geant4/license *
|
||||
// * The Geant4 software is copyright of the Copyright Holders of *
|
||||
// * the Geant4 Collaboration. It is provided under the terms and *
|
||||
// * conditions of the Geant4 Software License, included in the file *
|
||||
// * LICENSE and available at http://cern.ch/geant4/license . These *
|
||||
// * include a list of copyright holders. *
|
||||
// * *
|
||||
// * Neither the authors of this software system, nor their employing *
|
||||
// * institutes,nor the agencies providing financial support for this *
|
||||
// * work make any representation or warranty, express or implied, *
|
||||
// * regarding this software system or assume any liability for its *
|
||||
// * use. *
|
||||
// * use. Please see the license in the file LICENSE and URL above *
|
||||
// * for the full disclaimer and the limitation of liability. *
|
||||
// * *
|
||||
// * This code implementation is the intellectual property of the *
|
||||
// * GEANT4 collaboration. *
|
||||
// * By copying, distributing or modifying the Program (or any work *
|
||||
// * based on the Program) you indicate your acceptance of this *
|
||||
// * statement, and all its terms. *
|
||||
// * This code implementation is the result of the scientific and *
|
||||
// * technical work of the GEANT4 collaboration. *
|
||||
// * By using, copying, modifying or distributing the software (or *
|
||||
// * any work based on the software) you agree to acknowledge its *
|
||||
// * use in resulting scientific publications, and indicate your *
|
||||
// * acceptance of all terms of the Geant4 Software license. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4ionIonisation.hh,v 1.38 2005/05/12 11:06:43 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-08-00 $
|
||||
// $Id: G4ionIonisation.hh,v 1.41 2006/06/29 19:52:34 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-08-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
@@ -50,6 +53,7 @@
|
||||
// 08-04-05 Major optimisation of internal interfaces (V.Ivantchenko)
|
||||
// 11-04-05 Move MaxSecondary energy to model (V.Ivanchneko)
|
||||
// 11-04-04 Move MaxSecondaryEnergy to models (V.Ivanchenko)
|
||||
// 10-05-06 Add a possibility to download user data (V.Ivantchenko)
|
||||
//
|
||||
// Class Description:
|
||||
//
|
||||
@@ -70,6 +74,8 @@
|
||||
|
||||
class G4Material;
|
||||
class G4VEmFluctuationModel;
|
||||
class G4PhysicsVector;
|
||||
class G4BraggIonModel;
|
||||
|
||||
class G4ionIonisation : public G4VEnergyLossProcess
|
||||
{
|
||||
@@ -84,6 +90,11 @@ public:
|
||||
// Print out of the class parameters
|
||||
virtual void PrintInfo();
|
||||
|
||||
void AddStoppingData(G4int Z, G4int A, const G4String& materialName,
|
||||
G4PhysicsVector& dVector);
|
||||
|
||||
void ActivateStoppingData(G4bool);
|
||||
|
||||
protected:
|
||||
|
||||
void CorrectionsAlongStep(
|
||||
@@ -110,17 +121,22 @@ protected:
|
||||
|
||||
private:
|
||||
|
||||
void DefineMassCharge(const G4ParticleDefinition* pd,
|
||||
const G4Material* mat,
|
||||
G4double mass,
|
||||
G4double kinEnergy);
|
||||
|
||||
// hide assignment operator
|
||||
G4ionIonisation & operator=(const G4ionIonisation &right);
|
||||
G4ionIonisation(const G4ionIonisation&);
|
||||
|
||||
G4ionEffectiveCharge effCharge;
|
||||
G4ionEffectiveCharge* effCharge;
|
||||
G4VEmFluctuationModel* flucModel;
|
||||
G4EmCorrections* corr;
|
||||
|
||||
// cash
|
||||
const G4Material* theMaterial;
|
||||
const G4ParticleDefinition* currentParticle;
|
||||
const G4Material* curMaterial;
|
||||
const G4ParticleDefinition* curParticle;
|
||||
const G4ParticleDefinition* theParticle;
|
||||
const G4ParticleDefinition* theBaseParticle;
|
||||
|
||||
@@ -129,8 +145,11 @@ private:
|
||||
G4double eth;
|
||||
G4double baseMass;
|
||||
G4double massRatio;
|
||||
G4double massFactor;
|
||||
G4double charge2;
|
||||
|
||||
G4bool isInitialised;
|
||||
G4bool stopDataActive;
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
@@ -138,7 +157,7 @@ private:
|
||||
|
||||
inline G4bool G4ionIonisation::IsApplicable(const G4ParticleDefinition& p)
|
||||
{
|
||||
return (p.GetPDGCharge() != 0.0 && !p.IsShortLived() &&
|
||||
return (p.GetPDGCharge() != 0.0 && !p.IsShortLived() &&
|
||||
p.GetParticleType() == "nucleus");
|
||||
}
|
||||
|
||||
@@ -154,42 +173,37 @@ inline G4double G4ionIonisation::MinPrimaryEnergy(
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
|
||||
inline G4double G4ionIonisation::GetMeanFreePath(const G4Track& track,
|
||||
G4double,
|
||||
G4ForceCondition* cond)
|
||||
inline void G4ionIonisation::DefineMassCharge(const G4ParticleDefinition* pd,
|
||||
const G4Material* mat,
|
||||
G4double mass,
|
||||
G4double kinEnergy)
|
||||
{
|
||||
|
||||
currentParticle = track.GetDefinition();
|
||||
theMaterial = track.GetMaterial();
|
||||
preKinEnergy = track.GetKineticEnergy();
|
||||
massRatio = baseMass/track.GetDynamicParticle()->GetMass();
|
||||
|
||||
G4double q_2 = effCharge.EffectiveChargeSquareRatio(currentParticle,theMaterial,
|
||||
preKinEnergy);
|
||||
SetMassRatio(massRatio);
|
||||
SetReduceFactor(1.0/(q_2*massRatio));
|
||||
SetChargeSquare(q_2);
|
||||
SetChargeSquareRatio(q_2);
|
||||
|
||||
return G4VEnergyLossProcess::GetMeanFreePath(track, 0.0, cond);
|
||||
preKinEnergy = kinEnergy;
|
||||
massRatio = baseMass/mass;
|
||||
charge2 = effCharge->EffectiveChargeSquareRatio(pd,mat,kinEnergy);
|
||||
SetDynamicMassCharge(massRatio, charge2);
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline void G4ionIonisation::CorrectionsAlongStep(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
const G4MaterialCutsCouple* couple,
|
||||
const G4DynamicParticle* dp,
|
||||
G4double& eloss,
|
||||
G4double& s)
|
||||
{
|
||||
if(eloss < preKinEnergy) {
|
||||
if(preKinEnergy*massRatio > eth)
|
||||
eloss += s*corr->HighOrderCorrections(currentParticle,theMaterial,preKinEnergy);
|
||||
else
|
||||
eloss += s*corr->NuclearDEDX(currentParticle,theMaterial,preKinEnergy - eloss*0.5);
|
||||
fParticleChange.SetProposedCharge(effCharge.EffectiveCharge(currentParticle,
|
||||
theMaterial,preKinEnergy-eloss));
|
||||
const G4ParticleDefinition* part = dp->GetDefinition();
|
||||
const G4Material* mat = couple->GetMaterial();
|
||||
if(preKinEnergy*massRatio > eth)
|
||||
eloss += s*corr->HighOrderCorrections(part,mat,preKinEnergy);
|
||||
else {
|
||||
if(stopDataActive)
|
||||
eloss *= corr->EffectiveChargeCorrection(part,mat,preKinEnergy);
|
||||
eloss += s*corr->NuclearDEDX(part,mat,preKinEnergy - eloss*0.5);
|
||||
}
|
||||
fParticleChange.SetProposedCharge(effCharge->EffectiveCharge(part,
|
||||
mat,preKinEnergy-eloss));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -206,4 +220,11 @@ inline std::vector<G4DynamicParticle*>* G4ionIonisation::SecondariesPostStep(
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline void G4ionIonisation::ActivateStoppingData(G4bool val)
|
||||
{
|
||||
stopDataActive = val;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user