Two-stage reactive power flow generation method considering switching times of reactive power compensation device

A linearized integer programming model is constructed through a two-stage solution strategy to adjust the reactive output of the generator set and the switching state of the discrete reactive compensation device, which solves the problem of low efficiency of reactive power flow generation in the power system and realizes fast and feasible reactive power flow generation.

CN120728614AActive Publication Date: 2025-09-30SOUTH CHINA UNIV OF TECH
View PDF 7 Cites 0 Cited by

Patent Information

Application Number
CN202510895754.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-06-30
Publication Date
2025-09-30
Estimated Expiration
2045-06-30

AI Technical Summary

Technical Problem

Existing methods for generating reactive power flows in power systems face a contradiction between efficiency and feasibility, making it difficult to meet the requirements of new power systems for rapid generation of reactive power flows and solution feasibility. Especially in large-scale power systems, the algorithm converges slowly, takes a long time to solve, and it is difficult to ensure the feasibility of the solution results.

Method used

A two-stage solution strategy is adopted. First, the objective function is to minimize the branch active power flow deviation and the square difference of the voltage at both ends of the branch. A parallel linear integer programming model is constructed to adjust the reactive output of the generator set and the switching state of the discrete reactive compensation device. Secondly, with the goal of minimizing the active power adjustment of the generator set, the second-stage model is constructed with the first-stage result fixed to adjust the active output of the generator set to meet the AC feasibility requirements.

Benefits of technology

The complexity of solving the reactive power flow generation problem is significantly reduced, rapid convergence and feasibility are achieved, the power system's requirements for rapid generation and feasibility of reactive power flows are met, and the adjustment amount of the active output of the generator set is reduced.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120728614A_ABST
    Figure CN120728614A_ABST
Patent Text Reader

Abstract

The invention discloses a two-stage reactive power flow generation method considering the switching times of a reactive power compensation device. According to the method, a two-stage solving strategy is adopted to solve the reactive power flow generation problem considering the switching frequency limitation of the parallel reactive power compensation device, and in the first stage, the minimum branch active power flow deviation and the voltage square difference between the two ends of a branch serve as a target function; an optimization model containing constraints such as the switching frequency limitation of the discrete reactive power compensation device is constructed, linear processing is carried out, and rapid convergence of the alternating current power flow is achieved by adjusting the switching state of the reactive power compensation device; and in the second stage, fixing the switching state obtained in the first stage, and further adjusting the active output, the reactive output and the terminal voltage of the generator set by taking the minimization of the active adjustment amount of the generator set as a target function, so that the system meets the AC feasibility requirement. According to the method, the solving complexity of the reactive power flow generation problem can be remarkably reduced, the solving efficiency is improved, and the rapid generation and feasibility requirements of the reactive power flow of the power system are met.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of reactive power flow generation in power systems, and in particular relates to a two-stage reactive power flow generation method taking into account the switching times of reactive compensation devices. Background Art

[0002] With the large-scale grid connection of new energy sources and the increasing complexity of power system structures, the operation modes of power systems have become complex and diverse, and the reactive power and voltage problems of power systems have become increasingly prominent. How to quickly generate reasonable reactive power flows in the process of grid operation modes and planning schemes to ensure the convergence of AC power flows in the operation modes has become increasingly important. Due to the fact that discrete reactive compensation devices cannot be frequently switched on and off, the reactive power flow generation problem in the power grid is a large-scale complex mixed integer nonlinear programming problem with strong time coupling, which is difficult to solve directly using nonlinear programming algorithms or mainstream solvers. To ensure the efficiency of solving the reactive power flow generation problem, the common solution methods currently include: 1) intelligent optimization methods; 2) deep learning methods; 3) reinforcement learning methods; 4) linearizing the nonlinear part of the reactive power flow generation model or relaxing the discrete variables in the reactive power flow generation model, and then using mathematical optimization algorithms to solve it.

[0003] In the prior art, such as the “A distribution network voltage and reactive power control method based on DDQN algorithm” disclosed in CN116780562A, the method includes: constructing a distribution network voltage and reactive power optimization model based on the forward-backward flow calculation method; describing the distribution network voltage and reactive power optimization model as a Markov decision MDP model in the deep reinforcement learning method; constructing a deep dual-Q network DDQN algorithm architecture by introducing the Q value of the target network for evaluating the action, and using the DDQN algorithm to solve the MDP model; simulating the distribution network simulation operating environment according to historical data, training the DDQN intelligent agent and the operating environment, and making decisions on the online voltage and reactive power control of the distribution network based on the trained DDQN intelligent agent model.

[0004] In the prior art, for example, the "A method and system for dynamic reactive power optimization of an AC / DC hybrid power grid" disclosed in CN109617092 includes: collecting grid operating parameters; bringing the grid operating parameters into a pre-built and processed AC / DC dynamic reactive power optimization model for solution; and performing reactive power control on the AC / DC hybrid power grid system based on the solution result; wherein the processing of the AC / DC dynamic reactive power optimization model includes relaxing and linearizing the AC / DC dynamic reactive power optimization model based on second-order cone programming.

[0005] However, as the scale of power systems continues to expand, intelligent optimization algorithms, deep learning, and reinforcement learning methods are commonly encountered in practical applications, such as slow algorithm convergence and long solution times. Furthermore, it is difficult to effectively guarantee the feasibility of the solutions. On the other hand, while linearizing the reactive power flow generation model or relaxing discrete variables can reduce solution complexity, the lack of a subsequent feasibility correction mechanism also makes it difficult to ensure the actual feasibility of the final solution. Therefore, existing solution methods have a clear contradiction between efficiency and feasibility, making it difficult to meet the requirements of new power systems for both rapid reactive power flow generation and solution feasibility. Summary of the Invention

