### IAM Search

## Tuning Techniques Compared

This is not necessarily an indictment of Ziegler’s and Nichols’ recommendations as much as it is a demonstration of the power of understanding. Ziegler and Nichols presented a simple step-by-step procedure for obtaining approximate PID tuning constant values based on closed-loop and open-loop process responses, which could be applied by anyone regardless of their level of understanding PID control theory. If I were tasked with drafting a procedure to instruct anyone to quantitatively determine PID constant values without an understanding of process dynamics or process control theory, I doubt my effort would be an improvement. Ultimately, robust PID control is attainable only at the hands of someone who understands how PID works, what each mode does (and why), and is able to distinguish between intrinsic process characteristics and instrument limitations. The purpose of this section is to clearly demonstrate the limitations of ignorantly-followed procedures, and contrast this “mindless” approach against the results of simple experimentation directed by qualitative understanding.

Each of the examples illustrated in this section were simulations run on a computer program called PC-ControLab developed by Wade Associates, Inc. Although these are simulated processes, in general I have found similar results using both Ziegler-Nichols and heuristic tuning methods on real processes. The control criteria I used for heuristic tuning were fast response to setpoint changes, with minimal overshoot or oscillation.

The first process tuned in simulation was a “generic” process, unspecific in its nature or application. Performing an open-loop test (two 10% output step-changes made in manual mode, both increasing) on this process resulted in the following behavior:

From the trend, we can see that this process is self-regulating, with multiple lags and some dead time. The reaction rate (R) is 20% over 15 minutes, or 1.333 percent per minute. Dead time (L) appears to be approximately 2 minutes. Following the Ziegler-Nichols recommendations for PID tuning based on these process characteristics (also including the 10% step-change magnitude ∆m):

Applying the PID values of 4.5 (gain), 4 minutes per repeat (integral), and 1 minute (derivative) gave the following result in automatic mode:

The process oscillations follow a 10% setpoint change (from 60% to 50%), and take almost an hour to settle. Clearly, this is less-than-robust behavior. The controller is much too aggressive, which is why the process oscillates so much following the setpoint step-change.

Looking closely at the PV and OUT waveforms, we see their phase relationship is nearly 180^{o}, consistent with what we would expect for a reverse-acting controller with strong proportional action. If integral or derivative action were primarily responsible for the oscillation, we would see the influence of an additional 90^{o} phase shift characteristic to those actions (integral naturally produces a -90^{o} phase shift, while derivative naturally produces a +90^{o} phase shift, for any sinusoidal function). Thus, if the oscillations were primarily the result of excessive integral action, we would expect the OUT wave to lead the PV wave by nearly 90^{o} (180^{o} from reverse action − 90^{o} from integral action = 90^{o}). If excessive derivative action were primarily responsible for the oscillations, we would expect the OUT wave to lag the PV wave by nearly 90^{o} (180^{o} from reverse action + 90^{o} from derivative action = 270^{o} = −90^{o}). Since we see a phase shift of the oscillations between OUT and PV very close to the 180^{o} predicted by proportional action, we can be sure this controller’s response is dominated by proportional action, which would be a good place to start “taming” this over-exuberant controller if we were inclined to modify the Ziegler-Nichols tuning recommendations.

Next, the closed-loop, or “Ultimate” tuning method of Ziegler and Nichols was applied to this process. Eliminating both integral and derivative control actions from the controller, and experimenting with different gain (proportional) values until self-sustaining oscillations of consistent amplitude^{1} were obtained, gave a gain value of 11:

From the trend, we can see that the ultimate period (Pu) is approximately 7 minutes in length. Following the Ziegler-Nichols recommendations for PID tuning based on these process characteristics:

It should be immediately apparent that these tuning parameters will yield poor control. While the integral and derivative values are close to those predicted by the open-loop (Reaction Rate) method, the gain value calculated here is even larger than what was calculated before. Since we know proportional action was excessive in the last tuning attempt, and this one recommends an even higher gain value, we can expect our next trial to oscillate even worse.

Applying the PID values of 6.6 (gain), 3.5 minutes per repeat (integral), and 0.875 minute (derivative) gave the following result in automatic mode:

The process oscillations follow a 10% setpoint change (from 60% to 50%), and are nowhere near settled after an hour’s worth of time. Once again we see the nearly 180o phase shift between the OUT and the PV waves, indicating proportional reverse-action controller response. As expected, this is far too much gain for robust control!

From the initial open-loop (manual output step-change) test, we could see this process contains multiple lags in addition to about 2 minutes of dead time. Both of these factors tend to limit the amount of gain we can use in the controller before the process oscillates. Both Ziegler-Nichols tuning attempts confirmed this fact, which led me to try much lower gain values in my initial heuristic tests. Given the self-regulating nature of the process, I knew the controller needed integral action, but once again the aggressiveness of this action would be necessarily limited by the lag and dead times. Derivative action, however, would prove to be useful in its ability to help “cancel” lags, so I suspected my tuning would consist of relatively tame proportional and integral values, with a relatively aggressive derivative value.

After some experimenting, the values I arrived at were 1.5 (gain), 10 minutes (integral), and 5 minutes (derivative). These tuning values represent a proportional action only one-third as aggressive as the least-aggressive Ziegler-Nichols recommendation, an integral action less than half as aggressive as the Ziegler-Nichols recommendations, and a derivative action five times more aggressive than the most aggressive Ziegler-Nichols recommendation. The results of these tuning values in automatic mode are shown here:

With this PID tuning, the process responded well to not just one, but two 10% setpoint step-changes within the span of an hour.

The next simulated process I attempted to tune was a liquid level-control process. Performing an open-loop test (one 10% increasing output step-change, followed by a 10% decreasing output step-change, both made in manual mode) on this process resulted in the following behavior:

Applying the PID values of 24 (gain), 0.2 minutes per repeat (integral), and 0.05 minutes (derivative) gave the following result in automatic mode:

The process variable certainly responds rapidly to the five increasing setpoint changes and also to the one large decreasing setpoint change, but the valve action is hopelessly chaotic. Not only would this “jittery” valve motion prematurely wear out the stem packing, but it would also result in vast over-consumption of compressed air to continually stroke the valve from one extreme to the other. Furthermore, we see evidence of “overshoot” at every setpoint change, most likely from excessive integral action.

We can see from the valve’s wild behavior even during periods when the process variable is holding at setpoint that the problem is not a loop oscillation, but rather the effects of process noise on the controller. The extremely high gain value of 24 is amplifying PV noise by that factor, and reproducing it on the output signal.

Next, I attempted to perform a closed-loop “Ultimate” gain test on this process, but I was not successful. Even the controller’s maximum possible gain value would not generate oscillations, due to the extremely crisp response of the process (minimal lag and dead times) and its integrating nature (constant phase shift of -90^{o}).

From the initial open-loop (manual output step-change) test, we could see this process was purely integrating. This told me it could be controlled primarily by proportional action, with very little integral action required, and no derivative action whatsoever. The presence of some process noise is the only factor limiting the aggressiveness of proportional action. With this in mind, I experimented with increasingly aggressive gain values until I reached a point where I felt the output signal noise was at a maximum acceptable limit for the control valve. Then, I experimented with integral action to ensure reasonable elimination of offset.

After some experimenting, the values I arrived at were 3 (gain), 10 minutes (integral), and 0 minutes (derivative). These tuning values represent a proportional action only one-eighth as aggressive as the Ziegler-Nichols recommendation, and an integral action fifty times less aggressive than the Ziegler-Nichols recommendation. The results of these tuning values in automatic mode are shown here:

You can see on this trend five 10% increasing setpoint value changes, with crisp response every time, followed by a single 50% decreasing setpoint step-change. In all cases, the process response clearly meets the criteria of rapid attainment of new setpoint values and no overshoot or oscillation.

