A power grid topology modeling method, computer device, and system based on graph theory

By setting neighborhood ranges of different scales in the topology diagram structure of large power grids, obtaining and analyzing topology vectors, filtering out segmented neighborhoods and building a second topology diagram structure, the problem of poor optimization effect of large power grid topology structure is solved, and efficient grid analysis and processing is achieved.

CN119358182BActive Publication Date: 2025-06-03YICHUN POWER SUPPLY COMPANY OF STATE GRID HEILONGJIANG ELECTRIC POWER COMPANY +1
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202411483282.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-10-23
Publication Date
2025-06-03
Estimated Expiration
2044-10-23

AI Technical Summary

Technical Problem

The prior art has poor optimization effect on the topological structure of large power grids, resulting in a large amount of computing resources still required in topological analysis.

Method used

By setting neighborhood ranges of different scales in the grid topology graph structure, obtaining the topology vectors of nodes at different scales, constructing a sequence of topology vectors, analyzing the similarity between adjacent elements to determine the segmentation points and segmentation effects, filtering out the segmentation neighbors, and building a second topology graph structure under the segmentation neighborhood to determine node classification and grid structure descriptors.

Benefits of technology

It realizes multi-scale information expression of grid topology modeling, reduces the amount of calculation, and ensures the information richness of the model, and improves the analysis and processing efficiency of the smart grid.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119358182B_ABST
    Figure CN119358182B_ABST
Patent Text Reader

Abstract

The present invention relates to the technical field of smart grids, and particularly relates to a power grid topology modeling method, a computer device, and a system based on graph theory. This method obtains the topological vectors of each node in the neighborhood range at different scales in the first topological graph structure of the power grid. In the topological vector sequence, the similarity between adjacent elements is analyzed to determine the neighborhood range corresponding to the segmentation point and the segmentation effect. By statistically analyzing the segmentation points and segmentation effects of all nodes, the segmentation property within each neighborhood range is obtained, and the segmented neighborhoods are screened out. Under each segmented neighborhood, a second topological graph structure is constructed based on the topological vectors of the nodes and the nodes are classified to obtain the node category regions and their power grid structure descriptors. The final power grid topology modeling of the present invention has multi-scale information, and the graph structure at each scale contains large-scale information, reducing the computational complexity of power grid topology analysis while ensuring information richness and improving the analysis and processing efficiency of smart grids.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of smart grids, and particularly to a power grid topology modeling method, a computer device, and a system based on graph theory. Background Art

[0002] In the process of power system simulation and analysis calculation, power grid topology analysis is one of the basic technologies. A topology analysis model is constructed through a power equipment model and a connection relationship model. Graph theory and graph calculation methods can abstract the power grid structure into a graph structure for power grid topology analysis. For example, the patent with the publication number CN113051694B proposes a power grid topology modeling method based on graph theory. This method merges the vertices of line type devices and the connected edges, and establishes a mapping relationship between the switch state and the section connection state for switch type devices, thereby reducing the number of vertices and edges in the graph structure, effectively reducing the calculation amount of power grid topology analysis, and improving the efficiency of power grid analysis. Although the prior art has optimized and simplified the power grid graph structure to a certain extent, for large power grids, the simplified graph structure still contains a large number of nodes and edges, and a large amount of computing resources are still required for topology analysis during topology analysis. That is, the prior art has a poor optimization effect on the topology structure of large power grids. Summary of the Invention

[0003] In order to solve the technical problem that the prior art has a poor optimization effect on the topology structure of large power grids, the purpose of the present invention is to provide a power grid topology modeling method, a computer device, and a system based on graph theory. The specific technical solutions adopted are as follows:

[0004] The present invention proposes a power grid topology modeling method based on graph theory, and the method includes:

[0005] Obtain the first topological graph structure of the power grid; for each node in the initial topological graph structure, obtain the topological vectors of the node within the neighborhood ranges of different scales;

[0006] For each of the nodes, form a topological vector sequence from the topological vectors according to the size of the neighborhood range; obtain an adjacent scale similarity sequence according to the similarity between adjacent elements in the topological vector sequence; determine the segmentation points in the adjacent scale similarity sequence and the segmentation effect in the nodes according to the magnitudes of consecutive elements; count the segmentation points and segmentation effects of all nodes, and obtain the segmentation property of each neighborhood range according to the segmentation effect of each node under the neighborhood range to which the segmentation point belongs, and screen out the segmented neighborhoods according to the segmentation property;

