Geant4  10.02.p01
G4FissionProductYieldDist.hh
Go to the documentation of this file.
1 //
2 // ********************************************************************
3 // * License and Disclaimer *
4 // * *
5 // * The Geant4 software is copyright of the Copyright Holders of *
6 // * the Geant4 Collaboration. It is provided under the terms and *
7 // * conditions of the Geant4 Software License, included in the file *
8 // * LICENSE and available at http://cern.ch/geant4/license . These *
9 // * include a list of copyright holders. *
10 // * *
11 // * Neither the authors of this software system, nor their employing *
12 // * institutes,nor the agencies providing financial support for this *
13 // * work make any representation or warranty, express or implied, *
14 // * regarding this software system or assume any liability for its *
15 // * use. Please see the license in the file LICENSE and URL above *
16 // * for the full disclaimer and the limitation of liability. *
17 // * *
18 // * This code implementation is the result of the scientific and *
19 // * technical work of the GEANT4 collaboration. *
20 // * By using, copying, modifying or distributing the software (or *
21 // * any work based on the software) you agree to acknowledge its *
22 // * use in resulting scientific publications, and indicate your *
23 // * acceptance of all terms of the Geant4 Software license. *
24 // ********************************************************************
25 //
26 /*
27  * File: G4FissionProductYieldDist.hh
28  * Author: B. Wendt (wendbryc@isu.edu)
29  *
30  * Created on May 11, 2011, 12:04 PM
31  */
32 
33 #ifndef G4FISSIONPRODUCTYIELDDIST_HH
34 #define G4FISSIONPRODUCTYIELDDIST_HH
35 
36 #include "G4Ions.hh"
37 #include "G4Gamma.hh"
38 #include "G4IonTable.hh"
39 #include "G4ParticleHPNames.hh"
40 #include "globals.hh"
41 #include "G4DynamicParticle.hh"
43 #include "G4ReactionProduct.hh"
44 
45 #include "G4ENDFTapeRead.hh"
47 #include "G4FFGEnumerations.hh"
48 #include "G4FPYNubarValues.hh"
49 #include "G4FPYSamplingOps.hh"
50 #include "G4FPYTreeStructures.hh"
51 
55 {
56 public:
57 // Constructor definition
67  G4FissionProductYieldDist( G4int WhichIsotope,
68  G4FFGEnumerations::MetaState WhichMetaState,
70  G4FFGEnumerations::YieldType WhichYieldType,
71  std::istringstream& dataStream);
82  G4FissionProductYieldDist( G4int WhichIsotope,
83  G4FFGEnumerations::MetaState WhichMetaState,
85  G4FFGEnumerations::YieldType WhichYieldType,
87  std::istringstream& dataStream);
88 private:
90  void Initialize( std::istringstream& dataStream );
91 
92 public:
93 // Functions
115  G4Ions* G4GetFissionProduct( void );
127  void G4SetAlphaProduction( G4double WhatAlphaProduction );
135  void G4SetEnergy( G4double WhatIncidentEnergy );
160  void G4SetVerbosity( G4int WhatVerbosity );
161 
162 protected:
163 // Variables
164  // Class descriptor variables
178 
179  // Datafile variables
184 
185  // Fission generation variables
220 
221  // Pointers to the field of trees and relevant normalization data
244 
245  // Pointers to runtime classes that G4FissionProductYieldDist needs to
246  // function properly
258 
259 //Functions
263  void CheckAlphaSanity( void );
267  G4Ions* FindParticle( G4double RandomParticle );
274  G4Ions* FindParticleExtrapolation( G4double RandomParticle,
275  G4bool LowerEnergyGroupExists );
282  G4Ions* FindParticleInterpolation( G4double RandomParticle,
283  G4int LowerEnergyGroup );
290  G4double RandomParticle,
291  G4int EnergyGroup1,
292  G4int EnergyGroup2 );
295  virtual void GenerateAlphas( std::vector< G4ReactionProduct* >* Alphas );
299  virtual void GenerateNeutrons( std::vector< G4ReactionProduct* >* Neutrons );
303  virtual G4Ions* GetFissionProduct( void ) = 0;
317  G4String MakeDirectoryName( void );
331  virtual void MakeTrees( void );
333  virtual void ReadProbabilities( void );
339  void Renormalize( ProbabilityBranch* Branch );
343  void SampleAlphaEnergies( std::vector< G4ReactionProduct* >* Alphas );
345  void SampleGammaEnergies( std::vector< G4ReactionProduct* >* Gammas );
349  void SampleNeutronEnergies( std::vector< G4ReactionProduct* >* Neutrons );
354  void SetNubar( void );
356  virtual void SortProbability( G4ENDFYieldDataContainer* YieldData );
357 
358 // Destructor function(s)
359 public:
363  virtual ~G4FissionProductYieldDist( void );
364 protected:
366  void BurnTree( ProbabilityBranch* Branch );
367 };
368 
369 #endif /* G4FISSIONPRODUCTYIELDDIST_HH */
370 
virtual ~G4FissionProductYieldDist(void)
Default deconstructor.
const G4FFGEnumerations::YieldType YieldType_
The type of yield to be used: INDEPENDET or CUMULATIVE.
MetaState
ENDF format provides for 3 isomers - 1 ground state and 2 meta states.
G4ParticleHPNames * ElementNames_
Pointer to G4NeutronHPNames Provides access to the list of element names included in Geant4...
void CheckAlphaSanity(void)
Checks to make sure that alpha overpopulation will not occur, which could result in an unsolvable zer...
G4Ions * LargestA_
Defines the largest Z particle in the field of trees.
G4FissionProductYieldDist(G4int WhichIsotope, G4FFGEnumerations::MetaState WhichMetaState, G4FFGEnumerations::FissionCause WhichCause, G4FFGEnumerations::YieldType WhichYieldType, std::istringstream &dataStream)
Default constructor.
G4Ions * FindParticle(G4double RandomParticle)
Returns the G4Ions definitions pointer for the particle whose probability segment contains the (0...
G4FPYSamplingOps * RandomEngine_
Pointer to the CLHEP library random engine.
G4double * YieldEnergies_
Energy values of each energy.
void G4SetTernaryProbability(G4double TernaryProbability)
Sets the probability of ternary fission.
G4DynamicParticleVector * G4GetFission(void)
Generates a fission event using default sampling and returns the pointer to that fission event...
G4String MakeDirectoryName(void)
Generates the directory location for the data file referenced by G4FissionProductYieldDist.
G4ENDFTapeRead * ENDFData_
Name of the fission yield product data file that G4FissionProductYieldDist references.
void G4SetAlphaProduction(G4double WhatAlphaProduction)
Set the alpha production behavior for fission event generation.
void Initialize(std::istringstream &dataStream)
Initialize is a common function called by all constructors.
G4String MakeFileName(G4int Isotope, G4FFGEnumerations::MetaState MetaState)
Generates the appropriate file name for the isotope requested.
G4double RemainingEnergy_
Container for the energy remaining to be assigned in the fission generation.
YieldType
The two types of fission data available.
virtual void SortProbability(G4ENDFYieldDataContainer *YieldData)
Sorts information for a potential new particle into the correct tree.
int G4int
Definition: G4Types.hh:78
void G4SetVerbosity(G4int WhatVerbosity)
Sets the verbosity levels.
G4double NubarWidth_
Width of the gaussian distribution that samples nubar for the isotope and incident neutron energy tha...
G4int RemainingA_
Counter for the number of nucleons available to the fission event.
G4Gamma * GammaDefinition_
Contains the g4ParticleDefinition pointer to a gamma particle.
FissionCause
Causes of fission.
G4FissionProductYieldDist is the base class for storing all the fission data and generating fission e...
G4Ions * NeutronDefinition_
Contains the G4ParticleDefinition pointer to a neutron, cast as a G4Ion for compatibility.
Verbosity
These are the verbosity levels.
G4double TernaryProbability_
Sets the ternary fission probability.
virtual void GenerateNeutrons(std::vector< G4ReactionProduct * > *Neutrons)
Generate a linked chain of neutrons and return the pointer to the last neutron in the chain...
virtual void GenerateAlphas(std::vector< G4ReactionProduct * > *Alphas)
Generates a G4DynamicParticleVector with the fission alphas.
G4DynamicParticle * MakeG4DynamicParticle(G4ReactionProduct *)
Creates a G4DynamicParticle from an existing G4ReactionProduct.
void SampleAlphaEnergies(std::vector< G4ReactionProduct * > *Alphas)
Sample the energy of the alpha particles.
virtual void MakeTrees(void)
Dynamically allocates and initializes the 'field' of 'trees' with the 'trunks'.
Definition: G4Ions.hh:51
ProbabilityTree is the 'root' for each tree hierarchy, and contains pointer to the first ProbabilityB...
G4double Nubar_
Nubar for the isotope and incident neutron energy that G4FissionProductYieldDist references.
bool G4bool
Definition: G4Types.hh:79
G4int YieldEnergyGroups_
Number of specific energy groups.
static const G4double TernaryProbability
Default probabilility of a ternary fission.
G4double AlphaProduction_
Controls whether alpha particles are emitted, and how many.
G4double * DataTotal_
A running total of all the probabilities.
G4int BranchCount_
A run-time counter for the total number of branches stored.
ProbabilityTree * Trees_
An array, or 'field', of the probability trees.
G4Ions * SmallestA_
Defines the smallest A particle in the field of trees.
std::vector< G4DynamicParticle * > G4DynamicParticleVector
const G4int Isotope_
Number in ZZZAAA format of the isotope that G4FissionProductYieldDist references. ...
G4Ions * GetParticleDefinition(G4int Product, G4FFGEnumerations::MetaState MetaState)
Returns the G4Ions definition pointer to the isotope defined by Product and MetaState.
G4Ions * FindParticleBranchSearch(ProbabilityBranch *Branch, G4double RandomParticle, G4int EnergyGroup1, G4int EnergyGroup2)
Returns the G4Ions definitions pointer for the particle whose probability segment contains the (0...
void G4SetEnergy(G4double WhatIncidentEnergy)
Sets the energy of the incident particle.
static const G4int Isotope
Default Isotope.
G4ENDFYieldDataContainer is a simple data storage class that handles the memory management internally...
void Renormalize(ProbabilityBranch *Branch)
Renormalizes the data in a ProbabilityTree.
G4Ions * SmallestZ_
Defines the smallest Z particle in the field of trees.
G4ENDFTapeRead is a class designed to read in data from unformatted ENDF data tapes for MT = 454 or M...
void SampleGammaEnergies(std::vector< G4ReactionProduct * > *Gammas)
Samples the energy of the gamma rays.
G4Ions * FindParticleExtrapolation(G4double RandomParticle, G4bool LowerEnergyGroupExists)
Returns the G4Ions definitions pointer for the particle whose probability segment contains the (0...
void SetNubar(void)
Sets the nubar values for the isotope referenced by G4FissionProductYieldDistdefined from the data se...
G4double IncidentEnergy_
Kinetic energy, if any, of the incident particle in GeV.
G4Ions * FindParticleInterpolation(G4double RandomParticle, G4int LowerEnergyGroup)
Returns the G4Ions definitions pointer for the particle whose probability segment contains the (0...
G4double MeanGammaEnergy_
Sets the mean gamma energy, in MeV, produced by the fission of the isotope described by Isotope_...
virtual void ReadProbabilities(void)
Reads in the probability data from the data file.
const G4FFGEnumerations::FissionCause Cause_
The cause of fission: SPONTANEOUS or N_INDUCED.
ProbabilityBranch is a tree hierarchy storage method.
G4FPYSamplingOps performs all the uniform and Gaussian distribution sampling operations.
G4double * MaintainNormalizedData_
Variable for ensuring that the input data is normalized.
void SampleNeutronEnergies(std::vector< G4ReactionProduct * > *Neutrons)
Sample the energy of the neutrons using the Watt fission spectrum.
void BurnTree(ProbabilityBranch *Branch)
Recursively burns each branch in a probability tree.
G4IonTable * IonTable_
Pointer to G4IonTable All G4Ions are created using G4IonTable.
double G4double
Definition: G4Types.hh:76
G4Ions * AlphaDefinition_
Contains the G4Ions pointer to an alpha particle.
G4int TreeCount_
The number of trees in the field.
virtual G4Ions * GetFissionProduct(void)=0
Selects a fission product from the probability tree, limited by the number of nucleons available to t...
G4Ions * G4GetFissionProduct(void)
Selects a fission fragment at random from the probability tree and returns the G4Ions pointer...
G4String MakeIsotopeName(G4int Isotope, G4FFGEnumerations::MetaState MetaState)
Generates the unique name for an isotope/isomer defined by Isotope\ and MetaState in the following fo...
G4Ions * LargestZ_
Defines the largest Z particle in the field of trees.
G4int RemainingZ_
Counter for the number of protons available to the fission event.
const G4FFGEnumerations::MetaState MetaState_
MetaState information of the isotope that G4FissionProductYieldDist references Possible values are ...