[0006] In order to solve the problem of low reactive power flow generation efficiency in power systems, the present invention provides a two-stage reactive power flow generation method that takes into account the switching times of reactive compensation devices.

[0007] The purpose of the present invention is achieved by at least one of the following technical solutions.

[0008] A two-stage reactive power flow generation method considering the switching times of reactive compensation devices includes the following steps:

[0009] S1, initialize the total optimization cycle episode, the optimization cycle M1_T of the first stage model M1, the maximum adjustment interval length M2_T_Max of the second stage model M2, and read the grid data and the source and load output data of each period in the total optimization cycle;

[0010] S2. Combine the source and load outputs of each time period obtained in S1 with the grid data, and perform DC power flow calculations in parallel to obtain the node voltage phase angle and branch active power flow of each time period;

[0011] S3, with M1_T as the optimization period, construct a model M with the objective function of minimizing the branch active power flow deviation and the square difference of the voltage at both ends of the branch;

[0012] S4, linearize the model M and construct the first-stage model M1;

[0013] S5. Combined with the calculation results of step S2, the model M1 is instantiated with episode / M1_T as the optimization period, and the solution is performed to obtain the switching state result of the discrete reactive compensation device;

[0014] S6. Based on the solution of S5, AC power flow calculation is performed in parallel, and whether the AC power flow calculation results of each time period meet the AC feasibility requirements is determined, and the time periods that do not meet the AC feasibility requirements are added to the adjustment set F;

[0015] S7. Determine whether the adjustment set F is empty. If so, execute step S11; if not, execute step S8.

[0016] S8. Sort the time periods in the adjustment set F in chronological order and divide them into several intervals according to whether the time periods are adjacent, and the length of each interval does not exceed M2_T_Max;

[0017] S9, taking the minimum active output adjustment of the generator set as the objective function, fixing the switching state of discrete reactive compensation devices such as shunt capacitors / reactors obtained by solving the first-stage model M1, and constructing the second-stage model M2;

[0018] S10, for each interval obtained in step S8, instantiate the second-stage model M2, while considering the ramp-up constraints between the feasible periods adjacent to the beginning and the end of the interval, and solve them in parallel;

[0019] S11. Output the solution result of the second-stage model M2 to obtain the reactive power flow configuration that meets the AC feasibility requirements.

[0020] Furthermore, in step S3, the objective function in model M is expressed as follows:

[0021]

[0022] Where NL represents the number of branches; K represents the branch set; (i, j) represents the branch with start and end nodes i and j respectively; represents the AC forward active power of branch (i, j) in time period t; represents the AC reverse active power of branch (j,i) in time period t; Indicates the forward active power of branch (i, j) calculated from the DC power flow in time period t, which is a known value. i,t represents the voltage amplitude of node i in time period t; U j,t Represents the voltage amplitude of node j in time period t. The calculation formula is as follows:

[0023]

[0024] Where G ij 、B ij Respectively represent the conductance and susceptance between node i and node j; α ij,t It represents the voltage phase angle difference between nodes i and j in time period t.

[0025] Model M includes the following constraints: 1) upper and lower limits of reactive power output of thermal power units; 2) AC power flow equation constraint; 4) node voltage amplitude constraint; 5) node voltage phase angle constraint; 6) branch transmission power constraint; 7) shunt capacitor / reactor capacity constraint; 8) total switching times of shunt capacitors / reactors constraint.

[0026] Furthermore, in step S4, the model M is linearized to simplify the mixed integer nonlinear programming model into a mixed integer linear programming model, thereby obtaining the first-stage model M1. The linearization method is as follows:

[0027] 1) Use the first-order Tailor expansion to calculate the nonlinear term U in the model M i U j cosα ij and U i U j sinα ij Perform linearization, and the linearization expression is as follows:

[0028] U i U j cosα=U i U j cosα0-U i0 U j0 αsinα0+U i0 U j0 α0sinα0

[0029] U i U j sinα=U i U j sinα0+U i0 U j0 αcosα0-U i0 U j0 α0cosα0

[0030] Where U i represents the voltage amplitude of node i; U j represents the voltage amplitude of node j; α ij represents the voltage phase angle difference between node i and node j; α ij0 Represents α ij Tailor expansion point; U i0 Indicates U i Tailor expansion point; U j0 Indicates U j Tailor expansion point.

[0031] U i U j The linearized expression of is as follows:

[0032]

[0033] 2) Mathematically, an absolute value constraint of the form |x|≤C can be equivalent to -C≤x≤C. Based on this, the absolute value constraint in model M can be removed.

[0034] Based on the above linearization method, the objective function of the first-stage model M1 is:

[0035]

[0036] Where M1_T represents the optimization period of the first-stage model M1; Z ij,t and Y ij,t are the auxiliary variables of branch (i, j) in time period t, Z ij,t The calculation formula is as follows:

[0037]

[0038] Where, The calculation formula is as follows:

[0039]

[0040] Where, α ij,t,0 is the voltage phase difference at both ends of the branch (i, j) obtained by DC power flow calculation in time period t, which is a known quantity.

[0041] Auxiliary variable Y ij,t The calculation formula is as follows:

[0042]

[0043] The constraints of the first-stage model M1 are as follows:

[0044] 1) Upper and lower limits of reactive power output of thermal power units

[0045]

