Power distribution network state estimation method and system fusing physical constraints and graph attention

CN122553335APending Publication Date: 2026-08-11TIANJIN UNIV +3
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-05-19
Publication Date
2026-08-11

AI Technical Summary

Technical Problem

首先,相较于经典的加权最小二乘法(WLS),基于卡尔曼滤波等动态状态估计方法虽然考虑了时间相关性,但其线性或准线性的状态转移矩阵难以准确刻画高比例新能源接入下的复杂非线性动态,在剧烈波动场景下极易失效甚至发散

Benefits of technology

[0063]The distribution network state estimation method integrating physical constraints and graph attention provided by this invention has the following characteristics: By constructing a spatiotemporal feature extraction architecture based on GCN and Transformer modules, it effectively overcomes the defect of traditional pure time series models ignoring the spatial topological correlation of the distribution network, and achieves accurate capture of the complex nonlinear dynamic evolution law of high-proportion active distribution networks under drastic source-load fluctuations; By establishing a differentiable physical layer based on Kirchhoff's laws and Ohm's law, the inherent electrical physical laws of the distribution network are embedded as a penalty term into the model training closed loop, solving the pain point of traditional pure data-driven models where the prediction results violate basic electrical laws due to the lack of physical constraints, and significantly improving the physical consistency, reliability, and interpretability of generated pseudo-measurements; By proposing to integrate the generated high-fidelity pseudo-measurements with the finite and sparse real-time measurements of the distribution network, and substituting them into a weighted least squares framework for dynamic iterative solution of the Jacobian matrix, it effectively compensates for the low coverage of distribution network measurement equipment and the sparse data. The method significantly improves the numerical stability and final sensing accuracy of the state estimation process, addressing the insufficient observability of traditional dynamic state estimation methods. A comprehensive evaluation of the distribution network state estimation results is conducted using metrics such as mean square error (MSE), mean absolute percentage error (MAPE), and the average and maximum deviations of node voltage amplitude and phase angle. Compared with traditional dynamic state estimation methods and pure data prediction models without physical constraints, the proposed method achieves significant reductions in several core error metrics, demonstrating strong robustness and adaptability. In summary, the method not only improves the overall accuracy and physical reliability of high-penetration active distribution network state estimation, verifying the effectiveness and superiority of the "data-physical" dual-drive model in solving the problem of sparse distribution network measurements, but also proves that the proposed distribution network state estimation method, which integrates physical constraints and graph attention network-generated pseudo-measurements, has high practical engineering application value and significance for ensuring the safe, stable, and economical operation of smart grids.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122553335A_ABST
    Figure CN122553335A_ABST
Patent Text Reader

Abstract

This invention discloses a method and system for estimating the state of a distribution network by integrating physical constraints and graph attention. The method includes: constructing a historical feature input matrix representing the evolution of electrical states at multiple time steps; extracting a high-order topological spatial feature matrix of the distribution network using a graph convolutional neural network (GCN) with Chebyshev polynomial approximation; inputting the extracted spatial feature matrix into a Transformer module to decode and generate initial pseudo-measurements of the distribution network node states; constructing a differentiable physical layer based on the distribution network power flow equations, substituting the initial pseudo-measurements into Kirchhoff's laws to calculate node power imbalances, and outputting high-fidelity pseudo-measurements that satisfy electrical laws; constructing a high-dimensional hybrid measurement vector, and solving a weighted least squares objective function based on the Newton-Raphson iterative method to achieve high-precision estimation of the distribution network system state. This invention has extremely high practical engineering application value and significance for ensuring the safe, stable, and economical operation of smart grids.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of distribution network state estimation technology, and more specifically, to a distribution network state estimation method and system that integrates physical constraints and graph attention. Background Technology

[0002] With the continuous development of smart grid technology, the complexity and scale of distribution networks are also expanding. State estimation, as a core component of grid operation, is receiving increasing attention for its accuracy and reliability. In particular, the integration of highly pervasive distributed energy resources brings significant spatiotemporal uncertainties to active distribution networks. State estimation errors can distort the dispatch center's perception of node voltage and branch power flow, making it unable to accurately identify potential equipment overloads or voltage exceedance risks, potentially leading to delayed or incorrect control decisions. Furthermore, errors weaken the system's observability; relying on measurements with large errors further amplifies risks, resulting in insufficient understanding of the grid's true state by operators, thus reducing the system's resilience to sudden disturbances and increasing operational risks. Therefore, accurate distribution network state estimation technology is crucial for ensuring the safe, stable, and economical operation of the power grid.

[0003] For high-proportion active power distribution networks, existing state estimation and prediction methods still have many shortcomings. First, compared with the classic weighted least squares (WLS) method, dynamic state estimation methods based on Kalman filtering, although considering time correlation, cannot accurately characterize the complex nonlinear dynamics under high-proportion renewable energy access with their linear or quasi-linear state transition matrices. They are prone to failure or even divergence under drastic fluctuations. Although the WLS method has good numerical stability, it heavily depends on the quality of real-time measurement data. However, the power distribution network has long suffered from low measurement coverage and sparse measurements, so it is urgent to introduce high-quality pseudo-measurements to supplement it. Second, traditional prediction methods such as Long Short-Term Memory (LSTM) networks and Recurrent Neural Networks (RNNs) have significant limitations in generating pseudo-measurements because they only focus on the time dimension and ignore the spatial correlation between load and distributed power sources. This leads to excessively large pseudo-measurement errors. If these pseudo-measurements are directly used as input to WLS, it will amplify the estimation error and may even prevent the equation system from converging. Finally, if existing data-driven models only aim to minimize prediction error during training, their loss functions lack inherent physical constraints, leading to prediction results that often violate basic electrical laws and lack physical interpretability in the spatial dimension.

