While utilizing different units has helped, using a relative epsilon has proven vastly superior to using an absolute epsilon. With the two combined, almost no errors are thrown when very similar materials are extracted from one another. This is related to @gonuke's suggestion the last time we talked about this issue in Madison. Thanks @gonuke :) .
updated the extract function to compare relative amounts for the final isotopic amount as it does for the removal amount. I also updated the language of the variables to clarify what's going on. the previous implementation had both removal and remainder variables using rem_. It got really confusing...
adds test that fails for inexact extraction, even within cyclus::eps_rsrc()
added two more tests for inexact sizes and compositions combined
these tests are more informative with a composition that has more than one entry.
clarifying comments
this fixes the extract_complete_inexact_comp test
other inexact tests now pass too. This required checking for the situations in which final_amt was either very small and negative, or zero
more explicit checks are simpler. Checks specifically whether final_amt is zero and uses more accurate variable name rel_err
diff function.
adds initial threshold methods for material and compmap classes.
const correctness and almostEqual functions.
compiles, but fails some extraction tests.
diff tests pass
test tweaks
test tweaks
more extract tests passing again.
diff close comp test added and passes.
passes more tests.
inexact comp and size ok