A method for optimizing the operation of a gas-electric coupling system

By randomly generating allocation coefficients in the gas-electric coupling system and optimizing using genetic algorithms, the problems of fixed allocation coefficients and single energy flow paths in the prior art are solved, and the operating cost and flexibility of the gas-electric coupling system are minimized.

CN110119855BActive Publication Date: 2025-05-13STATE GRID SHANGHAI MUNICIPAL ELECTRIC POWER CO +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN201910500700.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2019-06-11
Publication Date
2025-05-13
Estimated Expiration
2039-06-11

AI Technical Summary

Technical Problem

When the existing gas-electric coupling system optimizes the scheduling, the distribution coefficient of the equipment is fixed and the energy flow path is single, so it is impossible to achieve optimal energy distribution under the demand response of real-time energy prices.

Method used

A gas-electric coupling system operation optimization method is adopted, and the distribution coefficients of thermal load and electrical load are randomly generated, combined with genetic algorithms, the population samples are gradually optimized to meet the constraints and minimize the operating cost.

Benefits of technology

Quickly and accurately minimizes the operating cost of the gas-electric coupling system, taking into account constraints such as equipment capacity and network trends, and improving the economic and flexibility of the system operation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN110119855B_ABST
    Figure CN110119855B_ABST
Patent Text Reader

Abstract

The present invention discloses a method for optimizing the operation of a gas-electricity coupling system, comprising the following steps: a data reading step, a sample generating step, a population sample number determining step, a maximum population algebra setting step, a population sample calculating step, a population sample determining step, a genetic operation step, a population algebra determining step and an optimal solution outputting step; by optimizing the energy management based on the real-time demand of natural gas load and electric load, an energy center model is established based on the concept of energy hub, the energy center model contains energy conversion equipment including transformers, cogeneration units, gas boilers, heat pumps and lithium bromide units to provide flexible energy flow path selection, and takes the minimization of the operation cost of the gas-electricity coupling system as the goal, taking into account constraints including equipment capacity and network flow.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to a gas-electricity coupling system operation optimization method in the field of energy integration optimization. Background Art

[0002] Developing new energy, improving energy utilization and the ability to absorb renewable energy are the keys to solving increasingly severe energy and environmental problems, which puts forward an urgent need for the integrated optimization of multiple energy sources.

[0003] Multi-energy complementation is to use multiple energy sources to complement each other according to different resource conditions and energy users to alleviate the contradiction between supply and demand of a certain energy shortage. The document "Optimal power flow of multi-ple energy carriers" proposed the concept of energy hub. According to the user's demand for electricity, heat and cold multi-energy loads, the energy center composed of multiple easily controllable energy sources such as gas turbines, air conditioners, heat pumps, etc., performs optimal energy distribution to meet the user's economic and environmental protection needs. Based on this theory, the document "Modeling and simulation of multi-vector energy systems" built multiple energy center models with different structures and applied them in the electric-gas coupling system to study its feasibility for grid voltage regulation. The document "Multi-objective optimal hybrid power flow algorithm for regional integrated energy system" considers the relevant constraints of three-phase unbalanced distribution system, natural gas pipeline network and energy center, and proposes a multi-objective optimal power flow algorithm based on the real-time electricity price with the goal of minimizing the operating economic cost and minimizing the pollution emission. The above studies are all based on the concept of energy hub when analyzing and optimizing the gas-electricity coupling system. However, the allocation coefficients of different devices in the established energy center model are fixed and the energy flow path is single. However, when considering the demand response of real-time energy prices, the energy conversion characteristics and forward and backward interaction mechanisms of different devices provide optimization space for their energy distribution. Summary of the invention

[0004] The purpose of the present invention is to overcome the deficiencies of the prior art and to provide a method for optimizing the operation of a gas-electric coupling system, which can quickly and accurately achieve the goal of minimizing the operating cost of the gas-electric coupling system.

[0005] A technical solution to achieve the above object is: a method for optimizing the operation of a gas-electric coupling system, comprising the following steps:

[0006] Data reading steps: reset the population sample number x to zero, and read the system parameters of the gas-electric coupling system;

[0007] Sample generation step: Randomly generate the distribution coefficient v of the heat load at the current moment 1,x and the current load distribution coefficient v3,x , obtaining an initial sample, and calculating the operating cost of the initial sample according to the system parameters of the gas-electric coupling system read in the data reading step;

