Import Geant4 3.1.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-08 16:03:00 +02:00
parent cfcb558cfe
commit 137e303ecc
2843 changed files with 37082 additions and 38426 deletions
@@ -1,46 +0,0 @@
// 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.
//
// -------------------------------------------------------------------
// GEANT 4 class file
//
// For information related to this code contact:
// CERN, IT Division, ASD group
// CERN, Geneva, Switzerland
//
// File name: G4Data.hh
//
// Author: Alessandra Forti (Alessandra.Forti@cern.ch)
//
// Creation date: 1 Giugno 1999
//
// Modifications:
//
// -------------------------------------------------------------------
#include "G4Data.hh"
G4Data::~G4Data(){
this->clear();
}
G4bool G4Data::operator == (const G4Data& input) const {
return(this->length() == input.length());
}
G4bool G4Data::operator < (const G4Data& input) const {
return(this->length() < input.length());
}
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4LowEnergyBremsstrahlung.cc,v 1.27 2000/09/20 16:49:40 vnivanch Exp $
// GEANT4 tag $Name: geant4-03-00 $
// $Id: G4LowEnergyBremsstrahlung.cc,v 1.28 2001/02/05 17:45:18 gcosmo Exp $
// GEANT4 tag $Name: geant4-03-01 $
//
//
// --------------------------------------------------------------
@@ -75,7 +75,6 @@ G4LowEnergyBremsstrahlung::~G4LowEnergyBremsstrahlung()
}
if(ZNumVec){
ZNumVec->clear();
delete ZNumVec;
}
@@ -151,7 +150,7 @@ void G4LowEnergyBremsstrahlung::BuildCrossSectionTable(){
theCrossSectionTable = new G4SecondLevel();
G4int dataNum = 2;
for(G4int TableInd = 0; TableInd < ZNumVec->entries(); TableInd++){
for(G4int TableInd = 0; TableInd < ZNumVec->size(); TableInd++){
G4int AtomInd = (G4int) (*ZNumVec)[TableInd];
@@ -200,7 +199,7 @@ void G4LowEnergyBremsstrahlung::BuildZVec(){
delete ZNumVec;
}
ZNumVec = new G4Data();
ZNumVec = new G4DataVector();
for (G4int J=0 ; J < numOfMaterials; J++){
const G4Material* material= (*theMaterialTable)[J];
@@ -211,12 +210,9 @@ void G4LowEnergyBremsstrahlung::BuildZVec(){
G4double Zel = (*theElementVector)(iel)->GetZ();
if(ZNumVec->contains(Zel) == FALSE){
ZNumVec->insert(Zel);
}
else{
if( !(ZNumVec->contains(Zel)) ) {
ZNumVec->push_back(Zel);
} else{
continue;
}
}
@@ -301,6 +297,7 @@ void G4LowEnergyBremsstrahlung::BuildMeanFreePathTable()
G4Material* material;
G4double* CutInKineticEnergy = G4Gamma::Gamma()->GetCutsInEnergy() ;
PartialSumSigma.clearAndDestroy();
PartialSumSigma.resize(NumbOfMaterials);
G4double LowEdgeEnergy , Value;
@@ -362,7 +359,7 @@ void G4LowEnergyBremsstrahlung::ComputePartialSumSigma(const G4double KineticEne
const G4ElementVector* theElementVector = aMaterial->GetElementVector();
const G4double* theAtomNumDensityVector = aMaterial->GetAtomicNumDensityVector();
PartialSumSigma(Imate) = new G4ValVector(NbOfElements);
PartialSumSigma[Imate] = new G4DataVector();
G4double SIGMA = 0. ;
@@ -374,7 +371,7 @@ void G4LowEnergyBremsstrahlung::ComputePartialSumSigma(const G4double KineticEne
SIGMA += theAtomNumDensityVector[Ielem]*interCrsSec;
PartialSumSigma(Imate)->insert(SIGMA);
PartialSumSigma[Imate]->push_back(SIGMA);
}
}
@@ -661,9 +658,9 @@ G4Element* G4LowEnergyBremsstrahlung::SelectRandomAtom(G4Material* aMaterial) co
const G4int NumberOfElements = aMaterial->GetNumberOfElements();
const G4ElementVector* theElementVector = aMaterial->GetElementVector();
G4double rval = G4UniformRand()*((*PartialSumSigma(Index))(NumberOfElements-1));
G4double rval = G4UniformRand()*((*PartialSumSigma[Index])[NumberOfElements-1]);
for ( G4int i=0; i < NumberOfElements; i++ )
if (rval <= (*PartialSumSigma(Index))(i)) return ((*theElementVector)(i));
if (rval <= (*PartialSumSigma[Index])[i]) return ((*theElementVector)(i));
return (*theElementVector)(0);
}
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4LowEnergyCompton.cc,v 1.20 2000/07/11 18:46:47 pia Exp $
// GEANT4 tag $Name: geant4-03-00 $
// $Id: G4LowEnergyCompton.cc,v 1.21 2001/02/05 17:45:18 gcosmo Exp $
// GEANT4 tag $Name: geant4-03-01 $
//
//
// --------------------------------------------------------------
@@ -71,7 +71,6 @@ G4LowEnergyCompton::~G4LowEnergyCompton()
}
if(ZNumVec){
ZNumVec->clear();
delete ZNumVec;
}
@@ -105,7 +104,7 @@ void G4LowEnergyCompton::BuildCrossSectionTable(){
theCrossSectionTable = new G4SecondLevel();
G4int dataNum = 2;
for(G4int TableInd = 0; TableInd < ZNumVec->entries(); TableInd++){
for(G4int TableInd = 0; TableInd < ZNumVec->size(); TableInd++){
G4int AtomInd = (G4int) (*ZNumVec)[TableInd];
@@ -126,7 +125,7 @@ void G4LowEnergyCompton::BuildScatteringFunctionTable(){
theScatteringFunctionTable = new G4SecondLevel();
G4int dataNum = 2;
for(G4int TableInd = 0; TableInd < ZNumVec->entries(); TableInd++){
for(G4int TableInd = 0; TableInd < ZNumVec->size(); TableInd++){
G4int AtomInd = (G4int) (*ZNumVec)[TableInd];
@@ -143,12 +142,11 @@ void G4LowEnergyCompton::BuildZVec(){
G4int numOfMaterials = theMaterialTable->length();
if(ZNumVec){
ZNumVec->clear();
delete ZNumVec;
}
ZNumVec = new G4Data();
ZNumVec = new G4DataVector();
for (G4int J=0 ; J < numOfMaterials; J++){
const G4Material* material= (*theMaterialTable)[J];
@@ -160,11 +158,8 @@ void G4LowEnergyCompton::BuildZVec(){
G4double Zel = (*theElementVector)(iel)->GetZ();
if(ZNumVec->contains(Zel) == FALSE){
ZNumVec->insert(Zel);
}
else{
ZNumVec->push_back(Zel);
} else{
continue;
}
}
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4LowEnergyGammaConversion.cc,v 1.15 2000/09/04 18:18:08 pia Exp $
// GEANT4 tag $Name: geant4-03-00 $
// $Id: G4LowEnergyGammaConversion.cc,v 1.16 2001/02/05 17:45:19 gcosmo Exp $
// GEANT4 tag $Name: geant4-03-01 $
//
//
// --------------------------------------------------------------
@@ -69,7 +69,6 @@ G4LowEnergyGammaConversion::~G4LowEnergyGammaConversion()
}
if(ZNumVec){
ZNumVec->clear();
delete ZNumVec;
}
@@ -98,7 +97,7 @@ void G4LowEnergyGammaConversion::BuildCrossSectionTable(){
theCrossSectionTable = new G4SecondLevel();
G4int dataNum = 2;
for(G4int TableInd = 0; TableInd < ZNumVec->entries(); TableInd++){
for(G4int TableInd = 0; TableInd < ZNumVec->size(); TableInd++){
G4int AtomInd = (G4int) (*ZNumVec)[TableInd];
@@ -115,12 +114,11 @@ void G4LowEnergyGammaConversion::BuildZVec(){
G4int numOfMaterials = theMaterialTable->length();
if(ZNumVec){
ZNumVec->clear();
delete ZNumVec;
}
ZNumVec = new G4Data();
ZNumVec = new G4DataVector();
for (G4int J=0 ; J < numOfMaterials; J++){
const G4Material* material= (*theMaterialTable)[J];
@@ -132,11 +130,8 @@ void G4LowEnergyGammaConversion::BuildZVec(){
G4double Zel = (*theElementVector)(iel)->GetZ();
if(ZNumVec->contains(Zel) == FALSE){
ZNumVec->insert(Zel);
}
else{
ZNumVec->push_back(Zel);
} else{
continue;
}
}
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4LowEnergyIonisation.cc,v 1.40 2000/09/20 16:49:40 vnivanch Exp $
// GEANT4 tag $Name: geant4-03-00 $
// $Id: G4LowEnergyIonisation.cc,v 1.41 2001/02/05 17:45:20 gcosmo Exp $
// GEANT4 tag $Name: geant4-03-01 $
//
//
// -------------------------------------------------------------
@@ -258,7 +258,7 @@ void G4LowEnergyIonisation::BuildShellCrossSectionTable(){
allAtomShellCrossSec = new allAtomTable();
G4int dataNum = 2;
for(G4int TableInd = 0; TableInd < ZNumVec->entries(); TableInd++){
for(G4int TableInd = 0; TableInd < ZNumVec->size(); TableInd++){
G4int AtomInd = (G4int) (*ZNumVec)[TableInd];
@@ -291,10 +291,10 @@ void G4LowEnergyIonisation::BuildFluorTransitionTable(){
}
theFluorTransitionTable = new allAtomTable();
ZNumVecFluor = new G4Data(*ZNumVec);
ZNumVecFluor = new G4DataVector(*ZNumVec);
G4int dataNum = 3;
for(G4int TableInd = 0; TableInd < ZNumVec->entries(); TableInd++){
for(G4int TableInd = 0; TableInd < ZNumVec->size(); TableInd++){
G4int AtomInd = (G4int) (*ZNumVec)[TableInd];
if(AtomInd > 5){
@@ -321,7 +321,7 @@ void G4LowEnergyIonisation::BuildSamplingCoeffTable(){
G4int dataNum = 17;
for(G4int TableInd = 0; TableInd < ZNumVec->entries(); TableInd++){
for(G4int TableInd = 0; TableInd < ZNumVec->size(); TableInd++){
G4int AtomInd = (G4int) (*ZNumVec)[TableInd];
oneAtomTable* oneAtomShellSc = util.BuildSecondLevelTables(AtomInd, dataNum, "ioni/io-co-");
@@ -346,7 +346,7 @@ void G4LowEnergyIonisation::BuildZVec(){
delete ZNumVec;
}
ZNumVec = new G4Data();
ZNumVec = new G4DataVector();
for (G4int J=0 ; J < numOfMaterials; J++){
const G4Material* material= (*theMaterialTable)[J];
@@ -358,11 +358,8 @@ void G4LowEnergyIonisation::BuildZVec(){
G4double Zel = (*theElementVector)(iel)->GetZ();
if(ZNumVec->contains(Zel) == FALSE){
ZNumVec->insert(Zel);
}
else{
ZNumVec->push_back(Zel);
} else{
continue;
}
}
@@ -452,8 +449,8 @@ G4double G4LowEnergyIonisation::ComputeCrossSection(const G4double AtomIndex,
for(G4int ind = 0; ind < oneAtomCS->entries(); ind++){
G4double crossSec = 0;
G4Data* EnergyVector = (*(*oneAtomCS)[ind])[0];
G4Data* CrossSecVector = (*(*oneAtomCS)[ind])[1];
G4DataVector* EnergyVector = (*(*oneAtomCS)[ind])[0];
G4DataVector* CrossSecVector = (*(*oneAtomCS)[ind])[1];
if(IncEnergy < (*EnergyVector)[1]){ // First element is the shell number
@@ -484,8 +481,8 @@ G4double G4LowEnergyIonisation::ComputeCrossSectionWithCut(const G4double AtomIn
for(G4int ind = 0; ind < oneAtomCS->entries(); ind++){
G4double crossSec = 0;
G4Data* EnergyVector = (*(*oneAtomCS)[ind])[0];
G4Data* CrossSecVector = (*(*oneAtomCS)[ind])[1];
G4DataVector* EnergyVector = (*(*oneAtomCS)[ind])[0];
G4DataVector* CrossSecVector = (*(*oneAtomCS)[ind])[1];
TotalCrossSection += GetShellCrossSectionwithCut(AtomIndex,ind,IncEnergy,CutEnergy);
}
@@ -507,8 +504,8 @@ G4double G4LowEnergyIonisation::GetShellCrossSection(const G4double AtomicNumber
if( ind >= oneAtomCS->entries() ) return crossSec ;
G4Data* EnergyVector = (*(*oneAtomCS)[ind])[0];
G4Data* CrossSecVector = (*(*oneAtomCS)[ind])[1];
G4DataVector* EnergyVector = (*(*oneAtomCS)[ind])[0];
G4DataVector* CrossSecVector = (*(*oneAtomCS)[ind])[1];
if(KineticEnergy < (*EnergyVector)[1]){ // First element is the shell number
@@ -561,27 +558,27 @@ G4double G4LowEnergyIonisation::GetShellCrossSectionwithCut(
const G4int CoeffNumber = oneShellCoeffTable->entries();
const G4Data* energyVec = (*oneShellCoeffTable)[0];
const G4int LastPar = energyVec->length()-1;
G4Data Parms;
const G4DataVector* energyVec = (*oneShellCoeffTable)[0];
const G4int LastPar = energyVec->size()-1;
G4DataVector Parms;
for(G4int ind = 1; ind < CoeffNumber-2; ind++){
const G4Data* oneCoeffVec = (*oneShellCoeffTable)[ind];
const G4DataVector* oneCoeffVec = (*oneShellCoeffTable)[ind];
if(KineticEnergy < (*energyVec)[0]){
Parms.insert((*oneCoeffVec)[0]);
Parms.push_back((*oneCoeffVec)[0]);
}
else if(KineticEnergy > (*energyVec)[LastPar]){
Parms.insert((*oneCoeffVec)[LastPar]);
Parms.push_back((*oneCoeffVec)[LastPar]);
}
else{
G4double par = util.DataSemiLogInterpolation(KineticEnergy,(*energyVec),(*oneCoeffVec));
Parms.insert(par);
Parms.push_back(par);
}
}
@@ -763,27 +760,27 @@ G4double G4LowEnergyIonisation::GetShellEnergyLosswithCut(
const G4int CoeffNumber = oneShellCoeffTable->entries();
const G4Data* energyVec = (*oneShellCoeffTable)[0];
const G4int LastPar = energyVec->length()-1;
G4Data Parms;
const G4DataVector* energyVec = (*oneShellCoeffTable)[0];
const G4int LastPar = energyVec->size()-1;
G4DataVector Parms;
for(G4int ind = 1; ind < CoeffNumber-2; ind++){
const G4Data* oneCoeffVec = (*oneShellCoeffTable)[ind];
const G4DataVector* oneCoeffVec = (*oneShellCoeffTable)[ind];
if(KineticEnergy < (*energyVec)[0]){
Parms.insert((*oneCoeffVec)[0]);
Parms.push_back((*oneCoeffVec)[0]);
}
else if(KineticEnergy > (*energyVec)[LastPar]){
Parms.insert((*oneCoeffVec)[LastPar]);
Parms.push_back((*oneCoeffVec)[LastPar]);
}
else{
G4double par = util.DataSemiLogInterpolation(KineticEnergy,(*energyVec),(*oneCoeffVec));
Parms.insert(par);
Parms.push_back(par);
}
}
@@ -1125,8 +1122,8 @@ G4VParticleChange* G4LowEnergyIonisation::PostStepDoIt( const G4Track& trackData
// Fluorescence data start from element 6
if(thePrimShVec.length() != 0){thePrimShVec.clear();}
thePrimShVec.insert(thePrimaryShell);
if(thePrimShVec.size() != 0){thePrimShVec.clear();}
thePrimShVec.push_back(thePrimaryShell);
if(AtomIndex > 5){
G4bool ThereAreShells = TRUE;
@@ -1288,8 +1285,8 @@ G4int G4LowEnergyIonisation::SelectRandomShell(const G4int AtomIndex
for(G4int ind = 0; ind < oneAtomCS->entries(); ind++){
G4double crossSec;
G4Data* EnergyVector = (*(*oneAtomCS)[ind])[0];
G4Data* CrossSecVector = (*(*oneAtomCS)[ind])[1];
G4DataVector* EnergyVector = (*(*oneAtomCS)[ind])[0];
G4DataVector* CrossSecVector = (*(*oneAtomCS)[ind])[1];
if(IncEnergy < (*EnergyVector)[0]){ //First element is the shell number
crossSec = 0;
@@ -1403,7 +1400,7 @@ G4bool G4LowEnergyIonisation::SelectRandomTransition(G4int thePrimShell,
G4double PartSum = 0;
TransProb = 1;
while(TransProb < (*(*TransitionTable)[ShellNum])[ProbCol]->length()){
while(TransProb < (*(*TransitionTable)[ShellNum])[ProbCol]->size()){
PartSum += (*(*(*TransitionTable)[ShellNum])[ProbCol])[TransProb];
@@ -1457,21 +1454,21 @@ G4double G4LowEnergyIonisation::EnergySampling(const G4int AtomicNumber,
// 2) Interpolate coefficients (I need the incoming electron kinetic energy)
const G4int CoeffNumber = oneShellCoeffTable->entries();
const G4Data* energyVec = (*oneShellCoeffTable)[0];
const G4int LastPar = energyVec->length()-1;
G4Data Parms;
const G4DataVector* energyVec = (*oneShellCoeffTable)[0];
const G4int LastPar = energyVec->size()-1;
G4DataVector Parms;
for(G4int ind = 1; ind < CoeffNumber-2; ind++){
const G4Data* oneCoeffVec = (*oneShellCoeffTable)[ind];
const G4DataVector* oneCoeffVec = (*oneShellCoeffTable)[ind];
if(KinEn < (*energyVec)[0]){
Parms.insert((*oneCoeffVec)[0]);
Parms.push_back((*oneCoeffVec)[0]);
}
else if(KinEn > (*energyVec)[LastPar]){
Parms.insert((*oneCoeffVec)[LastPar]);
Parms.push_back((*oneCoeffVec)[LastPar]);
}
else{
@@ -1480,7 +1477,7 @@ G4double G4LowEnergyIonisation::EnergySampling(const G4int AtomicNumber,
// can be negative.
G4double par = util.DataSemiLogInterpolation(KinEn,(*energyVec),(*oneCoeffVec));
Parms.insert(par);
Parms.push_back(par);
}
}
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4LowEnergyPhotoElectric.cc,v 1.26 2000/07/11 18:46:48 pia Exp $
// GEANT4 tag $Name: geant4-03-00 $
// $Id: G4LowEnergyPhotoElectric.cc,v 1.27 2001/02/05 17:45:21 gcosmo Exp $
// GEANT4 tag $Name: geant4-03-01 $
//
//
// --------------------------------------------------------------
@@ -93,7 +93,6 @@ G4LowEnergyPhotoElectric::~G4LowEnergyPhotoElectric()
// ClearAndDestroy of this tables is called in their destructors
if (theFluorTransitionTable) {
delete theFluorTransitionTable;
}
@@ -103,14 +102,12 @@ G4LowEnergyPhotoElectric::~G4LowEnergyPhotoElectric()
}
if(ZNumVec){
ZNumVec->clear();
delete ZNumVec;
}
if(ZNumVecFluor){
ZNumVecFluor->clear();
ZNumVecFluor->erase(ZNumVecFluor->begin(),ZNumVecFluor->end());
delete ZNumVecFluor;
}
@@ -157,7 +154,7 @@ void G4LowEnergyPhotoElectric::BuildCrossSectionTable(){
theCrossSectionTable = new G4SecondLevel();
G4int dataNum = 2;
for(G4int TableInd = 0; TableInd < ZNumVec->entries(); TableInd++){
for(G4int TableInd = 0; TableInd < ZNumVec->size(); TableInd++){
G4int AtomInd = (G4int) (*ZNumVec)[TableInd];
@@ -181,7 +178,7 @@ void G4LowEnergyPhotoElectric::BuildShellCrossSectionTable(){
allAtomShellCrossSec = new allAtomTable();
G4int dataNum = 2;
for(G4int TableInd = 0; TableInd < ZNumVec->entries(); TableInd++){
for(G4int TableInd = 0; TableInd < ZNumVec->size(); TableInd++){
G4int AtomInd = (G4int) (*ZNumVec)[TableInd];
@@ -217,10 +214,10 @@ void G4LowEnergyPhotoElectric::BuildFluorTransitionTable(){
}
theFluorTransitionTable = new allAtomTable();
ZNumVecFluor = new G4Data(*ZNumVec);
ZNumVecFluor = new G4DataVector(*ZNumVec);
G4int dataNum = 3;
for(G4int TableInd = 0; TableInd < ZNumVec->entries(); TableInd++){
for(G4int TableInd = 0; TableInd < ZNumVec->size(); TableInd++){
G4int AtomInd = (G4int) (*ZNumVec)[TableInd];
if(AtomInd > 5){
@@ -244,12 +241,11 @@ void G4LowEnergyPhotoElectric::BuildZVec(){
G4int numOfMaterials = theMaterialTable->length();
if(ZNumVec){
ZNumVec->clear();
delete ZNumVec;
}
ZNumVec = new G4Data();
ZNumVec = new G4DataVector();
for (G4int J=0 ; J < numOfMaterials; J++){
const G4Material* material= (*theMaterialTable)[J];
@@ -261,11 +257,8 @@ void G4LowEnergyPhotoElectric::BuildZVec(){
G4double Zel = (*theElementVector)(iel)->GetZ();
if(ZNumVec->contains(Zel) == FALSE){
ZNumVec->insert(Zel);
}
else{
ZNumVec->push_back(Zel);
} else{
continue;
}
}
@@ -290,8 +283,8 @@ G4double G4LowEnergyPhotoElectric::ComputeCrossSection(const G4double AtomIndex,
for(G4int ind = 0; ind < oneAtomCS->entries(); ind++){
G4double crossSec = 0;
G4Data* EnergyVector = (*(*oneAtomCS)[ind])[0];
G4Data* CrossSecVector = (*(*oneAtomCS)[ind])[1];
G4DataVector* EnergyVector = (*(*oneAtomCS)[ind])[0];
G4DataVector* CrossSecVector = (*(*oneAtomCS)[ind])[1];
if(IncEnergy < (*EnergyVector)[1]){ // First element is the shell number
@@ -412,12 +405,12 @@ G4VParticleChange* G4LowEnergyPhotoElectric::PostStepDoIt(const G4Track& aTrack,
G4int thePrimaryShell = (G4int) (*(*theBindEnVec)[0])[subShellIndex];
G4double BindingEn = ((*(*theBindEnVec)[1])[subShellIndex])*MeV;
if(thePrimShVec.length() != 0){
if(thePrimShVec.size() != 0){
thePrimShVec.clear();
}
thePrimShVec.insert(thePrimaryShell);
thePrimShVec.push_back(thePrimaryShell);
// Create lists of pointers to DynamicParticles (photons and electrons)
G4ParticleVector photvec;
@@ -578,8 +571,8 @@ G4int G4LowEnergyPhotoElectric::SelectRandomShell(const G4int AtomIndex,
for(G4int ind = 0; ind < oneAtomCS->entries(); ind++){
G4double crossSec;
G4Data* EnergyVector = (*(*oneAtomCS)[ind])[0];
G4Data* CrossSecVector = (*(*oneAtomCS)[ind])[1];
G4DataVector* EnergyVector = (*(*oneAtomCS)[ind])[0];
G4DataVector* CrossSecVector = (*(*oneAtomCS)[ind])[1];
if(IncEnergy < (*EnergyVector)[0]){ //First element is the shell number
crossSec = 0;
@@ -643,7 +636,6 @@ G4LowEnergyPhotoElectric::SelectRandomAtom(const G4DynamicParticle* aDynamicPhot
}
return (*theElementVector)(0);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//
@@ -701,7 +693,7 @@ G4bool G4LowEnergyPhotoElectric::SelectRandomTransition(G4int thePrimShell,
G4double PartSum = 0;
TransProb = 1;
while(TransProb < (*(*TransitionTable)[ShellNum])[ProbCol]->length()){
while(TransProb < (*(*TransitionTable)[ShellNum])[ProbCol]->size()){
PartSum += (*(*(*TransitionTable)[ShellNum])[ProbCol])[TransProb];
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4LowEnergyRayleigh.cc,v 1.18 2000/07/11 18:46:48 pia Exp $
// GEANT4 tag $Name: geant4-03-00 $
// $Id: G4LowEnergyRayleigh.cc,v 1.19 2001/02/05 17:45:21 gcosmo Exp $
// GEANT4 tag $Name: geant4-03-01 $
//
//
// --------------------------------------------------------------
@@ -71,7 +71,6 @@ G4LowEnergyRayleigh::~G4LowEnergyRayleigh()
}
if(ZNumVec){
ZNumVec->clear();
delete ZNumVec;
}
@@ -104,7 +103,7 @@ void G4LowEnergyRayleigh::BuildCrossSectionTable(){
theCrossSectionTable = new G4SecondLevel();
G4int dataNum = 2;
for(G4int TableInd = 0; TableInd < ZNumVec->entries(); TableInd++){
for(G4int TableInd = 0; TableInd < ZNumVec->size(); TableInd++){
G4int AtomInd = (G4int) (*ZNumVec)[TableInd];
@@ -125,7 +124,7 @@ void G4LowEnergyRayleigh::BuildFormFactorTable(){
theFormFactorTable = new G4SecondLevel();
G4int dataNum = 2;
for(G4int TableInd = 0; TableInd < ZNumVec->entries(); TableInd++){
for(G4int TableInd = 0; TableInd < ZNumVec->size(); TableInd++){
G4int AtomInd = (G4int) (*ZNumVec)[TableInd];
@@ -142,12 +141,11 @@ void G4LowEnergyRayleigh::BuildZVec(){
G4int numOfMaterials = theMaterialTable->length();
if(ZNumVec){
ZNumVec->clear();
delete ZNumVec;
}
ZNumVec = new G4Data();
ZNumVec = new G4DataVector();
for (G4int J=0 ; J < numOfMaterials; J++){
const G4Material* material= (*theMaterialTable)[J];
@@ -159,11 +157,8 @@ void G4LowEnergyRayleigh::BuildZVec(){
G4double Zel = (*theElementVector)(iel)->GetZ();
if(ZNumVec->contains(Zel) == FALSE){
ZNumVec->insert(Zel);
}
else{
ZNumVec->push_back(Zel);
} else{
continue;
}
}
@@ -366,3 +361,4 @@ G4Element* G4LowEnergyRayleigh::SelectRandomAtom(const G4DynamicParticle* aDynam
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4LowEnergyUtilities.cc,v 1.7 2000/12/14 09:43:57 gcosmo Exp $
// GEANT4 tag $Name: geant4-03-00 $
// $Id: G4LowEnergyUtilities.cc,v 1.8 2001/02/05 17:45:21 gcosmo Exp $
// GEANT4 tag $Name: geant4-03-01 $
//
//
// --------------------------------------------------------------
@@ -82,7 +82,7 @@ G4SecondLevel* G4LowEnergyUtilities::BuildSecondLevelTables(const G4int TableInd
for(G4int j = 0; j < ParNum; j++){
oneShellPar->insertAt(j,new G4Data());
oneShellPar->insertAt(j,new G4DataVector());
}
G4double a = 0;
@@ -101,7 +101,7 @@ G4SecondLevel* G4LowEnergyUtilities::BuildSecondLevelTables(const G4int TableInd
for(G4int j = 0; j < ParNum; j++){
oneShellPar->insertAt(j,new G4Data());
oneShellPar->insertAt(j,new G4DataVector());
}
}
@@ -122,12 +122,12 @@ G4SecondLevel* G4LowEnergyUtilities::BuildSecondLevelTables(const G4int TableInd
if(k%ParNum != 0){
(*oneShellPar)[k-1]->insert(a);
(*oneShellPar)[k-1]->push_back(a);
k++;
}
else if(k%ParNum == 0){
(*oneShellPar)[k-1]->insert(a);
(*oneShellPar)[k-1]->push_back(a);
k = 1;
}
}
@@ -181,7 +181,7 @@ G4FirstLevel* G4LowEnergyUtilities::BuildFirstLevelTables(const G4int TableInd,
for(G4int j = 0; j < ParNum; j++){
oneAtomPar->insertAt(j,new G4Data());
oneAtomPar->insertAt(j,new G4DataVector());
}
G4double a = 0;
@@ -198,12 +198,12 @@ G4FirstLevel* G4LowEnergyUtilities::BuildFirstLevelTables(const G4int TableInd,
if(k%ParNum != 0){
(*oneAtomPar)[k-1]->insert(a);
(*oneAtomPar)[k-1]->push_back(a);
k++;
}
else if(k%ParNum == 0){
(*oneAtomPar)[k-1]->insert(a);
(*oneAtomPar)[k-1]->push_back(a);
k = 1;
}
}
@@ -6,7 +6,7 @@
// and all its terms.
//
// $Id: G4VeLowEnergyLoss.cc,v 1.6 2000/11/22 16:06:57 vnivanch Exp $
// GEANT4 tag $Name: geant4-03-00 $
// GEANT4 tag $Name: geant4-03-01 $
//
//
// --------------------------------------------------------------
@@ -6,7 +6,7 @@
// and all its terms.
//
// $Id: G4eLowEnergyLoss.cc,v 1.7 2000/09/20 16:49:41 vnivanch Exp $
// GEANT4 tag $Name: geant4-03-00 $
// GEANT4 tag $Name: geant4-03-01 $
//
// -----------------------------------------------------------
// GEANT 4 class implementation file
@@ -6,7 +6,7 @@
// and all its terms.
//
// $Id: G4hLowEnergyLoss.cc,v 1.8 2000/11/05 12:17:06 vnivanch Exp $
// GEANT4 tag $Name: geant4-03-00 $
// GEANT4 tag $Name: geant4-03-01 $
//
// -----------------------------------------------------------
// GEANT 4 class implementation file