[0046] Where Q G,n,min Indicates the minimum reactive power output of the nth thermal power unit; Q G,n,t represents the reactive power of the nth thermal power unit in time period t; Q G,n,max Indicates the maximum reactive power output of the nth thermal power unit.

[0047] 2) Linearized AC power flow equation constraints

[0048]

[0049] Where, P G,i,t P represents the active power output of the thermal power unit at node i in time period t; R,i,t represents the active power output of the new energy unit at node i in time period t; Q G,i,t represents the reactive power output of the thermal power unit at node i in time period t; Q C,i,t U represents the reactive compensation amount of the shunt capacitor / reactor at node i in time period t, which is a discrete variable;i,t 、U j,t They represent the voltage amplitudes of nodes i and j in time period t respectively; N represents the number of AC nodes in the system.

[0050] 4) Node voltage amplitude square constraint

[0051]

[0052] Where U i,min Indicates the minimum value of the voltage amplitude at node i; U i,max Indicates the maximum voltage amplitude at node i.

[0053] 5) Node voltage phase angle constraint

[0054]

[0055] Where θ i,min Represents the minimum value of the voltage phase angle at node i; θ i,max Represents the maximum value of the voltage phase angle at node i; θ i,t It represents the voltage phase angle of node i in time period t.

[0056] 6) Branch transmission power constraints

[0057]

[0058] Where, is the maximum transmission power of branch (i, j). 7) Shunt capacitor / reactor capacity constraint

[0059]

[0060] Where Q C,m,min Indicates the minimum value of the reactive power compensation of the mth parallel capacitor / reactor; Q C,m,max It represents the maximum reactive compensation value of the mth parallel capacitor / reactor, and NC represents the number of parallel capacitors / reactors.

[0061] 8) Constraints on the total number of switching cycles of linearized parallel capacitors / reactors

[0062]

[0063] Where, Cut_Num m Indicates the maximum number of times the mth parallel capacitor / reactor can be switched on and off within the period M1_T; X m,t It represents the auxiliary variable of the mth parallel capacitor / reactor in time period t, and its calculation formula is as follows:

[0064]

[0065] Where C n (t) represents the number of times the mth parallel capacitor / reactor is switched on and off in the t time period. When t=1, C m (t-1) = C m (0), C m (0) represents the initial switching times of the mth shunt capacitor / reactor.

[0066] Furthermore, in step S5, combined with the calculation results of step S2, the total optimization cycle is divided into episode / M1_T sub-cycles, and the model M1 is instantiated for each sub-cycle, and the Gurobi solver is used in sequence to solve the problem in series. During the solution process, the switching state of the parallel capacitor / reactor at the end of the current sub-cycle is used as the initial switching state of the parallel capacitor / reactor in the next sub-cycle.

[0067] Furthermore, in step S6, it is determined whether the AC power flow calculation results also meet the AC feasibility requirements, and the time periods that do not meet the AC feasibility requirements are added to the adjustment set F. The AC feasibility requirements include: 1) whether the node voltage amplitude is within a specified range; 2) whether the branch transmission active power is within a specified range; and 3) whether the generator reactive output is within a specified range.

[0068] Furthermore, in step S9, the objective function is to minimize the active output adjustment of the generator set, fix the switching state of the discrete reactive compensation devices such as shunt capacitors / reactors obtained by solving the first-stage model M1, and construct the second-stage model M2. The objective function expression in the second-stage model M2 is as follows:

[0069]

[0070] Where, M2_T represents the total time period for solution, NG represents the number of thermal power units; P G,n,t P represents the active power of the nth thermal power unit in the t time period; G,n,t,0 represents the initial active power of the nth thermal power unit in time period t; NR represents the number of new energy units; P R,k,t represents the active power of the kth renewable energy unit in time period t; P R,k,t,0 represents the initial active power of the kth renewable energy unit in time period t;

[0071] The second-stage model M2 includes the following constraints: 1) upper and lower limits of active power output of thermal power units; 2) upper and lower limits of reactive power output of thermal power units; 3) upper and lower limits of active power output of new energy units; 4) AC power flow equation constraints; 5) node voltage amplitude constraints; 6) node voltage phase angle constraints; 7) branch transmission power constraints; 8) thermal power unit climbing constraints.

[0072] Furthermore, in step S10, for each interval obtained in step S8, when instantiating the second-stage model M2, the climbing constraints between the feasible time periods adjacent to the beginning and the end of the interval are simultaneously considered, and then the interior point method is used for parallel solution.

[0073] The present invention also provides a computer device.

[0074] The present invention also provides a computer-readable storage medium.

[0075] Compared with the prior art, the present invention can achieve at least the following beneficial effects:

[0076] The present invention addresses the inefficiency of reactive power flow generation methods in power systems by adopting a two-stage solution strategy to solve the reactive power flow generation problem that takes into account the switching limit of parallel reactive compensation devices. First, an optimization model is constructed by minimizing the branch active power flow deviation and the square difference of the voltage across the branch as the objective function, taking into account constraints such as the switching limit of discrete reactive compensation devices. The model is then linearized to obtain a first-stage optimization model. This model achieves rapid convergence of the AC power flow by adjusting the reactive output of the generator set, the terminal voltage, and the switching state of the discrete reactive compensation device. In the second stage, the switching state of the discrete reactive compensation device obtained in the first stage is fixed, and a second-stage optimization model is constructed with minimizing the active power adjustment of the generator set as the objective function. This model adjusts the active output and reactive output of the generator set and the terminal voltage to ensure that the system meets AC feasibility requirements such as voltage safety. Solving the reactive power flow generation problem through a two-stage solution strategy can significantly reduce the solution complexity of the reactive power flow generation problem, accelerate the solution efficiency, and meet the rapid generation and feasibility requirements of the power system reactive power flow. BRIEF DESCRIPTION OF THE DRAWINGS

