Presentation on theme: "PID Controllers and PID tuning ETEC 6419. The PID algorithm The PID controller is the most common form of feedback. In process control today, more than."— Presentation transcript:
PID Controllers and PID tuning ETEC 6419
The PID algorithm The PID controller is the most common form of feedback. In process control today, more than 95% of the control loops are of PID type, most loops are actually PI control.
Types of implementation of PID controllers There are standalone systems in boxes for one or a few loops, which are manufactured by the hundred thousands yearly. PID control is often combined with logic, sequential functions, selectors, and simple function blocks to build the complicated automation systems used for energy production, transportation, and manufacturing. Many sophisticated control strategies, such as model predictive control, are also organized hierarchically
PID implementations today Practically all PID controllers made today are based on microprocessors. Implementation platforms include Single board computers Industrial computers Personal computers Microcontrollers PLCs
The textbook version of the PID algorithm where y is the measured process variable, r the reference variable, u is the control signal and e is the control error (e = y sp y). The reference variable is often called the set point. The control signal is thus a sum of three terms: the P-term (which is proportional to the error), the I-term (which is proportional to the integral of the error), and the D-term (which is proportional to the derivative of the error). The controller parameters are proportional gain K, integral time Ti, and derivative time Td. The three terms used in the PID controller are proportional, integral, derivative abbreviated PID
The PID controller in a system Consider the PID controller implemented in the control system below
Proportional control action In the proportional control action, the output is directly related to the input so G 1 =k p The constant k p is the gain and this controls the basic response of the system
Impact of proportional controller Increasing the proportional gain may produce overshoot and hunting as shown on the previous slide, when a sudden (step) change is made to the input. This is especially true if the system is oscillatory in nature due to second order terms such as inertia or inductance and there is insufficient damping.
Open loop system response Using block diagram reduction rules a closed loop system can be converted into an open loop system. Open loop systems do not always settle at the desired level when a step input is applied. Consider the system with open loop transfer function
The system settles at a level less than unity. Increasing the gain k brings the response closer to unity but introduces a damped oscillation. To overcome the problem of a constant error at steady state, we introduce the integral controller term
Integral control This is very useful in avoiding offset error. Some systems will respond to a step input by settling at a different level to the step value. This might be due to the way the system is designed or due to a disturbance added to the output.
The integral control action will cause the output Q to increase over time until the system responds and reduces the error to zero. This ability to accumulate small errors into much larger error based control action is how the integral controller prevent continuous constant steady state errors occurring.
Integral control action The equation for integral control is usually rearranged as follows Ki is the integral constant of proportionality, it is sometimes replaced with Kp is the proportional constant and Ti is the integral time constant. The reason for arranging the equation into this form will become apparent later.
Differential control action The output of the controller is directly proportional to rate of change of the error. In the case of a step change, the rate of change is greatest at the start of the change and so the system will respond quickest in the early stages. As the error reduces, the rate of change of error also reduces and the system is slowed down in anticipation of arriving at the correct level. This form of control enables quicker response without overshoot.
The derivative equation can be rearranged as follows. Or in laplace form Kp is the proportional constant and Td is the differential time constant. Most system controllers will have adjustments which enable the constants Kp, Ti and Td to be set in order to optimise the system response.
The three terms together The output of a PID controller is
Example The input and output of a PID controller is related by the equation Find the value of the proportional gain, the integral gain, the integral time constant and the differential time constant
Solution By comparison with the equation It is apparent that:
Exercise 1 The input and output of a PID controller is related by the equation Find the value of the proportional gain, the integral time constant and the differential time constant. (2,4 and 2)
Zeigler – Nichols method of tuning In order to optimize the performance of a system, the controller parameters need to be set. The late Zeigler and Nichols produced a practical guide for setting up three term controllers for plant systems dating back to the 1940s. Today many control engineers still use the Zeigler Nichols method of tuning PID equations
Zeigler nichols closed loop method In this method only the proportional gain is used and this is adjusted until small continuous oscillations are obtained. The system is then at the limit of instability. The gain G and periodic time Tp are noted. The three term controller is then set so that: kp=0.6G, Ti=Tp/2, Td=Tp/8
This will produce a response to a step change in the form of a decaying oscillation with a damping ratio of 0.21 and the amplitude of the second cycle will be ¼ of the initial amplitude as shown. This is accepted as a reasonable setting for most process plant systems
Open loop controller tuning method With the disconnected introduce a step change and measure the response. A typical plant process produces as open loop response as shown. τ is the time delay which often occurs in plant systems due to the lag in the process. T is the time constant, H 1 is the input step and H2 is the resultant step in the steady state. The steady state gain is H 1 /H 2
The settings for the controller using the open loop method are as follows K p =1.2TH 1 /(H 2 τ) T i =2τ T d =0.5τ
Example A plant process is controlled by a PID controller. In a closed loop test using only proportional gain, the limit of stability was found to occur with a gain of 4.5. Calculate the proportional, integral and differential constants required so that a ¼ decay is obtained in response to a step change
example The three term controller in a plant process is to be adjusted for optimal performance using the Zeigler nichols open loop method. The proportional gain was set to give a steady state step change equal to the input change. The time delay was 24 seconds and the time constant was 50 seconds. Calculate the proportional, integral and differential constants required.