A data-driven optimal control method for grid-connected inverters

The data-driven DeePC optimization controller solves the problem of insufficient adaptability and stability of traditional grid-connected inverters in new power systems, realizes flexible control mode switching and multi-objective optimization, and improves the stability and dynamic response capability of the system.

CN121485159BActive Publication Date: 2026-05-08ZHEJIANG UNIV
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
ZHEJIANG UNIV
Filing Date
2026-01-08
Publication Date
2026-05-08

AI Technical Summary

Technical Problem

Traditional grid-connected inverter control strategies are poorly adaptable to new power systems, have slow response times, and lack stability. They also struggle to cope with complex and ever-changing grid environments, leading to model mismatch issues that cause oscillations and instability.

Method used

A data-driven optimal control method is adopted. By constructing a DeePC optimized controller, a predictive model is built using real-time power grid data. The frequency, voltage and power reference values ​​of the converter are dynamically adjusted. Combined with weight matrix and coupling terms, flexible control mode switching and multi-objective collaborative optimization are achieved.

Benefits of technology

It improves the adaptability and robustness of grid-connected inverters in complex power grids, enhances system stability and dynamic response capabilities, reduces reliance on precise mathematical models, and achieves seamless integration and autonomous switching with traditional controllers, adapting to power grid environments with a high proportion of renewable energy access.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121485159B_ABST
    Figure CN121485159B_ABST
Patent Text Reader

Abstract

The application discloses a data-driven optimal control method for a grid-connected inverter. The method comprises the following steps: constructing a DeePC optimization controller of the grid-connected inverter on the grid side; acquiring a data matrix of the grid-connected inverter in a preset historical period and an initial trajectory after a preset adjacent period, inputting the controller, setting parameters for different control targets and types of the grid-connected inverter, outputting an optimal input data sequence after processing, generating a sinusoidal pulse width modulation wave signal and acting on the grid-connected inverter, and realizing data-driven optimal control. The method can automatically perceive and adapt to the dynamic characteristics of the actual power grid through real-time data-driven predictive control, can present or enhance the control behavior of the grid-constructing or grid-following inverter by modifying the cost parameters, can realize multi-mode flexible, optimal and coordinated control, has excellent dynamic response and steady-state performance, is beneficial to safe and stable operation, and improves the ability to adapt to complex and variable operating conditions and power grid strength.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to an inverter control method, specifically a data-driven optimal control method for grid-connected inverters. Background Technology

[0002] In the global context of addressing climate change, there is a current need to promote the large-scale grid connection of renewable energy. Unlike traditional fossil fuel power plants that rely on synchronous generators, renewable energy is mainly connected to the grid through power electronic converters. While this shift has driven the development of clean energy, it has also brought new technological challenges.

[0003] With the large-scale integration of renewable energy into the power system, long-distance power transmission from wind power, photovoltaic, and other new energy bases via high-voltage direct current (HVDC) transmission has become the mainstream mode. However, the high proportion of power electronics in new energy units presents a significant contradiction with the weak support capacity of the power grid. Traditional converter control often employs a multi-loop control structure based on PID control, including synchronization units, outer-loop power / voltage control, and inner-loop current control. These control loops are typically tuned based on simplified power grid models (such as single-machine infinite bus systems) and remain fixed after commissioning. However, the actual power grid is a highly complex, time-varying, and often unknown dynamic system, differing significantly from the simplified model. This "model mismatch" can lead to decreased control performance or even system oscillations or instability. Existing research has shown that many small-signal oscillation problems encountered in actual wind farm operation are precisely due to the inability of controllers tuned under ideal test conditions (such as connection to an ideal voltage source) to adapt to the dynamic characteristics of the real power grid. To address this issue, researchers have attempted to use robust control or adaptive control methods to cope with the uncertainties and unknown dynamics of the power grid. However, due to the complex and variable operating conditions of the power grid, it is difficult to design a fixed controller to adapt to all possible scenarios. Summary of the Invention

[0004] To address the problems existing in the background technology, this invention provides a data-driven optimal control method for grid-connected inverters. This method can overcome the problems of poor adaptability, slow response, insufficient stability, and high cost of traditional control strategies in new power systems. By collecting grid operation data in real time, constructing a data prediction model, and solving for the optimal control sequence online, the frequency, voltage, and power reference values ​​of the inverter are dynamically adjusted. This invention can flexibly achieve smooth switching between grid-connected and grid-connected control modes, and by designing the weight matrix and coupling terms in the cost function, it accurately configures the dynamic response characteristics of active power-frequency and reactive power-voltage, effectively solving the stability problem caused by model mismatch in traditional inverter control in complex power grids, and exhibiting stronger adaptability, robustness, and comprehensive control performance.

[0005] The technical solution adopted in this invention is:

[0006] The data-driven optimal control method for grid-connected inverters of the present invention includes:

[0007] Step 1) Construct a DeePC optimized controller for the grid-connected inverter on the grid side by introducing regularization terms.

[0008] Step 2) Obtain the input and output data sequences of the grid-connected inverter for a preset historical time period and construct a data matrix. Obtain the input and output data sequences of the grid-connected inverter for a preset adjacent time period before the control time as the initial trajectory.

