Commit graph

16 commits

Author SHA1 Message Date
Perry
1f7ac4215f
Clip negative atom densities that result from CRAM (#3879)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
2026-04-21 20:24:53 +00:00
Jonathan Shimwell
db426b66ca
Materials name persist when running depletion simulation (#3738)
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>
2026-01-27 06:06:36 +00:00
Paul Romano
cf6b67c05d Remove explicit inheritance from object for Python classes 2020-03-23 12:12:31 -05:00
rockfool
78a3e7b937 add explicit settings in dummy_operator for unit_tests 2019-11-19 14:37:47 -05:00
Andrew Johnson
1a4bbb9068
Chain.get_thermal_fission_yields -> Chain.get_default_fission_yields 2019-09-11 10:41:58 -05:00
Andrew Johnson
129ee7e941
Merge branch 'develop' into chain-fission-yields 2019-08-23 11:24:06 -05:00
Andrew Johnson
dbd24035a3
Refactor depletion unit tests with parametrization
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.
2019-08-22 10:05:23 -05:00
Andrew Johnson
6556abc2a8
Add empty fission yields to tests.TestChain
This object is used in unit testing the depletion schemes, where
the depletion matrix is pre-defined and there is no
need for fission yields. However, the depletion interface
expects the chain to have a fission_yields attribute.
2019-08-14 11:18:12 -05:00
Andrew Johnson
72bf884d9b
Pass fission yields to depletion matrix_func
Takes a single set of fission yields and passes them as
an additional argument to matrix_func:

   >>> A = matrix_func(chain, rates, fission_yields)

Applied to cf4, epc_rk4, celi, and leqi functions.
Assumes that fission yields will not change during a
depletion event. This change is probably overshadowed
by how much the reaction rates may change, but still worth
pointing out.
2019-08-07 19:54:49 -05:00
Andrew Johnson
a4905c03af
Add TransportOperator.write_bos_data abstract method
Called with a single integer corresponding to the current
depletion step. This method is intended to document the current
beginning-of-step calculations prior to any depletion at each step
and at the final simulation.
The Operator uses this method to write a statepoint using the
C API.

Also rename the Integrator _get_bos_data_from_openmc to
_get_bos_data_from_operator for generality. It is here that the
write_bos_data method is called.
2019-08-06 17:36:22 -05:00
Andrew Johnson
98957fb473
Store OperatorResults.k as uncertainties.ufloat
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.
2019-07-26 10:31:24 -05:00
guillaume
09a4475e38 fixed bugs when changing integrator at restart time 2018-06-02 16:33:24 -04:00
guillaume
a85db74b2b addressed paulromano's review, added support for restart in cecm integrator 2018-06-02 14:03:11 -04:00
guillaume
d4ff02d2a2 first round of adapting tests 2018-05-30 13:39:04 -04:00
Paul Romano
92697ec06e Introduce ResultsList class to replace scattered functions 2018-02-21 15:36:27 -06:00
Paul Romano
a9df0465f0 Start cleaning up documentation 2018-02-19 22:51:53 -06:00
Renamed from tests/dummy_geometry.py (Browse further)