Comprehensive energy system dynamic optimal power flow method based on second-order cone relaxation and convex approximation

By employing second-order cone relaxation and convex approximation methods to process integrated power-heat-gas energy systems, this approach addresses the challenges of non-convex power flow in power networks and the complexity of modeling heat and gas networks. It achieves efficient optimization calculations and high renewable energy absorption rates, supporting optimized scheduling in practical engineering projects.

CN121749202APending Publication Date: 2026-03-27CHINA ELECTRIC POWER RESEARCH INSTITUTE CO LTD +3
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-20
Publication Date
2026-03-27

AI Technical Summary

Technical Problem

In existing integrated energy system optimization methods, the non-convex power flow constraints of the power network make the optimization problem difficult to solve. The heterogeneous physical characteristics of the heating network and the gas network increase the complexity of dynamic modeling. The traditional MINLP method has high computational cost and is difficult to apply to engineering practice.

Method used

A second-order cone relaxation technique is used to handle the non-convex power flow constraints of the power grid, and a convex approximation is applied to the heating network and the gas network. A mixed-integer second-order cone programming model is constructed and solved using the Gurobi solver.

Benefits of technology

It improves the computational efficiency of complex integrated energy system optimization problems, reduces operating costs, reduces carbon emissions, and increases the absorption rate of renewable energy, providing an economical and environmentally friendly solution.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121749202A_ABST
    Figure CN121749202A_ABST
Patent Text Reader

Abstract

The invention discloses an integrated energy system dynamic optimal power flow method based on second-order cone relaxation and convex approximation, and the method comprises the steps: constructing an optimal power flow model of an integrated energy system which is an electric, thermal and gas integrated energy system; a two-dimensional cone relaxation technology is adopted to restrain the non-convex power flow of the power distribution network in the optimal power flow model, and controlled convex approximation is carried out on nonlinear equations of a gas network and a heat network in the optimal power flow model to obtain a convex optimization model; adding an optimization framework of multi-time scale dynamic characteristics into the convex optimization model to form a mixed integer second-order cone programming model; and solving the mixed integer second-order cone programming model by adopting a Gurobi solver to obtain a load flow calculation result of the integrated energy system.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of integrated energy system operation analysis and optimization, and more particularly, to an integrated energy system dynamic optimal power flow method based on second-order cone relaxation and convex approximation. BACKGROUND

[0002] Integrated energy system (IES) is a key technology carrier for realizing the collaborative optimization and complementary utilization of electricity, heat, gas and other multiple energies, and is an important direction of modern energy system development. With the deepening of the "double carbon" strategy, high-proportion renewable energies such as wind power and photovoltaic are connected to the integrated energy system, making the system present complex operation characteristics of "multi-energy flow coupling and multi-time scale".

[0003] However, in the field of optimal power flow analysis of the electricity-heat-gas integrated energy system, the existing optimization methods face significant challenges: first, the alternating current flow equation in the power network, the Weymouth equation in the natural gas network and the like all have strong non-convex characteristics, making it difficult to solve the optimization problem; second, the thermal inertia dynamics of the heat system and the slow flow process of the natural gas system form a multi-time scale coupling, increasing the complexity of dynamic modeling; third, although the traditional mixed integer nonlinear programming (MINLP) method can obtain an accurate solution, the calculation cost is high and it is difficult to be applied to engineering practice. Although existing researches have tried to use methods such as alternating iteration or linearization approximation for improvement, there are still problems such as insufficient convergence and large precision loss, which restrict the engineering optimization operation of the integrated energy system.

[0004] In the field of optimization of the electricity-heat-gas integrated energy system, the existing optimal power flow methods have the following outstanding problems: the non-convex power flow constraints of the power network make it difficult to solve the optimization problem; the heterogeneous physical characteristics of the heat network and the gas network increase the difficulty of dynamic modeling; the traditional MINLP method has a high calculation cost and poor engineering applicability. SUMMARY

[0005] In view of the deficiencies of the prior art, the present application provides an integrated energy system dynamic optimal power flow method based on second-order cone relaxation and convex approximation.

[0006] According to one aspect of the present application, an integrated energy system dynamic optimal power flow method based on second-order cone relaxation and convex approximation is provided, comprising:

[0007] An optimal power flow model of the integrated energy system is constructed, wherein the integrated energy system is an integrated energy system of electricity, heat and gas;

[0008] A two-dimensional cone relaxation technique is used to constrain the non-convex power flow of the distribution network in the optimal power flow model, and a controlled convex approximation is performed on the nonlinear equations of the gas network and the heat network in the optimal power flow model, to obtain a convex optimization model.

[0009] The optimization framework is added with the multi-time scale dynamic characteristics in the convex optimization model to form a mixed integer second-order cone programming model;

[0010] The mixed integer second-order cone programming model is solved by using a Gurobi solver to obtain a power flow calculation result of the comprehensive energy system.

[0011] Optionally, the objective function of the optimal power flow model is:

[0012] minw1·F1+w2·F2-w3·F3

[0013] In the formula, w1, w2 and w3 are influence weights of F1, F2 and F3 respectively; F1 is a total operation cost; F2 is a carbon emission cost; F3 is a renewable energy consumption reward; wherein,

[0014]

[0015] In the formula, C grid,t , C gas,t , C OM,t , C DR,t , C STOR,t , R sell,t and R subsidy,t are a main grid electricity purchase cost, a purchased natural gas cost, an equipment fixed and variable operation and maintenance cost, a demand response compensation cost, a storage cyclic depreciation cost, a sold natural gas income and a P2G subsidy income at t moment;

[0016]

[0017] In the formula, c carbon is a cost of a unit carbon emission; α e is a carbon emission coefficient of externally purchased power; P grid,t is an electricity power purchased from the main grid at t moment; α g is a carbon emission coefficient of natural gas; G buy,t is an electricity power purchased from the main grid at t moment;

[0018]

[0019] In the formula, c reward is a reward amount of a unit renewable energy consumption; P wind,t is a wind power consumption at t moment; P PV,t is a photovoltaic power consumption at t moment.

[0020] Optionally, the constraint conditions of the optimal power flow model include: power network subsystem constraints, heat network subsystem constraints, and natural gas network subsystem constraints, coupling device constraints and other constraints, wherein,

[0021] The constraints of the power network subsystem include: the classical AC node power balance equations and voltage drop constraints, among which...

[0022] The classic AC node power balance equation is:

[0023]

[0024] In the formula: Let t represent the total active power and total reactive power injected into node i by all generating devices connected to node i at time t. V represents the total active power and total reactive power consumed by all loads flowing out of node i at time t; i,t V j,t Let θ represent the voltage magnitudes at node i and node j at time t, respectively; ij,t G represents the voltage phase angle difference between node i and node j at time t; ij B ij Let be the branch conductance and susceptance connecting node i and node j at time t, respectively;

[0025] The voltage drop constraint is:

[0026]

[0027] In the formula: V i,t V j,t Let r be the voltage magnitudes at node i and node j at time t, respectively; ij x ij These represent the line impedance and reactance between node i and node j, respectively; P ij,t Q ij,t These represent the active power and reactive power between node i and node j at time t, respectively; I ij,t Let t be the current amplitude between node i and node j at time t;

[0028] The constraints of the thermal network subsystem include: nodal heat power balance equations and pipe transport models; among which,

[0029] The nodal heat power balance equation is:

[0030]

[0031] In the formula: Inject net heat power into node j at time t; Let be the power of the heat source and the heat load at node j at time t, respectively. These represent the heat release and heat charge power of the thermal storage device at node j at time t, respectively. The net heat power transfer between node j and node k at time t; is the sum of net heat power of node j and all adjacent nodes at time t;

[0032] The pipeline transmission model is:

[0033]

[0034] wherein, is the heat power between node i and node j at time t; c p is the specific heat capacity of water; m ij,t is the mass flow rate of fluid (water) between node i and node j at time t, i.e., the mass of water passing through per unit time; is the water supply temperature at node i at time t; T0 is the initial water supply temperature;

[0035] The natural gas network subsystem constraints include node flow balance equations and pipeline pressure drop equations, wherein,

[0036] Node flow balance equation

[0037]

[0038] wherein, is the sum of pipeline flow from all upstream nodes i adjacent to node j into node j; is the flow rate of gas source injected into node j at time t, the gas source being the supply source of gas; is the gas production flow rate injected into node j by the P2G device at time t; is the sum of pipeline flow from node j to all downstream nodes k; is the gas load flow rate of node j at t; is the gas flow rate consumed by the compressor at node j at t; is the gas flow rate consumed by the CHP unit at node j at t;

[0039] The pipeline pressure drop equation is:

[0040]

[0041] wherein, respectively represent the gas pressure of nodes i and j at both ends of the pipeline at time t; K ij is the pressure drop coefficient of pipeline ij, reflecting the inherent property of the pipeline to produce pressure drop for gas flow; f ij,t is the gas flow rate in pipeline ij at time t, |f ij,t is the absolute value thereof;

[0042] The coupling device constraints include: combined heat and power unit constraints, electric-to-gas device constraints, electric-to-hydrogen device constraints, and fuel cell and hydrogen gas turbine constraints, wherein,