[0009] Step 3) Input the data matrix and initial trajectory into the DeePC optimization controller, and set different weights and coupling matrices in the DeePC optimization controller for different control objectives of the grid-connected inverter. At the same time, set different cost parameters to form different inverter types, and output the optimal input data sequence after processing.

[0010] Step 4) Obtain the frequency deviation and modulation wave signal voltage amplitude of the grid-connected inverter based on the optimal input data sequence, and then generate a sinusoidal pulse width modulation (SPWM) wave signal and apply it to the grid-connected inverter to achieve optimal data-driven control of the grid-connected inverter.

[0011] In step 1), the DeePC optimization controller is specifically as follows:

[0012]

[0013]

[0014] Where g is the decision variable to be optimized; and These are the input and output slack variables, respectively. and These are the input and output data sequences of the grid-connected inverter to be optimized, respectively. This is the set of constraints for the input and output data sequences, i.e., the upper and lower limits of the input and output data sequences; For vectors quadratic form , =u or yr, P is the cost matrix, P=R or Q. and These are the cost matrix and the penalty matrix, respectively. The second norm of vector S The square of S = or , = , To output the cost item; This is a preset reference output data sequence; For regularization terms, , and They are respectively , and The scaling factor; and These represent the first input and first output trajectories of the grid-connected inverter for a predicted historical time period. and These are the second input and second output trajectories of the grid-connected inverter for predicting historical time periods, respectively. and These are the preset adjacent time periods before the control time. The input and output data sequences of the grid-connected inverter.

[0015] The DeePC optimization controller optimizes the decision variable g and ultimately obtains the optimal input data sequence. .

[0016] The output cost term of the DeePC optimized controller Specifically as follows:

[0017]

[0018]

[0019] in, , and These are the first, second, and third weights for active power control, reactive power / voltage control, and voltage-oriented control, respectively. Let N be the frequency deviation of the grid-connected inverter at times t, t+1, ..., t+N-1, i.e. the deviation between the actual value and the reference value, and N be the length of the optimal input data sequence. and These represent the active and reactive power of the grid-connected inverter at times t, t+1, ..., t+N-1, respectively. This is an adjustable offset. and These are the preset reference active power and reactive power, respectively; It is an identity matrix of dimension N; It is a quadratic form, S = , or , It is an identity matrix with dimension 2N; and These are the first coupling matrix and the second coupling matrix, respectively; and These are the dq-axis components of the voltage at the output port of the grid-connected inverter at times t, t+1, ..., t+N-1, respectively. and These are the dq-axis components of the preset reference voltage.

[0020] In step 2), the input data sequence of the grid-connected inverter for a preset historical time period T is obtained. and output data sequence Construct the input data sequences respectively Hankel matrix and output Hankel matrix Then, the input data sequence is obtained by performing block operations separately. Constructed input data matrix and output data sequence Constructed output data matrix , , Ultimately, the first input trajectory of the grid-connected inverter for the predicted historical period is obtained. and the first output trajectory and the second input trajectory Second output trajectory ; This is a definition symbol.

[0021] Input data sequence This includes the frequency deviation of the grid-connected inverter and the amplitude of the modulated wave voltage along the dq axis, as well as the output data sequence. This includes the dq-axis components of the voltage, the dq-axis components of the current, the active power, and the reactive power at the output port of the grid-connected inverter.

[0022] In step 3), when the control objective of the grid-connected inverter is voltage-oriented control, the q-axis component of the preset reference voltage is set. And the third weight It is greater than the first preset threshold.

[0023] When the control target of the grid-connected inverter is the voltage amplitude, a second weight is set. Greater than the second preset threshold, the second coupling matrix The settings are as follows:

[0024]

[0025] in, and These are the voltage amplitude and reactive power tracking status variables, respectively. , A value of 1 indicates the tracking voltage amplitude. A value of 0 indicates that the tracking voltage amplitude is not used as a target. A value of 1 indicates tracking reactive power. A value of 0 indicates that reactive power tracking is not a target; This is the QV droop coefficient; For Kronecker product; It is an identity matrix of dimension N.

[0026] When the control target of the grid-connected inverter is active power, then the first weight is set. If the value is greater than the third preset threshold, set the first coupling matrix. as follows:

[0027] .

[0028] In step 3), the cost parameter includes a first weight. Second weight Third weight First coupling matrix Second coupling matrix and offset When the inverter type formed is a grid-connected inverter (GFL), set , =0, first coupling matrix Second coupling matrix as follows:

[0029] =

[0030] =

[0031] in, For Kronecker product; It is an identity matrix of dimension N.

[0032] When the inverter type formed is a grid-connected inverter (GFM), set First coupling matrix Second coupling matrix and offset as follows:

[0033] =

[0034] =

[0035] =

[0036]

[0037] in, To act on Discrete rocking equation operator; This is virtual inertia; This is the initial condition vector; Optimize the sampling time of the controller for DeePC; The damping coefficient; It is a backward difference operator.

[0038] This enables flexible switching between the grid-connected inverter GFL and the grid-connected inverter GFM mode.

