This is documentation for an old release of SciPy (version 0.12.0). Read this page in the documentation of the latest stable release (version 1.15.1).
Calculate bode magnitude and phase data of a continuous-time system.
New in version 0.11.0.
Parameters : | system : an instance of the LTI class or a tuple describing the system.
w : array_like, optional
n : int, optional
|
---|---|
Returns : | w : 1D ndarray
mag : 1D ndarray
phase : 1D ndarray
|
Examples
>>> from scipy import signal
>>> import matplotlib.pyplot as plt
>>> s1 = signal.lti([1], [1, 1])
>>> w, mag, phase = signal.bode(s1)
>>> plt.figure()
>>> plt.semilogx(w, mag) # bode magnitude plot
>>> plt.figure()
>>> plt.semilogx(w, phase) # bode phase plot
>>> plt.show()