[0043] The constraints of the cogeneration unit are:

[0044]

[0045] PCHP(t) and PCHP(t) are the power generation and heat generation of the CHP unit at time t, respectively; t CHP , PCHP(t) and PCHP(t) are the power generation and heat generation of the CHP unit at time t, respectively; PCHP(t) and PCHP(t) are the power generation and heat generation of the CHP unit at time t, respectively; PCHP(t) is the gas consumption of the CHP unit at time t; ηCHP(t) is the power generation efficiency of the CHP unit at time t; e PCHP(t) is the gas consumption of the CHP unit at time t; ηCHP(t) is the power generation efficiency of the CHP unit at time t;

[0046] The constraints of the electricity-to-gas device are:

[0047]

[0048] PCHP(t) and PCHP(t) are the power generation and heat generation of the CHP unit at time t, respectively; t P2G PCHP(t) and PCHP(t) are the power generation and heat generation of the CHP unit at time t, respectively; PCHP(t) and PCHP(t) are the power generation and heat generation of the CHP unit at time t, respectively; PCHP(t) and PCHP(t) are the power generation and heat generation of the CHP unit at time t, respectively; P2G PCHP(t) and PCHP(t) are the power generation and heat generation of the CHP unit at time t, respectively;

[0049] The constraints of the electricity-to-hydrogen device are:

[0050]

[0051] PCHP(t) and PCHP(t) are the power generation and heat generation of the CHP unit at time t, respectively; PCHP(t) and PCHP(t) are the power generation and heat generation of the CHP unit at time t, respectively; t P2H PCHP(t) and PCHP(t) are the power generation and heat generation of the CHP unit at time t, respectively; PCHP(t) and PCHP(t) are the power generation and heat generation of the CHP unit at time t, respectively; P2H PCHP(t) and PCHP(t) are the power generation and heat generation of the CHP unit at time t, respectively;

[0052] The constraints of the fuel cell and hydrogen gas turbine are:

[0053]

[0054] PCHP(t) and PCHP(t) are the power generation and heat generation of the CHP unit at time t, respectively; t H2P PCHP(t) and PCHP(t) are the power generation and heat generation of the CHP unit at time t, respectively; t HGT PCHP(t) and PCHP(t) are the power generation and heat generation of the CHP unit at time t, respectively; H2P PCHP(t) and PCHP(t) are the power generation and heat generation of the CHP unit at time t, respectively; HGT PCHP(t) and PCHP(t) are the power generation and heat generation of the CHP unit at time t, respectively; PCHP(t) and PCHP(t) are the power generation and heat generation of the CHP unit at time t, respectively; Let t be the amount of hydrogen used by the fuel cell or hydrogen gas turbine at time t; This represents the maximum amount of hydrogen that can be used.

[0055] Other constraints include: grid demand response constraints and heating network demand response constraints, among which...

[0056] The grid demand response constraints are:

[0057]

[0058] In the formula: γ e This is the proportional adjustment coefficient for electrical load demand response; Let ΔP be the original active power and reactive power of the electrical load at time t; d,t ΔQ d,t These represent the demand response adjustments for active and reactive power of the electrical load at time t, respectively.

[0059] The demand response constraints for the heating network are:

[0060]

[0061] In the formula: γ h This is the adjustment ratio coefficient for heat load demand response; ΔΦ represents the initial power of the heat load at time t. L,t U represents the demand response adjustment of the heat load at time t. Φ,t This represents the upper limit of the heat load regulation capacity at time t.

[0062] Optionally, for non-convex power flow in the distribution network, auxiliary variables are introduced to eliminate quadratic terms. The relaxed second-order cone constraint is:

[0063]

[0064] In the formula: α i,t As an auxiliary variable, β represents the squared voltage of node i at time t; ij,t As an auxiliary variable, P represents the square of the current amplitude between node i and node j at time t; ij,t Q ij,t These represent the active power and reactive power between node i and node j at time t, respectively; β ij,t -α i,t The difference between the square of the current and the square of the voltage, relating the quadratic terms of the current and voltage; β ij,t +α i,t The sum of the square of the current and the square of the voltage.

[0065] Optionally, the air network is approximated by a controlled convexity to obtain the relaxed convex constraint as follows:

[0066]

[0067] Where: G ij Let be the gas flow rate in pipe ij; auxiliary variable η ij =(d ij+ -d ij- )Δx ij d represents the directional pressure difference. ij+ This indicates that the airflow is from node i to node j; d ij- This indicates that the airflow is from node j to node i, K ij Let be the pressure drop coefficient of pipe ij.

[0068] Optionally, the heating network undergoes a controlled convex approximation, including:

[0069] Linearized approximation of the pipe temperature drop equation:

[0070]

[0071] In the formula: T end T start These are the temperatures at the end and beginning of the pipe, respectively; T a The ambient temperature is represented by λ and L, respectively, which are the pipe heat loss coefficient and pipe length. p ρ is the specific heat capacity at constant pressure of the fluid; m is the mass flow rate of the fluid;

[0072] Linearization of the thermal power equation:

[0073] Φ=c p m(T s -T r )

[0074] In the formula: Φ is the thermal power; T s Temperature on the heating side (or high-temperature side); T r This refers to the temperature on the heated side (or the lower temperature side).

[0075] Piecewise linearization of heat transfer in pipes and node temperatures:

[0076]

[0077] In the formula: T out γ is the system outlet temperature; s δ represents the temperature / heat loss value of the s-th segment node; s For the s-th segment in T out The proportion and weight in; N s The number of segments; where

[0078] The segment points (γ) corresponding to the flow-pressure drop or flow-heat loss curve s ,m s Approaching:

[0079]

[0080] Where: m s Let δ represent the flow rate value of the s-th segment; s,ij (t) represents the s-th segment in f ij The weights in (t).

[0081] Alternatively, the expression for the mixed-integer second-order cone programming model is: In the formula, For energy storage devices t The charging status indicator at any time. express t The energy storage is always in a charging state. express t The energy storage is always in a non-charging state; For energy storage devices t The charging status indicator at any time. express t The stored energy is constantly in a discharging state. express t The stored energy is always in a non-discharge state; This means that at any given moment, energy storage can only be in one of three states: charging, discharging, or neither charging nor discharging; it cannot be charged or discharged simultaneously. express t Time Node i With nodes j The active power of the branches between; express t Time Node i With nodes j The reactive power of the branch circuits between them; The difference between the square of the current and the square of the voltage is the quadratic term relating the current and the voltage. The sum of the squares of the current and the squares of the voltage serves as the upper bound of the second-order cone.

[0084] According to another aspect of the present invention, a dynamic optimal power flow device for a comprehensive energy system based on second-order cone relaxation and convex approximation is provided, comprising:

[0085] The module is used to build the optimal power flow model of an integrated energy system, which is an integrated energy system of electricity, heat and gas.

[0086] The approximation module is used to constrain the non-convex power flow of the distribution network in the optimal power flow model using two-dimensional cone relaxation techniques, and to perform controlled convex approximation on the nonlinear equations of the gas network and heat network in the optimal power flow model to obtain a convex optimization model.

[0087] The module is used to incorporate multi-timescale dynamic characteristics into the convex optimization model, forming a mixed-integer second-order cone programming model.

[0088] The solver module is used to solve the mixed-integer second-order cone programming model using the Gurobi solver to obtain the power flow calculation results of the integrated energy system.

[0089] According to another aspect of the present invention, a computer-readable storage medium is provided, the storage medium storing a computer program for performing the methods described in any of the above aspects of the present invention.

[0090] According to another aspect of the present invention, an electronic device is provided, the electronic device comprising: a processor; a memory for storing executable instructions of the processor; the processor being configured to read the executable instructions from the memory and execute the instructions to implement the method described in any of the preceding aspects of the present invention.

[0091] Therefore, this invention provides a dynamic optimal power flow optimization method for integrated energy systems of electricity, heat, and gas based on second-order cone relaxation and convex approximation. By using second-order cone relaxation to handle the non-convex power flow constraints of the power grid, and simultaneously applying convex approximations to the key equations of the heat and gas networks, the original mixed-integer nonlinear programming problem is transformed into a solvable mixed-integer second-order cone programming problem. This achieves a breakthrough improvement in the computational efficiency of complex integrated energy system optimization problems, effectively solving the problems of high computational cost and poor engineering applicability of traditional MINLP methods. Through the constructed multi-objective optimization framework and model predictive control mechanism, a comprehensive optimization effect of reduced operating costs and carbon emissions is achieved, while increasing the renewable energy utilization rate to nearly 100%. This provides a complete solution for integrated energy systems with a high proportion of renewable energy, balancing economic efficiency, environmental friendliness, and computational efficiency, and can support the optimization and scheduling needs of practical engineering projects. Attached Figure Description

[0092] Exemplary embodiments of the present invention can be more fully understood by referring to the following figures:

[0093] Figure 1 This is a flowchart illustrating an exemplary embodiment of the present invention for a dynamic optimal power flow method for a comprehensive energy system based on second-order cone relaxation and convex approximation.

[0094] Figure 2 This is an IES configuration diagram provided by an exemplary embodiment of the present invention;

