Skip to content

Commit

Permalink
Allowing jumpRingTo to be equal to 1 (#697)
Browse files Browse the repository at this point in the history
  • Loading branch information
opotowsky committed Jun 6, 2022
1 parent ec3270b commit 2b5bbfa
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion armi/physics/fuelCycle/fuelHandlers.py
Expand Up @@ -990,7 +990,7 @@ def buildRingSchedule(
chargeRing = maxRingInCore
if jumpRingFrom is not None and not (1 < jumpRingFrom < maxRingInCore):
raise ValueError(f"JumpRingFrom {jumpRingFrom} is not in the core.")
if jumpRingTo is not None and not (1 < jumpRingTo < maxRingInCore):
if jumpRingTo is not None and not (1 <= jumpRingTo < maxRingInCore):
raise ValueError(f"JumpRingTo {jumpRingTo} is not in the core.")

if chargeRing > dischargeRing and jumpRingTo is None:
Expand Down
4 changes: 4 additions & 0 deletions armi/physics/fuelCycle/tests/test_fuelHandlers.py
Expand Up @@ -544,6 +544,10 @@ def test_buildRingSchedule(self):
schedule, widths = fh.buildRingSchedule(1, 9)
self.assertEqual(schedule, [9, 8, 7, 6, 5, 4, 3, 2, 1])

# simple with no jumps
schedule, widths = fh.buildRingSchedule(9, 1, jumpRingTo=1)
self.assertEqual(schedule, [1, 2, 3, 4, 5, 6, 7, 8, 9])

# simple with 1 jump
schedule, widths = fh.buildRingSchedule(9, 1, jumpRingFrom=6)
self.assertEqual(schedule, [5, 4, 3, 2, 1, 6, 7, 8, 9])
Expand Down

0 comments on commit 2b5bbfa

Please sign in to comment.