summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorConnor Hugh Moore <moore_c@pc17430.psi.ch>2026-07-17 08:59:18 +0200
committerConnor Hugh Moore <moore_c@pc17430.psi.ch>2026-07-17 08:59:18 +0200
commit24035d4b712c7b443a9b09437623abb70d3744c3 (patch)
treef151371673bf0e32c45a9761d3303934b4139346
parent43af3a674f2171c4ba22534b366277e18baad67b (diff)
Fixed bug in TRISO lattice definition
-rwxr-xr-xhpmr.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/hpmr.py b/hpmr.py
index f8d288c..25a48f9 100755
--- a/hpmr.py
+++ b/hpmr.py
@@ -464,7 +464,7 @@ 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 = (10,10,10)
+geo_triso_compact_domain = (3,3,6)
# Generate packing
geo_triso_compact_packing = openmc.model.pack_spheres(
@@ -480,7 +480,7 @@ geo_triso_compact_trisos = [openmc.model.TRISO(geo_triso_spheres[4].r, geo_triso
geo_triso_compact_lattice = openmc.model.create_triso_lattice(
trisos=geo_triso_compact_trisos,
lower_left=(-geo_const_triso_radius,-geo_const_triso_radius,-geo_const_height),
- pitch=(geo_const_triso_radius*2,geo_const_triso_radius*2,geo_const_height*2),
+ pitch=tuple((2*p/d for p,d in zip((geo_const_triso_radius,geo_const_triso_radius,geo_const_height),geo_triso_compact_domain))),
shape=geo_triso_compact_domain,
background=mat_graphite_matrix
)
@@ -733,7 +733,7 @@ settings.batches = 200
settings.inactive = 50
#settings.verbosity = 10
-set_dyn_radial = geo_const_core_cyl.r if cli_args.geometry_level=="core"else geo_const_pin_pitch if cli_args.geometry_level=="pin" else geo_const_lattice_pitch/3**0.5
+set_dyn_radial = geo_const_core_cyl.r if cli_args.geometry_level=="core" else geo_const_pin_pitch/3**0.5 if cli_args.geometry_level=="pin" else geo_const_lattice_pitch/3**0.5
set_dyn_axial = 180 if cli_args.geometry_level=="core" else geo_const_height
set_source_pts = openmc.IndependentSource(