[0039] In step 4), the optimal input data sequence includes the optimal frequency deviation of the grid-connected inverter and the amplitude of the optimal modulation wave voltage dq axis. The actual frequency of the grid-connected inverter and the phase angle of the modulation wave signal are obtained based on the optimal frequency deviation. The amplitude of the optimal modulation wave voltage dq axis and the phase angle of the modulation wave signal are subjected to Park inverse transformation to obtain the three-phase modulation wave signal. The three-phase modulation wave signal is then applied to the pulse width modulation (PWM) generator to generate a sinusoidal pulse width modulation (SPWM) wave signal, which is then applied to the grid-connected inverter.

[0040] The present invention provides a data-driven optimal control system for grid-connected inverters, comprising:

[0041] The data acquisition module is used to acquire the input and output data sequences of the grid-connected inverter for a preset historical time period and construct a data matrix, and to acquire the input and output data sequences of the grid-connected inverter for a preset adjacent time period before the control time as the initial trajectory.

[0042] The controller building module is used to build a DeePC-optimized controller for grid-connected inverters on the grid side by introducing regularization terms.

[0043] The control optimization module is used to input the data matrix and initial trajectory into the DeePC optimization controller. For different control objectives of the grid-connected inverter, different weights and coupling matrices are set in the DeePC optimization controller, and different cost parameters are set to form different inverter types. After processing, the optimal input data sequence is output.

[0044] The inverter control module is used to obtain the frequency deviation and modulation wave signal voltage amplitude of the grid-connected inverter based on the optimal input data sequence, and then generate a sinusoidal pulse width modulation (SPWM) wave signal and apply it to the grid-connected inverter to achieve optimal data-driven control of the grid-connected inverter.

[0045] The electronic device of the present invention includes: a memory and a processor coupled to each other, wherein the memory stores program data, and the processor invokes the program data to execute the method described above.

[0046] The present invention provides a computer-readable storage medium having program data stored thereon, which, when executed by a processor, implements the method described above.

[0047] The core objective of this invention is to address the multiple control challenges faced by grid-connected converters in new power systems. Traditional control architectures based on PID and fixed models suffer from severe model mismatch risks, making them ill-suited to the complex, variable, and highly uncertain operating environment of the power grid, and prone to oscillations and instability. Furthermore, traditional control structures are rigid, unable to flexibly switch between grid-connected inverter GFL and grid-connected inverter GFM modes, limiting the system's responsiveness to diverse operational demands. This invention constructs a fully data-driven predictive control architecture, achieving adaptive and optimal control of the converter solely based on real-time system operating data, completely eliminating reliance on precise mathematical models of the power grid. This method is uniformly compatible with both GFL and GFM functions, adjusting control strategies online according to system requirements, significantly enhancing the converter's adaptability and robustness under weak grid conditions and variable operating conditions. Through built-in regularization and relaxation mechanisms, noise and disturbances are effectively suppressed, improving control reliability and fundamentally overcoming the model mismatch problem.

[0048] Another important objective of this invention is to promote the transformation of the control paradigm of power electronic power systems from "model-driven" to "data-driven." By utilizing the system dynamic characteristics implicit in real-time data, multi-objective collaborative optimization decisions can be completed within milliseconds, significantly enhancing the system's ability to resist oscillations, overvoltages, and frequency instability, and providing a novel stable control solution for high-proportion renewable energy integration. This method not only significantly reduces the dependence on traditional physical models but also achieves seamless integration and autonomous switching of GFL / GFM characteristics under a single controller structure, and can be widely applied to weak grids, isolated microgrids, and highly power electronic scenarios. This invention aims to lead a profound transformation in grid control paradigms, providing core algorithmic support for building a new type of power system with high stability and high resilience. This technical path provides a disruptive control solution for the safe consumption of large-scale renewable energy and the high-quality operation of the grid, and by improving the stability of the system under all operating conditions, it provides key technical guarantees for the safe, economical, and efficient operation of future power systems.

[0049] The beneficial effects of this invention are:

[0050] The method of this invention can realize an accurate mathematical model independent of the power grid. It can automatically sense and adapt to the dynamic characteristics of the actual power grid through real-time data-driven predictive control. Under the same data-driven framework, it can present or enhance the control behavior of traditional grid-connected inverters or grid-linked inverters by simply modifying the cost function parameters. It realizes flexible, optimal and coordinated control in multiple modes, and has excellent dynamic response, steady-state performance and robustness. It is conducive to the safe and stable operation of the system and also improves the ability to adapt to complex and ever-changing operating conditions and power grid intensity.

[0051] This invention presents a data-driven global optimization control method for converters in novel power systems. The proposed DeePC control architecture achieves adaptive, robust, and optimal control of grid-connected converters without relying on precise mathematical models of the power grid. It can flexibly reproduce various operating modes, such as grid-connected inverters (GFL) and grid-connected inverters (GFM), and significantly enhances the stability and dynamic performance of the system under complex conditions such as weak grids and high interference. The method not only effectively solves the oscillation and instability problems caused by model mismatch in traditional control, but also improves anti-interference capability and steady-state accuracy through built-in regularization and rolling optimization mechanisms, while reducing dependence on external compensation equipment. This invention can promote the transformation and upgrading of power system control paradigms from "model-driven" to "data-driven," providing core support for the safe and stable operation of the power grid under high-proportion renewable energy integration, promoting the efficient consumption of clean energy and the sustainable development of novel power systems. Attached Figure Description

[0052] Figure 1 This is a schematic flowchart of the method of the present invention;