[0007] For each segmented neighborhood, set the node value of each node to the corresponding topological vector to obtain a second topological graph structure; obtain the node category regions in the second topological graph structure; screen the topological vectors in the node category regions to determine the representative topological vector of the node category region and use it as the power grid structure descriptor of the node category region.

[0008] Further, use the Node2Vec method to obtain the topological vectors of the node within the neighborhood ranges of different scales.

[0009] Further, the method for obtaining the adjacent scale similarity sequence includes:

[0010] The topological vector sequence is a sequence sorted from small to large according to the neighborhood range. For each topological vector in the topological vector sequence, take the average value of the cosine similarities between the topological vector and each previous topological vector as the adjacent scale similarity of the corresponding topological vector; the adjacent scale similarities of all topological vectors form the adjacent scale similarity sequence.

[0011] Further, use the otsu multi-threshold segmentation algorithm to obtain the segmentation points in the adjacent scale similarity sequence.

[0012] Further, the method for obtaining the segmentation effect includes:

[0013] In the adjacent scale similarity sequence, take the ratio between the element corresponding to the segmentation point and the minimum value of the previous segmentation segment as the first ratio, and the ratio between the element corresponding to the segmentation point and the maximum value of the previous segmentation segment as the second ratio. Perform a negative correlation mapping and normalization on the mean value of the first ratio and the second ratio to obtain the segmentation effect of the segmentation point.

[0014] Further, the method for obtaining the segmentability includes:

[0015] Take any neighborhood range as the target scale. If the neighborhood range to which the segmentation point of the node belongs is the target scale, then take the node as the target node; accumulate the segmentation effects of the segmentation points of all target nodes at the target scale to obtain the segmentability of the target scale.

[0016] Further, the method for obtaining the node category regions includes:

[0017] In the second topological graph structure, obtain multiple initial node categories according to the similarity of the node values between each node and assign labels to each node according to the initial node categories. Use the SLPA algorithm to update the labels to obtain the final label result. In the final label result, the nodes with the same label and connected to each other form a node category region.

[0018] Further, the method for obtaining the representative topological vector includes:

[0019] In the node category region, calculate the cosine similarity between each topological vector and other topological vectors and accumulate it to obtain the overall similarity of each topological vector, and use the topological vector with the maximum overall similarity as the representative topological vector.

[0020] The present invention also proposes a computer device for power grid topological modeling based on graph theory, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the steps of any one of the power grid topological modeling methods based on graph theory.

[0021] The present invention also proposes a power grid topological modeling system based on graph theory, and the system includes:

[0022] A power grid first topological graph structure acquisition module, configured to obtain the first topological graph structure of the power grid; for each node in the initial topological graph structure, obtain the topological vectors of the node within the neighborhood ranges of different scales;

[0023] A first topological graph analysis module, configured to, for each of the nodes, form a topological vector sequence according to the neighborhood range size; obtain an adjacent scale similarity sequence according to the similarity between adjacent elements in the topological vector sequence; determine the segmentation points in the adjacent scale similarity sequence and the segmentation effect in the nodes according to the magnitudes of consecutive elements; count the segmentation points and segmentation effects of all nodes, and obtain the segmentation property of each neighborhood range according to the segmentation effect of each node under the neighborhood range to which the segmentation point belongs, and screen out the segmented neighborhoods according to the segmentation property;

[0024] A power grid topological modeling module, configured to, for each segmented neighborhood, set the node value of each node to the corresponding topological vector to obtain a second topological graph structure; obtain the node category region in the second topological graph structure; screen the topological vectors in the node category region to determine the representative topological vector of the node category region and use it as the power grid structure descriptor of the node category region.

[0025] The present invention has the following beneficial effects:

[0026] The present invention first sets neighborhood ranges of different scales and obtains topological vectors of nodes in the first topological graph structure within different neighborhood ranges. By setting neighborhood ranges of different scales, the final result can be a multi-scale result. The final power grid topological model has multi-scale information, can adaptively select an appropriate scale for analysis and processing according to the analysis requirements, reduces the computational amount of power grid topological analysis, while ensuring the information richness of the final model and improving the analysis and processing efficiency of the smart grid. Further considering that not every neighborhood range can enable nodes to contain accurate information about the edges in the original power grid. If the neighborhood range is inappropriate, it will be difficult to represent the large-scale information of the original power grid in the final modeling result. Therefore, by analyzing the distribution characteristics of the topological vectors represented by nodes under each neighborhood range, the divisibility of the neighborhood range is obtained, and then the divided neighborhoods are screened out. Based on the corresponding topological vectors in the divided neighborhoods, a second topological graph structure is constructed. By classifying the nodes in the second topological graph structure, the nodes can be further merged, and overall analysis is performed in a node category area through the power grid structure descriptor, so that the final modeling result has larger-scale information and contains the effective information in the original power grid, preventing information distortion. BRIEF DESCRIPTION OF THE DRAWINGS

[0027] In order to more clearly illustrate the technical solutions and advantages in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings required for the description of the embodiments or the prior art. Obviously, the following drawings are only some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other drawings can be obtained based on these drawings.

[0028] Figure 1 It is a flowchart of a power grid topological modeling method based on graph theory provided by an embodiment of the present invention;

[0029] Figure 2 It is a block diagram of the structure of a power grid topological modeling system based on graph theory provided by an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0030] In order to further elaborate on the technical means and effects adopted by the present invention to achieve the intended invention purpose, the following, in combination with the accompanying drawings and preferred embodiments, details the specific implementation manners, structures, features, and effects of a power grid topological modeling method, computer device, and system based on graph theory proposed according to the present invention. In the following description, different "one embodiment" or "another embodiment" do not necessarily refer to the same embodiment. In addition, the specific features, structures, or characteristics in one or more embodiments can be combined in any suitable form.

[0031] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the technical field to which this invention belongs.

[0032] The following specifically describes the specific solutions of a graph - theory - based power grid topology modeling method, computer device, and system provided by the present invention with reference to the accompanying drawings.

[0033] Please refer to Figure 1 , which shows a flowchart of a graph - theory - based power grid topology modeling method provided by an embodiment of the present invention. The method includes:

[0034] Step S1: Obtain the first topological graph structure of the power grid; for each node in the initial topological graph structure, obtain the topological vectors within the neighborhood ranges at different scales.

[0035] The present invention aims at further optimizing the power grid topological graph structure. Therefore, the nodes and edges in the graph structure of the power grid can be constructed based on existing technical means. For example, the method in the patent with publication number CN113051694B is used to construct the first topological graph structure of the power grid. This method is prior art, and only its process is briefly described here:

[0036] (1) Create corresponding nodes in the graph structure for each electrical device, and generate unique identification codes for the nodes and edges.

[0037] (2) For switch - type devices, establish the mapping relationship between the switch state and the terminal connection state.

[0038] (3) For connection nodes, create corresponding edges according to whether they contain busbars or operating poles.

[0039] (4) For line - type devices such as wires and cables, if the degree of a node is 2, then merge the node and the two connected edges into one edge.

[0040] It should be noted that in other embodiments of the present invention, other existing calculations can also be selected to construct the first topological graph structure of the power grid, which will not be elaborated here.

[0041] After determining an effective neighborhood range in the embodiments of the present invention, further classification is performed based on the structural information of the nodes within the neighborhood range, thereby playing a role in optimizing the graph structure. Since there is topological information in the topological structure, the nodes in the first topological graph structure cannot be directly classified and analyzed. It is necessary to make the nodes first contain the information of the surrounding nodes and then perform classification in order to obtain the structural information of a larger scale of the power grid topological structure. Otherwise, it will lead to the loss of information in the final modeling structure. Therefore, in the embodiments of the present invention, first for the nodes in the initial topological graph structure, topological vectors of the nodes within different-scale neighborhood ranges are obtained. The topological vector is a vector constructed based on the connection relationship between the node and other surrounding nodes, and can represent the surrounding structural information of the node under the current neighborhood range.

[0042] In the embodiments of the present invention, the Node2Vec algorithm is used to obtain the topological vector of each node in each neighborhood range. This algorithm is a method for processing graph structures and can transform the graph structure into a vector space. The specific algorithm is a technical means well-known to those skilled in the art and will not be elaborated here.

