mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-27 21:55:41 -04:00
Make mix_materials() inherit "depletable" attribute of involved materials
This commit is contained in:
parent
4fb66912a9
commit
b7a4beff5c
1 changed files with 7 additions and 0 deletions
|
|
@ -1079,6 +1079,13 @@ class Material(IDManagerMixin):
|
|||
new_density = np.sum([dens for dens in mass_per_cc.values()])
|
||||
new_mat.set_density('g/cm3', new_density)
|
||||
|
||||
# If any of the involved materials is depletable, the new material is
|
||||
# depletable
|
||||
for mat in materials:
|
||||
if mat.depletable:
|
||||
new_mat.depletable = True
|
||||
break
|
||||
|
||||
return new_mat
|
||||
|
||||
@classmethod
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue