Advanced PID Control

Download as pdf or txt
Download as pdf or txt
You are on page 1of 15

White Paper

Advanced PID Control

Advanced PID Control

Author: Tushar Chowhan Date: July 04, 2005

SoftDEL Systems Inc. (www.softdel.com)

White Paper

Advanced PID Control

Abstract
This paper presents the various methods available to automatically tune the PID controller identifying their merits and demerits. It also presents a comparative analysis on various autotuning methods that are used to tune a PID controller. The paper also provides the guidelines to select the appropriate tuning algorithm for a given process. Further, the paper introduces a novel method to improve the relay based auto tune PID algorithm.

Introduction
PID control is the most commonly used strategy for programmable controllers in the industry. Ninety seven percent of control loops in use are PIDs. A typical factory floor application implements hundreds of PID loops. This makes it important to ensure that the control loops are tuned to the best of its performance as this directly affects the quality, quantity and cost of the product. It is important for a process engineer to understand the mechanism that is used to tune the PID control loop. In recent years, a variety of Auto-tuning PID methods have emerged. Unfortunately, these methods and algorithms are not well understood by the end user thus leading to a significant loss, which according to an estimate runs to billions of dollars. PID control is a widely used control strategy to control most of the industrial automation processes because of its remarkable efficacy, simplicity of implementation and broad applicability. Long history of its practical use and proficient working dynamics are some of the pivotal reasons behind the large acceptance of the PID control. The PID control algorithm is a three-term linear control strategy that uses Proportional control as its major control term Integral action to largely remove steady state error Derivative control to add stability to a loop and thus facilitating the use of higher proportional action

PID controllers are tuned by setting the Proportional Band, the Integral time and the Derivative time such that a robust and optimal control is obtained. In practice, operators use trial and error procedures to carry out the tuning using some experience based rules. This procedure often proves to be difficult and time consuming, especially when the dynamic process is slow, partly nonlinear, and contains significant dead time or random disturbances acting on the plant. Even after tuning the control performance may later deteriorate due to nonlinear or time varying characteristics of the process under control. Although PID controllers are common and well known, they are often poorly tuned.

SoftDEL Systems Inc. (www.softdel.com)

White Paper

Advanced PID Control

This is an evident practice sighted in almost any industrial process in light of the following facts: More than 30% of installed controllers operate in manual mode More than 30% of the loops increase short term variability (lack robustness) About 25% of the loops use default settings About 30% of the loops have equipment problems About 90% of the loops work in the PI mode

A simple control analysis indicates that to control a nonlinear process a nonlinear control is required, but PID controller is a linear controller. Unfortunately, almost all real-time processes are non-linear and therefore are controlled with sub-optimal PID control. Moreover, loops tuned for setpoint regulation do not work well for load regulation.

Overview of Existing Auto Tune PID Control


There are five major methods used to automatically tune PID loops. These methods are: Magnitude optimum multiple integrations method (step response analyzer) Using Relay or Modified Relay tuning method Online Close loop response analyzer Using Internal Model Control Using Neuro Fuzzy tuning

Practical regulators supporting the above mentioned features are now available in many controllers. Automatic tuning methods based on transient-response identification can work in open or closed loop systems. Many of these methods are based on the analysis of system response to special inputs e.g. steps and pulses. This analysis is used to identify simple models for some dynamic characteristics of the systems. A set of empirical rules can also be used for tuning. Frequency-response can be used to determine the process dynamics. The relay tuning method works extensively in the frequency domain. It works by inserting a nonlinear element (relay or relay plus hysteresis) in a negative series feedback with the process. This forces the system into a limit cycle with oscillations in the system. This identifies a unique point on the Nyquist curve of the process, where the function describing the nonlinear element intersects with the Nyquist curve. Using PID control compensation it is possible to move this identified point to another desired point on

SoftDEL Systems Inc. (www.softdel.com)

White Paper

Advanced PID Control