[0043] It should be noted that the neighborhood range of the node is the neighborhood range determined based on the connection relationship. Taking a node as the analysis node as an example, the other nodes directly connected to the analysis node are the nodes within the first neighborhood range of the analysis node; the nodes directly connected to the nodes within the first neighborhood are the nodes within the second neighborhood range of the analysis node. And so on, the node information within each scale neighborhood range can be obtained. The number of scales of the neighborhood range can be adaptively set according to the scale of the power grid. In the embodiments of the present invention, it is set to analyze ten neighborhood ranges from one to ten.

[0044] Step S2: For each node, form a topological vector sequence according to the neighborhood range size for the topological vectors; obtain an adjacent-scale similarity sequence according to the similarity between adjacent elements in the topological vector sequence; determine the segmentation points in the adjacent-scale similarity sequence and the segmentation effect in the nodes according to the magnitudes of consecutive elements; count the segmentation points and segmentation effects of all nodes, and obtain the segmentation property of each neighborhood range according to the segmentation effect of each node under the neighborhood range to which the segmentation point belongs. Then, select the segmented neighborhood according to the segmentation property.

[0045] Although each node obtains the topological vectors under each neighborhood range in step S1, not every neighborhood range can be used as an analysis scale for analysis. The scale of a neighborhood range can have a good segmentation effect on some nodes, enabling these nodes to obtain effective neighborhood node distribution information under this neighborhood range; however, for some other nodes, this neighborhood range may be too large, resulting in noise in the neighborhood node distribution information of these nodes, or it may be too small, resulting in the neighborhood node distribution information of these nodes not being able to fully represent the surrounding node distribution information of the nodes. Therefore, it is necessary to effectively screen the neighborhood ranges and select a more appropriate neighborhood range for subsequent analysis.

[0046] The embodiment of the present invention takes into account that a useful neighborhood range scale will cause the topological vector to change greatly as the neighborhood range expands. That is, if a neighborhood range scale is an optimal neighborhood range, the topological vectors between neighborhood range scales smaller than this neighborhood range are not very different, and as the neighborhood range expands, scales larger than this neighborhood range are no longer suitable for the nodes, resulting in noise interference in the obtained topological vectors and obvious changes in the obtained topological vectors. Therefore, the embodiment of the present invention analyzes each node, and forms a topological vector sequence according to the size of the neighborhood range for the topological vectors, that is, the topological vectors in the topological vector sequence are sorted in ascending or descending order along the neighborhood range.

[0047] The embodiments of the present invention further analyze based on the topological vector sequence. According to the above relationship between the neighborhood range scale and the change of the topological vector, the segmentation point in the topological vector sequence is the relatively effective neighborhood range corresponding to the node. Therefore, in the embodiments of the present invention, first, an adjacent scale similarity sequence is obtained according to the similarity between adjacent elements in the topological vector sequence. Each element in the adjacent scale similarity sequence is a specific similarity value, which has a more quantifiable effect compared to analyzing the topological vector sequence. Therefore, the segmentation point in the adjacent scale similarity sequence and the segmentation effect of the segmentation point in the node are determined according to the magnitudes of consecutive elements in the adjacent scale similarity sequence. Since the segmentation point is an element in the adjacent scale similarity sequence, and this element corresponds to a neighborhood range in the topological vector sequence, that is, the neighborhood range corresponding to the segmentation point is the relatively effective neighborhood range of the node. However, there are multiple nodes in the first topological graph structure, and the effective neighborhood range cannot be determined only based on a certain node. It is necessary to count the segmentation points and segmentation effects of all nodes. If a certain neighborhood range is the neighborhood range corresponding to the segmentation point in many nodes and the segmentation effect is good, it indicates that the segmentation of this neighborhood range for the overall power grid topological structure is good. Further analysis under this neighborhood range can obtain large-scale power grid information while ensuring that the original information in the power grid is not damaged. Therefore, the embodiments of the present invention further count the segmentation points and segmentation effects of all nodes, obtain the segmentation property of each neighborhood range according to the segmentation effect of each node under the neighborhood range to which the segmentation point belongs, and the segmentation neighborhoods to be analyzed subsequently can be screened according to the segmentation property.

[0048] Preferably, in some implementation manners of the embodiments of the present invention, the method for obtaining the adjacent scale similarity sequence includes:

[0049] The topological vector sequence is a sequence sorted in ascending order according to the neighborhood range. For each topological vector in the topological vector sequence, the average value of the cosine similarities between this topological vector and each previous topological vector is used as the adjacent scale similarity corresponding to this topological vector. It should be noted that the previous topological vector is the vector before this topological vector in the sequence, that is, the neighborhood ranges corresponding to the previous topological vectors are all smaller than the neighborhood range corresponding to this topological vector. By calculating the average value of the cosine similarities between this topological vector and each previous topological vector, the difference between the element corresponding to the segmentation point and other previous elements in the adjacent scale similarity sequence can be effectively amplified, making the subsequent determination of the segmentation point and the determination of the segmentation effect more obvious. The adjacent scale similarities of all topological vectors form the adjacent scale similarity sequence.

[0050] It should be noted that in some implementation manners of the embodiments of the present invention, the order of the topological vector sequences is from large to small according to the neighborhood range. Therefore, it is necessary to analyze the similarity relationship between each topological vector and its subsequent topological vectors, which will not be elaborated here.

[0051] In other implementation manners of the embodiments of the present invention, the cosine similarity between each topological vector in the topological vector sequence and the previous topological vector can also be directly used as an element in the adjacent scale similarity sequence.

[0052] In some implementation manners of the embodiments of the present invention, the Otsu multi-threshold segmentation algorithm is used to obtain the segmentation points in the adjacent scale similarity sequence. The Otsu multi-threshold segmentation algorithm is a well-known technical means for those skilled in the art and will not be elaborated here.

[0053] Preferably, in some implementation manners of the embodiments of the present invention, the method for obtaining the segmentation effect includes:

[0054] In the adjacent scale similarity sequence, the ratio between the element corresponding to the segmentation point and the minimum value of the previous segmentation segment is used as the first ratio, and the ratio between the element corresponding to the segmentation point and the maximum value of the previous segmentation segment is used as the second ratio. For the segmentation point, since it represents the similarity between adjacent elements in the topological vector sequence, the corresponding element value in the adjacent scale similarity sequence should be a relatively small value, and the minimum and maximum values of the previous segmentation segment should be similar and both greater than the element value of the segmentation point. The smaller the first ratio and the second ratio, the smaller the element value of the segmentation point, the lower the adjacent scale similarity, and the better the segmentation effect. Therefore, in the embodiments of the present invention, the mean value of the first ratio and the second ratio is negatively correlated and normalized to obtain the segmentation effect of the segmentation point.

[0055] It should be noted that those skilled in the art can use basic mathematical means to implement the method of negative correlation mapping and normalization. For example, the data is first normalized using the function mapping method to limit the value range between 0 and 1, and then the normalized value is subtracted from the positive integer 1 to obtain the final result. In the embodiments of the present invention, the opposite number of the data is directly used as the power of the exponential function with the natural constant as the base to achieve the effect of negative correlation mapping and normalization.

[0056] Preferably, in the embodiments of the present invention, the method for obtaining the segmentation property includes:

[0057] Any neighborhood range is used as the target scale. If the neighborhood range to which the segmentation point of a node belongs is the target scale, the node is used as the target node; the segmentation effects of the segmentation points of all target nodes at the target scale are accumulated to obtain the segmentation property of the target scale. That is, for the target scale, the more target nodes and the better the segmentation effect, the greater the segmentation property of the target scale.

[0058] In the embodiments of the present invention, based on the divisibility of all neighborhood ranges, range normalization is used to normalize each divisibility. The divisibility threshold is set to 0.6. According to the above logical description, the larger the divisibility, the more effective the neighborhood range. Therefore, the neighborhood ranges with divisibility greater than the divisibility threshold are used as the segmentation neighborhoods.

[0059] Step S3: For each segmentation neighborhood, set the node value of each node to the corresponding topological vector to obtain a second topological graph structure; obtain the node category regions in the second topological graph structure; screen the topological vectors in the node category regions to determine the representative topological vector of the node category region and use it as the power grid structure descriptor of the node category region.

[0060] In step S2, multi-scale segmentation neighborhoods with more effective information in the first topological graph structure of the current power grid are obtained. For each segmentation neighborhood, further structural analysis can be performed and the topological graph can be optimized. For each segmentation neighborhood, set the node value of each node to the topological vector of the node under the segmentation neighborhood to obtain a second topological graph structure. Since the node values of the nodes in the second topological graph structure are the topological vectors under the segmentation neighborhood, and the topological vector represents the node structure information in a local range, for adjacent and structurally similar nodes, the node values in the second topological graph structure should be similar. Therefore, the node category regions in the second topological graph structure can be further obtained, that is, the node category regions are the merged large-scale information. Since the node structure distributions in the node category regions all tend to the same distribution, they can be regarded as a whole for topological analysis. Further considering that the node category regions contain multiple nodes, that is, multiple topological vectors, the topological vectors in the node category regions are screened to determine the representative topological vector of the node category region and use it as the power grid structure descriptor of the node category region. When performing intelligent analysis on the power grid, only the power grid structure descriptor of the node category region needs to be analyzed to effectively analyze the power grid structure, reduce the analysis calculation amount, and improve the power grid intelligent analysis efficiency.

[0061] Similarly, the classification information in the second topological graph structure can be obtained for each segmented neighborhood, completing the power grid topological modeling. After obtaining the final modeling structure, operations such as macroscopic analysis, mesoscopic analysis, microscopic analysis, integrated analysis, and continuous update can be performed on the power grid. Graph structures at different scales help to gradually identify potential fault points and risk areas in the power grid from the whole to the local. Among them, macroscopic analysis includes: dividing the power grid into multiple regions, identifying key nodes and load conditions, analyzing power supply paths, etc.; mesoscopic analysis includes: checking the connections between nodes within the area, considering switch states, evaluating equipment states, etc.; microscopic analysis includes: performing detailed analysis on key nodes, constructing local network topologies, simulating the impact of faults, etc.; integrated analysis includes: integrating the results at all levels, evaluating risks, and proposing preventive measures, etc.; continuous update includes: real-time monitoring of the power grid state, updating the model, and dynamically adjusting the analysis, etc.

[0062] Preferably, in the embodiments of the present invention, the method for obtaining the node category area includes:

[0063] In the second topological graph structure, multiple initial node categories are obtained according to the similarity of node values between each node, and each node is labeled according to the initial node categories. The SLPA algorithm is used to update the labels to obtain the final label result. In the final label result, nodes with the same label and connected to each other form a node category area.

[0064] In the embodiments of the present invention, the initial node categories can be directly implemented by calculating the cosine similarity of node values between nodes and using the density clustering method. The cosine similarity and density clustering are well-known technical means in the art and will not be elaborated here.

[0065] It should be noted that the SLPA algorithm is a well-known method for updating category labels in a graph structure in the art. The general process is briefly described here:

[0066] (1) Label different initial node categories. According to the number n of node categories, each category is respectively assigned a label from 1 to n, and at the same time, the node value of each node is replaced with the label value of the category to which the node belongs.

[0067] (2) First, calculate the number of nodes with different node labels among the directly connected nodes of each node, denoted as the number of different-sign nodes. According to the order from large to small of the number of different-sign nodes, the nodes are calculated in turn, that is, the calculation order of the nodes is determined first.

[0068] (3) For each node, when calculating, the label with the largest number among the directly connected nodes of the node is used as the updated label value of the node, and the update is performed in turn according to the calculation order to complete the first round of update and obtain a once-updated graph.

[0069] (4) Calculate whether the updated label value of each node in the once-updated graph and the original graph structure is the same as the original label value. If they are the same, do not count; otherwise, increment the count by 1. Statistically obtain the count quantity, calculate the ratio of the count quantity to the number of nodes. If the ratio is greater than 0.2, perform the next round of node label update; otherwise, stop. If the ratio is greater than 0.2, based on the update result of the first round, calculate the calculation order of the nodes by the same method, then obtain the second-updated graph, and keep iterating. When the iteration stops, at this time, perform label conversion on the target node through the labels of adjacent nodes, achieving the purpose of making the labels of similar nodes the same. Furthermore, regard the nodes with the same label and being connected as the same area, that is, obtain multiple node category areas.

