Traditional Culture Encyclopedia - Traditional festivals - How to change the parameters of PID?

How to change the parameters of PID?

At present, the level of industrial automation has become an important symbol to measure the modernization level of all walks of life. At the same time, the development of control theory has gone through three stages: classical control theory, modern control theory and intelligent control theory. A typical example of intelligent control is fuzzy automatic washing machine. Automatic control system can be divided into open-loop control system and closed-loop control system. The control system includes a controller, a sensor, a transmitter, an actuator and an input/output interface. The output of the controller is added to the controlled system through the output interface and actuator; The controlled quantity of the control system is sent to the controller through sensors, transmitters and input interfaces. Different control systems have different sensors, transmitters and actuators. For example, a pressure control system should use a pressure sensor. The sensor of the electric heating control system is a temperature sensor. At present, there are many PID controllers and their controllers or intelligent PID controllers (instruments), and their products have been widely used in engineering practice. There are many kinds of PID controller products, and all major companies have developed intelligent regulators with PID parameter self-tuning function, in which the automatic adjustment of PID controller parameters is realized by intelligent adjustment or self-tuning and adaptive algorithm. Pressure, temperature, flow and liquid level controllers with PID control, programmable controller (PLC) with PID control function, PC system with PID control, etc. Programmable controller (PLC) uses its closed-loop control module to realize PID control, which can be directly connected with ControlNet. There are also controllers that can realize PID control function, such as Rockwell's Logix product series, which can be directly connected with ControlNet and realize its remote control function through the network. 1, open-loop control system Open-loop control system means that the output of the controlled object (controlled quantity) has no influence on the output of the controller. In this control system, it does not depend on the feedback controlled quantity to form any closed loop. 2. Closed-loop control system The characteristic of closed-loop control system is that the output of the controlled object (controlled quantity) of the system will be sent back to the output of the influence controller to form one or more closed loops. The closed-loop control system has positive feedback and negative feedback. If the feedback signal is opposite to the given value signal of the system, it is called negative feedback, and if the polarity is the same, it is called positive feedback. Closed-loop control system generally adopts negative feedback, also known as negative feedback control system. There are many examples of closed-loop control systems. For example, people are a closed-loop control system with negative feedback, and the eyes are sensors, which play a feedback role. The human body system can make all kinds of correct actions through constant correction. If there are no eyes, there is no feedback loop and it becomes an open-loop control system. For another example, when a real automatic washing machine can continuously detect whether clothes are washed and automatically cut off the power supply after washing, it is a closed-loop control system. 3. Step response Step response refers to the output of the system when a step function is added to the system. Steady-state error refers to the difference between the expected output and the actual output of the system after the response of the system enters a steady state. The performance of the control system can be described in three words: stable, accurate and fast. Stability refers to the stability of the system. If a system can work normally, it must be stable first and converge in step response. Accuracy refers to the accuracy and control precision of the control system, which is usually described by steady-state error, which represents the difference between the steady-state value and the expected value of the system output; Fast refers to the rapidity of control system response, which is usually described quantitatively by rise time. 4. Principles and characteristics of PID control In engineering practice, the most widely used regulator control laws are proportional, integral and differential control, referred to as PID control, also known as PID regulation. PID controller has a history of nearly 70 years since it came out. Because of its simple structure, good stability, reliable operation and convenient adjustment, it has become one of the main technologies of industrial control. When the structure and parameters of the controlled object can not be fully grasped, or the accurate mathematical model can not be obtained, and other technologies of control theory are difficult to adopt, the structure and parameters of the system controller must be determined by experience and field debugging, so it is most convenient to apply PID control technology. That is, when we don't fully understand a system and the controlled object, or we can't get the system parameters through effective measurement, PID control technology is the most suitable. PID control, in fact, there are also PI and PD control. PID controller is based on the system error, using proportion, integral and differential to calculate the control quantity to control. Proportional (P) control Proportional control is the simplest control method. The output of the controller is proportional to the input error signal. When there is only proportional control, there is a steady-state error in the system output. Integral (I) control In integral control, the output of the controller is proportional to the integral of the input error signal. For an automatic control system, if there is a steady-state error after entering the steady state, then the control system is called a system with steady-state error. In order to eliminate the steady-state error, an "integral term" must be introduced into the controller. The error of the integral term pair depends on the integration of time, and the integral term will increase with the increase of time. In this way, even if the error is small, the integral term will increase with the increase of time, thus pushing the output of the controller to increase and further reducing the steady-state error until it is equal to zero. Therefore, the proportional+integral (PI) controller can make the system enter the steady state without steady-state error. Differential (D) control In differential control, the output of the controller is directly proportional to the differential of the input error signal (that is, the rate of change of the error). In the process of adjusting to overcome the error, the automatic control system may oscillate or even become unstable. The reason is that there are components (links) with large inertia or delayed components, which can suppress errors, and their changes always lag behind the changes of errors. The solution is to introduce the change of error suppression effect, that is, when the error is close to zero, the error suppression effect should be zero. In other words, it is often not enough to introduce only the "proportion" item into the controller. The function of the proportional term is only to amplify the amplitude of the error. What needs to be added now is the "differential term", which can predict the trend of the error. In this way, the proportional+differential controller can make the control function of restraining error equal to zero or even negative in advance, thus avoiding the serious overshoot of the controlled quantity. Therefore, for the controlled object with large inertia or time delay, the Proportional+Differential (PD) controller can improve the dynamic characteristics of the system during the adjustment process.

