Ignore:
Timestamp:
May 28, 2009, 4:26:57 PM (15 years ago)
Author:
garnier
Message:

maj sur la beta de geant 4.9.3

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

Legend:

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

    r1007 r1055  
    2424// ********************************************************************
    2525//
    26 // $Id: G4MuBetheBlochModel.cc,v 1.24 2008/03/25 12:31:04 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-02 $
     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 $
    2828//
    2929// -------------------------------------------------------------------
     
    8888  theElectron = G4Electron::Electron();
    8989  corr = G4LossTableManager::Instance()->EmCorrections();
     90  fParticleChange = 0;
    9091
    9192  if(p) SetParticle(p);
     
    99100//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
    100101
    101 void G4MuBetheBlochModel::SetParticle(const G4ParticleDefinition* p)
    102 {
    103   if(!particle) {
    104     particle = p;
    105     mass = particle->GetPDGMass();
    106     massSquare = mass*mass;
    107     ratio = electron_mass_c2/mass;
    108   }
    109 }
    110 
    111 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
    112 
    113102G4double G4MuBetheBlochModel::MinEnergyCut(const G4ParticleDefinition*,
    114103                                           const G4MaterialCutsCouple* couple)
     
    117106}
    118107
     108//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
     109
     110G4double G4MuBetheBlochModel::MaxSecondaryEnergy(const G4ParticleDefinition*,
     111                                                 G4double kinEnergy)
     112{
     113  G4double tau  = kinEnergy/mass;
     114  G4double tmax = 2.0*electron_mass_c2*tau*(tau + 2.) /
     115                  (1. + 2.0*(tau + 1.)*ratio + ratio*ratio);
     116  return tmax;
     117}
     118
    119119//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
    120120
     
    123123{
    124124  if(p) SetParticle(p);
    125 
    126   if(pParticleChange)
    127     fParticleChange = reinterpret_cast<G4ParticleChangeForLoss*>
    128                                                              (pParticleChange);
    129   else
    130     fParticleChange = new G4ParticleChangeForLoss();
     125  if(!fParticleChange) fParticleChange = GetParticleChangeForLoss();
    131126}
    132127
  • trunk/source/processes/electromagnetic/muons/src/G4MuBremsstrahlung.cc

    r1007 r1055  
    2424// ********************************************************************
    2525//
    26 // $Id: G4MuBremsstrahlung.cc,v 1.41 2008/10/16 13:37:04 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-02 $
     26// $Id: G4MuBremsstrahlung.cc,v 1.42 2009/02/20 14:48:16 vnivanch Exp $
     27// GEANT4 tag $Name: geant4-09-03-beta-cand-01 $
    2828//
    2929// -------------------------------------------------------------------
     
    9393//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
    9494
     95G4bool G4MuBremsstrahlung::IsApplicable(const G4ParticleDefinition& p)
     96{
     97  return (p.GetPDGCharge() != 0.0 && p.GetPDGMass() > 10.0*MeV);
     98}
     99
     100//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
     101
     102G4double G4MuBremsstrahlung::MinPrimaryEnergy(const G4ParticleDefinition*,
     103                                              const G4Material*,
     104                                              G4double)
     105{
     106  return lowestKinEnergy;
     107}
     108
     109//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
     110
    95111void G4MuBremsstrahlung::InitialiseEnergyLossProcess(
    96112                                 const G4ParticleDefinition* part,
  • trunk/source/processes/electromagnetic/muons/src/G4MuBremsstrahlungModel.cc

    r1007 r1055  
    2424// ********************************************************************
    2525//
    26 // $Id: G4MuBremsstrahlungModel.cc,v 1.32 2008/07/22 16:11:34 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-02 $
     26// $Id: G4MuBremsstrahlungModel.cc,v 1.35 2009/04/12 17:48:45 vnivanch Exp $
     27// GEANT4 tag $Name: geant4-09-03-beta-cand-01 $
    2828//
    2929// -------------------------------------------------------------------
     
    111111//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
    112112
     113G4double G4MuBremsstrahlungModel::MinEnergyCut(const G4ParticleDefinition*,
     114                                               const G4MaterialCutsCouple*)
     115{
     116  return minThreshold;
     117}
     118
     119//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
     120
    113121void G4MuBremsstrahlungModel::Initialise(const G4ParticleDefinition* p,
    114122                                         const G4DataVector& cuts)
     
    131139    if(nn > 0) {
    132140      for (G4int ii=0; ii<nn; ii++){
    133         G4DataVector* a=partialSumSigma[ii];
     141        G4DataVector* a = partialSumSigma[ii];
    134142        if ( a )  delete a;   
    135143      }
     
    154162
    155163  // define pointer to G4ParticleChange
    156   if(!fParticleChange) {
    157     if(pParticleChange)
    158       fParticleChange =
    159         reinterpret_cast<G4ParticleChangeForLoss*>(pParticleChange);
    160     else
    161       fParticleChange = new G4ParticleChangeForLoss();
    162   }
     164  if(!fParticleChange) fParticleChange = GetParticleChangeForLoss();
    163165}
    164166
  • trunk/source/processes/electromagnetic/muons/src/G4MuIonisation.cc

    r1007 r1055  
    2424// ********************************************************************
    2525//
    26 // $Id: G4MuIonisation.cc,v 1.57 2008/10/27 10:55:07 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-02 $
     26// $Id: G4MuIonisation.cc,v 1.59 2009/02/26 11:04:20 vnivanch Exp $
     27// GEANT4 tag $Name: geant4-09-03-beta-cand-01 $
    2828//
    2929// -------------------------------------------------------------------
     
    8686#include "G4MuBetheBlochModel.hh"
    8787#include "G4UniversalFluctuation.hh"
     88#include "G4IonFluctuations.hh"
    8889#include "G4BohrFluctuations.hh"
    8990#include "G4UnitsTable.hh"
     
    112113//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
    113114
     115G4bool G4MuIonisation::IsApplicable(const G4ParticleDefinition& p)
     116{
     117  return (p.GetPDGCharge() != 0.0 && p.GetPDGMass() > 10.0*MeV);
     118}
     119
     120//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
     121
     122G4double G4MuIonisation::MinPrimaryEnergy(const G4ParticleDefinition*,
     123                                          const G4Material*,
     124                                          G4double cut)
     125{
     126  G4double x = 0.5*cut/electron_mass_c2;
     127  G4double g = x*ratio + std::sqrt((1. + x)*(1. + x*ratio*ratio));
     128  return mass*(g - 1.0);
     129}
     130
     131//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
     132
    114133void G4MuIonisation::InitialiseEnergyLossProcess(const G4ParticleDefinition* part,
    115134                                                 const G4ParticleDefinition* bpart)
     
    123142    SetSecondaryParticle(G4Electron::Electron());
    124143
    125     flucModel = new G4UniversalFluctuation();
     144    // Bragg peak model
     145    if (!EmModel(1)) SetEmModel(new G4BraggModel(),1);
     146    EmModel(1)->SetLowEnergyLimit(MinKinEnergy());
     147    EmModel(1)->SetHighEnergyLimit(0.2*MeV);
     148    AddEmModel(1, EmModel(1), new G4IonFluctuations());
    126149
    127     G4VEmModel* em = new G4BraggModel();
    128     em->SetLowEnergyLimit(MinKinEnergy());
    129     em->SetHighEnergyLimit(0.2*MeV);
    130     AddEmModel(1, em, flucModel);
    131     G4VEmModel* em1 = new G4BetheBlochModel();
    132     em1->SetLowEnergyLimit(0.2*MeV);
    133     em1->SetHighEnergyLimit(1.0*GeV);
    134     AddEmModel(2, em1, flucModel);
    135     G4VEmModel* em2 = new G4MuBetheBlochModel();
    136     em2->SetLowEnergyLimit(1.0*GeV);
    137     em2->SetHighEnergyLimit(MaxKinEnergy());
    138     AddEmModel(3, em2, flucModel);
     150    // high energy fluctuation model
     151    if (!FluctModel()) SetFluctModel(new G4UniversalFluctuation());
     152
     153    // moderate energy model
     154    if (!EmModel(2)) SetEmModel(new G4BetheBlochModel(),2);
     155    EmModel(2)->SetLowEnergyLimit(0.2*MeV);
     156    EmModel(2)->SetHighEnergyLimit(1.0*GeV);
     157    AddEmModel(2, EmModel(2), FluctModel());
     158
     159    // high energy model
     160    if (!EmModel(3)) SetEmModel(new G4MuBetheBlochModel(),3);
     161    EmModel(3)->SetLowEnergyLimit(1.0*GeV);
     162    EmModel(3)->SetHighEnergyLimit(MaxKinEnergy());
     163    AddEmModel(3, EmModel(3), FluctModel());
    139164
    140165    ratio = electron_mass_c2/mass;
  • trunk/source/processes/electromagnetic/muons/src/G4MuPairProduction.cc

    r1007 r1055  
    2424// ********************************************************************
    2525//
    26 // $Id: G4MuPairProduction.cc,v 1.51 2008/10/16 13:37:04 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-02 $
     26// $Id: G4MuPairProduction.cc,v 1.52 2009/02/20 14:48:16 vnivanch Exp $
     27// GEANT4 tag $Name: geant4-09-03-beta-cand-01 $
    2828//
    2929// -------------------------------------------------------------------
     
    100100//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
    101101
     102G4bool G4MuPairProduction::IsApplicable(const G4ParticleDefinition& p)
     103{
     104  return (p.GetPDGCharge() != 0.0 && p.GetPDGMass() > 10.0*MeV);
     105}
     106
     107//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
     108
     109G4double G4MuPairProduction::MinPrimaryEnergy(const G4ParticleDefinition*,
     110                                              const G4Material*,
     111                                              G4double)
     112{
     113  return lowestKinEnergy;
     114}
     115
     116//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
     117
    102118void G4MuPairProduction::InitialiseEnergyLossProcess(
    103119                         const G4ParticleDefinition* part,
  • trunk/source/processes/electromagnetic/muons/src/G4MuPairProductionModel.cc

    r1007 r1055  
    2424// ********************************************************************
    2525//
    26 // $Id: G4MuPairProductionModel.cc,v 1.39 2008/07/22 16:11:34 vnivanch Exp $
    27 // GEANT4 tag $Name: geant4-09-02 $
     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 $
    2828//
    2929// -------------------------------------------------------------------
     
    137137//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
    138138
     139G4double G4MuPairProductionModel::MinEnergyCut(const G4ParticleDefinition*,
     140                                               const G4MaterialCutsCouple* )
     141{
     142  return minPairEnergy;
     143}
     144
     145//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
     146
     147G4double G4MuPairProductionModel::MaxSecondaryEnergy(const G4ParticleDefinition*,
     148                                                     G4double kineticEnergy)
     149{
     150  G4double maxPairEnergy = kineticEnergy + particleMass*(1.0 - 0.75*sqrte*z13);
     151  return maxPairEnergy;
     152}
     153
     154//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
     155
    139156void G4MuPairProductionModel::Initialise(const G4ParticleDefinition* p,
    140157                                         const G4DataVector&)
     
    144161    MakeSamplingTables();
    145162  }
    146   if(!fParticleChange) {
    147     if(pParticleChange)
    148       fParticleChange =
    149         reinterpret_cast<G4ParticleChangeForLoss*>(pParticleChange);
    150     else
    151       fParticleChange = new G4ParticleChangeForLoss();
    152   }
     163  if(!fParticleChange) fParticleChange = GetParticleChangeForLoss();
    153164}
    154165
Note: See TracChangeset for help on using the changeset viewer.