[0008] Constraint condition determination step: determine whether the initial sample meets the constraint condition;

[0009] If the initial sample does not meet the constraints, return to the sample generation step;

[0010] If the initial sample meets the constraint conditions, then the initial sample is put into the population as a population sample of the population, and the number of population samples x=x+1;

[0011] Population sample number determination step: if the population sample number x is lower than the set value, return to the sample generation step; if the population sample number x reaches the set value, enter the maximum population generation setting step;

[0012] The maximum population generation setting steps: set the value of the maximum population generation y_max, set the population generation y = 1, and set the v of each population sample in the population 1,x =v 1,x,y , v 3,x =v 3,x,y ;

[0013] Population sample calculation step: Calculate the operating cost F of each population sample in the population based on the system parameters read in the data reading step;

[0014] Population sample determination step: determine whether each population sample in the population satisfies the constraint conditions;

[0015] If any sample in the population satisfies the constraint condition, then the fitness of the sample is

[0016] If any sample in the population does not meet the constraint condition, the fitness of the sample is set to M = 0;

[0017] Genetic operation steps: retain the population sample with the largest fitness M in the population, perform genetic operations on the remaining population samples in the population to form a new population;

[0018] Population generation determination step: determine whether the population generation y is greater than y_max;

[0019] If y≤y_max, set y=y+1 and return to the population sample calculation step;

[0020] If y>y_max, then enter the step of outputting the optimal solution;

[0021] Output optimal solution step: Output the population samples retained in the genetic operation step.

[0022] Furthermore, the system parameters of the gas-electric coupling system read in the data reading step include: the efficiency η of the transformer T , power generation efficiency of cogeneration units Heating efficiency of combined heat and power units Thermal efficiency η of gas boiler B , Energy efficiency coefficient η of heat pump C 、Energy efficiency coefficient η of lithium bromide unit D , calorific value of methane g CH4 、Current electrical load demand L e 、Current cooling load demand L c 、The current heat load demand L h 、Current natural gas load demand L g 、Current electricity price e and the current natural gas price C g ;

[0023] Through the coupling matrix And the formula The electric power P of the input side of the initial sample is calculated e and the natural gas power P on the input side of the initial sample g ;

[0024] According to formula G g =P g / g CH4 , and obtain the natural gas flow G required to be purchased for the initial sample g ;

[0025] According to the formula F=C e P e +C g G g , calculate the running cost F of this initial sample.

[0026] Furthermore, the constraints in the constraint determination step include energy center model constraints:

[0027] P g (1-v 1,x )≤S A ;P g v 1,x ≤S B ;

[0028]

[0029] as well as

[0030] Where S A is the capacity of the cogeneration unit, S B is the capacity of the gas boiler, S C is the capacity of the heat pump, S D is the capacity of the lithium bromide unit, P e,max is the upper limit of the purchased electric power, G g,max is the upper limit of the natural gas flow purchased; v 2,x is the distribution coefficient of the cooling load at the current moment, and the calculation formula is:

[0031]

[0032] Furthermore, the constraints in the population sample determination step include energy center model constraints:

[0033] P g (1-v 1,x,y )≤S A ;P g v 1,x,y ≤S B ;

[0034]

[0035] as well as

[0036] in,

[0037] Furthermore, the constraints in the constraint condition determination step and the population sample determination step also include:

[0038] Node voltage constraint: U i,min ≤U i ≤U i,max ;

[0039] Branch power constraint: S ij,min ≤S ij ≤S ij,max , where j∈i;

[0040] Gas node pressure constraint p h,min ≤p h ≤p h,max ;

[0041] Natural gas pipeline flow constraints n,min ≤f n,t ≤f n,max ;

[0042] U i,min , Ui,max are the upper and lower limits of the voltage amplitude of the grid node i in the gas-electricity coupling system; U i is the voltage amplitude of the grid node i in the gas-electricity coupling system at the current moment; S ij,min and S ij,max are the upper and lower power limits allowed for the line segment connecting grid node i and grid node j in the gas-electricity coupling system; S ij is the power value of the line segment connecting grid node i and grid node j in the electric coupling system at the current moment, j∈i means that grid node j is directly connected to grid node i, p h,min and p h,max are the upper and lower limits of pressure at the natural gas pipeline node h in the gas-electricity coupling system; p h is the pressure of the natural gas pipeline node h in the gas-electricity coupling system at the current moment; f n,min and f n,max are the upper and lower flow limits of natural gas pipeline n in the gas-electricity coupling system at the current moment; f n is the flow rate of natural gas pipeline n in the gas-electricity coupling system at the current moment.