If it was decided that the noise in the output signal was too much for the valve to handle over time, we would have the option of further reducing the gain value and (possibly) compensating for slow offset recovery with more aggressive integral action. We could also attempt the insertion of a damping constant into either the level transmitter or the controller itself, so long as this added lag did not cause oscillation problems in the loop^{2}. The best solution would be to find a way to isolate the level transmitter from noise, so that the process variable signal was much “quieter.” Whether or not this is possible depends on the process and on the particular transmitter used.

This next simulated process is a temperature control process. Performing an open-loop test (two 10% increasing output step-changes, both made in manual mode) on this process resulted in the following behavior:

From the trend, the process appears to be self-regulating with a slow time constant (lag) and a substantial dead time. The reaction rate (R) on the first step-change is 30% over 30 minutes, or 1 percent per minute. Dead time (L) looks to be approximately 1.25 minutes. Following the Ziegler- Nichols recommendations for PID tuning based on these process characteristics (also including the 10% step-change magnitude ∆m):

Applying the PID values of 9.6 (gain), 2.5 minutes per repeat (integral), and 0.625 minutes (derivative) gave the following result in automatic mode:

As you can see, the results are quite poor. The PV is still oscillating with a peak-to-peak amplitude of almost 20% from the last process upset at the time of the 10% downward SP change. Additionally, the output trend is rather noisy, indicating excessive amplification of process noise by the controller.

Next, the closed-loop, or “Ultimate” tuning method of Ziegler and Nichols was applied to this process. Eliminating both integral and derivative control actions from the controller, and experimenting with different gain (proportional) values until self-sustaining oscillations of consistent amplitude were obtained, gave a gain value of 15:

From the trend, we can see that the ultimate period (Pu) is approximately 5.2 minutes in length. Following the Ziegler-Nichols recommendations for PID tuning based on these process characteristics:

These PID tuning values are quite similar to those predicted by the open loop (“Reaction Rate”) method, and so we would expect to see very similar results:

As expected, we still see excessive oscillation following a 10% setpoint change, as well as excessive “noise” in the output trend.

From the initial open-loop (manual output step-change) test, we could see this process was self-regulating with a slow lag and substantial dead time. The self-regulating nature of the process demands at least some integral control action to eliminate offset, but too much will cause oscillation given the long lag and dead times. The existence of over 1 minute of process dead time also prohibits the use of aggressive proportional action. Derivative action, which is generally useful in overcoming lag times, will cause problems here by amplifying process noise. In summary, then, we would expect to use mild proportional, integral, and derivative tuning values in order to achieve good control with this process. Anything too aggressive will cause problems for this process.

After some experimenting, the values I arrived at were 3 (gain), 5 minutes (integral), and 0.5 minutes (derivative). These tuning values represent a proportional action only one-third as aggressive as the Ziegler-Nichols recommendation, and an integral action about half as aggressive as the Ziegler- Nichols recommendation. The results of these tuning values in automatic mode are shown here:

As you can see, the system’s response has almost no overshoot (with either a 10% setpoint change or a 15% setpoint change) and very little “noise” on the output trend. Response to setpoint changes is relatively crisp considering the naturally slow nature of the process: each new setpoint is achieved within about 7.5 minutes of the step-change.

^{1}The astute observer will note the presence of some limiting (saturation) in the output waveform, as it attemptsto go below zero percent. Normally, this is unacceptable while determining the ultimate gain of a process, but here it was virtually impossible to make the process oscillate at consistent amplitude without saturating on the output signal. The gain of this process falls off quite a bit at the ultimate frequency, such that a high controller gain is necessary to sustain oscillations, causing the output waveform to have a large amplitude.

^{2}We would have to be very careful with the addition of damping, since the oscillations could create may not appear on the trend. Remember that the insertion of damping (low-pass filtering) in the PV signal is essentially an act of “lying” to the controller: telling the controller something that differs from the real, measured signal. If our PV trend shows us this damped signal and not the “raw” signal from the transmitter, it is possible for the process to oscillate and the PV trend to be deceptively stable!

**Go Back to Lessons in Instrumentation Table of Contents**

### Related Articles

