CN112859585B - Method for dynamically adjusting control period of PID controller - Google Patents

Method for dynamically adjusting control period of PID controller Download PDF

Info

Publication number
CN112859585B
CN112859585B CN202110036171.XA CN202110036171A CN112859585B CN 112859585 B CN112859585 B CN 112859585B CN 202110036171 A CN202110036171 A CN 202110036171A CN 112859585 B CN112859585 B CN 112859585B
Authority
CN
China
Prior art keywords
control
period
steady
increment
pid controller
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202110036171.XA
Other languages
Chinese (zh)
Other versions
CN112859585A (en
Inventor
马越峰
刘双刚
刘金刚
李海祥
杨建波
韩斌
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhongkong Technology Co ltd
Original Assignee
Zhongkong Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhongkong Technology Co ltd filed Critical Zhongkong Technology Co ltd
Priority to CN202110036171.XA priority Critical patent/CN112859585B/en
Publication of CN112859585A publication Critical patent/CN112859585A/en
Application granted granted Critical
Publication of CN112859585B publication Critical patent/CN112859585B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B11/00Automatic controllers
    • G05B11/01Automatic controllers electric
    • G05B11/36Automatic controllers electric with provision for obtaining particular characteristics, e.g. proportional, integral, differential
    • G05B11/42Automatic controllers electric with provision for obtaining particular characteristics, e.g. proportional, integral, differential for obtaining a characteristic which is both proportional and time-dependent, e.g. P.I., P.I.D.

Abstract

The invention discloses a method for dynamically adjusting a control period of a PID controller, which specifically comprises the following steps: s1, updating a variable control period based on a preset steady-state cruise switch and a steady-state mark; s2, determining whether to calculate a second parameter and a control increment of the PID controller based on a comparison result of the first parameter and the variable control period, if the first parameter is greater than or equal to the variable control period, calculating the second parameter and the control increment of the PID controller, otherwise, not executing the step S3; s3, comparing the calculated second parameter of the PID controller with a preset threshold value, updating a steady-state mark based on a comparison result, and outputting a control quantity of an accumulation control increment; the invention combines long period control and quick response during disturbance, realizes short control period and automatic switching of long control period after regulated output under steady state, so as to quickly respond to disturbance and ensure that output is not regulated frequently.

Description

Method for dynamically adjusting control period of PID controller
Technical Field
The invention relates to the field of real-time control of industrial control systems, in particular to a method for dynamically adjusting a control period of a PID controller.
Background
The control loop of more than 90% in the industrial field adopts a PID algorithm, and the basic idea of the PID algorithm is that proportional control increment is calculated by using deviation variation quantity at fixed time intervals, integral increment is calculated by using deviation quantity, and differential control increment is calculated by using variation quantity of deviation variation quantity (namely, difference between current deviation and deviation of last calculation time and difference between deviation of last calculation time and deviation of last calculation time, and difference between two difference values is also called deviation variation acceleration).
In some industrial processes, such as control of centrifugal fans, the control output should not be frequently operated, so that the PID controller sets a longer control period, but once the disturbance causes the process index to fluctuate, the PID controller hopefully responds in time. In the prior art, the PID controllers all adopt fixed control period control, and quick response to disturbance is difficult to realize in long period control.
Disclosure of Invention
In order to solve the problems, the invention provides a method for dynamically adjusting the control period of a PID controller, which combines long-period control and quick response during disturbance, and improves the control quality of an industrial field.
The invention provides a method for dynamically adjusting a control period of a PID controller, which specifically comprises the following steps: s1, updating a variable control period based on a preset steady-state cruise switch and a steady-state mark; s2, determining whether to calculate a second parameter of the PID controller based on a comparison result of the first parameter and the variable control period, wherein the second parameter comprises a control increment, if the first parameter is greater than or equal to the variable control period, calculating the second parameter of the PID controller, otherwise, not executing the step S3; s3, comparing the calculated second parameter of the PID controller with a preset threshold value, and updating a steady-state mark and outputting the control quantity of the accumulated control increment based on the comparison result.
Further, the step S1 specifically includes: if the preset steady-state cruise switch is ON and the steady-state flag is ON, the variable control period is updated to the system scanning period, otherwise, the variable control period keeps the preset control period unchanged.
If the preset steady-state cruise switch is ON and the steady-state flag is ON, the PID controller starts the function of dynamically adjusting the control period and the system is in a steady state.
Further, the system scanning period is smaller than the preset control period, and the preset control period is an integer multiple of the system scanning period.
The variable control period can realize the quick response of the short control period to disturbance in a steady state, and the long control period is adopted when the regulated output exists.
Further, the value of the first parameter in step S2 is the scanning period of the value accumulation system with the period counter
The accumulation of the period counter and the system scan period is used to determine the calculation of the second parameter of the PID controller.
Further, the step S3 specifically includes: s31, if the control increment is smaller than a preset threshold value, judging that the system is in a stable state, setting a stable state mark to be ON, and keeping the output control quantity unchanged; s32, if the control increment is larger than a preset threshold, setting a steady-state flag to be OFF, judging that the system is not in a steady state, and outputting a control quantity accumulation control increment.
Further, step S32 further includes limiting the control increment to an increment limiter if the control increment is greater than a preset threshold and exceeds the preset increment limiter.
Further, the second parameter further includes a difference between the measured value and the set value.
Further, the step S3 specifically includes: s31 If the average difference value between the measured value and the set value is smaller than the first preset threshold value and the maximum difference value between the measured value and the set value is smaller than the second preset threshold value in the t time period, judging that the system is in a stable state, setting a stable state mark as ON, and keeping the output control quantity unchanged; s32 Otherwise, the steady state flag is set to OFF, and if the system is judged not to be in steady state, the control quantity accumulation control increment is output.
The beneficial effects of the invention are as follows:
1. and the control period of the PID controller is dynamically set by detecting whether the control increment is smaller than a threshold value, so that the rapid response to disturbance in long-period control is realized.
2. The automatic switching of a short control period and a long control period after the regulation output is realized in a steady state, so that the process index fluctuation is responded quickly, and the infrequent regulation of the output is ensured.
3. A safety threshold is defined for the output, thereby ensuring the safety of the output.
Drawings
FIG. 1 is a flow chart of a method for dynamically adjusting a control period of a PID controller according to an embodiment of the invention;
FIG. 2 is a flowchart of a PID controller dynamic adjustment control period software function implementation according to an embodiment of the invention.
Detailed Description
The invention will now be described in further detail with reference to the drawings and the specific examples, which are given by way of illustration only and are not intended to limit the scope of the invention, in order to facilitate a better understanding of the invention to those skilled in the art.
In order to facilitate understanding of the present invention, some of the terms mentioned in the present invention will be described first.
The PID controller is used for obtaining control increment by calculating information such as deviation between measured value and set value, deviation change speed, deviation change acceleration and the like, so that the measured value tracks the set value.
Deviation, difference between measured value and set value.
The control period, the PID controller calculation period set by the engineer, is an integer multiple of the system scanning period.
The control period is variable, and the method provides a dynamically-changing PID controller control period.
The system scans the period, the time interval of the algorithm logic of the periodic scanning determined by the control system.
Steady state means that the measured value meets the process requirement and is kept close to or equal to the set value within a certain time.
The method provides that the PID controller adopts the running state with a shorter control period in the steady state.
And the period counter is used for accumulating the scanning period of each system and is used for realizing the operation of the PID controller according to the control period.
And when the control increment is negative, the control increment is required to be less than 0 and subtracted from the clipping.
Referring to fig. 1, a flow chart of a method for dynamically adjusting a control period of a PID controller in an embodiment of the present invention specifically includes S1, updating a variable control period based on a preset steady-state cruise switch and a steady-state flag; s2, determining whether to calculate a second parameter of the PID controller based on a comparison result of the first parameter and the variable control period, wherein the second parameter comprises a control increment, if the first parameter is greater than or equal to the variable control period, calculating the second parameter of the PID controller, otherwise, not executing the step S3; s4, repeatedly executing the steps S1-S3.
The method for dynamically adjusting the control period of the PID controller provided by the invention is described below in connection with the control of a centrifugal fan in a coke oven gas collecting tube system in the coking industry.
In coke oven gas collection systems in the coking industry, the fan front pressure is one of the important process control indicators. Too high pressure in front of the machine can cause too high pressure of the gas collecting tube, so that raw gas is leaked, environmental protection requirements are violated, and too low pressure in front of the machine can cause the exceeding of oxygen content in the raw gas, so that production accidents such as explosion and the like are caused.
Most coke oven gas collecting tube systems in the coking industry adopt centrifugal fans, and the front pressure of the fans is controlled by adjusting the rotating speed of the fans through a PID controller. The equipment characteristics of the centrifugal fan require that the rotating speed cannot be frequently regulated, so the control period of the fan rotating speed PID controller is set longer. However, various disturbances can cause instantaneous and large-amplitude fluctuation of pressure in front of the machine, such as charging coal into a coke oven and spraying ammonia water, and the process hopes that the fan rotating speed can respond quickly in order to timely restrain the pressure fluctuation, and the implementation adopts the following method to solve the problems.
S1, an operator or an engineer sets a steady-state cruise switch to be ON, a function of dynamically adjusting a control period of the PID controller is started, the steady-state cruise switch is set to be OFF, and the function of dynamically adjusting the control period of the PID controller is closed. The preset control period of the PID controller for controlling the rotating speed of the centrifugal fan is 20 seconds, and the variable control period is the preset control period, namely 20 seconds;
if the steady state flag of the first running of the system is set to be OFF, the system is not in steady state, the variable control period is unchanged at the moment, and the PID controller keeps the control period of 20s to control the centrifugal fan, so that the change of the wind speed of the centrifugal fan does not have larger fluctuation.
If the steady state flag is set to be ON in the subsequent operation process, the system is in a steady state, and the time of the control period of the class list is updated to be 0.5s in the system scanning period, so that the system can respond to disturbance in time.
S2, the initial value of the period counter is 0, and the period counter and the system scanning period are accumulated to serve as a first parameter. And comparing the accumulated period counter with the variable control period, and if the accumulated period counter is greater than or equal to the variable control period, calculating a second parameter. In this embodiment, each control increment of PID ratio, integral and derivative is calculated according to the PID control algorithm, and each part is accumulated to obtain the control increment of the total PID controller.
If the variable control period obtained in step S1 is 0.5S, the period counter must be equal to or greater than the variable control period, i.e. the system is in a steady state. The control increment of the PID controller is calculated once, and the period counter is restored to be 0. In an embodiment of the present invention, the second parameter of the PID controller may also be a difference between the measured value and the set value.
If the variable control period obtained in step S2 is 20S and the period counter is 0.5S, the period counter does not calculate the control increment of the PID controller, and the process is restarted from step S1.
S3, comparing the control increment of the PID controller calculated in the step S2 with a preset threshold value.
In the embodiment of the invention, the preset threshold is a certain proportion of incremental amplitude limiting, and preferably, the preset threshold is 1% of the incremental amplitude limiting. If the control increment is smaller than the preset threshold value, the steady-state flag bit is updated to be ON, the system is in a steady state, the control increment is also set to be 0, the output control quantity is unchanged, and the control output is not modified.
If the control increment is larger than the preset threshold value, updating the steady-state flag bit OFF, and if the system is not in a steady state, outputting the control quantity which is the accumulation of the control quantity and the control increment.
In order to ensure the safety of the output, the control increment is limited by an upper limit, namely, the control increment and the increment limiting are compared. If the control increment is larger than the increment amplitude limiting, taking the value of the increment amplitude limiting as the control increment, and accumulating the control increment with the control quantity to be used as the control quantity.
S4, repeatedly executing S1-S3.
FIG. 2 is a flow chart showing the implementation of the PID controller dynamic adjustment control period software function according to an embodiment of the invention. The method specifically comprises the following steps:
(1) And starting the PID controller to dynamically adjust the control period scanning.
(2) The variable control period is set equal to the preset control period.
(3) The steady-state cruise circulation switch is set by an operator or an engineer, if the steady-state cruise circulation switch is ON, the step 4 is switched to judge whether the current state is steady, and otherwise, the step 6 is switched to.
(4) If the steady state flag is ON, go to step 5, otherwise go to step 6.
(5) The variable control period is set equal to the system scan period.
(6) The period counter and the system scan period count up.
(7) If the period counter is larger than or equal to the variable control period, turning to the 8 th step, otherwise turning to the 17 th step.
(8) The cycle counter is cleared.
(9) And calculating PID proportion, integral and differential control increments according to a PID control algorithm, and accumulating to obtain a total control increment.
(10) If the control increment is smaller than the preset threshold value, turning to the 11 th step, otherwise turning to the 12 th step.
(11) Setting the steady state flag to ON, i.e., the control increment has been less than the preset threshold, the system is considered to be in a steady state.
(12) If the control increment is greater than the threshold, i.e., there has been a significant adjustment output, then the steady state flag is set to OFF and the system is deemed not to be in steady state.
(13) If the control increment is less than a certain threshold, the control increment is set to 0, and the control output is not modified.
(14) If the calculated control increment is larger than the increment limiting, the step 15 is carried out, otherwise, the step 16 is carried out.
(15) The control increment is set not to exceed the increment limiting.
(16) The control quantity is overlapped with the calculated control increment output.
(17) The above steps are repeatedly performed.
The foregoing has described only the basic principles and preferred embodiments of the present invention, and many variations and modifications will be apparent to those skilled in the art in light of the above description, which variations and modifications are intended to be included within the scope of the present invention.

Claims (6)

1. A method for dynamically adjusting control period of PID controller is characterized in that,
s1, updating a variable control period based ON a preset steady-state cruise switch and a steady-state mark, if the preset steady-state cruise switch is ON and the steady-state mark is ON, updating the variable control period to a system scanning period, otherwise, keeping the preset control period unchanged;
s2, determining whether to calculate a second parameter of the PID controller based on a comparison result of the first parameter and the variable control period, if the first parameter is greater than or equal to the variable control period, calculating the second parameter of the PID controller, otherwise, not executing the step S3, wherein the value of the first parameter is a value of a period counter for accumulating the scanning period of the system, and the second parameter is a control increment;
s3, comparing the calculated second parameter of the PID controller with a preset threshold, updating a steady-state mark and outputting a control quantity based ON a comparison result, and if the control increment is smaller than the preset threshold, judging that the system is in a steady state, setting the steady-state mark as ON, and keeping the output control quantity unchanged; s32, if the control increment is larger than a preset threshold, setting a steady-state flag to be OFF, judging that the system is not in a steady state, and outputting a control quantity accumulation control increment.
2. The method of claim 1, wherein the system scan period is less than a predetermined control period, and the predetermined control period is an integer multiple of the system scan period.
3. The method according to claim 1, wherein step S32 further comprises limiting the control increment to an increment limiter if the control increment is greater than a preset threshold and exceeds a preset increment limiter.
4. A method for dynamically adjusting a control period of a PID controller according to any of claims 1-3, characterized in that the second parameter comprises a difference between a measured value and a set point and a control increment.
5. The method for dynamically adjusting a control period of a PID controller according to claim 4, wherein step S3 comprises:
S31 if the average difference value between the measured value and the set value is smaller than the first preset threshold value and the maximum difference value between the measured value and the set value is smaller than the second preset threshold value in the t time period, judging that the system is in a stable state, setting a stable state mark as ON, and keeping the output control quantity unchanged;
S32 otherwise, the steady state flag is set to OFF, and if the system is judged not to be in steady state, the control quantity accumulation control increment is output.
6. The method for dynamically adjusting a control period of a PID controller according to claim 1, further comprising S4, repeating steps S1-S3.
CN202110036171.XA 2021-01-12 2021-01-12 Method for dynamically adjusting control period of PID controller Active CN112859585B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110036171.XA CN112859585B (en) 2021-01-12 2021-01-12 Method for dynamically adjusting control period of PID controller

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110036171.XA CN112859585B (en) 2021-01-12 2021-01-12 Method for dynamically adjusting control period of PID controller

Publications (2)

Publication Number Publication Date
CN112859585A CN112859585A (en) 2021-05-28
CN112859585B true CN112859585B (en) 2024-03-08

Family

ID=76002896

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110036171.XA Active CN112859585B (en) 2021-01-12 2021-01-12 Method for dynamically adjusting control period of PID controller

Country Status (1)

Country Link
CN (1) CN112859585B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5159547A (en) * 1990-10-16 1992-10-27 Rockwell International Corporation Self-monitoring tuner for feedback controller
CN102841539A (en) * 2012-09-10 2012-12-26 广东电网公司电力科学研究院 Subcritical coordinative control method based on multiple model predictive control
CN105116726A (en) * 2015-07-20 2015-12-02 宁波大学 Parameter design method for nonlinear predictive controller based on mechanism model
JP2020160550A (en) * 2019-03-25 2020-10-01 株式会社チノー Control device and control method

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5159547A (en) * 1990-10-16 1992-10-27 Rockwell International Corporation Self-monitoring tuner for feedback controller
CN102841539A (en) * 2012-09-10 2012-12-26 广东电网公司电力科学研究院 Subcritical coordinative control method based on multiple model predictive control
CN105116726A (en) * 2015-07-20 2015-12-02 宁波大学 Parameter design method for nonlinear predictive controller based on mechanism model
JP2020160550A (en) * 2019-03-25 2020-10-01 株式会社チノー Control device and control method

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
增量式PID控制在全钢内衬层生产线中的应用;吴斌;刘晶;方秀华;;橡塑技术与装备(第03期);全文 *

Also Published As

Publication number Publication date
CN112859585A (en) 2021-05-28

Similar Documents

Publication Publication Date Title
CN107036256A (en) The control method of delivery temperature, the control device of delivery temperature and air conditioner
CN101832287A (en) Method and device for speed regulation of fan and communication system
CN113189862B (en) PID control loop quality evaluation method for thermal power plant
CA2934348A1 (en) Method and regulation and/or control device for operating a wind turbine and/or a wind farm, and wind turbine and wind farm
CN112859585B (en) Method for dynamically adjusting control period of PID controller
CN108361183A (en) A kind of current protection control method and device
CN110513158B (en) Feed-forward multistage speed regulation method for steam turbine
CN113865062A (en) Control method of variable frequency air conditioner
CN116609606B (en) Railway moving ring real-time safety detection system based on artificial intelligence
CN103465794A (en) Train power supply control method and system for electric locomotives and train power supply equipment
CN114665784A (en) Predictive desaturation type PI controller and control method thereof
CN114484790B (en) Control method and control system of air conditioner and air conditioner
CN115560449A (en) Air conditioner and air conditioner compressor operation frequency adjusting method and system
US11867157B2 (en) Method of cooling a wind turbine
CN103291691B (en) A kind of hydraulic cooling system temperature control method, equipment and engineering machinery
CN111697813B (en) Frequency conversion equipment, control method and device of PFC circuit of frequency conversion equipment and storage medium
CN111306536A (en) Method and device for controlling sulfur dioxide emission of circulating fluidized bed boiler
WO2020120008A1 (en) Method and controller for full-power control of a wind turbine
CN110578051B (en) Control method of smoke exhaust fan of continuous annealing furnace
CN113890062B (en) Method for controlling primary frequency modulation power of wind generating set
CN111581601B (en) Method for saving environmental protection cost
CN114575939B (en) Method and system for switching control modes of steam turbine for nuclear power station
CN112366715B (en) Method for determining transient voltage stability control performance of generator excitation system
CN114251257B (en) Method and system for controlling rotating speed of permanent magnet condensate pump, electronic equipment and storage medium
CN113405214B (en) External fan control method and device and air conditioner

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
CB02 Change of applicant information
CB02 Change of applicant information

Country or region after: China

Address after: 310053 No. 309 Liuhe Road, Binjiang District, Hangzhou City, Zhejiang Province

Applicant after: Zhongkong Technology Co.,Ltd.

Address before: 310053 No. 309 Liuhe Road, Binjiang District, Hangzhou City, Zhejiang Province

Applicant before: ZHEJIANG SUPCON TECHNOLOGY Co.,Ltd.

Country or region before: China

GR01 Patent grant
GR01 Patent grant