Search

CN-121386343-B - Adaptive PID control method and system based on error dynamic adjustment

CN121386343BCN 121386343 BCN121386343 BCN 121386343BCN-121386343-B

Abstract

The invention provides a self-adaptive PID control method and a self-adaptive PID control system based on error dynamic adjustment, which relate to the technical field of self-adaptive control and comprise the steps of determining an error value output by a system at each moment based on a system output value and an expected output value, obtaining a corresponding error slope based on the error value at an adjacent moment, constructing a trend factor by utilizing the error slope at the current moment and the error slope at the historical moment, executing a first adjustment strategy on an initial PID controller parameter based on the trend factor to obtain a first target parameter, determining a parameter feasible region of the first target parameter and a corresponding evaluation time window according to system characteristics and priori knowledge, constructing an error target function in each evaluation time window, searching a second target parameter which enables the error target function to be optimal in the parameter feasible region by adopting a global optimization strategy, and determining the second target parameter as the current PID controller parameter of the system.

Inventors

  • ZHANG ZHAOQIN
  • XUAN YANG
  • LI JINGHUI
  • ZHANG YIHAO

Assignees

  • 上海旷鹰赛光学科技有限公司

Dates

Publication Date
20260512
Application Date
20250924

Claims (10)

  1. 1. An adaptive PID control method based on error dynamic adjustment is characterized by comprising the following steps: Determining an error value output by the system at each moment based on the system output value and the expected output value, and determining a corresponding error slope based on the error values at adjacent moments; Constructing a trend factor by utilizing the error slope at the current moment and the error slope at the historical moment, and executing a first regulation strategy on an initial PID controller parameter based on the trend factor to obtain a first target parameter, wherein the PID controller parameter comprises a proportional coefficient, an integral coefficient and a differential coefficient; And determining a parameter feasible domain and a corresponding evaluation time window of the first target parameter according to the system characteristics and priori knowledge, constructing an error target function in each evaluation time window, searching a second target parameter which optimizes the error target function in the parameter feasible domain by adopting a global optimization strategy, and determining the second target parameter as the current PID controller parameter of the system.
  2. 2. The adaptive PID control method based on dynamic adjustment of errors according to claim 1, wherein the constructing a trend factor using the error slope at the current time and the error slope at the historical time, and performing a first adjustment strategy on the initial PID controller parameter based on the trend factor, to obtain a first target parameter, comprises: Obtaining a first influence factor based on the product of the error slope at the current time and the error slope at the previous time; and determining the sum of the first influence factor and the second influence factor as a trend factor.
  3. 3. The adaptive PID control method based on dynamic adjustment of error as claimed in claim 1, wherein the global optimization strategy comprises at least one of a particle swarm optimization algorithm, a genetic algorithm, a simulated annealing algorithm, a cross entropy method and a bayesian optimization algorithm.
  4. 4. The adaptive PID control method based on dynamic adjustment of errors as claimed in claim 1, wherein the determining the parameter feasibility domain and the corresponding evaluation time window of the first objective parameter based on the system characteristics and the a priori knowledge, constructing an error objective function within each evaluation time window, comprises: Determining a first value range of the first target parameter according to system characteristics, and reducing the first value range by combining the priori knowledge to obtain a parameter feasible region of the first target parameter, wherein the system characteristics comprise a dynamic range of a system and a limiting interval of an executing mechanism; Selecting at least one proper time period as an evaluation time window based on the dynamic characteristics of the system, wherein the dynamic characteristics comprise response time and stability time of the system; And collecting an actual output signal and an expected output signal of the system in each evaluation time window, and constructing an error objective function according to the difference between the actual output signal and the expected output signal, wherein the expected output signal is an ideal output set according to a control target of the system, the actual output signal is a real output of the system under the action of the current PID parameters, and the error objective function comprises at least one of an absolute error, a square error and a constraint penalty function.
  5. 5. The adaptive PID control method based on dynamic adjustment of an error as claimed in claim 4, wherein the step of collecting the actual output signal and the desired output signal of the system and constructing an error objective function based on the difference between the actual output signal and the desired output signal within each of the evaluation time windows comprises: The weight respectively corresponding to the absolute error, the square error and the constraint penalty function is adjusted by using a self-adaptive algorithm; an error objective function is constructed based on a weighted sum of the absolute error, the square error, and the constraint penalty function.
  6. 6. The adaptive PID control method based on dynamic adjustment of errors according to claim 1, wherein the searching for a second target parameter in the parameter feasibility domain using a global optimization strategy to optimize the error objective function, determining the second target parameter as a current PID controller parameter of the system, comprises: randomly generating a set of initial PID parameter combinations in the parameter feasible domain; and adjusting the PID parameter combination according to the error objective function, searching a parameter space near each parameter in the PID parameter combination by adopting a local search algorithm, so that the error objective function value is gradually reduced, carrying out optimization iteration by combining group learning until the maximum iteration number is reached or the error objective function value is smaller than a preset threshold, and determining the corresponding PID parameter combination as the current PID controller parameter of the system.
  7. 7. The adaptive PID control method based on dynamic adjustment of errors according to claim 1, wherein the searching for a second target parameter in the parameter feasibility domain using a global optimization strategy to optimize the error objective function, determining the second target parameter as a current PID controller parameter of the system, further comprises: establishing a parameter-error mapping mathematical model according to the system characteristics and priori knowledge, wherein the parameter-error mapping mathematical model characterizes the mapping relation between an error objective function and a first objective parameter; Updating model parameters of the parameter-error mapping mathematical model based on a recursive least squares method or an SPSA gradient approximation method, and determining a second target parameter for optimizing the error target function.
  8. 8. The self-adaptive PID control system based on the error dynamic adjustment is characterized by comprising a slope determining module, a parameter adjusting module and a parameter optimizing module, wherein, The slope determining module is configured to determine an error value output by the system at each moment based on the system output value and the expected output value, and a corresponding error slope based on the error values at adjacent moments; The parameter adjustment module is configured to construct a trend factor by using the error slope at the current moment and the error slope at the historical moment, and execute a first adjustment strategy on the initial PID controller parameter based on the trend factor to obtain a first target parameter; The parameter optimization module is configured to determine a parameter feasible domain and a corresponding evaluation time window of the first target parameter according to the system characteristics and priori knowledge, construct an error target function in each evaluation time window, search a second target parameter which optimizes the error target function in the parameter feasible domain by adopting a global optimization strategy, and determine the second target parameter as a current PID controller parameter of the system.
  9. 9. An electronic device comprising a processor and a memory, the memory having a stored computer program, wherein the computer program when executed by the processor implements the adaptive PID control method based on dynamic adjustment of errors of any of claims 1 to 7.
  10. 10. A computer storage medium having a computer program stored thereon, wherein the computer program when executed by a processor implements the adaptive PID control method based on dynamic adjustment of errors as claimed in any of claims 1 to 7.