[0004] In summary, traditional methods have many shortcomings when dealing with high-proportion active distribution networks. Therefore, it is necessary to study a method that can significantly improve the physical consistency, reliability and interpretability of generated pseudo-measurements, thereby realizing distribution network state estimation. Summary of the Invention

[0005] This patent proposes a method and system for power distribution network state estimation that integrates physical constraints and graph attention. First, the method extracts spatial features of the power distribution network using a graph convolutional neural network (GCN) to explicitly mine topological relationships and identify spatial distances and higher-order dependencies between nodes. Second, it utilizes a Transformer model to capture time-series patterns in massive historical data, dynamically measuring the importance of historical features to the current prediction target. Simultaneously, a differentiable physical layer is constructed to add physical constraints, embedding Kirchhoff's laws of the power distribution network into the loss function as differentiable penalty terms, achieving closed-loop calibration of data fitting and physical laws. Through the above methods, pseudo-measurements with high fidelity and physical interpretability are generated. These pseudo-measurements are then fused with limited actual measurements, and high-precision state estimation is performed using WLS. Finally, simulation examples are used to evaluate its accuracy and feasibility in multiple scenarios, verifying the effectiveness of the proposed model and algorithm.

[0006] A distribution network state estimation method integrating physical constraints and graph attention includes the following steps:

[0007] S1. Abstract the physical topology of the distribution network into a non-Euclidean space graph structure, extract the historical voltage amplitude and phase angle data of each node, and construct a historical feature input matrix that characterizes the evolution of electrical state at multiple time steps.

[0008] S2. Using a graph convolutional neural network (GCN) with Chebyshev polynomial approximation, the historical feature input matrix is ​​subjected to spectral domain convolution processing to explicitly mine the electrical coupling correlation between nodes and extract the high-order topological spatial feature matrix of the distribution network.

[0009] S3. Input the extracted spatial feature matrix into the Transformer module, use the multi-head self-attention mechanism to dynamically capture the nonlinear evolution dependence of node states over a long time span, and decode to generate the initial pseudo-measurement values ​​of distribution network node states.

[0010] S4. Construct a differentiable physical layer based on the power flow equation of the distribution network, substitute the initial pseudo-measurement value into Kirchhoff's law to calculate the node power imbalance, form a physical-driven penalty term and perform back-propagation closed-loop correction in conjunction with data-driven loss, and output a high-fidelity pseudo-measurement value that satisfies electrical laws.

[0011] S5. The high-fidelity pseudo-measurement values ​​are fused with the sparse SCADA measurement data collected in real time from the distribution network to construct a high-dimensional hybrid measurement vector. The weighted least squares objective function is solved based on the Newton-Raphson iterative method to achieve high-precision estimation of the distribution network system state.

[0012] Furthermore, in step S4, a differentiable physical layer based on the power flow equations of the distribution network is constructed. The initial pseudo-measurement values ​​are substituted into Kirchhoff's laws to calculate the node power imbalance, forming a physical-driven penalty term. Combined with data-driven losses, backpropagation closed-loop correction is performed to output high-fidelity pseudo-measurement values ​​that satisfy electrical laws.

[0013] Derive nodes using the initial pseudo-measurement values ​​obtained in step S3. active power With reactive power ;

[0014] A physical drive loss function containing active / reactive power balance constraints is constructed based on the derived electrical quantities. The calculation process is as follows:

[0015] ;

[0016] In the formula, Represents the physics-driven loss function; Indicates the total number of nodes in the distribution network; and Representing nodes respectively Predicted active and reactive power; and Representing nodes respectively The actual active and reactive power; Represents the square of the L2 norm;

[0017] Building a fusion data-driven loss and physical drive loss Total loss function Backpropagation closed-loop correction is performed; where the total loss function is... for:

[0018] ;

[0019] In the formula, To balance the hyperparameters of data fitting and physical constraint penalty terms.

[0020] Furthermore, using the total loss function The method for performing backpropagation closed-loop correction is as follows:

[0021] Based on the total loss function, the trainable parameters in the graph convolutional network module and the Transformer module are jointly optimized: first, initial pseudo-measurement values ​​are obtained through forward computation, and the corresponding physical loss term is calculated by the differentiable physical layer; then, the data-driven loss term and the physical-driven loss term are weighted and summed to obtain the total loss function. Subsequently, the backpropagation algorithm was used to calculate the total loss function with respect to the set of parameters to be optimized. The gradient is calculated, and the parameters are iteratively updated according to the following formula:

[0022] ;

[0023] In the formula, This represents the set of parameters to be optimized in the graph convolutional network module and the Transformer module. Indicates the learning rate. Indicates the number of iterations;

[0024] After multiple rounds of training, the initial pseudo-measurements output in step S3 are subjected to physical consistency correction to obtain the node. High-fidelity voltage amplitude and high-fidelity voltage phase angle .

[0025] Furthermore, in step S2, a graph convolutional neural network (GCN) with Chebyshev polynomial approximation is used to perform spectral domain convolution processing on the historical feature input matrix to explicitly mine the electrical coupling correlation between nodes and extract the high-order topological spatial feature matrix of the distribution network. The specific method is as follows:

[0026] Construct the input feature set X of the graph convolutional neural network;

[0027] Construct an adjacency matrix A based on the topological connections of the distribution network; where, if there is an electrical connection between node i and node j, then A... ij =1; otherwise, A ij =0; Construct the degree matrix D based on the adjacency matrix A, where Based on this, construct the normalized graphical Laplace matrix L:

[0028] ;

[0029] In the formula, It is the identity matrix;

[0030] The convolution of the graph signal in the spectral domain can be represented as:

[0031] ;

[0032] In the formula, For the graph Laplace matrix eigenvector matrix, The corresponding eigenvalue diagonal matrix, Here, represents the spectral convolution kernel function. To reduce the computational complexity of spectral convolution, a Chebyshev polynomial is used to approximate the expansion of the spectral convolution kernel.