- Disassembly of a sliding-stem control valve
- Instrumentation Documents - Process and Instrument Diagrams
- Instrumentation Documents - SAMA Diagrams
- Conservation Laws
- Analog Electronic Instrumentation
- Machine Vibration Measurement - Vibration Sensors
- Machine Vibration Measurement - Monitoring Hardware
- Machine Vibration Measurement - Mechanical Vibration Switches
- Signal Characterization
- Doctor Strangeflow, or how I learned to relax and love Reynolds numbers
- Practical Calibration Standards - Temperature Standards
- Practical Calibration Standards - Pressure Standards
- The International System of Units
- Practical Calibration Standards - Flow Standards
- Fluid Mechanics - Torricelli’s Equation
- Fluid Mechanics - Flow Through a Venturi Tube
- Elementary Thermodynamics - Temperature
- Elementary Thermodynamics - Heat
- Industrial Physics Terms and Definitions
- Elementary Thermodynamics - Heat Transfer
- Elementary Thermodynamics - Specific Heat and Enthalpy
- Positive Displacement Flowmeters
- Mathematics for Industrial Instrumentation
- True Mass Flowmeters
- Process/Instrument Suitability of Flowmeters
- Machine Vibration Measurement
- Continuous Analytical Measurement - Safety Gas Analyzers
- Industrial Physics for Industrial Instrumentation
- Metric Prefixes
- Dimensional Analysis for Industrial Physics
- Classical Mechanics
- Elementary Thermodynamics
- Fluid Mechanics
- Chemistry for Instrumentation
- Continuous Analytical Measurement - Conductivity Measurement
- Fluid Mechanics - Pressure
- Fluid Mechanics - Pascal's Principle and Hydrostatic Pressure
- Fluid Mechanics - Manometers
- Fluid Mechanics - Systems of Pressure Measurement
- Fluid Mechanics - Buoyancy
- Fluid Mechanics - Gas Laws
- Fluid Mechanics - Fluid Viscosity
- Fluid Mechanics - Reynolds Number
- Fluid Mechanics - Viscous Flow
- Fluid Mechanics - Bernoulli’s Equation
- Elementary Thermodynamics - Phase Changes
- Elementary Thermodynamics - Phase Diagrams and Critical Points
- Elementary Thermodynamics - Thermodynamic Degrees of Freedom
- Elementary Thermodynamics - Applications of Phase Changes
- Continuous Analytical Measurement - pH Measurement
- Continuous Analytical Measurement - Chromatography
- Continuous Analytical Measurement - Optical Analyses
- Chemistry - Terms and Definitions
- Chemistry - Atomic Theory and Chemical Symbols
- Chemistry - Periodic Table of Elements
- Chemistry - Electronic Structure
- Chemistry - Spectroscopy
- Practical Calibration Standards - Analytical Standards
- Chemistry - Formulae for Common Chemical Compounds
- Chemistry - Molecular Quantities
- Chemistry - Energy in Chemical Reactions
- Chemistry - Periodic Table of the Ions
- Chemistry - Ions in Liquid Solutions
- Chemistry - pH
- Final Control Elements - Control Valves
- Final Control Elements - Variable-Speed Motor Controls
- Principles of Feedback Control
- Basic Feedback Control Principles
- On/Off Control
- Proportional -Only Control
- Proportional-Only Offset
- Integral (Reset) Control
- Derivative (Rate) Control
- Summary of PID Control Terms
- P, I, and D Responses Graphed
- Different PID Equations
- Pneumatic PID Controllers
- Analog Electronic PID Controllers
- Digital PID Controllers
- Practical PID Controller Features
- Classified Areas and Electrical Safety Measures
- Concepts of Probability and Reliability
- Process Characterization
- Before You Tune...
- Quantitative PID Tuning Procedures
- Process Safety and Instrumentation
- Notes to Students with Regards to Process Dynamics and PID Controller Tuning
- Basic Process Control Strategies
- Lessons in Instrumentation TOC
- Supervisory Control
- Cascade Control
- Ratio Control
- Relation Control
- Feedforward Control
- Feedforward with Dynamic Compensation
- Limit, Selector, and Override Controls
- Safety Instrumented Functions and Systems
- Instrument System Problem-Solving