[0077] Figure 1 It is a flow chart of a two-stage reactive power flow generation method taking into account the switching times of reactive compensation devices provided by an embodiment of the present invention.

[0078] Figure 2 This is a modified IEEE39 node system test grid structure diagram in a two-stage reactive power flow generation method that takes into account the switching times of reactive compensation devices provided in an embodiment of the present invention.

[0079] Figure 3 It is a schematic diagram of active load curves of each node in a two-stage reactive power flow generation method taking into account the switching times of reactive compensation devices provided by an embodiment of the present invention.

[0080] Figure 4 It is a schematic diagram of active power output curves of each generator set in a two-stage reactive power flow generation method considering the switching times of reactive compensation devices provided by an embodiment of the present invention.

[0081] Figure 5 It is a schematic diagram of a switching state change curve of a parallel capacitor / reactor in a two-stage reactive power flow generation method considering the switching times of a reactive compensation device provided by an embodiment of the present invention.

[0082] Figure 6 It is a schematic diagram of a node voltage amplitude change curve in a two-stage reactive power flow generation method considering the switching times of reactive compensation devices provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0083] In order to make the purpose, technical solutions and advantages of this application more clear, the following further describes this application in detail with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain this application and are not intended to limit this application.

[0084] See also Figure 1 The two-stage reactive power flow generation method considering the switching times of reactive compensation devices provided by the embodiment of the present invention includes the following steps:

[0085] S1. Initialize the total optimization cycle episode, the optimization cycle M1_T of the first-stage model M1, and the maximum adjustment interval length M2_T_Max of the second-stage model M2, and read the grid data and the source and load output data of each period within the total optimization cycle episode.

[0086] In one embodiment of the present invention, reactive power flow is generated for the IEEE 39 node system. On the basis of the original IEEE 39 node system, the thermal power unit at node 32 is replaced by photovoltaic power generation, and the thermal power unit at node 37 is replaced by a wind turbine. The system topology is shown in FIG. Figure 2 The total optimization period episode is set to 96, the optimization period M1_T of the first stage model M1 is set to 24, and the maximum adjustment interval length M2_T_Max of the second stage model M2 is set to 4. The active load curve of each load node is shown as follows: Figure 3 As shown, the change curve of the load reactive power is the same as that of the active power, and the maximum total switching times of the parallel capacitor / reactor within 24 hours is set to 20, and the reactive power of each switching group is 5MVar.

[0087] S2. Combining the source-load output data of each time period obtained in step S1 with the grid data, performing DC power flow calculation in parallel, and obtaining the node voltage phase angle and branch active power flow of each time period.

[0088] The formula for DC power flow calculation is as follows:

[0089] P=Bθ

[0090] Where P is the injected active power vector of each node, which can be obtained from the source-load output data; B is the node admittance matrix considering only the branch reactance, which can be obtained from the grid data; θ is the voltage phase angle vector of each node.

[0091] After solving the above equation to obtain the voltage phase angle vector of each node, the active power flow of each branch can be calculated. The calculation formula is as follows:

[0092] P ij =B ij (θ i -θ j )

[0093] Where, P ij represents the active power flow of branch (i, j), B ij represents the susceptance of branch (i, j), θ i ,θ j are the voltage phase angles at node i and node j respectively.

[0094] S3. Taking the optimization period M1_T of the first-stage model M1 as the optimization period, a model M is constructed with the objective function of minimizing the branch active power flow deviation and the square difference of the voltage at both ends of the branch.

[0095] The objective function in model M is expressed as follows:

[0096]

[0097] Where NL represents the number of branches; K represents the branch set; (i, j) represents the branch with start and end nodes i and j respectively; represents the AC forward active power of branch (i, j) in time period t; represents the AC reverse active power of branch (j,i) in time period t; U represents the DC forward active power of branch (i, j) in time period t, which is a known value; i,t represents the voltage amplitude of node i in time period t; U j,t represents the voltage amplitude of node j in time period t.

[0098] in, The calculation formula is as follows:

[0099]

[0100] Where G ij 、B ij Respectively represent the conductance and susceptance between node i and node j; α ij,t It represents the voltage phase angle difference between nodes i and j in time period t.

[0101] Model M includes the following constraints:

[0102] 1) Upper and lower limits of reactive power output of thermal power units

[0103]

[0104] Where Q G,n,min Indicates the minimum reactive power output of the nth thermal power unit; Q G,n,t represents the reactive power of the nth thermal power unit in time period t; Q G,n,max It represents the maximum reactive power output of the nth thermal power unit; NG represents the number of thermal power units.

[0105] 2) AC power flow equation constraints

[0106]

[0107] Where, P G,i,t P represents the active power output of the thermal power unit at node i in time period t; R,i,t represents the active power output of the new energy unit at node i in time period t; Q G,i,t represents the reactive power output of the thermal power unit at node i in time period t; Q C,i,t U represents the reactive compensation amount of the shunt capacitor / reactor at node i in time period t, which is a discrete variable; i,t 、U j,t They represent the voltage amplitudes of nodes i and j in time period t respectively; N represents the number of AC nodes in the system.

[0108] 3) Node voltage amplitude constraint

[0109]

