Control Systems
Ziegler–Nichols Tuning
A recipe for tuning a PID controller
Ziegler–Nichols tuning is a recipe for setting the gains of a PID controller from two numbers you measure on the real plant: push the loop until it oscillates with a steady amplitude, read off the ultimate gain and the period of that oscillation, then look the controller settings straight out of a fixed table — no math model required.
- PublishedZiegler & Nichols, Taylor Instrument, 1942
- MeasuresUltimate gain Ku and period Pu
- PID ruleKp = 0.6·Ku, Ti = 0.5·Pu, Td = 0.125·Pu
- Design targetQuarter-amplitude decay (~25–60 % overshoot)
- Damping ratio≈ 0.2 — deliberately under-damped
- Modern descendantRelay auto-tune: Ku ≈ 4d/(π·a)
Interactive visualization
Press play, or step through manually. The visualization is yours to drive — try it before reading on.
Watch the 60-second explainer
A condensed visual walkthrough — narrated, captioned, under a minute.
What Ziegler–Nichols tuning actually is
A PID controller has three knobs: proportional gain Kp, integral time Ti, and derivative time Td. Set them well and a tank holds level, a furnace holds temperature, a motor holds position — quickly, accurately, and without hunting. Set them badly and the loop either crawls toward setpoint over minutes or swings into a growing oscillation that hammers valves and trips alarms. The hard part of control engineering has never been writing the PID equation; it is choosing those three numbers for a process whose dynamics you do not know exactly.
In 1942, two engineers at the Taylor Instrument Companies in Rochester, New York — John G. Ziegler and Nathaniel B. Nichols — published a method that sidesteps the modelling problem entirely. Instead of deriving a transfer function, you let the plant tell you its dynamics by how it misbehaves. Drive the loop with proportional action only and push the gain up until it sits exactly on the edge of stability, oscillating forever at constant amplitude. Two numbers fall out of that experiment — the gain that produced the oscillation and its period — and from those two numbers a one-line table hands you Kp, Ti, and Td. That is the entire idea. Eight decades later it is still the first PID tuning method every process-control course teaches, and the conceptual root of the auto-tune button on virtually every industrial controller.
The closed-loop method — the ultimate cycle
The original and most famous variant is the closed-loop or continuous-cycling method. The procedure is mechanical:
- Put the controller in proportional-only mode — set Ti to infinity (integral off) and Td to zero (derivative off). Many controllers express integral as reset rate; set it to its minimum.
- Starting low, raise Kp in steps. After each step, bump the setpoint slightly and watch the response.
- At low gain the response is sluggish and over-damped. As gain rises, oscillations appear and decay. Keep increasing.
- At one specific gain the oscillation neither grows nor dies — it cycles at constant amplitude indefinitely. That gain is the ultimate gain Ku, and the period of one full cycle is the ultimate period Pu.
What you have found physically is the point where the open-loop gain is exactly 1 and the phase lag is exactly −180°. At that frequency the feedback that should be corrective has rotated into reinforcement, so the loop sustains its own oscillation — the same Barkhausen condition that makes an oscillator circuit ring. Once you have Ku and Pu, you back the gain off and read the controller settings out of the table:
Closed-loop (continuous cycling) table — series/standard form
Kp Ti Td
P 0.50·Ku — —
PI 0.45·Ku Pu / 1.2 —
PID 0.60·Ku 0.5·Pu 0.125·Pu
Parallel-gain equivalents for PID:
Ki = Kp/Ti = 1.2·Ku / Pu
Kd = Kp·Td = 0.075·Ku·Pu
A worked example makes the numbers concrete. Suppose a temperature loop on a small jacketed reactor goes into sustained oscillation when the proportional band is set so that Ku = 4.0 (% output per % error), and you time ten cycles at 80 s total, so Pu = 8.0 s. The classic PID settings are:
Ku = 4.0, Pu = 8.0 s
Kp = 0.60 × 4.0 = 2.4
Ti = 0.50 × 8.0 s = 4.0 s → Ki = Kp/Ti = 0.60 /s
Td = 0.125 × 8.0 s = 1.0 s → Kd = Kp·Td = 2.4 s
Equivalently as a proportional band: PB = 100 / Kp = 41.7 %
Those are the settings the operator dials in. The loop will now respond quickly to a setpoint change, with — by design — a noticeable first overshoot.
Why the answer overshoots: quarter-amplitude decay
Ziegler and Nichols did not aim for a smooth, critically-damped approach. They tuned the constants in the table to produce a specific transient: a quarter-amplitude decay ratio, meaning each overshoot is about one quarter the height of the one before it. The first peak overshoots setpoint, the loop swings back to about a quarter of that overshoot below, then a sixteenth above, and settles after two or three cycles.
Quarter decay corresponds to a closed-loop damping ratio ζ ≈ 0.2 — strongly under-damped. On a setpoint step you typically see 25 percent overshoot at best and 50 to 60 percent on lag-dominant loops. For a 1942 pneumatic flow or pressure loop, where the priority was a fast return to setpoint after a load disturbance and a little overshoot was harmless, that was a sensible trade. For a modern motion-control servo, where a 25 percent position overshoot might slam a mechanism into a hard stop, it is often far too aggressive. This is the single most important caveat about Ziegler–Nichols: the rules are biased toward speed and disturbance rejection, not toward gentle, low-overshoot servo tracking.
Practitioners routinely temper the numbers. Pessen's "some overshoot" and "no overshoot" tables keep Pu-based timing but cut the proportional gain — for example Kp = 0.33·Ku and Td = 0.33·Pu for "no overshoot." A common field shortcut is simply to halve the Ziegler–Nichols Kp and re-evaluate.
The open-loop method — the reaction curve
Taking a live process to the edge of instability is not always acceptable. On a furnace at temperature or a reactor mid-batch, a sustained oscillation can spoil product or trip safety interlocks. For those cases Ziegler and Nichols also published an open-loop or reaction-curve method that never destabilises the plant.
Put the controller in manual, let the process settle, then apply a single step Δu to the actuator and record the output. Self-regulating processes produce a characteristic S-shaped curve. Draw a tangent at its steepest point; where it crosses the initial level gives the apparent dead time L (the transport lag before the output begins to move appreciably), and the slope of that tangent gives the reaction rate R (units of output per unit time, normalised per unit of input step). From those two numbers:
Open-loop (reaction-curve) table
Kp Ti Td
P 1.0 / (R·L) — —
PI 0.9 / (R·L) 3.33·L —
PID 1.2 / (R·L) 2.0·L 0.5·L
R = slope of the steepest tangent (ΔPV/Δt per unit Δu)
L = dead time intercept of that tangent
This is the same family of rules expressed through a first-order-plus-dead-time (FOPDT) fit instead of an oscillation. The key parameter is the ratio of dead time to time constant: the larger the dead time L relative to the dominant lag, the harder the loop is to control and the more conservative the gains must be. Processes with L approaching the time constant are "dead-time dominant" and are exactly where Ziegler–Nichols starts to struggle and model-based methods such as Smith predictors pull ahead.
Ziegler–Nichols versus other tuning methods
Ziegler–Nichols is the canonical starting point, but it is one of several standard recipes. Each makes a different trade between aggressiveness, safety, and how much you need to know about the plant.
| Method | What you measure | Destabilises plant? | Typical overshoot | Best for |
|---|---|---|---|---|
| Ziegler–Nichols (closed-loop) | Ku, Pu from sustained oscillation | Yes — pushed to instability | 25–60 % | Fast disturbance rejection, robust loops |
| Ziegler–Nichols (open-loop) | L, R from step reaction curve | No | 20–50 % | Processes you cannot safely cycle |
| Cohen–Coon | FOPDT fit (K, L, τ) | No | 20–40 % | Dead-time-dominant loops; tighter than open-loop Z–N |
| Lambda / IMC | FOPDT fit + chosen closed-loop time constant λ | No | 0–10 % (tunable) | Smooth setpoint tracking, level loops, robustness |
| Relay auto-tune (Åström) | Ku, Pu from a bounded relay limit cycle | No — bounded cycle | Depends on table used | Automated tuning, the "auto-tune" button |
| Manual / experience | Trial and error | Possibly | Whatever you accept | Loops a technician knows intimately |
The pattern is clear: Ziegler–Nichols buys you a model-free, quick result at the cost of an under-damped response and (in its closed-loop form) a deliberate trip to the edge of stability. Lambda/IMC tuning trades a little modelling effort for a response whose overshoot and speed you can dial directly. Cohen–Coon sits between the two for dead-time-heavy loops. In practice many engineers use Ziegler–Nichols to get a working loop fast, then refine from there.
The relay auto-tune — Ziegler–Nichols made safe
The most important modern descendant of the closed-loop method is the relay feedback auto-tune, introduced by Karl Åström and Tore Hägglund in 1984. The insight is that you do not need to hand-crank the gain toward instability to find Ku and Pu — you can provoke a bounded oscillation deliberately.
Replace the controller temporarily with a relay: whenever the error is positive the output jumps to +d, whenever it is negative it jumps to −d. A relay wrapped around almost any process settles into a stable limit cycle — it cannot run away because the output is clamped at ±d. The period of that limit cycle is essentially the ultimate period Pu, and the amplitude a of the resulting oscillation gives the ultimate gain through the describing-function estimate:
Ku ≈ 4·d / (π·a)
d = relay half-amplitude (the ± output step)
a = measured peak amplitude of the process oscillation
Pu = measured period of the limit cycle
The controller watches one or two clean cycles, computes Ku and Pu, applies a Ziegler–Nichols-style table, and drops back into normal PID operation — all in under a minute and without ever risking a runaway. This is what the "auto-tune" or "self-tune" function does inside a Eurotherm, Honeywell, Allen-Bradley, or Siemens loop controller. The lineage runs straight back to 1942.
Where Ziegler–Nichols fails or misleads
- Integrating processes. Level loops, position loops, and batch-temperature loops with no self-regulation do not settle to a steady oscillation in the same way. The basic tables assume a self-regulating process; applied blindly to an integrator they give wildly wrong gains. Integrating-process variants of the rules exist and must be used instead.
- Lag-dominant loops (small dead time). When the dead time is tiny relative to the time constant, the ultimate gain is enormous and the method tends to be far too aggressive, producing a violently under-damped loop. These loops can usually tolerate much higher integral action than Z–N suggests.
- Noisy measurements. The derivative term amplifies high-frequency noise, and a noisy signal makes a clean ultimate-cycle oscillation hard to identify. On noisy loops, drop the derivative term (use PI), filter the measurement, or prefer a relay test with a hysteresis band.
- Safety and product risk. The closed-loop method intentionally oscillates a live process. On exothermic reactors, high-pressure systems, or anything with a hard mechanical limit, that oscillation can damage equipment or trip interlocks. Use the open-loop reaction curve or a bounded relay test instead.
- Quarter-decay is not always wanted. The default tables target ζ ≈ 0.2. If the loop must track a setpoint smoothly — a coordinate axis on a machine tool, a slow level loop feeding a downstream unit — the Z–N numbers will overshoot unacceptably. Detune the proportional gain or switch to lambda/IMC tuning.
- Non-minimum-phase and inverse-response plants. Boiler-drum level (shrink and swell) and some heat exchangers initially move the wrong way after a step. The reaction-curve tangent is meaningless here and the ultimate-cycle test is treacherous; these need model-based treatment.
Putting it to work in practice
A pragmatic field workflow looks like this. First decide whether you can safely cycle the loop. If yes, and the loop is reasonably fast (seconds to a few minutes per cycle), the relay auto-tune — or a careful manual closed-loop test — gives you Ku and Pu quickly. If the process is too valuable or hazardous to oscillate, do an open-loop step test and read L and R off the reaction curve. Apply the appropriate table, then watch a real setpoint step and a real load disturbance.
If the loop overshoots more than the application tolerates, reduce Kp (a halving is a common first move) or move to the "some overshoot" coefficients. If it is sluggish in rejecting disturbances, shorten the integral time. If it hunts on noise, lengthen the derivative filter or remove derivative action entirely. Ziegler–Nichols gets you into the right neighbourhood in one experiment; the last 20 percent is almost always a few rounds of informed refinement. That, ultimately, is why the method has survived eighty years: not because its numbers are optimal, but because two measurements and a one-line table reliably turn a dead, untuned loop into a working one — a starting point good enough to refine, on a plant you never had to model.
Frequently asked questions
What is Ziegler–Nichols tuning in simple terms?
It is a recipe for choosing the three gains of a PID controller from two numbers you measure on the real plant. In the closed-loop form you switch off integral and derivative action, leaving a pure proportional controller, and raise the proportional gain until the loop oscillates at a constant, steady amplitude. The gain at that knife-edge is the ultimate gain Ku, and one full cycle is the ultimate period Pu. You then read the settings out of a table — for full PID, Kp = 0.6·Ku, Ti = 0.5·Pu, Td = 0.125·Pu. No model of the process is required; the plant tells you its own dynamics by how it oscillates.
What are the Ziegler–Nichols PID tuning rules?
For the closed-loop method, with ultimate gain Ku and ultimate period Pu: P-only, Kp = 0.5·Ku; PI, Kp = 0.45·Ku and Ti = Pu/1.2; classic PID, Kp = 0.6·Ku, Ti = 0.5·Pu, Td = 0.125·Pu. In parallel-gain form the PID values are Ki = 1.2·Ku/Pu and Kd = 0.075·Ku·Pu. The numbers target a quarter-amplitude decay, which is fast but under-damped and leaves roughly 25 percent overshoot on a setpoint step.
What is the difference between the open-loop and closed-loop methods?
The closed-loop (ultimate-cycle) method drives the loop into sustained oscillation to measure Ku and Pu directly — accurate but risky, since you take a live process to the edge of instability. The open-loop (reaction-curve) method opens the loop, applies a step to the actuator, and reads the dead time L and the steepest-tangent slope R off the S-shaped response, then computes Kp = 1.2/(R·L), Ti = 2·L, Td = 0.5·L for PID. The open-loop method never destabilises the plant, so it is preferred on processes you cannot safely cycle.
Why does Ziegler–Nichols give so much overshoot?
The rules were designed for a quarter-amplitude decay ratio — each overshoot about a quarter the height of the previous one. That leaves a closed-loop damping ratio of only about 0.2 and typically 25 to 60 percent overshoot on a setpoint change. It suited 1940s pneumatic flow and pressure loops, where a fast return to setpoint mattered more than a smooth approach. Modern practice often dials the numbers back (Pessen's "some overshoot" and "no overshoot" tables, or simply halving Kp) or switches to lambda/IMC tuning when smooth, low-overshoot tracking is the priority.
When should you not use Ziegler–Nichols tuning?
Avoid the closed-loop method on any process where a sustained oscillation could damage equipment, spoil product, or trip a safety system — large exothermic reactors, high-pressure systems, hard mechanical limits. It also performs poorly on lag-dominant loops (very little dead time), where it is too aggressive, and on integrating processes such as level or position, where the basic table does not apply. Noisy loops are a poor fit too, because derivative action amplifies noise. For these, prefer an open-loop reaction-curve fit, a relay auto-tune, or model-based lambda tuning.
How does the relay auto-tune relate to Ziegler–Nichols?
The relay (Åström–Hägglund) auto-tune is the safe, automated descendant of the closed-loop method. Instead of hand-cranking the gain toward instability, the controller temporarily replaces itself with an on/off relay of amplitude d. A relay around a process produces a bounded limit-cycle oscillation whose period is essentially Pu and whose amplitude a gives Ku ≈ 4d/(π·a). The controller measures one or two cycles, computes Ku and Pu, and applies a Ziegler–Nichols-style table — automatically, without ever risking a runaway. This is the "auto-tune" button on most modern PID controllers.