[0095] Figure 3 This is a system power purchase surface diagram provided by an exemplary embodiment of the present invention;

[0096] Figure 4 This is a market electricity purchase surface diagram provided by an exemplary embodiment of the present invention;

[0097] Figure 5 This is a schematic diagram of wind power output and available wind power provided in an exemplary embodiment of the present invention;

[0098] Figure 6 This is a schematic diagram of CHP electrical output and TES energy storage state provided in an exemplary embodiment of the present invention;

[0099] Figure 7 This is a schematic diagram of the demand response characteristics (electric + thermal) of a multi-energy system provided in an exemplary embodiment of the present invention;

[0100] Figure 8 This is a convergence comparison diagram provided by an exemplary embodiment of the present invention;

[0101] Figure 9 This is an efficiency comparison chart provided by an exemplary embodiment of the present invention;

[0102] Figure 10 This is a schematic diagram of the structure of a dynamic optimal power flow device for a comprehensive energy system based on second-order cone relaxation and convex approximation provided in an exemplary embodiment of the present invention.

[0103] Figure 11 This is the structure of an electronic device provided in an exemplary embodiment of the present invention. Detailed Implementation

[0104] Hereinafter, exemplary embodiments according to the present invention will be described in detail with reference to the accompanying drawings. Obviously, the described embodiments are merely some embodiments of the present invention, and not all embodiments of the present invention. It should be understood that the present invention is not limited to the exemplary embodiments described herein.

[0105] It should be noted that, unless otherwise specifically stated, the relative arrangement, numerical expressions, and values ​​of the components and steps described in these embodiments do not limit the scope of the invention.

[0106] Those skilled in the art will understand that the terms "first," "second," etc., in the embodiments of the present invention are only used to distinguish different steps, devices, or modules, and do not represent any specific technical meaning, nor do they indicate a necessary logical order between them.

[0107] It should also be understood that in the embodiments of the present invention, "multiple" can refer to two or more, and "at least one" can refer to one, two or more.

[0108] It should also be understood that any component, data or structure mentioned in the embodiments of the present invention can generally be understood as one or more unless explicitly defined or given contrary instructions in the context.

[0109] Furthermore, the term "and / or" in this invention is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, or B existing alone. Additionally, the character " / " in this invention generally indicates that the preceding and following related objects have an "or" relationship.

[0110] It should also be understood that the description of the various embodiments in this invention emphasizes the differences between the various embodiments, and the similarities or similarities can be referred to each other. For the sake of brevity, they will not be described in detail.

[0111] At the same time, it should be understood that, for ease of description, the dimensions of the various parts shown in the accompanying drawings are not drawn according to actual scale.

[0112] The following description of at least one exemplary embodiment is merely illustrative and is in no way intended to limit the invention or its application or use.

[0113] Techniques, methods, and equipment known to those skilled in the art may not be discussed in detail, but where appropriate, they should be considered part of the specification.

[0114] It should be noted that similar labels and letters in the following figures indicate similar items; therefore, once an item is defined in one figure, it does not need to be discussed further in subsequent figures.

[0115] The embodiments of this invention can be applied to electronic devices such as terminal devices, computer systems, and servers, and can operate together with a wide range of other general-purpose or special-purpose computing system environments or configurations. Well-known examples of terminal devices, computing systems, environments, and / or configurations suitable for use with electronic devices such as terminal devices, computer systems, and servers include, but are not limited to: personal computer systems, server computer systems, thin clients, thick clients, handheld or laptop devices, microprocessor-based systems, set-top boxes, programmable consumer electronics, network PCs, minicomputer systems, mainframe computer systems, and distributed cloud computing environments including any of the above systems, etc.

[0116] Electronic devices such as terminal devices, computer systems, and servers can be described in the general context of computer system executable instructions (such as program modules) executed by a computer system. Typically, program modules can include routines, programs, object programs, components, logic, data structures, etc., which perform specific tasks or implement specific abstract data types. Computer systems / servers can be implemented in distributed cloud computing environments, where tasks are executed by remote processing devices linked through communication networks. In distributed cloud computing environments, program modules can reside on local or remote computing system storage media, including storage devices.

[0117] Exemplary method

[0118] Figure 1 This is a flowchart illustrating a comprehensive energy system dynamic optimal power flow method based on second-order cone relaxation and convex approximation, provided in an exemplary embodiment of the present invention. This embodiment can be applied to electronic devices, such as… Figure 1 As shown, the dynamic optimal power flow method 100 for a comprehensive energy system based on second-order cone relaxation and convex approximation includes the following steps:

[0119] Step 101: Construct an optimal power flow model for the integrated energy system, which is an integrated energy system of electricity, heat and gas;

[0120] Step 102: The two-dimensional cone relaxation technique is used to constrain the non-convex power flow of the distribution network in the optimal power flow model, and the nonlinear equations of the gas network and heat network in the optimal power flow model are approximated by a controlled convex approximation to obtain the convex optimization model.

[0121] Step 103: Add an optimization framework with multi-time-scale dynamic characteristics to the convex optimization model to form a mixed integer second-order cone programming model;

[0122] Step 104: Use the Gurobi solver to solve the mixed-integer second-order cone programming model to obtain the power flow calculation results of the integrated energy system.

[0123] Specifically, this invention constructs a unified mathematical model for an integrated energy system encompassing electricity, heat, and gas. It employs a second-order cone relaxation technique to handle non-convex power flow constraints in the power grid, transforming the original problem into a solvable convex optimization form. For the heat network and gas network, convex approximation models considering thermal inertia and pipeline dynamics are established separately, effectively balancing model accuracy and computational complexity. Based on a multi-objective optimization framework and model predictive control mechanism, a mixed-integer second-order cone programming model is constructed and solved efficiently using a commercial solver. This invention achieves a systematic methodological innovation from non-convex problem modeling and multi-energy flow constraint convexification to efficient optimization solution. It provides a dynamic optimal power flow solution for integrated energy systems containing a high proportion of renewable energy, balancing physical accuracy and engineering feasibility, and can support the low-carbon economic dispatch and safe and stable operation of integrated energy systems.

[0124] To verify the model proposed in this invention, a test case of an integrated electric-heat-gas energy system based on an improved IEEE-33 node distribution network and extended with thermal and natural gas subnetworks was constructed. The system includes coupled devices such as CHP, P2G, fuel cells, hydrogen engines, electric boilers, and heat pumps, as well as electrochemical energy storage, thermal storage, and gas storage units. The subnetworks are interconnected through energy hubs to form a unified multi-energy coordinated dispatch system. Key operating parameters of the system are shown in Table 1 of this paper.

[0125] Table 1 Parameters of each unit

[0126]

[0127] Specifically, such as Figure 1 As shown, the method may include:

[0128] Step S101: Construct an optimal power flow model for the integrated electricity-heat-gas energy system to accurately describe the physical characteristics of each energy system and their coupling relationships.

[0129] The specific method for constructing the optimal power flow model of the integrated electricity-heat-gas energy system is as follows:

[0130] 1. Objective function

[0131] This invention constructs a multi-objective function that comprehensively considers economy, environmental protection, and system reliability, and transforms it into a single-objective problem using a weighted summation method. The objective function is as follows:

[0132] min w1·F1+w2·F2-w3·F3 (1)

[0133] In the formula: w1, w2, and w3 are the influence weights on F1, F2, and F3, respectively; F1 is the total operating cost; F2 is the carbon emission cost; and F3 is the renewable energy consumption incentive.

[0134] 1.1 Total operating cost F1:

[0135]

[0136] In the formula: C grid,t C gas,t C OM,t C DR,t C STOR,t R sell,t R subsidy,t These are, respectively, the main grid electricity purchase cost at time t, the natural gas purchase cost, the fixed and variable operation and maintenance costs of equipment, the demand response compensation cost, the energy storage cycle depreciation cost, the natural gas sales revenue, and the P2G subsidy revenue.

[0137] 1.2 Carbon emission cost F2:

[0138]

[0139] In the formula: c carbon Cost per unit of carbon emissions; α e Carbon emission factor for purchased electricity; P grid,t Let α be the electrical power purchased from the main grid at time t; g G represents the carbon emission factor for natural gas. buy,t Let t be the electrical power purchased from the main grid at time t.

[0140] 1.3 Renewable Energy Consumption Incentive F3:

[0141]

[0142] In the formula: c reward The reward amount per unit of renewable energy consumption; P wind,t P represents the wind power absorbed at time t. PV,t Let t be the photovoltaic power generation absorbed at time t.

[0143] 2. Constraints

[0144] 2.1 Power Network Subsystem Modeling

[0145] The power network subsystem is the core of the IES (Enhanced Economic System), and its modeling is based on the Branch Flow Model (BFM) framework for distribution networks. This model clearly describes the power flow distribution of radial networks, and its original AC power flow equations contain nonlinear terms, laying the foundation for subsequent convex relaxation. The model is as follows:

[0146] 1) Classical AC node power balance equations:

[0147]