[0110] Where U i,min Indicates the minimum value of the voltage amplitude at node i; U i,max Indicates the maximum voltage amplitude at node i.

[0111] 4) Node voltage phase angle constraint

[0112]

[0113] Where θ i,min Represents the minimum value of the voltage phase angle at node i; θ i,max Represents the maximum value of the voltage phase angle at node i; θ i,t It represents the voltage phase angle of node i in time period t.

[0114] 5) Branch transmission power constraints

[0115]

[0116] Where, represents the maximum transmission power of branch (i, j). 6) Shunt capacitor / reactor capacity constraint

[0117]

[0118] Where Q C,m,min Indicates the minimum value of the reactive power compensation of the mth parallel capacitor / reactor; Q C,m,max It represents the maximum reactive compensation value of the mth parallel capacitor / reactor, and NC represents the number of parallel capacitors / reactors.

[0119] 7) Constraints on the total number of switching times of parallel capacitors / reactors

[0120]

[0121] Where C m (t) represents the number of times the mth shunt capacitor / reactor is switched on and off in the t time period, Cut_Num m Indicates the maximum number of times the mth parallel capacitor / reactor can be switched on and off within the optimization period M1_T of model M. When t=1, C m (t-1) = C m (0), C m (0) represents the initial switching times of the mth parallel capacitor / reactor. In one embodiment of the present invention, Cut_Num m Set to 20.

[0122] S4. Linearize the model M, simplify the mixed integer nonlinear programming model into a mixed integer linear programming model, and obtain the first-stage model M1.

[0123] The linearization method is as follows:

[0124] 1) Use the first-order Tailor expansion to calculate the nonlinear term U in the model M i U j cosα ij and U i U j sinα ij Perform linearization. The linearization process is as follows:

[0125] First, the sinα in the AC power flow equation ij and cosα ij In α ij0 The first-order Tailor expansion at is:

[0126] sinα ij =sinα ij0 +cosα ij0 (αij -α ij0 )

[0127] cosα ij =cosα ij0 -sinα ij0 (α ij -α ij0 )

[0128] Substitute the above equation into U i U j cosα ij and U i U j sinα [[ID=3))] ij We can get:

[0129] U i U ? j cosα ij =U i U j (cosα ij0 +α ij0 sinα ij0 )-U i U j α<00001< ij sinα ij0

[0130] U i U j sinα ij =U i U j (sinα ij0 -α ij0 cosα ij0 )+U i U j α ij cosα ij0

[0131] U i U j α ij At the point (U i0 U j0 , α0), the first-order Taylor expansion is:

[0132] U i ]]U j α ij =U i ? U j α ij0 +U i0 U j0 α ij -U i0 U j0 α ij0 Notes: There seems to be some unclear or incorrect notations in the original text (e.g., "U j " which might be a formatting issue). The translation has been done as accurately as possible based on the provided text.

[0133] Combining the above formulas, we can get:

[0134] U i U j cosα ij =U i U j cosα ij0 -U i0 U j0 α ij sinα ij0 +U i0 U j0 α ij0 sinα ij0

[0135] U i U j sinα ij =U i U j sinα ij0 +U i0 U j0 α ij cosα ij0 -U i0 U j0 α ij0 cosα ij0

[0136] Where U i represents the voltage amplitude of node i; U j represents the voltage amplitude of node j; α ij represents the voltage phase angle difference between node i and node j; α ij0 Represents α ij Tailor expansion point; U i0 Indicates U i Tailor expansion point; U j0 Indicates U j Tailor expansion point.

[0137] Since model M reasonably configures the reactive output of reactive sources based on active power balance, so that the AC power flow calculation converges without basically changing the active power flow of the operation mode, the node voltage phase angle difference obtained by the DC power flow calculation can be regarded as α ij Tailor expansion point, and let U i U j The Tailor expansion point is 1, thereby eliminating the non-convex and nonlinear problems caused by trigonometric functions.

[0138] Then, for U i U jLinearization is performed, U i U j It can be expanded to:

[0139]

[0140] Considering that the node voltage U is generally expressed in per-unit value and the difference in the node voltage amplitude at both ends of the branch is small, (U i -U j ) 2 Ignore, so the above formula can be expressed as:

[0141]

[0142] Simplifying, we can get:

[0143]

[0144] 2) Mathematically, an absolute value constraint of the form |x|≤C can be equivalent to -C≤x≤C. Here, x represents a variable and C represents a constant. Based on this, the absolute value in the model M can be removed. Let's take the switching times constraint of the parallel capacitor / reactor as an example. First, introduce the auxiliary variable X m,t ,make:

[0145]

[0146] Therefore, the total switching times constraint of the parallel capacitor / reactor can be equivalent to:

[0147]

[0148] And use inequality constraints to replace the equality constraints above:

[0149]

[0150] In summary, based on the above model linearization method, the objective function of the first-stage model M1 can be expressed as:

[0151]

[0152] Where M1_T represents the optimization period of the first-stage model M1; Z ij,t and Y ij,t are auxiliary variables of branch (i, j) in time period t, Z ij,t The calculation formula is as follows:

[0153]

[0154] Where, The calculation formula is as follows:

[0155]

[0156] Where, α ij,t,0 is the voltage phase difference at both ends of the branch (i, j) obtained by DC power flow calculation in time period t, which is a known quantity.

[0157] Auxiliary variable Y ij,t The calculation formula is as follows:

[0158]