[0053] Figure 2 This is a control block diagram of the method of the present invention;

[0054] Figure 3 This is a comparison diagram of the active power and voltage amplitude waveforms of the DeePC controller of this invention and a traditional grid-connected inverter. Figure 3 (a) is a comparison of the active power response waveforms of the DeePC controller of the present invention and a traditional grid-connected inverter. Figure 3 (b) is a comparison of the output voltage amplitude response waveforms of the DeePC controller of the present invention and a traditional grid-connected inverter;

[0055] Figure 4 This is a comparison diagram of the output active power and voltage amplitude waveforms of the DeePC controller of this invention and a traditional grid-type inverter. Figure 4 (a) is a comparison of the active power response waveforms of the DeePC controller of the present invention and those of a traditional grid-connected inverter. Figure 4(b) is a comparison of the output voltage amplitude response waveforms of the DeePC controller of the present invention and the conventional grid-type inverter;

[0056] Figure 5 This is a schematic diagram of a two-zone power system with four converters according to the present invention;

[0057] Figure 6 The waveform diagram shows the active power output of the inverter in this invention. Figure 6 (a) is the output active power response waveform of the converter 3 of the present invention. Figure 6 (b) is the output active power response waveform of the converter 4 of the present invention;

[0058] Figure 7 The following are waveforms of the inverter output active power, three-phase voltage, and three-phase current of the present invention. Figure 7 (a) is a waveform diagram of the offline data collection process of the present invention. Figure 7 (b) is the active power response waveform of the inverter output of the present invention. Figure 7 Figure (c) is a diagram of the three-phase current waveform of the inverter output of the present invention. Figure 7 Figure (d) shows two waveforms of the three-phase current output of the inverter of the present invention. Figure 7 Figure (e) is a diagram of the three-phase voltage waveform of the inverter output of the present invention. Figure 7 (f) is a diagram showing the three-phase voltage waveform of the inverter output of the present invention. Detailed Implementation

[0059] The present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments.

[0060] like Figure 1 As shown, the data-driven optimal control method for grid-connected inverters of the present invention is as follows:

[0061] Step 1) Before control, it is necessary to obtain the voltage, current, and system frequency information at the output grid terminal, and then obtain the inverter's output active power and reactive power, as detailed below:

[0062] The angle of the common bus on the power grid side (system frequency) is measured using the synchronization unit module. and electric angle For grid-forming inverters (GFM), the synchronization unit achieves synchronization through simulated swing equations or droop control. For grid-following inverters (GFL), the synchronization unit is a phase-locked loop (PLL). The voltage at the inverter output port in the three-phase abc synchronous coordinate system is acquired through three-phase voltage and current transformers. Output current And by transforming them to the dq coordinate system using Park transformation, we obtain:

[0063]

[0064]

[0065] in, and The current at the inverter output port is respectively The dq axis components, and The voltages at the inverter output ports are respectively The dq axis components.

[0066] Then obtain the active power output of the inverter. reactive power ,as follows:

[0067]

[0068]

[0069] in, Indicates taking the real part; This indicates taking the imaginary part; This represents the voltage vector at the inverter output port. This represents the current vector at the inverter output port. This is a virtual part unit.

[0070] Then, a DeePC-optimized controller with regularization terms is constructed for the grid-connected inverter on the grid side, as follows:

[0071]

[0072]

[0073] Where g is the decision variable to be optimized; and These are the input and output slack variables, respectively. and These are the input and output data sequences of the grid-connected inverter to be optimized, respectively. This is the set of constraints for the input and output data sequences, i.e., the upper and lower limits of the input and output data sequences; For vectors quadratic form , =u or yr, P is the cost matrix, P=R or Q. and These are the cost matrix and the penalty matrix, respectively. The second norm of vector S The square of S = or , = , To output the cost term so that the controller exhibits the desired control effect; This is a preset reference output data sequence; For regularization terms, , , and They are respectively , and The scaling factor, through the scaling factor of the slack variable and the regularization term, provides a robustness guarantee for the DeePC control; and These represent the first input and first output trajectories of the grid-connected inverter for a predicted historical time period. and These are the second input and second output trajectories of the grid-connected inverter for predicting historical time periods, respectively. and These are the preset adjacent time periods before the control time. The input and output data sequences of the grid-connected inverter.

[0074] The DeePC optimization controller optimizes the decision variable g and ultimately obtains the optimal input data sequence. , .

[0075] In solving optimization problems, if the input / output constraint set is ignored, the solution can be obtained using the following formula. :

[0076]

[0077] in, To optimize decision variables; To be Mapped to Batch mapping matrix, This is the control matrix.

[0078] Batch mapping matrix We obtain the following by solving the system of equations:

[0079]

[0080]

[0081] in, Let be the Hessian matrix of the objective function; and For identity matrices, the subscripts indicate the dimensions; and These are the dual matrices corresponding to the slack variables.

[0082] For the control time domain In time application ,in In time At each point, repeat the above operations, that is, collect the initial trajectory and calculate the optimal input sequence.

[0083] DeePC Optimization Controller Output Cost Item Specifically as follows:

[0084]

[0085]

