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/highenergy/src
Files:
20 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/processes/electromagnetic/highenergy/src/G4AnnihiToMuPair.cc

    r1007 r1196  
    2525//
    2626//
    27 // $Id: G4AnnihiToMuPair.cc,v 1.5 2008/10/16 14:29:48 vnivanch Exp $
    28 // GEANT4 tag $Name: geant4-09-02 $
     27// $Id: G4AnnihiToMuPair.cc,v 1.6 2009/11/09 18:24:07 vnivanch Exp $
     28// GEANT4 tag $Name: geant4-09-03-cand-01 $
    2929//
    3030//         ------------ G4AnnihiToMuPair physics process ------
     
    6565 HighestEnergyLimit = 1000*TeV;
    6666 
     67 CurrentSigma = 0.0;
    6768 CrossSecFactor = 1.;
    6869 SetProcessSubType(6);
     
    8889//here no tables, just calling PrintInfoDefinition
    8990{
    90    PrintInfoDefinition();
     91  CurrentSigma = 0.0;
     92  PrintInfoDefinition();
    9193}
    9294
     
    117119  G4double SigmaEl = Sig0*xi*(1.+xi/2.)*sqrt(1.-xi); // per electron
    118120  CrossSection = SigmaEl*Z;         // number of electrons per atom
    119   CrossSection *= CrossSecFactor;   //increase the CrossSection by  (default 1)
    120121  return CrossSection;
    121122}
     
    123124//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
    124125
    125 G4double G4AnnihiToMuPair::GetMeanFreePath(const G4Track& aTrack,
    126                                            G4double, G4ForceCondition*)
    127 
    128 // returns the positron mean free path in GEANT4 internal units
    129 
    130 {
    131   const G4DynamicParticle* aDynamicPositron = aTrack.GetDynamicParticle();
    132   G4double PositronEnergy = aDynamicPositron->GetKineticEnergy()
    133                                               +electron_mass_c2;
    134   G4Material* aMaterial = aTrack.GetMaterial();
     126G4double G4AnnihiToMuPair::CrossSectionPerVolume(G4double PositronEnergy,
     127                                                 const G4Material* aMaterial)
     128{
    135129  const G4ElementVector* theElementVector = aMaterial->GetElementVector();
    136130  const G4double* NbOfAtomsPerVolume = aMaterial->GetVecNbOfAtomsPerVolume();
    137131
    138   G4double SIGMA = 0 ;
    139 
    140   for ( size_t i=0 ; i < aMaterial->GetNumberOfElements() ; i++ )
     132  G4double SIGMA = 0.0;
     133
     134  for ( size_t i=0 ; i < aMaterial->GetNumberOfElements() ; ++i )
    141135  {
    142136    G4double AtomicZ = (*theElementVector)[i]->GetZ();
     
    144138      ComputeCrossSectionPerAtom(PositronEnergy,AtomicZ);
    145139  }
    146   return SIGMA > DBL_MIN ? 1./SIGMA : DBL_MAX;
     140  return SIGMA;
     141}
     142
     143//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
     144
     145G4double G4AnnihiToMuPair::GetMeanFreePath(const G4Track& aTrack,
     146                                           G4double, G4ForceCondition*)
     147
     148// returns the positron mean free path in GEANT4 internal units
     149
     150{
     151  const G4DynamicParticle* aDynamicPositron = aTrack.GetDynamicParticle();
     152  G4double PositronEnergy = aDynamicPositron->GetKineticEnergy()
     153                                              +electron_mass_c2;
     154  G4Material* aMaterial = aTrack.GetMaterial();
     155  CurrentSigma = CrossSectionPerVolume(PositronEnergy, aMaterial);
     156
     157  // increase the CrossSection by CrossSecFactor (default 1)
     158  G4double mfp = DBL_MAX;
     159  if(CurrentSigma > DBL_MIN) mfp = 1.0/(CurrentSigma*CrossSecFactor);
     160
     161  return mfp;
    147162}
    148163
     
    162177  // current Positron energy and direction, return if energy too low
    163178  const G4DynamicParticle *aDynamicPositron = aTrack.GetDynamicParticle();
    164   G4double Epos = aDynamicPositron->GetKineticEnergy()+Mele;
    165 
    166  if (Epos < LowestEnergyLimit)
    167   { G4cout
    168         << "error in G4AnnihiToMuPair::PostStepDoIt called with energy below"
    169            " threshold Epos= "
    170         << Epos << G4endl;       // shoud never happen
    171         G4Exception(10);
     179  G4double Epos = aDynamicPositron->GetKineticEnergy() + Mele;
     180
     181  // test of cross section
     182  if(CurrentSigma*G4UniformRand() >
     183     CrossSectionPerVolume(Epos, aTrack.GetMaterial()))
     184    {
     185      return G4VDiscreteProcess::PostStepDoIt(aTrack,aStep);
     186    }
     187
     188  if (Epos < LowestEnergyLimit) {
     189     return G4VDiscreteProcess::PostStepDoIt(aTrack,aStep);
    172190  }
    173 
    174   if (Epos < LowestEnergyLimit)
    175      return G4VDiscreteProcess::PostStepDoIt(aTrack,aStep);
    176191
    177192  G4ParticleMomentum PositronDirection =
  • trunk/source/processes/electromagnetic/highenergy/src/G4BetheBlochNoDeltaModel.cc

    r1055 r1196  
    2525//
    2626// $Id: G4BetheBlochNoDeltaModel.cc,v 1.4 2009/02/20 16:38:33 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/highenergy/src/G4BraggNoDeltaModel.cc

    r1055 r1196  
    2525//
    2626// $Id: G4BraggNoDeltaModel.cc,v 1.4 2009/02/20 16:38:33 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/highenergy/src/G4GammaConversionToMuons.cc

    r1007 r1196  
    2626//
    2727// $Id: G4GammaConversionToMuons.cc,v 1.7 2008/10/16 14:29:48 vnivanch Exp $
    28 // GEANT4 tag $Name: geant4-09-02 $
     28// GEANT4 tag $Name: geant4-09-03-cand-01 $
    2929//
    3030//         ------------ G4GammaConversionToMuons physics process ------
  • trunk/source/processes/electromagnetic/highenergy/src/G4ee2KChargedModel.cc

    r1055 r1196  
    2525//
    2626// $Id: G4ee2KChargedModel.cc,v 1.2 2009/02/20 16:38:33 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/highenergy/src/G4ee2KNeutralModel.cc

    r1055 r1196  
    2525//
    2626// $Id: G4ee2KNeutralModel.cc,v 1.2 2009/02/20 16:38:33 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/highenergy/src/G4eeCrossSections.cc

    r1007 r1196  
    2525//
    2626// $Id: G4eeCrossSections.cc,v 1.7 2008/07/10 18:06:39 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-02 $
     27// GEANT4 tag $Name: geant4-09-03-cand-01 $
    2828//
    2929// -------------------------------------------------------------------
  • trunk/source/processes/electromagnetic/highenergy/src/G4eeTo3PiModel.cc

    r1055 r1196  
    2424// ********************************************************************
    2525//
    26 // $Id: G4eeTo3PiModel.cc,v 1.2 2009/02/20 16:38:33 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $
     26// $Id: G4eeTo3PiModel.cc,v 1.3 2009/11/11 17:13:47 vnivanch Exp $
     27// GEANT4 tag $Name: geant4-09-03-cand-01 $
    2828//
    2929// -------------------------------------------------------------------
     
    131131
    132132  G4LorentzVector w0, w1, w2;
    133   G4ThreeVector dir0, dir1, mom, mom1, mom2;
     133  G4ThreeVector dir0, dir1;
    134134  G4double e0, p0, e2, p, g, m01, m02, m12;
    135135
     
    154154    w2 = G4LorentzVector(p*dir1.x(),p*dir1.y(),p*dir1.z(),sqrt(e2));
    155155    w2.boost(bst);
    156     mom2 = w2.vect();
     156    G4double px2 = w2.x();
     157    G4double py2 = w2.y();
     158    G4double pz2 = w2.z();
    157159
    158160    // pi-
    159161    w1 -= w2;
    160     mom1 = w2.vect();
     162    G4double px1 = w1.x();
     163    G4double py1 = w1.y();
     164    G4double pz1 = w1.z();
    161165
    162166    m01 = w0*w1;
     
    164168    m12 = w1*w2;
    165169
    166     mom = mom1*mom2;
    167     g = mom.mag2()*norm( 1.0/cross->DpRho(m01) +  1.0/cross->DpRho(m02)
    168                          + 1.0/cross->DpRho(m12) );
     170    G4double px = py1*pz2 - py2*pz1;
     171    G4double py = pz1*px2 - pz2*px1;
     172    G4double pz = px1*py2 - px2*py1;
     173
     174    g = (px*px + py*py + pz*pz)*
     175      norm( 1.0/cross->DpRho(m01) +  1.0/cross->DpRho(m02)
     176            + 1.0/cross->DpRho(m12) );
    169177    if(g > gmax) {
    170178      G4cout << "G4eeTo3PiModel::SampleSecondaries WARNING matrix element g= "
  • trunk/source/processes/electromagnetic/highenergy/src/G4eeToHadrons.cc

    r1055 r1196  
    2525//
    2626// $Id: G4eeToHadrons.cc,v 1.9 2009/02/20 16:38:33 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/highenergy/src/G4eeToHadronsModel.cc

    r1007 r1196  
    2525//
    2626// $Id: G4eeToHadronsModel.cc,v 1.9 2008/07/10 18:06:39 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-02 $
     27// GEANT4 tag $Name: geant4-09-03-cand-01 $
    2828//
    2929// -------------------------------------------------------------------
  • trunk/source/processes/electromagnetic/highenergy/src/G4eeToHadronsMultiModel.cc

    r1055 r1196  
    2525//
    2626// $Id: G4eeToHadronsMultiModel.cc,v 1.8 2009/04/12 17:48:21 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/highenergy/src/G4eeToPGammaModel.cc

    r1055 r1196  
    2525//
    2626// $Id: G4eeToPGammaModel.cc,v 1.2 2009/02/20 16:38:33 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/highenergy/src/G4eeToTwoPiModel.cc

    r1055 r1196  
    2525//
    2626// $Id: G4eeToTwoPiModel.cc,v 1.7 2009/02/20 16:38:33 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/highenergy/src/G4hBremsstrahlung.cc

    r1055 r1196  
    2525//
    2626// $Id: G4hBremsstrahlung.cc,v 1.4 2009/02/20 16:38:33 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/highenergy/src/G4hBremsstrahlungModel.cc

    r1007 r1196  
    2525//
    2626// $Id: G4hBremsstrahlungModel.cc,v 1.3 2008/07/22 16:15:16 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-02 $
     27// GEANT4 tag $Name: geant4-09-03-cand-01 $
    2828//
    2929// -------------------------------------------------------------------
  • trunk/source/processes/electromagnetic/highenergy/src/G4hPairProduction.cc

    r1055 r1196  
    2525//
    2626// $Id: G4hPairProduction.cc,v 1.4 2009/02/20 16:38:33 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/highenergy/src/G4hPairProductionModel.cc

    r1007 r1196  
    2525//
    2626// $Id: G4hPairProductionModel.cc,v 1.1 2008/03/06 11:47:11 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-02 $
     27// GEANT4 tag $Name: geant4-09-03-cand-01 $
    2828//
    2929// -------------------------------------------------------------------
  • trunk/source/processes/electromagnetic/highenergy/src/G4hhIonisation.cc

    r1055 r1196  
    2525//
    2626// $Id: G4hhIonisation.cc,v 1.9 2009/02/20 16:38:33 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/highenergy/src/G4mplIonisation.cc

    r1055 r1196  
    2525//
    2626// $Id: G4mplIonisation.cc,v 1.8 2009/02/20 16:38:33 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/highenergy/src/G4mplIonisationModel.cc

    r1055 r1196  
    2525//
    2626// $Id: G4mplIonisationModel.cc,v 1.7 2009/04/12 17:35:41 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $
     27// GEANT4 tag $Name: geant4-09-03-cand-01 $
    2828//
    2929// -------------------------------------------------------------------
Note: See TracChangeset for help on using the changeset viewer.