[0159] The constraints for the first-stage model M1 include upper and lower limits on the reactive power output of thermal power units, linearized AC power flow equation constraints, node voltage amplitude square constraints, node voltage phase angle constraints, branch transmission power constraints, shunt capacitor / reactor capacity constraints, and linearized total shunt capacitor / reactor switching times constraints. The expressions for the upper and lower limits on the reactive power output of thermal power units, node voltage phase angle constraints, branch transmission power constraints, and shunt capacitor / reactor capacity constraints are identical to those in model M.

[0160] The linearized AC power flow equation constraints are as follows:

[0161]

[0162] Where, P G,i,t P represents the active power output of the thermal power unit at node i in time period t; R,i,t represents the active power output of the new energy unit at node i in time period t; Q G,i,t represents the reactive power output of the thermal power unit at node i in time period t; Q c,i,t U represents the reactive compensation amount of the shunt capacitor / reactor at node i in time period t, which is a discrete variable; i,t 、U j,t They represent the voltage amplitudes of nodes i and j in time period t respectively; N represents the number of AC nodes in the system.

[0163] The node voltage magnitude square constraint is as follows:

[0164]

[0165] Where U i,min Indicates the minimum value of the voltage amplitude at node i; U i,max Indicates the maximum voltage amplitude at node i.

[0166] The total switching times of linearized shunt capacitors / reactors are constrained as follows:

[0167]

[0168] Where, Cut_Numm The maximum number of times the mth parallel capacitor / reactor can be switched on and off within the period M1_T; X m,t It represents the auxiliary variable of the mth parallel capacitor / reactor in time period t, and its calculation formula is as follows:

[0169]

[0170] S5. Combined with the calculation results of step S2, the first-stage model M1 is instantiated with the optimization period M1_T of the first-stage model M1 as the optimization period, and the Gurobi solver is used to solve the problem in series to obtain the terminal voltage of the thermal power unit and the switching status of the shunt capacitor / reactor within the total optimization period episode.

[0171] The specific process is as follows:

[0172] S5.1. Initialize h=1;

[0173] S5.2. Before solving the hth first-stage model M1, the switching state of the shunt capacitors / reactors at the final moment of the h-1th first-stage model M1 is used as its initial switching state. When h = 1, the initial switching state is a manually set default value. In one embodiment of the present invention, the initial switching state of all shunt capacitors / reactors is set to 0, that is, no reactive compensation device is switched on at the initial moment;

[0174] S5.3, combining the calculation results of step S2, instantiating the hth first-stage model M1;

[0175] S5.4, use Gurobi solver to solve the hth first stage model M1;

[0176] S5.5, h=h+1;

[0177] S5.6. Determine whether h is greater than episode / M1_T. If so, proceed to step S5.7. If not, return to step S5.3.

[0178] S5.7. After all the first-stage models M1 are solved, the terminal voltages of the thermal power units and the switching status of the shunt capacitors / reactors within the total optimization period episode are summarized and obtained.

[0179] S6. Based on the solution of S5, perform AC power flow calculation in parallel (this is an existing known method, and its calculation process is not described in detail here), and determine whether the AC power flow calculation results meet the AC feasibility requirements. The time periods that do not meet the AC feasibility requirements are added to the adjustment set F.

[0180] The AC power flow calculation results must simultaneously meet the following AC feasibility requirements, including: 1) whether the node voltage amplitude is within the specified range; 2) whether the branch transmission active power is within the specified range; 3) whether the generator reactive output is within the specified range.

[0181] S7. Determine whether the adjustment set F is empty. If so, execute step S8; if not, execute step S6;

[0182] S8. Sort the adjustment set F in chronological order and divide it into several intervals according to whether the time periods are adjacent, and the length of each interval does not exceed the maximum adjustment interval length M2_T_Max of the second-stage model M2;

[0183] In one embodiment of the present invention, taking K = [2, 1, 3, 4, 8, 9, 11] as an example, the adjustment set F is first sorted in chronological order to obtain K = [1, 2, 3, 4, 8, 9, 11], and then divided into several intervals according to whether the time periods are adjacent, and the length of each interval does not exceed 4. The division results are: [1, 2, 3, 4], [5], [8, 9],

[11] .

[0184] S9. Taking the minimum adjustment of the active output of the generator set as the objective function, fix the switching state of the discrete reactive compensation devices such as the shunt capacitor / reactor obtained by solving the first-stage model M1, and construct the second-stage model M2. The objective function expression in the second-stage model M2 is as follows:

[0185]

[0186] Where, M2_T represents the total time period for solution, and its specific value is determined by the interval length obtained in step S8; NG represents the number of thermal power units; P G,n,t P represents the active power of the nth thermal power unit in the t time period; G,n,t,0 represents the initial active power of the nth thermal power unit in time period t; NR represents the number of new energy units (photovoltaic, wind power); P R,k,t represents the active power of the kth renewable energy unit in time period t; P R,k,t,0 It represents the initial active power of the kth renewable energy unit in time period t.

[0187] The constraints in the second-stage model M2 include: 1) upper and lower limits on the active power output of thermal power units; 2) upper and lower limits on the reactive power output of thermal power units; 3) upper and lower limits on the active power output of renewable energy units; 4) AC power flow equation constraints; 5) node voltage amplitude constraints; 6) node voltage phase angle constraints; 7) branch transmission power constraints; and 8) thermal power unit ramping constraints. Except for the constraints on the active power output of thermal power units, the active power output of renewable energy units, and the ramping constraints of thermal power units, the expressions for the other constraints are identical to those in model M.

[0188] Among them, the active output constraint expression of the thermal power unit is as follows:

[0189]

[0190] Where, P G,n,min Indicates the minimum active power output of the nth thermal power unit; P G,n,max Indicates the maximum active power output of the nth thermal power unit, P G,n,t It represents the active power of the nth thermal power unit in the time period t.

[0191] The active power output constraint expression of the new energy unit is as follows:

[0192]

[0193] Where, P R,k,max Indicates the maximum active power output of the kth new energy unit.

[0194] The climbing constraint expression of thermal power unit is as follows:

[0195]

[0196] In the formula, Up G,n Indicates the maximum upward ramp rate of the nth thermal power unit; Down G,n Indicates the maximum downward ramp rate of the nth thermal power unit.

[0197] S10. For each interval in step S8, when instantiating the second-stage model M2, the ramp-up constraints between the feasible time periods adjacent to the beginning and end of the interval must be considered simultaneously, and then the interior point method is used for parallel solution.

[0198] Taking the interval [3, 4, 5] as an example, when instantiating the second-stage model M2, it is necessary to consider the ramping constraints between periods 2 and 3, as well as the ramping constraints between periods 5 and 6. Among them, the active output of the thermal power units in periods 2 and 6 is a constant value.

[0199] S11. Output the solution result of the second-stage model M2 to obtain the reactive power flow configuration that meets the AC feasibility requirements.

[0200] In one embodiment of the present invention, the solution results are shown in Table 1, and the corresponding parallel capacitor / reactor switching state change curve is shown in Table 1. Figure 5 As shown in the figure, the node voltage amplitude change curve is as follows: Figure 6 As shown. At the same time, in order to better verify the effectiveness of the embodiment of the present invention, the two-stage reactive power flow generation method proposed in the embodiment of the present invention is compared with the following two mainstream methods: one is a direct solution method that uses the solver KNITRO to directly solve the reactive power flow generation model; the other is a method that relaxes the discrete variables in the reactive power flow generation model, uses the interior point method to solve it, and discretizes the relaxed variables after solution based on the nearest rounding method. The solution results of the comparison method are shown in Table 1. The reactive power flow generation model uses the objective function of the second-stage model M2 as the objective function, while considering the constraints of the model M and the second-stage model M2. The nearest rounding method refers to rounding a value to its nearest integer according to the rounding rule.

[0201] Table 1 Solution results using different methods in the embodiment

[0202]

[0203] The calculation expression of the average voltage deviation described in Table 1 is as follows:

[0204]

[0205] Where N represents the number of AC nodes in the system; V deviation Indicates the average voltage deviation within the total optimization cycle episode; U i,t Represents the node voltage amplitude at node i during time period t. The average voltage deviation measures the degree to which the node voltages in the reactive power flow generation scheme deviate from the standard value of 1. A larger average voltage deviation indicates a greater deviation from the standard value, and the corresponding reactive power flow configuration scheme deteriorates.

[0206] The calculation expression of the active power adjustment amount described in Table 1 is as follows:

[0207]

[0208] Where, P adjust Indicates the active power adjustment amount within the total optimization period episode; NG indicates the number of thermal power units; P G,n,t P represents the active power of the nth thermal power unit in the t time period; G,n,t,0 represents the initial active power of the nth thermal power unit in time period t; NR represents the number of new energy units (photovoltaic, wind power); P R,k,t represents the active power of the kth renewable energy unit in time period t; PR,k,t,0 represents the initial active power of the kth renewable energy generator in time period t. The active power adjustment is used to measure the impact of the reactive power flow generation scheme on the active power flow distribution. A larger active power adjustment indicates a greater disturbance of the reactive power flow generation scheme on the active power flow, and the corresponding reactive power flow configuration scheme is worse.

[0209] As shown in Table 1, compared with the direct solution method and the relaxed discrete variable solution method, the method provided by the embodiment of the present invention has a shorter solution time, the generated reactive power flow configuration has a smaller average voltage deviation, and can meet the AC feasibility requirements without adjusting the active output of the generator sets. These results show that the embodiment of the present invention can efficiently generate reactive power flow configuration plans while meeting the AC feasibility constraints, meeting the actual needs of power systems for rapid reactive power flow generation and feasibility solutions.

[0210] In one embodiment of the present invention, a computer device is further provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the method described in the aforementioned embodiment when executing the computer program.

[0211] In one embodiment of the present invention, a computer-readable storage medium is further provided, wherein the computer-readable storage medium stores a computer program, and wherein the computer program implements the method described in the aforementioned embodiment when executed by a processor.

[0212] The foregoing description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. Those skilled in the art will readily appreciate that the present invention is susceptible to various modifications and variations. Any modifications, equivalent substitutions, or improvements made within the spirit and principles of the present invention shall be included within the scope of protection of the present invention.

Claims

