From ac57f5004d3b559caaef54e9f89b4b9b66ff1b73 Mon Sep 17 00:00:00 2001 From: Adam Nelson Date: Mon, 16 Jan 2017 15:00:42 -0500 Subject: [PATCH] Enabled inverse-velocities to use polar/azimuthal angles consistent with the actual coding --- docs/source/io_formats/mgxs_library.rst | 5 +++-- openmc/mgxs/library.py | 9 +++------ 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/docs/source/io_formats/mgxs_library.rst b/docs/source/io_formats/mgxs_library.rst index 57a3770402..46c6b1839d 100644 --- a/docs/source/io_formats/mgxs_library.rst +++ b/docs/source/io_formats/mgxs_library.rst @@ -122,8 +122,9 @@ Temperature-dependent data, provided for temperature K. spectra as well and thus will have one additional dimension for the outgoing energy group. In this case, `nu-fission` has the same dimensionality as `multiplicity matrix`. - - **inverse-velocity** (*double[]*) -- Average inverse velocity - for each of the groups in the library. This dataset is optional. + - **inverse-velocity** (*double[]* or *double[][][]*) -- + Average inverse velocity for each of the groups in the library. + This dataset is optional. **//K/scatter_data/** diff --git a/openmc/mgxs/library.py b/openmc/mgxs/library.py index 6503735082..d8c83c2331 100644 --- a/openmc/mgxs/library.py +++ b/openmc/mgxs/library.py @@ -502,12 +502,9 @@ class Library(object): mgxs_type, name=self.name, num_polar=self.num_polar, num_azimuthal=self.num_azimuthal) else: - mgxs = openmc.mgxs.MGXS.get_mgxs(mgxs_type, name=self.name) - # The inverse velocity does not use angular-dependent data, - # so do not initialize it with such bins - if mgxs_type != 'inverse-velocity': - mgxs.num_polar = self.num_polar - mgxs.num_azimuthal = self.num_azimuthal + mgxs = openmc.mgxs.MGXS.get_mgxs( + mgxs_type, name=self.name, num_polar=self.num_polar, + num_azimuthal=self.num_azimuthal) mgxs.domain = domain mgxs.domain_type = self.domain_type