Ignore:
Timestamp:
Nov 25, 2009, 5:13:58 PM (15 years ago)
Author:
garnier
Message:

update CVS release candidate geant4.9.3.01

Location:
trunk/source/processes/electromagnetic/muons/src
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/processes/electromagnetic/muons/src/G4EnergyLossForExtrapolator.cc

    r1007 r1196  
    2424// ********************************************************************
    2525//
    26 // $Id: G4EnergyLossForExtrapolator.cc,v 1.18 2008/11/13 14:14:07 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-02 $
     26// $Id: G4EnergyLossForExtrapolator.cc,v 1.19 2009/07/09 17:04:55 vnivanch Exp $
     27// GEANT4 tag $Name: geant4-09-03-cand-01 $
    2828//
    2929//---------------------------------------------------------------------------
     
    230230  currentParticleName = "";
    231231
    232   linLossLimit = 0.001;
     232  linLossLimit = 0.01;
    233233  emin         = 1.*MeV;
    234234  emax         = 10.*TeV;
     
    406406    G4PhysicsVector* aVector = (*table)[i];
    407407
    408     for(G4int j=0; j<nbins; j++) {
     408    for(G4int j=0; j<=nbins; j++) {
    409409       
    410        G4double e = aVector->GetLowEdgeEnergy(j);
     410       G4double e = aVector->Energy(j);
    411411       G4double dedx = ioni->ComputeDEDX(couple,part,e,e) + brem->ComputeDEDX(couple,part,e,e);
    412412       if(1<verbose) {
     
    454454    const G4MaterialCutsCouple* couple = couples[i];
    455455    G4PhysicsVector* aVector = (*table)[i];
    456     for(G4int j=0; j<nbins; j++) {
     456    for(G4int j=0; j<=nbins; j++) {
    457457       
    458        G4double e = aVector->GetLowEdgeEnergy(j);
     458       G4double e = aVector->Energy(j);
    459459       G4double dedx = ioni->ComputeDEDX(couple,part,e,e) +
    460460                       pair->ComputeDEDX(couple,part,e,e) +
     
    499499    const G4MaterialCutsCouple* couple = couples[i];
    500500    G4PhysicsVector* aVector = (*table)[i];
    501     for(G4int j=0; j<nbins; j++) {
     501    for(G4int j=0; j<=nbins; j++) {
    502502       
    503        G4double e = aVector->GetLowEdgeEnergy(j);
     503       G4double e = aVector->Energy(j);
    504504       G4double dedx = ioni->ComputeDEDX(couple,part,e,e);
    505505       aVector->PutValue(j,dedx);
     
    542542      G4cout << "i= " << i << "  mat= " << mat->GetName() << G4endl;
    543543    G4PhysicsVector* aVector = (*table)[i];
    544     for(G4int j=0; j<nbins; j++) {
     544    for(G4int j=0; j<=nbins; j++) {
    545545       
    546        G4double e = aVector->GetLowEdgeEnergy(j);
     546       G4double e = aVector->Energy(j);
    547547       G4double xs = msc->CrossSectionPerVolume(mat,part,e);
    548548       aVector->PutValue(j,xs);
  • trunk/source/processes/electromagnetic/muons/src/G4MuBetheBlochModel.cc

    r1055 r1196  
    2424// ********************************************************************
    2525//
    26 // $Id: G4MuBetheBlochModel.cc,v 1.26 2009/04/12 17:19:01 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $
     26// $Id: G4MuBetheBlochModel.cc,v 1.27 2009/11/09 19:18:01 vnivanch Exp $
     27// GEANT4 tag $Name: geant4-09-03-cand-01 $
    2828//
    2929// -------------------------------------------------------------------
     
    220220  G4double eexc  = material->GetIonisation()->GetMeanExcitationEnergy();
    221221  G4double eexc2 = eexc*eexc;
    222   G4double cden  = material->GetIonisation()->GetCdensity();
    223   G4double mden  = material->GetIonisation()->GetMdensity();
    224   G4double aden  = material->GetIonisation()->GetAdensity();
    225   G4double x0den = material->GetIonisation()->GetX0density();
    226   G4double x1den = material->GetIonisation()->GetX1density();
     222  //G4double cden  = material->GetIonisation()->GetCdensity();
     223  //G4double mden  = material->GetIonisation()->GetMdensity();
     224  //G4double aden  = material->GetIonisation()->GetAdensity();
     225  //G4double x0den = material->GetIonisation()->GetX0density();
     226  //G4double x1den = material->GetIonisation()->GetX1density();
    227227
    228228  G4double eDensity = material->GetElectronDensity();
     
    237237  // density correction
    238238  G4double x = log(bg2)/twoln10;
    239   if ( x >= x0den ) {
    240     dedx -= twoln10*x - cden ;
    241     if ( x < x1den ) dedx -= aden*pow((x1den-x),mden) ;
    242   }
     239  //if ( x >= x0den ) {
     240  //  dedx -= twoln10*x - cden ;
     241  //  if ( x < x1den ) dedx -= aden*pow((x1den-x),mden) ;
     242  //}
     243  dedx -= material->GetIonisation()->DensityCorrection(x);
    243244
    244245  // shell correction
  • trunk/source/processes/electromagnetic/muons/src/G4MuBremsstrahlung.cc

    r1055 r1196  
    2525//
    2626// $Id: G4MuBremsstrahlung.cc,v 1.42 2009/02/20 14:48:16 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $
     27// GEANT4 tag $Name: geant4-09-03-cand-01 $
    2828//
    2929// -------------------------------------------------------------------
  • trunk/source/processes/electromagnetic/muons/src/G4MuBremsstrahlungModel.cc

    r1055 r1196  
    2525//
    2626// $Id: G4MuBremsstrahlungModel.cc,v 1.35 2009/04/12 17:48:45 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $
     27// GEANT4 tag $Name: geant4-09-03-cand-01 $
    2828//
    2929// -------------------------------------------------------------------
  • trunk/source/processes/electromagnetic/muons/src/G4MuIonisation.cc

    r1055 r1196  
    2525//
    2626// $Id: G4MuIonisation.cc,v 1.59 2009/02/26 11:04:20 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $
     27// GEANT4 tag $Name: geant4-09-03-cand-01 $
    2828//
    2929// -------------------------------------------------------------------
  • trunk/source/processes/electromagnetic/muons/src/G4MuMultipleScattering.cc

    r1007 r1196  
    2424// ********************************************************************
    2525//
    26 // $Id: G4MuMultipleScattering.cc,v 1.12 2008/10/16 13:37:04 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-02 $
     26// $Id: G4MuMultipleScattering.cc,v 1.14 2009/10/30 18:37:06 vnivanch Exp $
     27// GEANT4 tag $Name: geant4-09-03-cand-01 $
    2828//
    2929// -----------------------------------------------------------------------------
     
    4848#include "G4MuMultipleScattering.hh"
    4949#include "G4WentzelVIModel.hh"
     50#include "G4UrbanMscModel90.hh"
    5051#include "G4MscStepLimitType.hh"
    5152
     
    5455using namespace std;
    5556
    56 G4MuMultipleScattering::G4MuMultipleScattering(G4double tet,
    57                                                const G4String& processName)
    58   : G4VMultipleScattering(processName), thetaLimit(tet)
     57G4MuMultipleScattering::G4MuMultipleScattering(const G4String& pnam)
     58  : G4VMultipleScattering(pnam)
    5959{
    60   dtrl              = 0.05;
    61   samplez           = false ;
    62   isInitialized     = false; 
    63   SetRangeFactor(0.2);
    64   SetLateralDisplasmentFlag(true);
     60  isInitialized = false; 
     61  SetStepLimitType(fMinimal);
     62  //SetPolarAngleLimit(CLHEP::twopi);
     63  //SetRangeFactor(0.2);
    6564}
    6665
     
    7978//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
    8079
    81 void G4MuMultipleScattering::InitialiseProcess(const G4ParticleDefinition* p)
     80void G4MuMultipleScattering::InitialiseProcess(const G4ParticleDefinition*)
    8281{
    8382  // Modification of parameters between runs
    84   if(isInitialized) {
    85 
    86     if (p->GetParticleType() != "nucleus" && p->GetPDGMass() < GeV) {
    87       mscModel->SetStepLimitType(StepLimitType());
    88       mscModel->SetLateralDisplasmentFlag(LateralDisplasmentFlag());
    89       mscModel->SetRangeFactor(RangeFactor());
    90     }
    91     mscModel->SetPolarAngleLimit(PolarAngleLimit());
    92     return;
    93   }
    94 
    95   if (p->GetParticleType() == "nucleus" || p->GetPDGMass() > GeV) {
    96     SetLateralDisplasmentFlag(false);
    97     SetBuildLambdaTable(false);
    98   }
    99 
    100   // initialisation of the model
    101 
    102   mscModel = new G4WentzelVIModel();
    103   mscModel->SetStepLimitType(StepLimitType());
    104   mscModel->SetLateralDisplasmentFlag(LateralDisplasmentFlag());
    105   mscModel->SetRangeFactor(RangeFactor());
    106   mscModel->SetPolarAngleLimit(PolarAngleLimit());
    107   mscModel->SetLowEnergyLimit(MinKinEnergy());
    108   mscModel->SetHighEnergyLimit(MaxKinEnergy());
    109 
    110   AddEmModel(1,mscModel);
     83  if(isInitialized) return;
     84  AddEmModel(1, new G4UrbanMscModel90());
     85  //  AddEmModel(1, new G4WentzelVIModel());
    11186  isInitialized = true;
    11287}
     
    11994         << ", step limit type: " << StepLimitType()
    12095         << ", lateralDisplacement: " << LateralDisplasmentFlag()
     96         << ", polarAngleLimit(deg)= " << PolarAngleLimit()/degree
    12197         << G4endl;
    12298}
  • trunk/source/processes/electromagnetic/muons/src/G4MuPairProduction.cc

    r1055 r1196  
    2525//
    2626// $Id: G4MuPairProduction.cc,v 1.52 2009/02/20 14:48:16 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $
     27// GEANT4 tag $Name: geant4-09-03-cand-01 $
    2828//
    2929// -------------------------------------------------------------------
  • trunk/source/processes/electromagnetic/muons/src/G4MuPairProductionModel.cc

    r1055 r1196  
    2424// ********************************************************************
    2525//
    26 // $Id: G4MuPairProductionModel.cc,v 1.41 2009/04/12 17:19:01 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $
     26// $Id: G4MuPairProductionModel.cc,v 1.44 2009/08/11 16:50:07 vnivanch Exp $
     27// GEANT4 tag $Name: geant4-09-03-cand-01 $
    2828//
    2929// -------------------------------------------------------------------
     
    389389
    390390  SetCurrentElement(Z);
    391   G4double tmax = std::min(maxEnergy, kineticEnergy);
    392   G4double cut  = std::min(cutEnergy, kineticEnergy);
    393   if(cut < minPairEnergy) cut = minPairEnergy;
     391
     392  G4double maxPairEnergy = MaxSecondaryEnergy(particle,kineticEnergy);
     393  G4double tmax = std::min(maxEnergy, maxPairEnergy);
     394  G4double cut  = std::max(cutEnergy, minPairEnergy);
    394395  if (cut >= tmax) return cross;
    395396
     
    457458//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
    458459
    459 void G4MuPairProductionModel::SampleSecondaries(std::vector<G4DynamicParticle*>* vdp,
    460                                                 const G4MaterialCutsCouple* couple,
    461                                                 const G4DynamicParticle* aDynamicParticle,
    462                                                 G4double tmin,
    463                                                 G4double tmax)
     460void
     461G4MuPairProductionModel::SampleSecondaries(std::vector<G4DynamicParticle*>* vdp,
     462                                           const G4MaterialCutsCouple* couple,
     463                                           const G4DynamicParticle* aDynamicParticle,
     464                                           G4double tmin,
     465                                           G4double tmax)
    464466{
    465467  G4double kineticEnergy = aDynamicParticle->GetKineticEnergy();
     
    611613
    612614  G4double sum = 0.0;
     615  G4double dl;
    613616
    614617  size_t i;
     
    618621    G4double maxPairEnergy = MaxSecondaryEnergy(particle,kinEnergy);
    619622    G4double minEnergy     = std::max(tmin, minPairEnergy);
    620 
    621     G4int iz;
    622     for(iz=1; iz<nzdat; iz++) {if(Z <= zdat[iz]) break;}
    623     if(iz == nzdat) iz--;
    624     G4double dz = log(Z/zdat[iz-1])/log(zdat[iz]/zdat[iz-1]);
    625 
    626     G4double sigcut;
    627     if(minEnergy <= minPairEnergy)
    628       sigcut = 0.;
    629     else
    630     {
    631       G4double xc = log(minEnergy/minPairEnergy)/log(maxPairEnergy/minPairEnergy);
    632       G4int iy = (G4int)((log(xc) - ymin)/dy);
    633       if(iy < 0) iy = 0;
    634       if(iy >= nbiny) iy = nbiny-1;
    635       sigcut = InterpolatedIntegralCrossSection(dt,dz,iz,it,iy,   Z);
     623    dl = 0.0;
     624    if(minEnergy < maxPairEnergy) {
     625
     626      G4int iz;
     627      for(iz=1; iz<nzdat; iz++) {if(Z <= zdat[iz]) break;}
     628      if(iz == nzdat) iz--;
     629      G4double dz = log(Z/zdat[iz-1])/log(zdat[iz]/zdat[iz-1]);
     630
     631      G4double sigcut;
     632      if(minEnergy <= minPairEnergy)
     633        sigcut = 0.;
     634      else
     635        {
     636          G4double xc = log(minEnergy/minPairEnergy)/log(maxPairEnergy/minPairEnergy);
     637          G4int iy = (G4int)((log(xc) - ymin)/dy);
     638          if(iy < 0) iy = 0;
     639          if(iy >= nbiny) iy = nbiny-1;
     640          sigcut = InterpolatedIntegralCrossSection(dt,dz,iz,it,iy,   Z);
     641        }
     642
     643      G4double sigtot = InterpolatedIntegralCrossSection(dt,dz,iz,it,nbiny,Z);
     644      dl = (sigtot - sigcut)*theAtomNumDensityVector[i];
    636645    }
    637 
    638     G4double sigtot = InterpolatedIntegralCrossSection(dt,dz,iz,it,nbiny,Z);
    639     G4double dl = (sigtot - sigcut)*theAtomNumDensityVector[i];
    640 
    641646    // protection
    642647    if(dl < 0.0) dl = 0.0;
Note: See TracChangeset for help on using the changeset viewer.