From cd3f86567abef33a1e32af9b4785f8746bbeffd2 Mon Sep 17 00:00:00 2001 From: Connor Moreno Date: Tue, 8 Oct 2024 17:15:48 -0500 Subject: [PATCH] Revert filament toroidal angle checking --- parastell/magnet_coils.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/parastell/magnet_coils.py b/parastell/magnet_coils.py index a9f4182..8a25687 100644 --- a/parastell/magnet_coils.py +++ b/parastell/magnet_coils.py @@ -430,9 +430,12 @@ def in_toroidal_extent(self, lower_bound, upper_bound): max_tor_ang = np.max(toroidal_angles) # Determine if filament toroidal extent overlaps with that of model - in_toroidal_extent = (lower_bound <= min_tor_ang <= upper_bound) or ( - lower_bound <= max_tor_ang <= upper_bound - ) + if (min_tor_ang >= lower_bound or min_tor_ang <= upper_bound) or ( + max_tor_ang >= lower_bound or max_tor_ang <= upper_bound + ): + in_toroidal_extent = True + else: + in_toroidal_extent = False return in_toroidal_extent