G4IonYangFluctuationModel.cc

Go to the documentation of this file.
00001 //
00002 // ********************************************************************
00003 // * License and Disclaimer                                           *
00004 // *                                                                  *
00005 // * The  Geant4 software  is  copyright of the Copyright Holders  of *
00006 // * the Geant4 Collaboration.  It is provided  under  the terms  and *
00007 // * conditions of the Geant4 Software License,  included in the file *
00008 // * LICENSE and available at  http://cern.ch/geant4/license .  These *
00009 // * include a list of copyright holders.                             *
00010 // *                                                                  *
00011 // * Neither the authors of this software system, nor their employing *
00012 // * institutes,nor the agencies providing financial support for this *
00013 // * work  make  any representation or  warranty, express or implied, *
00014 // * regarding  this  software system or assume any liability for its *
00015 // * use.  Please see the license in the file  LICENSE  and URL above *
00016 // * for the full disclaimer and the limitation of liability.         *
00017 // *                                                                  *
00018 // * This  code  implementation is the result of  the  scientific and *
00019 // * technical work of the GEANT4 collaboration.                      *
00020 // * By using,  copying,  modifying or  distributing the software (or *
00021 // * any work based  on the software)  you  agree  to acknowledge its *
00022 // * use  in  resulting  scientific  publications,  and indicate your *
00023 // * acceptance of all terms of the Geant4 Software license.          *
00024 // ********************************************************************
00025 //
00026 //
00027 // -------------------------------------------------------------------
00028 //
00029 // GEANT4 Class file
00030 //
00031 //
00032 // File name:     G4IonYangFluctuationModel
00033 //
00034 // Author:        V.Ivanchenko (Vladimir.Ivanchenko@cern.ch)
00035 // 
00036 // Creation date: 18 August 2000
00037 //
00038 // Modifications: 
00039 // 18/08/2000  V.Ivanchenko First implementation
00040 // 04/09/2000  V.Ivanchenko Rename fluctuations            
00041 // 03/10/2000  V.Ivanchenko CodeWizard clean up
00042 // 10/05/2001  V.Ivanchenko Clean up againist Linux compilation with -Wall
00043 //
00044 // -------------------------------------------------------------------
00045 // Class Description: 
00046 //
00047 // The aproximation of additional ion energy loss fluctuations 
00048 // Q.Yang et al., NIM B61(1991)149-155.
00049 //
00050 // Class Description: End 
00051 //
00052 // -------------------------------------------------------------------
00053 //
00054 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
00055 
00056 #include "G4IonYangFluctuationModel.hh"
00057 
00058 #include "globals.hh"
00059 #include "G4PhysicalConstants.hh"
00060 #include "G4SystemOfUnits.hh"
00061 #include "G4DynamicParticle.hh"
00062 #include "G4ParticleDefinition.hh"
00063 #include "G4Material.hh"
00064 
00065 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
00066 
00067 G4IonYangFluctuationModel::G4IonYangFluctuationModel(const G4String& name)
00068   : G4VLowEnergyModel(name)
00069 {;}
00070 
00071 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
00072 
00073 G4IonYangFluctuationModel::~G4IonYangFluctuationModel() 
00074 {;}
00075 
00076 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
00077 
00078 G4double G4IonYangFluctuationModel::TheValue(const G4DynamicParticle* particle,
00079                                              const G4Material* material) 
00080 {
00081   G4double energy = particle->GetKineticEnergy() ;
00082   G4double mass = particle->GetMass() ;
00083   G4double charge = (particle->GetCharge())/eplus ;
00084 
00085   G4double q = YangFluctuationModel(material,energy,mass,charge) ;
00086 
00087   return q ;
00088 }
00089 
00090 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
00091 
00092 G4double G4IonYangFluctuationModel::TheValue(const G4ParticleDefinition* aParticle,
00093                                              const G4Material* material,
00094                                              G4double kineticEnergy) 
00095 {
00096   G4double mass = aParticle->GetPDGMass() ;
00097   G4double charge = (aParticle->GetPDGCharge())/eplus ;
00098 
00099   G4double q = YangFluctuationModel(material,kineticEnergy,mass,charge);
00100 
00101   return q ;
00102 }
00103 
00104 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
00105 
00106 G4double G4IonYangFluctuationModel::HighEnergyLimit(const G4ParticleDefinition*,
00107                                                     const G4Material*) const
00108 {
00109   return 1.0*TeV ;
00110 }
00111 
00112 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
00113 
00114 G4double G4IonYangFluctuationModel::LowEnergyLimit(const G4ParticleDefinition* ,
00115                                                    const G4Material* ) const
00116 {
00117   return 0.0 ;
00118 }
00119 
00120 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
00121 
00122 G4double G4IonYangFluctuationModel::HighEnergyLimit(const G4ParticleDefinition* ) const
00123 {
00124   return 1.0*TeV ;
00125 }
00126 
00127 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
00128 
00129 G4double G4IonYangFluctuationModel::LowEnergyLimit(
00130                               const G4ParticleDefinition* ) const
00131 {
00132   return 0.0 ;
00133 }
00134 
00135 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
00136  
00137 G4bool G4IonYangFluctuationModel::IsInCharge(const G4DynamicParticle*,
00138                                              const G4Material* ) const
00139 {
00140   return true ;
00141 }
00142 
00143 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
00144  
00145 G4bool G4IonYangFluctuationModel::IsInCharge(const G4ParticleDefinition* ,
00146                                              const G4Material* ) const
00147 {
00148   return true ;
00149 }
00150 
00151 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
00152 
00153 G4double G4IonYangFluctuationModel::YangFluctuationModel(const G4Material* material,
00154                                                          G4double kineticEnergy,
00155                                                          G4double particleMass,
00156                                                          G4double charge) const
00157 {
00158   // The aproximation of energy loss fluctuations 
00159   // Q.Yang et al., NIM B61(1991)149-155.
00160 
00161   // Reduced energy in MeV/AMU
00162   G4double energy = kineticEnergy *amu_c2/(particleMass*MeV) ;
00163 
00164   G4int i = 0 ;
00165   G4double factor = 1.0 ;
00166 
00167   // The index of set of parameters i = 0 for protons(hadrons) in gases
00168   //                                    1 for protons(hadrons) in solids
00169   //                                    2 for ions in atomic gases
00170   //                                    3 for ions in molecular gases
00171   //                                    4 for ions in solids
00172   static G4double b[5][4] = {
00173   {0.1014,  0.3700,  0.9642,  3.987},
00174   {0.1955,  0.6941,  2.522,   1.040},
00175   {0.05058, 0.08975, 0.1419, 10.80},
00176   {0.05009, 0.08660, 0.2751,  3.787},
00177   {0.01273, 0.03458, 0.3951,  3.812}
00178   } ;
00179 
00180   // protons (hadrons) 
00181   if(1.5 > charge) {
00182     if( kStateGas != material->GetState() ) i = 1 ;
00183 
00184   // ions
00185   } else {
00186     G4double zeff = (material->GetElectronDensity())/
00187                     (material->GetTotNbOfAtomsPerVolume()) ;
00188     factor = charge * std::pow(charge/zeff, 0.3333) ;
00189 
00190     if( kStateGas == material->GetState() ) {
00191       energy /= (charge * std::sqrt(charge)) ;      
00192 
00193       if(1 == (material->GetNumberOfElements())) {
00194         i = 2 ;
00195       } else {
00196         i = 3 ;
00197       }
00198 
00199     } else {
00200       energy /= (charge * std::sqrt(charge*zeff)) ;      
00201       i = 4 ;
00202     }
00203   }
00204 
00205   G4double x = b[i][2] * (1.0 - std::exp( - energy * b[i][3] )) ;
00206 
00207   G4double q = factor * x * b[i][0] / 
00208              ((energy - b[i][1])*(energy - b[i][1]) + x*x) ;
00209 
00210   return q ;    
00211 }
00212 
00213 
00214 
00215 
00216 
00217 

Generated on Mon May 27 17:48:40 2013 for Geant4 by  doxygen 1.4.7