81   theDEDXTable(aDEDXTable), theRangeTable(aRangeTable),
 
   82   theInverseRangeTable(anInverseRangeTable),
 
   83   theLabTimeTable(aLabTimeTable),
 
   84   theProperTimeTable(aProperTimeTable),
 
   85   theLowestKineticEnergy(aLowestKineticEnergy),
 
   86   theHighestKineticEnergy(aHighestKineticEnergy),
 
   87   theMassRatio(aMassRatio),
 
   88   theNumberOfBins(aNumberOfBins)
 
  122                     tLabTime,tProperTime,lowestKineticEnergy,
 
  123                     highestKineticEnergy, massRatio,NumberOfBins);
 
  141   helper_map::iterator it;
 
  142   if((it=
dict->find(p))==
dict->end()) 
return 0;
 
  143   return (*it).second.theDEDXTable;
 
  152   helper_map::iterator it;
 
  153   if((it=
dict->find(p))==
dict->end()) 
return 0;
 
  154   return (*it).second.theRangeTable;
 
  163   helper_map::iterator it;
 
  164   if((it=
dict->find(p))==
dict->end()) 
return 0;
 
  165   return (*it).second.theInverseRangeTable;
 
  174   helper_map::iterator it;
 
  175   if((it=
dict->find(p))==
dict->end()) 
return 0;
 
  176   return (*it).second.theLabTimeTable;
 
  185   helper_map::iterator it;
 
  186   if((it=
dict->find(p))==
dict->end()) 
return 0;
 
  187   return (*it).second.theProperTimeTable;
 
  198   helper_map::iterator it;
 
  199   if ((it=
dict->find(p))==
dict->end()) {
 
  235   if (scaledKineticEnergy<t->theLowestKineticEnergy) {
 
  237      dEdx =(*dEdxTable)(materialIndex)->GetValue(
 
  243      dEdx = (*dEdxTable)(materialIndex)->GetValue(
 
  248     dEdx = (*dEdxTable)(materialIndex)->GetValue(
 
  249                scaledKineticEnergy,isOut);
 
  278   const G4double parlowen=0.4 , ppar=0.5-parlowen ;
 
  284   if (scaledKineticEnergy<t->theLowestKineticEnergy) {
 
  287             (*labtimeTable)(materialIndex)->GetValue(
 
  293      time = (*labtimeTable)(materialIndex)->GetValue(
 
  298     time = (*labtimeTable)(materialIndex)->GetValue(
 
  299                scaledKineticEnergy,isOut);
 
  329   const G4double parlowen=0.4 , ppar=0.5-parlowen ;
 
  330   const G4double dToverT = 0.05 , facT = 1. -dToverT ;
 
  331   G4double timestart,timeend,deltatime,dTT;
 
  337   if (scaledKineticEnergy<t->theLowestKineticEnergy) {
 
  340                 (*labtimeTable)(materialIndex)->GetValue(
 
  346      timestart = (*labtimeTable)(materialIndex)->GetValue(
 
  351     timestart = (*labtimeTable)(materialIndex)->GetValue(
 
  352                 scaledKineticEnergy,isOut);
 
  356   dTT = (KineticEnergyStart - KineticEnergyEnd)/KineticEnergyStart ;
 
  359     scaledKineticEnergy = facT*KineticEnergyStart*
t->
theMassRatio;
 
  363   if (scaledKineticEnergy<t->theLowestKineticEnergy) {
 
  366                 (*labtimeTable)(materialIndex)->GetValue(
 
  372      timeend = (*labtimeTable)(materialIndex)->GetValue(
 
  377     timeend = (*labtimeTable)(materialIndex)->GetValue(
 
  378                 scaledKineticEnergy,isOut);
 
  382   deltatime = timestart - timeend ;
 
  385     deltatime *= dTT/dToverT;
 
  407   if (!propertimeTable) {
 
  412   const G4double parlowen=0.4 , ppar=0.5-parlowen ;
 
  418   if (scaledKineticEnergy<t->theLowestKineticEnergy) {
 
  421             (*propertimeTable)(materialIndex)->GetValue(
 
  427      time = (*propertimeTable)(materialIndex)->GetValue(
 
  432     time = (*propertimeTable)(materialIndex)->GetValue(
 
  433                scaledKineticEnergy,isOut);
 
  458   if (!propertimeTable) {
 
  463   const G4double parlowen=0.4 , ppar=0.5-parlowen ;
 
  464   const G4double dToverT = 0.05 , facT = 1. -dToverT ;
 
  465   G4double timestart,timeend,deltatime,dTT;
 
  471   if (scaledKineticEnergy<t->theLowestKineticEnergy) {
 
  474                 (*propertimeTable)(materialIndex)->GetValue(
 
  480      timestart = (*propertimeTable)(materialIndex)->GetValue(
 
  485     timestart = (*propertimeTable)(materialIndex)->GetValue(
 
  486                 scaledKineticEnergy,isOut);
 
  490   dTT = (KineticEnergyStart - KineticEnergyEnd)/KineticEnergyStart ;
 
  493     scaledKineticEnergy = facT*KineticEnergyStart*
t->
theMassRatio;
 
  497   if (scaledKineticEnergy<t->theLowestKineticEnergy) {
 
  500                 (*propertimeTable)(materialIndex)->GetValue(
 
  506      timeend = (*propertimeTable)(materialIndex)->GetValue(
 
  511     timeend = (*propertimeTable)(materialIndex)->GetValue(
 
  512                 scaledKineticEnergy,isOut);
 
  516   deltatime = timestart - timeend ;
 
  519     deltatime *= dTT/dToverT ;
 
  555   if (scaledKineticEnergy<t->theLowestKineticEnergy) {
 
  558             (*rangeTable)(materialIndex)->GetValue(
 
  563     Range = (*rangeTable)(materialIndex)->GetValue(
 
  566             (*dEdxTable)(materialIndex)->GetValue(
 
  571     Range = (*rangeTable)(materialIndex)->GetValue(
 
  572                scaledKineticEnergy,isOut);
 
  601   if (!inverseRangeTable) {
 
  606   G4double scaledrange,scaledKineticEnergy ;
 
  614     rmin = (*inverseRangeTable)(materialIndex)->
 
  615                               GetLowEdgeEnergy(0) ;
 
  616     rmax = (*inverseRangeTable)(materialIndex)->
 
  618     Thigh = (*inverseRangeTable)(materialIndex)->
 
  619                               GetValue(
rmax,isOut) ;
 
  624   if(scaledrange < 
rmin)
 
  627                    scaledrange*scaledrange/(
rmin*
rmin) ;
 
  631     if(scaledrange < 
rmax)
 
  633       scaledKineticEnergy = (*inverseRangeTable)(materialIndex)->
 
  634                               GetValue( scaledrange,isOut) ;
 
  638       scaledKineticEnergy = 
Thigh +
 
  640                       (*dEdxTable)(materialIndex)->
 
  641                                  GetValue(
Thigh,isOut) ;
 
  678   if (scaledKineticEnergy<t->theLowestKineticEnergy) {
 
  681             *(*dEdxTable)(materialIndex)->GetValue(
 
  686      dEdx = (*dEdxTable)(materialIndex)->GetValue(
 
  691       dEdx = (*dEdxTable)(materialIndex)->GetValue(
 
  692                           scaledKineticEnergy,isOut) ;
 
  727                    (*rangeTable)(materialIndex)->
 
  728                    GetLowEdgeEnergy(1) ;
 
  734   if (scaledKineticEnergy<t->theLowestKineticEnergy) {
 
  737             (*rangeTable)(materialIndex)->GetValue(
 
  740   } 
else if (scaledKineticEnergy>Thighr) {
 
  742     Range = (*rangeTable)(materialIndex)->GetValue(
 
  744             (scaledKineticEnergy-Thighr)/
 
  745             (*dEdxTable)(materialIndex)->GetValue(
 
  750      Range = (*rangeTable)(materialIndex)->GetValue(
 
  751                        scaledKineticEnergy,isOut) ;
 
  790   if (scaledKineticEnergy<t->theLowestKineticEnergy) {
 
  792      dEdx =(*dEdxTable)(materialIndex)->GetValue(
 
  798      dEdx = (*dEdxTable)(materialIndex)->GetValue(
 
  803     dEdx = (*dEdxTable)(materialIndex)->GetValue(
 
  804                scaledKineticEnergy,isOut);
 
  843   if (scaledKineticEnergy<t->theLowestKineticEnergy) {
 
  846             (*rangeTable)(materialIndex)->GetValue(
 
  851     Range = (*rangeTable)(materialIndex)->GetValue(
 
  854             (*dEdxTable)(materialIndex)->GetValue(
 
  859     Range = (*rangeTable)(materialIndex)->GetValue(
 
  860                scaledKineticEnergy,isOut);
 
  890   if (!inverseRangeTable) {
 
  896   G4double scaledrange,scaledKineticEnergy ;
 
  904     rmin = (*inverseRangeTable)(materialIndex)->
 
  905                               GetLowEdgeEnergy(0) ;
 
  906     rmax = (*inverseRangeTable)(materialIndex)->
 
  908     Thigh = (*inverseRangeTable)(materialIndex)->
 
  909                               GetValue(
rmax,isOut) ;
 
  914   if(scaledrange < 
rmin)
 
  917                    scaledrange*scaledrange/(
rmin*
rmin) ;
 
  921     if(scaledrange < 
rmax)
 
  923       scaledKineticEnergy = (*inverseRangeTable)(materialIndex)->
 
  924                               GetValue( scaledrange,isOut) ;
 
  928       scaledKineticEnergy = 
Thigh +
 
  930                       (*dEdxTable)(materialIndex)->
 
  931                                  GetValue(
Thigh,isOut) ;
 
  965   if (scaledKineticEnergy<t->theLowestKineticEnergy) {
 
  968             *(*dEdxTable)(materialIndex)->GetValue(
 
  973      dEdx = (*dEdxTable)(materialIndex)->GetValue(
 
  978       dEdx = (*dEdxTable)(materialIndex)->GetValue(
 
  979                           scaledKineticEnergy,isOut) ;
 
 1006   if ( !dEdxTable || !rangeTable)
 
 1012                    (*rangeTable)(materialIndex)->
 
 1013                    GetLowEdgeEnergy(1) ;
 
 1019   if (scaledKineticEnergy<t->theLowestKineticEnergy) {
 
 1022             (*rangeTable)(materialIndex)->GetValue(
 
 1025   } 
else if (scaledKineticEnergy>Thighr) {
 
 1027     Range = (*rangeTable)(materialIndex)->GetValue(
 
 1029             (scaledKineticEnergy-Thighr)/
 
 1030             (*dEdxTable)(materialIndex)->GetValue(
 
 1035      Range = (*rangeTable)(materialIndex)->GetValue(
 
 1036                        scaledKineticEnergy,isOut) ;
 
 1050     G4cout << 
"##### G4EnergyLossTable WARNING: The obsolete interface is used!" << 
G4endl;
 
 1051     G4cout << 
"##### RESULTS ARE NOT GARANTEED!" << 
G4endl;
 
 1052     G4cout << 
"##### Please, substitute G4Material by G4MaterialCutsCouple" << 
G4endl;
 
 1053     G4cout << 
"##### Obsolete interface will be removed soon" << 
G4endl;
 
 1059     G4cout << 
"##### G4EnergyLossTable WARNING closed" << 
G4endl;
 
static G4double GetDeltaProperTime(const G4ParticleDefinition *aParticle, G4double KineticEnergyStart, G4double KineticEnergyEnd, const G4Material *aMaterial)
 
const G4PhysicsTable * theProperTimeTable
 
static G4EnergyLossTablesHelper * null_loss
 
static G4LossTableManager * Instance()
 
G4double GetDEDX(const G4ParticleDefinition *aParticle, G4double kineticEnergy, const G4MaterialCutsCouple *couple)
 
static const G4PhysicsTable * GetDEDXTable(const G4ParticleDefinition *p)
 
const G4PhysicsTable * theDEDXTable
 
static void ParticleHaveNoLoss(const G4ParticleDefinition *aParticle, const G4String &)
 
const G4PhysicsTable * theRangeTable
 
static G4EnergyLossTablesHelper * t
 
static G4double GetDeltaLabTime(const G4ParticleDefinition *aParticle, G4double KineticEnergyStart, G4double KineticEnergyEnd, const G4Material *aMaterial)
 
G4EnergyLossTablesHelper()
 
static G4double QQPositron
 
G4GLOB_DLL std::ostream G4cout
 
const G4PhysicsTable * theLabTimeTable
 
static G4double GetLabTime(const G4ParticleDefinition *aParticle, G4double KineticEnergy, const G4Material *aMaterial)
 
static G4double GetPreciseRangeFromEnergy(const G4ParticleDefinition *aParticle, G4double KineticEnergy, const G4Material *aMaterial)
 
static G4EnergyLossTablesHelper GetTables(const G4ParticleDefinition *p)
 
G4double GetEnergy(const G4ParticleDefinition *aParticle, G4double range, const G4MaterialCutsCouple *couple)
 
static const G4PhysicsTable * GetLabTimeTable(const G4ParticleDefinition *p)
 
std::map< K, G4EnergyLossTablesHelper, std::less< K > > helper_map
 
static const G4PhysicsTable * GetRangeTable(const G4ParticleDefinition *p)
 
G4double theHighestKineticEnergy
 
static G4double GetDEDX(const G4ParticleDefinition *aParticle, G4double KineticEnergy, const G4Material *aMaterial)
 
static G4double GetProperTime(const G4ParticleDefinition *aParticle, G4double KineticEnergy, const G4Material *aMaterial)
 
const G4PhysicsTable * theInverseRangeTable
 
static void Register(const G4ParticleDefinition *p, const G4PhysicsTable *tDEDX, const G4PhysicsTable *tRange, const G4PhysicsTable *tInverseRange, const G4PhysicsTable *tLabTime, const G4PhysicsTable *tProperTime, G4double lowestKineticEnergy, G4double highestKineticEnergy, G4double massRatio, G4int NumberOfBins)
 
static const G4PhysicsTable * GetInverseRangeTable(const G4ParticleDefinition *p)
 
static G4ParticleDefinition * lastParticle
 
G4double GetPDGCharge() const 
 
static G4double GetPreciseEnergyFromRange(const G4ParticleDefinition *aParticle, G4double range, const G4Material *aMaterial)
 
static G4double GetPreciseDEDX(const G4ParticleDefinition *aParticle, G4double KineticEnergy, const G4Material *aMaterial)
 
G4double GetRange(const G4ParticleDefinition *aParticle, G4double kineticEnergy, const G4MaterialCutsCouple *couple)
 
static const G4PhysicsTable * GetProperTimeTable(const G4ParticleDefinition *p)
 
static G4double GetRange(const G4ParticleDefinition *aParticle, G4double KineticEnergy, const G4Material *aMaterial)
 
static G4double Chargesquare
 
G4double theLowestKineticEnergy
 
static G4int let_max_num_warnings