[0043] Furthermore, the set value of the population sample number x is 50.

[0044] Furthermore, the genetic operation in the genetic operation step is a crossover operation and / or a mutation operation.

[0045] Furthermore, the method is performed once every hour.

[0046] The technical solution of the gas-electric coupling system operation optimization method of the present invention is adopted, which includes the following steps: data reading step: clearing the population sample number x and reading the system parameters of the gas-electric coupling system; sample generation step: randomly generating the distribution coefficient v of the heat load at the current moment 1,x and the current load distribution coefficient v 3,x , obtain an initial sample, and calculate the operating cost of the initial sample according to the system parameters of the gas-electric coupling system read in the data reading step; constraint condition determination step: determine whether the initial sample meets the constraint conditions; if the initial sample does not meet the constraint conditions, return to the sample generation step; if the initial sample meets the constraint conditions, put the initial sample into the population as a population sample of the population, and set the population sample number x=x+1; population sample number determination step: if the population sample number x is lower than the set value, return to the sample generation step; if the population sample number x reaches the set value, enter the maximum population algebra setting step; maximum population algebra setting step: set the value of the maximum population algebra y_max, set the population algebra y=1, and set the v of each population sample in the population 1,x =v 1,x,y , v3,x =v 3,x,y ; Population sample calculation step: Calculate the operating cost F of each population sample in the population according to the system parameters read in the data reading step; Population sample determination step: Determine whether each population sample in the population meets the constraint conditions; If any population sample in the population meets the constraint conditions, set the fitness of the population sample If any population sample in the population does not meet the constraint condition, the fitness M of the population sample is set to 0; genetic operation step: retain the population sample with the largest fitness M in the population, perform genetic operation on the remaining population samples in the population to form a new population; population algebra determination step: determine whether the population algebra y is equal to y_max; if y≤y_max, set y=y+1 and return to the population sample calculation step; if y>y_max, enter the optimal solution output step; output optimal solution step: output the population sample retained in the genetic operation step. Its technical effect is: quickly and accurately achieve the goal of minimizing the operating cost of the gas-electric coupling system, taking into account the constraints including equipment capacity and network flow. BRIEF DESCRIPTION OF THE DRAWINGS

[0047] Figure 1 This is the structural diagram of the energy center model.

[0048] Figure 2 The present invention is a flow chart of a genetic algorithm in a method for optimizing the operation of a gas-electric coupling system.

[0049] Figure 3 Flowchart of running an optimization method for a gas-electric coupled system.

[0050] Figure 4 This is the fitness evolution curve.

[0051] Figure 5 This is a comparison chart of the energy purchase cost of a gas-electricity coupling system operation optimization method of the present invention and a traditional method.

[0052] Figure 6 This is the diagram of changes in electricity load demand.

[0053] Figure 7 Energy center model load demand change diagram.

[0054] Figure 8 This is the structural diagram of the gas-electric coupling system. DETAILED DESCRIPTION

[0055] See also Figures 1 to 8 In order to better understand the technical solution of the present invention, the inventor of the present invention will explain in detail through specific embodiments and in conjunction with the accompanying drawings:

[0056] See also Figure 1The present invention provides a method for optimizing the operation of a gas-electric coupling system, which considers the gas-electric coupling of the optimal energy flow path of energy conversion equipment including transformers, combined heat and power units (CHP), gas boilers, heat pumps and lithium bromide units in the gas-electric coupling system, and the method for optimizing the operation of the gas-electric coupling system. Considering the demand response of real-time electricity prices and natural gas prices, firstly, an energy center model of energy conversion equipment including transformers, combined heat and power units, gas boilers, heat pumps and lithium bromide units is established based on the energy hub theory, and the optimal energy flow path is determined by real-time allocation of energy; with the goal of minimizing the system energy purchase cost, the optimal power flow mathematical model is established taking into account the equipment capacity constraints and network power flow constraints, and the genetic algorithm is applied to solve it.

[0057] Considering the time-varying electricity load demand, cooling load demand, heating load demand and natural gas load demand, the decoupled power flow calculation of the gas-electricity coupling system was carried out based on the Newton-Raphson algorithm. It was verified that the established energy center model can improve the economy of the system operation, obtain the optimal energy flow path at different times and analyze the reasons for its changes.