[0033] ;

[0034] In the formula, The parameters to be learned For Chebyshev polynomials, This is the scaled Laplace matrix. For matrix The largest eigenvalue;

[0035] To further preserve the node's own characteristic information, self-connections are introduced into the adjacency matrix, resulting in an adjacency matrix with self-connections:

[0036] ;

[0037] In the formula, It is an identity matrix, representing that each node is connected to itself; This is the adjacency matrix after adding self-connections. Further definition... The degree matrix is ,in:

[0038] ;

[0039] right After performing symmetric normalization, the normalized propagation matrix is ​​obtained. Therefore, the graph convolutional neural network... layer to the first The formula for the propagation and update of node features in a layer is expressed as follows:

[0040]

[0041] In the formula, Indicates the first The node feature matrix of the layer; Indicates the first Layer-learnable weight transformation matrix; This represents a non-linear activation function.

[0042] Furthermore, in step S3, the extracted spatial feature matrix is ​​input into the Transformer module, and a multi-head self-attention mechanism is used to dynamically capture the nonlinear evolution dependence of node states over a long time span. The method for decoding and generating the initial pseudo-measurements of distribution network node states is as follows:

[0043] The single-head attention weight matrix is ​​calculated using scaled dot products to dynamically measure the impact of historical features on the current state.

[0044] ;

[0045] In the formula, Indicates the first The output of each attention head; This represents the scaling dot product attention calculation function; Indicates the first A query matrix with attention heads; Indicates the first The key matrix of each attention head; Indicates the first A matrix of values ​​for each attention head; Key matrix Transpose of; This represents the relevance score matrix between the query matrix and the key matrix. Indicates the dimension of the key vector; Represents the normalization function;

[0046] The outputs of multiple attention heads are concatenated and subjected to a linear transformation to obtain the final output feature matrix. Based on the output feature matrix The initial pseudo-measurement value of the node state is obtained by forward computation through the output mapping layer, and its expression is:

[0047] ;

[0048] In the formula, The initial pseudo-measurement output vector representing the node state includes the predicted voltage magnitude and predicted voltage phase angle for each node; This represents the weight matrix of the output mapping layer; This represents the bias vector of the output mapping layer.

[0049] Furthermore, step S5 fuses the high-fidelity pseudo-measurement values ​​with the sparse SCADA measurement data collected in real time from the distribution network to construct a high-dimensional hybrid measurement vector. The method for achieving high-precision estimation of the distribution network system state by solving the weighted least squares objective function based on the Newton-Raphson iterative method is as follows:

[0050] The high-fidelity pseudo-measurement value generated in step S4 Real-time measurement values ​​obtained from sparse SCADA systems in the power distribution network Combining and constructing hybrid measurement equations:

[0051] ;

[0052] In the formula, Let be the system state vector. For nonlinear measurement functions of distribution networks, For measurement error, Here is the error covariance matrix;

[0053] With the goal of minimizing the weighted sum of squares of measurement residuals, the Newton-Raphson iterative method is used to solve the weighted least squares problem, and finally the optimal solution to the distribution network state estimation problem is obtained.

[0054] A distribution network state estimation system integrating physical constraints and graph attention, used to implement the method described above, includes:

[0055] The historical feature input matrix acquisition module is used to abstract the physical topology of the distribution network into a non-Euclidean space graph structure, extract the historical voltage amplitude and phase angle data of each node, and construct a historical feature input matrix that characterizes the evolution of electrical state at multiple time steps.

[0056] The high-order topology spatial feature matrix construction module of the distribution network is used to perform spectral domain convolution processing on the historical feature input matrix using a graph convolutional neural network (GCN) with Chebyshev polynomial approximation, to explicitly mine the electrical coupling correlation between nodes and extract the high-order topology spatial feature matrix of the distribution network.

[0057] The initial pseudo-measurement acquisition module is used to input the extracted spatial feature matrix into the Transformer module, and use the multi-head self-attention mechanism to dynamically capture the nonlinear evolution dependence of node states over a long time span, and decode and generate the initial pseudo-measurement values ​​of the distribution network node states.

[0058] The high-fidelity pseudo-measurement acquisition module is used to construct a differentiable physical layer based on the power flow equation of the distribution network. It substitutes the initial pseudo-measurement into Kirchhoff's laws to calculate the node power imbalance, forms a physical-driven penalty term, and performs backpropagation closed-loop correction in conjunction with data-driven losses, outputting high-fidelity pseudo-measurement that satisfies electrical laws.

[0059] The distribution network system state determination module is used to fuse the high-fidelity pseudo-measurement values ​​with the sparse SCADA measurement data collected in real time from the distribution network to construct a high-dimensional hybrid measurement vector. Based on the Newton-Raphson iterative method, the weighted least squares objective function is solved to achieve high-precision estimation of the distribution network system state.

[0060] A non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the distribution network state estimation method that integrates physical constraints and graph attention as described above.

[0061] An electronic device includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the program, implements the power distribution network state estimation method that integrates physical constraints and graph attention as described above.

[0062] The beneficial technical effects of this invention are as follows:

