From 4f7617e90cb6a905fdb93566d737d31c52e1853d Mon Sep 17 00:00:00 2001 From: Paul Romano Date: Wed, 14 Oct 2020 15:10:03 -0500 Subject: [PATCH] Fix documentation for source site attributes --- docs/source/io_formats/source.rst | 8 ++++---- docs/source/io_formats/statepoint.rst | 10 +++++----- openmc/statepoint.py | 7 ++++--- 3 files changed, 13 insertions(+), 12 deletions(-) diff --git a/docs/source/io_formats/source.rst b/docs/source/io_formats/source.rst index 6058241e1f..4cd023e12e 100644 --- a/docs/source/io_formats/source.rst +++ b/docs/source/io_formats/source.rst @@ -15,7 +15,7 @@ is that documented here. :Datasets: - **source_bank** (Compound type) -- Source bank information for each - particle. The compound type has fields ``wgt``, ``xyz``, ``uvw``, - ``E``, ``delayed_group``, and ``particle``, which represent the - weight, position, direction, energy, energy group, delayed group, - and type of the source particle, respectively. + particle. The compound type has fields ``r``, ``u``, ``E``, + ``wgt``, ``delayed_group``, and ``particle``, which represent the + position, direction, energy, weight, delayed group, and particle + type (0=neutron, 1=photon, 2=electron, 3=positron), respectively. diff --git a/docs/source/io_formats/statepoint.rst b/docs/source/io_formats/statepoint.rst index f90d5b3af5..3a2ad1600e 100644 --- a/docs/source/io_formats/statepoint.rst +++ b/docs/source/io_formats/statepoint.rst @@ -51,11 +51,11 @@ The current version of the statepoint file format is 17.0. - **global_tallies** (*double[][2]*) -- Accumulated sum and sum-of-squares for each global tally. - **source_bank** (Compound type) -- Source bank information for each - particle. The compound type has fields ``wgt``, ``xyz``, ``uvw``, - ``E``, ``g``, and ``delayed_group``, which represent the weight, - position, direction, energy, energy group, and delayed_group of the - source particle, respectively. Only present when `run_mode` is - 'eigenvalue'. + particle. The compound type has fields ``r``, ``u``, ``E``, + ``wgt``, ``delayed_group``, and ``particle``, which represent the + position, direction, energy, weight, delayed group, and particle + type (0=neutron, 1=photon, 2=electron, 3=positron), respectively. + Only present when `run_mode` is 'eigenvalue'. **/tallies/** diff --git a/openmc/statepoint.py b/openmc/statepoint.py index 294f6c546d..f6177fcc4a 100644 --- a/openmc/statepoint.py +++ b/openmc/statepoint.py @@ -93,9 +93,10 @@ class StatePoint: seed : int Pseudorandom number generator seed source : numpy.ndarray of compound datatype - Array of source sites. The compound datatype has fields 'wgt', 'xyz', - 'uvw', and 'E' corresponding to the weight, position, direction, and - energy of the source site. + Array of source sites. The compound datatype has fields 'r', 'u', + 'E', 'wgt', 'delayed_group', and 'particle', corresponding to the + position, direction, energy, weight, delayed group, and particle type + of the source site, respectively. source_present : bool Indicate whether source sites are present sparse : bool