[0086] in, , and These are the first, second, and third weights for active power control, reactive power / voltage control, and voltage-oriented control, respectively. Let N be the frequency deviation of the grid-connected inverter at times t, t+1, ..., t+N-1, i.e. the deviation between the actual value and the reference value, and N be the length of the optimal input data sequence. and These represent the active and reactive power of the grid-connected inverter at times t, t+1, ..., t+N-1, respectively. This is an adjustable offset. and These are the preset reference active power and reactive power, respectively; It is an identity matrix of dimension N; It is a quadratic form, S = , or , It is an identity matrix with dimension 2N; and These are the first coupling matrix and the second coupling matrix, respectively. ; and These are the dq-axis components of the voltage at the output port of the grid-connected inverter at times t, t+1, ..., t+N-1, respectively. and These are the dq-axis components of the preset reference voltage.

[0087] Step 2) Obtain the input data sequence of the grid-connected inverter for the preset historical time period T. and output data sequence Construct the input data sequences respectively Hankel matrix and output Hankel matrix Then, the input data sequence is obtained by performing block operations separately. Constructed input data matrix and output data sequence Constructed output data matrix , , Ultimately, the first input trajectory of the grid-connected inverter for the predicted historical period is obtained. and the first output trajectory and the second input trajectory Second output trajectory , , , , , The column number of the Hankel matrix. , Represents the set of real numbers; This is a definition symbol.

[0088] The input of the inverter system is defined as follows: , For system frequency deviation, and These represent the amplitudes of the modulated wave voltage along the d and q axes, respectively. The system output is defined as... , which are the dq-axis components of the voltage, the dq-axis components of the current, the active power, and the reactive power at the inverter output port, respectively.

[0089] Collect preset historical time periods from the system The input and output trajectories are represented as follows: , The input data points are at times 0, 1, ..., T-1, respectively. , These represent the output data points at times 0, 1, ..., T-1, respectively. m represents the dimension of the system input u, p represents the dimension of the system output y, and the superscript d indicates data collected offline. The input trajectory is used. Construction depth is The Hankel matrix is ​​as follows:

[0090]

[0091]

[0092] in, The length of the preset adjacent time period.

[0093] Similarly, construct using the output trajectory Then the rows of the Hankel matrix are divided into data matrices.

[0094] The input and output trajectories need to be long enough and of a high enough order to fully capture the dynamic characteristics of the system, therefore they must satisfy the following conditions. And input trajectory have Rank, among which Let be the order of the system.

[0095] Simultaneously, the input and output data sequences of the grid-connected inverter in the preset adjacent time period before the control time are acquired as the initial trajectory.

[0096] Input data sequence This includes the frequency deviation of the grid-connected inverter and the amplitude of the modulated wave voltage along the dq axis, as well as the output data sequence. This includes the dq-axis components of the voltage, the dq-axis components of the current, the active power, and the reactive power at the output port of the grid-connected inverter.

[0097] Step 3) Input the data matrix and initial trajectory into the DeePC optimization controller. For different control objectives of the grid-connected inverter, set different weights and coupling matrices in the DeePC optimization controller, and set different cost parameters to form different inverter types. After processing, output the optimal input data sequence, as follows:

[0098] When the control objective of the grid-connected inverter is voltage-oriented control, the q-axis component of the preset reference voltage is set. And the third weight It is greater than a first preset threshold so that the voltage vector is aligned with the d-axis in steady state.

[0099] When the control target of the grid-connected inverter is the voltage amplitude, a second weight is set. Greater than the second preset threshold, the second coupling matrix The settings are as follows:

[0100]

[0101] in, and These are the voltage amplitude and reactive power tracking status variables, respectively. , A value of 1 indicates the tracking voltage amplitude. A value of 0 indicates that the tracking voltage amplitude is not used as a target. A value of 1 indicates tracking reactive power. A value of 0 indicates that reactive power tracking is not a target; This is the QV droop coefficient; For Kronecker product; It is an identity matrix of dimension N.

[0102] When the control target of the grid-connected inverter is active power, then the first weight is set. When the value exceeds the third preset threshold, active power tracking is achieved, and the first coupling matrix is ​​set. as follows:

[0103] .

[0104] Cost parameters include the first weight Second weight Third weight First coupling matrix Second coupling matrix and offset When the inverter type formed is a grid-connected inverter (GFL), set , =0, first coupling matrix Second coupling matrix as follows:

[0105] =

[0106] =

[0107] in, For Kronecker product; It is an identity matrix of dimension N.

[0108] When the inverter type formed is a grid-connected inverter (GFM), set First coupling matrix Second coupling matrix and offset as follows:

[0109] =

[0110] =

[0111] =

[0112]

[0113] in, To act on Discrete rocking equation operator; This is virtual inertia; This is the initial condition vector. ; Optimize the sampling time of the controller for DeePC; The damping coefficient; For backward difference operators, .

[0114] This enables flexible switching between the grid-connected inverter GFL and the grid-connected inverter GFM mode.

[0115] Step 4) Obtain the frequency deviation and modulation wave signal voltage amplitude of the grid-connected inverter based on the optimal input data sequence. The optimal input data sequence includes the optimal frequency deviation of the grid-connected inverter and the amplitude of the optimal modulation wave voltage dq axis. Obtain the actual frequency and modulation wave signal phase angle of the grid-connected inverter based on the optimal frequency deviation. Perform Park inverse transformation on the amplitude of the optimal modulation wave voltage dq axis and the modulation wave signal phase angle to obtain the three-phase modulation wave signal. Then apply the three-phase modulation wave signal to the pulse width modulation (PWM) generator to generate a sinusoidal pulse width modulation (SPWM) wave signal and apply it to the grid-connected inverter to achieve optimal data-driven control of the grid-connected inverter.

