Error in Destination Material

Hello,

I encountered a problem when attempting to use transfer rate feature in OpenMC. I wanted to removed some fission products from one material (“fuel”) and store it in another material (“fp_tank”) for tracking. So I wrote the material inputs more or less like this,

fuel = openmc.Material(name="fuel") 
fuel.add_nuclide('U235', 1.58775E-03)
fuel.add_nuclide('U238', 6.45147E-03)
fuel.add_nuclide('Th232', 4.09804E-02)
fuel.add_nuclide('F19', 6.07843E-01)
fuel.add_nuclide('Be9', 6.86275E-02)
fuel.add_nuclide('Li6', 1.37255E-05)
fuel.add_nuclide('Li7', 2.74496E-01)
fuel.set_density('g/cm3',3.3)
fuel.volume = 24594900.57
fuel.temperature = 900
fp_tank = openmc.Material(name="tank")
fp_tank.add_element('He', 1)
fp_tank.set_density('sum')
fp_tank.temperature = 327

Then I determined the power, removed nuclide, etc.

removed_nuclide = ['H','He','N','O','Ne', 'Ar','Kr','Nb','Mo','Tc','Ru','Rh','Pd', 'Ag','Sb','Te','Xe','Lu','Hf','Ta','W','Re','Os','Ir','Pt','Au','Rn']
dest_mat = 'fp_tank'

integrator = openmc.deplete.PredictorIntegrator(operator, time_steps, power, timestep_units='d')
integrator.add_transfer_rate(fuel,removed_nuclide, 3.333e-2, '1/s', destination_material=dest_mat)

However, this didn’t work as it shows error message, "ValueError: Unable to set “Material name” to “fp_tank” since it is not in “[‘fuel’]” "

Is it because I place the fp_tank on the outside of the reactor core boundary or something else?

Thanks.

Hi Dwijayanto, welcome to the community.
I think you want to declare destination material into the fp_tank material named ‘tank’, so it should look like dest_mat = fp_tank # or their name 'tank' instead of dest_mat = ‘fp_tank’

Also, have you set that material into depleteable and set its corresponding cell volume? I think this material should exist on the openmc geometry model since openmc.deplete remake of the xml file used for depletion calculation.

But I think the experts will comment if this error came from the same problem encountered in this discussion

Thanks, I think that resolves it.

1 Like