mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-28 22:26:08 -04:00
Enforce lower_left in lattice geometry (#2982)
Co-authored-by: Paul Romano <paul.k.romano@gmail.com>
This commit is contained in:
parent
88f3e4d21f
commit
12a278b1ac
1 changed files with 4 additions and 0 deletions
|
|
@ -884,6 +884,10 @@ class RectLattice(Lattice):
|
|||
dimension = ET.SubElement(lattice_subelement, "dimension")
|
||||
dimension.text = ' '.join(map(str, self.shape))
|
||||
|
||||
# Make sure lower_left has been specified
|
||||
if self.lower_left is None:
|
||||
raise ValueError(f"Lattice {self.id} does not have lower_left specified.")
|
||||
|
||||
# Export Lattice lower left
|
||||
lower_left = ET.SubElement(lattice_subelement, "lower_left")
|
||||
lower_left.text = ' '.join(map(str, self._lower_left))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue