Power transaction matching method and system based on smart contract

By analyzing power grid data through smart contracts and graph neural networks, overload risks are identified and congestion paths are predicted, and additional fees are generated. This solves the problems of single point of failure and computational complexity in centralized optimization algorithms, and realizes real-time, secure and fair power trading.

CN120894136AActive Publication Date: 2025-11-04CHINA ENERGY CONSTR (BEIJING) ENERGY RES INST CO LTD
View PDF 8 Cites 0 Cited by

Patent Information

Application Number
CN202511078216.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-08-01
Publication Date
2025-11-04
Estimated Expiration
2045-08-01

AI Technical Summary

Technical Problem

In existing power trading systems, centralized optimization algorithms rely on central servers, leading to a high risk of single point of failure, high computational complexity, difficulty in meeting real-time requirements, and a lack of decentralized trust mechanisms in transaction path allocation, which affects the fairness and transparency of transaction execution.

Method used

A smart contract-based power trading matching method is adopted. By analyzing power grid topology and heat map data through graph neural networks, potential overload risk nodes are identified, congestion paths are predicted, and congestion surcharges are generated through smart contracts to guide both parties to choose non-congestion paths.

Benefits of technology

It has improved the real-time performance and security of electricity trading, avoided the risk of single points of failure, ensured the fairness and transparency of the trading path, optimized the allocation of electricity resources, reduced trading failures, and improved the operational efficiency of the electricity market.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120894136A_ABST
    Figure CN120894136A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of smart contracts, provides a smart contract-based power transaction matching method and system, and solves the problems of poor matching efficiency and low safety of power transaction in a power transmission congestion scene. The method comprises the following steps: collecting a power grid topological structure, a historical blocking condition and line temperature data, analyzing a historical load peak value to generate load rate data of each line section, and combining real-time temperature monitoring value fusion processing to generate a fusion thermodynamic diagram reflecting a power grid operation state; inputting the fused thermodynamic diagram into a pre-trained graph neural network, identifying a potential overload risk node and predicting a possible blocking path, and calculating the remaining available capacity of the line according to a prediction result as a tradable capacity margin; differentiated blocking additional fee terms are automatically generated in the intelligent contract based on the capacity margin, and the two transaction parties are guided to preferentially select a non-blocking path to complete the power transaction through a price signal. According to the invention, the matching efficiency and safety of power transaction in a power transmission congestion scene are improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of smart contracts, in particular to a power transaction matching method and system based on smart contracts. BACKGROUND

[0002] With the advancement of power market reform, the scale of cross-regional power transactions is continuously expanding, and the problem of transmission congestion is becoming increasingly prominent. Power grids are prone to line overload during peak load periods, leading to transaction execution failure or reduced transmission efficiency. Therefore, there is an urgent need for an automated matching method that can predict congestion risks in real time and dynamically adjust transaction paths to improve the execution efficiency and safety of power transactions.

[0003] Currently, there are studies that propose a centralized optimization algorithm-based congestion management method. The method collects line load data in real time through the power grid dispatch center, combines linear programming or dynamic load flow calculation to generate an optimal transmission path solution, and pushes it to the transaction platform for execution. This method relies on a central server to process network-wide data, uses mathematical optimization models to calculate available transmission capacity, and prioritizes non-congestion paths during transaction matching.

[0004] The calculation process of this solution is highly dependent on centralized servers, which poses a single point of failure risk. Moreover, the high computational complexity of the optimization algorithm makes it difficult to meet the real-time requirements of high-frequency transactions. In addition, due to the lack of a decentralized trust mechanism, the parties involved in the transaction may dispute the path solution provided by the dispatch center, affecting the fairness and transparency of transaction execution. SUMMARY

[0005] The present application provides a power transaction matching method and system based on smart contracts to address the low efficiency and safety of existing power transaction matching in the context of transmission congestion.

[0006] In a first aspect, the present application provides a power transaction matching method based on smart contracts, comprising:

[0007] Collecting power grid topology data, historical congestion records, and line temperature distribution data;

[0008] Based on the power grid topology data and the historical congestion records, combining a load rate prediction model to generate line load rate data, and based on the line load rate data and the line temperature distribution data, generating a fusion heat map;

[0009] Inputting the fusion heat map into a pre-trained graph neural network, identifying potential overload risk nodes in the power grid from the fusion heat map through the graph neural network, and predicting congestion paths in the power grid based on the potential overload risk nodes to generate a congestion path prediction result;

[0010] Based on the congestion path prediction result, the tradable capacity margin is calculated, and a congestion surcharge item is generated in the smart contract according to the tradable capacity margin;

[0011] Through the congestion surcharge item, the power transaction parties are guided to select a non-congestion path in the power grid to complete the power transaction matching.

[0012] Optionally, the potential overload risk node in the power grid is identified from the fusion heat map through the graph neural network, and the congestion path in the power grid is predicted based on the potential overload risk node to generate a congestion path prediction result, comprising:

[0013] Each temperature monitoring point in the fusion heat map is taken as a graph node;

[0014] According to the line connection relationship in the power grid topology data, an adjacency matrix representing the connection relationship between graph nodes is constructed;

[0015] The temperature value, line load rate data and spatial coordinates of each graph node are encoded into a feature vector of the graph node;

[0016] Based on the adjacency matrix, the feature vector is updated through the neighborhood aggregation operation of the graph neural network, and when the updated feature vector meets the preset overload judgment condition, the corresponding graph node is marked as a potential overload risk node;

[0017] According to the spatial distribution characteristics of all potential overload risk nodes, the congestion path in the power grid is predicted to generate a congestion path prediction result.

[0018] Optionally, the feature vector is updated based on the adjacency matrix through the neighborhood aggregation operation of the graph neural network, and when the updated feature vector meets the preset overload judgment condition, the corresponding graph node is marked as a potential overload risk node, comprising:

[0019] For each graph node, the following process is performed in turn as the current graph node: extracting adjacent graph nodes directly connected to the current graph node from the adjacency matrix to form an adjacent graph node set;

[0020] Obtain the temperature value and line load rate data of all adjacent graph nodes in the adjacent graph node set to filter the corresponding data of the adjacent graph node set;

[0021] The temperature value and line load rate data of the current graph node are respectively weighted and averaged with the corresponding data of the adjacent graph node set to generate aggregated temperature features and aggregated load rate features;

[0022] The aggregated temperature features and the aggregated load rate features are fused into the feature vector of the graph node to form an updated feature vector;

[0023] When the updated feature vector satisfies both the aggregated temperature feature being greater than a preset temperature threshold and the aggregated load rate feature being greater than a preset load rate threshold, mark the current graph node as a potential overload risk node.

[0024] Optionally, the weighted average calculation of the temperature value of the current graph node and the line load rate data and the corresponding data of the adjacent graph node set respectively to generate the aggregated temperature feature and the aggregated load rate feature comprises:

[0025] Obtain the line impedance parameter between the current graph node and each adjacent graph node, and the rated transmission capacity of the line on which each adjacent graph node is located;

[0026] Based on the line impedance parameter, calculate the temperature weight value of each adjacent graph node;

[0027] Weighted sum the temperature value of the current graph node and the temperature value of all adjacent graph nodes according to the temperature weight value, divide the first weighted sum result by the first weight sum, and generate the aggregated temperature feature;

[0028] Based on the rated transmission capacity, calculate the load weight value of each adjacent graph node;

[0029] Weighted sum the line load rate data of the current graph node and the line load rate data of all adjacent graph nodes according to the load weight value, divide the second weighted sum result by the second weight sum, and generate the aggregated load rate feature.

[0030] Optionally, the line load rate data is generated based on the power grid topology data and the historical congestion record, combined with a load rate prediction model, and the fusion heat map is generated based on the line load rate data and the line temperature distribution data, comprising:

[0031] Map the line connection relationship in the power grid topology data to a spatial coordinate;

[0032] Input the load peak value data in the historical congestion record into a load rate prediction model, and output the line load rate data of each line segment;

[0033] Associate the line load rate data with the spatial coordinate to form a load rate distribution map;

[0034] Extract the position and temperature value of the temperature monitoring point from the line temperature distribution data;

[0035] Spatially superimpose the load rate distribution map and the position of the temperature monitoring point;

[0036] In the superimposed spatial distribution map, the line load rate data and the temperature values at the same position are weighted and fused to generate a fused thermal map.

[0037] Optionally, based on the congestion path prediction result, a tradable capacity margin is calculated, and a congestion surcharge item is generated in the smart contract according to the tradable capacity margin, including:

[0038] Locating a congestion line segment in the congestion path prediction result;

[0039] Obtaining the rated transmission capacity and actual load data of the congestion line segment;

[0040] Based on the rated transmission capacity and the actual load data, the remaining available capacity of the congestion line segment is calculated as a tradable capacity margin;

[0041] According to the comparison relationship between the tradable capacity margin and the preset capacity threshold, a surcharge coefficient is determined;

[0042] In the smart contract, a congestion surcharge item containing the surcharge coefficient is created.

[0043] Optionally, the congestion surcharge item is used to guide the power transaction parties to select a non-congestion path in the power grid to complete power transaction matching, including:

[0044] In the transaction interface of the smart contract, a first transaction option allowing selection of a congestion path and a second transaction option allowing selection of a non-congestion path are displayed side by side, wherein the first transaction option adopts a premium offer, and the second transaction option adopts a benchmark electricity price offer;

[0045] When it is monitored that the power transaction parties select the second transaction option, a power transaction contract corresponding to the non-congestion path is immediately executed;

[0046] When it is monitored that the power transaction parties select the first transaction option, the path optimization rules of the smart contract are automatically triggered to generate an optimized transaction scheme containing a non-congestion path and a corresponding benchmark electricity price offer;

[0047] Based on the confirmation instruction of the power transaction parties to the optimized transaction scheme, the power transaction matching is completed.

[0048] In a second aspect, the present application provides a power transaction matching system based on a smart contract, including:

[0049] A collection template is used to collect power grid topology data, historical congestion records, and line temperature distribution data;

[0050] generating line load rate data based on the power grid topology data and the historical congestion record in combination with a load rate prediction model, generating a fusion heat map based on the line load rate data and the line temperature distribution data;

[0051] The input module is configured to input the fusion heat map into a pre-trained graph neural network, identify potential overload risk nodes in the power grid from the fusion heat map through the graph neural network, predict a congestion path in the power grid based on the potential overload risk nodes, and generate a congestion path prediction result;

[0052] The calculation module is configured to calculate a tradable capacity margin based on the congestion path prediction result, and generate a congestion surcharge item in a smart contract according to the tradable capacity margin;

[0053] The selection module is configured to guide the two parties of the power transaction to select a non-congestion path in the power grid through the congestion surcharge item to complete the power transaction matching.

[0054] In a third aspect, the present application provides a computing device including a processor and a memory, wherein the memory stores a computer program, and the processor is configured to execute the computer program to perform the power transaction matching method based on a smart contract according to any one of the first aspect.

[0055] In a fourth aspect, the present application provides a computer storage medium storing computer program instructions, wherein the computer program instructions are executed by a processor to implement the power transaction matching method based on a smart contract according to any one of the first aspect.

[0056] In the present application, a power transaction matching method based on a smart contract is provided, which includes: collecting power grid topology data, historical congestion records and line temperature distribution data; generating line load rate data based on the power grid topology data and the historical congestion record in combination with a load rate prediction model, generating a fusion heat map based on the line load rate data and the line temperature distribution data; inputting the fusion heat map into a pre-trained graph neural network, identifying potential overload risk nodes in the power grid from the fusion heat map through the graph neural network, predicting a congestion path in the power grid based on the potential overload risk nodes, and generating a congestion path prediction result; calculating a tradable capacity margin based on the congestion path prediction result, and generating a congestion surcharge item in a smart contract according to the tradable capacity margin; guiding the two parties of the power transaction to select a non-congestion path in the power grid through the congestion surcharge item to complete the power transaction matching.

[0057] The technical scheme provided by the present application has the following beneficial effects:

[0058] The application obtains power grid structure, historical operation state and real-time temperature monitoring data, provides complete data basis for subsequent analysis, and ensures that the input information of the prediction model is comprehensive and accurate. The model is trained using historical data to predict the current line load condition, and potential high load risk areas are found in advance to provide a basis for congestion warning. The load rate and temperature data are combined for analysis to intuitively reflect the operation state of each region of the power grid, facilitating the identification of the correlation between overload and temperature anomalies. The power grid topology and heat map data are analyzed by a graph neural network to accurately locate overload risk points and predict possible congestion transmission paths. The transaction fee is dynamically adjusted according to the remaining available capacity, and economic means are used to guide transaction behavior to optimize power resource allocation. The intelligent optimization of transaction paths is realized to reduce transaction failures caused by congestion, and the operation efficiency and safety of the power market are improved.

[0059] Further, the application also takes the temperature monitoring points in the fusion heat map as graph nodes, constructs an adjacency matrix based on the power grid topology, and encodes the temperature, load rate and spatial coordinates of each node into a feature vector; the feature vector is updated using the neighborhood aggregation operation of the graph neural network, and the nodes that meet the overload condition are marked as risk nodes, and finally the congestion path in the power grid is predicted according to the distribution of the risk nodes.

[0060] Moreover, the scheme combines the graph neural network and power grid topology analysis to accurately identify overload risk areas and predict congestion paths, providing reliable congestion warning information for power trading, and improving the accuracy and real-time performance of the prediction through intelligent data processing, effectively supporting transaction decisions.

[0061] These aspects or other aspects of the application will be more apparent in the following description of the embodiments. BRIEF DESCRIPTION OF DRAWINGS

[0062] In order to more clearly illustrate the technical solutions in the embodiments of the application or the prior art, the following will briefly introduce the drawings needed to be used in the embodiment or prior art description. Obviously, the drawings in the following description are some embodiments of the application, and those skilled in the art can also obtain other drawings according to these drawings without creative labor.

[0063] Figure 1 A flowchart of a power transaction matching method based on a smart contract provided by an embodiment of the application;

[0064] Figure 2 A structural schematic diagram of a power transaction matching system based on a smart contract provided by an embodiment of the application;

[0065] Figure 3 A structural schematic diagram of a computing device provided by an embodiment of the application. DETAILED DESCRIPTION

[0066] In order for those skilled in the art to better understand the scheme of the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application.

[0067] In some processes described in the specification and claims of the present application and the above description, a plurality of operations occurring in a specific order are included, but it should be clearly understood that these operations can be executed or in parallel without the order in which they appear in this text. The serial numbers of the operations, such as 101, 102, etc., are only used to distinguish different operations, and the serial numbers themselves do not represent any execution order. In addition, these processes can include more or fewer operations, and these operations can be executed in sequence or in parallel. It should be noted that the descriptions of "first", "second", etc. in this text are used to distinguish different messages, devices, modules, etc. and do not represent the order of precedence. Also, "first" and "second" are not of different types.

[0068] In the current power trading system, the existing congestion management method mainly relies on centralized optimization algorithm, which is calculated and distributed by the dispatch center. This method has two key problems: first, all data is processed in the center server, once the system fails, the entire trading process will be interrupted; second, the calculation process is complex and time-consuming, and it is difficult to respond in time when the power demand changes rapidly, resulting in low trading efficiency. More importantly, since the path allocation is completely determined by the central agency, the trading parties cannot verify the fairness of the calculation results, which is easy to cause trust problems.

[0069] To solve these problems, the present application proposes a power trading matching method based on smart contract. This method automatically collects power grid topology data through the blockchain network, analyzes the line load and temperature changes using intelligent algorithms, and predicts possible congestion problems in advance. When it is detected that a line is about to overload, the system will automatically adjust the transaction cost of the line to guide the buyer and seller to choose a more unblocked power transmission path. This method completely avoids the risk of failure of a single central node, all calculation processes and data are open and transparent, and the trading parties can verify in real time. At the same time, the fast response capability of the intelligent algorithm ensures the timeliness of the trading decision, which not only solves the calculation delay problem of the existing scheme, but also realizes the optimal allocation of power transmission resources through the cost adjustment mechanism.

[0070] The technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, not all embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative labor are within the scope of protection of the present application.

[0071] Figure 1 A flowchart of a power transaction matching method based on a smart contract according to an embodiment of the present application is shown in FIG. 1, which comprises the following steps: Figure 1

[0072] Step 101: Collect power grid topology data, historical congestion records, and line temperature distribution data.

[0073] In step 101, the line is the basic transmission unit that constitutes the power grid, specifically the power transmission channel connecting various nodes (such as power stations, substations, and power utilization facilities) in the power grid, which has a clear start and end point location, rated transmission capacity, and impedance parameters. The "power grid" is a complete power transmission network formed by connecting multiple such lines according to a specific topology, including the collection of all lines and their connection relationships. In this scheme, the line, as a component of the power grid, is the basis for generating the fused thermal map, and the connection relationships of multiple lines constitute the power grid topology data, while the congestion problem of the power grid ultimately reflects the overload risk of specific line sections. The power grid topology data refers to the connection relationship data between various power equipment (such as substations and transmission lines) in the power grid, including line start and end points, connection methods, and other structural information. In this application, it is used to construct the physical connection model of the power grid. The historical congestion records refer to line overload events and related data that occurred in the past operation of the power grid, including overload time, line location, and load peak value. It is used to analyze the congestion pattern. The line temperature distribution data refers to the temperature values of each monitoring point of the transmission line collected by temperature sensors in real time. It is used to evaluate the operating state of the line.

[0074] In the embodiment of the present application, first, the topology data describing the structure of the power grid is obtained from the power grid management system, including the connection relationships and electrical parameters of all transmission lines. At the same time, the line overload event data recorded in the historical database is retrieved, including information such as occurrence time, location, and severity. Finally, through the deployment of a temperature sensor network on the line, real-time temperature readings of each monitoring point are collected. These three types of data together form the input basis for subsequent analysis.

[0075] For example, a regional power grid contains three main transmission lines: line A-B connecting substations A and B, line A-C connecting substations A and C, and line B-C connecting substations B and C. The system first obtains the connection relationship topology graph of the three lines, then retrieves 12 overload records of the three lines during the summer peak period of the past year, and simultaneously collects real-time temperature data through the 6 temperature sensors installed on each line, where the current temperature of the middle monitoring point of line A-B is 85 degrees, and the temperature of the end monitoring point of line B-C is 83 degrees. These data will be used for subsequent processing.

[0076] ​Step 102: Based on the power grid topology data and the historical congestion records, a line load rate data is generated in combination with a load rate prediction model, and a fusion heat map is generated based on the line load rate data and the line temperature distribution data.

[0077] In step 102, the load rate prediction model specifically refers to a machine learning model for predicting line load rate based on load peak data in historical congestion records, and the model type is not specifically limited. It can be any prediction model that can predict the current or future line load rate based on historical load data, including but not limited to time series prediction model, regression model or deep learning model. The model learns the historical load variation law through training to output predicted load rate data for each line segment. Line load rate data represents the ratio of current actual load to maximum carrying capacity. The fusion heat map represents a visualization chart formed by spatially superimposing line load rate and temperature data, with color depth representing risk level.

[0078] In the embodiments of the present application, the load peak data in the historical congestion records is input into the pre-trained load rate prediction model to output the predicted load rate values of each line segment. At the same time, the line connection relationship in the power grid topology data is mapped to the position information in the plane coordinate system. The predicted load rate values are labeled to the corresponding line positions to form a load rate distribution map. The position coordinates and temperature readings of each monitoring point are extracted from the temperature monitoring data. The load rate distribution map and the temperature monitoring point positions are spatially matched, and the load rate and temperature data at the same position are combined and calculated according to the set weight to finally generate a fusion heat map representing the risk level with color gradient.

[0079] For example, taking the aforementioned regional power grid as an example, the load rate prediction model predicts that the current line A-B load rate is 95%, the line A-C load rate is 90%, and the line B-C load rate is 93% according to historical data. These values are labeled to the corresponding line positions. At the same time, the positions and readings of the six temperature monitoring points are obtained, and the temperature of the middle monitoring point on line A-B is 85 degrees. The load rate 95% and the temperature 85 degrees are combined and calculated according to the weight of 6:4 to obtain the risk value of this point as 91. After processing all monitoring points in the same way, a complete fusion heat map is generated, and the middle section of line A-B in the map is displayed in red indicating high risk.

[0080] Step 103: inputting the fusion heat map into a pre-trained graph neural network, identifying potential overload risk nodes in the power grid from the fusion heat map through the graph neural network, and predicting congestion paths in the power grid based on the potential overload risk nodes to generate congestion path prediction results.

[0081] In step 103, the graph neural network represents a deep learning model specially designed to process graph-structured data, capable of analyzing the relationships between nodes. The potential overload risk node represents the monitoring point position determined by the model as likely to overload. The congestion path prediction result refers to the output of the power grid after analysis by the graph neural network, indicating the transmission line section and its location information that may experience overload. Specifically, it represents the line section connected by the temperature monitoring points marked as potential overload risk nodes. This result includes the location and severity of the congested line, which is used to guide subsequent capacity margin calculation and transaction path selection.

[0082] In the embodiments of the present application, each temperature monitoring point in the heat map is taken as a node of the graph neural network. An adjacency matrix is constructed according to the power grid topology data, where the matrix positions corresponding to the monitoring points of connected lines are set to 1. The temperature value, load rate data, and spatial coordinates of each node are combined into a feature vector. Through the neighborhood aggregation operation of the graph neural network, each node absorbs the feature information of adjacent nodes to update its own features. When the updated features of a certain node exceed the temperature and load rate thresholds at the same time, it is marked as a risk node. Finally, according to the spatial distribution of all risk nodes, the predicted congestion path is connected.

[0083] For example, taking the aforementioned heat map as an example, 6 monitoring points are set as graph nodes. According to the connection relationship of the lines, a 6x6 adjacency matrix is constructed, where monitoring point 1 (start of line A-B) is connected to monitoring point 2 (end of line A-B) and monitoring point 3 (start of line A-C). The feature vector of node 1 is [85, 95, 0, 0], representing temperature, load rate, and coordinates. After graph neural network calculation, nodes 1, 2, and 5 are marked as risk nodes with features exceeding the threshold, and the intersection of lines A-B and B-C is predicted as the congestion path.

[0084] Step 104: Based on the congestion path prediction result, calculate the tradable capacity margin, and generate a congestion surcharge item in the smart contract according to the tradable capacity margin.

[0085] In step 104, the tradable capacity margin represents the remaining power capacity available for trading on the line, which is equal to the rated capacity minus the current actual load. The congestion surcharge item represents an additional fee clause set in the smart contract, used to regulate the trading behavior of the congested line.

[0086] In the embodiments of the present application, specific line sections are located in the predicted congestion path, and the rated transmission capacity and current actual load data of these lines are obtained. The remaining available capacity of the line is calculated as the tradable capacity margin. According to the comparison result of the margin and the preset threshold, the surcharge coefficient is determined, which increases with the decrease of the margin. Finally, the surcharge clause containing the coefficient is created in the smart contract.

[0087] For example, the predicted congestion path involves lines A-B and B-C. Line A-B has a rated capacity of 500 MW, a current load of 480 MW, and a remaining capacity of 20 MW. When the preset threshold is 30 MW, the additional fee coefficient is calculated as (30-20) / 30=0.33. The smart contract automatically generates a clause: a 33% additional fee is charged for transactions passing through this path.

[0088] Step 105: Guide the power transaction parties to select a non-congestion path in the power grid to complete the power transaction matching through the congestion additional fee item.

[0089] In step 105, the power transaction parties refer to the power supply side (such as power plants, new energy power stations, etc.) and the power demand side (such as power distribution network companies, large industrial users, etc.), which conduct power transaction matching in the power grid environment with the risk of power transmission congestion through the smart contract clauses. The non-congestion path means the power transmission line that is not predicted to be congested. The transaction matching means the process of reaching a transaction agreement between the buyer and the seller.

[0090] In the embodiments of the present application, both the congestion path and the non-congestion path are displayed on the transaction interface, the former price includes the additional fee, and the latter maintains the benchmark price. When the transaction party selects the congestion path, the smart contract automatically recommends an optimized non-congestion path solution. After the transaction party confirms, the transaction is completed at the benchmark price.

[0091] For example, when a power plant and a user conduct a transaction, the system displays: path A-B-C is quoted at 0.665 yuan / degree (including additional fee), and path A-C is quoted at 0.5 yuan / degree. When the user selects A-B-C, the contract recommends A-C, and the user confirms the transaction at 0.5 yuan / degree.

[0092] This method collects real-time power grid operation data, intelligently predicts congestion risks, and automatically guides transaction parties to select the optimal path through price mechanisms, which not only avoids the response lag problem of traditional centralized management, but also ensures fair and transparent transactions through blockchain technology, effectively improving the execution efficiency and security of power transactions.

[0093] To solve the problem of the accuracy of the prediction of the congestion path in the power grid, in some embodiments, step 103: the potential overload risk nodes in the power grid are identified from the fusion heat map through a graph neural network, and the congestion path in the power grid is predicted based on the potential overload risk nodes to generate a congestion path prediction result, including:

[0094] Step 201: Take each temperature monitoring point in the fusion heat map as a graph node.

[0095] In step 201, the temperature monitoring point data set after the spatial coordinate mapping of the temperature monitoring point in the fusion heat map and the fusion of the load rate data is completed, at this time each monitoring point contains both the original temperature value, and the spatial coordinate and load rate data.

[0096] In the embodiment of the present application, the data of all monitoring points is extracted from the fusion heat map, and each monitoring point is converted into a node in the graph structure, which carries the key features of the line operation state.

[0097] Step 202: According to the line connection relationship in the power grid topology data, an adjacency matrix representing the connection relationship between the graph nodes is constructed.

[0098] In step 202, the adjacency matrix "in this method refers to a two-dimensional matrix representing the physical connection relationship between the graph nodes (temperature monitoring points) in the power grid, and the adjacency judgment standard is: when the transmission lines where the two temperature monitoring points are located are directly connected in the power grid topology structure, the corresponding matrix element value is 1 (indicating adjacency), otherwise it is 0 (indicating non-adjacency), the matrix contains the connection state information between all monitoring points in the power grid, and the data source is the line connection relationship mapped from the power grid topology data collected in claim 1.

[0099] In the embodiment of the present application, according to the power grid topology data, it is determined which monitoring points are located on the same line or line connection, and a complete node connection relationship matrix is constructed, providing a structural basis for subsequent graph neural network analysis.

[0100] Step 203: The temperature value, line load rate data and spatial coordinate of each graph node are encoded into the feature vector of the graph node.

[0101] In step 203, the feature vector is a mathematical expression combining the multi-dimensional feature data of the node, including the temperature value, load rate data and spatial coordinate.

[0102] In the embodiment of the present application, the three types of data of each monitoring point are standardized and combined into a feature vector, so that the graph neural network can consider the line operation state and spatial position relationship at the same time.

[0103] Step 204: Based on the adjacency matrix, the feature vector is updated through the neighborhood aggregation operation of the graph neural network, and when the updated feature vector meets the preset overload judgment condition, the corresponding graph node is marked as a potential overload risk node.

[0104] In step 204, the neighborhood aggregation operation is the core calculation process of the graph neural network, which updates the characteristics of the node by absorbing the feature information of adjacent nodes. The preset overload determination condition refers to a double standard for determining whether the graph node is in an overload state, specifically including a temperature determination condition and a load rate determination condition. The temperature determination condition requires that the aggregated temperature feature of the node exceeds the maximum working temperature allowed by the line material, and the load rate determination condition requires that the aggregated load rate feature of the node exceeds the upper limit of the load rate specified in the safe operation of the power grid. Only the nodes that meet both conditions will be marked as potential overload risk nodes.

[0105] In the embodiments of the present application, each node finds connected nodes according to the adjacency matrix, and the features of these nodes are weighted and fused according to the relationship between line impedance and capacity to generate a new feature vector. When the temperature and load rate in the new feature exceed the safety threshold, it is marked as a risk node.

[0106] Step 205: According to the spatial distribution characteristics of all potential overload risk nodes, the blocked path in the power grid is predicted, and a blocked path prediction result is generated.

[0107] In step 205, the spatial distribution characteristics are the position relationship data of the risk nodes in the power grid obtained after analysis by the graph neural network, which is derived from the spatial coordinate information and line connection relationship of the marked nodes. This feature reflects the aggregation and distribution of the overload risk points in the power grid, and is used to identify the continuous line sections that may form blockage, specifically manifested as a potential blocked area formed by multiple risk nodes that are adjacent in space or located on the same line.

[0108] In the embodiments of the present application, the position relationship of all marked risk nodes in the power grid is analyzed, and the risk nodes adjacent in space or located on the same line are connected to form a complete blocked path prediction.

[0109] The following is a specific example:

[0110] In a certain regional power grid, the system first obtains the connection relationship of lines A-B, A-C and B-C, and sets 6 monitoring points on each line to collect temperature data. The temperature of the middle monitoring point of line A-B is 85 degrees, and the temperature of the end monitoring point of line B-C is 83 degrees. Based on historical data, the current load rate of line A-B is predicted to be 95%, the load rate of line A-C is 90%, and the load rate of line B-C is 93%. The load rate and temperature data are combined and calculated according to a weight of 6:4, for example, the risk value of the middle monitoring point of line A-B is 95x0.6+85x0.4=91, and a fused heat map is generated to show that the middle monitoring point of line A-B is a red high-risk area. The 6 monitoring points are set as graph nodes, and a 6x6 adjacency matrix is constructed to represent the connection relationship, wherein monitoring point 1 (line A-B starting point coordinate 0,0) is connected to monitoring point 2 (line A-B end point) and monitoring point 3 (line A-C starting point). The feature vector of node 1 is [85, 95, 0, 0] representing temperature, load rate and coordinate. Through graph neural network calculation, the feature update values of nodes 1, 2 and 5 exceed the preset threshold (temperature greater than 80 degrees and load rate greater than 85%), which are marked as risk nodes. These nodes are located on lines A-B and B-C, so it is predicted that the intersection of the two lines is a blocked path.

[0111] In the embodiments of the present application, the method intelligently analyzes power grid operation data through a graph neural network, accurately identifies potential overload risk and predicts a blocked path, provides a reliable basis for power trading, and effectively improves the safety and execution efficiency of trading.

[0112] To solve the problem of the accuracy of power grid overload risk node identification, in some embodiments, step 204: based on the adjacency matrix, the feature vector is updated through the neighborhood aggregation operation of the graph neural network, and when the updated feature vector meets the preset overload judgment condition, the corresponding graph node is marked as a potential overload risk node, including:

[0113] Step 301: for each graph node, in turn as the current graph node, the following process is performed: extracting adjacent graph nodes directly connected to the current graph node from the adjacency matrix to form a set of adjacent graph nodes.

[0114] In step 301, direct connection refers to the node relationship directly connected by physical power transmission lines in the power grid topology, that is, there is a single line connection between two nodes without passing through other transit nodes, and this connection relationship is clearly defined by the adjacency matrix in the power grid topology data. The set of adjacent graph nodes refers to the combination of other monitoring points directly connected to the current monitoring point, and these monitoring points are physically connected through power transmission lines.

[0115] In the embodiments of the present application, the system finds all other monitoring points connected to the current monitoring point from the adjacency matrix, and groups these points into the same set for subsequent analysis.

[0116] Step 302: Obtain the temperature value and line load rate data of all adjacent graph nodes in the set of adjacent graph nodes to screen the corresponding data of the set of adjacent graph nodes.

[0117] In step 302, the temperature value refers to the conductor surface temperature data measured in real time by the temperature sensor installed on the transmission line, which directly reflects the heating condition of the line under the current operating state and is one of the important indicators for judging whether the line is overloaded. The line load rate data refers to the ratio of the actual power load currently transmitted by the line to its maximum carrying capacity, indicating the utilization level of the line. This data is calculated based on historical operation data by a load rate prediction model. The corresponding data refers to specific parameters required for aggregated calculation of the current node, specifically including the temperature monitoring value and line load rate data of each adjacent node. These data are comparable parameters of the same type and dimension as the temperature and load rate data of the current node.

[0118] In the embodiments of the present application, the latest temperature measurement value and predicted load rate data of each monitoring point in the set are retrieved from the real-time database of the power grid to provide input for subsequent calculation.

[0119] Step 303: Perform weighted average calculation on the temperature value and line load rate data of the current graph node and the corresponding data of the set of adjacent graph nodes respectively to generate aggregated temperature features and aggregated load rate features.

[0120] In step 303, the weighted average calculation refers to a differentiated data processing method considering the physical characteristics of the line, with the temperature weight being the inverse of the line impedance and the load rate weight being the capacity proportion of the line. The aggregated temperature feature is a regional representative temperature value calculated by considering the temperature data of the current node and its adjacent nodes, obtained by weighted average calculation, reflecting the overall temperature condition of the line segment where the node is located. The aggregated load rate feature is a regional load level indicator calculated by fusing the load rate data of the current node and its adjacent nodes, calculated by capacity proportion weighting, representing the comprehensive load condition of the line segment where the node is located.

[0121] In the embodiments of the present application, the temperature and load rate of the current monitoring point and adjacent monitoring points are weighted calculated respectively, where the temperature weight is equal to 1 divided by the line impedance value, and the load rate weight is equal to the line capacity divided by the total capacity of adjacent lines. The aggregated features are obtained by weighted summation and then divided by the total weight.

[0122] Step 304: Fuse the aggregated temperature features and the aggregated load rate features into the feature vector of the graph node to form an updated feature vector.

[0123] In step 304, the updated feature vector refers to new feature data fused with adjacent node information, including an aggregated temperature feature and an aggregated load rate feature.

[0124] In the embodiments of the present application, the calculated aggregated temperature value and the aggregated load rate value replace the corresponding values in the original feature vector to form a new feature reflecting the overall state of the region.

[0125] Step 305: When the updated feature vector simultaneously satisfies the aggregated temperature feature being greater than a preset temperature threshold and the aggregated load rate feature being greater than a preset load rate threshold, mark the current graph node as a potential overload risk node.

[0126] In step 305, the preset temperature threshold and the preset load rate threshold are critical values set according to power grid safety standards for judging whether a node is in a dangerous state.

[0127] In the embodiments of the present application, when the aggregated temperature in the updated feature vector exceeds the upper limit of the material temperature resistance and the aggregated load rate exceeds the upper limit of the line carrying capacity, the monitoring point is marked as a potential overload risk point.

[0128] The following is a specific example:

[0129] In a certain regional power grid, when the system performs overload risk assessment on the monitoring point 1 of the line A-B, first extract the monitoring points 2 and 3 directly connected to it from the adjacency matrix to form a set of adjacent nodes. The temperature value of monitoring point 2 is 82 degrees and the load rate is 88%, and the temperature value of monitoring point 3 is 78 degrees and the load rate is 85%. In temperature weighted calculation, the weight of monitoring point 2 is taken as the reciprocal of the impedance of line A-B, 1 / 0.3=3.33, the weight of monitoring point 3 is taken as the reciprocal of the impedance of line A-C, 1 / 0.2=5, and the weight of the current node is 1. The aggregated temperature feature is calculated as 85x1+82x3.33+78x5 divided by 1+3.33+5, which is equal to 81.4 degrees. In load rate weighted calculation, the weight of monitoring point 2 is taken as the capacity proportion of line A-B, 500 / 800=0.625, the weight of monitoring point 3 is taken as the capacity proportion of line A-C, 300 / 800=0.375, and the weight of the current node is 1. The aggregated load rate feature is calculated as 95x1+88x0.625+85x0.375 divided by 1+0.625+0.375, which is equal to 90.2%. Update 81.4 degrees and 90.2% to the feature vector of node 1. When the preset temperature threshold is 80 degrees and the load rate threshold is 85%, since 81.4 is greater than 80 and 90.2 is greater than 85, monitoring point 1 is marked as a potential overload risk node. After processing other nodes in the same way, monitoring points 1, 2 and 5 are marked as risk nodes, and the intersection of lines A-B and B-C is finally determined as the blocked path according to the location distribution of these nodes.

[0130] In the embodiment of the present application, the method accurately identifies the overload risk area in the power grid by considering the weighted calculation of the line physical characteristics and the fusion of the neighborhood information, provides a reliable basis for the congestion path prediction, and effectively improves the power grid safety warning capability.

[0131] To solve the problem of the accuracy of the power grid risk node feature aggregation, in some embodiments, step 303: the temperature value of the current graph node and the line load rate data are respectively weighted and averaged with the corresponding data of the adjacent graph node set to generate an aggregated temperature feature and an aggregated load rate feature, comprising:

[0132] Step 401: Obtain the line impedance parameters between the current graph node and each adjacent graph node, and the rated transmission capacity of the line on which each adjacent graph node is located.

[0133] In step 401, the line impedance parameter refers to the resistance encountered by the current when passing through the line, and the numerical value is equal to the resistance value of the unit length line, reflecting the electrical characteristics of the line. The rated transmission capacity of the line on which each adjacent graph node is located refers to the maximum safe transmission power allowed by the line design.

[0134] In the embodiment of the present application, the impedance data and capacity data of the line between the current node and the adjacent node are called from the power grid basic parameter library, providing a basis for subsequent weight calculation.

[0135] Step 402: Calculate the temperature weight value of each adjacent graph node based on the line impedance parameter.

[0136] In step 402, the temperature weight value is a weight coefficient calculated according to the line impedance parameter, and the greater the impedance of the line, the smaller the weight.

[0137] In the embodiment of the present application, for each adjacent node, the impedance parameter of the line on which it is located is taken to calculate the reciprocal of the impedance value as the temperature weight, and the line with smaller impedance has greater impact on temperature and higher weight.

[0138] Step 403: Weighted sum the temperature value of the current graph node and the temperature values of all adjacent graph nodes according to the temperature weight value, divide the first weighted sum result by the first weight sum, and generate an aggregated temperature feature.

[0139] In step 403, the first weighted sum result refers to the sum of the temperature value of the current graph node and the temperature values of all its adjacent graph nodes weighted by temperature weight values, wherein the current node temperature value is multiplied by the default weight 1, and the adjacent node temperature values are multiplied by the corresponding line impedance inverse weight, reflecting the regional temperature sum considering the influence of line impedance. The first weight sum refers to the sum of all weight values participating in temperature weighted calculation, including the default weight 1 of the current node and the temperature weight (line impedance inverse) of each adjacent node, which is used for normalization processing of the weighted sum result to obtain the aggregated temperature feature.

[0140] In the embodiments of the present application, the temperature value of the current node is multiplied by the default weight 1, and the temperature values of the adjacent nodes are multiplied by the corresponding temperature weight, and then the sum is divided by the sum of all weights, to obtain the representative temperature value of the region considering the influence of line impedance.

[0141] Step 404: Based on the rated transmission capacity, calculate the load weight value of each adjacent graph node.

[0142] In step 404, the load weight value is a weight coefficient calculated according to the line rated capacity, and the weight of the line with larger capacity is higher.

[0143] In the embodiments of the present application, the proportion of the capacity of each adjacent node line in the total capacity of all adjacent lines is calculated as the load weight of the node, and the line with larger capacity has greater impact on load.

[0144] Step 405: Weighted sum the line load rate data of the current graph node and the line load rate data of all adjacent graph nodes according to the load weight value, divide the second weighted sum result by the second weight sum, and generate the aggregated load rate feature.

[0145] In step 405, the second weighted sum result refers to the sum of the load rate data of the current graph node and the load rate data of all its adjacent graph nodes weighted by the load weight value, wherein the current node load rate is multiplied by the default weight 1, and the adjacent node load rate is multiplied by the corresponding line capacity proportion weight, reflecting the regional load rate sum considering the difference in line capacity. The second weight sum refers to the sum of all weight values participating in load rate weighted calculation, including the default weight 1 of the current node and the load weight (line capacity proportion) of each adjacent node, which is used for normalization processing of the weighted sum result to obtain the aggregated load rate feature.

[0146] In the embodiments of the present application, the load rate of the current node is multiplied by the default weight 1, and the load rates of the adjacent nodes are multiplied by the corresponding load weight, and then the sum is divided by the sum of all weights, to obtain the representative load rate of the region considering the difference in line capacity.

[0147] The following is a specific example:

[0148] In a certain regional power grid, when the system processes the monitoring point 5 of line B-C, first, the line parameters between the node and adjacent nodes 4 and 6 are obtained, wherein the impedance of line A-C connected with node 4 is 0.2 ohm with a rated capacity of 300 MW, and the impedance of line B-C connected with node 6 and node 5 is 0.25 ohm with a rated capacity of 400 MW. When calculating the temperature weight value, the weight of node 4 is 1 divided by 0.2, equaling to 5, the weight of node 6 is 1 divided by 0.25, equaling to 4, and the weight of the current node 5 is 1 by default, and the first weight sum is 1 plus 5 plus 4, equaling to 10. The temperature weighted sum calculation is 83 times 1 plus 80 times 5 plus 81 times 4, equaling to 83 plus 400 plus 324, equaling to 807, and the aggregated temperature feature is 807 divided by 10, equaling to 80.7 degrees. When calculating the load weight value, the weight of node 4 is 300 divided by 700, equaling to 0.4286, the weight of node 6 is 400 divided by 700, equaling to 0.5714, and the weight of the current node 5 is 1 by default, and the second weight sum is 1 plus 0.4286 plus 0.5714, equaling to 2. The load rate weighted sum calculation is 87 times 1 plus 82 times 0.4286 plus 86 times 0.5714, equaling to 87 plus 35.1052 plus 49.1404, equaling to 171.2456, and the aggregated load rate feature is 171.2456 divided by 2, equaling to 85.6228%.

[0149] In the embodiments of the present application, the method makes the generated aggregated features more accurately reflect the real operating state of the regional power grid by considering the differential weighting calculation of the line physical characteristics, provides a reliable data basis for overload risk identification, and effectively improves the accuracy of congestion prediction.

[0150] In order to solve the demand of power grid operating state visualization analysis, in some embodiments, step 102: based on the power grid topology data and the historical congestion record, a line load rate data is generated by combining a load rate prediction model, and a fusion heat map is generated based on the line load rate data and the line temperature distribution data, including:

[0151] Step 501: mapping the line connection relationship in the power grid topology data into spatial coordinates.

