mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-28 14:15:42 -04:00
Fixed issue with 3D lattice distribcell offsets
This commit is contained in:
parent
40038df9e5
commit
c746d7a9fa
2 changed files with 2 additions and 3 deletions
|
|
@ -368,7 +368,6 @@ class Summary(object):
|
|||
lattice.universes = universes
|
||||
|
||||
if offsets is not None:
|
||||
offsets = np.swapaxes(offsets, 0, 2)
|
||||
lattice.offsets = offsets
|
||||
|
||||
# Add the Lattice to the global dictionary of all Lattices
|
||||
|
|
|
|||
|
|
@ -1101,8 +1101,8 @@ class RectLattice(Lattice):
|
|||
|
||||
# For 3D Lattices
|
||||
else:
|
||||
offset = self._offsets[i[1]-1, i[2]-1, i[3]-1, distribcell_index-1]
|
||||
offset += self._universes[i[1]-1][i[2]-1][i[3]-1].get_cell_instance(
|
||||
offset = self._offsets[i[3]-1, i[2]-1, i[1]-1, distribcell_index-1]
|
||||
offset += self._universes[i[3]-1][i[2]-1][i[1]-1].get_cell_instance(
|
||||
path, distribcell_index)
|
||||
|
||||
return offset
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue