From 3114c935629fd6812bcb04cbd0115a4b776d5f49 Mon Sep 17 00:00:00 2001 From: Patrick Shriwise Date: Thu, 29 Jul 2021 20:01:21 -0500 Subject: [PATCH] Adding an extra layer to the geometry to test the cell instance filter regression test for a universe-filled cell. --- .../filter_cellinstance/inputs_true.dat | 21 ++++++++++--------- .../filter_cellinstance/test.py | 8 +++++-- 2 files changed, 17 insertions(+), 12 deletions(-) diff --git a/tests/regression_tests/filter_cellinstance/inputs_true.dat b/tests/regression_tests/filter_cellinstance/inputs_true.dat index 5abf734333..5df9926270 100644 --- a/tests/regression_tests/filter_cellinstance/inputs_true.dat +++ b/tests/regression_tests/filter_cellinstance/inputs_true.dat @@ -2,18 +2,19 @@ - - - - + + + + + 2 2 4 4 -4 -4 -1 2 2 2 -2 1 2 2 -2 2 1 2 -2 2 2 1 +2 3 3 3 +3 2 3 3 +3 3 2 3 +3 3 3 2 @@ -48,10 +49,10 @@ - 3 0 3 1 3 2 3 3 3 4 3 5 3 6 3 7 3 8 3 9 3 10 3 11 2 0 2 1 2 2 2 3 + 4 0 4 1 4 2 4 3 4 4 4 5 4 6 4 7 4 8 4 9 4 10 4 11 2 0 2 1 2 2 2 3 3 0 3 1 3 2 3 3 - 2 3 2 2 2 1 2 0 3 11 3 10 3 9 3 8 3 7 3 6 3 5 3 4 3 3 3 2 3 1 3 0 + 3 3 3 2 3 1 3 0 2 3 2 2 2 1 2 0 4 11 4 10 4 9 4 8 4 7 4 6 4 5 4 4 4 3 4 2 4 1 4 0 1 diff --git a/tests/regression_tests/filter_cellinstance/test.py b/tests/regression_tests/filter_cellinstance/test.py index dc00394fc2..bd708788c5 100644 --- a/tests/regression_tests/filter_cellinstance/test.py +++ b/tests/regression_tests/filter_cellinstance/test.py @@ -22,7 +22,10 @@ def model(): cyl1 = openmc.ZCylinder(r=0.7) c1 = openmc.Cell(fill=m1, region=-cyl1) c2 = openmc.Cell(fill=m2, region=+cyl1) - u1 = openmc.Universe(cells=[c1, c2]) + # intermediate universe + ui = openmc.Universe(cells=[c2]) + ci = openmc.Cell(fill=ui) + u1 = openmc.Universe(cells=[c1, ci]) cyl2 = openmc.ZCylinder(r=0.5) c3 = openmc.Cell(fill=m1, region=-cyl2) @@ -50,7 +53,8 @@ def model(): model.settings.source = openmc.Source(space=openmc.stats.Point()) instances = ([(c3, i) for i in range(c3.num_instances)] + - [(c2, i) for i in range(c2.num_instances)]) + [(c2, i) for i in range(c2.num_instances)] + + [(ci, i) for i in range(ci.num_instances)]) f1 = openmc.CellInstanceFilter(instances) f2 = openmc.CellInstanceFilter(instances[::-1]) t1 = openmc.Tally()