[0148] In the formula: Let t represent the total active power and total reactive power injected into node i by all generating devices connected to node i at time t. V represents the total active power and total reactive power consumed by all loads flowing out of node i at time t; i,t V j,t Let θ represent the voltage magnitudes at node i and node j at time t, respectively; ij,t G represents the voltage phase angle difference between node i and node j at time t; ij B ij Let be the branch conductance and susceptance connecting node i and node j at time t, respectively.

[0149] 2) Voltage drop constraint:

[0150]

[0151] In the formula: V i,t V j,t Let r be the voltage magnitudes at node i and node j at time t, respectively; ij x ij These represent the line impedance and reactance between node i and node j, respectively; P ij,t Q ij,t These represent the active power and reactive power between node i and node j at time t, respectively; I ij,t Let be the current amplitude between node i and node j at time t.

[0152] 2.2 Modeling of the Thermal Network Subsystem

[0153] Thermal networks exhibit significant thermal inertia, and their dynamic processes are much slower than the electromagnetic transients of power grids. Therefore, a quasi-steady-state model is used for modeling, focusing on the transmission and distribution of heat power. The model is as follows:

[0154] 1) Nodal heat power balance equation

[0155]

[0156] In the formula: Inject net heat power into node j at time t; Let be the power of the heat source and the heat load at node j at time t, respectively. These represent the heat release and heat charge power of the thermal storage device at node j at time t, respectively. The net heat power transfer between node j and node k at time t; Let be the sum of the net heat power connecting node j and all its adjacent nodes k at time t.

[0157] 2) Pipeline transmission model

[0158]

[0159] In the formula: Let c be the thermal power between node i and node j at time t; p The specific heat capacity of water; m ij,t Let t be the mass flow rate of the fluid (water) between node i and node j at time t, that is, the mass of water passing through per unit time; Let Ti be the water supply temperature at node i at time t; T0 be the water supply temperature at the initial time.

[0160] 2.3 Modeling of the Natural Gas Network Subsystem

[0161] A natural gas network consists of gas sources, pipelines, compressors, and load nodes. Its steady-state operation is constrained by mass conservation and pipeline pressure drop equations. The model is as follows:

[0162] 1) Node flow balance equation

[0163]

[0164] In the formula: Σf ij,t It is the sum of the pipeline flows into node j from all upstream nodes i adjacent to node j; Let t be the flow rate of gas injected into node j at time t. The gas source is the source of gas supply. Let Σf be the gas production flow rate injected by the P2G device into node j at time t; jk,t This is the sum of the pipeline flow from node j to all downstream nodes k; Let be the gas load flow rate at node j (t). Let J be the air flow rate consumed by the compressor at node t. This represents the gas flow rate consumed by the CHP unit at node j (t).

[0165] 2) Pipeline pressure drop equation

[0166]

[0167] In the formula: K represents the air pressure at nodes i and j at both ends of the pipeline at time t; ij f is the pressure drop coefficient of pipe ij, reflecting the inherent property of the pipe to cause pressure drop due to gas flow; ij,t Let f be the gas flow rate in pipe ij at time t. ij,t | is its absolute value.

[0168] 2.4 Modeling of Coupled Devices

[0169] Coupling devices are key to achieving multi-energy flow complementarity and conversion. This invention considers various coupling devices, and their models are as follows:

[0170] 1) Combined heat and power (CHP) units

[0171]

[0172] In the formula: P t CHP , These represent the power generation and heat production of the CHP unit at time t, respectively. These are the maximum power generation and maximum heat production of the CHP unit, respectively; α is the lower limit of the heat-to-power ratio. η is the gas consumption of the CHP unit at time t; e This refers to the power generation efficiency of the CHP unit.

[0173] 2) Electric-to-gas (P2G) equipment:

[0174]

[0175] In the formula: P t P2G Let t be the electrical power consumed by the P2G device at time t; This represents the maximum power consumption of a P2G device. Let η be the gas production rate of the P2G device at time t; P2G The electrical conversion efficiency of the P2G device; LHV is the lower heating value of the gas.

[0176] 3) Electro-to-hydrogen (P2H) equipment:

[0177]

[0178] In the formula: P t P2H The hydrogen production and electrical power consumption of the P2H device at time t are respectively: η represents the maximum power consumption of the P2H device. P2H The electro-hydrogen conversion efficiency of the P2H device.

[0179] 4) Fuel Cells (H2P) and Hydrogen Gas Turbines (HGT):

[0180]

[0181] In the formula: P t H2P P t HGT η represents the power generation of the fuel cell and the hydrogen gas turbine at time t, respectively; H2P η HGT The hydrogen-to-electricity conversion efficiencies are those of fuel cells and hydrogen gas turbines, respectively. These are the maximum power generation capacities of fuel cells and hydrogen gas turbines, respectively. Let t be the amount of hydrogen used by the fuel cell or hydrogen gas turbine at time t; This represents the maximum amount of hydrogen that can be used.

[0182] 2.5 Other Constraints

[0183] 1. Grid Demand Response (DR) Constraints

[0184]

[0185] In the formula: γ e This is the proportional adjustment coefficient for electrical load demand response; Let ΔP be the original active power and reactive power of the electrical load at time t; d,t ΔQ d,t These represent the demand response adjustments for active and reactive power of the electrical load at time t, respectively.

[0186] 2. Demand Response (DR) Constraints of Heating Network

[0187]

[0188] In the formula: γ h This is the adjustment ratio coefficient for heat load demand response; ΔΦ represents the initial power of the heat load at time t. L,t U represents the demand response adjustment of the heat load at time t. Φ,t This represents the upper limit of the heat load regulation capacity at time t.

[0189] Step S102: To address the nonlinear challenges in the optimal power flow model of the integrated power-heat-gas energy system, a second-order cone relaxation technique is used to handle the non-convex constraints of the power grid. At the same time, convex approximations are applied to the key equations of the heat network and the gas network, transforming the complex model into a convex optimization model.

[0190] As can be seen, the above constraints include quadratic and integer terms. This optimal power flow problem belongs to the mixed integer nonlinear programming (MINLP) problem. Conventional analytical solutions or intelligent optimization algorithms based on heuristics / metaheuristics often suffer from low efficiency and difficulty in guaranteeing feasibility / accuracy in large-scale coupled multi-energy systems. Therefore, this invention adopts convex relaxation technology and proposes a hierarchical convexity strategy: implementing second-order cone relaxation (SOCR) on the nonconvex power flow constraints of the distribution network, and performing controlled convex approximation on the nonlinear equations of the gas network and the heating network. The specific content is as follows:

[0191] 1. Second-order cone relaxation (SOCR) in power systems

[0192] The power system is modeled using a branch flow model (BFM). The flow equation constraints in this model are non-convex, which is the key reason why the problem is difficult to solve. SOCR transforms this non-convex problem into a convex optimization problem by introducing auxiliary variables and constraint relaxation.

[0193] 1.1 Variable Substitution and Relaxation

[0194] First, we introduce auxiliary variables to eliminate quadratic terms:

[0195]

[0196] The original non-convex power-voltage-current relationship:

[0197]

[0198] The relaxation is the following second-order cone constraint:

[0199]

[0200] In the formula: α i,t As an auxiliary variable, β represents the squared voltage of node i at time t; ij,t As an auxiliary variable, P represents the square of the current amplitude between node i and node j at time t; ij,t Q ij,t These represent the active power and reactive power between node i and node j at time t, respectively; β ij,t -α i,t The difference between the square of the current and the square of the voltage, relating the quadratic terms of the current and voltage; β ij,t +α i,t The sum of the squares of the current and the squares of the voltage serves as the "upper bound" of the second-order cone.

[0201] 2. Convex Approximation of Natural Gas System

[0202] The nonlinearity of natural gas networks is mainly reflected in the pipeline flow equation, which is usually in the form of the Weymouth equation.

[0203] 2.1 Treatment of pressure squared variable and flow direction

[0204] First, we introduce the squared stress variable to simplify the expression:

[0205]

[0206] In the formula: x i is an auxiliary variable, and is the square of the pressure at node i.

[0207] Pressure difference is expressed as Δx ij =x i -xj Pipe flow equation:

[0208]

[0209] Where: G ij K represents the gas flow rate in pipe ij. ij Let Δx be the pressure drop coefficient of pipe ij, reflecting the inherent property of the pipe causing pressure drop due to gas flow. ij Let be the squared pressure difference between nodes i and j.

[0210] To handle the non-convexity caused by the flow direction, a binary variable d is introduced. ij+ and d ij- To indicate the direction of airflow:

[0211] d ij+ +d ij- =1 (22)

[0212] In the formula: d ij+ This indicates that the airflow is from node i to node j; d ij- This indicates that the airflow is from node j to node i.

[0213] 2.2 McCormick Envelope Linearization

[0214] Introducing auxiliary variable η ij =(d ij+ -d ij- )Δx ij This represents the directional pressure difference. Using the McCormick envelope, η can be... ij With d ij+ d ij- Δx ij The relationship between them is approximated and relaxed using a set of linear inequality constraints:

[0215]

[0216] In the formula: η ij As an auxiliary variable, it is used to represent "directional pressure difference" and is used to evaluate the nonlinear term (d). ij+ -d ij- )Δx ij The core variable for linear approximation; Δx ij Δx represents the squared pressure difference between node i and node j. max This represents the maximum possible value of the square of the pressure difference.