[0063] The distribution network state estimation method integrating physical constraints and graph attention provided by this invention has the following characteristics: By constructing a spatiotemporal feature extraction architecture based on GCN and Transformer modules, it effectively overcomes the defect of traditional pure time series models ignoring the spatial topological correlation of the distribution network, and achieves accurate capture of the complex nonlinear dynamic evolution law of high-proportion active distribution networks under drastic source-load fluctuations; By establishing a differentiable physical layer based on Kirchhoff's laws and Ohm's law, the inherent electrical physical laws of the distribution network are embedded as a penalty term into the model training closed loop, solving the pain point of traditional pure data-driven models where the prediction results violate basic electrical laws due to the lack of physical constraints, and significantly improving the physical consistency, reliability, and interpretability of generated pseudo-measurements; By proposing to integrate the generated high-fidelity pseudo-measurements with the finite and sparse real-time measurements of the distribution network, and substituting them into a weighted least squares framework for dynamic iterative solution of the Jacobian matrix, it effectively compensates for the low coverage of distribution network measurement equipment and the sparse data. The method significantly improves the numerical stability and final sensing accuracy of the state estimation process, addressing the insufficient observability of traditional dynamic state estimation methods. A comprehensive evaluation of the distribution network state estimation results is conducted using metrics such as mean square error (MSE), mean absolute percentage error (MAPE), and the average and maximum deviations of node voltage amplitude and phase angle. Compared with traditional dynamic state estimation methods and pure data prediction models without physical constraints, the proposed method achieves significant reductions in several core error metrics, demonstrating strong robustness and adaptability. In summary, the method not only improves the overall accuracy and physical reliability of high-penetration active distribution network state estimation, verifying the effectiveness and superiority of the "data-physical" dual-drive model in solving the problem of sparse distribution network measurements, but also proves that the proposed distribution network state estimation method, which integrates physical constraints and graph attention network-generated pseudo-measurements, has high practical engineering application value and significance for ensuring the safe, stable, and economical operation of smart grids. Attached Figure Description

[0064] Figure 1 A flowchart illustrating the distribution network state estimation method integrating physical constraints and graph attention provided in Embodiment 1 of the present invention;

[0065] Figure 2 This is a comparison of voltage amplitude using a multi-state estimation method based on the IEEE 33-node system provided in Embodiment 2 of the present invention.

[0066] Figure 3 This is a comparison of the voltage phase angle in the multi-state estimation method based on the IEEE 33-node system provided in Embodiment 2 of the present invention;

[0067] Figure 4 This is a comparison of voltage amplitude errors of different state estimation methods in the IEEE 33-node system provided in Embodiment 2 of the present invention;

[0068] Figure 5 This is a comparison of voltage phase angle errors of different state estimation methods in the IEEE 33-node system provided in Embodiment 2 of the present invention. Detailed Implementation

[0069] Example 1

[0070] This embodiment discloses a distribution network state estimation method that integrates physical constraints and graph attention. First, a graph structure is constructed based on the connection relationships between distribution network nodes and branches. Second, spatiotemporal features are extracted based on historical voltage amplitude and phase angle data. Third, a physical constraint loss term is constructed based on the power flow equations to perform closed-loop correction on pseudo-measurements. Finally, the corrected pseudo-measurement values ​​are fused with real-time measurement values, and the distribution network state estimation result is solved using the weighted least squares method. Specifically, the method includes the following steps:

[0071] S1. Abstract the physical topology of the distribution network into a non-Euclidean space graph structure, extract the historical voltage amplitude and phase angle data of each node, and construct a historical feature input matrix that characterizes the evolution of electrical state at multiple time steps.

[0072] S2. Using a graph convolutional neural network (GCN) with Chebyshev polynomial approximation, the historical feature input matrix is ​​subjected to spectral domain convolution processing to explicitly mine the electrical coupling correlation between nodes and extract the high-order topological spatial feature matrix of the distribution network.

[0073] S3. Input the extracted spatial feature matrix into the Transformer module, use the multi-head attention mechanism to dynamically capture the nonlinear evolution dependence of node states over a long time span, and decode to generate the initial pseudo-measurement values ​​of distribution network node states.

[0074] S4. Construct a differentiable physical layer based on the power flow equation of the distribution network, substitute the initial pseudo-measurement value into Kirchhoff's law to calculate the node power imbalance, form a physical-driven penalty term and perform back-propagation closed-loop correction in conjunction with data-driven loss, and output a high-fidelity pseudo-measurement value that satisfies electrical laws.

[0075] S5. The high-fidelity pseudo-measurement values ​​are fused with the sparse SCADA measurement data collected in real time from the distribution network to construct a high-dimensional hybrid measurement vector. The weighted least squares (WLS) objective function is solved based on the Newton-Raphson iterative method to achieve high-precision estimation of the distribution network system state.

[0076] In step S2, a graph convolutional neural network (GCN) based on Chebyshev polynomial approximation is used to perform spectral domain convolution processing on the historical feature input matrix to explicitly mine the electrical coupling correlation between nodes and extract the high-order topological spatial feature matrix of the distribution network. The specific method is as follows:

[0077] Construct the input feature set X of the graph convolutional neural network, for any time step... ,node eigenvectors Includes voltage amplitude With phase angle Two physical dimensions, multiple time window inputs are represented as follows:

[0078] ;

[0079] In the formula, This represents the length of the historical time window.

[0080] To achieve efficient aggregation of local neighborhood information of nodes in the distribution network topology, this method approximates the spectral graph convolution kernel with a first-order truncation using Chebyshev polynomials. An adjacency matrix A is constructed based on the topological connectivity of the distribution network; where, if there is an electrical connection between node i and node j, then A... ij =1; otherwise, A ij =0; further, construct the degree matrix D based on the adjacency matrix A, where Based on this, construct the normalized graphical Laplace matrix L:

[0081] ;

[0082] In the formula, It is an identity matrix.

[0083] The convolution of the graph signal in the spectral domain can be represented as:

[0084] ;

[0085] In the formula, For the graph Laplace matrix eigenvector matrix, The corresponding eigenvalue diagonal matrix, Let be the spectral convolution kernel function. To reduce the computational complexity of spectral convolution, the spectral convolution kernel is approximated using Chebyshev polynomials, i.e.:

[0086] ;

[0087] In the formula, The parameters to be learned For Chebyshev polynomials, This is the scaled Laplace matrix. For matrix The largest eigenvalue. When taking a first-order truncation approximation, let Then the above formula can be expressed as a weighted aggregation of the node's own features and its first-order neighborhood features.

[0088] To further preserve the node's own characteristic information, self-connections are introduced into the adjacency matrix, resulting in an adjacency matrix with self-connections:

[0089] ;

[0090] In the formula, It is an identity matrix, representing that each node is connected to itself; This is the adjacency matrix after adding self-connections. Further definition... The degree matrix is ,in:

[0091] ;

[0092] right After performing symmetric normalization, the normalized propagation matrix is ​​obtained. This is done to eliminate the influence of differences in node degrees on feature aggregation results and improve the numerical stability of model training. Therefore, the graph convolutional neural network... layer to the first The formula for the propagation and update of node features in a layer is expressed as follows:

[0093]

[0094] In the formula, Indicates the first The node feature matrix of the layer; Indicates the first Layer-learnable weight transformation matrix; This represents a nonlinear activation function. The above propagation process extracts spatial features reflecting the local topological coupling relationship between distribution network nodes by weighted fusion of the node's own features and the features of its neighboring nodes, and outputs a high-order topological spatial feature matrix for subsequent time series modeling.

[0095] In step S3, temporal features are deeply mapped using a multi-head attention mechanism, as detailed below:

[0096] Through three learnable linear projection matrices , will the The features output by the layered graphical convolutional neural network (GCN) are mapped to the first layer, second layer, and third layer, respectively. The query space, key space, and value space of each attention head:

[0097] ;

[0098] The single-head attention weight matrix is ​​calculated using scaled dot products to dynamically measure the impact of historical features on the current state.

[0099] ;

[0100] In the formula, Indicates the first The output of each attention head; This represents the scaling dot product attention calculation function; Indicates the first A query matrix of attention heads is used to represent the current attention needs for historical features; Indicates the first The key matrix of each attention head is used to represent the index information of the features matched at each historical moment; Indicates the first The value matrix of each attention head is used to carry the feature information that actually participates in the weighted summation; Key matrix Transpose of; This represents the relevance score matrix between the query matrix and the key matrix. The dimension of the key vector is used to scale the relevance score to avoid the inner product result being too large, which would cause the softmax function to enter the region of insufficient gradient, thereby improving the stability of model training. This represents the normalization function used to convert relevance scores into attention weights; finally, the attention weights are compared with the value matrix. Multiply to get the first... The output of each attention head.

[0101] The outputs of multiple attention heads are concatenated and subjected to a linear transformation to obtain the final output feature matrix. Based on the output feature matrix The initial pseudo-measurement value of the node state is obtained by forward computation through the output mapping layer, and its expression is:

[0102] ;

[0103] ;

[0104] In the formula, The initial pseudo-measurement output vector representing the node state includes the predicted voltage magnitude and predicted voltage phase angle for each node; This represents the weight matrix of the output mapping layer; This represents the bias vector of the output mapping layer; from this, the nodes are obtained. Initial predicted voltage amplitude Phase angle with initial predicted voltage .

[0105] Step S4 involves constructing a differentiable physical layer based on the power flow equations of the distribution network. The initial pseudo-measurements are substituted into Kirchhoff's laws to calculate node power imbalance and branch network losses, forming a physically driven penalty term. This term is then combined with data-driven losses for backpropagation closed-loop correction, outputting high-fidelity pseudo-measurements that satisfy electrical laws. The specific method is as follows:

[0106] Based on the initial pseudo-measurements (node ​​voltage magnitude and phase angle) from the Transformer decoder output, the node voltage magnitude and phase angle are derived according to Ohm's law and Kirchhoff's laws. active power With reactive power :

[0107] ;

[0108] ;

[0109] In the formula, Representative node The set of adjacent nodes, and Let be the real and imaginary parts of the nodal admittance matrix, respectively. and These represent the predicted voltage magnitude and predicted voltage phase angle of node i obtained through step S3, respectively. and These represent the nodes obtained through step S3. The predicted voltage amplitude and predicted voltage phase angle; This represents the phase angle difference between predicted node voltages; and These represent the nodes obtained by substituting the predicted voltage magnitude and predicted voltage phase angle into the power flow equation. The predicted active power injection and the predicted reactive power injection.

[0110] A physical drive loss function containing active / reactive power balance constraints is constructed based on the derived electrical quantities. The calculation process is as follows:

[0111] ;

[0112] In the formula, Represents the physics-driven loss function; Indicates the total number of nodes in the distribution network; and Representing nodes respectively Predicted active and reactive power; and Representing nodes respectively The actual active and reactive power; The squared L2 norm is used to characterize the deviation between the predicted and target values. The physical driving loss function simultaneously constrains the prediction errors of both active and reactive power at the nodes, ensuring that the model output satisfies the basic electrical and physical laws of the distribution network.

[0113] Building a fusion data-driven loss and physical drive loss Total loss function Perform backpropagation closed-loop correction:

[0114] ;

[0115] In the formula, To balance the hyperparameters of data fitting and physical constraint penalty terms.

[0116] Based on the total loss function, the trainable parameters in the graph convolutional network module and the Transformer module are jointly optimized. Specifically, initial pseudo-measurement values ​​are first obtained through forward computation, and the corresponding physical loss term is calculated by the differentiable physical layer; then, the data-driven loss term and the physical-driven loss term are weighted and summed to obtain the total loss function. Subsequently, the backpropagation algorithm was used to calculate the total loss function with respect to the set of parameters to be optimized. The gradient is calculated, and the parameters are iteratively updated according to the following formula:

[0117] ;

[0118] In the formula, This represents the set of parameters to be optimized in the graph convolutional network module and the Transformer module. Indicates the learning rate. Indicates the number of iterations.

[0119] After multiple rounds of training, the initial pseudo-measurements output in step S3 are subjected to physical consistency correction to obtain the node. High-fidelity voltage amplitude and high-fidelity voltage phase angle Furthermore, the high-fidelity voltage amplitudes and phase angles of all nodes are combined in a preset order to form the high-fidelity pseudo-measurement vector output in step S4. :

