Zero zernike flux tallies for multiple fuel rods in one fuel assembly
Recently, I have met with such issue that all zero values were tallied for Zernike expansion of flux and reaction rate for all fuel pins in a fuel assembly.
This kind of issue is caused by incorrect position values to be evaluated in the definition of zernike filter. However, I suggest that OpenMC should get position values for zernike filter from geometry and materials definition instead of manual setting. But I am not sure if it is necessary.
I here come up with an idea to cover above case:
In this way, position values are prepared via Python API. The "x, y, radius" accept a list of values instead of single value, which number of values should agree with the one in material filter.
@paulromano Do you have any idea?
@rockfool Yes, that seems like a reasonable thing to do. A naive implementation will unfortunately require O(n) work where n is the number of (x, y, r) values. However, in principle one could use a spatial data structure to limit the number of bins that would need to be checked.
One other thing to consider with this is the consistency of the API. If we allow ZernikeFilter to take multiple (x,y,r) values, the same idea should be true of other spatial expansion filters. For example, SpatialLegendreFilter should probably allow specifying multiple (axis, min, max) values.