Direct AC / AC converter model prediction control strategy based on cuckoo algorithm
By adopting a model prediction control strategy based on the cuckoo algorithm in the direct AC/AC converter, the modulation ratio is optimized, and the problem of insufficient dynamic performance and anti-interference ability in the existing technology is solved, and better control effect and dynamic response ability are achieved.
Patent Information
- Application Number
- CN202411702178.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-26
- Publication Date
- 2025-03-07
AI Technical Summary
The existing direct AC/AC converters have shortcomings in dynamic performance and anti-interference capabilities, making it difficult to achieve optimal control results in complex applications.
The model prediction control strategy based on the cuckoo algorithm is adopted, and the state space equation of the AC/AC transformer is established, and the modulation ratio is optimized by using the cuckoo optimization algorithm to achieve the optimal control effect.
Through model prediction control strategies and cuckoo optimization algorithm, the AC/AC converter can be enabled to work in the best state, meet the power supply needs of the distribution network, and improve dynamic response capabilities and control effects.
Smart Images

Figure CN119582577A_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the technical field of power grid regulation, and in particular relates to a direct AC / AC converter model predictive control strategy based on a cuckoo algorithm. Background Art
[0002] With the rapid development of power electronic conversion technology, AC / AC converters are widely used in various fields of power electronics. Among them, "Cai Guowei, Wang Yibo, Guo Dongbo, et al. Direct AC / AC converter topology suitable for voltage amplitude bipolar regulation [J]. Electric Power Automation Equipment, 2020, 40(07): 83-88+95+89-92." A direct AC / AC converter proposed in the paper is a very representative topology in direct AC / AC converters. At present, it has many practical applications in power grids and has produced many improved related topologies. This requires it to have high reliability, stability and real-time performance, so it is very important to choose a suitable control strategy. This type of converter is analyzed and designed by transfer function in classical control theory and controlled by traditional PID controller. Although its control algorithm is simple and easy to implement, it can meet the basic stability and reliability, but its dynamic performance and anti-interference ability are not good. In some complex applications, it cannot achieve the best control effect. Summary of the invention
[0003] The purpose of the present invention is to provide a direct AC / AC converter model predictive control strategy based on the cuckoo algorithm, and adopt the cuckoo algorithm for solving, so as to obtain the optimal modulation ratio, so that the AC / AC converter works in the best state and meets the power supply needs of the distribution network.
[0004] The technical solution adopted by the present invention is a direct AC / AC converter model predictive control strategy based on the cuckoo algorithm, specifically:
[0005] S1. Select key parameters as variables, establish the sub-state space equations of each working mode of the AC / AC converter, and then use the state space averaging method to establish the total state space equation;
[0006] S2, discretizing the AC / AC converter state space equation finally obtained in step S1, and calculating the discrete prediction equation of the AC / AC converter within the future p moments predicted at moment k;
[0007] S3, define the objective function according to the performance requirements, give the constraints, and substitute the discrete prediction equation obtained in step S2 into the objective function and simplify it, finally obtaining the simplified objective function and constraints;
[0008] S4. Use the cuckoo optimization heuristic algorithm to optimize and solve the simplified objective function obtained in step S3.
[0009] The present invention is also characterized in that:
[0010] Step S1 is specifically implemented according to the following steps:
[0011] S011, selecting key parameters in the AC / AC converter as state space equation variables;
[0012] S012, establishing sub-state space equations for each working state of the AC / AC converter;
[0013] Among them, the AC / AC converter is divided into only the following four working states, and the sub-state space equations under the four working states are established for the positive half cycle respectively;
[0014] Working state 1: switch tube S2, S 2C , S 2P , S 2CP , S1 and S 1CP All are in the open state, S 1C , S 1P It is in the off state. According to the circuit path at this time, the KCL and KVL equations are listed as follows:
[0015]
[0016] Arranging formula (1) gives formula (2) as follows:
[0017]
[0018] where i L is the inductor current, V0 is the output voltage; V in is the AC input voltage; R is the resistance value of the resistor in the AC / AC converter, L is the filter inductance value of the AC / AC converter, and C is the capacitance value of the filter capacitor of the AC / AC converter;
[0019] use express X is the state variable mentioned in step S011, that is, X = [i L , V0] T , output variable Y = [i L , V0] T , simplifying equation (2) into the state equation form, as shown in equation (3):
[0020]
[0021] in:
[0022]
[0023]
[0024]
[0025] Similarly, the working state 2 is analyzed: switch tubes S1 and S 1P , S2, S 2C , S 2P , S 2CP is in the open state, and S 1CP , S 1C Turn off, and write the KCL and KVL equations according to the circuit path at this time as follows:
[0026]
[0027] For example, in the analysis process of working state 1, express X is the state variable mentioned in step S011, that is, X = [i L , V0] T , output variable Y = [i L , V0] T , formula (4) is organized into the form of the spatial state equation as follows:
[0028]
[0029] in:
[0030]
[0031]
[0032]
[0033] Working state 3: switch tubes S2, S 2C , S 2P , S 2CP , S1 and S 1CP All are in the open state, S 1C , S 1P It is in the off state. According to the circuit path at this time, the KCL and KVL equations are listed as follows:
[0034]
[0035] use express X is the state variable mentioned in step S011, that is, X = [i L , V0] T , output variable Y = [i L , V0]T , Formula (6) is organized into the state space equation form as follows (7):
[0036]
[0037] in:
[0038]
[0039] Working state 4: The switch tube turned on is: S 1CP , S 1C , S2, S 2C , S 2P , S 2CP , S1 and S 1P ;
[0040] According to the circuit path at this time, the KCL and KVL equations are written as follows:
[0041]
[0042] use express X is the state variable mentioned in step S011, that is, X = [i L , V0] T , output variable Y = [i L , V0] T , which is simplified from formula (8) to formula (9):
[0043]
[0044] in:
[0045]
[0046] Working state 1 action time is The duration of working state 2 is d2T, and the duration of working state 3 is The duration of working state 4 is (1-d1)T. Based on the idea of state space averaging, the four sub-state space equations (3), (5), (7) and (9) are weighted and added together. The weight is the ratio of the duration of each working state to the duration of a working cycle T. The total state space equation of the system at this time can be obtained as follows:
[0047]
[0048] in:
[0049]
[0050]
[0051]
[0052] Expanding equation (10) into a complete state space equation is:
[0053]
[0054] Based on equation (11), we introduce the input variable u = [d1, d2] T , the introduction process is explained by the following formula (12);
[0055]
[0056] By replacing equation (11) with equation (12), the state space equation of the AC / AC converter working state is finally obtained as follows:
[0057]
[0058] Formula (13) can be simplified as follows:
[0059]
[0060] Among them, express X is the state variable mentioned in step S011, that is, X = [i L , V0] T , output variable Y = [i L , V0] T ,i L is the inductor current, V0 is the output voltage; V in is the AC input voltage. R is the resistance value of the AC / AC converter, L is the inductance value of the AC / AC converter, and C is the capacitance value of the AC / AC converter; the values of the three matrices A, B, and C are as follows:
[0061]
[0062] Step S011 is specifically implemented according to the following steps:
[0063] The inductor current passing through the filter inductor, the output voltage at the load, the modulation ratio of the P-Leg bridge arm, the modulation ratio of the N-Leg bridge arm, and the AC input voltage are selected as key parameters. L is the inductor current, V0 is the output voltage; V in is the AC input voltage; d1 is the modulation ratio of P-Leg in the AC / AC converter, d2 is the modulation ratio of N-Leg in the AC / AC converter; the state variable is selected as X=[i L , V0] T , the input variable is u=[d1,d2]T , the output variable is Y=[i L , V0] T .
[0064] S2 is implemented in the following steps:
[0065] S021. Discretize the state space equation of the AC / AC converter, that is, equation (14), to obtain equation (15), which is written as follows:
[0066]
[0067] in T is the sampling period, A is the matrix in formula (14), B is the matrix in formula (14); C6 is the matrix in formula (14); k represents the current moment, k+1 represents the next moment, x(k) represents the value of the state variable at moment k, x(k+1) represents the value of the state variable at moment k+1, y(k+1) represents the value of the output variable at moment k+1, and u(k+1) represents the value of the input variable at moment k+1;
[0068] S022. The discrete prediction equation for the next i moments is derived from formula (15), as shown in formula (17);
[0069]
[0070] Wherein, k is the current time, x(k+i|k) represents the value of the state variable in the state space equation of the AC / AC converter predicted at time k+i at time k, y(k+i|k) represents the value of the output variable in the state space equation of the AC / AC converter predicted at time k+i at time k, u(k+i) represents the value of the control variable in the state space equation of the AC / AC converter predicted at time k+i at time k, and j is a positive integer between 1 and i;
[0071] S023. By using formula (17), select the discrete prediction equations for the future p moments predicted at time k, and write these p equations into a system of equations as shown in formula (18):
[0072]
[0073] The variables in formula (18) are replaced by symbols, where:
[0074]
[0075]
[0076] After substitution, equation (18) is organized into equation (19), and the discrete prediction equation for the future p moments predicted at moment k is obtained;
[0077]
[0078] Step S3 is specifically implemented according to the following steps:
[0079] S031. Determine the objective function;
[0080] S032. Simplify the objective function determined in S031 into a typical QP problem.
[0081] Step S031 is specifically implemented according to the following steps:
[0082] The control goal of the AC / AC converter is to ensure that the output voltage can track the expected value without error, and the waveform is as smooth as possible, and it is fast and accurate. The objective function is to solve the input variable that can minimize the error between the output voltage of the AC / AC converter and the preset voltage reference value, so the objective function is defined as follows:
[0083] J=(Y * (k)-Y(k)) T Q(Y * (k)-Y(k))+U(k) T VU(k)(20)
[0084] in:
[0085]
[0086]
[0087] In the formula, J represents the objective function, i is a positive integer between 1 and p, k is the current moment, and y is * (k+i)|k represents the output voltage system reference value of the output variable at the k+i sampling time in the state space equation of the AC / AC converter, y(k+i)|k represents the voltage prediction value of the output variable at the k+i sampling time in the state space equation of the AC / AC converter, u(k+i) represents the calculated value of the controller for the input variable at the k+i sampling time in the state space equation of the AC / AC converter at the k time; Q is the output deviation weight matrix, and V is the system control weight matrix.
[0088] Step S032 is specifically implemented according to the following steps:
[0089] Simplifying the objective function in equation (20) into a typical QP problem, equation (21) is obtained from equation (19):
[0090] Y(k)=O·(R1·x(k)+S·U(k))(21)
[0091] in:
[0092]
[0093] Use formula (21) to replace Y(k) in formula (20), and finally get formula (22):
[0094]
[0095] At this time, equation (22) only contains the input variable U(k) to be solved, and the rest are known values;
[0096] Extracting the common factors from equation (22) yields equation (23):
[0097]
[0098] Let G = 2(S T O T QOS+V),f T =2[Y * (k)-OR1*x(k)] T QOS, simplifying Equation (23) to the form in Equation (24), with the following constraints: the value range of U(k) should be between the minimum and maximum constraints;
[0099] Finally, the simplified objective function and constraints of the AC / AC converter are obtained as shown in formula (24):
[0100]
[0101] Among them, the matrices S, O, and R1 are shown in formula (18), and U min is the minimum value constraint of the input variable U(k) in the state space equation of the AC / AC converter, U max It is the maximum value constraint of the input variable U(k) in the state space equation of the AC / AC converter.
[0102] Step S4 is specifically implemented according to the following steps:
[0103] Step 1: Import the model parameters of the AC / AC converter; the model parameters are the key parameters specified in step S1, namely: inductor current, output voltage, AC input voltage, modulation ratio of P-Leg and N-Leg of the AC / AC converter, resistance value, inductance value and capacitance value;
[0104] Configure the cuckoo optimization related parameters, namely: the population size is n = 50, the population dimension is nd = 1, where the population represents the control variable, i.e. the modulation ratio; the probability that the host discovers the parasitic cuckoo egg pa = 0.25; define the objective function and its constraints, i.e., formula (24);
[0105] Step 2: Initialize the population, that is, initialize the modulation ratio, that is, U(k); according to the population parameters and constraints of Step 1, initialize a population; set the fitness value of the objective function to fitness, which is equivalent to J in formula (24); use fitness to replace J in the cuckoo algorithm; set the initial fitness value of the objective function to infinity;
[0106] Step 3: Substitute into the objective function obtained at the end of step S3, calculate the population fitness value, that is, find the value of the previous formula (24); and compare it with the fitness initialized in Step 2, that is, the infinite value. If it is less than the initial fitness, replace the corresponding item in fitness, record the value of the control variable at this time, and enter Step 4. If the population fitness value at this time is equal to or greater than the initialized fitness, it is discarded and then enter Step 4;
[0107] Step 4: Perform Levy flight, update the duty cycle value, and calculate the fitness corresponding to each duty cycle again, and compare it with the fitness obtained in Step 3. As in Step 3, use the smaller value of the two to replace the corresponding item in fitness, and record the value of the control variable at this time;
[0108] Step 5: Abandon the current population with a probability of pa = 0.25, and update it, enter Step 4 to recalculate the fitness and compare it with the last calculated fitness value;
[0109] Step 6: Finally, determine the relationship between the minimum fitness value and the set precision. The present invention requires that the solution of the equation in formula (24) should make fitness infinitely close to 0. The difference between fitness and 0 after each iteration is defined as the precision. The smaller the precision, the more perfect the final solution. Therefore, if the final fitness is greater than the precision and does not reach the upper limit of the number of iterations, jump to Step 4 to continue iterating. If it is less than the precision requirement or reaches the upper limit of the number of iterations, stop the loop and output the fiteness calculated for the last time at this time, as well as the corresponding value of the control variable U(k).
[0110] The beneficial effects of the present invention are: by establishing a discrete prediction model of the AC / AC converter, adopting a model prediction control strategy (hereinafter referred to as MPC control strategy), setting a suitable value function, and using the cuckoo algorithm for solving, the optimal modulation ratio can be obtained, so that the AC / AC converter works in the best state and meets the power supply needs of the distribution network. Various constraints can be systematically processed, the dynamic response capability of the system can be improved, the control effect is good, and the robustness is strong. Therefore, it is very suitable to replace the traditional PI control, so as to be applied in occasions with high real-time requirements and high dynamic response speed requirements. BRIEF DESCRIPTION OF THE DRAWINGS
[0111] Figure 1 Schematic diagram of the topological structure of the AC / AC converter in the present invention;
[0112] Figure 2 A schematic diagram of the PWM modulation strategy adopted by the AC / AC converter in the present invention;
[0113] Figure 3 This is a flow chart of the MPC control strategy adopted by AC / AC in the present invention;
[0114] Figure 4 is a flow chart of the cuckoo optimization algorithm used in the AC / AC converter of the present invention;
[0115] Figure 5 It is a schematic diagram of the overall structure of the AC / AC control strategy in the present invention;
[0116] Figure 6 This is the simulation effect diagram of the AC / AC converter using MPC control in steady-state operation;
[0117] Figure 7 This is the simulation effect diagram of the AC / AC converter using MPC control during voltage surge;
[0118] Figure 8 This is a simulation diagram of the AC / AC converter using MPC control when the voltage drops suddenly;
[0119] Fig. 9 A simulation diagram showing the dynamic response speed of an AC / AC converter using MPC control. DETAILED DESCRIPTION
[0120] The present invention is described in detail below with reference to the accompanying drawings and specific embodiments.
[0121] The present invention provides a direct AC / AC converter model predictive control strategy based on the cuckoo algorithm, such as Figure 3 and Figure 5 As shown, the method may include the following steps S1-S4:
[0122] S1. Select key parameters as variables, establish the sub-state space equations of each working mode of the AC / AC converter, and then use the state space averaging method to establish the total state space equation;
[0123] S1 is implemented according to the following steps:
[0124] S011, selecting key parameters in the AC / AC converter as state space equation variables;
[0125] AC / AC converter topology diagram Figure 1 As shown, Figure 1 The AC / AC converter is an H-bridge structure consisting of two bridge arms, where each bridge arm constituting the H-bridge is defined as a positive polarity bridge arm (P-Leg) and a negative polarity bridge arm (N-Leg). Both bridge arms are two-level non-differential AC chopper bridge arms, and each bridge arm is composed of four IGBT switches and a capacitor for absorbing energy in the stray inductance of the line. 1P , S2, S 2C , S 2P , S 2CP , S 1CP , S 1C The eight IGBT switches of the AC / AC converter are used. C1 and C2 are capacitors for absorbing stray inductance energy. In addition, in order to ensure the quality of the input voltage and reduce the impact of grid harmonics on the converter, an absorption capacitor C is added on the input side of the converter. in . C f is the filter capacitor, L f is the filter inductor. R is the resistive load.
[0126] The inductor current passing through the filter inductor, the output voltage at the load, the modulation ratio of the P-Leg bridge arm, the modulation ratio of the N-Leg bridge arm, and the AC input voltage are selected as key parameters. L is the inductor current, V0 is the output voltage; V in is the AC input voltage; d1 is the modulation ratio of P-Leg in the AC / AC converter, d2 is the modulation ratio of N-Leg in the AC / AC converter; the state variable is selected as X=[i L , V0] T , the input variable is u=[d1,d2] T , the output variable is Y=[i L , V0] T ;
[0127] S012, establishing sub-state space equations for each working state of the AC / AC converter;
[0128] The PWM modulation strategy adopted by AC / AC converter is as follows Figure 2 ;
[0129] Depend on Figure 2 It can be seen that the AC / AC converter adopts the PWM modulation strategy. This modulation principle takes into account the input side voltage V in The sign of V is introduced in the modulation process. inComparison, a 50Hz square wave signal is generated; d1 is the modulation ratio of P-Leg in the AC / AC converter, d2 is the modulation ratio of N-Leg in the AC / AC converter, the existence of the two modulation ratios increases the controllable freedom and working mode of the AC / AC converter; U c represents a triangular carrier wave with a peak value of 0 to 1. The two bridge arms use the same triangular carrier wave. The modulation process is: the input voltage V in Comparing with 0 potential generates a 50Hz square wave signal T1, and comparing the modulated wave with the triangular carrier generates a square wave signal T2. The two square wave signals are operated by the NOT gate and the OR gate to generate the corresponding PWM drive signal, which drives the corresponding switch tube to turn on or off;
[0130] Based on this, the switch on and off conditions in Table 1 are obtained, where the switch is on when the state is 1 and off when the state is 0. In the positive half cycle of the alternating current, the switch states of the eight switch tubes are used as the basis for judgment, and the working states of the AC / AC converter are divided into four, as shown in Table 1;
[0131] Table 1 The state of the switch tube in each working state of AC / AC converter
[0132]
[0133] Although the AC / AC converter used in this control strategy has different switching conditions in the positive and negative half cycles of the alternating current, the sub-state space equations are the same and are also divided into four working states, and are exactly the same as the mathematical expressions of the positive half cycle. Therefore, the positive and negative half cycles can be regarded as the same situation. No distinction is made below. Therefore, the AC / AC converter is only divided into the following four working states, and the sub-state space equations under the four working states are established for the positive half cycle.
[0134] Working state 1: switch tube S2, S 2C , S 2P , S 2CP , S1 and S 1CP All are in the open state, S 1C , S 1P It is in the off state. According to the circuit path at this time, the KCL and KVL equations are listed as follows:
[0135]
[0136] Arranging formula (1) gives formula (2) as follows:
[0137]
[0138] where i L is the inductor current, V0 is the output voltage; V inis the AC input voltage; R is the resistance value of the resistor in the AC / AC converter, L is the filter inductance value of the AC / AC converter, and C is the capacitance value of the filter capacitor of the AC / AC converter;
[0139] use express X is the state variable mentioned in step S011, that is, X = [i L , V0] T , output variable Y = [i L , V0] T , simplifying equation (2) into the state equation form, as shown in equation (3):
[0140]
[0141] in:
[0142]
[0143] Similarly, the working state 2 is analyzed: switch tubes S1 and S 1P , S2, S 2C , S 2P , S 2CP is in the open state, and S 1CP , S 1C Turn off, and write the KCL and KVL equations according to the circuit path at this time as follows:
[0144]
[0145] For example, in the analysis process of working state 1, express X is the state variable mentioned in step S011, that is, X = [i L , V0] T , output variable Y = [i L , V0] T , formula (4) is organized into the form of the spatial state equation as follows:
[0146]
[0147] in:
[0148]
[0149] Working state 3: switch tubes S2, S 2C , S 2P , S 2CP , S1 and S 1CP All are in the open state, S 1C , S 1P It is in the off state. According to the circuit path at this time, the KCL and KVL equations are listed as follows:
[0150]
[0151] use express X is the state variable mentioned in step S011, that is, X = [i L , V0] T , output variable Y = [i L , V0] T , Formula (6) is organized into the state space equation form as follows (7):
[0152]
[0153] in:
[0154]
[0155] Working state 4: The switch tube turned on is: S 1CP , S 1C , S2, S 2C , S 2P , S 2CP , S1 and S 1P ;
[0156] According to the circuit path at this time, the KCL and KVL equations are written as follows:
[0157]
[0158] use express X is the state variable mentioned in step S011, that is, X = [i L , V0] T , output variable Y = [i L , V0] T , which is simplified from formula (8) to formula (9):
[0159]
[0160] in:
[0161]
[0162] Depend on Figure 2 The PWM modulation strategy of the AC / AC converter and the switch state in Table 1 show that the duration of working state 1 is The duration of working state 2 is d2T, and the duration of working state 3 is The duration of working state 4 is (1-d1)T. Based on the idea of state space averaging, the four sub-state space equations (3), (5), (7) and (9) are weighted and added together. The weight is the ratio of the duration of each working state to the duration of a working cycle T. The total state space equation of the system at this time can be obtained as follows:
[0163]
[0164] in:
[0165]
[0166]
[0167]
[0168] Expanding equation (10) into a complete state space equation is:
[0169]
[0170] Based on equation (11), we introduce the input variable u = [d1, d2] T , the introduction process is explained by the following formula (12);
[0171]
[0172] By replacing equation (11) with equation (12), the state space equation of the AC / AC converter working state is finally obtained as follows:
[0173]
[0174] Formula (13) can be simplified as follows:
[0175]
[0176] Among them, express X is the state variable mentioned in step S011, that is, X = [i L , V0] T , output variable Y = [i L , V0] T ,i L is the inductor current, V0 is the output voltage; V in is the AC input voltage. R is the resistance value of the AC / AC converter, L is the inductance value of the AC / AC converter, and C is the capacitance value of the AC / AC converter; the values of the three matrices A, B, and C are as follows:
[0177]
[0178] S2, discretizing the AC / AC converter state space equation finally obtained in step S1, and calculating the discrete prediction equation of the AC / AC converter within the future p moments predicted at moment k;
[0179] S2 is implemented in accordance with the following measures:
[0180] S021. Discretize the state space equation of the AC / AC converter, that is, equation (14), to obtain equation (15), which is written as follows:
[0181]
[0182] where Φ = e AT , T is the sampling period, A is the matrix in formula (14), B is the matrix in formula (14); C6 is the matrix in formula (14); k represents the current moment, k+1 represents the next moment, x(k) represents the value of the state variable at moment k, x(k+1) represents the value of the state variable at moment k+1, y(k+1) represents the value of the output variable at moment k+1, and u(k+1) represents the value of the input variable at moment k+1;
[0183] S022. The discrete prediction equation for the next i moments is derived from formula (15), as shown in formula (17);
[0184] For example, the discrete prediction equation at time k+2 can be derived from equation (15), i.e., the discrete prediction equation at time k+1, as shown in equation (16):
[0185]
[0186] This means that x(k+2) can be derived from x(k+1), x(k+3) can be derived from x(k+2), and so on, all discrete prediction equations within the next i moments can be derived;
[0187]
[0188] Wherein, k is the current time, x(k+i|k) represents the value of the state variable in the state space equation of the AC / AC converter predicted at time k+i at time k, y(k+i|k) represents the value of the output variable in the state space equation of the AC / AC converter predicted at time k+i at time k, u(k+i) represents the value of the control variable in the state space equation of the AC / AC converter predicted at time k+i at time k, and j is a positive integer between 1 and i;
[0189] S023. By using formula (17), select the discrete prediction equations for the future p moments predicted at time k, and write these p equations into a system of equations as shown in formula (18):
[0190]
[0191] The variables in formula (18) are replaced by symbols, where:
[0192]
[0193]
[0194] After substitution, equation (18) is organized into equation (19), and the discrete prediction equation for the future p moments predicted at moment k is obtained;
[0195]
[0196] S3, define the objective function according to the performance requirements, give the constraints, and substitute the discrete prediction equation obtained in step S2 into the objective function and simplify it, finally obtaining the simplified objective function and constraints;
[0197] S3 is implemented in accordance with the following measures:
[0198] S031. Determine the objective function;
[0199] The control goal of the AC / AC converter is to ensure that the output voltage can track the expected value without error, and the waveform is as smooth as possible, and it is fast and accurate. The objective function is to solve the input variable that can minimize the error between the output voltage of the AC / AC converter and the preset voltage reference value, so the objective function is defined as follows:
[0200] J=(Y * (k)-Y(k)) T Q(Y * (k)-Y(k))+U(k) T VU(k)(20)
[0201] in:
[0202]
[0203]
[0204] In the formula, J represents the objective function, i is a positive integer between 1 and p, k is the current moment, and y is *(k+i)|k represents the output voltage system reference value of the output variable at the k+i sampling time in the state space equation of the AC / AC converter, y(k+i)|k represents the voltage prediction value of the output variable at the k+i sampling time in the state space equation of the AC / AC converter, u(k+i) represents the calculated value of the controller for the input variable at the k+i sampling time in the state space equation of the AC / AC converter at the k time; Q is the output deviation weight matrix, and V is the system control weight matrix.
[0205] S032. Simplify the objective function in equation (20) into a typical QP problem, and from equation (19) we can get equation (21):
[0206] Y(k)=O·(R1·x(k)+S·U(k))(21)
[0207] in:
[0208]
[0209] Use formula (21) to replace Y(k) in formula (20), and finally get formula (22):
[0210]
[0211] At this time, equation (22) only contains the input variable U(k) to be solved, and the rest are known values;
[0212] Extracting the common factors from equation (22) yields equation (23):
[0213]
[0214] Let G = 2(S T O T QOS+V),f T =2[Y * (k)-OR1*x(k)] T QOS, simplifying Equation (23) to the form in Equation (24), with the following constraints: the value range of U(k) should be between the minimum and maximum constraints;
[0215] Finally, the simplified objective function and constraints of the AC / AC converter are obtained as shown in formula (24):
[0216]
[0217] Among them, the matrices S, O, and R1 are shown in formula (18), and U min is the minimum value constraint of the input variable U(k) in the state space equation of the AC / AC converter, U maxIt is the maximum value constraint of the input variable U(k) in the state space equation of the AC / AC converter.
[0218] S4. The cuckoo optimization heuristic algorithm is used to optimize and solve the simplified objective function obtained in step S3, namely, equation (24), and a specific algorithm flow chart is drawn as follows: Figure 5 ;
[0219] S4 is implemented in accordance with the following measures:
[0220] For the convenience of the following description, the principle, key formula, assumptions and basic steps of the cuckoo algorithm are first introduced. The present invention is carried out according to the principle, formula, assumptions and basic steps.
[0221] 1. The cuckoo algorithm was proposed based on the cuckoo's brooding behavior and the fruit fly's Lévy flight characteristics. The algorithm simulates the cuckoo's brooding behavior and combines the fruit fly's Lévy flight to find the optimal solution quickly and effectively.
[0222] The brooding behavior of cuckoos refers to placing eggs in other birds' nests and increasing the hatching probability of their own eggs by removing the host's eggs. Cuckoos themselves do not build nests, raise chicks, or hatch them. They will look for birds with similar characteristics to themselves, and when the other birds are about to hatch, they will take advantage of the other birds' absence to parasitize their eggs in the nests of others. In order to ensure that they are not discovered, they will remove one of the original eggs, so that the total number of eggs in the nest remains unchanged. Once the parasitic cuckoo is hatched, it will instinctively expel all other eggs from the nest to increase its own survival rate.
[0223] 2. To simulate the cuckoo's breeding strategy, the cuckoo search algorithm makes the following assumptions:
[0224] (1) A cuckoo lays only one egg at a time and chooses its host randomly.
[0225] (2) Among the randomly selected hosts, high-quality hosts will be retained to the next generation.
[0226] (3) The total number of available host objects is fixed. When a host finds a cuckoo egg, it will discard it or rebuild the nest. The discovery probability is Pa∈[0,1].
[0227] 3. There are several core position update formulas in the cuckoo algorithm. One is the path that the cuckoo takes to find the host to lay eggs, which is updated by using a combination of long and short step lengths in Levy flight.
[0228] Assume the location of the bird's nest is X, the population is N, the dimension of the solution space is M, and the optimal location in the current bird's nest is U n , U n =[u n1,u n2 ,...,u nM ], the historical optimal nest position is Ug, and the nth nest position is X n =[x1,x2,...,x n ], the current optimal solution U n =[u n1 ,u n2 ,...,u nM ], the historical optimal solution is U g =[u g1 ,u g2 ,...,u gM ]. Then the position update formula using Levy flight is as follows:
[0229]
[0230] Where α is the step size scaling factor, which is usually 1. β is usually 1.5. LeSy(β) is the Levy flight path. Since LeSy(β) itself does not have a clear analytical solution, but the Levy distribution exhibits power-law behavior mathematically, an approximate method can be used to generate random numbers that obey the Levy distribution. The common Mantegna method is as follows:
[0231]
[0232]
[0233] s is the generated Levy flight step length, and Γ is the gamma function.
[0234] The other is the path that the host bird takes to rebuild the nest after discovering foreign eggs with a certain probability. The location of the newly built nest is defined as follows:
[0235]
[0236] In the above formula, r, ε are random numbers that obey uniform distribution, and X i , X j For any two bird nests, pa is the probability of discovery by the host, which is usually set to 0.25. Heaviside is a step function.
[0237] 4. The basic steps of the cuckoo algorithm are as follows: Figure 4 As shown:
[0238] Step 1: Initialization. Input system parameters, define the objective function, and set parameters such as population size, search space dimension, maximum number of iterations, and accuracy.
[0239] Step 2: For each bird nest of the initialized population, solve its objective function value according to the defined objective function, and record the optimal value Ug of the current population objective function and its corresponding bird nest position.
[0240] Step 3: Perform Lévy flight on all bird nests except the optimal value, update the bird nest position, recalculate the corresponding objective function value, and then compare it with the current optimal value. If there is a better bird nest, update and replace it.
[0241] Step 4: Abandon the currently updated bird's nest with a certain probability pa and re-update the position.
[0242] Step 5: If the current operation reaches the maximum number of iterations or meets the accuracy requirements, exit the loop; otherwise, continue iterating and go to Step 3.
[0243] Step 6: Output the global optimal value;
[0244] The cuckoo algorithm is used to solve the objective function. According to the research content of the present invention, the specific steps are as follows:
[0245] Step 1: Import the model parameters of the AC / AC converter; the model parameters are the key parameters specified in step S1, namely: inductor current, output voltage, AC input voltage, modulation ratio of P-Leg and N-Leg of the AC / AC converter, resistance value, inductance value and capacitance value;
[0246] Configure the cuckoo optimization related parameters, namely: the population size is n = 50, the population dimension is nd = 1, where the population represents the control variable, i.e. the modulation ratio; the probability that the host discovers the parasitic cuckoo egg pa = 0.25; define the objective function and its constraints, i.e., formula (24);
[0247] Step 2: Initialize the population, that is, initialize the modulation ratio, that is, U(k); according to the population parameters and constraints of Step 1, initialize a population; set the fitness value of the objective function to fitness, which is equivalent to J in formula (24); use fitness to replace J in the cuckoo algorithm; set the initial fitness value of the objective function to infinity;
[0248] Step 3: Substitute into the objective function obtained at the end of step S3, calculate the population fitness value, that is, find the value of the previous formula (24); and compare it with the fitness initialized in Step 2, that is, the infinite value. If it is less than the initial fitness, replace the corresponding item in fitness, record the value of the control variable at this time, and enter Step 4. If the population fitness value at this time is equal to or greater than the initialized fitness, it is discarded and then enter Step 4;
[0249] Step 4: Perform Levy flight, update the duty cycle value, and calculate the fitness corresponding to each duty cycle again, and compare it with the fitness obtained in Step 3. As in Step 3, use the smaller value of the two to replace the corresponding item in fitness, and record the value of the control variable at this time;
[0250] Step 5: Abandon the current population with a probability of pa = 0.25, and update it, enter Step 4 to recalculate the fitness and compare it with the last calculated fitness value;
[0251] Step 6: Finally, determine the relationship between the minimum fitness value and the set precision. The present invention requires that the solution of the equation in formula (24) should make fitness infinitely close to 0. The difference between fitness and 0 after each iteration is defined as precision. The smaller the precision, the more perfect the final solution. Therefore, if the final fitness is greater than the precision and does not reach the upper limit of the number of iterations, jump to Step 4 to continue iterating. If it is less than the precision requirement or reaches the upper limit of the number of iterations, stop the loop, output the fiteness calculated for the last time, and the corresponding value of the control variable U(k). See the flowchart. Figure 5 .
[0252] Example 1
[0253] The research content of the present invention was built in the simulink simulation platform of matlab. The AC / AC topology structure adopts a direct AC / AC converter proposed in the paper "Cai Guowei, Wang Yibo, Guo Dongbo, et al. Direct AC / AC converter topology suitable for voltage amplitude bipolar regulation [J]. Electric Power Automation Equipment, 2020, 40(07): 83-88+95+89-92." The load resistance is 15 ohms, the filter capacitor is 20e-6 farads, and the filter inductor is 0.25e-3 Hunter. The effective value of the AC input voltage is 220 volts. The voltage swell and voltage drop experiments were carried out at 0.025s.
[0254] For specific effects, see Figure 6 ,It can be seen from the figure that when the AC / AC converter controlled by MPC is in steady state operation, the AC waveform is very ,stable and has no distortion, and the effect is good. Figure 7 and Figure 8 This is the simulation effect diagram of the AC / AC converter controlled by MPC when the reference voltage changes. Figure 7 At 0.025 seconds, the reference voltage is adjusted down by 20 volts from the original effective value of 220 volts, and the change of the system voltage is observed. It can be seen that the transition process is very smooth and rapid, and the overall waveform has no obvious distortion, which proves that this method has good practicality, can accurately and quickly output the system reference voltage, and the dynamic process is stable and the response is rapid. Figure 8 At 0.025 seconds, the AC output voltage is 220 volts, the system reference voltage is 200 volts, and at 0.025 seconds, the reference voltage is increased by 20 volts to observe the change in system voltage. The transition process is also very smooth, and the overall waveform has no obvious distortion, which proves that this method has good practicality. Fig. 9 It can be seen that after adopting the model predictive control strategy, the AC / AC converter used in the present invention completes the adjustment within two milliseconds after the voltage is reduced and returns to a stable state, with good dynamic response speed and high accuracy.
Claims
1. A direct AC / AC converter model predictive control strategy based on the cuckoo algorithm, characterized in that: Specifically: S1. Select key parameters as variables, establish the sub-state space equations of each working mode of the AC / AC converter, and then use the state space averaging method to establish the total state space equation; S2, discretizing the AC / AC converter state space equation finally obtained in step S1, and calculating the discrete prediction equation of the AC / AC converter within the future p moments predicted at moment k; S3, define the objective function according to the performance requirements, give the constraints, and substitute the discrete prediction equation obtained in step S2 into the objective function and simplify it, finally obtaining the simplified objective function and constraints; S4. Use the cuckoo optimization heuristic algorithm to optimize and solve the simplified objective function obtained in step S3.
2. The direct AC / AC converter model predictive control strategy based on the cuckoo algorithm according to claim 1 is characterized in that: Step S1 is specifically implemented according to the following steps: S011, selecting key parameters in the AC / AC converter as state space equation variables; S012, establishing sub-state space equations for each working state of the AC / AC converter; Among them, the AC / AC converter is divided into only the following four working states, and the sub-state space equations under the four working states are established for the positive half cycle respectively; Working state 1: switch tube S2, S 2C , S 2P , S 2CP , S1 and S 1CP All are in the open state, S 1C , S 1P It is in the off state. According to the circuit path at this time, the KCL and KVL equations are listed as follows: Arranging formula (1) gives formula (2) as follows: where i L is the inductor current, V0 is the output voltage; V in is the AC input voltage; R is the resistance value of the resistor in the AC / AC converter, L is the filter inductance value of the AC / AC converter, and C is the capacitance value of the filter capacitor of the AC / AC converter; use express X is the state variable mentioned in step S011, that is, X = [i L , V0] T , output variable Y = [i L , V0] T , simplifying equation (2) into the state equation form, as shown in equation (3): in: Similarly, the working state 2 is analyzed: switch tubes S1 and S 1P , S2, S 2C , S 2P , S 2CP is in the open state, and S 1CP , S 1C Turn off, and write the KCL and KVL equations according to the circuit path at this time as follows: For example, in the analysis process of working state 1, express X is the state variable mentioned in step S011, that is, X = [i L , V0] T , output variable Y = [i L , V0] T , formula (4) is organized into the form of the spatial state equation as follows: in: Working state 3: switch tubes S2, S 2C , S 2P , S 2CP , S1 and S 1CP All are in the open state, S 1C , S 1P It is in the off state. According to the circuit path at this time, the KCL and KVL equations are listed as follows: use express X is the state variable mentioned in step S011, that is, X = [i L , V0] T , output variable Y = [i L , V0] T , Formula (6) is organized into the state space equation form as follows (7): in: Working state 4: The switch tube turned on is: S 1CP , S 1C , S2, S 2C , S 2P , S 2CP , S1 and S 1P ; According to the circuit path at this time, the KCL and KVL equations are written as follows: use express X is the state variable mentioned in step S011, that is, X = [i L , V0] T , output variable Y = [i L , V0] T , which is simplified from formula (8) to formula (9): in: Working state 1 action time is The duration of working state 2 is d2T, and the duration of working state 3 is The duration of working state 4 is (1-d1)T. Based on the idea of state space averaging, the four sub-state space equations (3), (5), (7) and (9) are weighted and added together. The weight is the ratio of the duration of each working state to the duration of a working cycle T. The total state space equation of the system at this time can be obtained as follows: in: Expanding equation (10) into a complete state space equation is: Based on equation (11), we introduce the input variable u = [d1, d2] T , the introduction process is explained by the following formula (12); By replacing equation (11) with equation (12), the state space equation of the AC / AC converter working state is finally obtained as follows: Formula (13) can be simplified as follows: Among them, express X is the state variable mentioned in step S011, that is, X = [i L , V0] T , output variable Y = [i L , V0] T ,i L is the inductor current, V0 is the output voltage; V in is the AC input voltage; R is the resistance value of the AC / AC converter, L is the inductance value of the AC / AC converter, and C is the capacitance value of the AC / AC converter; the values of the three matrices A, B, and C are as follows:
3. The direct AC / AC converter model predictive control strategy based on the cuckoo algorithm according to claim 2 is characterized in that: Step S011 is specifically implemented according to the following steps: The inductor current passing through the filter inductor, the output voltage at the load, the modulation ratio of the P-Leg bridge arm, the modulation ratio of the N-Leg bridge arm, and the AC input voltage are selected as key parameters. L is the inductor current, V0 is the output voltage; V in is the AC input voltage; d1 is the modulation ratio of P-Leg in the AC / AC converter, d2 is the modulation ratio of N-Leg in the AC / AC converter; the state variable is selected as X=[i L , V0] T , the input variable is u=[d1,d2] T , the output variable is Y=[i L , V0] T .
4. The direct AC / AC converter model predictive control strategy based on the cuckoo algorithm according to claim 3 is characterized in that: S2 is implemented in the following steps: S021. Discretize the state space equation of the AC / AC converter, that is, equation (14), to obtain equation (15), which is written as follows: where Φ = e AT , Y1=C6, T is the sampling period, A is the matrix in formula (14), B is the matrix in formula (14); C6 is the matrix in formula (14); k represents the current moment, k+1 represents the next moment, x(k) represents the value of the state variable at moment k, x(k+1) represents the value of the state variable at moment k+1, y(k+1) represents the value of the output variable at moment k+1, and u(k+1) represents the value of the input variable at moment k+1; S022. The discrete prediction equation for the next i moments is derived from formula (15), as shown in formula (17); Wherein, k is the current time, x(k+i|k) represents the value of the state variable in the state space equation of the AC / AC converter predicted at time k+i at time k, y(k+i|k) represents the value of the output variable in the state space equation of the AC / AC converter predicted at time k+i at time k, u(k+i) represents the value of the control variable in the state space equation of the AC / AC converter predicted at time k+i at time k, and j is a positive integer between 1 and i; S023. By using formula (17), select the discrete prediction equations for the future p moments predicted at time k, and write these p equations into a system of equations as shown in formula (18): The variables in formula (18) are replaced by symbols, where: After substitution, equation (18) is organized into equation (19), and the discrete prediction equation for the future p moments predicted at moment k is obtained; 5. The direct AC / AC converter model predictive control strategy based on the cuckoo algorithm according to claim 4 is characterized in that: Step S3 is specifically implemented according to the following steps: S031. Determine the objective function; S032. Simplify the objective function determined in S031 into a typical QP problem.
6. The direct AC / AC converter model predictive control strategy based on the cuckoo algorithm according to claim 5, characterized in that: Step S031 is specifically implemented according to the following steps: The control goal of the AC / AC converter is to ensure that the output voltage can track the expected value without error, and the waveform is as smooth as possible, and it is fast and accurate; the objective function is to solve the input variable that can minimize the error between the output voltage of the AC / AC converter and the preset voltage reference value, so the objective function is defined as follows: J=(Y * (k)-Y(k)) T Q(Y * (k)-Y(k))+U(k) T VU(k)(20) in: In the formula, J represents the objective function, i is a positive integer from 1 to p, k is the current time, and y * (k+i)|k represents the output voltage system reference value of the output variable at the k+i sampling time in the state space equation of the AC / AC converter, y(k+i)|k represents the voltage prediction value of the output variable at the k+i sampling time in the state space equation of the AC / AC converter, u(k+i) represents the calculated value of the controller for the input variable at the k+i sampling time in the state space equation of the AC / AC converter at the k time; Q is the output deviation weight matrix, and V is the system control weight matrix.
7. The direct AC / AC converter model predictive control strategy based on the cuckoo algorithm according to claim 6, characterized in that: Step S032 is specifically implemented according to the following steps: Simplifying the objective function in equation (20) into a typical QP problem, equation (21) is obtained from equation (19): Y(k)=O·(R1·x(k)+S·U(k))(21) in: Use formula (21) to replace Y(k) in formula (20), and finally get formula (22): At this time, equation (22) only contains the input variable U(k) to be solved, and the rest are known values; Extracting the common factors from equation (22) yields equation (23): Let G = 2(S T O T QOS+V),f T =2[Y * (k)-OR1*x(k)] T QOS, simplifying Equation (23) to the form in Equation (24), the constraints are: the value range of U(k) should be between the minimum and maximum constraints; Finally, the simplified objective function and constraints of the AC / AC converter are obtained as shown in formula (24): Among them, the matrices S, O, and R1 are shown in formula (18), and U min is the minimum value constraint of the input variable U(k) in the state space equation of the AC / AC converter, U max It is the maximum value constraint of the input variable U(k) in the state space equation of the AC / AC converter.
8. The direct AC / AC converter model predictive control strategy based on the cuckoo algorithm according to claim 7, characterized in that: Step S4 is specifically implemented according to the following steps: Step 1: Import the model parameters of the AC / AC converter; the model parameters are the key parameters specified in step S1, namely: inductor current, output voltage, AC input voltage, modulation ratio of P-Leg and N-Leg of the AC / AC converter, resistance value, inductance value and capacitance value; Configure the cuckoo optimization related parameters, namely: the population size is n = 50, the population dimension is nd = 1, where the population represents the control variable, i.e. the modulation ratio; the probability that the host discovers the parasitic cuckoo egg pa = 0.25; define the objective function and its constraints, i.e., formula (24); Step 2: Initialize the population, that is, initialize the modulation ratio, that is, U(k); according to the population parameters and constraints of Step 1, initialize a population; set the fitness value of the objective function to fitness, which is equivalent to J in formula (24); use fitness to replace J in the cuckoo algorithm; set the initial fitness value of the objective function to infinity; Step 3: Substitute into the objective function obtained at the end of step S3, calculate the population fitness value, that is, find the value of the previous formula (24); and compare it with the fitness initialized in Step 2, that is, the infinite value. If it is less than the initial fitness, replace the corresponding item in fitness, record the value of the control variable at this time, and enter Step 4; if the population fitness value at this time is equal to or greater than the initialized fitness, discard it and enter Step 4; Step 4: Perform Levy flight, update the duty cycle value, and calculate the fitness corresponding to each duty cycle again, and compare it with the fitness obtained in Step 3. As in Step 3, use the smaller value of the two to replace the corresponding item in fitness, and record the value of the control variable at this time; Step 5: Abandon the current population with a probability of pa = 0.25, and update it, enter Step 4 to recalculate the fitness and compare it with the last calculated fitness value; Step 6: Finally, determine the relationship between the minimum fitness value and the set precision. The present invention requires that the solution of the equation in formula (24) should make fitness infinitely close to 0. The difference between fitness and 0 after each iteration is defined as the precision. The smaller the precision, the more perfect the final solution. Therefore, if the final fitness is greater than the precision and does not reach the upper limit of the number of iterations, jump to Step 4 to continue iterating. If it is less than the precision requirement or reaches the upper limit of the number of iterations, stop the loop and output the fiteness calculated for the last time at this time, as well as the corresponding value of the control variable U(k).
