armi.nucDirectory package
The nucDirectory module contains tools to access nuclide information in the nuclideBases
module, and information for nuclide module.
Element data - name, symbol, atomic number (Z).
Generic nuclide data - this includes mass, atomic number, natural abundance and various names and labels that are used in ARMI for the nuclide. It also includes decay and transmutation modes.
Elements
Elements are simple objects containing minimal information about
atomic elements. This information is loaded from a data file within ARMI; elements.dat.
Elements are mainly used as a building block of the nuclide objects
, as discussed below. If you need to grab an element there are three available dictionaries provided for rapid access.:
>>> r = Reactor("ExampleReactor", bp)
>>> elements = r.nuclideBases.elements
>>> uranium = elements.byZ[92]
>>> uranium.name
'uranium'
>>> uranium.z
92
Likewise, elements can be retrieved by their name or symbol.:
>>> ironFromZ = elements.byZ[26]
>>> ironFromName = elements.byName['iron']
>>> ironFromSymbol = elements.bySymbol['FE']
>>> ironFromZ == ironFromName == ironFromSymbol
True
Note
The byName and
bySymbol are case specific; names are lower case and symbols are
UPPER CASE.
The elements are truly the same Element object. The
nucDirectory makes efficient use of the memory being used by elements and will only ever contain ~118
Elements.:
>>> id(ironFromZ) == id(ironFromName) == id(ironFromSymbol)
True
Nuclide Bases
The nucDirectory allows ARMI to get information about various nuclides, like U235 or FE56. Often times
you need to look up cross section or densities for nuclides, or you might need the atomic weight or the natural isotopic
distribution. The nucDirectory is here to help.
The fundamental object of nuclide management in ARMI is the INuclide object.
After construction, they contain basic information, such as Z, A, and atomic weight (if known). Similar to
Elements, the information is loaded from a series of data files within
ARMI. The data is originally from [NIST]:
>>> r = Reactor("ExampleReactor", bp)
>>> u235= r.nuclideBases.byName['U235']
>>> u235.z
92
>>> u235.weight
235.0439299
>>> u235.a
235
Upon creating a Reactor, a fully fledged NuclideBases object will be created. In that object there will be a full
Upon loading the armi.nucDirectory package, inside that will be a fully instantiated Elements object and a
list called.:py:data:nuclideBases.instances <armi.nucDirectory.nuclideBases.instances>. The instances will
be filled with nuclide base objects. Nuclide bases contain a lot of basic information about a nuclide, such as the
atomic mass, atomic number (Z), the mass number (A), and the natural abundance.
Nuclide names, labels, and IDs
Nuclides have names, labels and IDs.
INuclide.nameThe nuclide name is what should be used within ARMI and ARMI-based appliations. This is a human readable name such as,
U235orFE. The names contain only capital letters and numbers, made up from the corresponding element symbol and mass number (A).INuclide.labelThe nuclide label is a unique 4 character name which identifies the nuclide from all others. The label is fixed to 4 characters to conform with the CCCC standard files, which traditionally only allow for a maximum of 6 character labels in legacy nuclear codes. Of the 6 allowable characters, 4 are reserved for the unique identifier of the nuclide and 2 characters are reserved for cross section labels (i.e., AA, AB, ZA, etc.). The cross section labels are based on the cross section group manager implementation within the framework. These labels are not necessarily human readable/interpretable, but are generally the nuclide symbol followed by the last two digits of the mass number (A), so the nuclide for U235 has the label
U235, but PU239 has the labelPU39.
For reference, the data used to build the nuclide bases in ARMI comes from a file called nuclides.dat.
Indices - rapid access
There are three main ways to retrieve a nuclide, which are provided depending on what information you have about a
nuclide. For example, if you know a nuclide name, use NuclideBases.byName dictionary. There are also dictionaries
available for retrieving by the label, NuclideBases.byLabel, and by other software-specific IDs (i.e., MCNP,
MC2-2, and MC2-3). The software-specific labels are incorporated into the framework to support plugin developments and
may be extended as needed by end-users as needs arise.
>>> r = Reactor("testReactor", bp)
>>> pu239 = r.nuclideBases.byName["PU239"]
>>> pu239.z
94
Just like with elements, the item retrieved from the various dictionaries are the same object.
>>> tinFromName = r.nuclideBases.byName["SN112"]
>>> tinFromLabel = r.nuclideBases.byLabel["SN112"]
>>> tinFromMcc2Id = r.nuclideBases.byName["SN1125"]
>>> tinFromMcc3Id = r.nuclideBases.byLabel["SN1127"]
>>> tinFromName == tinFromLabel == tinFromMcc2Id == tinFromMcc3Id
True
>>> id(tinFromName) == id(tinFromLabel) == id(tinFromMcc2Id) == id(tinFromMcc3Id)
True
Subpackages
Submodules
- armi.nucDirectory.elements module
- armi.nucDirectory.nucDir module
- armi.nucDirectory.nuclideBases module
NuclideInterfaceNuclideInterface.getDatabaseName()NuclideInterface.getDecay()NuclideInterface.getMcc2Id()NuclideInterface.getMcc3Id()NuclideInterface.getMcc3IdEndfbVII0()NuclideInterface.getMcc3IdEndfbVII1()NuclideInterface.getSerpentId()NuclideInterface.getNaturalIsotopics()NuclideInterface.isFissile()NuclideInterface.isHeavyMetal()
NuclideWrapperNuclideWrapper.nameNuclideWrapper.weightNuclideWrapper.getDatabaseName()NuclideWrapper.getDecay()NuclideWrapper.getMcc2Id()NuclideWrapper.getMcc3Id()NuclideWrapper.getMcc3IdEndfbVII0()NuclideWrapper.getMcc3IdEndfbVII1()NuclideWrapper.getNaturalIsotopics()NuclideWrapper.isFissile()NuclideWrapper.isHeavyMetal()
INuclideIMcnpNuclideNuclideBaseNaturalNuclideBaseDummyNuclideBaseLumpNuclideBaseinitReachableActiveNuclidesThroughBurnChain()getIsotopics()fromName()isMonoIsotopicElement()where()single()changeLabel()getDepletableNuclides()imposeBurnChain()factory()addNuclideBases()readMCCNuclideData()updateNuclideBasesForSpecialCases()addGlobalNuclide()destroyGlobalNuclides()NuclideBasesNuclideBases.DEFAULT_NUCLIDES_FILENuclideBases.DEFAULT_MCC_NUCLIDES_FILENuclideBases.clear()NuclideBases.addNuclide()NuclideBases.factory()NuclideBases.initReachableActiveNuclidesThroughBurnChain()NuclideBases.getIsotopics()NuclideBases.fromName()NuclideBases.isMonoIsotopicElement()NuclideBases.where()NuclideBases.single()NuclideBases.changeLabel()NuclideBases.imposeBurnChain()NuclideBases.addNuclideBases()NuclideBases.readMCCNuclideData()NuclideBases.updateNuclideBasesForSpecialCases()
- armi.nucDirectory.thermalScattering module
- armi.nucDirectory.transmutations module