summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorConnor Moore <connor.moore@psi.ch>2026-07-22 15:50:21 +0200
committerConnor Moore <connor.moore@psi.ch>2026-07-22 15:50:21 +0200
commit19572e9d39bde7e93ced01e1a979e597c680473b (patch)
tree0d082ba41b672a14e2236cce2036d939fc3b8cab
parent88df2396b808f31d18b1564ada0fe92308bb2c8f (diff)
Updated height to 1.0 cm slice, added dynamic domain decomposition for compact height, fixed TRISO pebbles sticking out during packing
-rwxr-xr-xhpmr.py12
1 files changed, 7 insertions, 5 deletions
diff --git a/hpmr.py b/hpmr.py
index 5604974..ed703f7 100755
--- a/hpmr.py
+++ b/hpmr.py
@@ -30,7 +30,7 @@ cli_parser = argparse.ArgumentParser(
cli_parser.add_argument("-t","--technique",default="none",choices=["none","vwh","rpt","rrpt"],help="What homogenization technique to use (if any) [none/vwh/rpt/rrpt], default none")
cli_parser.add_argument("-r","--radius",default="0.8",type=float,help="Radius for RPT or RRPT homogenization [cm], default 0.8 cm. In the case of RRPT, this is the inner radius.")
cli_parser.add_argument("-l","--lclrs",default=False,action="store_true",help="Flag for specifying LCLRS accessible cross-sections, default false.")
-cli_parser.add_argument("-g","--geometry-level",default="core",choices=["pin","ass","core"],help="Geometry level to run the computation at [pin/ass/core], default pin.")
+cli_parser.add_argument("-g","--geometry-level",default="pin",choices=["pin","ass","core"],help="Geometry level to run the computation at [pin/ass/core], default pin.")
cli_parser.add_argument("-d","--drums-in",default=False,action="store_true",help="Flag for specifying the control drums are rotated in, default false")
cli_parser.add_argument("-e","--execute",default=False,action="store_true",help="Whether or not to automatically run OpenMC, default false.")
cli_args = cli_parser.parse_args()
@@ -445,7 +445,7 @@ geo_const_pin_pitch = 2.3
geo_const_lattice_pitch = 26.752
geo_const_triso_radius = 1.0
geo_const_triso_packing = 0.40
-geo_const_height = 2.0
+geo_const_height = 1.0
geo_const_z_max = openmc.ZPlane(z0=+geo_const_height,boundary_type="transmission" if cli_args.geometry_level=="core" else "reflective")
geo_const_z_min = openmc.ZPlane(z0=-geo_const_height,boundary_type="transmission" if cli_args.geometry_level=="core" else "reflective")
@@ -464,12 +464,14 @@ geo_triso_universe = openmc.Universe(name="TRISO Kernel Universe",cells=geo_tris
## TRISO compact ##
geo_triso_compact_region = -openmc.ZCylinder(r=geo_const_triso_radius,x0=0.0,y0=0.0)&+geo_const_z_min&-geo_const_z_max
-geo_triso_compact_domain = (3,3,6)
+geo_triso_compact_domain = (4,4,int(2*geo_const_height))
# Generate packing
geo_triso_compact_packing = openmc.model.pack_spheres(
- radius=geo_triso_spheres[4].r,
- region=geo_triso_compact_region,
+ radius=geo_triso_spheres[-1].r,
+ region=-openmc.ZCylinder(r=geo_const_triso_radius-geo_triso_spheres[-1].r,x0=0.0,y0=0.0) & \
+ +openmc.ZPlane(z0=-geo_const_height+geo_triso_spheres[-1].r) & \
+ -openmc.ZPlane(z0=+geo_const_height-geo_triso_spheres[-1].r),
pf=geo_const_triso_packing
)