the close loop Nyquist curve. This point is characterized by the desired robustness and optimality (phase and gain margin). Thus, PID loop parameters are computed by the effort to move the identified point to a desired point Other controllers do not perturb the plant. Instead, they consider the closed loop response of the system and apply the tuning algorithm according to the response. These controllers use a pattern recognition technique. They examine the plant responses caused by the step changes in the setpoint or the disturbances in order to compute some characteristic parameters of the process. Within the framework of an expert system some Zeigler Nichole aided tuning rules are then applied until the system behaves as prescribed. Other methods derive an explicit first or second order model from the observed plant transient behavior and provide a set of PID parameters based on minimization of an index. The main advantage of the above mentioned methods are that they require little a priori knowledge of the process. The draw back is that the transient response is sensitive to noise and external disturbances of an unknown structure, which can lead to poor tuning. The methods based on the use of special inputs are not suitable for continuous adaptation. Many of the self-tuning PID regulators are based on line identification algorithm, which obtains a parametric model of the plant followed by some design criteria. This is the case in a scheme, which combines an identification algorithm with a procedure to minimize an index with respect to the PID parameters. This index used is an addition to the square of the error between the set point and the controller output at instant t, and the square of change in control signal multiplied by a weighting factor. There are other alternatives for the automatic tuning of PID controller. Conventional control laws based on a parametric model of the plant can be configured to give a discrete PID regulator. This approach seems to be the most natural from the standard adaptive control point of view. However, several problems arise because of the fixed structure of the PID controller. Although conventional pole assignment methodology can be applied to yield a PID controller with closed loop poles of the system in a given position, only one solution exists for the special case of the first and second order discrete models with unit delay and without zeros and its applicable range is very narrow. If an attempt is made to derive a PID by minimizing an on-step quadratic performance criterion of prediction errors, and control efforts with respect to the parameters, it is found that there is no unique solution available and if available it can even change between sampling periods. In order to overcome this problem a more general index that smoothens the solution over a given period has to be used. The criticism about this tuning method is that they compute a set of parameters according to the chosen design criteria but the solution does not correspond to the

SoftDEL Systems Inc. (www.softdel.com)

White Paper

Advanced PID Control

set S (G), which could be obtained from discretization of a continuous time PID. A PID like behavior therefore, cannot be guaranteed in the controller. A major constraint on the development of industrial tuner has been to provide safe algorithms, which allows the operator to input the safety limits relevant to a particular process and to define the scope of automated tuners. This also implies enabling the process engineer to input specific process information such as feed forward and automatic override signals. The tuning algorithm themselves must have an inbuilt protection so that they give safe results in adverse environments. Safe results might imply that a continuous adaptive tuner does not change any parameters, or that a manually initiated autotune weighs its results more heavily towards another test if its level of confidence in its present measurement is poor. Tuning algorithm needs to be robust against all possible process conditions from good disturbance free control to noisy control, experiencing both random disturbances and interactions from adjacent loops. The five classes of most popularly used Auto tuners are: Ziegler-Nichols based Auto tuning Wave Form analysis-based tuning method initiated by reorganization. Parametric self-tuning controller based on least square identification of process transfer function related parameter. Neuro-Fuzzy tuner Internal model control based tuner

Let us now explore these methods in more details:

The Zeigler Nichols PID tuning Method


The Zeigler Nichols based algorithm is a manually initiated one-shot tune where as the algorithm based on waveform analysis and least square identification continuously adapts to changing process conditions. The Ziegler Nichols based algorithm measures the closed loop response to operational process disturbances; and uses the least square method require no special test signal

Relay/Modified Relay based method


As mentioned before the relay tuning method works by identifying a point on the Nyquist curve by placing a nonlinear element in a negative series feedback and forcing the system to oscillate. The Nyquist curve is a plot of the process transfer function in the complex frequency (s) domain. Each point on the curve is identified

SoftDEL Systems Inc. (www.softdel.com)

White Paper

Advanced PID Control

