Linear scheduling decision modeling method based on reversible neural network error supervision
By introducing reversible neural network units into the OPF model, establishing reversible mapping and using inverse transformation for error monitoring and optimization, the problem of large linear error in the existing linear OPF model is solved, and more efficient and accurate power system flow calculation is achieved.
Patent Information
- Application Number
- CN202210992664.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-08-18
- Publication Date
- 2025-06-06
- Estimated Expiration
- 2042-08-18
AI Technical Summary
The existing linear OPF model is based on empirical mathematical approximation, and linearization errors may be large, resulting in economic losses, and computational efficiency and accuracy in large-scale power systems are difficult to guarantee.
The error-supervised linear OPF modeling method based on reversible neural network is adopted. By establishing a reversible mapping between the input and output of the reversible neural network unit, error monitoring and optimization are used to improve the accuracy of the OPF model.
This method can maintain the accuracy of the neural network OPF model without historical data, reduce linearization errors, and improve the efficiency and accuracy of power system trend calculation.
Smart Images

Figure CN115912364B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of linearization of optimal power flow models of power systems, and in particular to a linear dispatch decision modeling method based on reversible neural network error supervision. Background Art
[0002] Power flow calculation is a basic electrical calculation that studies the steady-state operation of power systems. It determines the operating status of the entire system based on given operating conditions and network structures. Its basic mathematical model is a set of high-order nonlinear equations, which seek reliable convergence through continuous iterations and give the final correct answer. As the scale of power systems continues to expand, the complexity of power flow calculation equations has also increased, convergence has become more difficult, and there is no guarantee of giving the correct answer. This situation has prompted power system researchers to continuously look for faster and more reliable calculation methods. In the past 20 years, research on power flow calculation has remained very active, but most of it has been improved around PQ decomposition and improved Newton's method. In addition, with the rapid development of related research such as artificial intelligence theory, some new research methods have also begun to be gradually introduced into power flow calculation.
[0003] The optimal power flow (OPF) of the power system can achieve the optimal system stable operation state of the predetermined target by adjusting the available control means in the system under the conditions of specific power grid operation and safety constraints. OPF can improve the economy of the power system as much as possible while ensuring the safety of the power system, which is of great significance to the dispatching, operation and control of the actual power system.
[0004] In order to meet the computational efficiency requirements of power dispatch, OPF models are usually linearized. However, existing linear OPF models are usually based on empirical mathematical approximations. The linearization error can be quite large, which may cause huge economic losses. Summary of the invention
[0005] The purpose of the present invention is to provide a linear scheduling decision modeling method based on reversible neural network error supervision, comprising the following steps:
[0006] 1) Establish a linear OPF model based on a reversible neural network;
[0007] The steps to establish a linear OPF model based on a reversible neural network include:
[0008] 1.1) Establish the original nonlinear OPF model;
[0009] The objective function of the original nonlinear OPF model is as follows:
[0010]
[0011] In the formula, c g represents the cost of the g-th generator; represents the generator output; g represents the index of the generator; Represents a collection of generator indices.
[0012] The constraints of the original nonlinear OPF model are as follows:
[0013]
[0014]
[0015]
[0016]
[0017]
[0018]
[0019]
[0020]
[0021] In the formula, i, j, g represent the indexes of the starting node, the ending node, and the generator; represents the index set of nodes, generators, nodes connected to node i, and generators connected to node i; c g represents the cost of the g-th generator; Represents the active and reactive output of the generator; P i D , represents the active power and reactive power of node i; P ij , Q ij represents the active power and reactive power of line ij; v i 、v j represents the voltage amplitude of the starting node i and the ending node j; g ij 、b ij represents the admittance of line ij; θ ij Represents the voltage phase angle difference between the starting node i and the ending node j; Represents the upper and lower limits of the voltage amplitude of the starting node i, Represents the upper and lower limits of the voltage phase angle difference of the starting branch {ij}, Represents the upper and lower limits of the active power of the starting branch {ij}, Represents the upper and lower limits of the reactive power of the starting branch {ij}.
[0022] 1.2) Establish the general linear power flow equation;
[0023] The general linear power flow equation is shown below:
[0024]
[0025]
[0026] In the formula, the parameters Represents the linear active power and linear reactive power of line ij; Represents the general functional form of active power and reactive power of line ij; φ i (v i ),φ j (v j ) represents the state variable; φ i (v i,0 ),φ j (v j,0 ) represents the initial value of the state variable.
[0027] 1.3) Based on the original nonlinear OPF model and the general linear power flow equation, a linear OPF model based on a reversible neural network is established.
[0028] The linear OPF model based on the reversible neural network includes a plurality of reversible neural network units; the reversible neural network units establish a reversible mapping between input and output;
[0029] Among them, the input of the i-th reversible neural network unit is the voltage amplitude v i , the output is the state variable φ i (v i );
[0030] The forward data flow φ of the i-th reversible neural network unit i (v i ):v i →φ i As shown below:
[0031]
[0032] In the formula, is the state variable φ i The amount of and Represents the remainder after the reversible component.
[0033] Reverse data flow of the i-th reversible neural network unit φ i →v i As shown below:
[0034]
[0035] In the formula, η(v) and σ(φ) represent the remainder except the reversible component.
[0036] The reversible neural network unit is trained, and the training steps include:
[0037] a) Set the loss function L(V(H)) of the reversible neural network unit, that is:
[0038]
[0039] In the formula, parameter V(H)=(φ 1 (v 1 ,h 1 ),φ 2 (v 2 ,h 2 ),...,φ N (v N ,h N )) T ; H = [h i ] N×1 is the parameter vector of the reversible neural network unit; P ij (x ij ), Q ij (x ij ) represents the sample x ij The corresponding active power and reactive power of line ij;
[0040] b) Update the parameter h based on gradient descent i ,get:
[0041]
[0042] Where γ is the learning rate and the gradient matrix H k , H k+1 is the parameter vector of the reversible neural network unit before and after iterative update;
[0043] Among them, the gradient It can be obtained according to the chain rule as follows:
[0044]
[0045] In the formula, the gradient matrix Gradient Matrix φ N (v N ) is a state variable;
[0046] Among them, the gradient matrix The element dφ(v i ,h i ) / dh i As shown below:
[0047] dφ(v i ,h i ) / dh i =df i (n) {...f i (2) [f i (1) (v i )]} / dh i , (17)
[0048] In the formula, f i (l) is the activation function of the i-th layer of the i-th INN;
[0049] c) According to the parameter h i Calculate the loss function L(V(H)) of the reversible neural network unit, and determine whether the loss function L(V(H)) is less than the preset loss threshold. If so, end the training, otherwise, return to step b).
[0050] The linear OPF model based on the reversible neural network is as follows:
[0051]
[0052]
[0053]
[0054]
[0055]
[0056]
[0057] Where P ij , Q ij Represents the active power and reactive power of line ij.
[0058] 2) The linear OPF model based on the reversible neural network is optimized by using the error monitoring strategy based on inverse transformation to obtain the linear optimal OPF model based on the reversible neural network;
[0059] The steps of optimizing the linear OPF model based on reversible neural network using the inverse transformation based error monitoring strategy include:
[0060] 2.1) Calculate the error F of the reversible neural network unit corresponding to the branch {ij} ij ,Right now:
[0061]
[0062] Where M is the sample number; k is the sample index; and is the observed value of the kth sample; is the active power and reactive power corresponding to the kth sample; is the linear active power and reactive power corresponding to the kth sample;
[0063] 2.2) Judgment error F ij Is it greater than the preset threshold ε? ij , if yes, then update the parameters of the reversible neural network unit corresponding to the branch {ij} and return to step 2.1);
[0064] 2.3) Repeat step 2.1) to step 2.2) until the error of each reversible neural network unit in the linear OPF model based on the reversible neural network is less than or equal to the preset threshold.
[0065] When updating the parameters of the reversible neural network unit corresponding to the branch {ij}, the parameters of other reversible neural network units in the linear OPF model based on the reversible neural network remain unchanged.
[0066] 3) The power system flow is calculated using the linear optimal OPF model based on reversible neural network.
[0067] The technical effect of the present invention is unquestionable. The present invention proposes an error-supervised linear OPF modeling method based on a reversible neural network. Based on the topological information of the power system, a reversible neural network (INN) is used as an agent to select appropriate linear power flow models on all branches. INN establishes a reversible transformation between nonlinear and linear OPF models. Based on this reversibility, a data-independent supervision method is proposed to evaluate the linearization error of each branch. This method can maintain the accuracy of the neural network OPF model in the absence of historical data. Finally, an error supervision strategy is proposed to effectively improve the OPF model by locally updating the INN corresponding to the branch power flow equation whose linearization error exceeds the tolerance. BRIEF DESCRIPTION OF THE DRAWINGS
[0068] Figure 1 The data stream for INN;
[0069] Figure 2 It is the proposed INN training framework;
[0070] Figure 3It is an error supervision strategy and a local update method. DETAILED DESCRIPTION
[0071] The present invention is further described below in conjunction with the embodiments, but it should not be understood that the above subject matter of the present invention is limited to the following embodiments. Without departing from the above technical ideas of the present invention, various substitutions and changes are made according to the common technical knowledge and customary means in the art, which should all be included in the protection scope of the present invention.
[0072] Embodiment 1:
[0073] See also Figures 1 to 3 ,The linear scheduling decision modeling method based on reversible neural network error supervision includes the following steps:
[0074] 1) Establish a linear OPF model based on a reversible neural network;
[0075] The steps to establish a linear OPF model based on a reversible neural network include:
[0076] 1.1) Establish the original nonlinear OPF model;
[0077] The objective function of the original nonlinear OPF model is as follows:
[0078]
[0079] In the formula, c g represents the cost of the g-th generator; represents the generator output; g represents the index of the generator; Represents a collection of generator indices.
[0080] The constraints of the original nonlinear OPF model are as follows:
[0081]
[0082]
[0083]
[0084]
[0085]
[0086]
[0087]
[0088]
[0089] In the formula, i, j, g represent the indexes of the starting node, the ending node, and the generator; represents the index set of nodes, generators, nodes connected to node i, and generators connected to node i; c g represents the cost of the g-th generator; Represents the active and reactive output of the generator; P i D , represents the active power and reactive power of node i; P ij , Q ij represents the active power and reactive power of line ij; v i 、v j represents the voltage amplitude of the starting node i and the ending node j; g ij 、b ij represents the admittance of line ij; θ ij Represents the voltage phase angle difference between the starting node i and the ending node j; Represents the upper and lower limits of the voltage amplitude of the starting node i, Represents the upper and lower limits of the voltage phase angle difference of the starting branch {ij}, Represents the upper and lower limits of the active power of the starting branch {ij}, Represents the upper and lower limits of the reactive power of the starting branch {ij}.
[0090] 1.2) Establish the general linear power flow equation;
[0091] The general linear power flow equation is shown below:
[0092]
[0093]
[0094] In the formula, the parameters Represents the linear active power and linear reactive power of line ij; Represents the general functional form of active power and reactive power of line ij; φ i (v i ),φ j (v j ) represents the state variable; φ i (v i,0 ),φ j (v j,0 ) represents the initial value of the state variable.
[0095] 1.3) Based on the original nonlinear OPF model and the general linear power flow equation, a linear OPF model based on a reversible neural network is established.
[0096] The linear OPF model based on the reversible neural network includes a plurality of reversible neural network units; the reversible neural network units establish a reversible mapping between input and output;
[0097] Among them, the input of the i-th reversible neural network unit is the voltage amplitude v i , the output is the state variable φ i (v i );
[0098] The forward data flow φ of the i-th reversible neural network unit i (v i ):v i →φ i As shown below:
[0099]
[0100] In the formula, is the state variable φ i The amount of and Represents the remainder after the reversible component.
[0101] Reverse data flow of the i-th reversible neural network unit φ i →v i As shown below:
[0102]
[0103] In the formula, η(v) and σ(φ) represent the remainder except the reversible component.
[0104] The reversible neural network unit is trained, and the training steps include:
[0105] a) Set the loss function L(V(H)) of the reversible neural network unit, that is:
[0106]
[0107] In the formula, parameter V(H)=(φ 1 (v 1 ,h 1 ),φ 2 (v 2 ,h 2 ),...,φ N (v N ,h N )) T . H=[h i ] N×1 is the parameter vector of the reversible neural network unit; Pij (x ij ), Q ij (x ij ) represents the sample x ij The corresponding active power and reactive power of line ij;
[0108] b) Update the parameter h based on gradient descent i ,get:
[0109]
[0110] Where γ is the learning rate and the gradient matrix H k , H k+1 is the parameter vector of the reversible neural network unit before and after iterative update;
[0111] Among them, the gradient It can be obtained according to the chain rule as follows:
[0112]
[0113] In the formula, the gradient matrix Gradient Matrix φ N (v N ) is a state variable;
[0114] Among them, the gradient matrix The element dφ(v i ,h i ) / dh i As shown below:
[0115] dφ(v i ,h i ) / dh i =df i (n) {...f i (2) [f i (1) (v i )]} / dh i , (17)
[0116] In the formula, f i (l) is the activation function of the i-th layer of the i-th INN;
[0117] c) According to the parameter h i Calculate the loss function L(V(H)) of the reversible neural network unit, and determine whether the loss function L(V(H)) is less than the preset loss threshold. If so, end the training, otherwise, return to step b).
[0118] The linear OPF model based on the reversible neural network is as follows:
[0119]
[0120]
[0121]
[0122]
[0123]
[0124]
[0125] Where P ij , Q ij Represents the active power and reactive power of line ij.
[0126] 2) The linear OPF model based on the reversible neural network is optimized by using the error monitoring strategy based on inverse transformation to obtain the linear optimal OPF model based on the reversible neural network;
[0127] The steps of optimizing the linear OPF model based on reversible neural network using the inverse transformation based error monitoring strategy include:
[0128] 2.1) Calculate the error F of the reversible neural network unit corresponding to the branch {ij} ij ,Right now:
[0129]
[0130] Where M is the sample number; k is the sample index; and is the observed value of the kth sample; is the active power and reactive power corresponding to the kth sample; is the linear active power and reactive power corresponding to the kth sample;
[0131] 2.2) Judgment error F ij Is it greater than the preset threshold ε? ij , if yes, then update the parameters of the reversible neural network unit corresponding to the branch {ij} and return to step 2.1);
[0132] 2.3) Repeat step 2.1) to step 2.2) until the error of each reversible neural network unit in the linear OPF model based on the reversible neural network is less than or equal to the preset threshold.
[0133] When updating the parameters of the reversible neural network unit corresponding to the branch {ij}, the parameters of other reversible neural network units in the linear OPF model based on the reversible neural network remain unchanged.
[0134] 3) The power system flow is calculated using the linear optimal OPF model based on reversible neural network.
[0135] Embodiment 2:
[0136] The linear scheduling decision modeling method based on reversible neural network error supervision for improving the accuracy of the linear OPF model includes the following steps:
[0137] 1) Establish a linear OPF model based on reversible neural network.
[0138] The steps to establish a linear OPF model based on a reversible neural network are as follows:
[0139] 1.1) Establish the general linear power flow equation. The objective function of the original nonlinear OPF model is as follows:
[0140]
[0141] The constraints are:
[0142]
[0143]
[0144]
[0145]
[0146]
[0147]
[0148]
[0149]
[0150] In the formula, i, j, g represent the index of the starting node, the ending node, and the generator. represents the node, generator, nodes connected to node i, the index set of generators connected to node i, c g represents the cost of the g-th generator, Represents the generator output.
[0151] The basic idea of the general linear power flow model is: 1) The power flow equations (4)-(5) are regarded as (P ij ,Q ij) About the general function form The function is defined as 2) Based on the initial value point Derivation The first-order Taylor expansion of i,0 =v j,0 =1.0puθ ij,0 =0). The general linear power flow equation is as follows:
[0152]
[0153]
[0154] In the formula, The general linear OPF model is (1)-(3), (6)-(11), where formulas (10)-(11) show that by choosing a suitable Θ ij The error of the linear power flow model can be reduced.
[0155] 1.2) Establish a linear OPF model based on reversible neural network.
[0156] First, INN is used as the basic unit of neural network. It can establish a reversible mapping between input and output. The reversibility is the voltage amplitude v i With the state variable φ i (v i ) in general form (i.e., choosing Θ ij ). The reversibility of INN is realized through its special data flow, such as Figure 1 Input v i and output φ i (v i ) needs to be split into and η(v) and σ(φ) represent the remainder except the reversible component and are modeled as a trained convolutional neural network (CNN). After η(v) and σ(φ) are trained, the forward data flow φ i (v i ):v i →φ i It can be expressed as
[0157]
[0158] Reverse Data Flow φ i →v i It can be expressed as
[0159]
[0160] The proposed INN training framework is as follows Figure 2 As discussed above, the i-th INN sets the voltage amplitude v of the i-th node i Converted to state variable function form φ i (v i ). According to (10)-(11), the i,jth INN can be used as a proxy for selecting a suitable linear power flow equation on branch {ij}, that is, selecting Θ ij . Therefore, the INNs on all nodes together constitute a reversible mapping between nonlinear and linear OPF models. For the training of neural networks, the end condition of the training phase is to choose an ideal Θ ij The loss function of the neural network is set to the sum of the quadratic errors on all branches, as follows:
[0161]
[0162] In the formula, V(H)=(φ 1 (v 1 ,h 1 ),φ 2 (v 2 ,h 2 ),...,φ N (v N ,h N )) T ,H=[h i ] N×1 is the parameter of INNs. Update h based on gradient descent i as follows:
[0163]
[0164] Where γ is the learning rate, H k , H k+1 is the parameter vector of the reversible neural network unit before and after iterative update;
[0165] The following formula can be derived according to the chain rule:
[0166]
[0167] In the formula, As shown below:
[0168] dφ(v i ,h i ) / dh i =df i (n) {...f i(2) [f i (1) (v i )]} / dh i , (17)
[0169] In the formula, f i (l) is the activation function of the i-th layer of the i-th INN.
[0170] After training, the linear OPF model is generated by modifying the original model (1)-(9) as follows: 1) Keep formulas (1)-(3). 2) Constraints (4)-(5) are replaced by (10)-(11).
[0171] 1.3)φ i Replace vi as the decision variable and the boundary constraint (6) with φ i The boundaries are as follows:
[0172]
[0173] 2) Establish an error monitoring strategy based on inverse transformation.
[0174] To independently verify the accuracy of the trained INNs data, we uniformly sample Θ on the run domain (18) ij =(φ i (v i ),φ j (v j ),θ ij ), and by the inverse operation Get the corresponding x ij =(v i ,v j ,θ ij ). Under the assumption that active power and reactive power have equal weights, the error of branch {ij} can be represented by the sum of the errors in all samples as follows:
[0175]
[0176] Where M is the sample number and k is the sample index. and is the observed value of the hth sample. The accuracy of INN can be directly monitored by F ij The efficiency of LP modeling can be improved by locally updating the INN that exceeds the error tolerance, such as Figure 3 As shown. ijWhen the error tolerance is exceeded, it indicates that the linearization error of the power flow equation associated with the i,jth INN needs to be supervised. In addition, the error will extend to the branch connected to the node i,j. The INN corresponding to the node connected to i,j (including the node i,j) needs to be updated through the local update strategy, that is, the corresponding INN parameters are updated, while the other INN parameters are fixed.
[0177] Embodiment 3:
[0178] The verification experiment of the linear scheduling decision modeling method based on reversible neural network error supervision includes the following contents:
[0179] The method was validated on 3000 OPF samples (1000 for each system) of IEEE 30, 118 and Polish 2383 systems with a load fluctuation of 20%. The OPF model was solved using GAMS on a computer with an i5-9300H CPU as the core. The neural network was trained based on TensorFlow 2.0. During the training phase, 1000 training samples with a load fluctuation of 5% were selected and the learning rate γ was set to 0.01. The method was compared with the DC OPF, the linear OPF model Θ ij =(φ i (v i )=v i ,φ j (v j )=v j ,θ ij ), Linear OPF Model The accuracy of OPF results is shown in Table 1. It can be observed that the proposed method outperforms other OPF methods. i (Q i ) are reduced by 98.1%, 93.0% and 77.6% respectively. Moreover, the proposed method also successfully reduces the error of generator cost.
[0180] Table 1 Average error of OPF results in IEEE and Polish test systems
[0181]
[0182] “f” represents the unit cost and is the objective function of the OPF result. The subscript “L” represents the corresponding variable in the linear model. “φ(v)=v” and “φ(v)=v 2 represents the linear OPF model, (φ i (v i )=v i ,φ j (v j )=v j ,θ ij )and P i and Q i Represents the node power injection.
[0183] Furthermore, the solution performance is shown in Table 2, where the computation time of the OPF model is compared with the AC feasibility and constraint violation rate of the solved power generation. The proposed method guarantees the best feasibility of the OPF solution in all the tested systems. It only brings 1.9% of infeasible OPF solutions and 0.9% of OPF constraint violations. Note that the INN model aims to build a linear OPF model, so the training phase is performed offline. The relative time cost will not affect the real-time operation. After training, the solution efficiency of the proposed OPF model is similar to that of the general linear OPF model.
[0184] Table 2 Solution performance of OPF model
[0185]
[0186] Embodiment 4:
[0187] The linear scheduling decision modeling method based on reversible neural network error supervision includes the following steps:
[0188] 1) Establish a linear OPF model based on a reversible neural network;
[0189] 2) The linear OPF model based on the reversible neural network is optimized by using the error monitoring strategy based on inverse transformation to obtain the linear optimal OPF model based on the reversible neural network;
[0190] 3) The power system flow is calculated using the linear optimal OPF model based on reversible neural network.
[0191] Embodiment 5:
[0192] The linear scheduling decision modeling method based on reversible neural network error supervision, the main content of which is shown in Example 4, wherein the steps of establishing a linear OPF model based on a reversible neural network include:
[0193] 1) Establish the original nonlinear OPF model;
[0194] 2) Establish the general linear power flow equation;
[0195] 3) Based on the original nonlinear OPF model and the general linear power flow equation, a linear OPF model based on a reversible neural network is established.
[0196] Embodiment 6:
[0197] The linear scheduling decision modeling method based on reversible neural network error supervision, the main content of which is shown in Example 4, wherein the objective function of the original nonlinear OPF model is as follows:
[0198]
[0199] In the formula, c g represents the cost of the g-th generator; represents the generator output; g represents the index of the generator; Represents a collection of generator indices.
[0200] Embodiment 7:
[0201] The linear scheduling decision modeling method based on reversible neural network error supervision is mainly described in Example 4, wherein the constraints of the original nonlinear OPF model are as follows:
[0202]
[0203]
[0204]
[0205]
[0206]
[0207]
[0208]
[0209]
[0210] In the formula, i, j, g represent the indexes of the starting node, the ending node, and the generator; Represents the node, the nodes connected to node i, and the generator index set connected to node i; Represents the active and reactive output of the generator; P i D , represents the active power and reactive power of node i; P ij , Q ij represents the active power and reactive power of line ij; v i 、v j represents the voltage amplitude of the starting node i and the ending node j; g ij 、b ij represents the admittance of line ij; θ ij Represents the voltage phase angle difference between the starting node i and the ending node j; Represents the upper and lower limits of the voltage amplitude of the starting node i, Represents the upper and lower limits of the voltage phase angle difference of the starting branch {ij}, Represents the upper and lower limits of the active power of the starting branch {ij}, Represents the upper and lower limits of the reactive power of the starting branch {ij}.
[0211] Embodiment 8:
[0212] The linear scheduling decision modeling method based on reversible neural network error supervision, the main content of which is shown in Example 4, wherein the general linear power flow equation is as follows:
[0213]
[0214]
[0215] In the formula, the parameters Represents the linear active power and linear reactive power of line ij; Represents the general functional form of active power and reactive power of line ij; φ i (v i ),φ j (v j ) represents the state variable; φ i (v i,0 ),φ j (v j,0 ) represents the initial value of the state variable. ij , Q ij Represents the active power and reactive power of line ij;
[0216] Embodiment 9:
[0217] A linear scheduling decision modeling method based on reversible neural network error supervision, the main content of which is shown in Example 4, wherein the linear OPF model based on the reversible neural network includes a plurality of reversible neural network units; the reversible neural network units establish a reversible mapping between input and output;
[0218] Among them, the input of the i-th reversible neural network unit is the voltage amplitude v i , the output is the state variable φ i (v i );
[0219] The forward data flow φ of the i-th reversible neural network unit i (v i ):v i →φ i As shown below:
[0220]
[0221] In the formula, is the state variable φ i The amount of and Represents the remainder after the reversible component.
[0222] Reverse data flow of the i-th reversible neural network unit φ i →v i As shown below:
[0223]
[0224] In the formula, input Output Embodiment 10:
[0225] The linear scheduling decision modeling method based on reversible neural network error supervision is mainly described in Example 4, wherein the reversible neural network unit is trained, and the training steps include:
[0226] 1) Set the loss function L(V(H)) of the reversible neural network unit, that is:
[0227]
[0228] In the formula, parameter V(H)=(φ 1 (v 1 ,h 1 ),φ 2 (v 2 ,h 2 ),...,φ N (v N ,h N )) T ; H = [h i ] N×1 is the parameter vector of the reversible neural network unit; P ij (x ij ), Q ij (x ij ) represents the sample x ij The corresponding active power and reactive power of line ij;
[0229] 2) Update parameter h based on gradient descent i ,get:
[0230]
[0231] Where γ is the learning rate and the gradient matrix
[0232] Among them, the gradient According to the chain rule, we can get:
[0233]
[0234] In the formula, the gradient matrix Gradient Matrix φ N (v N ) is a state variable;
[0235] Among them, the gradient matrix The element dφ(v i ,h i ) / dh i As shown below:
[0236] dφ(v i ,h i ) / dh i =df i (n) {...f i (2) [f i (1) (v i )]} / dh i , (17)
[0237] In the formula, f i (l) is the activation function of the i-th layer of the i-th INN;
[0238] 3) According to the parameter h i Calculate the loss function L(V(H)) of the reversible neural network unit, and determine whether the loss function L(V(H)) is less than the preset loss threshold. If so, end the training, otherwise, return to step 2).
[0239] Embodiment 11:
[0240] The linear scheduling decision modeling method based on reversible neural network error supervision, the main content of which is shown in Example 4, wherein the linear OPF model based on reversible neural network is as follows:
[0241]
[0242]
[0243]
[0244]
[0245]
[0246]
[0247] Where P ij , Q ij Represents the active power and reactive power of line ij.
[0248] Embodiment 12:
[0249] The linear scheduling decision modeling method based on reversible neural network error supervision, the main content of which is shown in Example 4, wherein the step of optimizing the linear OPF model based on the reversible neural network using the error monitoring strategy based on inverse transformation includes:
[0250] 1) Calculate the error F of the reversible neural network unit corresponding to the branch {ij} ij ,Right now:
[0251]
[0252] Where M is the sample number; k is the sample index; and is the observed value of the kth sample; is the active power and reactive power corresponding to the kth sample; is the linear active power and reactive power corresponding to the kth sample;
[0253] 2) Judgment error F ij Is it greater than the preset threshold ε? ij , if yes, then update the parameters of the reversible neural network unit corresponding to the branch {ij} and return to step 1);
[0254] 3) Repeat step 1) to step 2) until the error of each reversible neural network unit in the linear OPF model based on the reversible neural network is less than or equal to a preset threshold.
[0255] Embodiment 13:
[0256] The linear scheduling decision modeling method based on reversible neural network error supervision, the main content of which is shown in Example 4, wherein when updating the parameters of the reversible neural network unit corresponding to the branch {ij}, the parameters of other reversible neural network units in the linear OPF model based on the reversible neural network remain fixed.
Claims
1. Linear scheduling decision modeling method based on reversible neural network error supervision, It is characterized in that The following steps are involved: 1) Establish a linear optimal power flow OPF model based on reversible neural network; 2) The linear OPF model based on the reversible neural network is optimized by using the error monitoring strategy based on inverse transformation to obtain the linear optimal OPF model based on the reversible neural network; 3) Calculate the power system flow using the linear optimal OPF model based on reversible neural network; The linear OPF model based on the reversible neural network includes a plurality of reversible neural network units; the reversible neural network units establish a reversible mapping between input and output; Among them, the input of the i-th reversible neural network unit is the voltage amplitude v i , the output is the state variable φ i (v i ); The forward data flow φ of the i-th reversible neural network unit i (v i ):v i →φ i As shown below: In the formula, is the state variable φ i The weight of and represents the remainder except the reversible component; Reverse data flow of the i-th reversible neural network unit φ i →v i As shown below: In the formula, input Output The linear optimal power flow OPF model based on reversible neural network is as follows: Where P ij , Q ij represents the active power and reactive power of line ij; c g represents the cost of the g-th generator; represents the generator output; g represents the index of the generator; represents the generator index set; P i D , represents the active power and reactive power of node i; Represents the node, the nodes connected to node i, and the generator index set connected to node i; Represents the upper and lower limits of the voltage amplitude of the starting node i, v i 、v j represents the voltage amplitude of the starting node i and the ending node j; g ij 、b ij represents the admittance of line ij; θ ij Represents the voltage phase angle difference between the starting node i and the ending node j; φ i (v i ),φ j (v j ) represents the state variable; φ i (v i,0 ),φ j (v j,0 ) represents the initial value of the state variable; Represents the linear active power and linear reactive power of line ij; parameters 2. According to claim 1, the linear scheduling decision modeling method based on reversible neural network error supervision, It is characterized in that The steps to establish a linear OPF model based on a reversible neural network include: 1) Establish the original nonlinear OPF model; 2) Establish the general linear power flow equation; 3) Based on the original nonlinear OPF model and the general linear power flow equation, a linear OPF model based on a reversible neural network is established.
3. According to claim 2, the linear scheduling decision modeling method based on reversible neural network error supervision, It is characterized in that The objective function of the original nonlinear OPF model is as follows: In the formula, c g represents the cost of the g-th generator; represents the generator output; g represents the index of the generator; Represents a collection of generator indices.
4. According to claim 2, the linear scheduling decision modeling method based on reversible neural network error supervision, It is characterized in that The constraints of the original nonlinear OPF model are as follows: In the formula, i, j, g represent the indexes of the starting node, the ending node, and the generator; Represents the node, the nodes connected to node i, and the generator index set connected to node i; Represents the active and reactive output of the generator; P i D , represents the active power and reactive power of node i; P ij , Q ij represents the active power and reactive power of line ij; v i 、v j represents the voltage amplitude of the starting node i and the ending node j; g ij , b ij represents the admittance of line ij; θ ij Represents the voltage phase angle difference between the starting node i and the ending node j; Represents the upper and lower limits of the voltage amplitude of the starting node i, Represents the upper and lower limits of the voltage phase angle difference of the starting branch {ij}, Represents the upper and lower limits of the active power of the starting branch {ij}, Represents the upper and lower limits of the reactive power of the starting branch {ij}.
5. According to claim 2, the linear scheduling decision modeling method based on reversible neural network error supervision, It is characterized in that The general linear power flow equation is shown below: In the formula, the parameters Represents the linear active power and linear reactive power of line ij; Represents the general functional form of active power and reactive power of line ij; φ i (v i ),φ j (v j ) represents the state variable; φ i (v i,0 ),φ j (v j,0 ) represents the initial value of the state variable; P ij , Q ij represents the active power and reactive power of line ij; g ij , b ij represents the admittance of line ij; θ ij represents the voltage phase difference between the starting node i and the ending node j; v i 、v j Represents the voltage amplitude of the starting node i and the ending node j.
6. According to claim 1, the linear scheduling decision modeling method based on reversible neural network error supervision, It is characterized in that The reversible neural network unit is trained, and the training steps include: 1) Set the loss function L(V(H)) of the reversible neural network unit, that is: In the formula, parameter V(H)=(φ 1 (v 1 ,h 1 ),φ 2 (v 2 ,h 2 ),...,φ N (v N ,h N )) T ; H = [h i ] N×1 is the parameter vector of the reversible neural network unit; P ij (x ij ), Q ij (x ij ) represents the sample x ij The corresponding active power and reactive power of line ij; Represents the linear active power and linear reactive power of line ij; parameters φ i (v i ),φ j (v j ) represents the state variable; θ ij represents the voltage phase difference between the starting node i and the ending node j; v i 、v j Represents the voltage amplitude of the starting node i and the ending node j; 2) Update parameter h based on gradient descent i ,get: Where γ is the learning rate and the gradient matrix Among them, the gradient According to the chain rule, we can get: In the formula, the gradient matrix Gradient Matrix φ N (v N ) is a state variable; Among them, the gradient matrix The element dφ(v i ,h i ) / dh i As shown below: dφ(v i ,h i ) / dh i =df i (n) {...f i (2) [f i (1) (v) i )]} / dh i , (17) In the formula, f i (l) is the activation function of the i-th layer of the i-th reversible neural network INN; 3) According to the parameter h i Calculate the loss function L(V(H)) of the reversible neural network unit, and determine whether the loss function L(V(H)) is less than the preset loss threshold. If so, end the training, otherwise, return to step 2).
7. According to claim 1, the linear scheduling decision modeling method based on reversible neural network error supervision, It is characterized in that The steps of optimizing the linear OPF model based on reversible neural network using the inverse transformation based error monitoring strategy include: 1) Calculate the error F of the reversible neural network unit corresponding to the branch {ij} ij ,Right now: Where M is the sample number; k is the sample index; and is the observed value of the kth sample; is the active power and reactive power corresponding to the kth sample; is the linear active power and reactive power corresponding to the kth sample; 2) Judgment error F ij Is it greater than the preset threshold ε? ij , if yes, then update the parameters of the reversible neural network unit corresponding to the branch {ij} and return to step 1); 3) Repeat step 1) to step 2) until the error of each reversible neural network unit in the linear OPF model based on the reversible neural network is less than or equal to a preset threshold.
8. According to claim 7, the linear scheduling decision modeling method based on reversible neural network error supervision, Features: When updating the parameters of the reversible neural network unit corresponding to the branch {ij}, the parameters of other reversible neural network units in the linear OPF model based on the reversible neural network remain unchanged.