Particle underwent maximum number of events - BEAVRS model

Greetings,

I am trying to build the BEAVRS model from the ground up, however OpenMC shows a sequence of warnings that “particle X underwent maximum number of events” when i run the model. I have already checked my materials definitions and the boundary conditions on the outermost surfaces of the model and when i plot the geometry it seems everything is as expected, so i must be missing something. Could anyone check my model for errors?

BEAVRS Full Core.ipynb (36.3 KB)

Thanks in advance,
Artur Souza

I tracked down the problem to the neutron shield geometry definition. Initially, i had defined the neutron shield as follows:

neutron_shield_NE_surface = openmc.model.CylinderSector(194.840, 201.630, 45 - 16, 45 + 16, center = (0.0, 0.0), axis = 'z')
neutron_shield_NW_surface = openmc.model.CylinderSector(194.840, 201.630, 135 - 16, 135 + 16, center = (0.0, 0.0), axis = 'z')
neutron_shield_SW_surface = openmc.model.CylinderSector(194.840, 201.630, 225 - 16, 225 + 16, center = (0.0, 0.0), axis = 'z')
neutron_shield_SE_surface = openmc.model.CylinderSector(194.840, 201.630, 315 - 16, 315 + 16, center = (0.0, 0.0), axis = 'z')

neutron_shield_exterior_region = +neutron_shield_NE_surface & +neutron_shield_NW_surface & +neutron_shield_SW_surface & +neutron_shield_SE_surface

neutron_shield_NE_cell = openmc.Cell(fill = SS304, region = -neutron_shield_NE_surface)
neutron_shield_NW_cell = openmc.Cell(fill = SS304, region = -neutron_shield_NW_surface)
neutron_shield_SW_cell = openmc.Cell(fill = SS304, region = -neutron_shield_SW_surface)
neutron_shield_SE_cell = openmc.Cell(fill = SS304, region = -neutron_shield_SE_surface)

Although the geometry plot was showing everything correct, i was getting a sequence of “particle X underwent maximum number of events” warnings when trying to run the model. So i redefined the neutron shield as follows:

def define_plane(theta):
    
    return openmc.Plane.from_points((0, 0, 0), (0, 0, 1), (1, np.tan(np.radians(theta)), 0))

inner_cylinder = openmc.ZCylinder(x0 = 0.0, y0 = 0.0, r = 194.840)
outer_cylinder = openmc.ZCylinder(x0 = 0.0, y0 = 0.0, r = 201.630)

plane_29_degrees = define_plane(29)
plane_61_degrees = define_plane(61)

plane_119_degrees = define_plane(119)
plane_151_degrees = define_plane(151)

plane_209_degrees = define_plane(209)
plane_241_degrees = define_plane(241)

plane_299_degrees = define_plane(299)
plane_331_degrees = define_plane(331)

neutron_shield_NE_region = +inner_cylinder & -outer_cylinder & +plane_29_degrees & -plane_61_degrees
neutron_shield_NW_region = +inner_cylinder & -outer_cylinder & -plane_119_degrees & +plane_151_degrees
neutron_shield_SW_region = +inner_cylinder & -outer_cylinder & -plane_209_degrees & +plane_241_degrees
neutron_shield_SE_region = +inner_cylinder & -outer_cylinder & +plane_299_degrees & -plane_331_degrees

neutron_shield_exterior_region = ~(neutron_shield_NE_region | neutron_shield_NW_region | neutron_shield_SW_region | neutron_shield_SE_region)

neutron_shield_NE_cell = openmc.Cell(fill = SS304, region = neutron_shield_NE_region)
neutron_shield_NW_cell = openmc.Cell(fill = SS304, region = neutron_shield_NW_region)
neutron_shield_SW_cell = openmc.Cell(fill = SS304, region = neutron_shield_SW_region)
neutron_shield_SE_cell = openmc.Cell(fill = SS304, region = neutron_shield_SE_region)

Then i got no more warnings. I am suspecting there might be an underlying bug in the openmc.model.CylinderSector function @paulromano.