Ignore:
Timestamp:
Apr 6, 2009, 12:21:12 PM (15 years ago)
Author:
garnier
Message:

update processes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/processes/electromagnetic/standard/include/G4PAIxSection.hh

    r819 r961  
    2525//
    2626//
    27 // $Id: G4PAIxSection.hh,v 1.12 2006/06/29 19:50:44 gunter Exp $
    28 // GEANT4 tag $Name: $
     27// $Id: G4PAIxSection.hh,v 1.15 2008/05/30 16:04:40 grichine Exp $
     28// GEANT4 tag $Name: geant4-09-02-ref-02 $
    2929//
    3030//
     
    7474         
    7575  G4PAIxSection( G4int materialIndex,
    76                          G4double maxEnergyTransfer   ) ;
     76                         G4double maxEnergyTransfer   );
    7777         
    7878  G4PAIxSection( G4int materialIndex,           // for proton loss table
    7979                         G4double maxEnergyTransfer,
    8080                         G4double betaGammaSq ,
    81                          G4double** photoAbsCof, G4int intNumber         ) ;
     81                         G4double** photoAbsCof, G4int intNumber         );
    8282
    8383  G4PAIxSection( G4int materialIndex,           // test constructor
    8484                         G4double maxEnergyTransfer,
    85                          G4double betaGammaSq          ) ;
    86          
    87           // G4PAIxSection(const G4PAIxSection& right) ;
     85                         G4double betaGammaSq          );
     86         
     87          // G4PAIxSection(const G4PAIxSection& right);
    8888         
    8989          // Destructor
    9090         
    91           ~G4PAIxSection() ;
     91          ~G4PAIxSection();
    9292         
    9393          // Operators
    94           // G4PAIxSection& operator=(const G4PAIxSection& right) ;
    95           // G4int operator==(const G4PAIxSection& right)const ;
    96           // G4int operator!=(const G4PAIxSection& right)const ;
     94          // G4PAIxSection& operator=(const G4PAIxSection& right);
     95          // G4int operator==(const G4PAIxSection& right)const;
     96          // G4int operator!=(const G4PAIxSection& right)const;
    9797         
    9898          // Methods
     
    100100          // General control functions
    101101         
    102           void InitPAI() ;
    103 
    104           void NormShift( G4double betaGammaSq ) ;
    105 
    106           void SplainPAI( G4double betaGammaSq ) ;
     102          void InitPAI();
     103
     104          void NormShift( G4double betaGammaSq );
     105
     106          void SplainPAI( G4double betaGammaSq );
    107107                 
    108108          // Physical methods
     
    111111          G4double RutherfordIntegral( G4int intervalNumber,
    112112                                       G4double limitLow,
    113                                        G4double limitHigh     ) ;
     113                                       G4double limitHigh     );
    114114
    115115          G4double ImPartDielectricConst( G4int intervalNumber,
    116                                           G4double energy        ) ;
    117 
    118           G4double RePartDielectricConst(G4double energy) ;
     116                                          G4double energy        );
     117
     118          G4double GetPhotonRange( G4double energy );
     119          G4double GetElectronRange( G4double energy );
     120
     121          G4double RePartDielectricConst(G4double energy);
    119122
    120123          G4double DifPAIxSection( G4int intervalNumber,
    121                                    G4double betaGammaSq    ) ;
     124                                   G4double betaGammaSq    );
    122125
    123126          G4double PAIdNdxCerenkov( G4int intervalNumber,
    124                                    G4double betaGammaSq    ) ;
     127                                   G4double betaGammaSq    );
     128          G4double PAIdNdxMM( G4int intervalNumber,
     129                                   G4double betaGammaSq    );
    125130
    126131          G4double PAIdNdxPlasmon( G4int intervalNumber,
    127                                    G4double betaGammaSq    ) ;
    128 
    129           void     IntegralPAIxSection() ;
    130           void     IntegralCerenkov() ;
    131           void     IntegralPlasmon() ;
    132 
    133           G4double SumOverInterval(G4int intervalNumber) ;
    134           G4double SumOverIntervaldEdx(G4int intervalNumber) ;
    135           G4double SumOverInterCerenkov(G4int intervalNumber) ;
    136           G4double SumOverInterPlasmon(G4int intervalNumber) ;
     132                                   G4double betaGammaSq    );
     133
     134          G4double PAIdNdxResonance( G4int intervalNumber,
     135                                   G4double betaGammaSq    );
     136
     137          void     IntegralPAIxSection();
     138          void     IntegralCerenkov();
     139          void     IntegralMM();
     140          void     IntegralPlasmon();
     141          void     IntegralResonance();
     142
     143          G4double SumOverInterval(G4int intervalNumber);
     144          G4double SumOverIntervaldEdx(G4int intervalNumber);
     145          G4double SumOverInterCerenkov(G4int intervalNumber);
     146          G4double SumOverInterMM(G4int intervalNumber);
     147          G4double SumOverInterPlasmon(G4int intervalNumber);
     148          G4double SumOverInterResonance(G4int intervalNumber);
    137149
    138150          G4double SumOverBorder( G4int intervalNumber,
    139                                   G4double energy          ) ;
     151                                  G4double energy          );
    140152          G4double SumOverBorderdEdx( G4int intervalNumber,
    141                                   G4double energy          ) ;
     153                                  G4double energy          );
    142154          G4double SumOverBordCerenkov( G4int intervalNumber,
    143                                         G4double energy          ) ;
     155                                        G4double energy          );
     156          G4double SumOverBordMM( G4int intervalNumber,
     157                                        G4double energy          );
    144158          G4double SumOverBordPlasmon( G4int intervalNumber,
    145                                        G4double energy          ) ;
    146 
    147           G4double GetStepEnergyLoss( G4double step ) ;
    148           G4double GetStepCerenkovLoss( G4double step ) ;
    149           G4double GetStepPlasmonLoss( G4double step ) ;
     159                                       G4double energy          );
     160          G4double SumOverBordResonance( G4int intervalNumber,
     161                                       G4double energy          );
     162
     163          G4double GetStepEnergyLoss( G4double step );
     164          G4double GetStepCerenkovLoss( G4double step );
     165          G4double GetStepMMLoss( G4double step );
     166          G4double GetStepPlasmonLoss( G4double step );
     167          G4double GetStepResonanceLoss( G4double step );
     168         
     169          G4double GetEnergyTransfer();
     170          G4double GetCerenkovEnergyTransfer();
     171          G4double GetMMEnergyTransfer();
     172          G4double GetPlasmonEnergyTransfer();
     173          G4double GetResonanceEnergyTransfer();
     174          G4double GetRutherfordEnergyTransfer();
    150175         
    151176          // Inline access functions
    152177
    153           G4int GetNumberOfGammas() const { return fNumberOfGammas ; }
    154          
    155           G4int GetSplineSize() const { return fSplineNumber ; }
    156          
    157           G4int GetIntervalNumber() const { return fIntervalNumber ; }
    158 
    159           G4double GetEnergyInterval(G4int i){ return fEnergyInterval[i] ; }
    160 
    161           G4double GetDifPAIxSection(G4int i){ return fDifPAIxSection[i] ; }
    162           G4double GetPAIdNdxCrenkov(G4int i){ return fdNdxCerenkov[i] ; }
    163           G4double GetPAIdNdxPlasmon(G4int i){ return fdNdxPlasmon[i] ; }
    164          
    165           G4double GetMeanEnergyLoss() const {return fIntegralPAIxSection[0] ; }
    166           G4double GetMeanCerenkovLoss() const {return fIntegralCerenkov[0] ; }
    167           G4double GetMeanPlasmonLoss() const {return fIntegralPlasmon[0] ; }
    168 
    169           G4double GetNormalizationCof() const { return fNormalizationCof ; }
     178          G4int GetNumberOfGammas() const { return fNumberOfGammas; }
     179         
     180          G4int GetSplineSize() const { return fSplineNumber; }
     181         
     182          G4int GetIntervalNumber() const { return fIntervalNumber; }
     183
     184          G4double GetEnergyInterval(G4int i){ return fEnergyInterval[i]; }
     185
     186          G4double GetDifPAIxSection(G4int i){ return fDifPAIxSection[i]; }
     187          G4double GetPAIdNdxCerenkov(G4int i){ return fdNdxCerenkov[i]; }
     188          G4double GetPAIdNdxMM(G4int i){ return fdNdxMM[i]; }
     189          G4double GetPAIdNdxPlasmon(G4int i){ return fdNdxPlasmon[i]; }
     190          G4double GetPAIdNdxResonance(G4int i){ return fdNdxResonance[i]; }
     191         
     192          G4double GetMeanEnergyLoss() const {return fIntegralPAIxSection[0]; }
     193          G4double GetMeanCerenkovLoss() const {return fIntegralCerenkov[0]; }
     194          G4double GetMeanMMLoss() const {return fIntegralMM[0]; }
     195          G4double GetMeanPlasmonLoss() const {return fIntegralPlasmon[0]; }
     196          G4double GetMeanResonanceLoss() const {return fIntegralResonance[0]; }
     197
     198          G4double GetNormalizationCof() const { return fNormalizationCof; }
    170199         
    171           inline G4double GetPAItable(G4int i,G4int j) const ;
    172 
    173           inline G4double    GetLorentzFactor(G4int i) const ;
     200          inline G4double GetPAItable(G4int i,G4int j) const;
     201
     202          inline G4double GetLorentzFactor(G4int i) const;
    174203                 
    175           inline G4double GetSplineEnergy(G4int i) const ;
    176          
    177           inline G4double GetIntegralPAIxSection(G4int i) const ;
    178           inline G4double GetIntegralPAIdEdx(G4int i) const ;
    179           inline G4double GetIntegralCerenkov(G4int i) const ;
    180           inline G4double GetIntegralPlasmon(G4int i) const ;
     204          inline G4double GetSplineEnergy(G4int i) const;
     205         
     206          inline G4double GetIntegralPAIxSection(G4int i) const;
     207          inline G4double GetIntegralPAIdEdx(G4int i) const;
     208          inline G4double GetIntegralCerenkov(G4int i) const;
     209          inline G4double GetIntegralMM(G4int i) const;
     210          inline G4double GetIntegralPlasmon(G4int i) const;
     211          inline G4double GetIntegralResonance(G4int i) const;
    181212
    182213protected :
     
    186217// Local class constants
    187218 
    188 static const G4double fDelta ; // energy shift from interval border = 0.001
    189 static const G4double fError ; // error in lin-log approximation = 0.005
    190 
    191 static       G4int fNumberOfGammas ;         // = 111 ;
    192 static const G4double fLorentzFactor[112] ;  //  static gamma array
     219static const G4double fDelta; // energy shift from interval border = 0.001
     220static const G4double fError; // error in lin-log approximation = 0.005
     221
     222static       G4int fNumberOfGammas;         // = 111;
     223static const G4double fLorentzFactor[112];  //  static gamma array
    193224
    194225static
    195 const G4int fRefGammaNumber  ; // The number of gamma for creation of spline (15)
    196 
    197 G4int    fIntervalNumber  ;    //  The number of energy intervals
    198 G4double fNormalizationCof ;   // Normalization cof for PhotoAbsorptionXsection
    199 
    200 // G4double fBetaGammaSq ;        // (beta*gamma)^2
    201 
    202 G4double fDensity ;            // Current density
    203 G4double fElectronDensity ;    // Current electron (number) density
    204 G4int    fSplineNumber ;       // Current size of spline
     226const G4int fRefGammaNumber ; // The number of gamma for creation of spline (15)
     227
     228G4int    fIntervalNumber ;    //  The number of energy intervals
     229G4double fNormalizationCof;   // Normalization cof for PhotoAbsorptionXsection
     230
     231// G4double fBetaGammaSq;        // (beta*gamma)^2
     232
     233  G4int fMaterialIndex;  // current material index
     234  G4double fDensity;            // Current density
     235  G4double fElectronDensity;    // Current electron (number) density
     236  G4int    fSplineNumber;       // Current size of spline
    205237
    206238// Arrays of Sandia coefficients
     
    209241  G4SandiaTable*  fSandia;
    210242
    211 G4double* fEnergyInterval ;
    212 G4double* fA1 ;
    213 G4double* fA2 ;
    214 G4double* fA3 ;
    215 G4double* fA4 ;
     243G4double* fEnergyInterval;
     244G4double* fA1;
     245G4double* fA2;
     246G4double* fA3;
     247G4double* fA4;
    216248
    217249static
    218 const G4int   fMaxSplineSize  ;          // Max size of output splain arrays = 500
     250const G4int   fMaxSplineSize ;          // Max size of output splain arrays = 500
    219251
    220252/* ******************
    221 G4double*          fSplineEnergy ;   // energy points of splain
    222 G4double* fRePartDielectricConst ;   // Real part of dielectric const
    223 G4double* fImPartDielectricConst ;   // Imaginary part of dielectric const
    224 G4double*          fIntegralTerm ;   // Integral term in PAI cross section
    225 G4double*        fDifPAIxSection ;   // Differential PAI cross section
    226 G4double*   fIntegralPAIxSection ;   // Integral PAI cross section  ?
     253G4double*          fSplineEnergy;   // energy points of splain
     254G4double* fRePartDielectricConst;   // Real part of dielectric const
     255G4double* fImPartDielectricConst;   // Imaginary part of dielectric const
     256G4double*          fIntegralTerm;   // Integral term in PAI cross section
     257G4double*        fDifPAIxSection;   // Differential PAI cross section
     258G4double*   fIntegralPAIxSection;   // Integral PAI cross section  ?
    227259*/ ///////////////
    228260
    229261
    230 G4double          fSplineEnergy[500] ;   // energy points of splain
    231 G4double fRePartDielectricConst[500] ;   // Real part of dielectric const
    232 G4double fImPartDielectricConst[500] ;   // Imaginary part of dielectric const
    233 G4double          fIntegralTerm[500] ;   // Integral term in PAI cross section
    234 G4double        fDifPAIxSection[500] ;   // Differential PAI cross section
    235 G4double          fdNdxCerenkov[500] ;   // dNdx of Cerenkov collisions
    236 G4double          fdNdxPlasmon[500] ;   // dNdx of Plasmon collisions
    237 
    238 G4double   fIntegralPAIxSection[500] ;   // Integral PAI cross section  ?
    239 G4double   fIntegralPAIdEdx[500] ;   // Integral PAI dEdx  ?
    240 G4double   fIntegralCerenkov[500] ;   // Integral Cerenkov N>omega  ?
    241 G4double   fIntegralPlasmon[500] ;   // Integral Plasmon N>omega  ?
    242 
    243 G4double fPAItable[500][112] ; // Output array
    244 
    245 } ;   
     262G4double          fSplineEnergy[500];   // energy points of splain
     263G4double fRePartDielectricConst[500];   // Real part of dielectric const
     264G4double fImPartDielectricConst[500];   // Imaginary part of dielectric const
     265G4double          fIntegralTerm[500];   // Integral term in PAI cross section
     266G4double        fDifPAIxSection[500];   // Differential PAI cross section
     267G4double          fdNdxCerenkov[500];   // dNdx of Cerenkov collisions
     268G4double          fdNdxMM[500];   // dNdx of MM-Cerenkov collisions
     269G4double          fdNdxPlasmon[500];   // dNdx of Plasmon collisions
     270G4double          fdNdxResonance[500];   // dNdx of resonance collisions
     271
     272G4double   fIntegralPAIxSection[500];   // Integral PAI cross section  ?
     273G4double   fIntegralPAIdEdx[500];   // Integral PAI dEdx  ?
     274G4double   fIntegralCerenkov[500];   // Integral Cerenkov N>omega  ?
     275G4double   fIntegralMM[500];   // Integral MM-Cerenkov N>omega  ?
     276G4double   fIntegralPlasmon[500];   // Integral Plasmon N>omega  ?
     277G4double   fIntegralResonance[500];   // Integral resonance N>omega  ?
     278
     279G4double fPAItable[500][112]; // Output array
     280
     281};   
    246282
    247283////////////////  Inline methods //////////////////////////////////
     
    251287inline G4double G4PAIxSection::GetPAItable(G4int i, G4int j) const
    252288{
    253    return fPAItable[i][j] ;
     289   return fPAItable[i][j];
    254290}
    255291
    256292inline G4double G4PAIxSection::GetLorentzFactor(G4int j) const
    257293{
    258    return fLorentzFactor[j] ;
     294   return fLorentzFactor[j];
    259295}
    260296
     
    265301      G4Exception("Invalid argument in G4PAIxSection::GetSplineEnergy");
    266302   }
    267    return fSplineEnergy[i] ;
     303   return fSplineEnergy[i];
    268304}
    269305         
     
    274310    G4Exception("Invalid argument in G4PAIxSection::GetIntegralPAIxSection");
    275311   }
    276    return fIntegralPAIxSection[i] ;
     312   return fIntegralPAIxSection[i];
    277313}
    278314
     
    283319    G4Exception("Invalid argument in G4PAIxSection::GetIntegralPAIxSection");
    284320   }
    285    return fIntegralPAIdEdx[i] ;
     321   return fIntegralPAIdEdx[i];
    286322}
    287323
     
    292328    G4Exception("Invalid argument in G4PAIxSection::GetIntegralCerenkov");
    293329   }
    294    return fIntegralCerenkov[i] ;
     330   return fIntegralCerenkov[i];
     331}
     332
     333inline G4double G4PAIxSection::GetIntegralMM(G4int i) const
     334{
     335   if(i < 1 || i > fSplineNumber)
     336   {
     337    G4Exception("Invalid argument in G4PAIxSection::GetIntegralMM");
     338   }
     339   return fIntegralMM[i];
    295340}
    296341
     
    301346    G4Exception("Invalid argument in G4PAIxSection::GetIntegralPlasmon");
    302347   }
    303    return fIntegralPlasmon[i] ;
     348   return fIntegralPlasmon[i];
     349}
     350
     351inline G4double G4PAIxSection::GetIntegralResonance(G4int i) const
     352{
     353   if(i < 1 || i > fSplineNumber)
     354   {
     355    G4Exception("Invalid argument in G4PAIxSection::GetIntegralResonance");
     356   }
     357   return fIntegralResonance[i];
    304358}
    305359
Note: See TracChangeset for help on using the changeset viewer.