[0217] 2.3 Relaxed Pipe Flow Constraints

[0218] Ultimately, the pipeline flow equation is relaxed to the following convex constraint:

[0219]

[0220] This constraint, together with the McCormick envelope constraint, flow direction integer constraint, and node flow balance constraint (linear), constitutes the convex model of the natural gas network.

[0221] 3. Convex approximation of thermodynamic systems

[0222] The prevalent nonlinear and nonconvex characteristics of thermal systems are major factors affecting the efficiency of solving optimization problems. To improve the numerical stability and computational efficiency of the model, convex approximation techniques are commonly used to treat the thermal subsystem for dynamic optimal power flow problems.

[0223] 3.1 Linearization Approximation of the Pipeline Temperature Drop Equation

[0224]

[0225] In the formula: T end T start These are the temperatures at the end and beginning of the pipe, respectively; T a The ambient temperature is represented by λ and L, respectively, which are the pipe heat loss coefficient and pipe length. p is the specific heat capacity at constant pressure of the fluid; m is the mass flow rate of the fluid.

[0226] 3.2 Linearization of the heat power equation

[0227] Φ=c p m(T s -T r (26)

[0228] In the formula: Φ is the thermal power; T s Temperature on the heating side (or high-temperature side); T r The temperature is the temperature on the heated side (or the low-temperature side).

[0229] 3.3 Piecewise linearization of heat transfer in pipes and node temperatures

[0230]

[0231] In the formula: T out γ represents the system's outlet temperature, which can be used in the paper to represent complex heat transfer relationships; s δ represents the temperature / heat loss value of the s-th segment node; s For the s-th segment in T out The proportion and weight in; N s This represents the number of segments.

[0232] Simultaneously, the corresponding flow-pressure drop or flow-heat loss curves are segmented using the corresponding points (γ). s ,m s Approaching:

[0233]

[0234] Where: m s Let δ represent the flow rate value of the s-th segment; s,ij (t) represents the s-th segment in f ij The weights in (t) reflect the impact of each segment on f at different times. ij The contribution ratio of (t).

[0235] Step S103: Based on the convex optimization model, an optimization framework incorporating dynamic characteristics at multiple time scales is formed to create a standard mixed-integer second-order cone programming model, which is then solved using the MATLAB simulation environment combined with the GUROBI optimization solver.

[0236] Through the relaxation and convexity treatments described above, and by incorporating all linear and integer constraints, the original non-convex MINLP problem is transformed into a MISOCP problem of the following form: (29) The transformed MISOCP model is solved efficiently using the Gurobi solver. The solver incorporates advanced algorithms for handling integer variables and second-order cone constraints, enabling it to obtain high-quality optimal or near-optimal solutions within an acceptable timeframe, thus solving the computational complexity problem inherent in the original non-convex problem.

[0239] To verify the effectiveness of the proposed dynamic optimal power flow method for an integrated electric-thermal-gas energy system based on second-order cone relaxation and convex approximation, a test case of an integrated electric-thermal-gas energy system based on an improved IEEE-33 node distribution network with extended thermal and natural gas subnetworks was constructed. This system includes coupled devices such as CHP, P2G, fuel cells, hydrogen engines, electric boilers, and heat pumps, as well as electrochemical energy storage, thermal storage, and gas storage units. The subnetworks are interconnected through energy hubs to form a unified multi-energy coordinated dispatch system, as shown in the diagram. Figure 2 As shown.

[0240] Figure 3 The data shows the changes in power purchases at each node over 24 hours. Overall, power purchases were low and evenly distributed during low-load periods (e.g., periods 1–5). During period 2, due to insufficient local renewable energy output, power purchases surged to a peak of 26.4 MW to compensate for the shortfall. Subsequently, as wind power and CHP increased their output, power purchases decreased and remained within a reasonable range. This result indicates that the system's strategy of "multi-energy complementarity + local time-period compensation" effectively reduces dependence on the main grid while balancing economic efficiency and power supply reliability.

[0241] Figure 4The study demonstrates the change in the system's market-purchased power over time. Market-purchased power remains close to zero throughout the entire dispatch cycle, indicating that the system has essentially achieved power self-sufficiency. During low-load periods, energy storage devices and distributed power sources can meet demand; during peak periods, loads are balanced through CHP and decentralized power purchases, without relying on market power. These results demonstrate that the model achieves energy autonomy through internal multi-energy collaborative operation, avoiding the uncertainty and additional costs of market power purchases, and effectively improving independent operation capabilities.

[0242] Figure 5 A comparison of available and actual wind power output revealed a perfect match, with a total wind power absorption capacity of 20.241 MW·h, zero wind curtailment, and a 100% absorption rate. During low-load periods, some wind power was absorbed by energy storage devices; during peak periods, wind power was directly supplied to the load; and at night, wind power and energy storage worked together to further improve utilization. This demonstrates that the system fully utilizes wind power fluctuations through a "peak shaving by energy storage - valley filling by load," achieving full absorption of clean energy and highlighting its low-carbon advantages.

[0243] Figure 6 This demonstrates the changes in CHP power generation and TES (Thermal Energy Storage) energy storage levels over time. The CHP maintains high output during peak load periods, supporting both electricity and heat demand; while the TES charges heat during low load periods and releases heat during peak periods, with its SOC (State of Charge) gradually decreasing. This "heat release during the day, heat replenishment at night" strategy achieves thermoelectric decoupling, reducing the burden on the CHP unit and improving thermal efficiency. This illustrates that the system improves energy utilization and power supply flexibility through the coordinated operation of the CHP and TES.

[0244] Figure 7 The study demonstrates the system's demand response characteristics within a 24-hour scheduling cycle. Overall, the active power response on the electrical side exhibits short-term, significant peak fluctuations, primarily used for immediate power balancing; the reactive power response has a smaller amplitude, primarily used to maintain voltage / power factor; while the thermal response shows relatively smooth, inter-time-scale energy displacement, reflecting the thermal inertia and inter-time-scale buffering effect of the heating network. This indicates that through coordinated electrical-thermal scheduling, the system can rationally allocate regulation tasks across different time scales, improving operational autonomy and economy.

[0245] To evaluate the performance of optimal power flow based on second-order cone relaxation and convex approximation in an integrated electric-thermal-gas energy system, this study employs three typical scheduling schemes: Scheme 1 (the method of this invention), Scheme 2 (the traditional sub-network optimization method), and Scheme 3 (the MINLP approximation method). These three schemes represent different optimization modeling and solution strategies, aiming to compare their applicability, economy, environmental benefits, and solution efficiency in multi-energy system scheduling.

[0246] Based on the three design schemes, we compared the total operating cost, carbon emission cost, renewable energy consumption incentives, weighted total cost, and wind power integration rate. The specific results are shown in Table 3. The convergence comparison diagram of the methods is shown below. Figure 8 Efficiency comparison chart as follows Figure 9 .

[0247] Table 3 Comparison of Scheme Results

[0248]

[0249]

[0250] As shown in Table 3, Scheme 1 has the highest wind power absorption rate (1.0) and the lowest weighted total cost (27797.42), which is 0.10622 higher and 6790.58 lower than Scheme 2, and 0.02075 higher and 6845.58 lower than Scheme 3, respectively. Furthermore, both the total operating cost and carbon emission cost are significantly lower than the other schemes, indicating that the proposed method has a clear advantage in improving both economic efficiency and environmental friendliness.

[0251] Depend on Figure 8 and Figure 9 It can be seen that Scheme 1 has significant advantages over Schemes 2 and 3 in terms of convergence speed and solution efficiency, requiring fewer iterations and having an average computation time second only to Scheme 2. This is mainly due to the introduction of the second-order cone relaxation and convex approximation method, which transforms the non-convex power flow constraint into a convex form that can be solved efficiently, significantly reducing the model complexity and avoiding the convergence difficulties of traditional methods in strongly coupled scenarios.

[0252] In summary, the unified modeling method based on second-order cone relaxation and convex approximation, combined with the coordinated scheduling of hydrogen energy storage and liquid air energy storage, can significantly improve the economy, environmental protection and computational efficiency of integrated energy systems, providing a feasible and efficient solution for low-carbon optimized scheduling of IES.

[0253] Therefore, this invention provides a dynamic optimal power flow optimization method for integrated energy systems of electricity, heat, and gas based on second-order cone relaxation and convex approximation. By using second-order cone relaxation to handle the non-convex power flow constraints of the power grid, and simultaneously applying convex approximations to the key equations of the heat and gas networks, the original mixed-integer nonlinear programming problem is transformed into a solvable mixed-integer second-order cone programming problem. This achieves a breakthrough improvement in the computational efficiency of complex integrated energy system optimization problems, effectively solving the problems of high computational cost and poor engineering applicability of traditional MINLP methods. Through the constructed multi-objective optimization framework and model predictive control mechanism, a comprehensive optimization effect of reduced operating costs and carbon emissions is achieved, while increasing the renewable energy utilization rate to nearly 100%. This provides a complete solution for integrated energy systems with a high proportion of renewable energy, balancing economic efficiency, environmental friendliness, and computational efficiency, and can support the optimization and scheduling needs of practical engineering projects.

[0254] Exemplary apparatus

[0255] Figure 10 This is a schematic diagram of the structure of a dynamic optimal power flow device for a comprehensive energy system based on second-order cone relaxation and convex approximation, provided in an exemplary embodiment of the present invention. Figure 10 As shown, the device 1000 includes:

[0256] Module 1010 is used to construct the optimal power flow model of an integrated energy system, which is an integrated energy system of electricity, heat and gas.

[0257] The approximation module 1020 is used to constrain the non-convex power flow of the distribution network in the optimal power flow model using two-dimensional cone relaxation technology, and to perform controlled convex approximation on the nonlinear equations of the gas network and heat network in the optimal power flow model to obtain a convex optimization model.

[0258] Module 1030 is used to add an optimization framework with multi-time-scale dynamic characteristics to the convex optimization model to form a mixed integer second-order cone programming model.

[0259] The solver module 1040 is used to solve the mixed-integer second-order cone programming model using the Gurobi solver to obtain the power flow calculation results of the integrated energy system.

[0260] Exemplary electronic device

[0261] Figure 11 This is the structure of an electronic device provided in an exemplary embodiment of the present invention. For example... Figure 11 As shown, the electronic device 110 includes one or more processors 111 and memory 112.

[0262] The processor 111 may be a central processing unit (CPU) or other form of processing unit with data processing capabilities and / or instruction execution capabilities, and may control other components in the electronic device to perform desired functions.

[0263] The memory 112 may include one or more computer program products, which may include various forms of computer-readable storage media, such as volatile memory and / or non-volatile memory. The volatile memory may include, for example, random access memory (RAM) and / or cache memory. The non-volatile memory may include, for example, read-only memory (ROM), hard disk, flash memory, etc. One or more computer program instructions may be stored on the computer-readable storage medium, and the processor 111 may execute the program instructions to implement the methods of the software programs of the various embodiments of the present invention described above, and / or other desired functions. In one example, the electronic device may further include an input device 113 and an output device 114, which are interconnected via a bus system and / or other forms of connection mechanisms (not shown).

[0264] In addition, the input device 113 may also include, for example, a keyboard, a mouse, etc.

[0265] The output device 114 can output various information to the outside. The output device 114 may include, for example, a display, a speaker, a printer, and a communication network and its connected remote output devices, etc.

[0266] Of course, for the sake of simplicity, Figure 11 Only some of the components of this electronic device relevant to the present invention are shown, omitting components such as buses, input / output interfaces, etc. In addition, the electronic device may include any other suitable components depending on the specific application.

[0267] Exemplary computer program product and computer readable storage medium

[0268] In addition to the methods and apparatus described above, embodiments of the present invention may also be computer program products, which include computer program instructions that, when executed by a processor, cause the processor to perform the steps in the methods according to various embodiments of the present invention described in the "Exemplary Methods" section above.

[0269] The computer program product can be written in any combination of one or more programming languages ​​to perform the operations of the embodiments of the present invention. The programming languages ​​include object-oriented programming languages ​​such as Java and C++, as well as conventional procedural programming languages ​​such as C or similar languages. The program code can be executed entirely on the user's computing device, partially on the user's computing device, as a standalone software package, partially on the user's computing device and partially on a remote computing device, or entirely on a remote computing device or server.

[0270] Furthermore, embodiments of the present invention may also be computer-readable storage media storing computer program instructions thereon, which, when executed by a processor, cause the processor to perform the steps of the methods according to various embodiments of the present invention described in the "Exemplary Methods" section above.

[0271] The computer-readable storage medium may be any combination of one or more readable media. A readable medium may be a readable signal medium or a readable storage medium. A readable storage medium may be, for example, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or any combination thereof. More specific examples (a non-exhaustive list) of readable storage media include: an electrical connection having one or more wires, a portable disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof.

[0272] The basic principles of the present invention have been described above with reference to specific embodiments. However, it should be noted that the advantages, benefits, and effects mentioned in the present invention are merely examples and not limitations, and should not be considered as essential features of each embodiment of the present invention. Furthermore, the specific details disclosed above are for illustrative and facilitative purposes only, and are not limitations. These details do not limit the present invention to the necessity of employing the aforementioned specific details.

[0273] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on its differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. For system embodiments, since they largely correspond to method embodiments, the description is relatively simple; relevant parts can be referred to the descriptions in the method embodiments.

[0274] The block diagrams of devices, systems, devices, and systems involved in this invention are merely illustrative examples and are not intended to require or imply that they must be connected, arranged, or configured in the manner shown in the block diagrams. As those skilled in the art will recognize, these devices, systems, devices, and systems can be connected, arranged, and configured in any manner. Words such as “comprising,” “including,” “having,” etc., are open-ended terms meaning “including but not limited to,” and are used interchangeably with them. The terms “or” and “and” as used herein refer to the terms “and / or,” and are used interchangeably with them unless the context clearly indicates otherwise. The term “such as” as used herein refers to the phrase “such as but not limited to,” and is used interchangeably with it.

[0275] The methods and systems of the present invention may be implemented in many ways. For example, they may be implemented by software, hardware, firmware, or any combination of software, hardware, and firmware. The above-described order of steps for the methods is for illustrative purposes only, and the steps of the methods of the present invention are not limited to the order specifically described above unless otherwise specifically stated. Furthermore, in some embodiments, the present invention may also be implemented as a program recorded on a recording medium, the program comprising machine-readable instructions for implementing the methods according to the present invention. Thus, the present invention also covers recording media storing programs for performing the methods according to the present invention.

[0276] The above description has been given for purposes of illustration and description. Furthermore, this description is not intended to limit the embodiments of the invention to the forms disclosed herein. Although numerous exemplary aspects and embodiments have been discussed above, those skilled in the art will recognize certain variations, modifications, alterations, additions, and sub-combinations thereof.

Claims

1. A dynamic optimal power flow method for a comprehensive energy system based on second-order cone relaxation and convex approximation, characterized in that, include: Construct an optimal power flow model for an integrated energy system, which is an integrated energy system of electricity, heat and gas; Two-dimensional cone relaxation technique is used to constrain the non-convex power flow of the distribution network in the optimal power flow model, and controlled convex approximation is performed on the nonlinear equations of the gas network and heat network in the optimal power flow model to obtain a convex optimization model; An optimization framework with multi-time-scale dynamic characteristics is added to the convex optimization model to form a mixed integer second-order cone programming model; The mixed-integer second-order cone programming model was solved using the Gurobi solver to obtain the power flow calculation results of the integrated energy system.

2. The method according to claim 1, characterized in that, The objective function of the optimal power flow model is: minw1·F1+w2·F2-w3·F3 In the formula, w1, w2, and w3 are the influence weights on F1, F2, and F3, respectively; F1 is the total operating cost; F2 is the carbon emission cost; and F3 is the renewable energy consumption incentive. In the formula: C grid,t C gas,t C OM,t C DR,t C STOR,t R sell,t R subsidy,t These are, respectively, the main grid electricity purchase cost at time t, the natural gas purchase cost, the fixed and variable operation and maintenance costs of equipment, the demand response compensation cost, the energy storage cycle depreciation cost, the natural gas sales revenue, and the P2G subsidy revenue; In the formula, c carbon Cost per unit of carbon emissions; α e Carbon emission factor for purchased electricity; P grid,t Let α be the electrical power purchased from the main grid at time t; g G represents the carbon emission factor for natural gas. buy,t Let t be the electrical power purchased from the main grid at time t; In the formula, c reward The reward amount per unit of renewable energy consumption; P wind,t P represents the wind power absorbed at time t. PV,t Let t be the photovoltaic power generation absorbed at time t.

3. The method according to claim 1, characterized in that, The constraints of the optimal power flow model include: power network subsystem constraints, thermal network subsystem constraints, natural gas network subsystem constraints, coupling equipment constraints, and other constraints, among which, The constraints of the power network subsystem include: the classical AC node power balance equations and voltage drop constraints, wherein... The classic AC node power balance equation is as follows: In the formula: Let t represent the total active power and total reactive power injected into node i by all generating devices connected to node i at time t. V represents the total active power and total reactive power consumed by all loads flowing out of node i at time t; i,t V j,t Let θ represent the voltage magnitudes at node i and node j at time t, respectively; ij,t G represents the voltage phase angle difference between node i and node j at time t; ij B ij Let be the branch conductance and susceptance connecting node i and node j at time t, respectively; The voltage drop constraint is: In the formula: V i,t V j,t Let r be the voltage magnitudes at node i and node j at time t, respectively; ij x ij These represent the line impedance and reactance between node i and node j, respectively; P ij,t Q ij,t These represent the active power and reactive power between node i and node j at time t, respectively; I ij,t Let t be the current amplitude between node i and node j at time t; The constraints of the thermal network subsystem include: nodal heat power balance equations and pipe transport models; wherein... The node thermal power balance equation is: In the formula: Inject net heat power into node j at time t; Let be the power of the heat source and the heat load at node j at time t, respectively. These represent the heat release and heat charge power of the thermal storage device at node j at time t, respectively. The net heat power transfer between node j and node k at time t; Let be the sum of the net heat power connecting node j to all its adjacent nodes k at time t; The pipeline transport model is as follows: In the formula: Let c be the thermal power between node i and node j at time t; p The specific heat capacity of water; m ij,t Let t be the mass flow rate of the fluid (water) between node i and node j at time t, that is, the mass of water passing through per unit time; Let Ti be the water supply temperature at node i at time t; T0 be the initial water supply temperature. The constraints of the natural gas network subsystem include node flow balance equations and pipeline pressure drop equations, wherein... Node flow balance equation In the formula: It is the sum of the pipeline flows into node j from all upstream nodes i adjacent to node j; Let t be the flow rate of gas injected into node j at time t. The gas source is the source of gas supply. Let t be the gas production flow rate injected by the P2G device into node j; This is the sum of the pipeline flow from node j to all downstream nodes k; Let be the gas load flow rate at node j (t). Let J be the air flow rate consumed by the compressor at node t. The gas flow rate consumed by the CHP unit at node j is t. The pipeline pressure drop equation is as follows: In the formula: K represents the air pressure at nodes i and j at both ends of the pipeline at time t; ij f is the pressure drop coefficient of pipe ij, reflecting the inherent property of the pipe to cause pressure drop due to gas flow; ij,t Let f be the gas flow rate in pipe ij at time t. ij,t | is its absolute value; The constraints on the coupling equipment include: constraints on combined heat and power units, constraints on power-to-gas equipment, constraints on power-to-hydrogen equipment, and constraints on fuel cells and hydrogen gas turbines, wherein... The constraints of the combined heat and power unit are: In the formula: P t CHP , These represent the power generation and heat production of the CHP unit at time t, respectively. These are the maximum power generation and maximum heat production of the CHP unit, respectively; α is the lower limit of the heat-to-power ratio. η is the gas consumption of the CHP unit at time t; e The power generation efficiency of the CHP unit; The constraints of the electro-gas conversion equipment are: In the formula: P t P2G Let t be the electrical power consumed by the P2G device at time t; This represents the maximum power consumption of a P2G device. Let η be the gas production rate of the P2G device at time t; P2G The electrical conversion efficiency of the P2G device; LHV is the lower heating value of the gas; The constraints of the electro-hydrogen conversion equipment are: In the formula: P t P2H These represent the hydrogen production and electrical power consumption of the P2H device at time t, respectively. η represents the maximum power consumption of the P2H device. P2H The electro-hydrogen conversion efficiency of the P2H equipment; The constraints between the fuel cell and the hydrogen gas turbine are: In the formula: P t H2P P t HGT η represents the power generation of the fuel cell and the hydrogen gas turbine at time t, respectively; H2P η HGT These are the hydrogen-to-electricity conversion efficiencies of fuel cells and hydrogen gas turbines, respectively. These are the maximum power generation capacities of fuel cells and hydrogen gas turbines, respectively. Let t be the amount of hydrogen used by the fuel cell or hydrogen gas turbine at time t; This represents the maximum amount of hydrogen that can be used. The other constraints include: power grid demand response constraints and heating network demand response constraints, wherein... The power grid demand response constraint is: In the formula: γ e This is the proportional adjustment coefficient for electrical load demand response; Let ΔP be the original active power and reactive power of the electrical load at time t; d,t ΔQ d,t These represent the demand response adjustments for active and reactive power of the electrical load at time t, respectively. The heating network demand response constraints are as follows: In the formula: γ h This is the adjustment ratio coefficient for heat load demand response; ΔΦ represents the initial power of the heat load at time t. L,t U represents the demand response adjustment of the heat load at time t. Φ,t This represents the upper limit of the heat load regulation capacity at time t.

4. The method according to claim 1, characterized in that, The non-convex power flow of the distribution network is constrained by introducing auxiliary variables to eliminate quadratic terms. The relaxed second-order cone constraint is: In the formula: α i,t As an auxiliary variable, it represents the square of the voltage at node i at time t; β ij,t As an auxiliary variable, P represents the square of the current amplitude between node i and node j at time t; ij,t Q ij,t These represent the active power and reactive power between node i and node j at time t, respectively. β ij,t -α i,t The difference between the square of the current and the square of the voltage, relating the quadratic terms of the current and voltage; β ij,t +α i,t The sum of the square of the current and the square of the voltage.

5. The method according to claim 1, characterized in that, The air network is subjected to a controlled convex approximation, resulting in the relaxed convex constraint as follows: In the formula: G ij Let be the gas flow rate in pipe ij; auxiliary variable η ij =(d ij+ -d ij- )Δx ij d represents the directional pressure difference. ij+ This indicates that the airflow is from node i to node j; d ij- This indicates that the airflow is from node j to node i, K ij Let be the pressure drop coefficient of pipe ij.

6. The method according to claim 1, characterized in that, The heating network is subjected to a controlled convex approximation, including: Linearized approximation of the pipe temperature drop equation: In the formula: T end T start These are the temperatures at the end and beginning of the pipe, respectively; T a The ambient temperature is represented by λ and L, respectively, which are the pipe heat loss coefficient and pipe length. p ρ is the specific heat capacity at constant pressure of the fluid; m is the mass flow rate of the fluid; Linearization of the thermal power equation: Φ=c p m(T s -T r ) In the formula: Φ is the thermal power; T s Temperature on the heating side (or high-temperature side); T r This refers to the temperature on the heated side (or the lower temperature side). Piecewise linearization of heat transfer in pipes and node temperatures: In the formula: T out γ is the system outlet temperature; s δ represents the temperature / heat loss value of the s-th segment node; s For the s-th segment in T out The proportion and weight in; N s The number of segments; where The segment points (γ) corresponding to the flow-pressure drop or flow-heat loss curve s ,m s Approaching: Where: m s Let δ represent the flow rate value of the s-th segment; s,ij (t) represents the s-th segment in f ij The weights in (t).

7. The method according to claim 2, characterized in that, The expression for the mixed-integer second-order cone programming model is: min w1·F1+w2·F2-w3·F3 st Linear constraints: Power balance, thermodynamic model, coupling device, energy storage dynamics Demand response, hydrogen systems, piecewise linear natural gas,... Integer variable constraints: m ch (t)+μ disch (t)≤1,μ ch (t),μ disch (t)∈{0,1} Second-order cone constraint: In the formula, μ ch (t) represents the charging state flag of the energy storage device at time t, μ ch (t) = 1 indicates that the energy storage is in a charging state at time t, μ ch (t) = 0 indicates that the energy storage is in a non-charging state at time t; μ disch (t) represents the charging state flag of the energy storage device at time t, μ disch (t) = 1 indicates that the stored energy is in a discharge state at time t, μ disch (t) = 0 indicates that the stored energy is in a non-discharge state at time t; μ ch (t)+μ disch (t)≤1 indicates that at any given time, the stored energy can only be in one of three states: charging, discharging, or neither charging nor discharging; it cannot be charged or discharged simultaneously. ij (t) represents the active power of the branch between node i and node j at time t; Q ij (t) represents the reactive power of the branch between node i and node j at time t; L ij (t)-U i (t) The difference between the square of the current and the square of the voltage, relating the quadratic terms of the current and voltage; L ij (t)+U i (t) The sum of the squares of the current and the squares of the voltage is used as the upper bound of the second-order cone.

8. A dynamic optimal power flow device for a comprehensive energy system based on second-order cone relaxation and convex approximation, characterized in that, include: The module is used to build the optimal power flow model of an integrated energy system, which is an integrated energy system of electricity, heat and gas. An approximation module is used to constrain the non-convex power flow of the distribution network in the optimal power flow model using two-dimensional cone relaxation techniques, and to perform controlled convex approximation on the nonlinear equations of the gas network and heat network in the optimal power flow model to obtain a convex optimization model. A forming module is used to add an optimization framework with multi-time-scale dynamic characteristics to the convex optimization model to form a mixed integer second-order cone programming model. The solver module is used to solve the mixed-integer second-order cone programming model using the Gurobi solver to obtain the power flow calculation results of the integrated energy system.

9. The apparatus according to claim 8, characterized in that, The objective function of the optimal power flow model is: minw1·F1+w2·F2-w3·F3 In the formula, w1, w2, and w3 are the influence weights on F1, F2, and F3, respectively; F1 is the total operating cost; F2 is the carbon emission cost; and F3 is the renewable energy consumption incentive. In the formula: C grid,t C gas,t C OM,t C DR,t C STOR,t R sell,t R subsidy,t These are, respectively, the main grid electricity purchase cost at time t, the natural gas purchase cost, the fixed and variable operation and maintenance costs of equipment, the demand response compensation cost, the energy storage cycle depreciation cost, the natural gas sales revenue, and the P2G subsidy revenue; In the formula, c carbon Cost per unit of carbon emissions; α e Carbon emission factor for purchased electricity; P grid,t Let α be the electrical power purchased from the main grid at time t; g G represents the carbon emission factor for natural gas. buy,t Let t be the electrical power purchased from the main grid at time t; In the formula, c reward The reward amount per unit of renewable energy consumption; P wind,t P represents the wind power absorbed at time t. PV,t Let t be the photovoltaic power generation absorbed at time t.

10. The apparatus according to claim 8, characterized in that, The constraints of the optimal power flow model include: power network subsystem constraints, thermal network subsystem constraints, natural gas network subsystem constraints, coupling equipment constraints, and other constraints, among which, The constraints of the power network subsystem include: the classical AC node power balance equations and voltage drop constraints, wherein... The classic AC node power balance equation is as follows: In the formula: Let t represent the total active power and total reactive power injected into node i by all generating devices connected to node i at time t. V represents the total active power and total reactive power consumed by all loads flowing out of node i at time t; i,t V j,t Let θ represent the voltage magnitudes at node i and node j at time t, respectively; ij,t G represents the voltage phase angle difference between node i and node j at time t; ij B ij Let be the branch conductance and susceptance connecting node i and node j at time t, respectively; The voltage drop constraint is: In the formula: V i,t V j,t Let r be the voltage magnitudes at node i and node j at time t, respectively; ij x ij These represent the line impedance and reactance between node i and node j, respectively; P ij,t Q ij,t These represent the active power and reactive power between node i and node j at time t, respectively; I ij,t Let t be the current amplitude between node i and node j at time t; The constraints of the thermal network subsystem include: nodal heat power balance equations and pipe transport models; wherein... The node thermal power balance equation is: In the formula: Inject net heat power into node j at time t; Let be the power of the heat source and the heat load at node j at time t, respectively. These represent the heat release and heat charge power of the thermal storage device at node j at time t, respectively. The net heat power transfer between node j and node k at time t; Let be the sum of the net heat power connecting node j to all its adjacent nodes k at time t; The pipeline transport model is as follows: In the formula: Let c be the thermal power between node i and node j at time t; p The specific heat capacity of water; m ij,t Let t be the mass flow rate of the fluid (water) between node i and node j at time t, that is, the mass of water passing through per unit time; Let Ti be the water supply temperature at node i at time t; T0 be the initial water supply temperature. The constraints of the natural gas network subsystem include node flow balance equations and pipeline pressure drop equations, wherein... Node flow balance equation In the formula: It is the sum of the pipeline flows into node j from all upstream nodes i adjacent to node j; Let t be the flow rate of gas injected into node j at time t. The gas source is the source of gas supply. Let t be the gas production flow rate injected by the P2G device into node j; This is the sum of the pipeline flow from node j to all downstream nodes k; Let be the gas load flow rate at node j (t). Let J be the air flow rate consumed by the compressor at node t. The gas flow rate consumed by the CHP unit at node j is t. The pipeline pressure drop equation is as follows: In the formula: K represents the air pressure at nodes i and j at both ends of the pipeline at time t; ij f is the pressure drop coefficient of pipe ij, reflecting the inherent property of the pipe to cause pressure drop due to gas flow; ij,t Let f be the gas flow rate in pipe ij at time t. ij,t | is its absolute value; The constraints on the coupling equipment include: constraints on combined heat and power units, constraints on power-to-gas equipment, constraints on power-to-hydrogen equipment, and constraints on fuel cells and hydrogen gas turbines, wherein... The constraints of the combined heat and power unit are: In the formula: P t CHP , These represent the power generation and heat production of the CHP unit at time t, respectively. These are the maximum power generation and maximum heat production of the CHP unit, respectively; α is the lower limit of the heat-to-power ratio. η is the gas consumption of the CHP unit at time t; e The power generation efficiency of the CHP unit; The constraints of the electro-gas conversion equipment are: In the formula: P t P2G Let t be the electrical power consumed by the P2G device at time t; This represents the maximum power consumption of a P2G device. Let η be the gas production rate of the P2G device at time t; P2G The electrical conversion efficiency of the P2G device; LHV is the lower heating value of the gas; The constraints of the electro-hydrogen conversion equipment are: In the formula: P t P2H These represent the hydrogen production and electrical power consumption of the P2H device at time t, respectively. η represents the maximum power consumption of the P2H device. P2H The electro-hydrogen conversion efficiency of the P2H equipment; The constraints between the fuel cell and the hydrogen gas turbine are: In the formula: P t H2P P t HGT η represents the power generation of the fuel cell and the hydrogen gas turbine at time t, respectively; H2P η HGT These are the hydrogen-to-electricity conversion efficiencies of fuel cells and hydrogen gas turbines, respectively. These are the maximum power generation capacities of fuel cells and hydrogen gas turbines, respectively. Let t be the amount of hydrogen used by the fuel cell or hydrogen gas turbine at time t; This represents the maximum amount of hydrogen that can be used. The other constraints include: power grid demand response constraints and heating network demand response constraints, wherein... The power grid demand response constraint is: In the formula: γ e This is the proportional adjustment coefficient for electrical load demand response; Let ΔP be the original active power and reactive power of the electrical load at time t; d,t ΔQ d,t These represent the demand response adjustments for active and reactive power of the electrical load at time t, respectively. The heating network demand response constraints are as follows: In the formula: γ h This is the adjustment ratio coefficient for heat load demand response; ΔΦ represents the initial power of the heat load at time t. L,t U represents the demand response adjustment of the heat load at time t. Φ,t This represents the upper limit of the heat load regulation capacity at time t.

11. The apparatus according to claim 8, characterized in that, The non-convex power flow of the distribution network is constrained by introducing auxiliary variables to eliminate quadratic terms. The relaxed second-order cone constraint is: In the formula: α i,t As an auxiliary variable, it represents the square of the voltage at node i at time t; β ij,t As an auxiliary variable, P represents the square of the current amplitude between node i and node j at time t; ij,t Q ij,t These represent the active power and reactive power between node i and node j at time t, respectively. β ij,t -α i,t The difference between the square of the current and the square of the voltage, relating the quadratic terms of the current and voltage; β ij,t +α i,t The sum of the square of the current and the square of the voltage.

12. The apparatus according to claim 8, characterized in that, The air network is subjected to a controlled convex approximation, resulting in the relaxed convex constraint as follows: In the formula: G ij Let be the gas flow rate in pipe ij; auxiliary variable η ij =(d ij+ -d ij- )Δx ij d represents the directional pressure difference. ij+ This indicates that the airflow is from node i to node j; d ij- This indicates that the airflow is from node j to node i, K ij Let be the pressure drop coefficient of pipe ij.

13. The apparatus according to claim 8, characterized in that, The heating network is subjected to a controlled convex approximation, including: Linearized approximation of the pipe temperature drop equation: In the formula: T end T start These are the temperatures at the end and beginning of the pipe, respectively; T a The ambient temperature is represented by λ and L, respectively, which are the pipe heat loss coefficient and pipe length. p ρ is the specific heat capacity at constant pressure of the fluid; m is the mass flow rate of the fluid; Linearization of the thermal power equation: Φ=c p m(T s -T r ) In the formula: Φ is the thermal power; T s Temperature on the heating side (or high-temperature side); T r This refers to the temperature on the heated side (or the lower temperature side). Piecewise linearization of heat transfer in pipes and node temperatures: In the formula: T out γ is the system outlet temperature; s δ represents the temperature / heat loss value of the s-th segment node; s For the s-th segment in T out The proportion and weight in; N s The number of segments; where The segment points (γ) corresponding to the flow-pressure drop or flow-heat loss curve s ,m s Approaching: Where: m s Let δ represent the flow rate value of the s-th segment; s,ij (t) represents the s-th segment in f ij The weights in (t).

14. The apparatus according to claim 9, characterized in that, The expression for the mixed-integer second-order cone programming model is: minw1·F1+w2·F2-w3·F3 st Linear constraints: Power balance, thermodynamic model, coupling device, energy storage dynamics Demand response, hydrogen systems, piecewise linear natural gas,... Integer variable constraints: m ch (t)+μ disch (t)≤1,μ ch (t),μ disch (t)∈{0,1} Second-order cone constraint: In the formula, μ ch (t) represents the charging state flag of the energy storage device at time t, μ ch (t) = 1 indicates that the energy storage is in a charging state at time t, μ ch (t) = 0 indicates that the energy storage is in a non-charging state at time t; μ disch (t) represents the charging state flag of the energy storage device at time t, μ disch (t) = 1 indicates that the stored energy is in a discharge state at time t, μ disch (t) = 0 indicates that the stored energy is in a non-discharge state at time t; μ ch (t)+μ disch (t)≤1 indicates that at any given time, the stored energy can only be in one of three states: charging, discharging, or neither charging nor discharging; it cannot be charged or discharged simultaneously. ij (t) represents the active power of the branch between node i and node j at time t; Q ij (t) represents the reactive power of the branch between node i and node j at time t; L ij (t)-U i (t) The difference between the square of the current and the square of the voltage, relating the quadratic terms of the current and voltage; L ij (t)+U i (t) The sum of the squares of the current and the squares of the voltage is used as the upper bound of the second-order cone.

15. A computer-readable storage medium, characterized in that, The storage medium stores a computer program for performing the method described in any one of claims 1-7.

16. An electronic device, characterized in that, The electronic device includes: processor; Memory used to store the processor's executable instructions; The processor is configured to read the executable instructions from the memory and execute the instructions to implement the method described in any one of claims 1-7.