A distributed state estimation method for electric-gas integrated energy system based on deep learning pseudo-measurement modeling
By using deep neural networks to establish a pseudo-measurement model in natural gas systems, the problems of low measurement redundancy and large errors are solved, the state estimation accuracy is improved, and information barriers are solved through alternating iteration strategies, and the electrical-gas system is realized Efficient status monitoring and information privacy protection.
Patent Information
- Application Number
- CN202411261268.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-10
- Publication Date
- 2025-02-11
- Estimated Expiration
- 2044-09-10
AI Technical Summary
The measurement redundancy and measurement error in the natural gas system are low, resulting in low accuracy of gas network state estimation and information barriers in electrical and gas subsystems.
The pseudo-measurement modeling method based on deep neural network is adopted to establish a pseudo-measurement model of natural gas system, improve the accuracy of state estimation, and solve the information barriers of electrical and gas subsystems through alternating iterative estimation strategies.
It improves the accuracy of gas network estimation, improves online computing efficiency, and effectively protects the information privacy of each subsystem, real-time and accurate status monitoring of the integrated electrical and gas energy system.
Smart Images

Figure CN119047330B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of monitoring, operation and control of integrated energy systems, and in particular to a distributed state estimation method for an electric-gas integrated energy system based on deep learning pseudo-measurement modeling. Background Art
[0002] The increasing depletion of fossil energy and the continuous deterioration of the ecological environment have brought severe challenges to the sustainable development of human society, and the contradiction between energy supply and demand has become more and more significant. In order to alleviate environmental problems such as resource shortages and climate change, it is urgent to change the previous rough energy utilization form, improve energy utilization efficiency, and promote the clean and low-carbon transformation of the energy system. The integrated energy system (IES) integrates multiple energy forms such as electricity, heat, cold, and gas, breaking the situation of independent planning and operation of traditional energy subsystems. It has the advantages of multi-energy complementarity, low carbon and high efficiency, and has great potential in promoting the consumption of new energy. Among the various forms of IES, the integrated electricity and gas system (IEGS) has attracted widespread attention for its advantages such as economic efficiency, clean and low carbon.
[0003] In order to perceive the operating status of IEGS in real time, comprehensively and accurately, accurate and reliable state estimation (SE) technology is needed to filter the measurement data of the electricity and gas subsystems and accurately track the real-time operating status of IEGS. However, the real-time measurement configuration redundancy in the actual natural gas system is low and the measurement data error is large, resulting in low accuracy or even non-convergence of gas network SE. Therefore, gas network SE based on traditional methods has certain limitations.
[0004] In view of this, the present invention proposes an IEGS distributed state estimation method based on deep neural network pseudo-measurement modeling. Aiming at the problem of low measurement redundancy of natural gas system, a pseudo-measurement model of natural gas system is established by using deep neural network to improve the accuracy of SE while ensuring the observability of the system. On this basis, an alternating iterative estimation strategy is adopted to solve the information barrier problem of the electrical and gas subsystems. Summary of the invention
[0005] The purpose of the invention is to solve the problems of low measurement redundancy, large measurement errors and information barriers between the electricity and gas subsystems in the natural gas system. The present invention proposes a distributed state estimation method for an electricity-gas integrated energy system based on deep neural network pseudo-measurement modeling, which improves the estimation accuracy of the gas network while improving the online computing efficiency.
[0006] Technical solution, in order to achieve the above-mentioned purpose, the present invention provides a distributed state estimation method of an electric-gas integrated energy system based on deep learning pseudo-measurement modeling, the method comprising the following steps:
[0007] Step 1: Obtain the operating parameter information of the electric-gas integrated energy system and initialize it;
[0008] Step 2: Establish mathematical models of the power system, natural gas system and coupling elements respectively, and build a state estimation model of the electric-gas integrated energy system based on the mathematical models;
[0009] Step 3: In the offline training phase, based on the historical measurement data information and historical load curve of the gas grid, the real-time measurement data of the gas grid is used as input, and the gas grid load node flow is used as output to train the deep neural network model, optimize the model parameters, and save the trained model parameters and errors;
[0010] Step 4: during online calculation, the real-time measurement data of the gas grid is input into the model trained in the offline stage, pseudo-measurement of gas grid load and flow is quickly generated, the real-time measurement of the gas grid and the pseudo-measurement are input into the gas grid state estimator, the real-time measurement of the power grid is input into the power grid state estimator, and the state estimation of the power grid and the gas grid is performed respectively;
[0011] Step 5: Perform distributed state estimation on the electricity-gas integrated energy system, exchange coupling element information at the electricity-gas coupling boundary, and determine whether the boundary constraints of the power grid and the gas grid are met. If so, output the estimation result; otherwise, update the boundary information and enter the next iteration.
[0012] Furthermore, in step 1, the operating parameter information of the electric-gas integrated energy system is obtained, which is as follows: the power grid operating parameter information includes generator output information, power line parameters, power grid load factor and load curve, and power grid measurement configuration information; the gas grid operating parameters include natural gas pipeline parameters, compressor branch parameters, gas source information, gas grid load factor and load curve, and gas grid measurement configuration information; the coupling element information includes gas turbine and power-to-gas device parameters and their energy conversion efficiency.
[0013] Furthermore, the model in step 2 is as follows:
[0014] (1) Power system model
[0015] The AC power flow equation is used to describe the steady-state model of the power system. The node power equation in polar coordinate form is as follows:
[0016]
[0017] Where P i and Q i Respectively represent the active power and reactive power injected into node i; Vi and V j Represent the voltage amplitude of node i and node j respectively; N e represents the number of nodes in the power system; θ ij represents the voltage phase angle difference between nodes i and j; G ij and B ij denote the real and imaginary parts of the node admittance matrix respectively;
[0018] (2) Natural gas system model
[0019] The steady-state model of the natural gas system mainly includes the pipeline flow equation, the compressor branch equation and the node flow balance equation, which are described as follows:
[0020] 1) Pipeline flow equation
[0021] The flow equation of a natural gas pipeline without a compressor is described by the Weymouth equation, which is expressed as follows:
[0022]
[0023]
[0024] In the formula, π m and π n Respectively represent the pressure of node m and node n; f mn,l represents the natural gas flow in pipeline l from node m to node n; C mn,l represents the Weymouth constant of the pipeline l; s mn,l is the variable that characterizes the direction of airflow in pipe l;
[0025] 2) Compressor branch equation
[0026] For booster station k, the power consumed by the compressor is H c,k The flow rate f flowing through the compressor branch c,k The relationship between them is expressed as:
[0027]
[0028] In the formula, B k is a parameter related to compressor temperature and efficiency factors; Z k is a constant related to the gas compressibility factor;
[0029] Assuming that the compressor is gas-driven, that is, the power consumed by the compressor is provided by the natural gas system, the natural gas flow rate τ consumed by the compressor is c,k Calculate as follows:
[0030]
[0031] Where, α, β, γ are fuel coefficients;
[0032] 3) Node traffic balance equation
[0033] The flow balance equation of node m in the gas network is expressed as:
[0034]
[0035] Where, L m and K m They represent the natural gas system pipeline branch set and the pressure station set connected to node m respectively; s c Indicates the direction of the compressor branch flow, 1 if it flows out from node m, and -1 otherwise; f m,source is the gas source injection flow connected to node m; f m,load is the gas load flow connected to node m;
[0036] (3) Coupling element model
[0037] Gas turbines GT and power-to-gas P2G devices are commonly used coupling elements in the electricity-gas integrated energy system. Their energy conversion relationships are described as follows:
[0038] 1) GT model
[0039] The relationship between the natural gas flow consumed by GT and the electrical power generated is:
[0040] f m,d =η GT P i,g
[0041] In the formula, f m,d represents the natural gas flow consumed by node m in the natural gas system; P i,g represents the electric power injected into the power system node i; η GT represents the energy conversion efficiency of GT;
[0042] 2) P2G model
[0043] The relationship between the electrical power consumed by P2G and the natural gas flow rate generated is:
[0044] f n,s =η P2G P j,d
[0045] In the formula, f n,s represents the natural gas flow injected into the natural gas system node n; P j,d represents the electric power consumed by the power system node j; η P2G It represents the energy conversion efficiency of the P2G device;
[0046] (4) State estimation model of electricity-gas integrated energy system
[0047] Based on the above power system model, natural gas system model and coupling element model, the measurement equations of the power system and natural gas system are as follows:
[0048] 1) Power system measurement equations
[0049] The real-time measurement data of the power system include node voltage amplitude, node active injection power, node reactive injection power, branch active power and branch reactive power. The specific expression of the power grid measurement equation is as follows:
[0050]
[0051] Among them, the first equation represents the voltage amplitude measurement equation, the second and third equations represent the node active power injection measurement equation and reactive power injection measurement equation respectively, and the fourth and fifth equations represent the branch active power measurement equation and branch reactive power measurement equation respectively; In the formula, They represent the node voltage amplitude measurement, node injected active power measurement, node injected reactive power measurement, branch head end active power measurement and branch head end reactive power measurement of the power system respectively; They represent the node voltage amplitude measurement error, the node injected active power measurement error, the node injected reactive power measurement error, the branch head end active power measurement error, and the branch head end reactive power measurement error, respectively. It is generally assumed that the above errors obey Gaussian distribution; and denote the voltage amplitude estimation values of node i and node j respectively; represents the estimated value of the phase angle difference between nodes i and j; G ij and B ij Respectively represent the real and imaginary parts of the node admittance matrix; g ij and b ij They represent the branch series conductance and susceptance respectively; g si and b si denote the parallel conductance and susceptance on the node i side respectively;
[0052] 2) Natural gas system measurement equation
[0053] The real-time measurement data of the gas network includes node pressure, branch flow, and node flow. The gas network measurement equation is expressed as follows:
[0054]
[0055] Among them, the first equation represents the node pressure measurement equation, the second equation represents the pipeline branch flow measurement equation, and the third equation represents the node flow measurement equation. In the formula, They represent the node pressure measurement, pipeline branch flow measurement and node flow measurement of the natural gas system respectively. They represent the measurement error of node pressure, the measurement error of pipeline branch flow and the measurement error of node flow respectively, assuming that these errors obey Gaussian distribution; and Represents the estimated node pressure of node m and node n;
[0056] 3) State estimation model of electricity-gas integrated energy system
[0057] The state variable of the power system is the node complex voltage, so the grid state variable in polar coordinate form is expressed as: e =[V T ,θ T ] T , where V represents the column vector of node voltage amplitude, V i Represents the voltage amplitude of each node, i=1,2,...,N e ; θ represents the node voltage phase angle column vector, θ i Represents the node voltage phase angle except the balance node, i=1,2,...,N e -1. The state variable of the natural gas system is the node pressure, that is, x g =π, π represents the pressure column vector of the gas network node, π m Represents the pressure of each node in the gas network, N g Represents the total number of gas network nodes, m=1,2,...,N g ;
[0058] In summary, the state estimation model of the electric-gas integrated energy system based on the least squares criterion is constructed as follows:
[0059]
[0060] Where J(x) is the objective function to be optimized; e and z g Respectively represent the quantity measurement of the power grid and gas grid; h e (x e ) and h g (x g ) represent the measurement equations of the power grid and gas grid respectively; R e and R g They represent the measurement error covariance matrices of the power grid and the gas grid, respectively, and both are diagonal matrices; is the state variable of the electric-gas integrated energy system; c(x)=0 represents the zero equation constraint, including the zero injection equation constraint of the power grid and the gas grid and the electric-gas coupling element constraint;
[0061] The zero injection equality constraint of the power grid can be expressed as:
[0062]
[0063] in, They represent the active zero injection power and reactive zero injection power of the power grid, respectively. They are both power grid state quantities x e The function is denoted by c e (x e )=0;
[0064] The zero injection equality constraint of the gas grid is expressed as:
[0065]
[0066] in, Indicates the zero injection flow of the gas network node, which is the gas network state quantity x g The function is denoted by c g (x g )=0;
[0067] The electric-gas coupling constraint is expressed as follows:
[0068]
[0069] Among them, f m,d 、f n,s is the gas network state quantity x g The function of P i,g , P j,d is the power grid state quantity x e The function is denoted by c eg (x e ,x g )=0.
[0070] In summary,
[0071] Furthermore, step 3 includes the following contents: using a deep neural network (DNN) to establish a pseudo measurement model of the gas grid load node flow, using the nonlinear fitting ability of the DNN to predict the gas grid load node flow, the deep neural network pseudo measurement modeling includes two parts: offline training and online application, which are as follows:
[0072] (1) The offline training process of DNN includes the following steps:
[0073] 1) Using the historical load curves of electricity and gas, the steady-state power flow calculation of the electricity-gas integrated energy system is carried out to obtain the true value corresponding to the node pressure and branch flow measurement of the gas network configured with real-time measurement;
[0074] 2) Superimpose Gaussian noise on the true value obtained by power flow calculation to simulate real-time measurement data;
[0075] 3) Train DNN with real-time gas grid measurement data as input and load node flow as output;
[0076] 4) Save the trained DNN model parameters and errors;
[0077] (2) Online Application
[0078] During the online application stage, the gas grid measurement data collected in real time is input into the DNN model trained in the offline stage to obtain the pseudo-measurement value of the load node flow. When estimating the state of the gas grid alone, the real-time measurement, virtual measurement and pseudo-measurement of the gas grid are input into the gas grid state estimator for calculation to obtain the gas grid estimation result. When estimating the electricity-gas coupling state, DNN is first used to generate pseudo-measurement values of the gas grid load flow, and then the state estimation of the electricity and gas subsystems is performed separately. Through alternating iterations until the boundary conditions of the electricity and gas subsystems are met, the estimation results of the power grid and the gas grid are finally output.
[0079] Furthermore, in step 5, the electric-gas distributed state estimation includes the following contents:
[0080] 1) Execute state estimation of the electrical and gas subsystems respectively. When the state estimation of a subsystem converges, use its state quantity to calculate the power and flow information of the coupling nodes in the system. According to the energy conversion relationship of the coupling element, the power and flow of the coupling element calculated previously are converted into equivalent flow and power in another system, and used as pseudo-measurement to participate in the next iteration of the subsystem.
[0081] 2) Determine whether the power and flow information of the coupling element match. If the boundary constraint condition is met, the loop ends; otherwise, the boundary coupling information is updated to enter the next iteration;
[0082] Let c = GT, P2G represent the coupling element gas turbine and P2G respectively, and the coupling element constraint convergence criterion is as follows:
[0083]
[0084] In the formula, It represents the coupling node power calculated from the grid state quantity; It represents the coupling node flow calculated from the gas network state quantity; Indicates the flow rate of the gas network coupling node The equivalent grid coupling node power obtained by conversion; Represents the power of the grid-coupled node Equivalent gas network coupling node flow obtained by conversion; ε e and εg They represent the boundary convergence thresholds of the power grid and the gas grid respectively. The first formula represents the power grid boundary constraint convergence criterion, and the second formula represents the gas grid boundary constraint convergence criterion.
[0085] Beneficial effects: Compared with the prior art, the technical solution of the present invention has the following beneficial technical effects:
[0086] This paper adopts deep neural network to predict the flow of gas grid load nodes. Compared with the traditional pseudo-measurement modeling method based on time series prediction, it has higher prediction accuracy, thereby improving the estimation accuracy of the gas grid. On this basis, an alternating iterative estimation strategy is adopted to realize the distributed solution of the state estimation problem of the electricity and gas subsystems, which effectively protects the information privacy of each subsystem and has high online computing efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0087] Figure 1 It is the algorithm flow chart of the present invention.
[0088] Figure 2 This is the topology diagram of the electricity-gas integrated energy system.
[0089] Figure 3 Schematic diagram of the deep neural network model structure constructed for the present invention.
[0090] Figure 4 This is the interval diagram of node load flow prediction results.
[0091] Figure 5 is the pseudo-measurement prediction error of each load node. DETAILED DESCRIPTION
[0092] The technical content of the present invention is further described below in conjunction with the accompanying drawings and specific embodiments.
[0093] The present invention adopts the IEGS composed of the modified Belgian 20-node natural gas system and the IEEE 24-node power system as a test case. The natural gas system and the power system are bidirectionally coupled through 2 GTs and 2 P2Gs. The system topology is as follows: Figure 2 Assume that the compressor is gas driven and uses a constant compression ratio control mode.
[0094] The measurement types of the gas grid (NGS) include real-time measurement, virtual measurement and pseudo measurement. Real-time measurement includes node pressure measurement (nodes 1, 3, 5, 8 configuration), pipeline flow measurement (pipelines 1-2, 2-3, 5-6, 4-14, 9-10, 10-11, 12-13, 14-15, 15-16, 19-20 configuration) and compressor branch flow measurement (branch 8-9, 17-18 configuration). Virtual measurement is the gas grid zero injection node (nodes 4, 7, 9, 10, 14, 17, 18), and pseudo measurement is the natural gas load node (nodes 3, 5, 6, 11, 15, 16, 20). The measurement types of the power grid (EPS) include real-time measurement and virtual measurement. Real-time measurement is a full measurement configuration.
[0095] The algorithm flow chart of the present invention is as follows Figure 1 , a distributed state estimation method for an electric-gas integrated energy system based on deep neural network pseudo-measurement modeling includes the following steps:
[0096] Step 1: Obtain the operating parameter information of the electric-gas integrated energy system and initialize it.
[0097] The grid operation parameter information includes generator output information, power line parameters, grid load factor and load curve, and grid measurement configuration information; the gas grid operation parameters include natural gas pipeline parameters, compressor branch parameters, gas source information, gas grid load factor and load curve, and gas grid measurement configuration information; the coupling element information includes gas turbine and power-to-gas device parameters and their energy conversion efficiency.
[0098] Step 2: Establish mathematical models of the power system, natural gas system and coupling elements respectively, and build a state estimation model of the electric-gas integrated energy system based on them. The specific modeling process is as follows.
[0099] (1) Power system model
[0100] The AC power flow equation is used to describe the steady-state model of the power system. The node power equation in polar coordinate form is as follows:
[0101]
[0102] Where P i and Q i Respectively represent the active power and reactive power injected into node i; V i and V j Represent the voltage amplitude of node i and node j respectively; N e represents the number of nodes in the power system; θ ij represents the voltage phase angle difference between nodes i and j; G ij and B ij denote the real and imaginary parts of the node admittance matrix respectively;
[0103] (2) Natural gas system model
[0104] The steady-state model of the natural gas system mainly includes the pipeline flow equation, the compressor branch equation and the node flow balance equation, which are described as follows:
[0105] 1) Pipeline flow equation
[0106] The flow equation of a natural gas pipeline without a compressor is described by the Weymouth equation, which is expressed as follows:
[0107]
[0108] In the formula, π m and π n Respectively represent the pressure of node m and node n; f mn,l represents the natural gas flow in pipeline l from node m to node n; C mn,l represents the Weymouth constant of the pipeline l; s mn,l is the variable that characterizes the direction of airflow in pipe l;
[0109] 2) Compressor branch equation
[0110] For booster station k, the power consumed by the compressor is H c,k The flow rate f flowing through the compressor branch c,k The relationship between them is expressed as:
[0111]
[0112] In the formula, B k is a parameter related to compressor temperature and efficiency factors; Z k is a constant related to the gas compressibility factor;
[0113] Assuming that the compressor is gas-driven, that is, the power consumed by the compressor is provided by the natural gas system, the natural gas flow rate τ consumed by the compressor is c,k Calculate as follows:
[0114]
[0115] Where, α, β, γ are fuel coefficients;
[0116] 3) Node traffic balance equation
[0117] The flow balance equation of node m in the gas network is expressed as:
[0118]
[0119] Where, L m and K mThey represent the natural gas system pipeline branch set and the pressure station set connected to node m respectively; s c Indicates the direction of the compressor branch flow, 1 if it flows out from node m, and -1 otherwise; f m,source is the gas source injection flow connected to node m; f m,load is the gas load flow connected to node m;
[0120] (3) Coupling element model
[0121] Gas turbines GT and power-to-gas P2G devices are commonly used coupling elements in the electricity-gas integrated energy system. Their energy conversion relationships are described as follows:
[0122] 1) GT model
[0123] The relationship between the natural gas flow consumed by GT and the electrical power generated is:
[0124] f m,d =η GT P i,g
[0125] In the formula, f m,d represents the natural gas flow consumed by node m in the natural gas system; P i,g represents the electric power injected into the power system node i; η GT represents the energy conversion efficiency of GT;
[0126] 2) P2G model
[0127] The relationship between the electrical power consumed by P2G and the natural gas flow rate generated is:
[0128] f n,s =η P2G P j,d
[0129] In the formula, f n,s represents the natural gas flow injected into the natural gas system node n; P j,d represents the electric power consumed by the power system node j; η P2G It represents the energy conversion efficiency of the P2G device;
[0130] (4) State estimation model of electricity-gas integrated energy system
[0131] Based on the above power system model, natural gas system model and coupling element model, the measurement equations of the power system and natural gas system are as follows:
[0132] 1) Power system measurement equations
[0133] The real-time measurement data of the power system include node voltage amplitude, node active injection power, node reactive injection power, branch active power and branch reactive power. The specific expression of the power grid measurement equation is as follows:
[0134]
[0135] Among them, the first equation represents the voltage amplitude measurement equation, the second and third equations represent the node active power injection measurement equation and reactive power injection measurement equation respectively, and the fourth and fifth equations represent the branch active power measurement equation and branch reactive power measurement equation respectively; In the formula, They represent the node voltage amplitude measurement, node injected active power measurement, node injected reactive power measurement, branch head end active power measurement and branch head end reactive power measurement of the power system respectively; They represent the node voltage amplitude measurement error, the node injected active power measurement error, the node injected reactive power measurement error, the branch head end active power measurement error, and the branch head end reactive power measurement error, respectively. It is generally assumed that the above errors obey Gaussian distribution; and denote the voltage amplitude estimation values of node i and node j respectively; represents the estimated value of the phase angle difference between nodes i and j; G ij and B ij Respectively represent the real and imaginary parts of the node admittance matrix; g ij and b ij They represent the branch series conductance and susceptance respectively; g si and b si denote the parallel conductance and susceptance on the node i side respectively;
[0136] 2) Natural gas system measurement equation
[0137] The real-time measurement data of the gas network includes node pressure, branch flow, and node flow. The gas network measurement equation is expressed as follows:
[0138]
[0139] Among them, the first equation represents the node pressure measurement equation, the second equation represents the pipeline branch flow measurement equation, and the third equation represents the node flow measurement equation. In the formula, They represent the node pressure measurement, pipeline branch flow measurement and node flow measurement of the natural gas system respectively. They represent the measurement error of node pressure, the measurement error of pipeline branch flow and the measurement error of node flow respectively, assuming that these errors obey Gaussian distribution; and Represents the estimated node pressure of node m and node n;
[0140] 3) State estimation model of electricity-gas integrated energy system
[0141] The state variable of the power system is the node complex voltage, so the grid state variable in polar coordinate form is expressed as: e =[V T ,θ T ] T , where V represents the column vector of node voltage amplitude, V i Represents the voltage amplitude of each node, i=1,2,...,N e ; θ represents the node voltage phase angle column vector, θ i Represents the node voltage phase angle except the balance node, i=1,2,...,N e -1. The state variable of the natural gas system is the node pressure, that is, x g =π, π represents the pressure column vector of the gas network node, π m Represents the pressure of each node in the gas network, N g Represents the total number of gas network nodes, m=1,2,...,N g ;
[0142] In summary, the state estimation model of the electric-gas integrated energy system based on the least squares criterion is constructed as follows:
[0143]
[0144] Where J(x) is the objective function to be optimized; e and z g Respectively represent the quantity measurement of the power grid and gas grid; h e (x e ) and h g (x g ) represent the measurement equations of the power grid and gas grid respectively; R e and R g They represent the measurement error covariance matrices of the power grid and the gas grid, respectively, and both are diagonal matrices; is the state variable of the electric-gas integrated energy system; c(x)=0 represents the zero equation constraint, including the zero injection equation constraint of the power grid and the gas grid and the electric-gas coupling element constraint;
[0145] The zero injection equality constraint of the power grid can be expressed as:
[0146]
[0147] in, They represent the active zero injection power and reactive zero injection power of the power grid, respectively. They are both power grid state quantities x e The function is denoted by c e (xe )=0;
[0148] The zero injection equality constraint of the gas grid is expressed as:
[0149]
[0150] in, Indicates the zero injection flow of the gas network node, which is the gas network state quantity x g The function is denoted by c g (x g )=0;
[0151] The electric-gas coupling constraint is expressed as follows:
[0152]
[0153] Among them, f m,d 、f n,s is the gas network state quantity x g The function of P i,g , P j,d is the power grid state quantity x e The function is denoted by c eg (x e ,x g )=0.
[0154] In summary,
[0155] Step 3: Based on the historical measurement data information and historical load curve of the gas grid, train the deep neural network model, optimize the model parameters, and save the trained model parameters and errors.
[0156] 3600 sets of electricity and gas load data were selected for IEGS multi-section power flow calculation to obtain the true value of the power flow, and Gaussian noise was added to simulate the real-time measurement value based on the true value of the power flow. The standard deviations of node voltage and power were set to 0.005 and 0.01, respectively, and the standard deviations of node pressure and flow were set to 0.01 and 0.015, respectively. The DNN model was trained according to the method in Section 2.1, with 1 to 3200 sets of data as training sets and 3201 to 3600 sets of data as test sets.
[0157] The present invention uses Python's Keras module to build a DNN model, and the model structure is as follows: the input layer has a total of 14 neurons for receiving real-time measurement data of the gas network; the output layer has a total of 7 neurons for outputting the flow of each load node in the gas network; the number of hidden layers is set to 4, and the number of neurons in each layer is set to 1024, 256, 128, and 32 respectively, and the activation function uses the ReLU function. The model is trained using the mean square error as the loss function, and Adadelta is used as the optimizer. Eight samples are trained in one iteration, and all samples are trained 64 times. The schematic diagram of the DNN model structure built by the present invention is shown in the figure. Figure 3 shown.
[0158] Step 4: During online calculation, the real-time measurement data of the gas grid is input into the model trained in the offline stage to quickly generate pseudo-measurements of gas grid load and flow. The real-time measurement and pseudo-measurements of the gas grid are then input into the gas grid state estimator. At the same time, the real-time measurement of the power grid is input into the power grid state estimator to perform state estimation of the power grid and the gas grid respectively.
[0159] Step 5: Interact the coupling element information at the electric-gas coupling boundary to determine whether the boundary constraints of the power grid and the gas grid are met. If so, output the estimation result; otherwise, update the boundary information and enter the next iteration.
[0160] 1) Input the grid and gas grid parameters to initialize the program;
[0161] 2) Using the real-time measurements inside the electricity and gas subsystems to perform grid state estimation and gas network state estimation respectively, when performing gas network state estimation, the real-time measurements of the gas network subsystem are first input into the DNN to generate pseudo-measurement values of gas network load and flow, and then the real-time measurements, virtual measurements and pseudo-measurements of the gas network are input into the gas network state estimator together;
[0162] 3) When the state estimation of a subsystem converges, its state quantity can be used to calculate the power and flow information of the coupling nodes in the system. Then, according to the energy conversion relationship of the coupling element, the power and flow of the coupling element calculated previously are converted into equivalent flow and power in another system, and used as pseudo-measurement to participate in the next iteration of the subsystem.
[0163] 4) Determine whether the power and flow information of the coupling element match. If the boundary constraint conditions are met, the loop ends; otherwise, the boundary coupling information is updated to enter the next iteration.
[0164] Let c = GT, P2G represent the coupling element gas turbine and P2G respectively. The coupling element constraint convergence criterion is as follows:
[0165]
[0166] In the formula, It represents the coupling node power calculated from the grid state quantity; It represents the coupling node flow calculated from the gas network state quantity; Indicates the flow rate of the gas network coupling node The equivalent grid coupling node power obtained by conversion; Represents the power of the grid-coupled node Equivalent gas network coupling node flow obtained by conversion; ε e and ε g They represent the boundary convergence thresholds of the power grid and the gas grid, respectively. The first formula represents the boundary constraint convergence criterion of the power grid, and the second formula represents the boundary constraint convergence criterion of the gas grid.
[0167] The following is a test of the method of the present invention.
[0168] (1) Pseudo-measurement model test
[0169] The test results of DNN pseudo-measurement modeling are as follows Figure 4 shown. Figure 4 The ±3% error range between the DNN output results of 24 consecutive cross-section load nodes 3 and their corresponding true values is shown. It can be seen that the load node flow pseudo-measurement value output by DNN can accurately track the change trend of load flow, and the overall error can be controlled within the ±3% error range.
[0170] The average relative error is used to measure the effect of pseudo-measurement modeling of each load node:
[0171]
[0172] In the formula, and f i They represent the estimated value of gas grid load node flow and the true value of gas grid load node flow output by DNN respectively, and T represents the number of samples in the test set.
[0173] The average relative error of the prediction results of each load node obtained based on DNN is as follows: Figure 5 As shown, it can be seen from the figure that the average relative error of each load node does not exceed 1.2%, indicating that the DNN pseudo-measurement modeling method proposed in the present invention has high accuracy.
[0174] (2) IEGS-SE effect test based on DNN pseudo-measurement modeling
[0175] 1) Filtering effect test
[0176] The root mean square error (RMSE) is used to quantitatively analyze the effect of IEGS-SE, and its calculation formula is as follows:
[0177]
[0178] In the formula, and x i They represent the estimated value and true value of the state quantity respectively, and n represents the total number of state quantities.
[0179] In view of the large uncertainty and prediction error of the traditional pseudo-measurement modeling method based on time series prediction, it is assumed here that the pseudo-measurement error obtained based on the traditional prediction method obeys the Gaussian distribution with 30% and 50% uncertainty. p30 indicates that the pseudo-measurement error obeys the Gaussian distribution of 30%, p50 indicates that the pseudo-measurement error obeys the Gaussian distribution of 50%, and DNN indicates that the pseudo-measurement value is generated by DNN. CSE represents the centralized electric-gas state estimation, and DSE represents the distributed electric-gas state estimation. In order to verify the advantages of the DNN pseudo-measurement modeling method proposed in the present invention over the traditional method, the following 6 methods are set up:
[0180] M1: Artifact-free measurement modeling, CSE
[0181] M2: DNN-based CSE
[0182] M3: Pseudo-free measurement modeling, DSE
[0183] M4: DSE based on 30% pseudo measurement error
[0184] M5: DSE based on 50% pseudo measurement error
[0185] M6: DNN-based DSE, i.e. the method in this paper
[0186] The RMSE comparison of the estimation results of different methods is shown in Table 1. It can be seen from the table that regardless of whether the CSE method or the DSE method is used, the DNN pseudo-measurement modeling can improve the estimation accuracy of the gas grid, verifying the accuracy of the DNN pseudo-measurement modeling. In addition, by comparing the impact of the DNN pseudo-measurement modeling method and the traditional pseudo-measurement modeling method on the gas grid estimation results, it can be seen that the DNN pseudo-measurement modeling is superior to the traditional method. The RMSE of the gas grid estimation results based on DNN is reduced by 28.11% and 28.53% compared with p30 and p50, respectively. It is worth noting that although the estimation accuracy of DSE is slightly lower than that of CSE, the estimation error is still in the same order of magnitude, which can meet the accuracy requirements of online estimation, indicating the effectiveness of the distributed algorithm proposed in the present invention. Since the measurement configuration of the power grid itself is more complete and the measurement accuracy is higher, whether or not DNN pseudo-measurement modeling is used has little effect on the results of the power grid SE.
[0187] Table 1 IEGS estimation results under different methods
[0188]
[0189]
[0190] 2) Computational efficiency test
[0191] The comparison between the computation time of the present invention and the computation time of the centralized state estimation (CSE) is shown in Table 2. The computation time of the proposed method is divided into two parts: offline computation and online computation. The offline computation time is the training time of the DNN, and the online computation time is divided into pseudo-measurement generation time and online SE time.
[0192] Table 2 IEGS-SE calculation time
[0193]
[0194] As can be seen from the table, the method proposed in the present invention has high computational efficiency. It should be noted that the online computing time of the present invention includes the time for DNN to generate pseudo-measurements and the maximum time for parallel state calculations of the electrical and gas subsystems. Compared with the CSE method, the computing time of the present invention is shortened by 40.83%. It should be pointed out that the training of DNN is completed in the offline stage and does not occupy the computing power resources of online computing. In the online application stage, it is only necessary to input the real-time measurement data into the DNN model obtained by offline training to quickly generate pseudo-measurement values. Since CSE needs to recalculate the overall Jacobian matrix and invert it in each iteration process, the computational burden is heavy; while the method of the present invention only needs to iterate in its respective subsystems, the computational scale is small, and the boundary constraints can be met by alternating 1 to 2 times at the boundary, so it has higher computational efficiency than CSE.
[0195] The above simulation results verify the effectiveness of the method proposed in the present invention. The present invention uses a deep neural network to establish a pseudo-measurement model of the load node flow of the natural gas system. In the online application stage, it can quickly generate high-precision pseudo-measurement data and improve the accuracy of online simulation of the gas network. In addition, the alternating iterative estimation strategy adopted by the present invention can protect the information privacy of the electricity and gas subsystems and has high online computing efficiency. It can accurately monitor the operating status of the electricity-gas integrated energy system in real time and support subsequent scheduling and control.
[0196] The specific implementation modes and examples of the present invention are described above, but the protection scope of the present invention is not limited thereto. Any changes or substitutions that can be easily conceived by a technician familiar with the technical field within the technical scope disclosed in the present invention should be included in the protection scope of the present invention.
Claims
1. A distributed state estimation method for an electric-gas integrated energy system based on deep learning pseudo-measurement modeling, characterized in that: The method comprises the following steps: Step 1: Obtain the operating parameter information of the electric-gas integrated energy system and initialize it; Step 2: Establish mathematical models of the power system, natural gas system and coupling elements respectively, and build a state estimation model of the electric-gas integrated energy system based on the mathematical models; Step 3: In the offline training phase, based on the historical measurement data information and historical load curve of the gas grid, the real-time measurement data of the gas grid is used as input, and the gas grid load node flow is used as output to train the deep neural network model, optimize the model parameters, and save the trained model parameters and errors; Step 4: during online calculation, the real-time measurement data of the gas grid is input into the model trained in the offline stage, pseudo-measurement of gas grid load and flow is quickly generated, the real-time measurement of the gas grid and the pseudo-measurement are input into the gas grid state estimator, the real-time measurement of the power grid is input into the power grid state estimator, and the state estimation of the power grid and the gas grid is performed respectively; Step 5: Perform distributed state estimation on the electricity-gas integrated energy system, perform coupling element information exchange at the electricity-gas coupling boundary, and determine whether the boundary constraints of the power grid and the gas grid are met. If so, output the estimation result; otherwise, update the boundary information and enter the next iteration; The model in step 2 is as follows: (1) Power system model The AC power flow equation is used to describe the steady-state model of the power system. The node power equation in polar coordinate form is as follows: Where P i and Q i Respectively represent the active power and reactive power injected into node i; V i and V j Represent the voltage amplitude of node i and node j respectively; N e represents the number of nodes in the power system; θ ij represents the voltage phase angle difference between nodes i and j; G ij and B ij denote the real and imaginary parts of the node admittance matrix respectively; (2) Natural gas system model The steady-state model of the natural gas system mainly includes the pipeline flow equation, the compressor branch equation and the node flow balance equation, which are described as follows: 1) Pipeline flow equation The flow equation of a natural gas pipeline without a compressor is described by the Weymouth equation, which is expressed as follows: In the formula, π m and π n Represent the pressure of node m and node n respectively; f mn,l represents the natural gas flow in pipeline l from node m to node n; C mn,l represents the Weymouth constant of the pipeline l; s mn,l is the variable that characterizes the direction of airflow in pipe l; 2) Compressor branch equation For booster station k, the power consumed by the compressor is H c,k The flow rate f flowing through the compressor branch c,k The relationship between them is expressed as: In the formula, B k is a parameter related to compressor temperature and efficiency factors; Z k is a constant related to the gas compressibility factor; Assuming that the compressor is gas-driven, that is, the power consumed by the compressor is provided by the natural gas system, the natural gas flow rate τ consumed by the compressor is c,k Calculate as follows: Where, α, β, γ are fuel coefficients; 3) Node flow balance equation The flow balance equation of node m in the gas network is expressed as: Where, L m and K m They represent the natural gas system pipeline branch set and the pressure station set connected to node m respectively; s c Indicates the direction of the compressor branch flow, 1 if it flows out from node m, and -1 otherwise; f m,source is the gas source injection flow connected to node m; f m,load is the gas load flow connected to node m; (3) Coupling element model Gas turbines GT and power-to-gas P2G devices are commonly used coupling elements in the electricity-gas integrated energy system. Their energy conversion relationships are described as follows: 1) GT model The relationship between the natural gas flow consumed by GT and the electrical power generated is: f m,d =η GT P i,g In the formula, f m,d represents the natural gas flow consumed by node m in the natural gas system; P i,g represents the electric power injected into the power system node i; η GT represents the energy conversion efficiency of GT; 2) P2G model The relationship between the electrical power consumed by P2G and the natural gas flow rate generated is: f n,s =η P2G P j,d In the formula, f n,s represents the natural gas flow injected into the natural gas system node n; P j,d represents the electric power consumed by power system node j; η P2G It represents the energy conversion efficiency of the P2G device; (4) State estimation model of electricity-gas integrated energy system Based on the above power system model, natural gas system model and coupling element model, the measurement equations of the power system and natural gas system are as follows: 1) Power system measurement equations The real-time measurement data of the power system include node voltage amplitude, node active injection power, node reactive injection power, branch active power and branch reactive power. The specific expression of the power grid measurement equation is as follows: Among them, the first equation represents the voltage amplitude measurement equation, the second and third equations represent the node active power injection measurement equation and reactive power injection measurement equation respectively, and the fourth and fifth equations represent the branch active power measurement equation and branch reactive power measurement equation respectively; In the formula, V i meas ,P i meas , They represent the node voltage amplitude measurement, node injected active power measurement, node injected reactive power measurement, branch head end active power measurement and branch head end reactive power measurement of the power system respectively; They represent the node voltage amplitude measurement error, the node injected active power measurement error, the node injected reactive power measurement error, the branch head end active power measurement error, and the branch head end reactive power measurement error, respectively. It is generally assumed that the above errors obey Gaussian distribution; and denote the voltage amplitude estimation values of node i and node j respectively; represents the estimated value of the phase angle difference between nodes i and j; G ij and B ij Respectively represent the real and imaginary parts of the node admittance matrix; g ij and b ij They represent the branch series conductance and susceptance respectively; g si and b si denote the parallel conductance and susceptance on the node i side respectively; 2) Natural gas system measurement equation The real-time measurement data of the gas network includes node pressure, branch flow, and node flow. The gas network measurement equation is expressed as follows: Among them, the first equation represents the node pressure measurement equation, the second equation represents the pipeline branch flow measurement equation, and the third equation represents the node flow measurement equation. In the formula, They represent the node pressure measurement, pipeline branch flow measurement and node flow measurement of the natural gas system respectively. They represent the measurement error of node pressure, the measurement error of pipeline branch flow and the measurement error of node flow respectively, assuming that these errors obey Gaussian distribution; and Represents the estimated node pressure of node m and node n; 3) State estimation model of electricity-gas integrated energy system The state variable of the power system is the node complex voltage, so the grid state variable in polar coordinate form is expressed as: e =[V T ,θ T ] T , where V represents the column vector of node voltage amplitude, V i Represents the voltage amplitude of each node, i=1,2,...,N e ; θ represents the node voltage phase angle column vector, θ i Represents the node voltage phase angle except the balance node, i=1,2,...,N e -1, the state variable of the natural gas system is the node pressure, that is, x g =π, π represents the pressure column vector of the gas network node, π m Represents the pressure of each node in the gas network, N g Represents the total number of gas network nodes, m=1,2,...,N g ; In summary, the state estimation model of the electric-gas integrated energy system based on the least squares criterion is constructed as follows: Where J(x) is the objective function to be optimized; e and z g Respectively represent the quantity measurement of the power grid and gas grid; h e (x e ) and h g (x g ) represent the measurement equations of the power grid and gas grid respectively; R e and R g They represent the measurement error covariance matrices of the power grid and the gas grid, respectively, and both are diagonal matrices; is the state variable of the electric-gas integrated energy system; c(x)=0 represents the zero equation constraint, including the zero injection equation constraint of the power grid and the gas grid and the electric-gas coupling element constraint; The zero injection equality constraint of the power grid is expressed as: in, They represent the active zero injection power and reactive zero injection power of the power grid, respectively. They are both power grid state quantities x e The function is denoted by c e (x e )=0; The zero injection equality constraint of the gas grid is expressed as: in, Indicates the zero injection flow of the gas network node, which is the gas network state quantity x g The function is denoted by c g (x g )=0; The electric-gas coupling constraint is expressed as follows: Among them, f m,d 、f n,s is the gas network state quantity x g The function of P i,g , P j,d is the power grid state quantity x e The function is denoted by c eg (x e ,x g )=0; In summary, 2. According to claim 1, a distributed state estimation method for an electric-gas integrated energy system based on deep learning pseudo-measurement modeling is characterized in that: In step 1, the operating parameter information of the electric-gas integrated energy system is obtained, which is as follows: the power grid operating parameter information includes generator output information, power line parameters, power grid load factor and load curve, and power grid measurement configuration information; the gas grid operating parameters include natural gas pipeline parameters, compressor branch parameters, gas source information, gas grid load factor and load curve, and gas grid measurement configuration information; the coupling element information includes gas turbine and power-to-gas device parameters and their energy conversion efficiency.
3. According to claim 1, a distributed state estimation method for an electric-gas integrated energy system based on deep learning pseudo-measurement modeling is characterized in that: Step 3 includes the following contents: using deep neural network (DNN) to establish a pseudo measurement model of gas grid load node flow, and using the nonlinear fitting ability of DNN to predict gas grid load node flow. The deep neural network pseudo measurement modeling includes two parts: offline training and online application, which are as follows: (1) The offline training process of DNN includes the following steps: 1) Using the historical load curves of electricity and gas, the steady-state power flow calculation of the electricity-gas integrated energy system is carried out to obtain the true value corresponding to the node pressure and branch flow measurement of the gas network configured with real-time measurement; 2) Superimpose Gaussian noise on the true value obtained by power flow calculation to simulate real-time measurement data; 3) Train DNN with real-time gas grid measurement data as input and load node flow as output; 4) Save the trained DNN model parameters and errors; (2) Online Application In the online application stage, the real-time gas network measurement data collected is input into the DNN model trained in the offline stage to obtain the pseudo-measurement value of the load node flow. When estimating the gas network state separately, the real-time gas network measurement, virtual measurement and pseudo-measurement are input into the gas network state estimator for calculation to obtain the gas network estimation result. When estimating the electricity-gas coupling state, DNN is first used to generate pseudo-measurement values of the gas grid load flow, and then the state estimation inside the electricity and gas subsystems is performed separately. Through alternating iterations until the boundary condition constraints of the electricity and gas subsystems are met, the estimation results of the power grid and gas grid are finally output.
4. According to claim 1, a distributed state estimation method for an electric-gas integrated energy system based on deep learning pseudo-measurement modeling is characterized in that: In step 5, the electric-gas distributed state estimation includes the following: 1) Execute state estimation of the electrical and gas subsystems respectively. When the state estimation of a subsystem converges, use its state quantity to calculate the power and flow information of the coupling nodes in the system. According to the energy conversion relationship of the coupling element, the power and flow of the coupling element calculated previously are converted into equivalent flow and power in another system, and used as pseudo-measurement to participate in the next iteration of the subsystem. 2) Determine whether the power and flow information of the coupling element match. If the boundary constraint condition is met, the loop ends; otherwise, the boundary coupling information is updated to enter the next iteration; Let c = GT, P2G represent the coupling element gas turbine and P2G respectively, and the coupling element constraint convergence criterion is as follows: In the formula, It represents the coupling node power calculated from the grid state quantity; It represents the coupling node flow calculated from the gas network state quantity; Indicates the flow rate of the gas network coupling node The equivalent grid coupling node power obtained by conversion; Represents the power of the grid-coupled node The equivalent gas network coupling node flow obtained by conversion; ε e and ε g They represent the boundary convergence thresholds of the power grid and the gas grid respectively. The first formula represents the power grid boundary constraint convergence criterion, and the second formula represents the gas grid boundary constraint convergence criterion.
Citation Information
Patent Citations
Solar heat pump hot water system control strategy optimization method based on machine learning
CN110906571A
Optimal energy flow stochastic optimization method of electricity-water combined system based on data driving
CN115049098A