Skip to content

Instrumentation and measurement

PID Control: How the Loop Works and How to Tune It

PID control loop tuning explained: what P, I and D do, how to prepare the loop, which field methods work and how to tell a badly tuned loop from a faulty one.

Direct answer

A PID controller computes its output from the error between setpoint and process variable using three actions: proportional reacts to the present error, integral removes steady offset, and derivative reacts to the rate of change. Tuning means adjusting those three parameters until the loop responds quickly and stays stable.

Institutional content: Authomathika

Published:

Most closed loops in a plant run on a PID algorithm inside a PLC, a DCS or a standalone controller. The algorithm is simple, but a loop only performs well when the instrument, the final element and the parameters work together. This guide covers the algorithm and the field tuning routine, not the loop architectures themselves.

What do the proportional, integral and derivative actions do?

PID is a control algorithm that calculates the controller output from the error, which is the difference between setpoint and process variable. Each of the three actions covers a different part of that error.

ActionWhat it responds toMain effectRisk when overdone
Proportional (P)Present size of the errorFast response, output moves in proportion to the errorSustained oscillation, leftover offset when used alone
Integral (I)Accumulated error over timeEliminates steady offsetOvershoot, slow oscillation, windup
Derivative (D)Rate of change of the errorDamps the response, anticipates trendsAmplifies measurement noise, jittery output

Proportional action is set as gain or as proportional band, which is the inverse of gain. Integral action is set as integral time or as repeats per minute, and derivative action as derivative time. Different controllers use different forms and units, so always confirm which one your controller uses before copying values from another loop.

Many loops, such as flow and pressure, work well as PI only. Derivative action is most useful on slow processes with significant lag, like temperature, and only when the signal is clean.

How does the PID enter the closed loop?

The PID is the controller block in a closed loop: it reads the measurement from a transmitter, compares it with the setpoint and sends an output to a final element such as a control valve or a drive. The process then reacts, and the transmitter reads the new value.

The parameters you choose only make sense in the context of the whole chain. The transmitter range and damping, the valve characteristic and stroke time, and the process dead time and lag all shape the response. If you need a refresher on the structures around the controller, see open loop vs closed loop control and control loops: open, closed, cascade and split range. For the final element, see control valves: what they are, how they work and types.

Two process properties matter most for tuning:

  • Process gain: how much the process variable moves for a given change in output.
  • Dead time and time constant: how long the process takes to start reacting and how slowly it settles. Loops with long dead time need gentler tuning.

How do you prepare the loop before tuning?

Prepare the loop by confirming that every device in it works correctly, because no parameter set can compensate for a sticking valve or a wrong scaling. Tuning a loop with a hardware fault only hides the problem.

  1. Confirm the loop passed its loop check: wiring, signal range, scaling and alarms. The instrumentation loop check and commissioning checklist covers this step.
  2. Check the control action: direct or reverse, and the valve failure position.
  3. Verify the final element for stiction, backlash and travel limits with small steps in manual mode.
  4. Review transmitter range and filtering so noise does not reach the derivative term.
  5. Define the operating point and the acceptable limits for the process variable during tests.
  6. Record the existing parameters and the controller form before changing anything.
  7. Get approval from operations, since tests disturb the process.

Which tuning methods are used in the field?

The common field methods are the step response test, the closed loop oscillation test and trial and error, and the choice depends on how much disturbance the process can accept.

MethodHow it worksBest forCaution
Open loop step testPut the loop in manual, apply a small output step, record the response and derive gain, dead time and time constantSlow, stable processesNeeds a steady process during the test
Closed loop oscillation test (Ziegler-Nichols type)Raise gain with P only until sustained oscillation, then derive parameters from that gain and periodFast, tolerant processesPushes the loop to the edge of stability, often too aggressive
Trial and errorAdjust one parameter at a time and watch the responseSmall corrections to an existing loopSlow and depends on operator experience
Software or autotuneController or tool runs a test and proposes valuesMany loops, repeatable routinesCheck the result and the test conditions

Whatever the method, the starting values are only a first estimate. Refine them with setpoint changes and disturbance checks, and decide what you want: a fast response that accepts some overshoot, or a smooth response with no overshoot. Level loops in buffer tanks, for example, often favor smooth output over tight control.

For application specifics, see temperature and pressure control loops.

What symptoms show a loop is badly tuned?

A badly tuned loop shows oscillation, sluggish response, large overshoot or a noisy output. Before changing parameters, check whether the symptom comes from tuning or from hardware.

SymptomProbable causeWhat to check
Steady oscillation around setpointGain too high or integral too fastReduce gain, lengthen integral time
Slow return to setpointGain too low or integral too slowIncrease gain moderately
Large overshoot after a setpoint changeExcess integral action or windupIntegral time, anti-windup, setpoint ramp
Jittery outputDerivative with a noisy signalFilter, reduce or disable derivative
Slow limit cycle with small amplitudeValve stiction or backlashValve test in manual
Output saturated at 0 or 100 percentUndersized final element or wrong operating pointValve sizing, process conditions

A limit cycle that persists even after retuning almost always points to the final element, not to the PID.

How do you record the final tuning in the documentation?

Record the final tuning in the loop's controller data sheet or the plant's loop documentation, so the next technician can restore or audit it. Without a record, parameters are lost after a controller replacement or a program download.

Include at least:

  • Loop tag, controller form and units used.
  • Final gain or band, integral time and derivative time.
  • Control action, output limits, setpoint limits and filters.
  • Operating conditions during the test and the method used.
  • Date, who tuned it and who approved it.
  • Performance observed: response to a setpoint change and to a disturbance.

At Authomathika, tuning and loop documentation are part of the automation work, delivered together with commissioning according to each project's scope. Scope and budget are assessed case by case. If you want to discuss a plant, use the request a quote page.

Frequently asked questions

Do I always need all three actions, P, I and D?
No. Many flow, pressure and level loops work well as PI, and derivative action is used mainly on slow processes with clean signals, such as temperature.
What is integral windup?
Integral windup is the buildup of the integral term while the output is saturated, which causes large overshoot when the loop recovers. Anti-windup features in the controller limit it.
Can I tune a loop with a sticking valve?
Not reliably. Stiction and backlash cause limit cycles that no parameter set removes, so repair or calibrate the valve first and tune afterwards.
Is autotune enough?
Autotune gives a good starting point, but you should confirm the test conditions and verify the response to setpoint changes and disturbances before accepting the result.
Why does the same tuning not work on two similar loops?
Small differences in valve size, piping, transmitter location and process conditions change gain and dead time, so each loop needs its own check, even when the equipment looks identical.
PID Control: How the Loop Works and How to Tune It | Authomathika