Anti-saturation PI control method based on integral steady state prediction
Technical Field
The invention relates to the field of anti-saturation PI control methods, in particular to an anti-saturation PI control method based on integral steady state prediction.
Background
An electric servo drive control system is generally composed of three control loops, namely a current loop, a speed loop and a position loop. The current loop is given, namely the output of the speed controller is limited by the limitation of factors such as maximum current of the motor, output torque and the like. In addition, in a system with a large load moment of inertia such as a turntable and a radar antenna mount, in order to ensure the safety of the system, the rotation speed of a speed loop is generally set, that is, the output of a position controller is limited. Thus, nonlinear links of output amplitude limitation appear in speed and position loops, and when a given value of the loop exceeds an amplitude limiting value, the output of an upper controller is unequal to the actual input of a controlled object, so that the closed-loop performance of the whole system is affected. This phenomenon of deterioration of the system response due to input restriction is called a windup phenomenon. For the PI controller most widely used in the current servo system, the integral saturation phenomenon is a typical representative of the windup phenomenon. The integral saturation phenomenon can cause the phenomenon of overshoot increase, adjustment time extension, oscillation frequency increase and the like of a servo system under the condition of given large-amplitude mutation, and even cause the instability of the system.
The patent No. CN201610830333.6 discloses a self-adaptive passive PI control method of a grid-connected inverter system based on MMC, and the patent proposes a passive PI control method aiming at the PI control problem in the grid-connected control of a modularized multi-level inverter (MMC). By establishing a bilinear Lagrangian model and adding adaptive gain adjustment in a control method, the robustness of the control system under different load conditions is enhanced. The high-power grid-connected inverter has the advantages of simple structure and wide stability range, and is particularly suitable for the control of complex working conditions of high-power grid-connected inverters. The method is based on a specific MMC structure, depends on a bilinear Lagrangian model and a passive design, is suitable for a high-power grid-connected inversion system, but is deficient in wide applicability of a control system, and is difficult to popularize in other types of control systems. The patent number CN202210487026.8 discloses an intelligent PI control method of a double-active full-bridge converter, and the patent combines a deep reinforcement learning algorithm to provide an intelligent PI control method, and parameters of a PI controller are dynamically adjusted through a TD3 algorithm, so that the intelligent PI control method can adapt to a complex running environment and improve dynamic performance. The method overcomes the limitation of fixed parameters of the traditional PI control, and greatly improves the dynamic response speed and steady-state performance of the system. The method introduces deep reinforcement learning to realize intelligent parameter adjustment, but the method relies on a complex TD3 algorithm and a large amount of training data, so that the complexity of system realization is increased, and an application bottleneck exists for a system with high real-time requirements.
The current control method for overcoming the integral saturation phenomenon is mainly divided into two major categories, namely a conditional integral method and a tracking inverse calculation method. The condition integration method stops or limits integration according to preset conditions, and the main disadvantage of the method is lack of robustness, the switching condition is often specific to a certain fixed object, and once the object or other parameters of the system change, the method cannot inhibit the saturation phenomenon of integration, and can cause the runaway of the system. The tracking counter calculation method is to eliminate the difference between the output of the controller and the input of the controlled object as a feedback signal to form a feedback branch, and the system dynamic performance of the method is not only dependent on PI control parameters, but also is limited by tracking counter calculation parameters, but because the change of instructions and loads is not considered when designing the regulator parameters, the fixed counter calculation parameters generally have difficulty in ensuring the consistency of the system response in a large range, when the counter calculation parameters are selected too small, the integral saturation phenomenon inhibition effect is not obvious, and when the integral saturation phenomenon inhibition effect is selected too large, the system response speed is slow.
Disclosure of Invention
Aiming at the defects existing in the prior art, the invention provides an anti-saturation PI control method based on integral steady state prediction, which dynamically detects the saturation state of a controller by respectively introducing anti-saturation modules into a speed loop and a position loop, and adjusts an integral term in real time through an integral steady state prediction formula so as to avoid excessive accumulation of the integral term in the saturation state. The design of a first-order filter is combined, noise interference caused by differential operation in the prediction process is reduced, and therefore comprehensive optimization of dynamic response speed, steady-state performance and robustness is achieved. The method specifically comprises the following steps:
S1, building an anti-saturation PI control system, wherein the system comprises a speed controller and a position controller, the speed controller comprises a PI controller A and a speed loop anti-saturation module, and the position controller comprises a PI controller B and a position loop anti-saturation module;
S2, performing closed-loop control on a speed loop, and specifically comprising the following steps of:
S2-1 PI controller A has the input of speed error signal e and the output of ideal current setting u, and the calculation formula is:
u=KPSe+KISα (1)
Wherein u is an ideal current setting, K PS、KIS is a proportional coefficient and an integral coefficient of the PI controller A respectively, alpha is an integral term value of the PI controller A, e is an input error of the PI controller A, e=ω *-ω;ω* is a speed setting, and ω is an actual rotating speed;
S2-2, establishing a speed loop dynamic model which regards a current loop as a dynamic link which responds faster than the speed loop, wherein a dynamic equation is described as follows:
Wherein, Given as current, k T is the motor torque coefficient, J is the load moment of inertia, B is the viscous friction coefficient, T L is the load torque, where,The relationship with u is:
Wherein u MIN is the minimum value of the output amplitude limit of the speed loop, and u MAX is the maximum value of the output amplitude limit of the speed loop;
S2-3 when the speed loop is in steady state, i.e., ω * =ω, the dynamic equation of the speed loop dynamic model is described as:
Wherein alpha S is the integral final value of the PI controller A in steady state, and the integral steady state condition is that The calculation formula of the integral final value is as follows:
S2-4, updating a motion equation of the PI controller A when the PI controller A is saturated, wherein the calculation formula is as follows:
Wherein, Differentiating the error of the PI controller A;
S2-5, calculating an integral prediction value through an error dynamic equation and an integral prediction formula under the saturated state of the speed loop The calculation formula is as follows:
Wherein, Is a derivative term of the velocity error;
S2-6, performing a first-order filter on the steady-state predicted value of the integral term of the PI controller A to eliminate noise interference, and obtaining a calculation formula of an anti-saturation integral term alpha 1,α1 of a speed loop, wherein the calculation formula is as follows:
Wherein τ S is the speed controller integral term filter time constant;
s2-7, finally, outputting the corrected current through the speed controller The calculation formula is as follows:
S3, performing position loop closed-loop control, and specifically comprising the following steps:
S3-1, the input of the PI controller B is a position error signal E, the output is an ideal speed set v, and the calculation formula is as follows:
v=KPPE+KIPβ (11)
Wherein v is an ideal speed setting, K PP、KIP is a proportional coefficient and an integral coefficient of the PI controller B respectively, beta is an integral term of the PI controller B, E is an input error of the PI controller B, E=theta *-θ;θ* is a position setting, and theta is an actual position;
S3-2, because the dynamic response speed of the speed loop is faster than that of the position loop, approximating the speed loop to a link with a proportionality coefficient of 1, and further establishing a dynamic relation of the position loop, wherein the mathematical expression is as follows:
Wherein, The method is characterized in that actual position differentiation is carried out, ω is actual speed, ω * is speed setting, and the relationship between ω * and v is a limiting rule, and a specific calculation formula is as follows:
V MIN is the minimum value of the position loop output amplitude limit, v MAX is the maximum value of the position loop output amplitude limit;
s3-3 when the position loop reaches steady state, i.e. θ * =θ, the integral final value β P is derived by integrating steady state conditions, and the specific calculation formula is:
Wherein, Giving a derivative for the position;
S3-4, when the position loop is in a saturated state, predicting an integral steady-state value through an error dynamic model The calculation formula is as follows:
Wherein, Inputting the differential of the error to the PI controller B;
S3-5, correcting an integral term value by adopting a first-order filter to inhibit noise interference caused by error differentiation in the integral prediction process, and finally obtaining an anti-saturation integral term value beta 1, wherein the calculation formula is as follows:
Wherein τ P is the position controller integral term filter time constant;
and S3-6, finally, setting omega * for the output speed of the position controller, wherein the calculation formula is as follows:
through the steps, the anti-saturation PI control based on integral steady state prediction is completed.
As a technical preferred solution of the present invention, the anti-saturation PI control system in step S1 specifically includes:
The speed loop anti-saturation module is used for detecting the output saturation state of the PI controller A in the speed loop, and adjusting the integral term of the PI controller A under the saturation state through an integral steady state prediction formula to enable the integral term to approach to a steady state integral value, so that speed loop integral anti-saturation control is realized.
The position controller consists of a PI controller B and a position loop anti-saturation module, wherein the PI controller B is used for generating ideal speed setting according to a position error signal, and the position loop anti-saturation module is used for detecting the output saturation state of the PI controller B in a position loop and adjusting the integral term of the PI controller B under the saturation state through an integral steady state prediction formula so as to enable the integral term to approach to a steady state integral value, thereby realizing position loop integral anti-saturation control.
As a technical preferred solution of the present invention, when the PI controller a in step S2 is in different working states, the control mode of the speed loop anti-saturation module includes:
When the PI controller a is in the linear segment, i.e., u MIN<u<uMAX, the integration function works normally, and the integral term value α is obtained by error signal accumulation.
When the PI controller A is in saturation state, i.e. u > u MAX or u < u MIN, the speed loop anti-saturation module stops the integral action, and calculates the steady-state value of the integral term through the integral steady-state prediction formulaAnd the accumulated value of the integral term is adjusted to be a steady-state integral predicted value, so that the dynamic adjustment of the integral effect is realized.
As a technical preferred solution of the present invention, when the PI controller B in step S3 is in different working states, the control manner of the position loop anti-saturation module includes:
When the PI controller B is in a linear section, namely v MIN<v<vMAX, the integration function works normally, and an anti-saturation integral term value beta 1 is obtained through position error signal accumulation;
When the PI controller B is in a saturated state, namely v > v MAX or v < v MIN, the position loop anti-saturation module stops the integral action, and calculates an integral term steady state value through an integral steady state prediction formula Thereby realizing the dynamic adjustment of the integration effect.
As a technical preferred scheme of the invention, in the step S2, the speed loop anti-saturation module corrects the integral predicted value through a first order filter, and the working mechanism comprises:
When the output of the PI controller a meets u MIN<u<uMAX, the filter keeps the integral term accumulated normally, and outputs an integral value of α 1 = Σ e, wherein e = ω * - ω is a speed error;
when the output of the PI controller A meets u > u MAX or u < u MI N, the filter calculates the corrected anti-saturation integral term by integrating the steady state prediction formula Wherein, For the steady-state integral prediction value of the speed loop, τ S is a filter time constant used to suppress noise interference in the integral prediction process.
As a technical preferable scheme of the invention, in the step S3, the position loop anti-saturation module corrects the integral predicted value through a first order filter, and the working mechanism comprises:
When the output of the PI controller B meets v MIN<v<vMAX, the filter keeps the integral term to be accumulated normally, and the integral value beta 1 = [ PI ] E is output, wherein E = theta-theta is a position error;
When the output of the PI controller B meets v > v MAX or v < v MIN, the filter calculates a corrected anti-saturation integral term by an integral steady state prediction formula Wherein, For the position loop steady state integral prediction value, τ P is a filter time constant used to reduce noise interference in the integral prediction process.
Compared with the prior art, the invention has the following beneficial effects:
The invention calculates the system steady state predicted value of the integral term when the regulator is saturated, and uses the system steady state predicted value as the integral initial value when the controller recovers the linear section, thereby effectively inhibiting the accumulation effect caused by integral saturation and obviously improving the dynamic response and steady state performance of the system.
The method of the invention enables the response curve of the system to approach the optimal characteristic by adjusting the integral initial value under the condition of accurate system parameters so as to realize the rapid convergence and accurate adjustment of the control system under the complex operation condition and greatly improve the overall performance of the control system.
The method only adjusts the integral initial value when the controller is switched from the nonlinear state to the linear state, and does not change the dynamic characteristics and design framework of the original controller, so that the original stability of the system is not negatively influenced, and the safe and reliable operation of the control system is ensured.
The method is simple and has low calculated amount, only an integral steady state prediction formula and a simple first order filter are needed to be introduced in the method for calculating and correcting the integral value, the algorithm is simple to realize, the calculation complexity is low, and the method is suitable for a control system with high real-time requirements.
Drawings
Fig. 1 is a flowchart of an anti-saturation PI control method based on integral steady state prediction provided by the invention.
Detailed Description
The invention is further illustrated by the following examples. This invention may, however, be embodied in many different forms and should not be construed as limited to the embodiments set forth herein but, on the contrary, will be apparent to those skilled in the art as providing a practical matter for use in accordance with the principles of the invention.
Embodiment 1 As shown in FIG. 1, the anti-saturation PI control method based on integral steady state prediction provided by the invention comprises the following steps:
And S1, building an anti-saturation PI control system.
An anti-saturation PI control system includes a speed controller and a position controller. The speed controller comprises a PI controller A and a speed loop anti-saturation module. The position controller comprises a PI controller B and a position loop anti-saturation module.
The speed loop anti-saturation module has the function of realizing speed loop integral anti-saturation closed-loop control.
The position loop anti-saturation module has the function of realizing position loop integral anti-saturation closed-loop control.
And S2, performing closed-loop control on the speed loop.
The PI controller a gets the ideal current given by:
u=KPSe+KISα (1)
In the formula (1), u is an ideal current, K PS、KIS is a proportional coefficient and an integral coefficient of the PI controller A respectively, alpha is an integral term of the PI controller A, e is an input error of the PI controller A, e=ω *-ω;ω* is a speed setting, and ω is an actual rotating speed.
Because the current loop bandwidth is far greater than the speed loop and the position loop bandwidth, the current loop is equivalent to a link with a proportionality coefficient of 1, and the obtained motion equation is as follows:
In the formula (2), Given as current, k T is the motor torque coefficient, J is the load moment of inertia, B is the viscous friction coefficient, T L is the load torque.
The relationship with u is:
In equation (3), u MIN is the speed loop output clipping minimum value, and u MAX is the speed loop output clipping maximum value.
When the speed loop is in steady state, e=0 and ω * =ω, we get:
In equation (5), α S is the integrated end value at the steady state of PI controller a.
From equation (4) and equation (5):
the equation of motion when PI controller a is saturated is obtained from ω=ω * -e and equation (2) as follows:
In the formula (5) of the present invention, Differential for PI controller a error.
The PI controller A integral steady state predicted value is obtained by the formula (6) and the formula (7):
When the PI controller A is in a linear section, namely u MIN<u<uMAX, the integration function works normally, and when the PI controller A is in a saturated state, namely u > u MAX or u < u MIN, the integration function is stopped, the speed loop anti-saturation module predicts the steady-state value of the integral term, and the accumulated value of the integral term is adjusted to be the integral predicted value when the speed loop is steady-state.
Because the formula (8) contains a differential term, a first-order filter is added to reduce noise interference, and a speed loop anti-saturation integral term alpha 1 is obtained:
In equation (9), τ S is the speed controller integral term filter time constant.
The final speed controller is:
and step S3, performing closed-loop control on the position loop.
The PI controller B obtains the ideal speed given by:
v=KPPE+KIPβ (11)
in the formula (11), v is an ideal speed, K PP、KIP is a proportional coefficient and an integral coefficient of the PI controller B, beta is an integral term of the PI controller B, E is an input error of the PI controller B, E=theta *-θ;θ* is a position setting, and theta is an actual position.
Since the speed loop bandwidth is far greater than the position loop bandwidth, the speed loop is equivalent to a link with a proportionality coefficient of 1, and the method comprises the following steps:
In the formula (12) of the present invention, Is differentiated for the actual position.
The relationship between ω * and v is:
In equation (13), v MIN is the position loop output clipping minimum value, and v MAX is the position loop output clipping maximum value.
When the position loop is in steady state, e=0 and θ * =θ, the integral final value is:
In the formula (14) of the present invention, The derivative is given for the position.
The integral term predicted value of the PI controller B in steady state is obtained by theta = theta * -E, a formula (12) and a formula (14):
in the formula (15) of the present invention, The differential of the error is input to PI controller B.
And stopping the integration when the PI controller B is in a saturated state, namely v > v MAX or v < v MIN, and predicting an integral term steady state value by the position loop anti-saturation module and adjusting the integral term accumulated value to be an integral predicted value when the position loop is steady.
Because the formula (15) contains a differential term, a first-order filter is added to reduce noise interference, and a position loop anti-saturation integral term beta 1 is obtained:
In equation (16), τ P is the position controller integral term filter time constant.
The final position controller is:
based on the steps, anti-saturation PI control based on integral steady state prediction is realized.
Embodiment 2. The present embodiment aims to verify the actual effect of the anti-saturation PI control method based on integral steady state prediction in a motor driving system, and analyze the improvement degree of dynamic response, steady state error and robustness in the saturated state by comparing the control performance of the conventional PI control method with the control performance of the method.
The experimental platform adopts a three-phase asynchronous motor with rated power of 2.2kW, and builds a closed-loop control system comprising a speed control loop and a position control loop. The controller is realized by adopting a DSP (model TMS320F 28335), and the sampling period is 1ms. And a load simulation device is added into the system, and the response performance of the control system is tested by setting different load torques and dynamic instructions. The key control parameters set in the experiment are shown in table 1:
TABLE 1 Critical control parameters
| Control parameters |
Sign symbol |
Value of |
Unit (B) |
| Proportional coefficient of PI controller A |
KPS |
5 |
- |
| Integral coefficient of PI controller a |
KIS |
0.1 |
- |
| Proportional coefficient of PI controller B |
KPP |
8 |
- |
| Integral coefficient of PI controller B |
KIP |
0.2 |
- |
| Speed loop output limit range |
[uMIN,uMAX] |
[-10,10] |
A |
| Position loop output limit range |
[vMIN,vMAX] |
[-5,5] |
rad/s |
| Time constant of filter |
τS,τP |
0.05 |
s |
The experiment is tested by adopting the traditional PI control method and the method of the invention respectively. In the test, two different conditions were set:
and under the first working condition, a steady-state instruction response test is performed, a speed instruction is set to 1500rpm, a position instruction is set to 30rad, and the dynamic response process from an initial static state to a steady state of the system and the steady-state error performance of the system under load disturbance are observed.
And the second working condition is that the dynamic instruction responds to the test, the speed instruction is set to be suddenly changed from 1500rpm to 1800rpm, the position instruction is suddenly changed from 30rad to 50rad, and the dynamic tracking performance of the system is tested, including response time, overshoot and stabilization time.
The experimental steps include:
1. Initializing system parameters, starting an experiment platform, and respectively setting the initial values of speed and position to 0;
2. respectively using a traditional PI control method and the method of the invention to run experiments under the first working condition and the second working condition, and recording a dynamic response curve and steady-state data;
3. comparing the performance of different methods in terms of dynamic response and steady state error, collating experimental data and generating a comparison table.
Condition one steady state instruction response test
The speed and position response curves of the system from an initial rest state to steady state were recorded in the experiment. The performance of the comparison of the conventional PI control method with the method of the present invention is shown in the following table:
TABLE 2 Experimental comparison results 1
| Test index |
Traditional PI control method |
The method of the invention |
Improvement rate |
| Speed steady state error (rpm) |
10 |
0.5 |
95% |
| Position steady state error (rad) |
0.5 |
0.02 |
96% |
| Dynamic response time(s) |
2.5 |
1.8 |
28% |
| Overshoot (%) |
15% |
5% |
67% |
It can be seen from the table that the method of the present invention is significantly superior to the conventional PI control method in terms of steady state error and dynamic response. In the speed control loop, the conventional PI control method accumulates a large integral value in a saturated state, so that a system has obvious steady-state deviation after the linear section is restored. The method adjusts the integral initial value through the integral steady state prediction formula, so that the system quickly enters a steady state, and the steady state error is reduced by 95%.
Also, in the position control loop, the method of the invention is excellent in inhibiting the integral accumulation effect of the saturated state, so that the position steady-state error is reduced from 0.5rad to 0.02rad, and the precision is improved by 96%. In addition, as the integral initial value is dynamically adjusted, the overshoot is reduced by 67%, and the dynamic response time is shortened by 28%.
Dynamic instruction response test
When the speed and position instructions are suddenly changed, the dynamic tracking curve of the system is recorded, and the response time, overshoot and final error are counted. Experimental data are shown in the following table:
TABLE 3 Experimental comparison results 2
| Test index |
Traditional PI control method |
The method of the invention |
Improvement rate |
| Speed overshoot (%) |
20% |
8% |
60% |
| Speed settling time(s) |
3 |
2 |
33% |
| Position overshoot (%) |
25% |
10% |
60% |
| Position stabilization time(s) |
4 |
2.5 |
38% |
As can be seen from the data, the conventional PI control method is easy to cause larger integration accumulation due to saturation state when processing dynamic instruction mutation, resulting in obvious overshoot phenomenon and longer settling time. By adjusting the initial value of integration, the method of the invention avoids the excessive integration accumulation effect in the saturated state, obviously reduces the overshoot and shortens the stabilizing time. In the speed control loop, overshoot was reduced from 20% to 8% and settling time was reduced from 3.0 seconds to 2.0 seconds. In the position control loop, the overshoot is reduced by 60%, and the settling time is shortened by 38%.
The experiment is further added with noise interference, and the control effect of the two methods in a noise environment is observed. The result shows that the method corrects the integral predicted value through the first-order filter, effectively inhibits the influence of noise on the system, ensures smoother system output and obviously improves the robustness. Experiments in the embodiment prove that the anti-saturation PI control method based on integral steady state prediction is remarkably superior to the traditional PI control method in dynamic response and steady state performance, and has the advantages of reducing integral accumulation effect in a saturated state, reducing steady state error, improving dynamic instruction tracking performance, shortening response time, enhancing robustness of a system and stabilizing performance in a noise interference environment.
The foregoing examples merely illustrate embodiments of the invention, which are described in more detail and are not to be construed as limiting the scope of the invention. It should be noted that it will be apparent to those skilled in the art that several variations and modifications can be made without departing from the spirit of the invention, which are all within the scope of the invention.