Import Geant4 6.2.0 source tree
This commit is contained in:
@@ -21,8 +21,8 @@
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// $Id: G4AnnihiToMuPair.hh,v 1.3 2004/03/10 16:48:44 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-06-01 $
|
||||
// $Id: G4AnnihiToMuPair.hh,v 1.5 2004/05/07 16:52:42 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-06-02 $
|
||||
//
|
||||
// ------------ G4AnnihiToMuPair physics process ------
|
||||
// by H.Burkhardt, S. Kelner and R. Kokoulin, November 2002
|
||||
|
||||
@@ -21,8 +21,8 @@
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// $Id: G4GammaConversionToMuons.hh,v 1.4 2004/03/10 16:48:45 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-06-01 $
|
||||
// $Id: G4GammaConversionToMuons.hh,v 1.6 2004/05/11 18:22:20 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-06-02 $
|
||||
//
|
||||
// ------------ G4GammaConversionToMuons physics process ------
|
||||
// by H.Burkhardt, S. Kelner and R. Kokoulin, April 2002
|
||||
|
||||
@@ -0,0 +1,263 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * 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 *
|
||||
// * *
|
||||
// * 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. *
|
||||
// * *
|
||||
// * 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. *
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
// GEANT4 Class header file
|
||||
//
|
||||
//
|
||||
// File name: G4PAIPhotonModel
|
||||
//
|
||||
// Author: V. Grichine based on Vladimir Ivanchenko code
|
||||
//
|
||||
// Creation date: 05.10.2003
|
||||
//
|
||||
// Modifications:
|
||||
//
|
||||
//
|
||||
// Class Description:
|
||||
//
|
||||
// Implementation of PAI model of energy loss and
|
||||
// delta-electron production by heavy charged particles
|
||||
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
|
||||
#ifndef G4PAIPhotonModel_h
|
||||
#define G4PAIPhotonModel_h 1
|
||||
|
||||
#include <vector>
|
||||
#include "G4VEmModel.hh"
|
||||
#include "globals.hh"
|
||||
#include "G4VEmFluctuationModel.hh"
|
||||
|
||||
class G4PhysicsLogVector;
|
||||
class G4PhysicsTable;
|
||||
class G4Region;
|
||||
class G4MaterialCutsCouple;
|
||||
|
||||
|
||||
class G4PAIPhotonModel : public G4VEmModel, public G4VEmFluctuationModel
|
||||
{
|
||||
|
||||
public:
|
||||
|
||||
G4PAIPhotonModel(const G4ParticleDefinition* p = 0, const G4String& nam = "PAI");
|
||||
|
||||
~G4PAIPhotonModel();
|
||||
|
||||
void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
|
||||
|
||||
void InitialiseMe(const G4ParticleDefinition*) {};
|
||||
|
||||
G4double HighEnergyLimit(const G4ParticleDefinition* p);
|
||||
|
||||
G4double LowEnergyLimit(const G4ParticleDefinition* p);
|
||||
|
||||
void SetHighEnergyLimit(G4double e) {fHighKinEnergy = e;};
|
||||
|
||||
void SetLowEnergyLimit(G4double e) {fLowKinEnergy = e;};
|
||||
|
||||
G4double MinEnergyCut(const G4ParticleDefinition*,
|
||||
const G4MaterialCutsCouple*);
|
||||
|
||||
G4bool IsInCharge(const G4ParticleDefinition*);
|
||||
|
||||
G4double ComputeDEDX(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy);
|
||||
|
||||
G4double CrossSection(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4DynamicParticle* SampleSecondary(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
|
||||
std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4double MaxSecondaryEnergy(const G4DynamicParticle*);
|
||||
|
||||
G4double SampleFluctuations(const G4Material*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&,
|
||||
G4double&,
|
||||
G4double&);
|
||||
|
||||
G4double Dispersion( const G4Material*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&,
|
||||
G4double&);
|
||||
|
||||
void DefineForRegion(const G4Region* r) ;
|
||||
void ComputeSandiaPhotoAbsCof();
|
||||
void BuildPAIonisationTable();
|
||||
void BuildLambdaVector(const G4MaterialCutsCouple* matCutsCouple);
|
||||
|
||||
G4double GetdNdxCut( G4int iPlace, G4double transferCut);
|
||||
G4double GetdNdxPhotonCut( G4int iPlace, G4double transferCut);
|
||||
G4double GetdNdxPlasmonCut( G4int iPlace, G4double transferCut);
|
||||
|
||||
G4double GetdEdxCut( G4int iPlace, G4double transferCut);
|
||||
|
||||
G4double GetPostStepTransfer(G4PhysicsTable*, G4PhysicsLogVector*,
|
||||
G4int iPlace, G4double scaledTkin );
|
||||
G4double GetAlongStepTransfer(G4PhysicsTable*, G4PhysicsLogVector*,
|
||||
G4int iPlace, G4double scaledTkin, G4double cof );
|
||||
G4double GetEnergyTransfer(G4PhysicsTable*, G4int iPlace,
|
||||
G4double position, G4int iTransfer );
|
||||
|
||||
|
||||
|
||||
protected:
|
||||
|
||||
G4double MaxSecondaryEnergy(const G4ParticleDefinition*,
|
||||
G4double kinEnergy);
|
||||
|
||||
private:
|
||||
|
||||
void SetParticle(const G4ParticleDefinition* p);
|
||||
|
||||
// hide assignment operator
|
||||
G4PAIPhotonModel & operator=(const G4PAIPhotonModel &right);
|
||||
G4PAIPhotonModel(const G4PAIPhotonModel&);
|
||||
|
||||
// The vector over proton kinetic energies: the range of gammas
|
||||
|
||||
G4double fLowestKineticEnergy;
|
||||
G4double fHighestKineticEnergy;
|
||||
G4int fTotBin;
|
||||
G4int fMeanNumber;
|
||||
G4PhysicsLogVector* fProtonEnergyVector ;
|
||||
|
||||
|
||||
|
||||
// vectors
|
||||
|
||||
G4PhysicsTable* fPAItransferTable;
|
||||
std::vector<G4PhysicsTable*> fPAIxscBank;
|
||||
|
||||
G4PhysicsTable* fPAIphotonTable;
|
||||
std::vector<G4PhysicsTable*> fPAIphotonBank;
|
||||
|
||||
G4PhysicsTable* fPAIplasmonTable;
|
||||
std::vector<G4PhysicsTable*> fPAIplasmonBank;
|
||||
|
||||
G4PhysicsTable* fPAIdEdxTable;
|
||||
std::vector<G4PhysicsTable*> fPAIdEdxBank;
|
||||
|
||||
std::vector<const G4MaterialCutsCouple*> fMaterialCutsCoupleVector;
|
||||
std::vector<const G4Region*> fPAIRegionVector;
|
||||
|
||||
size_t fMatIndex ;
|
||||
G4double** fSandiaPhotoAbsCof ;
|
||||
G4int fSandiaIntervalNumber ;
|
||||
|
||||
G4PhysicsLogVector* fdEdxVector ;
|
||||
std::vector<G4PhysicsLogVector*> fdEdxTable ;
|
||||
|
||||
G4PhysicsLogVector* fLambdaVector ;
|
||||
std::vector<G4PhysicsLogVector*> fLambdaTable ;
|
||||
|
||||
G4PhysicsLogVector* fdNdxCutVector ;
|
||||
std::vector<G4PhysicsLogVector*> fdNdxCutTable ;
|
||||
|
||||
G4PhysicsLogVector* fdNdxCutPhotonVector ;
|
||||
std::vector<G4PhysicsLogVector*> fdNdxCutPhotonTable ;
|
||||
|
||||
G4PhysicsLogVector* fdNdxCutPlasmonVector ;
|
||||
std::vector<G4PhysicsLogVector*> fdNdxCutPlasmonTable ;
|
||||
|
||||
|
||||
|
||||
|
||||
const G4ParticleDefinition* fParticle;
|
||||
|
||||
G4double fMass;
|
||||
G4double fSpin;
|
||||
G4double fChargeSquare;
|
||||
G4double fRatio;
|
||||
G4double fHighKinEnergy;
|
||||
G4double fLowKinEnergy;
|
||||
G4double fTwoln10;
|
||||
G4double fBg2lim;
|
||||
G4double fTaulim;
|
||||
G4double fQc;
|
||||
};
|
||||
|
||||
/////////////////////////////////////////////////////////////////////
|
||||
|
||||
inline G4double G4PAIPhotonModel::MaxSecondaryEnergy( const G4ParticleDefinition*,
|
||||
G4double kinEnergy)
|
||||
{
|
||||
|
||||
G4double gamma= kinEnergy/fMass + 1.0;
|
||||
G4double tmax = 2.0*electron_mass_c2*(gamma*gamma - 1.) /
|
||||
(1. + 2.0*gamma*fRatio + fRatio*fRatio);
|
||||
|
||||
return tmax;
|
||||
}
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////
|
||||
|
||||
inline G4double G4PAIPhotonModel::MaxSecondaryEnergy(const G4DynamicParticle* dp)
|
||||
{
|
||||
|
||||
G4double kineticEnergy = dp->GetKineticEnergy();
|
||||
G4double gamma= kineticEnergy/fMass + 1.0;
|
||||
G4double tmax = 2.0*electron_mass_c2*(gamma*gamma - 1.) /
|
||||
(1. + 2.0*gamma*fRatio + fRatio*fRatio);
|
||||
|
||||
return tmax;
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////
|
||||
|
||||
inline void G4PAIPhotonModel::DefineForRegion(const G4Region* r)
|
||||
{
|
||||
// G4Region* rPAI = r;
|
||||
// fPAIRegionVector.push_back(rPAI);
|
||||
fPAIRegionVector.push_back(r);
|
||||
}
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -83,166 +83,6 @@ G4PAIonisation::GetContinuousStepLimit( const G4Track& track ,
|
||||
return Step ;
|
||||
}
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
//
|
||||
|
||||
inline G4double G4PAIonisation::
|
||||
GetMeanFreePath( const G4Track& trackData,
|
||||
G4double,
|
||||
G4ForceCondition* condition )
|
||||
{
|
||||
// G4cout<<"G4PAIonisation::GetMeanFreePath is called"<<G4endl ;
|
||||
|
||||
G4int iTkin, iPlace ;
|
||||
G4double charge, charge2, mass, massRatio, kinE, gamma, scaledE, meanFreePath ;
|
||||
G4double E1, E2, W, W1, W2, primaryIon ;
|
||||
|
||||
*condition = NotForced ;
|
||||
|
||||
G4Material* aMaterial = trackData.GetMaterial() ;
|
||||
|
||||
if( aMaterial->GetIndex() != fMatIndex ) meanFreePath = DBL_MAX ;
|
||||
else
|
||||
{
|
||||
const G4DynamicParticle* aParticle = trackData.GetDynamicParticle() ;
|
||||
kinE = aParticle->GetKineticEnergy() ;
|
||||
mass = aParticle->GetDefinition()->GetPDGMass() ;
|
||||
gamma = 1.0 + kinE/mass ;
|
||||
|
||||
if(gamma < 1.2) return meanFreePath = DBL_MAX ;
|
||||
|
||||
charge = aParticle->GetDefinition()->GetPDGCharge() ;
|
||||
charge2 = charge*charge ;
|
||||
massRatio = proton_mass_c2/mass ;
|
||||
scaledE = kinE*massRatio ;
|
||||
|
||||
for(iTkin=0;iTkin<G4PAIonisation::GetBinNumber();iTkin++)
|
||||
{
|
||||
// if(scaledE < GetProtonEnergyVector()->GetLowEdgeEnergy(iTkin)) // <= ?
|
||||
if(scaledE < fProtonEnergyVector->GetLowEdgeEnergy(iTkin)) // <= ?
|
||||
{
|
||||
break ;
|
||||
}
|
||||
}
|
||||
iPlace = iTkin - 1 ;
|
||||
|
||||
if(iTkin == G4PAIonisation::GetBinNumber()) // Fermi plato, try from left
|
||||
{
|
||||
meanFreePath = 1.0/(*(*fPAItransferBank)(iPlace))(0)/charge2 ;
|
||||
}
|
||||
else
|
||||
{
|
||||
if(iTkin == 0) // Tkin is too small, trying from right only
|
||||
{
|
||||
meanFreePath = 1.0/(*(*fPAItransferBank)(iPlace+1))(0)/charge2 ;
|
||||
}
|
||||
else
|
||||
{
|
||||
E1 = fProtonEnergyVector->GetLowEdgeEnergy(iTkin - 1) ;
|
||||
E2 = fProtonEnergyVector->GetLowEdgeEnergy(iTkin) ;
|
||||
W = 1.0/(E2 - E1) ;
|
||||
W1 = (E2 - scaledE)*W ;
|
||||
W2 = (scaledE - E1)*W ;
|
||||
primaryIon = (*(*fPAItransferBank)(iPlace ))(0)*W1 +
|
||||
(*(*fPAItransferBank)(iPlace+1))(0)*W2 ;
|
||||
meanFreePath = 1.0/primaryIon/charge2 ;
|
||||
}
|
||||
}
|
||||
// meanFreePath = DBL_MAX ;
|
||||
}
|
||||
return meanFreePath ;
|
||||
}
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
//
|
||||
|
||||
inline G4double G4PAIonisation::
|
||||
GetFreePath( G4double scaledTkin, G4double charge2 )
|
||||
{
|
||||
// G4cout<<"G4PAIonisation::GetFreePath is called"<<G4endl ;
|
||||
|
||||
G4int iTkin, iPlace ;
|
||||
G4double meanFreePath ;
|
||||
G4double E1, E2, W, W1, W2, primaryIon ;
|
||||
|
||||
for( iTkin = 0 ; iTkin < G4PAIonisation::GetBinNumber() ; iTkin++ )
|
||||
{
|
||||
if(scaledTkin < fProtonEnergyVector->GetLowEdgeEnergy(iTkin)) break ;
|
||||
}
|
||||
iPlace = iTkin - 1 ;
|
||||
|
||||
if(iTkin == G4PAIonisation::GetBinNumber()) // Fermi plato, try from left
|
||||
{
|
||||
meanFreePath = 1.0/(*(*fPAItransferBank)(iPlace))(0)/charge2 ;
|
||||
}
|
||||
else
|
||||
{
|
||||
if(iTkin == 0) // Tkin is too small, trying from right only
|
||||
{
|
||||
meanFreePath = 1.0/(*(*fPAItransferBank)(iPlace+1))(0)/charge2 ;
|
||||
}
|
||||
else
|
||||
{
|
||||
E1 = fProtonEnergyVector->GetLowEdgeEnergy(iTkin - 1) ;
|
||||
E2 = fProtonEnergyVector->GetLowEdgeEnergy(iTkin) ;
|
||||
W = 1.0/(E2 - E1) ;
|
||||
W1 = (E2 - scaledTkin)*W ;
|
||||
W2 = (scaledTkin - E1)*W ;
|
||||
primaryIon = (*(*fPAItransferBank)(iPlace ))(0)*W1 +
|
||||
(*(*fPAItransferBank)(iPlace+1))(0)*W2 ;
|
||||
meanFreePath = 1.0/primaryIon/charge2 ;
|
||||
}
|
||||
}
|
||||
// meanFreePath = DBL_MAX ;
|
||||
|
||||
return meanFreePath ;
|
||||
}
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
//
|
||||
|
||||
inline G4double G4PAIonisation::
|
||||
GetdEdx( G4double scaledTkin, G4double charge2 )
|
||||
{
|
||||
// G4cout<<"G4PAIonisation::GetdEdx is called"<<G4endl ;
|
||||
|
||||
G4int iTkin, iPlace ;
|
||||
G4double dEdx ;
|
||||
G4double E1, E2, W, W1, W2 ;
|
||||
|
||||
for( iTkin = 0 ; iTkin < G4PAIonisation::GetBinNumber() ; iTkin++ )
|
||||
{
|
||||
if(scaledTkin < fProtonEnergyVector->GetLowEdgeEnergy(iTkin)) break ;
|
||||
}
|
||||
iPlace = iTkin - 1 ;
|
||||
|
||||
if(iTkin == G4PAIonisation::GetBinNumber()) // Fermi plato, try from left
|
||||
{
|
||||
dEdx = (*(*theLossTable)(iPlace))(0)*charge2 ;
|
||||
}
|
||||
else
|
||||
{
|
||||
if(iTkin == 0) // Tkin is too small, trying from right only
|
||||
{
|
||||
dEdx = (*(*theLossTable)(iPlace+1))(0)*charge2 ;
|
||||
}
|
||||
else
|
||||
{
|
||||
E1 = fProtonEnergyVector->GetLowEdgeEnergy(iTkin - 1) ;
|
||||
E2 = fProtonEnergyVector->GetLowEdgeEnergy(iTkin) ;
|
||||
W = 1.0/(E2 - E1) ;
|
||||
W1 = (E2 - scaledTkin)*W ;
|
||||
W2 = (scaledTkin - E1)*W ;
|
||||
dEdx = (*(*theLossTable)(iPlace))(0)*W1 + (*(*theLossTable)(iPlace+1))(0)*W2;
|
||||
dEdx *= charge2 ;
|
||||
}
|
||||
}
|
||||
return dEdx ;
|
||||
}
|
||||
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
//
|
||||
|
||||
@@ -21,8 +21,8 @@
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// $Id: G4PAIxSection.hh,v 1.10 2003/10/19 15:21:22 grichine Exp $
|
||||
// GEANT4 tag $Name: geant4-06-00-patch-01 $
|
||||
// $Id: G4PAIxSection.hh,v 1.11 2004/04/02 10:51:12 grichine Exp $
|
||||
// GEANT4 tag $Name: geant4-06-02 $
|
||||
//
|
||||
//
|
||||
// G4PAIxSection.hh -- header file
|
||||
@@ -59,20 +59,25 @@
|
||||
|
||||
#include"G4SandiaTable.hh"
|
||||
|
||||
class G4MaterialCutsCouple;
|
||||
class G4Sandiatable;
|
||||
|
||||
|
||||
class G4PAIxSection
|
||||
{
|
||||
public:
|
||||
// Constructors
|
||||
G4PAIxSection( G4MaterialCutsCouple* matCC);
|
||||
|
||||
G4PAIxSection( G4int materialIndex,
|
||||
G4PAIxSection( G4int materialIndex,
|
||||
G4double maxEnergyTransfer ) ;
|
||||
|
||||
G4PAIxSection( G4int materialIndex, // for proton loss table
|
||||
G4PAIxSection( G4int materialIndex, // for proton loss table
|
||||
G4double maxEnergyTransfer,
|
||||
G4double betaGammaSq ,
|
||||
G4double** photoAbsCof, G4int intNumber ) ;
|
||||
|
||||
G4PAIxSection( G4int materialIndex, // test constructor
|
||||
G4PAIxSection( G4int materialIndex, // test constructor
|
||||
G4double maxEnergyTransfer,
|
||||
G4double betaGammaSq ) ;
|
||||
|
||||
@@ -188,6 +193,7 @@ const G4int fRefGammaNumber ; // The number of gamma for creation of spline (15
|
||||
|
||||
G4int fIntervalNumber ; // The number of energy intervals
|
||||
G4double fNormalizationCof ; // Normalization cof for PhotoAbsorptionXsection
|
||||
|
||||
// G4double fBetaGammaSq ; // (beta*gamma)^2
|
||||
|
||||
G4double fDensity ; // Current density
|
||||
@@ -196,6 +202,9 @@ G4int fSplineNumber ; // Current size of spline
|
||||
|
||||
// Arrays of Sandia coefficients
|
||||
|
||||
G4OrderedTable* fMatSandiaMatrix;
|
||||
G4SandiaTable* fSandia;
|
||||
|
||||
G4double* fEnergyInterval ;
|
||||
G4double* fA1 ;
|
||||
G4double* fA2 ;
|
||||
@@ -204,6 +213,7 @@ G4double* fA4 ;
|
||||
|
||||
static
|
||||
const G4int fMaxSplineSize ; // Max size of output splain arrays = 500
|
||||
|
||||
/* ******************
|
||||
G4double* fSplineEnergy ; // energy points of splain
|
||||
G4double* fRePartDielectricConst ; // Real part of dielectric const
|
||||
@@ -212,6 +222,8 @@ G4double* fIntegralTerm ; // Integral term in PAI cross section
|
||||
G4double* fDifPAIxSection ; // Differential PAI cross section
|
||||
G4double* fIntegralPAIxSection ; // Integral PAI cross section ?
|
||||
*/ ///////////////
|
||||
|
||||
|
||||
G4double fSplineEnergy[500] ; // energy points of splain
|
||||
G4double fRePartDielectricConst[500] ; // Real part of dielectric const
|
||||
G4double fImPartDielectricConst[500] ; // Imaginary part of dielectric const
|
||||
|
||||
@@ -21,8 +21,8 @@
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// $Id: G4SynchrotronRadiation.hh,v 1.9 2004/03/10 16:48:45 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-06-01 $
|
||||
// $Id: G4SynchrotronRadiation.hh,v 1.10 2004/06/07 13:49:51 gcosmo Exp $
|
||||
// GEANT4 tag $Name: geant4-06-02 $
|
||||
//
|
||||
// ------------------------------------------------------------
|
||||
// GEANT 4 class header file
|
||||
@@ -91,9 +91,8 @@ class G4SynchrotronRadiation : public G4VDiscreteProcess
|
||||
|
||||
G4bool IsApplicable(const G4ParticleDefinition&);
|
||||
|
||||
static G4double GetLambdaConst() { return fLambdaConst ; } ;
|
||||
|
||||
static G4double GetEnergyConst() { return fEnergyConst ; } ;
|
||||
static G4double GetLambdaConst();
|
||||
static G4double GetEnergyConst();
|
||||
|
||||
protected:
|
||||
|
||||
@@ -133,85 +132,6 @@ class G4SynchrotronRadiation : public G4VDiscreteProcess
|
||||
};
|
||||
|
||||
////////////////////////// INLINE METHODS /////////////////////////////
|
||||
//
|
||||
// gives the MeanFreePath in GEANT4 internal units
|
||||
//
|
||||
|
||||
inline G4double
|
||||
G4SynchrotronRadiation::GetMeanFreePath( const G4Track& trackData,
|
||||
G4double,
|
||||
G4ForceCondition* condition)
|
||||
{
|
||||
const G4DynamicParticle* aDynamicParticle;
|
||||
G4Material* aMaterial;
|
||||
G4double MeanFreePath;
|
||||
//G4bool isOutRange ;
|
||||
|
||||
*condition = NotForced ;
|
||||
|
||||
aDynamicParticle = trackData.GetDynamicParticle();
|
||||
aMaterial = trackData.GetMaterial();
|
||||
|
||||
G4double gamma = aDynamicParticle->GetTotalEnergy()/
|
||||
(aDynamicParticle->GetMass() ) ;
|
||||
|
||||
G4double KineticEnergy = aDynamicParticle->GetKineticEnergy();
|
||||
|
||||
if (KineticEnergy < LowestKineticEnergy || gamma<1.0e3)
|
||||
{
|
||||
MeanFreePath = DBL_MAX ;
|
||||
}
|
||||
else
|
||||
{
|
||||
G4TransportationManager* transportMgr;
|
||||
G4FieldManager* globalFieldMgr;
|
||||
|
||||
transportMgr = G4TransportationManager::GetTransportationManager() ;
|
||||
|
||||
globalFieldMgr = transportMgr->GetFieldManager() ;
|
||||
|
||||
G4bool FieldExists = globalFieldMgr->DoesFieldExist() ;
|
||||
G4ThreeVector FieldValue;
|
||||
const G4Field* pField = 0 ;
|
||||
if (FieldExists)
|
||||
{
|
||||
pField = globalFieldMgr->GetDetectorField() ;
|
||||
G4ThreeVector globPosition = trackData.GetPosition() ;
|
||||
G4double globPosVec[3], FieldValueVec[3] ;
|
||||
globPosVec[0] = globPosition.x() ;
|
||||
globPosVec[1] = globPosition.y() ;
|
||||
globPosVec[2] = globPosition.z() ;
|
||||
|
||||
pField->GetFieldValue( globPosVec, FieldValueVec ) ;
|
||||
FieldValue = G4ThreeVector( FieldValueVec[0],
|
||||
FieldValueVec[1],
|
||||
FieldValueVec[2] ) ;
|
||||
|
||||
|
||||
|
||||
G4ThreeVector unitMomentum = aDynamicParticle->GetMomentumDirection();
|
||||
G4ThreeVector unitMcrossB = FieldValue.cross(unitMomentum) ;
|
||||
G4double perpB = unitMcrossB.mag() ;
|
||||
G4double beta = aDynamicParticle->GetTotalMomentum()/
|
||||
(aDynamicParticle->GetTotalEnergy() ) ;
|
||||
if(perpB > 0.0)
|
||||
{
|
||||
MeanFreePath = fLambdaConst*beta/perpB ;
|
||||
}
|
||||
else
|
||||
{
|
||||
MeanFreePath = DBL_MAX ;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
MeanFreePath = DBL_MAX ;
|
||||
}
|
||||
}
|
||||
return MeanFreePath;
|
||||
}
|
||||
|
||||
|
||||
|
||||
inline G4bool
|
||||
G4SynchrotronRadiation::IsApplicable( const G4ParticleDefinition& particle )
|
||||
|
||||
@@ -20,8 +20,8 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4eBremsstrahlung.hh,v 1.21 2004/01/21 18:05:22 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-06-01 $
|
||||
// $Id: G4eBremsstrahlung.hh,v 1.23 2004/05/07 16:52:42 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-06-02 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
|
||||
@@ -20,8 +20,8 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4ionIonisation.hh,v 1.23 2004/01/21 18:05:22 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-06-01 $
|
||||
// $Id: G4ionIonisation.hh,v 1.24 2004/05/10 18:46:48 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-06-02 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
@@ -168,8 +168,7 @@ inline G4double G4ionIonisation::MaxSecondaryEnergy(const G4DynamicParticle* dyn
|
||||
|
||||
|
||||
inline G4double G4ionIonisation::GetMeanFreePath(const G4Track& track,
|
||||
G4double step,
|
||||
G4ForceCondition* cond)
|
||||
G4double, G4ForceCondition*)
|
||||
{
|
||||
G4double mRatio = proton_mass_c2/track.GetDynamicParticle()->GetMass();
|
||||
G4double q_2 = EffectiveChargeSquare(track);
|
||||
@@ -178,7 +177,7 @@ inline G4double G4ionIonisation::GetMeanFreePath(const G4Track& track,
|
||||
SetChargeSquare(q_2);
|
||||
SetChargeSquareRatio(q_2);
|
||||
|
||||
return G4VEnergyLossProcess::GetMeanFreePath(track, step, cond);
|
||||
return G4VEnergyLossProcess::GetMeanFreePath(track, 0.0, 0);
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
Reference in New Issue
Block a user