[0120] ;

[0121] in, This represents a high-fidelity pseudo-measurement vector generated after correction by a differentiable physical layer, used in step S5 to compare with the SCADA measurement values ​​acquired in real time from the distribution network. The measurements are then fused to construct a hybrid measurement vector.

[0122] Step S5 involves fusing the high-fidelity pseudo-measurement values ​​with the sparse SCADA measurement data collected in real time from the distribution network to construct a high-dimensional hybrid measurement vector. The method for achieving high-precision estimation of the distribution network system state by solving the weighted least squares (WLS) objective function based on the Newton-Raphson iterative method is as follows:

[0123] The high-fidelity pseudo-measurement value generated in step S4 Real-time measurement values ​​obtained from sparse SCADA systems in the power distribution network Combining and constructing hybrid measurement equations:

[0124] ;

[0125] In the formula, Let be the system state vector. For nonlinear measurement functions of distribution networks, For measurement error, Let be the error covariance matrix.

[0126] The objective function is to minimize the weighted sum of squares of measurement residuals. This paper employs the Newton-Raphson iterative method to solve the weighted least squares (WLS) problem. Represented as:

[0127] ;

[0128] By calculating the partial derivative matrix (Jacobi matrix) of the measurement function with respect to the state variables. The Newton-Raphson iterative equation for state updates is defined as follows:

[0129] ;

[0130] ;

[0131] Among them, superscript and These represent the sequence numbers of two adjacent iterations; For the first The state correction amount for the next iteration; For the first The state estimate for the next iteration; For the updated state based on the state correction amount The state estimate for the next iteration.

[0132] Update continuously according to the iterative process until the state correction value is reached. Less than the set convergence threshold The final output is the optimal solution to the state estimation problem.

[0133] Example 2

[0134] As an example, in this embodiment, based on the IEEE 33-node system, the distribution network state estimation is performed using the method provided in this invention, WLS (Weighted Least Squares), and LSTM-WLS (Long Short-Term Memory Network and Weighted Least Squares Joint State Estimation Method), respectively. The comparison results are as follows: Figure 2 , 3 As shown in Figures 4 and 5, it can be seen from the figures that compared with the WLS method and the LSTM-WLS method, the estimated results of the node voltage amplitude and voltage phase angle obtained by the method of the present invention are closer to the true values ​​as a whole, and the amplitude error and phase angle error at each node are smaller. This indicates that the method of the present invention can more accurately track the changes in the distribution network state and has higher estimation accuracy and better robustness.

[0135] In addition, a comparison table of the quantization performance of different state estimation methods for voltage amplitude and voltage phase angle under various error evaluation indicators is provided, as shown in Tables 1 and 2. The tables show that the method of this invention outperforms the WLS and LSTM-WLS methods in all error indicators for voltage amplitude and voltage phase angle. Specifically, in terms of voltage amplitude, the RMSE is reduced by approximately 85.42% and 82.09% compared to the WLS and LSTM-WLS methods, respectively. In terms of voltage phase angle, compared to the WLS method, the RMSE and MAPE of the method of this invention are reduced by approximately 69.82% and 20.374%, respectively; compared to the LSTM-WLS method, the RMSE and MAPE are reduced by approximately 23.57% and 7.803%, respectively. This demonstrates that the method of this invention can significantly reduce state estimation errors and improve the accuracy of distribution network state estimation results.

[0136] RMSE represents the root mean square error, which characterizes the overall dispersion of the deviation between the estimated value and the true value; MAPE represents the mean absolute percentage error, which characterizes the average percentage deviation of the estimated value from the true value.

[0137] Table 1 Comparison of Voltage Amplitude Quantization Performance of Different State Estimation Methods under Various Error Evaluation Indicators

[0138] WLS 0.004853369 0.357996912 0.003688342 0.009755192 LSTM-WLS 0.00395197 0.297938899 0.003071139 0.008142022 Method of the present invention 0.00070763 0.054744679 0.000563399 0.001311791

[0139] Table 2 Comparison of Voltage Phase Angle Quantization Performance of Different State Estimation Methods under Various Error Evaluation Indicators

[0140] WLS 0.126819844 32.68040138 0.076464902 0.281050393 LSTM-WLS 0.050081472 20.10975519 0.041847041 0.086690197 Method of the present invention 0.038275267 12.30653468 0.02855309 0.07455347

[0141] Example 3

[0142] This embodiment provides a distribution network state estimation system that integrates physical constraints and graph attention, used to implement the method described in Embodiment 1, including:

[0143] The historical feature input matrix acquisition module is used to abstract the physical topology of the distribution network into a non-Euclidean space graph structure, extract the historical voltage amplitude and phase angle data of each node, and construct a historical feature input matrix that characterizes the evolution of electrical state at multiple time steps.

[0144] The high-order topology spatial feature matrix construction module of the distribution network is used to perform spectral domain convolution processing on the historical feature input matrix using a graph convolutional neural network (GCN) with Chebyshev polynomial approximation, to explicitly mine the electrical coupling correlation between nodes and extract the high-order topology spatial feature matrix of the distribution network.

[0145] The initial pseudo-measurement acquisition module is used to input the extracted spatial feature matrix into the Transformer module, and use the multi-head self-attention mechanism to dynamically capture the nonlinear evolution dependence of node states over a long time span, and decode and generate the initial pseudo-measurement values ​​of the distribution network node states.

[0146] The high-fidelity pseudo-measurement acquisition module is used to construct a differentiable physical layer based on the power flow equation of the distribution network. It substitutes the initial pseudo-measurement into Kirchhoff's laws to calculate the node power imbalance, forms a physical-driven penalty term, and performs backpropagation closed-loop correction in conjunction with data-driven losses, outputting high-fidelity pseudo-measurement that satisfies electrical laws.

