ValueError raised for certain systems with nyquist_response
For certain systems, when "indent_direction" is set to 'none', a ValueError is thrown on
python-control/control/freqplot.py
Line 1456 in 71bd731
| count = int(np.round(encirclements, 0)) |
when there is an attempt at casting the number of encirclements to an integer, but the number of encirclements is not a valid number (NaN).
Code to reproduce:
import sympy as smp from control import tf, nyquist_response s = tf('s') tf1 = ((1 + 5/s)/(1 + 0.5/s))**2 # Double-Lag-Compensator nyquist_response(tf1, warn_encirclements=False, indent_direction='none')