[0116] In practical implementation, to build a simulation model of a grid-connected inverter system using a data-driven optimal control method, this invention first needs to acquire the voltage, current, and system frequency information at the grid output, and then calculate the active and reactive power output of the virtual synchronous generator based on this data. On this basis, before the controller is put into operation, an input / output data sequence is collected from the target inverter system, and the data sequence is constructed into a Hankel matrix. The input data includes the system frequency deviation and the voltage amplitude of the inverter modulation signal, while the output data includes the voltage, current, output active power, and reactive power at the grid output. A DeePC optimization problem is constructed based on different control objectives. After the controller is put into operation, the input / output data is collected in real time as the initial trajectory, and the optimal input sequence is solved using the DeePC optimization problem to obtain the voltage amplitude of the modulation signal. Finally, the obtained modulation signal phase angle and voltage amplitude are combined to construct the modulation signal, thereby generating a PWM pulse modulation signal acting on the inverter, thus realizing a complete data-driven optimal control architecture design for the inverter. Specific control design details are as follows... Figure 2 As shown, Figure 2In this simulation, Voltage-Source Converter Control (VSC) and Data-enabled Predictive Control (DeePC) are employed respectively. The inverter control utilizes optimal control technology incorporating the DeePC controller. A single-unit grid-connected system simulation model is established based on the control strategy. Two different cost parameters are set to make the DeePC controller correspond to both grid-connected and grid-connected inverters. The inverter system using DeePC control is operated in grid-connected mode with a grid short-circuit ratio (SCR) of 2. At 0.5s, the active power reference value jumps from 0 to 1 per unit. At 2.5s, the grid short-circuit ratio drops to 1.67. The simulation is run, and the changes in the inverter system's output active power and voltage over time are recorded. Figure 3 and 4 As shown. Among them, It is a three-phase PWM voltage signal. and These represent the output voltage and current of the converter, respectively. For the converter-side filter inductor, For the LCL filter capacitor, For grid-side line current, This is the sum of the network test filter inductance and the transmission line inductance. For measuring the line resistance of a power grid, θ is the electrical angle, s is the complex frequency variable, and ω0 is the reference frequency. This refers to the voltage at the converter's grid connection point. and These are the dq-axis components of the modulated wave signal, respectively. , and These are the inputs to the DeePC controller. , , , , , These are the outputs of the DeePC controller.

[0117] like Figure 3 (a) and Figure 3As shown in (b), the DeePC controller operates in grid-connected inverter mode by setting cost parameters, and its control performance is compared with that of a traditional grid-connected inverter. The observation results show that the inverter using the DeePC controller responds quickly to surges in active power reference values, exhibiting good steady-state performance without significant overshoot or oscillation, while the traditional grid-connected inverter shows overshoot and oscillation. When the grid short-circuit ratio decreases, the inverter using the DeePC controller quickly returns to steady state, maintaining a smooth and stable active power response, and its voltage amplitude response also demonstrates superior performance compared to the traditional grid-connected inverter. Figure 4 (a) and Figure 4 As shown in (b), the cost parameters were modified to allow the DeePC controller to operate in grid-connected inverter mode, and its control performance was compared with that of a traditional grid-connected inverter. The results show that the inverter using the DeePC controller exhibits inertial and damping characteristics similar to the swing dynamics of a virtual synchronous machine when the active power reference value surges and the grid short-circuit ratio decreases. Furthermore, during voltage dips, its voltage amplitude recovery is faster than that of a traditional grid-connected inverter, demonstrating superior voltage source characteristics.

[0118] The simulation results above demonstrate that the DeePC controller can simulate the characteristics of grid-connected and grid-connected inverters with stronger performance. Compared with traditional inverters, it provides better power point tracking, anti-interference capability and voltage support capability, which is conducive to the safe and stable operation of the system and also improves the ability to adapt to complex and changing operating conditions and grid strength.

[0119] To further verify the effectiveness of the method of the present invention in improving the dynamic performance of the system, a two-region power system with four converters was constructed for simulation, such as... Figure 5 As shown, This represents the line susceptance between bus node i and bus node j. Four scenarios were designed: all using traditional grid-connected control; converter 3 using traditional grid-connected control, and the rest using traditional grid-connected control; converter 3 using DeePC control (considering the regulation of active and reactive power), and the rest using traditional grid-connected control; converter 3 using DeePC control (considering the regulation of active power and terminal voltage), and the rest using traditional grid-connected control. At 0.5s, the infinite bus voltage drops to 0.95 per unit value, lasting for 0.02s. Running the simulation model, the change of output active power of converters 3 and 4 (similar to converters 1 and 2) over time was obtained, as shown below. Figure 6 As shown.