[0147] The distribution network system state determination module is used to fuse the high-fidelity pseudo-measurement values ​​with the sparse SCADA measurement data collected in real time from the distribution network to construct a high-dimensional hybrid measurement vector. Based on the Newton-Raphson iterative method, the weighted least squares objective function is solved to achieve high-precision estimation of the distribution network system state.

[0148] Furthermore, the present invention adopts the following technical solution:

[0149] A non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the distribution network state estimation method that integrates physical constraints and graph attention as described above.

[0150] Furthermore, the present invention adopts the following technical solution:

[0151] An electronic device includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the program, implements the power distribution network state estimation method that integrates physical constraints and graph attention as described above.

[0152] From the above description of the embodiments, those skilled in the art will clearly understand that the facilities of the present invention can be implemented using software plus necessary general-purpose hardware platforms. Embodiments of the present invention can be implemented using existing processors, or by dedicated processors used for this or other purposes for suitable systems, or by hardwired systems. Embodiments of the present invention also include non-transitory computer-readable storage media, comprising machine-readable media for carrying or having machine-executable instructions or data structures stored thereon; such machine-readable media can be any available medium accessible by a general-purpose or special-purpose computer or other machine with a processor. For example, such machine-readable media can include RAM, ROM, EPROM, EEPROM, CD-ROM or other optical disc storage, disk storage or other magnetic storage devices, or any other medium that can be used to carry or store the required program code in the form of machine-executable instructions or data structures and is accessible by a general-purpose or special-purpose computer or other machine with a processor. When information is transmitted or provided to a machine via a network or other communication connection (hardwired, wireless, or a combination of hardwired and wireless), that connection is also considered a machine-readable medium.

[0153] The technical solution of the present invention has been described above with reference to the preferred embodiments shown in the accompanying drawings. However, it will be readily understood by those skilled in the art that the scope of protection of the present invention is obviously not limited to these specific embodiments. Without departing from the principles of the present invention, those skilled in the art can make equivalent changes or substitutions to the relevant technical features, and the technical solutions after such changes or substitutions will all fall within the scope of protection of the present invention.

Claims

1. A power distribution network state estimation method that fuses physical constraints with graph attention, characterized in that, Includes the following steps: S1. Abstract the physical topology of the distribution network into a non-Euclidean space graph structure, extract the historical voltage amplitude and phase angle data of each node, and construct a historical feature input matrix that characterizes the evolution of electrical state at multiple time steps. S2. Using a graph convolutional neural network (GCN) with Chebyshev polynomial approximation, the historical feature input matrix is ​​subjected to spectral domain convolution processing to explicitly mine the electrical coupling correlation between nodes and extract the high-order topological spatial feature matrix of the distribution network. S3. Input the extracted spatial feature matrix into the Transformer module, use the multi-head self-attention mechanism to dynamically capture the nonlinear evolution dependence of node states over a long time span, and decode to generate the initial pseudo-measurement values ​​of distribution network node states. S4. Construct a differentiable physical layer based on the power flow equation of the distribution network, substitute the initial pseudo-measurement value into Kirchhoff's law to calculate the node power imbalance, form a physical-driven penalty term and perform back-propagation closed-loop correction in conjunction with data-driven loss, and output a high-fidelity pseudo-measurement value that satisfies electrical laws. S5. The high-fidelity pseudo-measurement values ​​are fused with the sparse SCADA measurement data collected in real time from the distribution network to construct a high-dimensional hybrid measurement vector. The weighted least squares objective function is solved based on the Newton-Raphson iterative method to achieve high-precision estimation of the distribution network system state.

2. The power grid state estimation method fusing physical constraints and graph attention according to claim 1, wherein: In step S4, a differentiable physical layer based on the power flow equations of the distribution network is constructed. The initial pseudo-measurement values ​​are substituted into Kirchhoff's laws to calculate the node power imbalance, forming a physical-driven penalty term. Combined with data-driven losses, backpropagation closed-loop correction is performed to output high-fidelity pseudo-measurement values ​​that satisfy electrical laws. Derive nodes using the initial pseudo-measurement values ​​obtained in step S3. active power With reactive power ; A physical drive loss function containing active / reactive power balance constraints is constructed based on the derived electrical quantities. The calculation process is as follows: ; In the formula, Represents the physics-driven loss function; Indicates the total number of nodes in the distribution network; and Representing nodes respectively Predicted active and reactive power; and Representing nodes respectively The actual active and reactive power; Represents the square of the L2 norm; Building a fusion data-driven loss and physical drive loss Total loss function Backpropagation closed-loop correction is performed; where the total loss function is... for: ; In the formula, To balance the hyperparameters of data fitting and physical constraint penalty terms.

3. The distribution network state estimation method integrating physical constraints and graph attention as described in claim 2, characterized in that: Using the total loss function The method for performing backpropagation closed-loop correction is as follows: Based on the total loss function, the trainable parameters in the graph convolutional network module and the Transformer module are jointly optimized: first, initial pseudo-measurement values ​​are obtained through forward computation, and the corresponding physical loss term is calculated by the differentiable physical layer; then, the data-driven loss term and the physical-driven loss term are weighted and summed to obtain the total loss function. Subsequently, the backpropagation algorithm was used to calculate the total loss function with respect to the set of parameters to be optimized. The gradient is calculated, and the parameters are iteratively updated according to the following formula: ; In the formula, This represents the set of parameters to be optimized in the graph convolutional network module and the Transformer module. Indicates the learning rate. Indicates the number of iterations; After multiple rounds of training, the initial pseudo-measurements output in step S3 are subjected to physical consistency correction to obtain the node. High-fidelity voltage amplitude and high-fidelity voltage phase angle .

