Co-authored-by: GuySten <guyste@post.bgu.ac.il>
Co-authored-by: GuySten <62616591+GuySten@users.noreply.github.com>
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
Removed unit test files for test_deplete_*py that pertained to a
single integrator type only. Similarly removed tests where the
integrators are used to perform simple restart analysis.
These tests are still present, but done with two parametrized tests.
Each of the integrators has the exact same solution in the unit tests
with and without restarting,by nature of their design.
This and the near-fixture like way the tests
are structured allowed these tests to be easily parametrized provided
1) integrator, 2) reference solutions for atoms 1 and 2.
Exact results for each integrator in the unit test are contained
inside a collections.namedtuple, along with the Integrator class.
These named tuples are placed in a dictionary in
tests/dummy_operator.py that can be easily iterated over to provide
access to a name of the scheme, e.g. "predictor", and the tuple of
integrator, results for atom 1, and results for atom 2.
Exact results for atoms 1 and 2 should be provided using the depletion
matrix produced by the tests.dummy_operator.DummyOperator for two
time steps of 0.75 seconds.
The new class method ResultsList.from_hdf5 should be
used to load in results data, rather than passing
the file name into the __init__ method. __init__
passes directly to list.__init__ now.
The motivation for this is to resolve the depletion
restart with MPI bug #1275. To do this, each Operator
will create it's own ResultsList and distribute reaction
rates and densities according to what materials are burned
on this process. Rather than use a normal list, this Operator
expects the various accessor methods like get_atoms to be
present on self.prev_res
- SI_Integrator must be passed positive integer.
- Number of powers computed must be equal to the
number of time steps
Added unit test to ensure that the right errors are raised.
This allows the propagation of the uncertainty through
the SIE iterations, and alows the expressions for updating
k to be preserved. The OperatorResult.k was previous stored
as a tuple of two floats. The interface into the depletion_results
file is not changed, as the Results.save method, which writes the
OperatorResult data, breaks the ufloat into k and uncertainties.
Documentation has been updated on the OperatorResult.
Update results list unit test to ensure that the
correct uncertainties are pulled from the depletion_results file
Update basic integrator unit test to test writing and retrieving
eigenvalues and associated uncertainties
Now the ReactionRates controls all the indexing needed to build a depletion
matrix. Got all tests fixed here too. Decided to add get/set methods on
ReactionRates which take strings.