5. Parameter tuning of PID controller Parameter tuning of PID controller is the core content of control system design. According to the characteristics of the controlled process, the proportional coefficient, integral time and differential time of PID controller are determined. There are many methods for tuning PID controller parameters, which can be summarized into two categories: one is theoretical calculation tuning method. It mainly determines the controller parameters through theoretical calculation according to the mathematical model of the system. The calculated data obtained by this method cannot be used directly, and must be adjusted and corrected through engineering practice. The second is the engineering setting method, which mainly relies on engineering experience and is directly carried out in the test of control system. This method is simple and easy to master, and is widely used in engineering practice. The engineering tuning methods of PID controller parameters mainly include critical proportion method, response curve method and attenuation method. The three methods have their own characteristics, and the similarities are all through experiments, and then the parameters of the controller are adjusted according to the engineering experience formula. But no matter which method is adopted, the parameters of the controller need to be finally adjusted and improved in actual operation. At present, the critical proportion method is generally used. The steps of tuning PID controller parameters by this method are as follows: (1) First, preselect a sampling period short enough to make the system work; (2) Only add the proportional control link until the step response of the system to the input appears critical oscillation, and write down the proportional magnification and critical oscillation period at this time; (3) Under a certain degree of control, the parameters of PID controller are calculated by formula.

Setting of P\I\D parameters: Depending on experience and familiarity with technology, trace and set curves with reference to measured values, so as to adjust the size of P \ I \ d..

For the engineering tuning of PID controller parameters, we can refer to the empirical data of P.I.D parameters in various regulating systems as follows: temperature T: P = 20 ~ 60%, T = 180 ~ 600s, D = 3- 180s, pressure P: P = 30 ~ 70%.

The formula commonly used in books: to find the best parameter setting, first check the proportion, then integrate in order from small to large, and then add differentiation on the curve. Oscillation is very frequent. The proportional reel curve floats near Dawan, and the deviation of the proportional reel curve is slow, and the fluctuation period of the downward curve is long when the integration time is prolonged, and the oscillation frequency of the curve is fast when the integration time is prolonged. The differential is reduced first, and the fluctuation is slow when the dynamic difference is large. The differential time should be lengthened by two waves in the ideal curve, and the adjustment quality should not be lower than 1.

Here is an empirical method. This method is essentially a trial and error method, which is an effective method summed up in production practice and has been widely used in the field. The basic procedure of this method is to determine a set of regulator parameters according to the operation experience, put the system into closed-loop operation, and then artificially add step disturbance (such as changing the given value of the regulator) to observe the step response curve of the regulated quantity or regulator output. If the control quality is not satisfactory, the regulator parameters are changed according to the influence of each set parameter on the control process. Repeat this experiment until you are satisfied. ? The empirical method is simple and reliable, but it needs some field operation experience, and the timing is easy to be subjective and one-sided. When using PID regulator, there are many tuning parameters and the number of trial and error increases, so it is difficult to get the best tuning parameters.

Taking PID regulator as an example, the tuning steps of empirical method are described in detail: (1) Let the regulator parameter integral coefficient S0=0, the actual differential coefficient k=0, the control system is put into closed-loop operation, and the proportional coefficient S 1 changes from small to large, so that the disturbance signal changes step by step, and the control process is observed until it is satisfactory. ⑵ Multiply the proportional coefficient S 1 as the current value by 0.83, and change the integral coefficient S0 from small to large, which also makes the disturbance signal change step by step until a satisfactory control process is obtained. (3) Keep the integral coefficient S0 unchanged and change the proportional coefficient S 1 to see if the control process is improved. If there is improvement, continue to adjust until it is satisfactory. Otherwise, increase the original proportional coefficient S 1, and then adjust the integral coefficient S0 to improve the control process. This trial and error is repeated until satisfactory proportional coefficient S 1 and integral coefficient S0 are found. ⑷ By introducing appropriate actual differential coefficient k and actual differential time TD, the proportional coefficient S 1 and the integral coefficient S0 can be appropriately increased. Like the previous steps, it is necessary to adjust the setting of differential time repeatedly until the control process is satisfactory.

Note: The PID regulator used in the simulation system is different from the traditional industrial PID regulator, and the parameters are isolated from each other and do not affect each other, so it is very convenient to observe the regulation law with it. PID parameters are determined according to the inertia of the controlled object. Inertia is large, such as the temperature control of large drying room. Generally, P can be above 10, I = 3- 10, and D = 1. Inertia is small, such as closed-loop pressure control of small motor water pump, generally only PI control. P = 1- 10, I = 0. 1- 1, D = 0, which should be corrected during field debugging.

Provide an incremental PID for reference △ u (k) = AE (k)-Be (k-1)+Ce (k-2) A = KP (1+t/Ti+TD/t) B = KP (1+2td).

You can use the above algorithm to construct your own PID algorithm. U(K)=U(K- 1)+△U(K)