4. The distribution network state estimation method integrating physical constraints and graph attention as described in claim 1, characterized in that: In step S2, a graph convolutional neural network (GCN) based on Chebyshev polynomial approximation is used to perform spectral domain convolution processing on the historical feature input matrix to explicitly mine the electrical coupling correlation between nodes and extract the high-order topological spatial feature matrix of the distribution network. The specific method is as follows: Construct the input feature set X of the graph convolutional neural network; Construct an adjacency matrix A based on the topological connections of the distribution network; where, if there is an electrical connection between node i and node j, then A... ij =1; otherwise, A ij =0; Construct the degree matrix D based on the adjacency matrix A, where Based on this, construct the normalized graphical Laplace matrix L: ; In the formula, It is the identity matrix; The convolution of the graph signal in the spectral domain can be represented as: ; In the formula, For the graph Laplace matrix eigenvector matrix, The corresponding eigenvalue diagonal matrix, Here, represents the spectral convolution kernel function. To reduce the computational complexity of spectral convolution, a Chebyshev polynomial is used to approximate the expansion of the spectral convolution kernel. ; In the formula, The parameters to be learned For Chebyshev polynomials, This is the scaled Laplace matrix. For matrix The largest eigenvalue; To further preserve the node's own characteristic information, self-connections are introduced into the adjacency matrix, resulting in an adjacency matrix with self-connections: ; In the formula, It is an identity matrix, representing that each node is connected to itself; This is the adjacency matrix after adding self-connections. Further definition... The degree matrix is ,in: ; right After performing symmetric normalization, the normalized propagation matrix is ​​obtained. Therefore, the graph convolutional neural network... layer to the first The formula for the propagation and update of node features in a layer is expressed as follows: In the formula, Indicates the first The node feature matrix of the layer; Indicates the first Layer-learnable weight transformation matrix; This represents a non-linear activation function.

5. The distribution network state estimation method integrating physical constraints and graph attention as described in claim 1, characterized in that: In step S3, the extracted spatial feature matrix is ​​input into the Transformer module. A multi-head self-attention mechanism is used to dynamically capture the nonlinear evolution dependence of node states over a long time span. The method for decoding and generating the initial pseudo-measurements of distribution network node states is as follows: The single-head attention weight matrix is ​​calculated using scaled dot products to dynamically measure the impact of historical features on the current state. ; In the formula, Indicates the first The output of each attention head; This represents the scaling dot product attention calculation function; Indicates the first A query matrix with attention heads; Indicates the first The key matrix of each attention head; Indicates the first A matrix of values ​​for each attention head; Key matrix Transpose of; This represents the relevance score matrix between the query matrix and the key matrix. Indicates the dimension of the key vector; Represents the normalization function; The outputs of multiple attention heads are concatenated and subjected to a linear transformation to obtain the final output feature matrix. Based on the output feature matrix The initial pseudo-measurement value of the node state is obtained by forward computation through the output mapping layer, and its expression is: ; In the formula, The initial pseudo-measurement output vector representing the node state includes the predicted voltage magnitude and predicted voltage phase angle for each node; This represents the weight matrix of the output mapping layer; This represents the bias vector of the output mapping layer.

6. The distribution network state estimation method integrating physical constraints and graph attention as described in claim 1, characterized in that: Step S5 involves fusing the high-fidelity pseudo-measurement values ​​with the sparse SCADA measurement data collected in real time from the distribution network to construct a high-dimensional hybrid measurement vector. The method for achieving high-precision estimation of the distribution network system state by solving the weighted least squares objective function based on the Newton-Raphson iterative method is as follows: The high-fidelity pseudo-measurement value generated in step S4 Real-time measurement values ​​obtained from sparse SCADA systems in the power distribution network Combining and constructing hybrid measurement equations: ; In the formula, Let be the system state vector. For distribution network nonlinear measurement functions, For measurement error, Here is the error covariance matrix; With the goal of minimizing the weighted sum of squares of measurement residuals, the Newton-Raphson iterative method is used to solve the weighted least squares problem, and finally the optimal solution to the distribution network state estimation problem is obtained.

7. A distribution network state estimation system integrating physical constraints and graph attention, used to implement the method of any one of claims 1-6, characterized in that, include: The historical feature input matrix acquisition module is used to abstract the physical topology of the distribution network into a non-Euclidean space graph structure, extract the historical voltage amplitude and phase angle data of each node, and construct a historical feature input matrix that characterizes the evolution of electrical state at multiple time steps. The high-order topology spatial feature matrix construction module of the distribution network is used to perform spectral domain convolution processing on the historical feature input matrix using a graph convolutional neural network (GCN) with Chebyshev polynomial approximation, to explicitly mine the electrical coupling correlation between nodes and extract the high-order topology spatial feature matrix of the distribution network. The initial pseudo-measurement acquisition module is used to input the extracted spatial feature matrix into the Transformer module, and use the multi-head self-attention mechanism to dynamically capture the nonlinear evolution dependence of node states over a long time span, and decode and generate the initial pseudo-measurement values ​​of the distribution network node states. The high-fidelity pseudo-measurement acquisition module is used to construct a differentiable physical layer based on the power flow equation of the distribution network. It substitutes the initial pseudo-measurement into Kirchhoff's laws to calculate the node power imbalance, forms a physical-driven penalty term, and performs backpropagation closed-loop correction in conjunction with data-driven losses, outputting high-fidelity pseudo-measurement that satisfies electrical laws. The distribution network system state determination module is used to fuse the high-fidelity pseudo-measurement values ​​with the sparse SCADA measurement data collected in real time from the distribution network to construct a high-dimensional hybrid measurement vector. Based on the Newton-Raphson iterative method, the weighted least squares objective function is solved to achieve high-precision estimation of the distribution network system state.

8. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that, When executed by a processor, the computer program implements the distribution network state estimation method that integrates physical constraints and graph attention as described in any one of claims 1 to 6.

9. An electronic device 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 program, it implements the power distribution network state estimation method that integrates physical constraints and graph attention as described in any one of claims 1 to 6.