# nyquist

Nyquist plot of frequency response.

## Syntax

* nyquist(sys)
* nyquist(sys, w)
* \[re, im, wout] = nyquist(sys)
* \[re, im, wout] = nyquist(sys, w)

## Input argument

* sys - Dynamic system
* w - Frequencies: vector or {wmin,wmax}

## Output argument

* re - Real part of system response
* im - Imaginary part of system response
* wout - Frequencies

## Description

The Nyquist function, nyquist(sys), generates a graphical representation known as a Nyquist plot, illustrating the frequency response of a dynamic system model represented by sys.

This plot visualizes both the real and imaginary components of the system's response across varying frequencies.

The contour depicted by nyquist encompasses both positive and negative frequencies.

Additionally, the plot incorporates arrows that signify the direction of increasing frequency for each branch.

## Examples

```matlab
f = figure();
sys = tf([1, 1, 3, 3], [1, -3, 3, -1])
nyquist(sys);
```

![](https://160667757-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LdPvJ6mJve3gz5MU4d1%2Fuploads%2Fgit-blob-c9a1a779fc4abb23e183acd5d5fb89a82e8e0c4f%2Fnyquist_1_64B50C31.svg?alt=media)

```matlab
H = tf([2 5 1], [1 2 3]);
[re, im, wout] = nyquist(H);
```

```matlab
f = figure();
      H = tf([2 5 1], [1 2 3]);
nyquist(H);
```

![](https://160667757-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LdPvJ6mJve3gz5MU4d1%2Fuploads%2Fgit-blob-29aa27d7d8ba25be1b70b0c32de655d44d198cae%2Fnyquist_2_39609249.svg?alt=media)

## See also

[bode](bode).

## History

| Version | Description     |
| ------- | --------------- |
| 1.0.0   | initial version |

## Author

Allan CORNET
