cyclus/cyclus — pull request #372 by katyhuff (2012-09-06 14:03:59+00:00)
Title: Mat extract

This should actually address #370 and #367 . It includes tests addressing the concerns of those issues as well as constructor and other tests that became necessary during diagnosis.

It bypasses the IsoVector::separate() and IsoVector::operator-= methods which have no notion of total material amount. Instead, it makes extraction a purely material class concern. The reason for this is that the Material::extract() method and the IsoVector::separate() functions are meant to do different things, fundamentally. In the extraction case, you want mass/atoms to be removed according to some recipe, but in the separation case you want them to be removed according to the efficiency proportion. The latter has no and needs no notion of total mass, while the former relies on it heavily.

Note ! To extract a CompMap from a material, you must provide a non-normalized CompMap (unless the total amount you want to remove is 1).