[0120] like Figure 6 (a) and Figure 6As shown in (b), in case 1, all converters are controlled using traditional grid-connected control. Due to the interaction between the phase-locked loop and the weak grid, the system experiences continuous oscillations. In case 2, the oscillations are suppressed because converter 3 switches to traditional grid-connected control. In cases 3 and 4, converter 3 uses DeePC control (considering the regulation of active and reactive power or the regulation of active power and terminal voltage), and the system oscillations are also effectively suppressed. Moreover, after the disturbance, the fluctuation of the system's output active power is significantly smaller than in case 2, indicating that the performance is better than the combination of traditional grid-connected and traditional grid-connected control. This demonstrates that DeePC control (considering the regulation of active and reactive power or the regulation of active power and terminal voltage) provides stronger voltage support for the grid and can stabilize traditional grid-connected converters, exhibiting "self-stabilization" and "stabilization" capabilities. Compared with traditional methods, it has better performance, significantly enhancing the adaptability and robustness of converters under weak grids and variable operating conditions, which is beneficial to the safe and stable operation of the system and also improves the ability to adapt to complex and variable operating conditions and grid strength.

[0121] To further verify the effectiveness of the method of the present invention in improving the dynamic performance of the system, refer to... Figure 2 This invention establishes a hardware-in-the-loop simulation experiment. The platform consists of an OP5700, an NI PXIe-8840 FPGA controller, two host computers, and an oscilloscope. Three scenarios were designed: using DeePC control (considering power regulation), using traditional grid-based control, and using traditional grid-based control. At 2s, the system's active power reference value jumps from 0 to 0.5 per unit. At 5s, the infinite bus drops to 0.75 per unit and remains at that value for 0.04s. At 8s, the DeePC control switches from regulating PQ to regulating PV. Running the simulation model yields the change in the converter's active power over time, as well as the waveforms of the converter's three-phase voltage and current under DeePC control when system disturbances occur, as shown below. Figure 7 As shown.

[0122] like Figure 7 As shown in (a), the process of injecting white noise into the system to obtain the Hankel matrix is ​​as follows: Figure 7 As shown in (b), the DeePC control (considering the regulating power PQ) has the fastest active power response and the best dynamic response. It exhibits excellent anti-interference capability and robustness during sudden drops in infinite bus voltage, and the transition from PQ mode to PV mode is smooth and rapid, significantly outperforming traditional grid-following and grid-connected control. Figure 7 (c) Figure 7 of (d), Figure 7 (e) and Figure 7As shown in (f), the three-phase voltage and three-phase current waveforms demonstrate that the converter also has good transient characteristics under DeePC control, realizing flexible, optimal and coordinated control in multiple modes, and possessing excellent dynamic response, steady-state performance and robustness, thus verifying the effectiveness and correctness of the control strategy proposed in this invention.

[0123] This invention also designs a data-driven optimal control system for grid-connected inverters. The system includes a data acquisition module, a controller construction module, a control optimization module, and an inverter control module. The data acquisition module is used to acquire the input and output data sequences of the grid-connected inverter for a preset historical time period and construct a data matrix. It also acquires the input and output data sequences of the grid-connected inverter for a preset adjacent time period before the control time as the initial trajectory. The controller construction module is used to construct a DeePC optimization controller for the grid-connected inverter with regularization terms. The control optimization module is used to input the data matrix and the initial trajectory into the DeePC optimization controller. For different control objectives of the grid-connected inverter, different weights and coupling matrices are set in the DeePC optimization controller, and different cost parameters are set to form different inverter types. After processing, the optimal input data sequence is output. The inverter control module is used to obtain the frequency deviation and modulation wave signal voltage amplitude of the grid-connected inverter based on the optimal input data sequence, and then generate a sinusoidal pulse width modulation (SPWM) wave signal and apply it to the grid-connected inverter to achieve data-driven optimal control of the grid-connected inverter.

[0124] The above are merely preferred embodiments of the present invention and do not constitute any limitation on the present invention. Any equivalent substitutions or modifications made by those skilled in the art to the technical solutions and content disclosed in the present invention without departing from the scope of the present invention shall be deemed to have remained within the protection scope of the present invention.

Claims

1. A data-driven optimal control method for grid-connected inverters, characterized in that, include: Step 1) Construct the DeePC optimized controller for the grid-connected inverter on the grid side; Step 2) Obtain the input and output data sequences of the grid-connected inverter for a preset historical time period and construct a data matrix. Obtain the input and output data sequences of the grid-connected inverter for a preset adjacent time period before the control time as the initial trajectory. Step 3) Input the data matrix and initial trajectory into the DeePC optimization controller, and set different weights and coupling matrices in the DeePC optimization controller for different control objectives of the grid-connected inverter. At the same time, set different cost parameters to form different inverter types, and output the optimal input data sequence after processing. Step 4) Obtain the frequency deviation and modulation wave signal voltage amplitude of the grid-connected inverter based on the optimal input data sequence, and then generate a sinusoidal pulse width modulation (SPWM) wave signal and apply it to the grid-connected inverter to achieve optimal data-driven control of the grid-connected inverter. The DeePC optimization controller optimizes the decision variable g to obtain the optimal input data sequence. The DeePC optimization controller includes an output cost item. Specifically as follows: ; in, For vectors quadratic form , =yr, The output data sequence of the grid-connected inverter to be optimized. As a preset reference output data sequence, For the penalty matrix; , and These are the first, second, and third weights for active power control, reactive power / voltage control, and voltage-oriented control, respectively. Let N be the frequency deviation of the grid-connected inverter at times t, t+1, ..., t+N-1, and N be the length of the optimal input data sequence. and These represent the active and reactive power of the grid-connected inverter at times t, t+1, ..., t+N-1, respectively. This is the offset; and These are the preset reference active power and reactive power, respectively; It is an identity matrix of dimension N; It is a quadratic form, S = , or , It is an identity matrix with dimension 2N; and These are the first coupling matrix and the second coupling matrix, respectively; and These are the dq-axis components of the voltage at the output port of the grid-connected inverter at times t, t+1, ..., t+N-1, respectively. and These are the dq-axis components of the preset reference voltage.

