About openmc.deplete.atom_number.set_atom_density()

Hello, everyone! I have a question about openmc’s burn-up module. I used the official chain_simply.xml burnup chain file and did not pass in the parameters dilute_initial, which defaults to 0, when I instantiated the coupledoperator class as operator. But when I call operator.initial_condition(), I find that the nuclides present in my model, but not in the burnup chain, are assigned a non-zero atomic density. I see in the source code that in the _extract_number method in the openmc_operator.py file, the atomic density in the burnup chain nuclides will only be provided if the dilute_initial parameter is not 0. Did I do something wrong? Or do other modules give nucleon density to nuclides that are present in the burn-up chain but not in my model?

I’m sorry, I didn’t notice that there is a default setting in class TransportOperator.But I meet another question,in the deplete.openmc_operator.OpenMCOperator class,it’s init has a method named _extract_number() which will extract atom density into the self.number.
My problem is,in the method _extract_number(),there is a method named _set_number_from_mat(),and in the _set_number_from_mat() ,there is set_atom_density()method,when I saw the context of the set_atom_density(),I see self[mat, nuc] = val * self.volume[mat] .So I actually see that I set the total number of atoms instead of the atoms density, right? Even though the name of this method is set_atom_density()?

1 Like