Hi all,
I’m building a model in OpenMC using CSG. What I’d like to do is:
- Sketch a 2-D cross-section of a nuclear reactor (the lines are all parabolic),
- Revolve that profile 360° about a central axis (say the z-axis),
- End up with the corresponding 3-D volume, within the CSG system.
I haven’t found a “revolve”/“sweep” command in the docs. Before I start piecing the shape together, I wanted to check:
- Does OpenMC-CSG have a built-in way to revolve a surface/curve into a solid?
- If not, what’s the usual workaround - approximating with analytic surfaces, importing a CAD model through DAGMC, or something else?
Thanks in advance! 
Hi Ozzy,
As far as I am aware there is not built in method to revolve a parabolic curve around an axis, but there are methods to approximate it. You have a few options depending on what results you’re looking for, the first option, which is best computationally would be to do only a 2d slice with quadric surfaces as your reactor is symmetrical around the axis. The other method would be to approximate the curve with repeated stacked cylinders. A code that could be used for this is below,
a = 5.0 # controls curvature
y_max = 100.0
n_layers = 100
Reactor_Shell = []
for i in range(n_layers):
z0 = i * y_max / n_layers
z1 = (i + 1) * y_max / n_layers
r0 = np.sqrt(a * z0)
r1 = np.sqrt(a * z1)
cyl_inner = openmc.ZCylinder(r=r0)
cyl_outer = openmc.ZCylinder(r=r1)
surf_bottom = openmc.ZPlane(z0=z0)
surf_top = openmc.ZPlane(z0=z1)
cell = openmc.Cell(region=-cyl_outer & +cyl_inner & +surf_bottom & -surf_top, fill=Reactor_material)
Reactor_shell.append(cell)
r_max = np.sqrt(a * y_max)
This is using the following equation to define the paraboloid
x2+z2=ay
with “a” being a constant. This equation can be adjusted for your specific curvature.
You could also import from a CAD software if you’re more familiar with that, though I don’t have any experience with that process. Let me know if you have any other questions.