[0058] A method for optimizing the operation of a gas-electric coupling system of the present invention comprises the following models:

[0059] Power network flow model:

[0060] The power network flow equation is as follows:

[0061]

[0062]

[0063] Among them, P i ele and are respectively the active power and reactive power injected into the grid node i by the outside world at the current moment; j∈i means that the grid node j is all the grid nodes directly connected to the grid node i; U i Indicates the voltage amplitude of grid node i at the current moment, U j represents the voltage amplitude of grid node j at the current moment, G ij and B ij are the real and imaginary parts of the node admittance matrix respectively; θ ij is the voltage phase angle difference between grid node i and grid node j at the current moment.

[0064] The constraints of the power network flow model include:

[0065] Node voltage constraint: U i,min ≤U i ≤U i,max ;

[0066] Where Ui,min and U i,max are the upper limit and lower limit of the voltage amplitude of the grid node i respectively;

[0067] Branch power constraint: S ij,min ≤S ij ≤S ij,max ;

[0068] In the formula, S ij,min and S ij,max are the upper and lower power limits allowed for the line segment connecting grid node i and grid node j in the gas-electricity coupling system.

[0069] Natural gas pipeline network model

[0070] The natural gas pipeline network can be based on Kirchhoff's current law in the circuit. The load of any natural gas pipeline node h is equal to the sum of the inflow flow and the outflow flow, that is: G = AF; where G is the load column vector of all nodes; F is the flow column vector of the branch pipeline, which is composed of all pipeline flow equations; A is the branch-node association matrix.

[0071] In the natural gas pipeline network, the pipeline flow equation can be approximated as a function of the pipeline coefficient and the pressure drop between pipelines, that is:

[0072] In the formula, p h and p l are the pressure of the natural gas pipeline node h at the current moment and the pressure of the natural gas pipeline node l at the current moment, respectively, n is the flow rate of natural gas pipeline n between natural gas pipeline node h and natural gas pipeline node l; T hl In p h >p l When it is 1, otherwise it is -1; K is the pipeline constant of the pipeline between the natural gas pipeline node h and the natural gas pipeline node l.

[0073] The constraints of the natural gas pipeline network model include:

[0074] Nodal pressure constraint: p h,min ≤p h ≤p h,max ;

[0075] p h,min and p h,max are the upper and lower pressure limits of the natural gas pipeline node h respectively.

[0076] Pipeline flow constraint: f n,min ≤f n ≤f n,max ;

[0077] f n,minand f n,max They are the upper and lower limits of the flow rate of pipeline n between natural gas pipeline node h and natural gas pipeline node l respectively.

[0078] Energy Center Model

[0079] The energy consumption links on the load side include energy conversion equipment including transformers, cogeneration units, gas boilers, heat pumps and lithium bromide units, short-distance energy supply networks, distributed power sources, etc. The energy center model established on the load side based on the concept of energy hub expresses the conversion relationship of different forms of energy through a coupling matrix, and the energy flow through the energy conversion equipment is characterized only by power and efficiency.

[0080] In the energy center model, electricity and natural gas are converted through coupling elements to meet users' needs for various energy loads. The cogeneration unit is set as a constant heat ratio unit, and cold and hot energy interact through the lithium bromide unit. The energy flow path is characterized by the distribution coefficient. The electric-driven heat pump can change the working state according to the difference in cold and hot loads in winter and summer, thereby improving the flexibility of system operation. The heat pump is used for cooling in summer.

[0081] The mathematical expression of the energy center model is as follows:

[0082]

[0083] L e is the current electrical load demand, L c is the cooling load demand at the current moment, L h is the heat load demand at the current moment, L g is the natural gas load demand at the current moment. e is the electric power on the input side at the current moment.

[0084] Let v1 be the current heat load distribution coefficient, v2 be the current cold load distribution coefficient, and v3 be the current electricity load distribution coefficient; P g It is the natural gas power on the input side at the current moment.

[0085] The matrix X is the coupling matrix, which is determined by the distribution coefficient and the efficiency of the energy conversion element, that is, the system parameters of the gas-electric coupling system. The system parameters include: the efficiency η of the transformer T , power generation efficiency of cogeneration units Heating efficiency of combined heat and power units Thermal efficiency η of gas boiler B , Energy efficiency coefficient η of heat pump C 、Energy efficiency coefficient η of lithium bromide unit D , calorific value of methane g CH4 、Current electrical load demand L e、Current cooling load demand L c 、The current heat load demand L h 、Current natural gas load demand L g 、Current electricity price e and the current natural gas price C g ; The matrix X is:

