Return BOS concentration as list of vectors from restarts

Operator.initial_condition return list of vectors representing
the initial composition for a burnable material as an element
in the list. This format is expected from depletion solvers as well.
Previously, when pulling from the previous results on an operator,
the initial concentration was returned simply as a 2D array of
compositions. This commit converts the 2D array to a list of
vectors to be consistent across the integration schemes.
This commit is contained in:
Andrew Johnson 2019-07-29 08:36:09 -05:00
parent d28546bcd6
commit 791f7c78b7
No known key found for this signature in database
GPG key ID: 253418E91B7F6FEB

View file

@ -97,7 +97,9 @@ class Integrator(ABC):
def _get_bos_data_from_restart(self, step_index, step_power, bos_conc):
res = self.operator.prev_res[-1]
bos_conc = res.data[0]
# Depletion methods expect list of arrays
# See Operator.__call__, Operator.initial_condition
bos_conc = list(res.data[0])
rates = res.rates[0]
k = ufloat(res.k[0,0], res.k[0, 1])