2. The data-driven optimal control method for grid-connected inverters according to claim 1, characterized in that: In step 1), the DeePC optimization controller is specifically as follows: ; ; Where g is the decision variable to be optimized; and These are the input and output slack variables, respectively. and These are the input and output data sequences of the grid-connected inverter to be optimized, respectively. The set of constraints for the input and output data sequences; For vectors quadratic form , =u or yr, P is a matrix, P=R or Q. and These are the cost matrix and the penalty matrix, respectively. The second norm of vector S The square of S = or , = , To output the cost item; This is a preset reference output data sequence; For regularization terms, , and They are respectively , and The scaling factor; and These represent the first input and first output trajectories of the grid-connected inverter for a predicted historical time period. and These are the second input and second output trajectories of the grid-connected inverter for predicting historical time periods, respectively. and These are the preset adjacent time periods before the control time. The input and output data sequences of the grid-connected inverter.

3. The data-driven optimal control method for grid-connected inverters according to claim 2, characterized in that: In step 2), the input data sequence of the grid-connected inverter for a preset historical time period T is obtained. and output data sequence Construct the input data sequences respectively Hankel matrix and output Hankel matrix Then, the input data sequence is obtained by performing block operations separately. Constructed input data matrix and output data sequence Constructed output data matrix , , Ultimately, the first input trajectory of the grid-connected inverter for the predicted historical period is obtained. and the first output trajectory and the second input trajectory Second output trajectory ; For definition; Input data sequence This includes the frequency deviation of the grid-connected inverter and the amplitude of the modulated wave voltage along the dq axis, as well as the output data sequence. This includes the dq-axis components of the voltage, the dq-axis components of the current, the active power, and the reactive power at the output port of the grid-connected inverter.

4. The data-driven optimal control method for grid-connected inverters according to claim 1, characterized in that: In step 3), when the control objective of the grid-connected inverter is voltage-oriented control, the q-axis component of the preset reference voltage is set. And the third weight Greater than the first preset threshold; When the control target of the grid-connected inverter is the voltage amplitude, a second weight is set. Greater than the second preset threshold, the second coupling matrix The settings are as follows: ; in, and These are the voltage amplitude and reactive power tracking status variables, respectively. , A value of 1 indicates the tracking voltage amplitude. A value of 0 indicates that the tracking voltage amplitude is not used as a target. A value of 1 indicates tracking reactive power. A value of 0 indicates that reactive power tracking is not a target; This is the QV droop coefficient; For Kronecker product; It is an identity matrix of dimension N; When the control target of the grid-connected inverter is active power, then the first weight is set. If the value is greater than the third preset threshold, set the first coupling matrix. as follows: 。 5. The data-driven optimal control method for grid-connected inverters according to claim 1, characterized in that: In step 3), the cost parameter includes a first weight. Second weight Third weight First coupling matrix Second coupling matrix and offset When the inverter type formed is a grid-connected inverter (GFL), set , =0, first coupling matrix Second coupling matrix as follows: = ; = ; in, For Kronecker product; It is an identity matrix of dimension N; When the inverter type formed is a grid-connected inverter (GFM), set First coupling matrix Second coupling matrix and offset as follows: = ; = ; = ; ; in, To act on Discrete rocking equation operator; This is virtual inertia; This is the initial condition vector; Optimize the sampling time of the controller for DeePC; The damping coefficient; For backward difference operators; This enables flexible switching between the grid-connected inverter GFL and the grid-connected inverter GFM mode.

6. The data-driven optimal control method for grid-connected inverters according to claim 1, characterized in that: In step 4), the optimal input data sequence includes the optimal frequency deviation of the grid-connected inverter and the amplitude of the optimal modulation wave voltage dq axis. The phase angle of the modulation wave signal of the grid-connected inverter is obtained based on the optimal frequency deviation. The amplitude of the optimal modulation wave voltage dq axis and the phase angle of the modulation wave signal are subjected to Park inverse transformation to obtain the three-phase modulation wave signal. The three-phase modulation wave signal is then applied to the pulse width modulation (PWM) generator to generate a sinusoidal pulse width modulation (SPWM) wave signal, which is then applied to the grid-connected inverter.

7. An electronic device, characterized in that, include: A memory and a processor are coupled to each other, wherein the memory stores program data and the processor invokes the program data to perform the method as described in any one of claims 1-6.

8. A computer-readable storage medium storing program data thereon, characterized in that, When the program data is executed by the processor, it implements the method as described in any one of claims 1-6.

Citation Information

Patent Citations

  • Power distribution network station area inverter switching control method and system based on double-layer MPC

    CN120474091A