Description

Adaptive PID control method and system based on error dynamic adjustment Technical Field The invention relates to the technical field of self-adaptive control, in particular to a self-adaptive PID control method and system based on error dynamic adjustment. Background PID (proportion-integral-derivative) control algorithm is widely applied in the field of industrial control by virtue of the characteristics of simple structure, easy realization and strong robustness. However, with the continuous improvement of the complexity of the industrial system, especially under the scenes of nonlinearity, strong disturbance, time-varying working conditions and the like, the limitation of the traditional PID control is more remarkable, and the problems of slow response, overshoot and poor robustness of the fixed-parameter PID are often caused. The computational effort and storage resources of the embedded platform are limited, and complex control strategies are difficult to deploy. The existing self-adaptive or gain scheduling methods mainly neglect trend information of errors changing along with time according to current error adjustment parameters, and lack forward looking judgment on the dynamic mode of divergence, convergence and oscillation, so that the dynamic mode is difficult to adjust in time and stably under strong disturbance or abrupt change of working conditions. In addition, the traditional online setting is easy to fall into local optimum, and experience and parameters are difficult to share among different working conditions. Disclosure of Invention In view of the above, the invention provides an adaptive PID control method and system based on dynamic adjustment of errors. The technical scheme of the invention is realized in such a way that the first aspect of the invention provides a self-adaptive PID control method based on error dynamic adjustment, which comprises the following steps: determining an error value output by the system at each moment based on the system output value and the expected output value, and corresponding error slope based on the error values at adjacent moments; Constructing a trend factor by utilizing the error slope at the current moment and the error slope at the historical moment, and executing a first regulation strategy on an initial PID controller parameter based on the trend factor to obtain a first target parameter, wherein the PID controller parameter comprises a proportional coefficient, an integral coefficient and a differential coefficient; And determining a parameter feasible domain and a corresponding evaluation time window of the first target parameter according to the system characteristics and priori knowledge, constructing an error target function in each evaluation time window, searching a second target parameter which optimizes the error target function in the parameter feasible domain by adopting a global optimization strategy, and determining the second target parameter as the current PID controller parameter of the system. On the basis of the above technical solution, preferably, the constructing a trend factor by using the error slope at the current time and the error slope at the historical time, and executing a first adjustment strategy on the initial PID controller parameter based on the trend factor, to obtain a first target parameter, includes: Obtaining a first influence factor based on the product of the error slope at the current time and the error slope at the previous time; and determining the sum of the first influence factor and the second influence factor as a trend factor. On the basis of the above technical solution, preferably, the global optimization strategy includes at least one of a particle swarm optimization algorithm, a genetic algorithm, a simulated annealing algorithm, a cross entropy method and a bayesian optimization algorithm. On the basis of the above technical solution, preferably, the determining, according to the system characteristics and the priori knowledge, the parameter feasible region of the first target parameter and the corresponding evaluation time window, and constructing an error objective function in each evaluation time window includes: Determining a first value range of the first target parameter according to system characteristics, and reducing the first value range by combining the priori knowledge to obtain a parameter feasible region of the first target parameter, wherein the system characteristics comprise a dynamic range of a system and a limiting interval of an executing mechanism; Selecting at least one proper time period as an evaluation time window based on the dynamic characteristics of the system, wherein the dynamic characteristics comprise response time and stability time of the system; And collecting an actual output signal and an expected output signal of the system in each evaluation time window, and constructing an error objective function according to the difference between the actual outpu