[0086]

[0087] It can be seen from the matrix X that there is no direct coupling relationship between the heat load and the power supply, so the heat load and the cooling load can be combined into one item.

[0088] From the equation group, the relationship between the distribution coefficient v2 of the cooling load and the distribution coefficient v1 of the heating load at the current moment is as follows:

[0089]

[0090] The simplified mathematical expression of matrix X is:

[0091]

[0092] By formula And the formula can be obtained G g =P g / g CH4 The electric power P on the input side can be obtained e and the natural gas power P on the input side g .

[0093] According to formula G g =P g / g CH4 , get the natural gas flow G to be purchased g .

[0094] The internal constraints of the Energy Center include:

[0095] Cogeneration unit capacity constraint: P g (1-v1)≤S A ; where S A It is the capacity of the cogeneration unit and does not take its reactive power output into account.

[0096] Gas boiler capacity constraint: P g v1≤S B , where S B is the capacity of the gas boiler.

[0097] Heat pump capacity constraints: Where S C is the capacity of the heat pump.

[0098] Lithium bromide unit capacity constraints: Where S D is the capacity of the lithium bromide unit.

[0099] Partition coefficient constraints:

[0100]

[0101] Energy supply constraints:

[0102]

[0103] P e,max is the upper limit of the purchased electric power, G g,max The upper limit of the natural gas flow purchased is mainly determined by the capacity of the energy conversion equipment and the security constraints of the network.

[0104] Optimal Power Flow Model for Gas-Electric Coupled System

[0105] The optimal power flow mathematical model of the gas-electric coupling system is constructed with the goal of minimizing the economic cost of system operation. The objective function is shown in the following formula:

[0106] minF=C e P e +C g G g ;

[0107] The objective function consists of two parts: electricity purchase cost and gas purchase cost. e is the current electricity price, C g is the natural gas price at the current moment. The input power P e and the natural gas flow G to be purchased g They are all functions of the distribution coefficient v1 of the thermal load at the current moment and the distribution coefficient v3 of the electric load at the current moment. The load distribution coefficient v1 and the distribution coefficient v3 of the electric load at the current moment are used as decision variables to be optimized, which determine the energy flow path of the energy center model at the current moment.

[0108] A method for optimizing the operation of a gas-electric coupling system of the present invention adopts a genetic algorithm to solve the problem, and comprises the following steps:

[0109] Data reading steps: reset the population sample number x to zero, and read the system parameters of the gas-electric coupling system, including: the efficiency η of the transformer T , power generation efficiency of cogeneration units Heating efficiency of combined heat and power units Thermal efficiency η of gas boiler B , Energy efficiency coefficient η of heat pump C 、Energy efficiency coefficient η of lithium bromide unit D , calorific value of methane g CH4 、Current electrical load demand L e、Current cooling load demand L c 、The current heat load demand L h 、Current natural gas load demand L g 、Current electricity price e and the current natural gas price C g ;

[0110] Sample generation step: Randomly generate the initial current heat load distribution coefficient v 1,x and the current load distribution coefficient v 3,x , get an initial sample,

[0111] Generate the coupling matrix based on the system parameters read in the data reading step:

[0112]

[0113] And the formula The electric power P of the input side of the initial sample is calculated e and the natural gas power P on the input side of the initial sample g .

[0114] According to formula G g =P g / g CH4 , calculate the natural gas flow G required to be purchased at the current moment g .

[0115] And solve the running cost of the initial sample, F = C e P e (v 1,x ,v 3,x )+C g G g (v1,v 3,x ).

[0116] Constraint condition determination step: determine whether the initial sample meets the constraint condition;

[0117] If the initial sample does not meet the constraints, return to the sample generation step;

[0118] If the initial sample meets the constraint conditions, then the initial sample is put into the population as a population sample of the population, and the number of population samples x=x+1;

[0119] The constraints include: Energy center model constraints:

[0120] P g (1-v 1,x )≤S A ;P g v 1,x ≤SB ;

[0121]

[0122] as well as

[0123] Where S A is the capacity of the cogeneration unit, S B is the capacity of the gas boiler, S C is the capacity of the heat pump, S D is the capacity of the lithium bromide unit, P e,max is the upper limit of the purchased electric power, G g,max The upper limit of the natural gas flow purchased;