by its phase and amplitude for the given frequency. The curve is plotted in a complex plane. Nyquist plot is applicable for linear system or linear operating regions of a process. The nonlinear element i.e. the relay cannot be represented by a Nyquist plot. An approximate nonlinear technique called the describing function (N) is used to model the nonlinear relay element. The negative inverse (-1/N) of a describing function can be superimposed and plotted on the same Nyquist curve to evaluate the coupled system. As the system oscillates it is uniquely identified by its amplitude, phase & frequency of oscillation. This represents the unique point on the Nyquist plot where the describing function plot of the nonlinear element intersects it. Using PID control compensation it is possible to move this identified point to any another desired point on the close loop Nyquist curve. This implies that the closed loop transfer function will pass from the desired point. This point is characterized by the desired robustness and optimality (phase and gain margin). Thus, PID loop parameters are computed by the effort to move the identified point to the desired point. Following observations can be made with for the method: Identifies a single point on the plot and considers only the single point to move to a desired point. The describing function technique is an approximate technique, which requires the process to be a low pass filter, and requires the Nyquist curve to intersect it orthogonal for accuracy. Thus in the first case the identified point may be away from the actual point that is used to move to desired point. The 1 point on the Nyquist curve signifies a point of stability on the Nyquist plane, the closer the curve to this point the more unstable or oscillatory is the response. For higher order, systems identifying a single point (close to the 1) will not indicate in general how the curve trajectory forms around the 1 point. This may lead to PID parameters that are relatively unstable for the process. Some processes may not oscillate with the nonlinear element in place. Does not consider cascaded PID loops

The relay tuning experiments identifies the point on the Nyquist curve, which intersects with the negative real axis. This does not however, necessarily give the best possible information about the process with respect to PI and PID controller tuning. For example for PI controller tuning it is then not possible to specify a phase margin for the controlled system. Even though a specified

SoftDEL Systems Inc. (www.softdel.com)

White Paper

Advanced PID Control


phase margin can be obtained with the use of the derivative action in the controller, this procedure is far from robust for certain types of processes. A large phase margin requires particularly strong derivative action, which can lead to poor control quality or instability of the control system In normal relay based tests due to the adoption of the describing function approximation, the estimation of the critical point is not accurate in nature. More-ever with this method only a crude controller setting can be obtained on the single point identified. A modified Two Channel relay method identifies a point on the Nyquist plot at a user-selected phase lag in the third quadrant is proposed. With respect to PI controller tuning the identification of the process in the third quadrant is superior to standard relay based autotuning method, because it enables not only of amplitude margin specification but also phase margin specification.

Some of the advantages with relay autotuning are as follows: Little a priori knowledge of the plant is required. The identification and tuning sequences are easy to automate and easy to use. It is closed-loop test with bounded input amplitude and the output can therefore be kept close to the set point during identification. It gives more accurate information about the frequencies important for feedback control than e.g. a step response does.

SoftDEL Systems Inc. (www.softdel.com)

White Paper

Advanced PID Control

I m

A B Re

C, D & E F
Fig.1.0. The above figure illustrates the intersection of the process Nyquist curve with various candidate-describing functions. A Ideal Relay, B Relay with Hysterisis, C, D, E Modified relay with Integrator, F Ideal relay in series with an integrator

Fig.2.0. this figure illustrates the vector effect of changing PID parameters on the identified point. The total effort required by tuning the PID parameters is to shift the point from A to B.

Deleted: This

SoftDEL Systems Inc. (www.softdel.com)

White Paper

Advanced PID Control

This method gives good results for most processes suited to two or three term control, although first order process will not oscillate and thus need special handling, when the process is automated. One solution to this results from approach to phase margin design using an integrator giving an extra 90 phase lag which ensures oscillations. The loop can be guarantied to oscillate if the controller includes either switching Hysterisis or a time delay in its on-off response. Nyquist plot indicates the oscillation condition for the same second order process with either Hysterisis or an integrator in the controller. The above method can give reliable loop tuning and is most widely used tuning technique. Its significant advantage is that it requires minimal knowledge of the process, as the time period of the natural response automatically defines the duration of the test. The major disadvantage of this technique is that not all processes can tolerate the large control disturbances generated by this test. Some industrial auto tuners include feedback to limit the size of the resulting process value oscillation to value defined by a user. A problem arises if the process value does not exceed the set point during the tuning test. A artificial set point is often used to perform the test. This artificial set point reflects a compromise between avoiding overshoot and attempting to tune as close as possible to the working set point. For the implementation of the loop, the controller output is frozen for one minute immediately when the test is initiated, during which time the operator may choose to change the set point. During this period, the tuner measures any overall trend of the process out put and the noise on this value, thus parametering a trigger level for subsequent adaptive tuning. For set points, which differ from the process value by more than a small percentage of the instrument span, the algorithm applies maximum controller out put to drive the process value towards the set point. The process value is continuously monitored, and an estimate of the delay time in the process is made from these readings using the Ziegler Nichols process curve technique. This estimate is used to provide timeouts in a supervisory algorithm, should the process not complete any phase as expected. When the process value has reached 95% of the set point change, the algorithm proceeds into a finite state machine implementation of ON-OFF control at this process value. The output is turned OFF at this point and the process value is monitored until the peak value has been achieved. The magnitude of this peak and the time to achieve it are stored and the algorithm proceeds to the next state finding the period and magnitude of oscillation. The state machine approach gives a defensive strategy where by the auto tuner chooses a best estimate if the full sequence is not complete.