[0152] In step 501, the line connection relationship refers to the physical connection mode and network structure relationship between each power transmission line, substation and power generation node in the power grid, which is derived from the architectural design drawings of the power grid or the digital topology information of the power grid operation management system. The spatial coordinates refer to the position information of the line connection relationship in the power grid in the plane coordinate system, which is expressed by numerical values to represent the specific position of the line in the power grid.

[0153] In the embodiments of the present application, the entire power grid structure is mapped into a two-dimensional coordinate system according to the start and end point position information of the lines, so that each line has a corresponding coordinate range.

[0154] Step 502: input the load peak data in the historical congestion record into a load rate prediction model, and output line load rate data of each line section.

[0155] In step 502, the load peak data refers to the highest load rate data of the transmission line when congestion occurs in the past operation of the power grid, which is derived from the long-term accumulated line load monitoring history database of the power grid dispatching system.

[0156] In the embodiments of the present application, the maximum load data in the historical record is input into the trained prediction model, and the model outputs the predicted value of the load rate of each line section after analyzing the historical change rule.

[0157] Step 503: associate the line load rate data with the spatial coordinates to form a load rate distribution map.

[0158] In step 503, the load rate distribution map refers to a visual chart formed by marking the load rate values of each line to the corresponding spatial position.

[0159] In the embodiments of the present application, according to the position range of the line in the coordinate system, the load rate value obtained in step 502 is filled into the corresponding position to form a distribution map representing the load level by color depth.

[0160] Step 504: extract the position and temperature value of the temperature monitoring point from the line temperature distribution data.

[0161] In step 504, the temperature monitoring point refers to the specific physical point where the temperature sensor installed on the power grid line is located, and these monitoring points continuously collect line temperature data to form the line temperature distribution data. The position of the temperature monitoring point refers to the specific coordinates of the sensors installed on the transmission line, and the temperature value is the real-time measurement of the conductor surface temperature reading of these sensors.

[0162] In the embodiments of the present application, the installation position information and the latest temperature measurement data of all sensors are extracted from the temperature monitoring system.

[0163] Step 505: spatially superimpose the load rate distribution map and the position of the temperature monitoring point.

[0164] In step 505, the spatial superimposition processing refers to the process of matching and aligning the load rate distribution map and the temperature monitoring point position information in the same coordinate system.

[0165] In the embodiment of the present application, the coordinate information of the temperature monitoring points is superimposed on the load rate distribution map to ensure that the spatial positions of the two are accurately corresponding.

[0166] Step 506: In the spatial distribution map formed by superimposition, the line load rate data and the temperature value at the same position are weighted and fused to generate a fused heat map.

[0167] In step 506, the weighted fusion refers to a method of merging and calculating the load rate and temperature data at the same position according to a set proportion.

[0168] In the embodiment of the present application, the load rate value and the temperature value at the position of each temperature monitoring point are calculated according to a weight proportion of 6:4 to obtain a characteristic value that comprehensively reflects the operating state of the line.

[0169] The following is a specific example:

[0170] In a certain regional power grid, the system first obtains the connection relationship of lines A-B, A-C and B-C, sets the starting point of line A-B as the coordinate origin (0, 0) and the terminal point as (150, 0); the terminal point of line A-C is set as (100, 100); the connection points B (150, 0) and C (100, 100) of line B-C. 12 overload records in the summer peak period of the past year are called, and it is obtained by analyzing the load rate prediction model that the current load rate of line A-B is 95%, the load rate of line A-C is 90%, and the load rate of line B-C is 93%, and these values are marked on the corresponding line coordinate positions to form a load rate distribution map. At the same time, the real-time data of 6 temperature monitoring points are obtained, among which the temperature of the middle monitoring point of line A-B at coordinate (75, 0) is 85 degrees, and the temperature of the end monitoring point of line B-C at coordinate (125, 50) is 83 degrees. After superimposing the load rate distribution map and the temperature monitoring point position, the load rate 95% and the temperature 85 degrees at the position (75, 0) are calculated according to the weight of 6:4 to obtain the risk value of this point = 95x0.6+85x0.4=91, and the load rate 93% and the temperature 83 degrees at the position (125, 50) are calculated to obtain the risk value = 93x0.6+83x0.4=89. After processing all the monitoring points, a complete fused heat map is generated, in which the middle section of line A-B is displayed as deep red, and the end of line B-C is displayed as light red, directly showing the risk level of different line sections.

[0171] In the embodiment of the present application, the method combines the power grid load state and temperature information organically through spatial mapping and data fusion technology to generate a heat map that directly reflects the operating risk of the line, provides a reliable visual basis for subsequent congestion analysis, and effectively improves the comprehensiveness and accuracy of power grid state monitoring.

[0172] To solve the pricing problem of the congestion path in the electricity transaction, in some embodiments, step 104: based on the congestion path prediction result, the tradable capacity margin is calculated, and the congestion surcharge item is generated in the smart contract according to the tradable capacity margin, including:

[0173] Step 601: locate the congestion line section in the congestion path prediction result.

[0174] In step 601, the congestion line section refers to the part of the transmission line that may be overloaded predicted by the foregoing analysis, which is specifically manifested as a continuous line section marked as high risk.

[0175] In the embodiments of the present application, according to the distribution of the risk nodes, the line section connecting multiple high-risk nodes in the power grid is found as the congestion line section.

[0176] Step 602: obtain the rated transmission capacity and actual load data of the congestion line section.

[0177] In step 602, the rated transmission capacity refers to the maximum safe transmission power allowed by the line design. The actual load data refers to the size of the current actual load carried by the line.

[0178] In the embodiments of the present application, the capacity upper limit value of the congestion line is queried from the power grid basic parameter library, and the current load data provided by the real-time monitoring system is obtained.

[0179] Step 603: based on the rated transmission capacity and the actual load data, the remaining available capacity of the congestion line section is calculated, and the remaining available capacity is taken as the tradable capacity margin.

[0180] In step 603, the remaining available capacity refers to the additional power load that the line can still carry, which is equal to the rated capacity minus the actual load.

[0181] In the embodiments of the present application, for each congestion line section, the rated capacity value is subtracted from the current actual load value to obtain how much additional power transaction the line section can still carry.

[0182] Step 604: according to the comparison relationship between the tradable capacity margin and the preset capacity threshold, determine the surcharge coefficient.

[0183] In step 604, the comparison relationship refers to comparing the remaining available capacity of the line (the tradable capacity margin) with the minimum allowed remaining capacity value (the preset capacity threshold) set by the safe operation of the power grid. When the margin is lower than the threshold, the surcharge is triggered, and the specific relationship is that the closer the margin is to the threshold, the larger the surcharge coefficient generated, forming an inverse correlation relationship. The surcharge coefficient is a fee adjustment ratio calculated according to the gap between the remaining capacity of the line and the safety threshold.

[0184] In the embodiment of the present application, the line residual capacity is compared with the preset safety threshold, the greater the gap, the higher the coefficient, and the specific coefficient value is calculated by the formula (threshold - residual capacity) / threshold.

[0185] Step 605: In the smart contract, create a congestion additional fee item containing the additional fee coefficient.

[0186] In the embodiment of the present application, a contract clause containing line identification, additional fee coefficient and effective time and the like information is created on the blockchain and automatically pushed to the relevant transaction party. The specific implementation process is: in the Ethereum smart contract, define a congestion additional fee structure (containing line ID, additional fee coefficient, effective timestamp), when the capacity margin calculation is completed, call the addCongestionFee function of the contract, write the line segment identifier, the real-time calculated additional fee coefficient and the block time into the structure, and broadcast to all transaction nodes through the event log. For example, the tradable capacity margin of A-B line in a certain regional power grid is reduced to 30% of the preset threshold, the system calculates the additional fee coefficient 0.5, and the smart contract automatically generates the congestion additional fee item containing the coefficient, resulting in a 50% increase in the transaction price of the A-B path, while the adjacent A-C-B path remains at the benchmark price due to sufficient margin, prompting the transaction party to switch to the non-congestion path to complete the matching.

[0187] The following is a specific example:

[0188] In a certain regional power grid, the system predicts that the intersection of lines A-B and B-C is a congestion area according to the foregoing analysis, and first determines the middle section of line A-B as the specific congestion line section. It is queried from the power grid parameter library that the rated transmission capacity of this line section is 500 megawatts, and the current actual load is obtained from the real-time monitoring system as 480 megawatts. The remaining available capacity is calculated as the rated capacity minus the actual load, i.e. 500 minus 480 equals 20 megawatts, which is taken as the tradable capacity margin. The system's preset safety capacity threshold is 30 megawatts, and the additional fee coefficient is calculated as (threshold minus margin) divided by threshold, i.e. (30 minus 20) divided by 30 equals 0.33. The smart contract platform automatically creates a transaction clause, which stipulates that any power transaction passing through the congestion line section needs to increase the additional fee by 33% based on the benchmark price. For example, when a power plant and a user conduct a transaction, the system displays two optional paths: the price of the path through the congestion area A-B-C is the benchmark price 0.5 yuan per degree plus the additional fee 0.165 yuan per degree, a total of 0.665 yuan per degree, while the A-C path bypasses the non-congestion area and maintains the benchmark price of 0.5 yuan per degree. When the user selects the A-B-C path, the smart contract automatically prompts the better solution, and the user confirms to finally complete the transaction through the A-C path at a price of 0.5 yuan per degree.

[0189] In the embodiment of the present application, the method realizes intelligent adjustment of the transaction cost of the blocked section by quantitatively analyzing the residual capacity of the line, guarantees the safe operation of the power grid, optimizes the allocation of power resources through the price mechanism, and effectively improves the fairness and economy of power trading.

[0190] To solve the optimization problem of power trading path selection, in some embodiments, step 105: the blocked additional fee item is used to guide the power trading parties to select a non-blocked path in the power grid to complete power trading matching, including:

[0191] Step 701: In the transaction interface of the smart contract, a first transaction option allowing selection of a blocked path and a second transaction option allowing selection of a non-blocked path are displayed side by side, wherein the first transaction option adopts a premium offer, and the second transaction option adopts a benchmark electricity price offer.

[0192] In step 701, the first transaction option refers to a transaction scheme allowing selection of a blocked path, and the offer contains an additional fee calculated according to the blocking degree. The second transaction option refers to a transaction scheme allowing selection of a non-blocked path, and the benchmark electricity price of the power grid is maintained without additional premium.

[0193] In the embodiment of the present application, the two path options and their corresponding offers are displayed in the transaction interface at the same time, providing clear selection for the transaction parties.

[0194] Step 702: When it is monitored that the power trading parties select the second transaction option, the power trading contract of the corresponding non-blocked path is immediately executed.

[0195] In step 702, immediately executing refers to when the transaction parties directly select a non-blocked path, the system automatically completes the contract signing and transaction confirmation process quickly according to the benchmark electricity price.

[0196] In the embodiment of the present application, through the automatic execution function of the smart contract, an electronic contract with legal effect is generated immediately after the transaction party selects the second option, without manual intervention.

[0197] Step 703: When it is monitored that the power trading parties select the first transaction option, the path optimization rule of the smart contract is automatically triggered to generate an optimized transaction scheme containing a non-blocked path and a corresponding benchmark electricity price offer.

[0198] In step 703, the path optimization rule refers to a smart algorithm that automatically finds and recommends a better alternative path when the transaction party selects a blocked path.

[0199] In the embodiment of the present application, by analyzing the real-time state of the power grid, the optimal path meeting the transaction demand is selected from all available non-blocked paths, and a new transaction scheme is automatically generated for user confirmation.

[0200] Step 704: Based on the confirmation instructions of the power transaction parties on the optimized transaction scheme, complete the power transaction matching.

[0201] In step 704, the confirmation instruction refers to the final confirmation operation of the transaction parties on the system recommended optimization scheme.

[0202] In the embodiments of the present application, the optimized transaction scheme is pushed to the transaction parties, and after the parties confirm and agree, the system completes the final contract signing and transaction execution according to the new scheme.

[0203] The following is a specific example:

[0204] In a certain regional power grid power transaction scenario, when power plant A and user B conduct transactions through the intelligent contract platform, the system interface displays two optional path schemes: the first one is the path through the predicted blocked area A-B-C. Since this path contains a blocked line segment that needs to be charged an additional fee of 33%, its electricity price is the benchmark price of 0.5 yuan per degree plus the additional fee of 0.165 yuan per degree, totaling 0.665 yuan per degree. The second one is the path that bypasses the non-blocked line A-C, maintaining the benchmark electricity price of 0.5 yuan per degree. When user B directly selects the second non-blocked path scheme, the system immediately generates and executes a transaction contract at a price of 0.5 yuan per degree. If user B selects the first blocked path scheme, the intelligent contract automatically triggers the path optimization process: first, it detects that the line A-C has a current load rate of 90% and a remaining capacity of 30 megawatts, which can meet the transaction demand; then it generates an optimization scheme suggesting to take the A-C path and maintain the benchmark electricity price of 0.5 yuan per degree; after user B confirms to accept the optimization scheme, the system finally completes the transaction matching through the A-C path at a price of 0.5 yuan per degree.

[0205] In the embodiments of the present application, this method, through double path selection and intelligent optimization mechanism, not only respects the choice of the transaction parties, but also guides the optimal allocation of resources through price leverage and intelligent recommendation, realizing the double improvement of power transaction efficiency and safety under the premise of ensuring the safe operation of the power grid.

[0206] Figure 2 The structure diagram of an intelligent contract-based power transaction matching system provided in the embodiments of the present application is shown in FIG. 1, which includes: Figure 2

[0207] The collection template 21 is used to collect power grid topology data, historical blocking records, and line temperature distribution data.

[0208] ​The generating module 22 is configured to generate line load rate data based on the power grid topology data and the historical congestion records in combination with a load rate prediction model, and generate a fusion heat map based on the line load rate data and the line temperature distribution data.

[0209] The input module 23 is configured to input the fusion heat map into a pre-trained graph neural network, identify potential overload risk nodes in the power grid from the fusion heat map through the graph neural network, predict a congestion path in the power grid based on the potential overload risk nodes, and generate a congestion path prediction result.

[0210] The computing module 24 is configured to calculate a tradable capacity margin based on the congestion path prediction result, and generate a congestion surcharge item in a smart contract according to the tradable capacity margin.

[0211] The selecting module 25 is configured to guide power transaction parties to select a non-congestion path in the power grid through the congestion surcharge item to complete power transaction matching.

[0212] Figure 2 The power transaction matching system based on the smart contract can perform the following functions Figure 1 The power transaction matching method based on the smart contract has the implementation principle and technical effects as described above. The specific manner in which each module, unit of the power transaction matching system based on the smart contract performs operations has been described in detail in the embodiments related to the method, and will not be described in detail here.

[0213] In one possible design, Figure 2 The power transaction matching system based on the smart contract can be implemented as a computing device, such as a server. Figure 3 As shown in the figure, the computing device can include a storage component 31 and a processing component 32.

[0214] The storage component 31 stores one or more computer instructions, wherein the one or more computer instructions are called and executed by the processing component 32.

[0215] The processing component 32 is configured to perform the power transaction matching method based on the smart contract as described above. Figure 1 The power transaction matching method based on the smart contract.

[0216] The processing component 32 can include one or more processors to execute computer instructions to complete all or part of the steps in the above method. Of course, the processing component can also be one or more Application-Specific Integrated Circuits (ASICs), Digital Signal Processors (DSPs), Digital Signal Process Device (DSPD), Programmable Logic Devices (PLDs), Field Programmable Gate Arrays (FPGAs), controllers, microcontrollers, microprocessors or other electronic components, for executing the above method.

[0217] The storage component 31 is configured to store various types of data to support the operation of the terminal. The storage component can be implemented by any type of volatile or non-volatile storage devices or a combination thereof, such as Static Random-Access Memory (SRAM), Electrically Erasable Programmable Read Only Memory (EEPROM), Erasable Programmable Read Only Memory (EPROM), Programmable Read Only Memory (PROM), Read Only Memory (ROM), magnetic storage, flash memory, magnetic disk or optical disk.

[0218] Of course, the computing device can also include other components, such as an input / output interface, a display component, a communication component, etc.

[0219] The input / output interface provides an interface between the processing component and peripheral interface modules, which can be output devices, input devices, etc.

[0220] The communication component is configured to facilitate wired or wireless communication between the computing device and other devices, etc.

[0221] The computing device can be a physical device or an elastic computing host provided by a cloud computing platform, and the computing device can be a cloud server, and the processing component, the storage component, etc. can be basic server resources rented or purchased from the cloud computing platform.

[0222] The embodiment of the application further provides a computer storage medium, which stores a computer program, and the computer program can realize the above method when being executed by a computer. Figure 1 The embodiment of the application further provides a computer storage medium, which stores a computer program, and the computer program can realize the above method when being executed by a computer.

[0223] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the above-described system, device and unit can refer to the corresponding processes in the foregoing method embodiments, and will not be described here.

