Hello, I’m currently encountering an issue with the hexagonal boundary. As shown in the figure, I used hexagonal_prism
to create a hexagonal prism without setting any boundary conditions for it. However, now my neutrons are unable to escape from the prism; they are all being reflected back. How can I resolve this issue?
Thank you!
Hi Kotori, welcome back to the community
regarding your case, since you said that you didn’t set the boundary condition for hexprism, so as the manual said, the default BC will be transmissive, “pass through the surface freely”.
https://docs.openmc.org/en/stable/usersguide/geometry.html?highlight=boundary%20conditions#boundary-conditions
So if you think the outer surface should not be reflective, then you can set the outer surface BC to vacuum.
Thank you very much for your reply! My outermost geometric surface is indeed a boundary condition for the vacuum, which is why I’m wondering why neutrons can’t escape from the hexagonal prisms
Just to make sure, you can add , boundary_type = 'transmission'
to each surface you want it to be transmission.
Or if you are using the newer version of openmc >0.14, have you tried the HexagonalPrism feature? Since 0.14, the hexagonal_prism
function has been replaced by the openmc.model.HexagonalPrism
class
https://docs.openmc.org/en/stable/releasenotes/0.14.0.html?highlight=hexagonalprism
Also, can you share the minimum input geometry to replicate the problem?
Hi @wahidluthfi @kotori,
This issue could be caused by a number of things, but I think it’s worth verifying that there aren’t any surfaces with reflecting boundary conditions accidentally inserted into the model.
Can you run the following for your model?
import openmc
model = openmc.Model.from_xml() # or from_model_xml as needed
for surface in model.geometry.get_all_surfaces().values():
if surface.boundary_type == 'transmission':
print(surface)
Overlapping regions might also be a possibility. You can attempt to detect these by running with:
$ openmc -g
or in Python
import openmc
openmc.run(geometry_debug=True)
Best of luck!
Patrick