SoftDEL Systems Inc. (www.softdel.com)

White Paper

Advanced PID Control

Most controllers using the Relay/Modified Relay tuning algorithm use three sub algorithms. The algorithm starts typically fifteen percent away from the set point and first enters a phase of measuring noise. This phase is used to internally generate and parameterize a low pass filter that will work in the other phases. In the second stage, the algorithm subjects the process to a step response analyzing the process for its dead time and time constant. It internally builds a FOPDT model (First order plus dead time model). The ratio of the dead time vs. time constant is important as this characterizes the process. The point to move to on the Nyquist curve is determined from this ratio and this governed by a set of rules. In the third, stage an appropriate nonlinear modified relay is inserted in a negative series feedback with the process, and a measuring algorithm used to measure the ultimate frequency, phase and amplitude of the process output. These measurements are next used to identify the point on the Nyquist curve and compute the PID parameters.

A Novel approach to improve on the Relay based Auto tuning


This approach improves PID tuning in a multi-order nonlinear-cascaded process. It works by identifying a multiple order model or identifying candidate influential points on the Nyquist curve. A first level algorithm uses a multiple integration (Area computation) method to compute the dead time and ordered time constants of the system. These points are later used to generate a nonlinear component that is used in place of the relay element. The advantage of this method is its handling of higher order process.

Neuro fuzzy based method


The Neuro Fuzzy algorithm augments the capability of the relay based tuning by providing an inline self-tuner. A fuzzy rule base and linguistic model are designed to work with the same empirical rules as would be used by the PID specialist to tune the PID Controller. An expert system observes the process response looking for the process reaction time, steady state error and stability (oscillation). The Neuro-Fuzzy network uses this data to fire valid Fuzzy rules that work to iteratively change the PID parameters. Another advantage of fuzzy tuning is its applicability to nonlinear processes. Gain scheduling is the usual approach to enable PID control loops to work with non-linear processes. The non-linear process is linearized into multiple operating regions where corresponding PID control is applied. Thus each operating region has its own unique set of PID parameters. The major problem in implementing a Gain Scheduling method is the abrupt switching of the PID parameters between these operating regions. A Fuzzy implementation works well in this scenario providing for a smooth switch over. The neural network helps in adapting the fuzzy network between these boundaries.

SoftDEL Systems Inc. (www.softdel.com)

White Paper

Advanced PID Control

Disturbance response analysis technique


This Disturbance response analysis technique is based on continuous analysis of process value waveforms as a function of time during operational closed loop control. The actual responses monitored are the error signals generated when the control loops experience a disturbance. As control, errors can be generated by process noise, external process disturbances and set point changes it is helpful to be able to recognize these specific sources, while evaluating the response to the disturbance. A fundamental problem of the waveform analysis technique is that it may not have enough information to be aware to changes of the initial disturbance. The problem of process noise is soluble by providing a means of measuring the noise environment during an autotune test prior to initializing the adaptive tuner and the parametrizing the noise filter. Alternatively, the use may define the expected noise level and input this to the tuner. As the controller has knowledge of set point changes, the adaptive tuner can easily be reinitialized to evaluate the response to this disturbance. However, periodic external disturbance to the process can result in incorrect identification. Once the disturbance analysis tuner has been triggered by an error, exceeding the measured noise levels, subsequent error peaks are measured. Poorly tuned loops may exhibit a damped oscillatory recovery from a loop disturbance. The control strategies is to improve poor responses and is not difficult to derive, given a model of a typical process and generally these strategies are well suited to implement in microprocessor-based systems. It is however more difficult to record the responses in such a way that they can be safely categorized as one of the expected models. The tuner must analyze the response over a long enough period to enable consistency checks to be performed on measurement. Defining a long enough period on a completely unknown system is very arbitrary and so a practical tuner uses predefined time out periods, resulting from previous tests or, at worst, safe default values. In addition, the tuner can use zero error and zero rate of change of error as time land marks. Measuring rates of change of a noisy signal requires complex measurement techniques, because any error filtering must be related to the time constants as yet unidentified, process. Having evaluated the disturbance response, the tuner must then decide whether the measurement matches its preprogrammed model for good responses for example with a damped oscillatory responses is the damping factor greater than the acceptable value or are subsequent oscillations comparable with noise levels. One of the disadvantage of waveform analysis technique is that it has to have completed identification of a poor response in order to correct it, where as the ideal tuner would correct the control values within the response time of the loop.