1. A two-stage reactive power flow generation method considering the switching times of reactive compensation devices, characterized in that: The steps include: S1, initialize the total optimization cycle episode, the optimization cycle M1_T of the first stage model M1, the maximum adjustment interval length M2_T_Max of the second stage model M2, and read the grid data and the source and load output data of each period within the total optimization cycle episode; S2. Combine the source and load output of each time period with the grid data, and perform DC power flow calculation in parallel to obtain the node voltage phase angle and branch active power flow of each time period; S3, with M1_T as the optimization period, construct a model M with the objective function of minimizing the branch active power flow deviation and the square difference of the voltage at both ends of the branch; S4, linearize the model M and construct the first-stage model M1; S5. Based on the calculation results of step S2, the first-stage model M1 is instantiated with episode / M1_T as the optimization period and solved to obtain the switching state result of the reactive compensation device; S6. Based on the solution of S5, AC power flow calculation is performed in parallel, and whether the AC power flow calculation results of each time period meet the AC feasibility requirements is determined, and the time periods that do not meet the AC feasibility requirements are added to the adjustment set F; S7. Determine whether the adjustment set F is empty. If so, execute step S11; if not, execute step S8. S8. Sort the time periods in the adjustment set F in chronological order and divide them into several intervals according to whether the time periods are adjacent, and the length of each interval does not exceed M2_T_Max; S9, taking the minimum active output adjustment of the generator set as the objective function, fixing the switching state of the discrete reactive compensation device obtained by solving the first-stage model M1, and constructing the second-stage model M2; S10, for each interval obtained in step S8, instantiate the second-stage model M2, while considering the ramp-up constraints between the feasible periods adjacent to the beginning and the end of the interval, and solve them in parallel; S11. Output the solution result of the second-stage model M2 to obtain the reactive power flow configuration that meets the AC feasibility requirements.

2. The two-stage reactive power flow generation method considering the switching times of reactive compensation devices according to claim 1 is characterized in that: In step S3, the objective function in model M is expressed as follows: Where NL represents the number of branches; K represents the branch set; (i,j) represents a branch whose starting and ending nodes are i and j respectively; represents the AC forward active power of branch (i, j) in time period t; represents the AC reverse active power of branch (j,i) in time period t; U represents the DC forward active power of branch (i, j) in time period t; i,t represents the voltage amplitude of node i in time period t; U j,t represents the voltage amplitude of node j in time period t; Model M includes the following constraints: 1) upper and lower limits of reactive power output of thermal power units; 2) AC power flow equation constraint; 4) node voltage amplitude constraint; 5) node voltage phase angle constraint; 6) branch transmission power constraint; 7) shunt capacitor / reactor capacity constraint; 8) total switching times of shunt capacitors / reactors constraint.

3. The two-stage reactive power flow generation method considering the switching times of reactive compensation devices according to claim 1 is characterized in that: In step S4, the objective function of the first-stage model M1 is: Where M1_T represents the optimization period of the first-stage model M1; Z ij,t and Y ij,t are auxiliary variables of branch (i, j) in time period t; NL represents the number of branches; K represents the branch set.

4. The two-stage reactive power flow generation method considering the switching times of reactive compensation devices according to claim 3 is characterized in that: Auxiliary variable Z ij,t The calculation formula is as follows: Where, The calculation formula is as follows: Where, α ij,t,0 is the voltage phase difference at both ends of branch (i, j) obtained by DC power flow calculation in time period t; U i,t represents the voltage amplitude of node i in time period t; U j,t represents the voltage amplitude of node j in time period t; α ij,t represents the voltage phase angle difference between node i and node j in time period t; Auxiliary variable Y ij,t The calculation formula is as follows: The constraints of the first-stage model M1 include: upper and lower limits of reactive output of thermal power units, linearized AC power flow equation constraints, node voltage amplitude square constraints, node voltage phase angle constraints, branch transmission power constraints, shunt capacitor / reactor capacity constraints, and linearized shunt capacitor / reactor total switching times constraints.

5. The two-stage reactive power flow generation method considering the switching times of reactive compensation devices according to claim 1 is characterized in that: In step S5, a Gurobi solver is used for serial solution. During the solution process, the switching state of the parallel capacitor / reactor at the end of the current sub-period is used as the initial switching state of the parallel capacitor / reactor in the next sub-period.

6. The two-stage reactive power flow generation method considering the switching times of reactive compensation devices according to claim 1, characterized in that: In step S6, the AC feasibility requirements include: 1) whether the node voltage amplitude is within a specified range; 2) whether the branch transmission active power is within a specified range; 3) whether the generator set reactive output is within a specified range.

7. The two-stage reactive power flow generation method considering the switching times of reactive compensation devices according to claim 1 is characterized in that: In step S9, the objective function expression in the second stage model M2 is as follows: Where, M2_T represents the total time period for solution, NG represents the number of thermal power units; P G,n,i P represents the active power of the nth thermal power unit in the t time period; G,n,t,0 represents the initial active power of the nth thermal power unit in time period t; NR represents the number of new energy units; P R,k,t represents the active power of the kth renewable energy unit in time period t; P R,k,t,0 represents the initial active power of the kth renewable energy unit in time period t; The second-stage model M2 includes the following constraints: upper and lower limits of active power output of thermal power units; upper and lower limits of reactive power output of thermal power units; upper and lower limits of active power output of new energy units; AC power flow equation constraints; node voltage amplitude constraints; node voltage phase angle constraints; branch transmission power constraints; and thermal power unit ramping constraints.

8. The two-stage reactive power flow generation method according to any one of claims 1 to 7, wherein: In step S10, the interior point method is used for parallel solution.

9. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the computer program, the method according to any one of claims 1 to 8 is implemented.

10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 8 is implemented.

Citation Information

Patent Citations

  • Two-stage reactive power regulation method for active power distribution network based on opportunity constraint optimization

    CN113162060A

  • Multi-target dynamic reactive power optimization method and system for power distribution network

    CN115085211A

  • Multi-time-scale reactive power scheduling method and system for power distribution network containing controllable photovoltaic

    CN115313504A

  • Active power distribution network two-stage power flow optimization method considering distribution network reconstruction

    CN116345466A

  • Active power distribution network dynamic optimal power flow calculation method based on second-order cone relaxation

    CN117458493A