[0070] Preferably, in the embodiment of the present invention, the method for obtaining the representative topological vector includes: in the node category area, calculate and accumulate the cosine similarity between each topological vector and other topological vectors to obtain the overall similarity of each topological vector, and use the topological vector with the largest overall similarity as the representative topological vector. That is, the representative topological vector is the topological vector that can best represent the structural information in the node category area.

[0071] In summary, the embodiment of the present invention obtains the topological vectors of each node in the first topological graph structure of the power grid within the neighborhood range at different scales. In the topological vector sequence, analyze the similarity between adjacent elements to determine the neighborhood range and segmentation effect corresponding to the segmentation point. By statistically analyzing the segmentation points and segmentation effects of all nodes, obtain the segmentation property within each neighborhood range, and screen out the segmented neighborhoods. Under each segmented neighborhood, construct the second topological graph structure based on the topological vectors of the nodes and classify the nodes to obtain the node category areas and their power grid structure descriptors. By setting the neighborhood ranges at different scales, the present invention can make the final result a multi-scale result. The final power grid topological modeling has multi-scale information, can adaptively select an appropriate scale for analysis and processing according to the analysis requirements, and the graph structure at each scale contains large-scale information, reducing the computational amount of power grid topological analysis while ensuring the information richness of the final model and improving the analysis and processing efficiency of the smart grid.

[0072] Based on the same inventive concept, the present invention also proposes a computer device for power grid topological modeling based on graph theory, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the steps of any one of the power grid topological modeling methods based on graph theory.

[0073] The present invention also proposes a power grid topological modeling system based on graph theory. Please refer to Figure 2 , and this system includes:

[0074] The first power grid topology structure acquisition module 101 is configured to obtain the first power grid topology structure. For each node in the initial topology structure, the topology vector within the neighborhood range at different scales is acquired.

[0075] The first topology analysis module 102 is configured to, for each node, form a topology vector sequence based on the topology vectors according to the neighborhood range size. Obtain the adjacent scale similarity sequence according to the similarity between adjacent elements in the topology vector sequence. Determine the segmentation points in the adjacent scale similarity sequence and the segmentation effect in the nodes according to the magnitudes of consecutive elements. Statistically analyze the segmentation points and segmentation effects of all nodes, and obtain the segmentation property of each neighborhood range according to the segmentation effect of each node under the neighborhood range to which the segmentation point belongs. Filter out the segmented neighborhoods according to the segmentation property.

[0076] The power grid topology modeling module 103 is configured to, for each segmented neighborhood, set the node value of each node to the corresponding topology vector to obtain the second topology structure. Obtain the node category regions in the second topology structure. Screen the topology vectors in the node category regions to determine the representative topology vector of the node category region and use it as the power grid structure descriptor of the node category region.

[0077] It should be noted that: the above sequence of embodiments of the present invention is only for description and does not represent the superiority or inferiority of the embodiments. The processes depicted in the drawings do not necessarily require the specific order or consecutive order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.

[0078] Each embodiment in this specification is described in a progressive manner. The same or similar parts among the embodiments can be referred to each other, and the key point of each embodiment is to illustrate the differences from other embodiments.

Claims

1. A power grid topology modeling method based on graph theory, characterized in that: The method comprises: Obtaining a first topological graph structure of the power grid; for each node in the initial topological graph structure, obtaining a topological vector of the node within a neighborhood range of different scales; For each of the nodes, the topological vectors are formed into a topological vector sequence according to the size of the neighborhood range; an adjacent scale similarity sequence is obtained according to the similarity between adjacent elements in the topological vector sequence; a segmentation point in the adjacent scale similarity sequence and a segmentation effect in the node are determined according to the size of the continuous elements; the segmentation points and segmentation effects of all nodes are counted, and the segmentation property of each neighborhood range is obtained according to the segmentation effect of each node in the neighborhood range to which the segmentation point belongs, and a segmentation neighborhood is screened out according to the segmentation property; For each segmented neighborhood, the node value of each node is set to the corresponding topological vector to obtain a second topological graph structure; a node category region in the second topological graph structure is obtained; the topological vectors in the node category region are screened to determine a representative topological vector of the node category region and use it as a power grid structure descriptor of the node category region; The method for obtaining the segmentation effect includes: In the adjacent scale similarity sequence, a ratio between an element corresponding to the segmentation point and a minimum value of a previous segmentation segment is used as a first ratio, a ratio between an element corresponding to the segmentation point and a maximum value of a previous segmentation segment is used as a second ratio, and a mean of the first ratio and the second ratio is negatively correlated and normalized to obtain the segmentation effect of the segmentation point; The method for obtaining the segmentability includes: Any neighborhood range is taken as the target scale. If the neighborhood range to which the segmentation point of the node belongs is the target scale, the node is taken as the target node. The segmentation effects of the segmentation points of all target nodes at the target scale are accumulated to obtain the segmentability of the target scale.

