44 :
G4VEmModel(
"LivermoreRayleigh"),isInitialised(false)
59 G4cout <<
"G4LivermoreRayleighModel is constructed " <<
G4endl;
85 G4cout <<
"Calling Initialise() of G4LivermoreRayleighModel." <<
G4endl
98 char* path = getenv(
"G4LEDATA");
103 for(
G4int i=0; i<numOfCouples; ++i)
111 for (
G4int j=0; j<nelm; ++j)
141 G4cout <<
"Calling ReadData() of G4LivermoreRayleighModel"
147 const char* datadir = path;
151 datadir = getenv(
"G4LEDATA");
154 G4Exception(
"G4LivermoreRayleighModelModel::ReadData()",
"em0006",
156 "Environment variable G4LEDATA not defined");
168 std::ostringstream ostCS;
169 ostCS << datadir <<
"/livermore/rayl/re-cs-" << Z <<
".dat";
170 std::ifstream finCS(ostCS.str().c_str());
172 if( !finCS .is_open() )
175 ed <<
"G4LivermoreRayleighModel data file <" << ostCS.str().c_str()
176 <<
"> is not opened!" <<
G4endl;
178 ed,
"G4LEDATA version should be G4EMLOW6.27 or later.");
184 G4cout <<
"File " << ostCS.str()
185 <<
" is opened by G4LivermoreRayleighModel" <<
G4endl;
201 G4cout <<
"G4LivermoreRayleighModel::ComputeCrossSectionPerAtom()"
211 if(intZ < 1 || intZ >
maxZ) {
return xs; }
220 if(!pv) {
return xs; }
227 }
else if(e >= pv->
Energy(0)) {
228 xs = pv->
Value(e)/(e*e);
233 G4cout <<
"****** DEBUG: tcs value for Z=" << Z <<
" at energy (MeV)="
235 G4cout <<
" cs (Geant4 internal unit)=" << xs <<
G4endl;
236 G4cout <<
" -> first E*E*cs value in CS data file (iu) =" << (*pv)[0]
238 G4cout <<
" -> last E*E*cs value in CS data file (iu) =" << (*pv)[
n]
240 G4cout <<
"*********************************************************"
249 std::vector<G4DynamicParticle*>*,
255 G4cout <<
"Calling SampleSecondaries() of G4LivermoreRayleighModel"
G4double LowEnergyLimit() const
std::vector< G4Element * > G4ElementVector
G4LivermoreRayleighModel()
std::ostringstream G4ExceptionDescription
G4double GetKineticEnergy() const
virtual void InitialiseLocal(const G4ParticleDefinition *, G4VEmModel *masterModel)
CLHEP::Hep3Vector G4ThreeVector
void InitialiseElementSelectors(const G4ParticleDefinition *, const G4DataVector &)
G4double HighEnergyLimit() const
virtual void InitialiseForElement(const G4ParticleDefinition *, G4int Z)
G4VEmAngularDistribution * GetAngularDistribution()
G4ParticleDefinition * GetDefinition() const
size_t GetVectorLength() const
const G4ElementVector * GetElementVector() const
void ProposeMomentumDirection(G4double Px, G4double Py, G4double Pz)
#define G4MUTEX_INITIALIZER
virtual ~G4LivermoreRayleighModel()
void ProposeLocalEnergyDeposit(G4double anEnergyPart)
G4GLOB_DLL std::ostream G4cout
virtual G4ThreeVector & SampleDirection(const G4DynamicParticle *dp, G4double finalTotalEnergy, G4int Z, const G4Material *)=0
size_t GetTableSize() const
void ReadData(size_t Z, const char *path=0)
G4double Energy(size_t index) const
std::vector< G4EmElementSelector * > * GetElementSelectors()
G4double Value(G4double theEnergy, size_t &lastidx) const
static G4LPhysicsFreeVector * dataCS[101]
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *comments)
static G4ProductionCutsTable * GetProductionCutsTable()
virtual G4double ComputeCrossSectionPerAtom(const G4ParticleDefinition *, G4double kinEnergy, G4double Z, G4double A=0, G4double cut=0, G4double emax=DBL_MAX)
void SetElementSelectors(std::vector< G4EmElementSelector * > *)
const G4MaterialCutsCouple * GetMaterialCutsCouple(G4int i) const
void SetAngularDistribution(G4VEmAngularDistribution *)
virtual G4bool Retrieve(std::ifstream &fIn, G4bool ascii=false)
virtual void Initialise(const G4ParticleDefinition *, const G4DataVector &)
void SetProposedKineticEnergy(G4double proposedKinEnergy)
size_t GetNumberOfElements() const
virtual void SampleSecondaries(std::vector< G4DynamicParticle * > *, const G4MaterialCutsCouple *, const G4DynamicParticle *, G4double tmin, G4double maxEnergy)
void ProposeTrackStatus(G4TrackStatus status)
G4ParticleChangeForGamma * fParticleChange
const G4Element * SelectRandomAtom(const G4MaterialCutsCouple *, const G4ParticleDefinition *, G4double kineticEnergy, G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
G4ParticleChangeForGamma * GetParticleChangeForGamma()
const G4Material * GetMaterial() const