control//frequency response

The frequency response says how a system passes a sine wave at each frequency: how much it amplifies or shrinks it (the **gain**) and how late the output wave comes out (the **phase**). Engineers use it to predict whether a loop will oscillate, how much noise it lets through and how fast it can follow, and it can be measured on real hardware by shaking the input at one frequency after another, a sine sweep.


The frequency response says how a system passes a sine wave at each frequency: how much it amplifies or shrinks it (the gain) and how late the output wave comes out (the phase). Engineers use it to predict whether a loop will oscillate, how much noise it lets through and how fast it can follow, and it can be measured on real hardware by shaking the input at one frequency after another, a sine sweep.

For a linear system a sine at the input gives, once the transient has died, a sine of the same frequency at the output, scaled and shifted. A first-order lag of time constant τ\tauτ passes slow sines almost untouched; at its corner frequency ω=1/τ\omega=1/\tauω=1/τ the gain has fallen to about 0.71 and the output lags by 45 degrees; far above it the gain falls in proportion to frequency and the lag approaches 90 degrees. A pure dead time keeps the gain at one and adds a lag that grows without limit as the frequency rises (delay and lag).

Phase lag is what makes feedback dangerous. A loop corrects against the error, which is a shift of 180 degrees by construction; if at some frequency the rest of the loop delays the signal by another 180 degrees, the correction arrives in step with the error and reinforces it, and if the gain round the loop at that frequency is one or more, the oscillation sustains itself or grows. Every lag and every dead time in the loop adds phase, which is why slow sensors and long pipes make loops oscillate.

The bandwidth is the frequency up to which a closed loop follows its setpoint well, conventionally where its gain has dropped by 3 dB. It is the frequency-domain twin of the rise time: twice the bandwidth, roughly half the rise time.

The frequency response is read on the Bode plot, gain and phase against frequency on logarithmic axes, which is also where the stability margins of a loop are measured.

It describes linear behaviour only. A saturated actuator or a sticking valve passes a sine distorted, with a gain that depends on the amplitude, and such loops can settle into a limit cycle that a linear analysis does not predict exactly.