[0124] v 2,x is the distribution coefficient of the cooling load at the current moment, and the calculation formula is:

[0125]

[0126] The constraints also include: node voltage constraint: U i,min ≤U i ≤U i,max ;

[0127] Branch power constraint: S ij,min ≤S ij ≤S ij,max , where j∈i;

[0128] Gas node pressure constraint p h,min ≤p h ≤p h,max ;

[0129] Natural gas pipeline flow constraints n,min ≤f n ≤f n,max .

[0130] Population sample number determination step: if the population sample number x is lower than the set value, return to the sample generation step; if the population sample number x reaches the set value, enter the maximum population generation setting step; the set value can be set to 50.

[0131] The maximum population generation setting steps: set the value of the maximum population generation y_max, set the population generation y = 1, and set the v of each population sample in the population 1,x =v 1,x,y , v 3,x =v 3,x,y .

[0132] Population sample calculation step: Calculate the operating cost of each population sample in the population based on the system parameters read in the data reading step;

[0133] Generate the coupling matrix based on the system parameters of the gas-electric coupling system read in the data reading step:

[0134]

[0135] And the formula Calculate the input power P of each population sample e and the natural gas power P on the input side of each population sample g .

[0136] According to formula G g =P g / g CH4 , calculate the natural gas flow G required to be purchased by each population sample at the current moment g .

[0137] And solve the running cost F of each population sample.

[0138] Population sample determination step: determine whether each population sample in the population satisfies the constraint conditions;

[0139] If any sample in the population satisfies the constraint condition, then the fitness of the sample is

[0140] If any sample in the population does not meet the constraint condition, the fitness of the sample is set to M = 0;

[0141] The constraints in the population sample determination step include the energy center model constraints:

[0142] P g (1-v 1,x,y )≤S A ;P g v 1,x,y ≤S B ;

[0143]

[0144] as well as

[0145] in,

[0146] The constraints in the population determination step also include:

[0147] Branch power constraint: S ij,min ≤Sij ≤S ij,max , where j∈i;

[0148] Gas node pressure constraint p h,min ≤p h ≤p h,max ;

[0149] Natural gas pipeline flow constraints n,min ≤f n,t ≤f n,max .

[0150] Genetic operation steps: retain the population sample with the largest fitness M in the population, and randomly perform genetic operations on the remaining population samples in the population to form a new population.

[0151] Genetic operations include crossover and mutation operations. The crossover operation is to exchange v between any two samples in the population. 1,x,y and v 3,x,y Any element in the population. The mutation operation regenerates v for any sample in the population 1,x,y and v 3,x,y The value of any element in .

[0152] Population generation determination step: determine whether the population generation y is greater than y_max;

[0153] If y≤y_max, set y=y+1 and return to the population sample calculation step;

[0154] If y>y_max, then enter the step of outputting the optimal solution;

[0155] Output optimal solution step: Output the population samples retained in the genetic operation step.

[0156] A method for optimizing the operation of a gas-electric coupling system of the present invention can determine the optimal energy flow path through real-time allocation of energy; taking the minimum system energy purchase cost as the goal, taking into account the equipment capacity constraints and network flow constraints, establishing an optimal power flow mathematical model, and applying a genetic algorithm to solve it; considering time-varying load demand, decoupling power flow calculations for the electrical coupling system are performed based on the Newton-Raphson algorithm, and abnormal individuals are excluded, so that each individual in the population is a valid solution, thereby improving the speed of solving discrete optimization problems.

[0157] The above embodiments are used to illustrate the present invention rather than to limit the present invention. As long as they are within the essential spirit of the present invention, any changes and modifications to the above embodiments will fall within the scope of the claims of the present invention.

Claims