2. The method for power grid topology modeling based on graph theory according to claim 1, characterized in that: The Node2Vec method is used to obtain the topological vectors of the nodes in neighborhoods of different scales.

3. The method for power grid topology modeling based on graph theory according to claim 1, characterized in that: The method for obtaining the adjacent scale similarity sequence includes: The topological vector sequence is a sequence sorted from small to large according to the neighborhood range. For each topological vector in the topological vector sequence, the average value of the cosine similarity between the topological vector and each preceding topological vector is taken as the adjacent scale similarity of the corresponding topological vector; the adjacent scale similarities of all topological vectors constitute the adjacent scale similarity sequence.

4. The method for power grid topology modeling based on graph theory according to claim 1, characterized in that: The segmentation points in the adjacent scale similarity sequence are obtained using the Otsu multi-threshold segmentation algorithm.

5. The method for power grid topology modeling based on graph theory according to claim 1, characterized in that: The method for obtaining the node category area includes: In the second topological graph structure, multiple initial node categories are obtained according to the similarity of node values ​​between each node, and each node is labeled according to the initial node category. The label is updated using the SLPA algorithm to obtain a final label result. In the final label result, nodes with the same label and connected form a node category area.

6. The method for power grid topology modeling based on graph theory according to claim 1, characterized in that: The method for obtaining the representative topology vector includes: In the node category area, the cosine similarities between each topology vector and other topology vectors are calculated and accumulated to obtain the overall similarity of each topology vector, and the topology vector with the largest overall similarity is used as the representative topology vector.

7. A computer device for power grid topology modeling based on graph theory, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of a graph-theory-based power grid topology modeling method are implemented as described in any one of claims 1 to 6.

8. A power grid topology modeling system based on graph theory, characterized in that: The system comprises: A power grid first topology structure acquisition module is used to obtain a first topology structure of the power grid; for each node in the initial topology structure, a topology vector of the node in a neighborhood range of different scales is obtained; The first topology map analysis module is used to form a topology vector sequence from the topology vector according to the size of the neighborhood range for each of the nodes; obtain an adjacent scale similarity sequence according to the similarity between adjacent elements in the topology vector sequence; determine the segmentation points in the adjacent scale similarity sequence and the segmentation effect in the node according to the size of the continuous elements; count the segmentation points and segmentation effects of all nodes, obtain the segmentation property of each neighborhood range according to the segmentation effect of each node in the neighborhood range to which the segmentation point belongs, and select the segmentation neighborhood according to the segmentation property; A power grid topology modeling module is used to set the node value of each node to the corresponding topology vector for each segmented neighborhood to obtain a second topology graph structure; obtain a node category area in the second topology graph structure; screen the topology vectors in the node category area, determine the representative topology vector of the node category area and use it as a power grid structure descriptor of the node category area; The method for obtaining the segmentation effect includes: In the adjacent scale similarity sequence, a ratio between an element corresponding to the segmentation point and a minimum value of a previous segmentation segment is used as a first ratio, a ratio between an element corresponding to the segmentation point and a maximum value of a previous segmentation segment is used as a second ratio, and a mean of the first ratio and the second ratio is negatively correlated and normalized to obtain the segmentation effect of the segmentation point; The method for obtaining the segmentability includes: Any neighborhood range is taken as the target scale. If the neighborhood range to which the segmentation point of the node belongs is the target scale, the node is taken as the target node. The segmentation effects of the segmentation points of all target nodes at the target scale are accumulated to obtain the segmentability of the target scale.

Citation Information

Patent Citations

  • A graph theory-based method for power grid topology modeling

    CN113051694B

  • Power system state similarity analysis method

    CN106816871A

  • Graph theory-based power grid topology modeling method

    CN113051694A