[0224] The device embodiments described above are only schematic, and the units described as separate components can or can not be physically separate, and the components shown as units can or can not be physical units, that is, they can be located in one place, or can be distributed on multiple network units. Part or all of the modules can be selected according to actual needs to achieve the purpose of the embodiment scheme. Those skilled in the art can understand and implement without creative labor.

[0225] Through the description of the foregoing embodiments, those skilled in the art can clearly understand that each embodiment can be realized by means of software and a necessary general hardware platform, and of course, can also be realized by hardware. Based on such understanding, the foregoing technical solutions can be embodied in the form of a software product, which can be stored in a computer readable storage medium, such as a ROM / RAM, a magnetic disk, an optical disk, etc., and includes a plurality of instructions to make a computer device (which can be a personal computer, a server, or a network device, etc.) execute the methods described in each embodiment or some parts of the embodiments.

[0226] Finally, it should be noted that: the above embodiments are only used to illustrate the technical solutions of the application, and not to limit them; although the application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that: it can still modify the technical solutions recorded in the foregoing embodiments, or make equivalent replacement for some technical features; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the application.

Claims

1. A method for matching electricity transactions based on smart contracts, characterized in that, include: Collect power grid topology data, historical congestion records, and line temperature distribution data; Based on the power grid topology data and the historical congestion records, and combined with the load rate prediction model, line load rate data is generated. Based on the line load rate data and the line temperature distribution data, a fused heat map is generated. The fused heatmap is input into a pre-trained graph neural network. The graph neural network identifies potential overload risk nodes in the power grid from the fused heatmap and predicts congestion paths in the power grid based on the potential overload risk nodes, generating congestion path prediction results. Based on the predicted congestion path, the tradable capacity margin is calculated, and a congestion surcharge item is generated in the smart contract according to the tradable capacity margin. The aforementioned congestion surcharge guides both parties in a power transaction to select a non-congested path in the power grid in order to complete the power transaction matching.

2. The power trading matching method based on smart contracts according to claim 1, characterized in that, The step of identifying potential overload risk nodes in the power grid from the fused heatmap using a graph neural network, and predicting congestion paths in the power grid based on the potential overload risk nodes, and generating congestion path prediction results, includes: Each temperature monitoring point in the fused thermal map is used as a graph node; Based on the line connection relationships in the power grid topology data, an adjacency matrix representing the connection relationships between graph nodes is constructed; The temperature value, line load rate data, and spatial coordinates of each graph node are encoded into a feature vector for the graph node. Based on the adjacency matrix, the feature vector is updated through the neighborhood aggregation operation of the graph neural network. When the updated feature vector meets the preset overload judgment condition, the corresponding graph node is marked as a potential overload risk node. Based on the spatial distribution characteristics of all potential overload risk nodes, the congestion paths in the power grid are predicted, and the congestion path prediction results are generated.

3. The power trading matching method based on smart contracts according to claim 2, characterized in that, The step of updating the feature vector based on the adjacency matrix through neighborhood aggregation operation of graph neural network, and marking the corresponding graph node as a potential overload risk node when the updated feature vector meets the preset overload judgment condition, includes: For each graph node, it is sequentially designated as the current graph node, and the following process is executed: extract the adjacent graph nodes directly connected to the current graph node from the adjacency matrix to form an adjacent graph node set; Obtain the temperature values ​​and line load rate data of all adjacent graph nodes in the adjacent graph node set, so as to filter out the corresponding data of the adjacent graph node set; The temperature value and line load rate data of the current graph node are weighted and averaged with the corresponding data of the adjacent graph node set to generate aggregated temperature features and aggregated load rate features. The polymerization temperature feature and the polymerization loading rate feature are fused into the feature vector of the graph node to form the updated feature vector; When the updated feature vector simultaneously satisfies that the aggregation temperature feature is greater than a preset temperature threshold and the aggregation load rate feature is greater than a preset load rate threshold, the current graph node is marked as a potential overload risk node.

4. The power trading matching method based on smart contracts according to claim 3, characterized in that, The step of calculating a weighted average of the temperature value and line load rate data of the current graph node with the corresponding data of the adjacent graph node set to generate aggregated temperature features and aggregated load rate features includes: Obtain the line impedance parameters between the current graph node and each adjacent graph node, and the rated transmission capacity of the line where each adjacent graph node is located; Based on the line impedance parameters, calculate the temperature weight value of each adjacent graph node; The temperature value of the current graph node is weighted and summed with the temperature values ​​of all adjacent graph nodes according to the temperature weight value. The first weighted summation result is divided by the first weight summation to generate the aggregated temperature feature. Based on the rated transmission capacity, calculate the load weight value of each adjacent graph node; The line load rate data of the current graph node is weighted and summed with the line load rate data of all adjacent graph nodes according to the load weight value. The second weighted summation result is divided by the second weight summation to generate the aggregated load rate feature.

5. The power trading matching method based on smart contracts according to claim 1, characterized in that, The process of generating line load rate data based on the power grid topology data and historical congestion records, combined with a load rate prediction model, and generating a fused heat map based on the line load rate data and the line temperature distribution data includes: Map the line connection relationships in the power grid topology data to spatial coordinates; Input the load peak data from the historical congestion records into the load rate prediction model, and output the line load rate data for each line segment. The line load rate data is correlated with the spatial coordinates to form a load rate distribution map; Extract the location and temperature value of the temperature monitoring point from the temperature distribution data of the line; The load rate distribution map is spatially superimposed with the location of the temperature monitoring point; In the spatial distribution map formed by overlay, the line load rate data at the same location is weighted and fused with the temperature value to generate a fused heat map.

6. The power trading matching method based on smart contracts according to claim 1, characterized in that, The step of calculating the tradable capacity margin based on the congestion path prediction results, and generating a congestion surcharge item in the smart contract according to the tradable capacity margin, includes: Locate the blocked line segment in the blocked path prediction results; Obtain the rated transmission capacity and actual load data of the blocked line segment; Based on the rated transmission capacity and the actual load data, calculate the remaining available capacity of the blocked line segment, and use the remaining available capacity as the tradable capacity margin; The surcharge coefficient is determined based on the comparison between the tradable capacity margin and the preset capacity threshold; In the smart contract, a blocking surcharge item containing the aforementioned surcharge coefficient is created.

7. The power trading matching method based on smart contracts according to claim 1, characterized in that, The process of guiding both parties in a power transaction to select a non-congested path in the power grid through the congestion surcharge to complete the power transaction matching includes: In the smart contract's transaction interface, a first transaction option that allows the selection of a blocking path and a second transaction option that allows the selection of a non-blocking path are displayed side by side, wherein the first transaction option uses a premium quote and the second transaction option uses a base electricity price quote; When it is detected that both parties to the power transaction have selected the second transaction option, the corresponding non-blocking power transaction contract is executed immediately; When it is detected that both parties in the power transaction have selected the first transaction option, the path optimization rules of the smart contract are automatically triggered to generate an optimized transaction plan that includes a non-blocking path and the corresponding benchmark electricity price. Based on the confirmation instructions from both parties to the power transaction regarding the optimized transaction plan, the power transaction is matched.

8. A power trading matching system based on smart contracts, characterized in that, include: Data acquisition templates are used to collect power grid topology data, historical congestion records, and line temperature distribution data. The generation module is used to generate line load rate data based on the power grid topology data and the historical congestion records, combined with the load rate prediction model, and to generate a fused heat map based on the line load rate data and the line temperature distribution data. The input module is used to input the fused heat map into a pre-trained graph neural network, identify potential overload risk nodes in the power grid from the fused heat map through the graph neural network, predict congestion paths in the power grid based on the potential overload risk nodes, and generate congestion path prediction results. The calculation module is used to calculate the tradable capacity margin based on the blocked path prediction results, and generate a blocking surcharge item in the smart contract according to the tradable capacity margin. The selection module is used to guide both parties in a power transaction to choose a non-blocking path in the power grid through the congestion surcharge item in order to complete the power transaction matching.

9. A computing device, characterized in that, It includes a processing component and a storage component; the storage component stores one or more computer instructions; the one or more computer instructions are invoked and executed by the processing component to implement a smart contract-based power trading matching method as described in any one of claims 1 to 7.

10. A computer storage medium, characterized in that, The device contains a computer program that, when executed by a computer, implements a smart contract-based power trading matching method as described in any one of claims 1 to 7.

Citation Information

Patent Citations

  • Method for searching and determining trading channel in three-class power market

    CN101751645A

  • Electricity price zoning method and device, computer equipment and storage medium

    CN110717079A

  • Distributed energy P2P transaction system and method based on blockchain

    CN111833184A

  • Power grid blocking adjusting method

    CN119070350A

  • Node electricity price determination method and device, storage medium and electronic equipment

    CN119477379A