1. A method for optimizing the operation of a gas-electric coupling system, comprising the following steps: Data reading steps: reset the population sample number x to zero, and read the system parameters of the gas-electric coupling system; Sample generation step: Randomly generate the distribution coefficient v of the heat load at the current moment 1,x and the current load distribution coefficient v 3,x , obtaining an initial sample, and calculating the operating cost of the initial sample according to the system parameters of the gas-electric coupling system read in the data reading step; Constraint determination step: determine whether the initial sample meets the constraint conditions; If the initial sample does not meet the constraints, return to the sample generation step; If the initial sample meets the constraint conditions, then the initial sample is put into the population as a population sample of the population, and the number of population samples x=x+1; Population sample number determination step: if the population sample number x is lower than the set value, return to the sample generation step; if the population sample number x reaches the set value, enter the maximum population generation setting step; The maximum population generation setting steps are as follows: set the value of the maximum population generation y_max, set the population generation y = 1, and set the v of each population sample in the population 1,x =v 1,x,y , v 3,x =v 3,x,y ; Population sample calculation step: Calculate the operating cost F of each population sample in the population based on the system parameters read in the data reading step; Population sample determination step: determine whether each population sample in the population satisfies the constraint conditions; If any sample in the population satisfies the constraint condition, then the fitness of the sample is If any sample in the population does not meet the constraint condition, the fitness of the sample is set to M = 0; Genetic operation steps: retain the population sample with the largest fitness M in the population, perform genetic operations on the remaining population samples in the population to form a new population; Population generation determination step: determine whether the population generation y is greater than y_max; If y≤y_max, set y=y+1 and return to the population sample calculation step; If y>y_max, then enter the step of outputting the optimal solution; Output optimal solution step: Output the population sample retained in the genetic operation step, The system parameters of the gas-electric coupling system read in the data reading step include: the efficiency η of the transformer T , power generation efficiency of cogeneration units Heating efficiency of combined heat and power units Thermal efficiency η of gas boiler B , Energy efficiency coefficient η of heat pump C 、Energy efficiency coefficient η of lithium bromide unit D , calorific value of methane g CH4 、Current electrical load demand L e 、Current cooling load demand L c 、The current heat load demand L h 、Current natural gas load demand L g 、Current electricity price e and the current natural gas price C g ; Through the coupling matrix And the formula The electric power P of the input side of the initial sample is calculated e and the natural gas power P on the input side of the initial sample g ; According to formula G g =P g / g CH4 , and obtain the natural gas flow G required to be purchased for the initial sample g ; According to the formula F=C e P e +C g G g , calculate the running cost F of this initial sample, The constraints in the constraint determination step include energy center model constraints: as well as Where S A is the capacity of the cogeneration unit, S B is the capacity of the gas boiler, S C is the capacity of the heat pump, S D is the capacity of the lithium bromide unit, P e,max is the upper limit of the purchased electric power, G g,max is the upper limit of the natural gas flow purchased; v 2,x is the distribution coefficient of the cooling load at the current moment, and the calculation formula is:

2. The method for optimizing the operation of a gas-electric coupling system according to claim 1, characterized in that: The constraints in the population sample determination step include the energy center model constraints: P g (1-in 1,x,y )≤S A ;P g in 1,x,y ≤S B ; as well as in, 3. The method for optimizing the operation of a gas-electric coupling system according to claim 1, characterized in that: The constraints in the constraint condition determination step and the population sample determination step also include: Node voltage constraint: U i,min ≤U i ≤U i,max ; Branch power constraint: S ij,min ≤S ij ≤S ij,max , where j∈i; Gas node pressure constraint p h,min ≤p h ≤p h,max ; Natural gas pipeline flow constraints n,min ≤f n,t ≤f n,max ; U i,min , U i,max are the upper and lower limits of the voltage amplitude of the grid node i in the gas-electricity coupling system; U i is the voltage amplitude of the grid node i in the gas-electricity coupling system at the current moment; S ij,min and S ij,max are the upper and lower power limits allowed for the line segment connecting grid node i and grid node j in the gas-electricity coupling system; S ij is the power value of the line segment connecting grid node i and grid node j in the electric coupling system at the current moment, j∈i means that grid node j is directly connected to grid node i, p h,min and p h,max are the upper and lower limits of pressure at the natural gas pipeline node h in the gas-electricity coupling system; p h is the pressure of the natural gas pipeline node h in the gas-electricity coupling system at the current moment; f n,min and f n,max are the upper and lower flow limits of natural gas pipeline n in the gas-electricity coupling system at the current moment; f n is the flow rate of natural gas pipeline n in the gas-electricity coupling system at the current moment.

4. The method for optimizing the operation of a gas-electric coupling system according to claim 1, characterized in that: The set value of population sample number x is 50.

5. The method for optimizing the operation of a gas-electric coupling system according to claim 1, characterized in that: The genetic operation in the genetic operation step is a crossover operation and / or a mutation operation.

6. The method for optimizing the operation of a gas-electric coupling system according to claim 1, characterized in that: The method was performed once an hour.