SoftDEL Systems Inc. (www.softdel.com)

White Paper

Advanced PID Control

Comparative Evaluation
The following table summarizes and provides indicative guidelines when selecting an appropriate Auto tuning strategy. Method Neuro Fuzzy Control based Tuning (PID) Guideline Use when regular Auto tune PID does not sufficiently control the process or process is not critical. Advantages Disadvantages

1. Linear & 1. Basic control nonlinear properties such control as controllability, 2. Works well observability & when used to stability not augment other guaranteed. methods 2. Mathematical 3. Can be used formulation and where working conventional dynamics are not PID will not completely work. reliable 4. Will work if subjecting the process to a step response is not desired. 1. In case of the large modeling errors, its performance will not be satisfactory. 2. For a high order system model the resulting controller derived will be of high order, and implementation of IMC is sometimes costly. 1. Forces the process offline requiring a step response followed with at least two cycles of forced relay oscillations

Internal Model Control (IMC)

Emerging technique

Relay Tuning / Modified Relay Tuning method

Most widely used method works well for average to simple processes where a first order plus dead time model is sufficient to represent the system

1. Little a - priori knowledge of the system is required. 2. The identification and tuning segments are easy to

SoftDEL Systems Inc. (www.softdel.com)

White Paper

Advanced PID Control

Method

Guideline

Advantages automate and easy to use. 3. It is a closed loop test with bounded input amplitude & the output can be kept close to the set point during identification 4. It gives more accurate informations about the frequencies important for feedback control than e.g. a step response does.

Disadvantages 2. Assumes the process to be a low pass filter 3. It is based on identifying a single point in the Nyquist plots, which fails to represent the whole system/process. 4. Will not work for higher order processes 5. No general rule for cascading

SoftDEL Systems Inc. (www.softdel.com)

White Paper

Advanced PID Control

Magnitude Optimum Multiple Integration based PID tuning method

Use where a step change in the process is amenable but where cycling of the processes is not possible.

It is quite robust to the process high frequency noise and non-linearity.

1. It requires a stable open-loop process response in order to determine the appropriate controller parameters. 2. Low frequency noise or disturbances can significantly affect the accuracy of the calculated controller parameters if some additional precautions are not taken. 3. Does not handle nonlinear processes 4. Need to work off line and subject the process to a step response

Online close loop response analyzers

Use in processes were tuning is required online and no step, pulse or cycling is permissible

Process need not be Needs to collect a perturbed. history of data before arriving to a acceptable PID parameters.

Conclusion
We examined the various Auto Tune PID algorithms and presented a comparative analysis for it. The modified relay tuning method is one of the most popular tuning algorithms. Newer algorithms have emerged identifying the disadvantages over the conventional Relay based auto tuning and built over it. This algorithms are designed to handler a larger class of nonlinear multiple order processes. It is advisable to upgrade to these algorithms when the process is complex and cannot be handled by the relay tuning method. We also have presented a new way of modifying the existing relay tuning algorithm to work with multiple ordered systems and a significantly better performance.

SoftDEL Systems Inc. (www.softdel.com)

White Paper

Advanced PID Control

References: [1] Vrancic D, R. Hanus, and S. Strmcnik . A new tuning method for delayed processes based on the multiple integration method. Accepted by the IFAC Conference on System Structure and Control, Nantes, July 8-10, 1998. [2] Friman M, and Waller K.V . A two channel relay for auto-tuning, A technical report. Process Control Laboratory, Department of Chemical Engineering, Abo Akademi, Abo, Finland. December 13, 1996. [3] Marchetti G, and Scali C. Use of modified relay techniques for the design of model based controllers for chemical processes. Department of Chemical Engg. University of Pisa.

SoftDEL Systems Inc. (www.softdel.com)

You might also like