mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-26 05:05:30 -04:00
Ensure boundary_type is used by keyword in several spots
This commit is contained in:
parent
16d7ec0641
commit
ca10c58c8a
3 changed files with 13 additions and 13 deletions
|
|
@ -361,14 +361,14 @@ class RegularMesh(MeshBase):
|
|||
n_dim = len(self.dimension)
|
||||
|
||||
# Build the cell which will contain the lattice
|
||||
xplanes = [openmc.XPlane(self.lower_left[0], bc[0]),
|
||||
openmc.XPlane(self.upper_right[0], bc[1])]
|
||||
xplanes = [openmc.XPlane(self.lower_left[0], boundary_type=bc[0]),
|
||||
openmc.XPlane(self.upper_right[0], boundary_type=bc[1])]
|
||||
if n_dim == 1:
|
||||
yplanes = [openmc.YPlane(-1e10, 'reflective'),
|
||||
openmc.YPlane(1e10, 'reflective')]
|
||||
yplanes = [openmc.YPlane(-1e10, boundary_type='reflective'),
|
||||
openmc.YPlane(1e10, boundary_type='reflective')]
|
||||
else:
|
||||
yplanes = [openmc.YPlane(self.lower_left[1], bc[2]),
|
||||
openmc.YPlane(self.upper_right[1], bc[3])]
|
||||
yplanes = [openmc.YPlane(self.lower_left[1], boundary_type=bc[2]),
|
||||
openmc.YPlane(self.upper_right[1], boundary_type=bc[3])]
|
||||
|
||||
if n_dim <= 2:
|
||||
# Would prefer to have the z ranges be the max supported float, but
|
||||
|
|
@ -378,11 +378,11 @@ class RegularMesh(MeshBase):
|
|||
# inconsistency between what numpy uses as the max float and what
|
||||
# Fortran expects for a real(8), so this avoids code complication
|
||||
# and achieves the same goal.
|
||||
zplanes = [openmc.ZPlane(-1e10, 'reflective'),
|
||||
openmc.ZPlane(1e10, 'reflective')]
|
||||
zplanes = [openmc.ZPlane(-1e10, boundary_type='reflective'),
|
||||
openmc.ZPlane(1e10, boundary_type='reflective')]
|
||||
else:
|
||||
zplanes = [openmc.ZPlane(self.lower_left[2], bc[4]),
|
||||
openmc.ZPlane(self.upper_right[2], bc[5])]
|
||||
zplanes = [openmc.ZPlane(self.lower_left[2], boundary_type=bc[4]),
|
||||
openmc.ZPlane(self.upper_right[2], boundary_type=bc[5])]
|
||||
root_cell = openmc.Cell()
|
||||
root_cell.region = ((+xplanes[0] & -xplanes[1]) &
|
||||
(+yplanes[0] & -yplanes[1]) &
|
||||
|
|
|
|||
|
|
@ -13,9 +13,9 @@ def model():
|
|||
model.materials.append(mat)
|
||||
|
||||
cyl = openmc.XCylinder(r=1.0, boundary_type='vacuum')
|
||||
x_plane_left = openmc.XPlane(-1.0, 'vacuum')
|
||||
x_plane_left = openmc.XPlane(-1.0, boundary_type='vacuum')
|
||||
x_plane_center = openmc.XPlane(1.0)
|
||||
x_plane_right = openmc.XPlane(1.0e9, 'vacuum')
|
||||
x_plane_right = openmc.XPlane(1.0e9, boundary_type='vacuum')
|
||||
|
||||
inner_cyl_left = openmc.Cell()
|
||||
inner_cyl_right = openmc.Cell()
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ class ResonanceScatteringTestHarness(PyAPITestHarness):
|
|||
mats_file.export_to_xml()
|
||||
|
||||
# Geometry
|
||||
dumb_surface = openmc.XPlane(100, 'reflective')
|
||||
dumb_surface = openmc.XPlane(100, boundary_type='reflective')
|
||||
c1 = openmc.Cell(cell_id=1, fill=mat, region=-dumb_surface)
|
||||
root_univ = openmc.Universe(universe_id=0, cells=[c1])
|
||||
geometry = openmc.Geometry(root_univ)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue