G4ContinuumGammaTransition Class Reference

#include <G4ContinuumGammaTransition.hh>

Inheritance diagram for G4ContinuumGammaTransition:

G4VGammaTransition

Public Member Functions

 G4ContinuumGammaTransition (const G4NuclearLevelManager *levelManager, G4int Z, G4int A, G4double excitation, G4int verbose)
virtual ~G4ContinuumGammaTransition ()
virtual void SetEnergyFrom (G4double energy)
virtual G4double GetGammaEnergy ()
virtual G4double GetGammaCreationTime ()
virtual void SelectGamma ()

Detailed Description

Definition at line 59 of file G4ContinuumGammaTransition.hh.


Constructor & Destructor Documentation

G4ContinuumGammaTransition::G4ContinuumGammaTransition ( const G4NuclearLevelManager levelManager,
G4int  Z,
G4int  A,
G4double  excitation,
G4int  verbose 
)

Definition at line 66 of file G4ContinuumGammaTransition.cc.

References G4VGammaTransition::_verbose, G4NuclearLevel::Energy(), G4Pow::GetInstance(), G4NuclearLevelManager::GetLevel(), G4NuclearLevelManager::MaxLevelEnergy(), G4NuclearLevelManager::MinLevelEnergy(), G4NuclearLevelManager::NumberOfLevels(), and G4Pow::powZ().

00070                                           :
00071   _nucleusA(A), _nucleusZ(Z), _excitation(excitation), _levelManager(levelManager) 
00072 {
00073   G4double eTolerance = 0.;
00074   G4int lastButOne = _levelManager->NumberOfLevels() - 2;
00075   if (lastButOne >= 0)
00076     {
00077       eTolerance = (_levelManager->MaxLevelEnergy() -
00078                     _levelManager->GetLevel(lastButOne)->Energy());
00079       if (eTolerance < 0.) eTolerance = 0.;
00080     }
00081   
00082 
00083   _verbose = verbose;
00084   _eGamma = 0.;
00085   _gammaCreationTime = 0.;
00086 
00087   _maxLevelE = _levelManager->MaxLevelEnergy() + eTolerance;
00088   _minLevelE = _levelManager->MinLevelEnergy();
00089 
00090   // Energy range for photon generation; upper limit is defined 5*Gamma(GDR) from GDR peak
00091   _eMin = 0.001 * MeV;
00092   // Giant Dipole Resonance energy
00093   G4double energyGDR = (40.3 / G4Pow::GetInstance()->powZ(_nucleusA,0.2) ) * MeV;
00094   // Giant Dipole Resonance width
00095   G4double widthGDR = 0.30 * energyGDR;
00096   // Extend 
00097   G4double factor = 5;
00098   _eMax = energyGDR + factor * widthGDR;
00099   if (_eMax > excitation) _eMax = _excitation;
00100 
00101 }

G4ContinuumGammaTransition::~G4ContinuumGammaTransition (  )  [virtual]

Definition at line 107 of file G4ContinuumGammaTransition.cc.

00108 {}


Member Function Documentation

G4double G4ContinuumGammaTransition::GetGammaCreationTime (  )  [virtual]

Implements G4VGammaTransition.

Definition at line 167 of file G4ContinuumGammaTransition.cc.

00168 {
00169   return _gammaCreationTime;
00170 }

G4double G4ContinuumGammaTransition::GetGammaEnergy (  )  [virtual]

Implements G4VGammaTransition.

Definition at line 162 of file G4ContinuumGammaTransition.cc.

00163 {
00164   return _eGamma;
00165 }

void G4ContinuumGammaTransition::SelectGamma (  )  [virtual]

Implements G4VGammaTransition.

Definition at line 110 of file G4ContinuumGammaTransition.cc.

References G4VGammaTransition::_verbose, G4NuclearLevel::Energy(), G4cout, G4endl, and G4NuclearLevelManager::NearestLevel().

00111 {
00112 
00113   _eGamma = 0.;
00114 
00115   G4int nBins = 200;
00116   G4double sampleArray[200];
00117   G4int i;
00118   for (i=0; i<nBins; i++)
00119     {
00120       G4double e = _eMin + ( (_eMax - _eMin) / nBins) * i;
00121       sampleArray[i] = E1Pdf(e);
00122 
00123       if(_verbose > 10)
00124         G4cout << "*---* G4ContinuumTransition: e = " << e 
00125                << " pdf = " << sampleArray[i] << G4endl;
00126     }
00127   G4RandGeneralTmp randGeneral(sampleArray, nBins);
00128   G4double random = randGeneral.shoot();
00129   
00130   _eGamma = _eMin + (_eMax - _eMin) * random;
00131   
00132   G4double finalExcitation = _excitation - _eGamma;
00133   
00134   if(_verbose > 10) {
00135     G4cout << "*---*---* G4ContinuumTransition: eGamma = " << _eGamma
00136            << "   finalExcitation = " << finalExcitation 
00137            << " random = " << random << G4endl;
00138   }
00139   //  if (finalExcitation < 0)
00140   if(finalExcitation < _minLevelE/2.)
00141     {
00142       _eGamma = _excitation;
00143       finalExcitation = 0.;
00144     }
00145   
00146   if (finalExcitation < _maxLevelE && finalExcitation > 0.) 
00147     {
00148       G4double levelE = _levelManager->NearestLevel(finalExcitation)->Energy();
00149       G4double diff = finalExcitation - levelE;
00150       _eGamma = _eGamma + diff;
00151     }  
00152 
00153   _gammaCreationTime = GammaTime();
00154 
00155   if(_verbose > 10) {
00156     G4cout << "*---*---* G4ContinuumTransition: _gammaCreationTime = "
00157            << _gammaCreationTime/second << G4endl;
00158   }
00159   return;  
00160 }

void G4ContinuumGammaTransition::SetEnergyFrom ( G4double  energy  )  [virtual]

Implements G4VGammaTransition.

Definition at line 173 of file G4ContinuumGammaTransition.cc.

00174 {
00175   if (energy > 0.) _excitation = energy;
00176 }


The documentation for this class was generated from the following files:
Generated on Mon May 27 17:51:42 2013 for Geant4 by  doxygen 1.4.7