Power grid line division method, computer device and computer readable storage medium
By simplifying and tightly calculating the topology diagram of the power grid nodes and dividing the lines with the clustering algorithm, the problem of inability to effectively consider the relationship between the trends between lines in the existing technology is solved, and the clear division of power grid lines and the rapid identification of heavy overload risks are achieved.
Patent Information
- Application Number
- CN202211245438.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-10-12
- Publication Date
- 2025-04-25
- Estimated Expiration
- 2042-10-12
AI Technical Summary
The prior art is difficult to effectively consider the relationship between the trends between lines and lines. When dividing lines in the power grid, it is impossible to clearly and intuitively reflect the tightness of the trends between lines.
By obtaining the topology diagram of the power grid node, multiple sub-graphs are obtained simplified operations, and the density calculation of the sub-graphs is performed to obtain the flow transfer density matrix. Then, the lines are clustered and divided according to the preset clustering algorithm and the density matrix, and multiple first lines are clustered, allowing the lines to appear repeatedly in different clusters.
It realizes the effective division of power grid lines, clearly and intuitively reflects the tightness of the flow transfer between lines, and can quickly identify the risk of heavy overload when multiple power grid lines are interrupted.
Smart Images

Figure CN115566670B_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the technical field of power system automation, and in particular, relates to a power grid line division method, a computer device, and a computer-readable storage medium. Background Art
[0002] The risk of heavy overload of lines and equipment is one of the most concerned operational risks in the power grid. Conventional static safety analysis can only calculate the transfer of power flow to other lines when a single-circuit line fails. In actual large power grids, due to the large scale of the power grid and the large number of lines, it is difficult to enumerate and analyze the power flow transfer and overload risks of the power grid when multiple lines are disconnected by power flow calculation. Therefore, in conventional methods, the lines in the power grid are clustered and divided. However, in the process of line clustering, there are often some lines that have a high degree of similarity with two or more clusters. In conventional clustering methods, they can only be divided into a category with the closest distance, without considering the influence of the power flow relationship between lines. In other words, the division method of the prior art cannot well reflect the power flow correlation between lines. Therefore, how to effectively divide the lines in the power grid is a technical problem that needs to be solved urgently by technical personnel in this field.
[0003] The preceding description is intended to provide general background information and does not necessarily constitute prior art. Summary of the invention
[0004] Based on this, it is necessary to propose a power grid line division method, a computer device and a computer-readable storage medium to address the above problems, which can effectively divide the lines in the power grid.
[0005] The present application solves the technical problem by adopting the following technical solutions:
[0006] The present application provides a method for dividing power grid lines, comprising the following steps: obtaining a power grid node topology map, simplifying the power grid node topology map to obtain multiple sub-graphs, each sub-graph including at least one power grid line; calculating the density of the sub-graph to obtain a power flow transfer density matrix corresponding to each sub-graph; clustering the lines according to a preset clustering algorithm and the power flow transfer density matrix to obtain multiple first line clusters, wherein the same line may appear repeatedly in the multiple first line clusters.
[0007] In an optional embodiment of the present application, a simplification operation is performed on a power grid node topology graph to obtain multiple subgraphs, including: determining all edges in the power grid node topology graph; selecting an edge and deleting the selected edge from the power grid node topology graph to test the connectivity of the power grid node topology graph; if the power grid node topology graph is not connected, determining the edge as a bridge; deleting the bridge from the power grid node topology graph to obtain a subgraph; traversing all edges in the power grid node topology graph to obtain multiple subgraphs, and there is no electrical connection between the multiple subgraphs.
[0008] In an optional embodiment of the present application, a density calculation is performed on the subgraph to obtain a power transfer density matrix corresponding to each subgraph, including: obtaining the number of line loops n of the subgraph, establishing an initial power transfer density matrix of size n*n, wherein the initial power transfer density matrix is a zero matrix; obtaining calculation factors corresponding to the line combination, calculating the calculation factors according to the density calculation, and obtaining the density corresponding to the line combination, wherein the calculation factors include the size of the active power flow, the amount of power flow change, the branch disconnection distribution factor, and the active power flow rated capacity; filling the corresponding density into the initial power transfer density matrix according to the line combination to obtain the power transfer density matrix.
[0009] In an optional embodiment of the present application, when the calculation factor includes a branch disconnection distribution factor, the calculation factor corresponding to the line combination is obtained, including: obtaining a node reactance matrix and a node-line association vector, and obtaining the impedance of the port node where the line is located according to the node reactance matrix and the node-line association vector, wherein the impedance of the port node where the line is located includes self-impedance and mutual impedance; obtaining the line reactance, and calculating the branch disconnection distribution factor according to the line reactance and the impedance of the port node where the line is located.
[0010] In an optional embodiment of the present application, the corresponding density is filled into the initial power flow transfer density matrix according to the line combination, including: obtaining a preset correlation threshold; if the density is less than the correlation threshold, the density is set to 0 and filled into the initial power flow transfer density matrix; if the density is greater than or equal to the correlation threshold, the density is difference calculated to obtain the difference density, and filled into the initial power flow transfer density matrix.
[0011] In an optional embodiment of the present application, the lines are clustered and divided according to a preset clustering algorithm and a power transfer density matrix to obtain multiple first line clusters, including: setting a preference, and obtaining a similarity matrix of the line combination according to the preference and the power transfer density matrix; performing initial clustering on the line combination according to the preset algorithm and the similarity matrix to obtain multiple second line clusters, and the lines between the multiple second line clusters are non-overlapping; and performing correction calculations on the second line clusters to determine that multiple first line clusters are obtained.
[0012] In an optional embodiment of the present application, the second line clustering includes a selected second line cluster and remaining second line clusters, the selected second line cluster is the second line cluster currently selected for calculation, and the remaining second line clusters are the second line clusters remaining in the second line cluster except the selected second line cluster; the selected second line cluster includes a selected line, and the selected line is a line in the second line cluster currently selected for calculation; the second line cluster is corrected and calculated to obtain multiple first line clusters, including: determining an average similarity between the selected line in the selected second line cluster and the remaining second line clusters; when the average similarity is greater than a preset average similarity threshold, adding the selected line to the remaining second line clusters; after traversing the calculation of all selected lines and the remaining second line clusters, determining the corrected second line cluster as the first line cluster.
[0013] In an optional embodiment of the present application, after obtaining multiple first line clusters, the method also includes: obtaining a similarity matrix corresponding to the first line clusters; obtaining an overlap index corresponding to the first line clusters according to the similarity matrix; obtaining a preset index threshold, and when the overlap index is greater than the index threshold, determining that the first line cluster division is valid and outputting it.
[0014] The present application also provides a computer device, including a processor and a memory: the processor is used to execute a computer program stored in the memory to implement the aforementioned method.
[0015] The present application also provides a computer-readable storage medium storing a computer program, which implements the aforementioned method when the computer program is executed by a processor.
[0016] The embodiments of the present application have at least the following beneficial effects:
[0017] The present application can simplify the power grid lines into multiple subgraphs, and cluster the lines according to the compactness to obtain multiple first line clusters, which can clearly and intuitively reflect the compactness of the power flow transfer between the lines, and the first line clusters are the result of algorithm optimization, and the lines between the first line clusters can be repeated, thereby realizing overlapping cluster division, avoiding the problem that when the line has a high similarity with two or more clusters, it can only be classified into a category with the closest distance, resulting in inaccurate analysis of the risk of heavy overload of lines in other subgroups. Through the overall analysis of the power flow level of the same group of lines, the risk of heavy overload under the disconnection of multiple lines in the power grid can be quickly identified.
[0018] The above description is only an overview of the technical solution of the present application. In order to more clearly understand the technical means of the present application, it can be implemented according to the contents of the specification, and in order to make the above and other purposes, features and advantages of the present application more obvious and easy to understand, the following preferred embodiments are specifically cited and described in detail with the accompanying drawings. It should be understood that the above general description and the detailed description below are only exemplary and explanatory, and cannot limit the present application. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0020] in:
[0021] Figure 1 A schematic diagram of a flow chart of a method for dividing power grid lines provided in an embodiment;
[0022] Figure 2 A schematic diagram of an IEEE39 node system provided by an embodiment;
[0023] Figure 3 A schematic list of IEEE39 node system power flow distribution provided by an embodiment;
[0024] Figure 4 A schematic table of a power flow transfer density matrix provided by an embodiment;
[0025] Figure 5 A schematic table of similarity matrices provided by an embodiment;
[0026] Figure 6 A second line clustering division schematic table is provided for an embodiment;
[0027] Figure 7 A schematic table of average similarities between lines provided in an embodiment;
[0028] Figure 8 A schematic table of first line clustering division is provided for an embodiment;
[0029] Fig. 9 A schematic block diagram of the structure of a computer device provided by an embodiment. DETAILED DESCRIPTION
[0030] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0031] In conventional clustering, objects are not allowed to appear repeatedly in multiple groups. This is a current limitation for the detection of heavy overload risks in power grids, and it is difficult to clearly and intuitively reflect the closeness of power flow transfer between lines. Based on this, if the transmission lines of large power grids can be grouped according to the closeness of power flow transfer between lines, the lines in the same group can have a strong mutual power flow transfer relationship with each other. Through an overall analysis of the power flow levels of lines in the same group, it is possible to quickly identify the heavy overload risks when multiple lines in the power grid are disconnected. To this end, a power grid line division method provided in the present application is proposed. In order to clearly describe a power grid line division method provided in this embodiment, please refer to Figures 1 to 8 It includes steps S110 to S130.
[0032] Step S110: obtaining a power grid node topology map, and simplifying the power grid node topology map to obtain a plurality of sub-maps, each of which includes at least one power grid line.
[0033] In one embodiment, in step S110: simplifying the power grid node topology map to obtain multiple subgraphs, including: determining all edges in the power grid node topology map; selecting an edge and deleting the selected edge from the power grid node topology map to test the connectivity of the power grid node topology map; if the power grid node topology map is not connected, determining the edge as a bridge; deleting the bridge from the power grid node topology map to obtain a subgraph; traversing all edges in the power grid node topology map to obtain multiple subgraphs, and there is no electrical connection between the multiple subgraphs.
[0034] In one embodiment, the power grid is first regarded as a directed graph according to the connection relationship between the power grid nodes and the lines, and the bridges of the power grid are deleted in the graph to simplify the graph model. A vector method is used to quickly calculate the branch disconnection distribution factor, and then the defined power flow transfer density matrix is calculated. The matrix can comprehensively reflect the disconnection sensitivity and disconnection consequences between lines. For ease of understanding, it can be combined with Figure 2 Take the IEEE39 node system provided as an example for understanding. Figure 2 As shown in Figure 1, the IEEE 39-node system has 39 nodes and 46 lines. Furthermore, when obtaining the grid node topology, the flow size and capacity of each line of the power-saving system under a known operating mode can be obtained. For details, please refer to Figure 3The contents listed in the diagram. Based on the connection relationship between the nodes and edges of the power grid, the topological structure of the power grid is described using a topological graph. In the topological graph, if a certain edge is deleted, resulting in the graph being disconnected, the edge is called the bridge of the graph. In other words, if the bridge is deleted, the topological graph G (that is, the topological graph of the power grid nodes, hereinafter referred to as "topological graph G", the same below) will be divided into several subgraphs without electrical connection, that is, to determine multiple independent subgraphs. To this end, it is necessary to traverse all the edges in the topological graph, delete them from the topological graph G, and test the connectivity of the topological graph G. If the topological graph G is not connected, it can be determined that the edge is a bridge and it is determined to be deleted; otherwise, it is not a bridge and the edge is retained. After traversing all the edges in the topological graph G, the topological graph G can be divided into multiple subgraphs that have no electrical connection with each other. It can be understood that the topology graph G obtained above is actually a directed graph expression of the IEEE39 node system, in which the edges are the lines in the IEEE39 node system, so the subgraph can contain lines of several power grids. Figure 2 Taking the IEEE39 node system shown in the figure as an example, the edges determined as bridges after traversal include: 22, 37, 38, 39, 40, 41, 42, 43, 44, 45, and 46. After deleting the above bridges from the topological graph G, multiple subgraphs with no electrical connection between each other can be obtained. Subsequently, clustering operations can be performed on the lines in each subgraph, so as to divide the groups according to the closeness or correlation.
[0035] Step S120: Calculate the density of the subgraphs to obtain a power flow transfer density matrix corresponding to each subgraph.
[0036] In one embodiment, in step S120: a density calculation is performed on the subgraph to obtain a power transfer density matrix corresponding to each subgraph, including: obtaining the number of lines n of the subgraph, establishing an initial power transfer density matrix of n*n size, wherein the initial power transfer density matrix is a zero matrix; obtaining calculation factors corresponding to the line combination, calculating the calculation factors according to the density calculation, and obtaining the density corresponding to the line combination, wherein the calculation factors include the active power size, the power change amount, the branch disconnection distribution factor, and the active power rated capacity; filling the corresponding density into the initial power transfer density matrix according to the line combination to obtain the power transfer density matrix.
[0037] In one embodiment, when the calculation factor includes a branch disconnection distribution factor, obtaining the calculation factor corresponding to the line combination includes: obtaining a node reactance matrix and a node-line association vector, and obtaining the impedance of the port node where the line is located according to the node reactance matrix and the node-line association vector, wherein the impedance of the port node where the line is located includes self-impedance and mutual impedance; obtaining the line reactance, and calculating the branch disconnection distribution factor according to the line reactance and the impedance of the port node where the line is located.
[0038] In one embodiment, the corresponding compactness is filled into the initial power flow transfer compactness matrix according to the line combination, including: obtaining a preset correlation threshold; if the compactness is less than the correlation threshold, the compactness is set to 0 and filled into the initial power flow transfer compactness matrix; if the compactness is greater than or equal to the correlation threshold, the compactness is difference calculated to obtain the difference compactness, and filled into the initial power flow transfer compactness matrix.
[0039] In one embodiment, the number of lines is n, and the power transfer density matrix C is an n*n matrix, in which the elements in the i-th row and j-th column represent the density of the power transfer between line i and line j, that is, the density. First, an initial power transfer density matrix as a zero matrix can be established, and then the density between each line is obtained and filled into the initial power transfer density matrix to finally determine the power transfer density matrix. Among them, the density between each line is also the element in the power transfer density matrix, and the settlement can refer to the following formula:
[0040]
[0041] Where C ij Indicates the degree of power transfer from line i to line j, obtained by calculating the calculation factors. The calculation factors include: j is the active power flow of line j in the initial state; D ij P i is the change in power flow of line j after line i is shut down; P jmax is the rated capacity of the active power flow of line j. The above values can be preset or obtained simultaneously when obtaining the topology map G. In addition, the calculation factor also includes the branch disconnection distribution factor, such as D in formula (1): ij is the branch disconnection distribution factor of line i to line j, which needs to be obtained by calculation, which will be expanded in the following text and will not be described again for the time being. Further, when the calculated density is filled into the initial power flow transfer density matrix to obtain the power flow transfer density matrix, further calculation is required, which can be specifically referred to formula (2):
[0042]
[0043] C0 is the preset correlation threshold, which can usually be in the range of 0.2 to 0.3; tanh(·) is the inverse tangent function. ij When it is lower than the correlation threshold, it can be considered that there is no power flow transfer density between the lines, and C ij When filling in the initial power flow transfer density matrix, the density is set to 0; when the density C ijWhen it is higher than or equal to the correlation threshold, the inverse tangent function can be used to calculate so that a small number of outliers enter the saturation region of the function and the difference between the intermediate elements is enlarged. ij The calculation process first needs to obtain the node reactance matrix and the node-line association vector, and then obtain the node impedance of the line port based on the node reactance matrix and the node-line association vector. The node impedance of the line port includes self-impedance and mutual impedance. Obtain the line reactance, and calculate the branch disconnection distribution factor based on the line reactance and the node impedance of the line port. The specific calculation process can be obtained through formulas (3) to (5):
[0044]
[0045]
[0046]
[0047] Where M i and M j denote the node-line correlation vectors of line i and line j respectively, and X is the node reactance matrix. i and x j are the reactances of line i and line j respectively; X ii is the self-impedance between the port nodes where line i is located; X ij is the mutual impedance between the port node where line i is located and the port node where line j is located. Therefore, based on the above calculation, the power transfer density matrix composed of the density between lines in each subgraph can be obtained. Taking the IEEE39 node system provided in this embodiment as an example, the correlation threshold is set to 0.2, and the power transfer density matrix finally obtained by calculating the calculation factor can be referred to Figure 4 , Figure 4 A schematic table of a power flow transfer density matrix provided by an embodiment.
[0048] Step S130: clustering the lines according to a preset clustering algorithm and a power flow transfer density matrix to obtain a plurality of first line clusters, wherein the same line may appear repeatedly in the plurality of first line clusters.
[0049] In one embodiment, in step S130: clustering the lines according to a preset clustering algorithm and a power flow transfer density matrix to obtain a plurality of first line clusters, including: setting a preference, and obtaining a similarity matrix of the line combination according to the preference and the power flow transfer density matrix; performing initial clustering on the line combination according to the preset algorithm and the similarity matrix to obtain a plurality of second line clusters, wherein the lines between the plurality of second line clusters are non-overlapping; and performing correction calculation on the second line clusters to determine to obtain a plurality of first line clusters.
[0050] In one embodiment, the similarity between lines can be determined according to the power transfer density matrix obtained in the previous text. The overall clustering process can be roughly understood as first dividing the clusters according to the similarity to obtain multiple second line clusters, in which the lines between the second line clusters are independent of each other, that is, they will not appear repeatedly. Then the second line cluster is corrected and calculated so that the line can appear repeatedly in other line clusters to obtain the first line cluster, and the lines in the first line cluster can appear repeatedly. It can be understood that in the clustering process, there are often some lines that have a high similarity with two or more line clusters. In conventional clustering methods, they can only be divided into a line cluster with the closest distance. For safety analysis, this will affect the analysis of the risk of heavy overload of lines in other subgroups. In other words, based on application requirements, line grouping needs to achieve the repetition of some lines in multiple groups. This application refers to the above process as overlapping clustering, and the specific implementation process will be described in detail later. First, the lines need to be grouped. You can choose any clustering method that can adaptively determine the number of classifications to achieve clustering of the lines. For example, in this embodiment, AP clustering and other methods can be used, and there is no specific limitation. In this application, AP clustering is used for easy understanding. First, the similarity between lines (that is, line combinations) needs to be obtained based on the power transfer density matrix, so as to accumulate the similarity matrix. The calculation method of the similarity matrix can refer to the following formula:
[0051]
[0052] Where S ij represents the similarity between route i and route j, and the diagonal element p is the preference, that is, S ii The larger the value is, the more likely line i is to become a cluster center. The preference is set by the user in advance. In this embodiment, p=-0.5 is set for ease of understanding. The similarity matrix obtained by the IEEE 39 node system provided in this embodiment can be referred to. Figure 5 , Figure 5 A schematic table of similarity matrices provided in an embodiment. Since S is relatively sparse and satisfies S=S T , so Figure 5 According to the corresponding position elements of the similarity matrix, the similarity of the triangular position line combination under the matrix S is displayed. Figure 5 In the similarity matrix S, we can select the AP clustering algorithm to cluster the routes. Since the similarity between routes 35 and 36 and the rest of the routes is 0, we delete them directly. Finally, the remaining 33 routes are divided into 6 second route clusters. The division results can be referred to Figure 6 , Figure 6A schematic diagram of second line clustering division is provided for an embodiment. It can be seen that the lines contained in each second line cluster are not repeated, and correction calculation is required to complete overlapping clustering. The correction process will be described in detail later.
[0053] In one embodiment, the second line clustering includes a selected second line cluster and remaining second line clusters, the selected second line cluster is the second line cluster currently selected for calculation, and the remaining second line clusters are the second line clusters remaining in the second line cluster except the selected second line cluster; the selected second line cluster includes a selected line, and the selected line is a line in the second line cluster currently selected for calculation; the second line cluster is corrected and calculated to obtain multiple first line clusters, including: determining an average similarity between the selected line in the selected second line cluster and the remaining second line clusters; when the average similarity is greater than a preset average similarity threshold, adding the selected line to the remaining second line clusters; after traversing the calculation of all selected lines and the remaining second line clusters, determining the corrected second line cluster as the first line cluster.
[0054] In one embodiment, to determine whether a route has a high similarity to the other second route clusters at the same time, it is necessary to calculate each route and the other second route clusters accordingly. Therefore, it is necessary to select a route in a second route and calculate the average similarity of the other second route clusters. Therefore, it is necessary to clarify several concepts. First, the selected second route cluster is the selected second route cluster, and the remaining ones are the other second route clusters. For example, Figure 6 Taking the second line cluster as an example, assuming that the second line cluster with the sequence number 2 is currently selected for calculation, then the second line cluster with the sequence number 2 is also the selected second line cluster; and the second line clusters with the sequences 1, 3, 4, 5, and 6 are the remaining second line clusters. Further, the selected second line cluster includes the selected line, and the selected line is a line in the second line cluster currently selected for calculation. For ease of understanding, it can be assumed that all lines have been divided into n after the previous division. a In the second line clusters, each second line cluster is recorded as Cl1, Cl2, ...Cl na , for the k in the i-th second line cluster i The line can be recorded as Cl i ={cl i,1 ,cl i,2 ,…,cl i,ki}. Then the correction process can be to select a second line cluster Cl i (i.e., select the second line cluster), traverse each line in the selected second line cluster, and record the line as cl i,p(That is, the selected line). Calculate the selected line and the remaining second line cluster Cl j (i.e. the average similarity of the rest of the second line clusters), set the similarity threshold S0, if it is the same as Cl j If the similarity is greater than the threshold, the route is added to the remaining second route clusters. The average similarity calculation method is as follows:
[0055]
[0056] In the formula Indicates the selected line cl i,p Cluster Cl with the rest of the second lines j The average similarity of For line cl i,p and line cl j,q The corresponding position element in the similarity matrix S. In this embodiment, for ease of understanding, the average similarity threshold can be set to S0=0.4, and the average similarity between the selected route and the remaining second route clusters that can be obtained is as follows: Figure 7 As shown. Figure 7 As shown, the average similarity between the selected route and the remaining second route clusters that is higher than the average similarity threshold has been highlighted, which means that the selected route and the corresponding remaining second route clusters have a high similarity with the selected route cluster at the same time, and can appear in both route clusters at the same time, so the selected route can be added to the remaining second route clusters. After traversing the calculation of all selected routes and the remaining second route clusters, the first route cluster can be finally determined. The first route cluster can refer to Figure 8 , Figure 8 A first line clustering diagram is provided for an embodiment. Figure 8 As shown, the newly added line has been highlighted, which means that it can appear repeatedly. For example, line 10 has a high similarity to the first line clusters with sequence numbers 1 and 2, which facilitates the analysis of the risk of line overload.
[0057] In one embodiment, after obtaining a plurality of first line clusters in step S130, the method further includes: obtaining a similarity matrix corresponding to the first line clusters; obtaining an overlap index corresponding to the first line clusters according to the similarity matrix; obtaining a preset index threshold, and when the overlap index is greater than the index threshold, determining that the first line cluster division is valid and outputting it.
[0058] In one embodiment, after completing the division of the first line, it can be understood that since the scheme proposed in the present application is referred to as overlapping clustering in the present application, for reproducible lines and their divisions, an evaluation can be performed after the division to determine whether the division is effective. Among them, the modularity index is generally used for evaluation. The modularity index can reflect the division effect of the community or cluster. The modularity index value range is [0,1]. The closer to 1, the better the division effect. Usually, the modularity index result of the community or cluster division is 0.3 to 0.7. When the modularity is greater than 0.3, the division result can be considered to be effective. In the traditional overlapping modularity index, only whether there is an association between cluster objects is considered, and the size of the association is not considered. Therefore, the present application can integrate the size of the similarity between lines into the overlapping index EQ according to the similarity matrix, so that it can reflect the degree of influence of the degree of association between lines on the clustering effect. Among them, the calculation process of the overlapping index EQ can be:
[0059]
[0060] Where S sum is the sum of the elements of the similarity matrix S except the diagonal elements. Since S is a symmetric matrix, S sum represents 2 times the sum of similarities between all routes. p and q represent the first route cluster Cl i Middle two lines, Q p and Q q represents the number of first line clusters with line p and line q, respectively, S pq is the size of the element at the corresponding position between line p and line q in the similarity matrix, k p Indicates that the row corresponding to line p in the similarity matrix is removed from S pp The sum of the remaining elements, k q Indicates that the row corresponding to line q in the similarity matrix is removed from S qq The sum of the remaining elements. For example, the first line cluster finally divided by the IEEE 39 node system provided in the embodiment of the present application has an EQ=0.521 obtained by calculation. This index is greater than 0.3, which indicates that the above-mentioned tight line cluster division is effective, so it can be output.
[0061] Therefore, the present application can simplify the power grid-type lines into multiple subgraphs, and cluster the lines according to the density to obtain multiple first line clusters, which can clearly and intuitively reflect the density of the flow transfer between the lines, and the first line clusters are the result of algorithm optimization. The lines between the first line clusters can be repeated, thereby realizing overlapping clustering division, so that the lines with higher density of flow transfer are in the same group of clusters, so as to facilitate the overall analysis of the power grid flow level.
[0062] Fig. 9 FIG. 1 shows an internal structure diagram of a computer device in an embodiment. The computer device may be a terminal or a server. Fig. 9 As shown, the computer device includes a processor, a memory and a network interface connected via a system bus. The memory includes a non-volatile storage medium and an internal memory. The non-volatile storage medium of the computer device stores an operating system and may also store a computer program. When the computer program is executed by the processor, the processor may implement the power grid line division method. The internal memory may also store a computer program. When the computer program is executed by the processor, the processor may implement the age recognition method. Those skilled in the art will understand that Fig. 9 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0063] In one embodiment, a computer device is proposed, including a memory and a processor, wherein the memory stores a computer program, and when the computer program is executed by the processor, the processor performs the following steps: Step S110: Obtain a grid node topology map, simplify the grid node topology map to obtain multiple subgraphs, and the subgraphs include at least one grid line; Step S120: Calculate the density of the subgraphs to obtain a power flow transfer density matrix corresponding to each subgraph; Step S130: Cluster and divide the lines according to a preset clustering algorithm and a power flow transfer density matrix to obtain multiple first line clusters, and the same line may appear repeatedly in multiple first line clusters. Avoid the problem that when a line has a high similarity with two or more clusters, it can only be classified into a category with the closest distance, resulting in inaccurate analysis of the risk of heavy overload of lines in other subgroups. Through the overall analysis of the power flow level of the same group of lines, the risk of heavy overload under the disconnection of multiple lines in the power grid can be quickly identified.
[0064] In one embodiment, a computer-readable storage medium is provided, which stores a computer program. When the computer program is executed by a processor, the processor executes the steps of the power grid line division method as described above.
[0065] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the program can be stored in a non-volatile computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
[0066] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0067] The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. A method for dividing power grid lines, characterized in that: The steps include: Acquire a power grid node topology map, and simplify the power grid node topology map to obtain a plurality of sub-maps, wherein the sub-maps include at least one power grid line; Calculating the density of the subgraphs to obtain a power flow transfer density matrix corresponding to each subgraph; Clustering the lines according to a preset clustering algorithm and the power flow transfer density matrix to obtain a plurality of first line clusters, wherein the same line may appear repeatedly in the plurality of first line clusters; The simplification operation on the power grid node topology graph is performed to obtain a plurality of subgraphs, including: Determine all edges in the power grid node topology graph; Selecting an edge and deleting the selected edge from the power grid node topology graph to test the connectivity of the power grid node topology graph; If the power grid node topology graph is not connected, determining the edge as a bridge; Deleting the bridge from the power grid node topology graph to obtain a subgraph; Traversing all edges in the power grid node topology graph to obtain a plurality of subgraphs, wherein there is no electrical connection between the plurality of subgraphs; The step of calculating the density of the subgraphs to obtain a power flow transfer density matrix corresponding to each subgraph includes: Obtaining the number of lines n of the subgraph, establishing an initial power flow transfer density matrix of size n*n, wherein the initial power flow transfer density matrix is a zero matrix; Obtaining a calculation factor corresponding to a line combination, calculating the calculation factor according to the compactness calculation, and obtaining the compactness corresponding to the line combination, wherein the calculation factor includes an active power flow size, a power flow change amount, a branch circuit breaking distribution factor, and an active power flow rated capacity; The corresponding density is filled into the initial power flow transfer density matrix according to the line combination to obtain the power flow transfer density matrix.
2. The method for dividing power grid lines according to claim 1, characterized in that: When the calculation factor includes the branch disconnection distribution factor, The obtaining the calculation factor corresponding to the line combination includes: Obtaining a node reactance matrix and a node-line association vector, and obtaining a port node impedance of the line according to the node reactance matrix and the node-line association vector, wherein the port node impedance of the line includes a self-impedance and a mutual impedance; The line reactance is obtained, and the branch circuit breaking distribution factor is calculated according to the line reactance and the impedance of the port node where the line is located.
3. The method for dividing power grid lines according to claim 1, characterized in that: The step of filling the corresponding density into the initial power flow transfer density matrix according to the line combination includes: Obtaining a preset correlation threshold; If the compactness is less than the correlation threshold, the compactness is set to 0 and filled into the initial power flow transfer compactness matrix; If the compactness is greater than or equal to the correlation threshold, a difference calculation is performed on the compactness to obtain a difference compactness, and the difference compactness is filled into the initial power flow transfer compactness matrix.
4. The method for dividing power grid lines according to claim 1, characterized in that: The clustering of the lines according to the preset clustering algorithm and the power flow transfer density matrix to obtain a plurality of first line clusters includes: Setting a preference degree, and obtaining a similarity matrix of line combinations according to the preference degree and the power flow transfer density matrix; Performing initial clustering division on the route combination according to a preset algorithm and the similarity matrix to obtain a plurality of second route clusters, wherein the routes between the plurality of second route clusters are non-overlapping; The second line cluster is corrected and calculated to obtain a plurality of the first line clusters.
5. The method for dividing power grid lines according to claim 4, characterized in that: The second line cluster includes a selected second line cluster and remaining second line clusters, the selected second line cluster is the second line cluster currently selected for calculation, and the remaining second line clusters are the remaining second line clusters in the second line cluster except the selected second line cluster; The selected second line cluster includes a selected line, and the selected line is a line in the second line cluster currently selected for calculation; The performing correction calculation on the second line cluster to determine to obtain a plurality of the first line clusters includes: determining an average similarity between the selected route in the selected second route cluster and the remaining second route clusters; When the average similarity is greater than a preset average similarity threshold, adding the selected route to the remaining second route clusters; After traversing the calculation of all the selected lines and the remaining second line clusters, the modified second line cluster is determined as the first line cluster.
6. The method for dividing power grid lines according to claim 1, characterized in that: After obtaining the plurality of first line clusters, the method further includes: Obtaining a similarity matrix corresponding to the first line cluster; Obtaining an overlap index corresponding to the first line cluster according to the similarity matrix; A preset index threshold is obtained, and when the overlap index is greater than the index threshold, it is determined that the first line clustering division is valid and output.
7. A computer device, characterized in that: including a processor and a memory; The processor is configured to execute the computer program stored in the memory to implement the method according to any one of claims 1 to 6.
8. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method according to any one of claims 1 to 6 is implemented.
Citation Information
Patent Citations
Power grid line loss calculation method and device
CN111834996A
Electric power CPS risk propagation range prediction method and system based on collaborative attack gene
CN113055358A