Disturbance analysis method, device and equipment for power grid road network coupling system
By constructing a dynamic hypergraph structure and a spatiotemporal Transformer network, and combining the power flow and traffic flow dynamics equations, the problems of capturing dynamic changes and model forgetting in the power grid-road network coupling system are solved, and efficient disturbance analysis and decision support are achieved.
Patent Information
- Application Number
- CN202510761569.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-09
- Publication Date
- 2025-09-05
AI Technical Summary
Existing power grid-road network coupling system analysis methods cannot effectively capture dynamic change characteristics, and periodic retraining leads to large consumption of computing resources and serious model forgetting problems. They lack the ability to explain the system coupling mechanism, affecting the credibility of decision-making.
A dynamic hypergraph structure is constructed, and node adaptive weight allocation is performed through a multi-head attention mechanism. The power flow equation and traffic flow dynamics equation are combined as physical constraints. The PINN network is used for training, and a spatiotemporal Transformer network is constructed for disturbance analysis to achieve joint prediction and disturbance analysis of the power grid and road network status.
It achieves dynamic adaptability and physical interpretability of the power grid-road network coupling system, improves the decision-making credibility of the model, provides reliable technical support for real-time optimization and key node diagnosis, and avoids the computing resource consumption and catastrophic forgetting problems caused by periodic retraining.
Smart Images

Figure CN120597716A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of power grid-road network coupling system analysis, and in particular relates to a disturbance analysis method, device and equipment for a power grid-road network coupling system. Background Art
[0002] With the rapid development of new energy vehicles, charging stations, as key nodes connecting transportation and power grids, have formed a typical time-varying coupled network system. This system not only exhibits time-varying characteristics such as fluctuating traffic flow, fluctuating charging demand, and dependence on power load, but also features a network topology that continuously evolves with the charging stations. The coupling relationship between these systems manifests itself in the mutual influence and multi-level feedback between traffic flow, charging demand, and grid stability. This complex coupling relationship leads to a series of practical problems: concentrated charging demand caused by traffic congestion causes local grid overloads, while grid capacity limitations in turn affect charging efficiency and exacerbate traffic congestion. The mismatch between charging station layout and traffic flow distribution further exacerbates the problem of low system efficiency, impacting not only service quality and user experience but also potentially threatening the safe and stable operation of the grid.
[0003] To analyze and solve the above problems, existing technologies have proposed a variety of graph learning-based methods to model and analyze power grid-road network coupling systems. However, traditional graph learning methods mainly use static graph models or periodic retraining strategies, which have significant limitations. Static graph models cannot effectively capture the dynamic changes of the system. If the dynamic changes of the system are to be captured, periodic retraining is required. Periodic retraining not only consumes a lot of computing resources but is also prone to catastrophic forgetting, resulting in insufficient model retention of historical knowledge. In addition, these methods are mostly black-box models that lack the ability to explain the system coupling mechanism, which affects the model's credibility in critical decision-making. Summary of the Invention
[0004] In order to solve the above problems, the present invention provides a disturbance analysis method, device and equipment for a power grid-network coupling system.
[0005] In order to achieve the above object, the present invention provides the following technical solutions: A disturbance analysis method for a power grid-road network coupling system, the method comprising: Acquire historical data of power grid nodes, road network nodes, and charging station nodes, and extract time-varying features of the historical data; Construct a power grid subgraph with substations as nodes and transmission lines as edges, and a road network subgraph with charging stations as nodes and roads as edges. Based on the geographic location, functional relevance, and temporal evolution characteristics of the nodes in the power grid and road network subgraphs, construct cross-network coupling hyperedges between the power grid and road network subgraphs to obtain a dynamic hypergraph structure. Adaptive weights are then assigned to different types of nodes in the dynamic hypergraph structure using time-varying features based on a multi-head attention mechanism. The power flow equation and traffic flow dynamics equation are used as physical constraints, and an error loss function is constructed based on historical data. The PINN network is trained based on the physical constraints and the error loss function to obtain a power grid-road network coupling data prediction model. Mapping the topological relationship of the dynamic hypergraph structure into an attention association matrix, determining delayed attention based on the temporal evolution characteristics of the dynamic hypergraph structure, determining a data propagation matrix between the power grid and the road network based on the output of the power grid-road network coupling data prediction model, constructing a spatiotemporal transformer network based on the attention association matrix, delayed attention, and data propagation matrix, and training the spatiotemporal transformer network to obtain a disturbance analysis model for performing disturbance analysis on each node; The data of each node is obtained and input into the disturbance analysis model to obtain the disturbance analysis results of each node.
[0006] Optionally, the adaptive weight allocation of different types of nodes in the dynamic hypergraph structure based on the multi-head attention mechanism through time-varying features includes: Construct a charging demand attention module, which includes an attention score , the formula is: ; in, 、 、 are query matrix, key matrix and value matrix respectively, is the dimension of the attention head; Construct a traffic flow attention module, which includes an attention score , the formula is: ; in, The mask matrix is generated based on the time-varying characteristics of road network traffic flow; Construct a charging mode attention module, which includes an attention score , the formula is: ; in, The mask matrix generated based on the time-varying characteristics of charging behavior; Construct a time-series-aware dynamic weight fusion mechanism, where the weight update formula is: ; ; ; in, Represents three different attention modules, is the weight coefficient, β is the time series smoothing factor, for t The weight evaluation value at the moment, for t Attention effect score at each moment, To score historical performance, MLP is a multi-layer perceptron; The output of each attention module is temporally weighted fused, and the formula is: ; in, for t Attention scores of different dimensions at the moment, express The comprehensive relationship representation vector of the multi-dimensional node relationship at each moment includes the characteristic relationships of the three dimensions of charging demand, traffic flow, and charging mode.
[0007] Optionally, the spatiotemporal transformer network includes a delay perception module, a structural perturbation analysis module, an attribute perturbation analysis module, and a cross-domain propagation module; and constructing the spatiotemporal transformer network based on the attention association matrix, the delayed attention, and the data propagation matrix includes: A delay perception module is constructed by the delayed attention, and the delay perception module identifies the disturbance impact under different time steps τ by calculating the delayed attention score D(τ); The specific formula of the delayed attention score is: ; in, is the delay mask matrix; The structural perturbation analysis module and the attribute perturbation analysis module are constructed by the attention association matrix. The hyperedge evolution rate of the charging station network is calculated by the structural perturbation analysis module. The formula is: ; Where E(t) represents the hyperedge set at time t, including the grid connection relationship, transportation connection relationship and charging station service range; The structural disturbance analysis module is used to evaluate the degree of change in the connection mode of charging station nodes. , the formula is: ; in, represents the connectivity of charging station node i at time t; The attribute disturbance analysis module calculates the delay The characteristic perturbation intensity is: ; Among them, X(t) is the node feature matrix at time t, including charging load, traffic flow and other characteristics; The attribute disturbance analysis module is used to analyze the timing deviation of the feature distribution. The formula is: ; in, represents the KL divergence, Represents feature distribution; The cross-domain propagation module is constructed by the data propagation matrix, and the cross-domain propagation module calculates the cross-domain disturbance propagation matrix , quantifying the intensity and direction of disturbance propagation between the power system and the transportation system; the calculation formula of the disturbance propagation matrix is: ; in, and are the hidden states of the power system and the transportation system, respectively, containing the operating status information of each system, is the propagation weight matrix, is the activation function.
[0008] Optionally, after obtaining the disturbance analysis model, the disturbance analysis model is further updated, including: Calculate the comprehensive disturbance index: ; in, 、 、 is the weight coefficient; Adaptively adjust the learning rate according to the degree of disturbance: ; in, is the initial learning rate, is the attenuation coefficient.
[0009] Optionally, the power flow equation and the traffic flow dynamics equation are used as physical constraints, and an error loss function is constructed based on historical data; and the PINN network is trained based on the physical constraints and the error loss function to obtain a power grid-road network coupling data prediction model, including: Based on the historical data, calculate the error between the model prediction result and the actual value As the error loss function, and the degree of violation of physical constraints is determined by physical constraints ; When the error is greater than the preset threshold When , the parameters of the PINN network are updated by the gradient descent method , the formula for the update process is: ; in is the adaptive learning rate, is the balance factor; the update process is repeated until the error is less than or equal to the preset threshold Or when the maximum number of iterations is reached and the degree of violation of the physical constraints of the output results reaches the preset conditions, the power grid-road network coupling data prediction model is obtained.
[0010] Optionally, obtaining historical data of each node in the power grid-road network coupling system includes: Based on the preset sampling time interval within the preset historical time window , obtain the power data of the grid node and traffic data of road network nodes ;in, , is the number of sampling points, t 0 is the start sampling time; through the formula: , standardize the power data of power grid nodes; among them, is the average power in the historical time window, is the power standard deviation within the historical time window; By formula: , standardize the traffic data of road network nodes; among them, is the average flow rate in the historical time window, is the standard deviation of the flow rate within the historical time window.
[0011] A disturbance analysis device for a power grid-network coupling system, comprising: An acquisition module is used to acquire historical data of power grid nodes, road network nodes, and charging station nodes, and extract time-varying features of the historical data; A construction module is used to construct a power grid subgraph with substations as nodes and transmission lines as edges, and a road network subgraph with charging stations as nodes and roads as edges; based on the geographical location relationship, functional correlation and temporal evolution characteristics of the power grid subgraph nodes and the road network subgraph nodes, a cross-network coupling hyperedge between the power grid subgraph and the road network subgraph is constructed to obtain a dynamic hypergraph structure, and based on the multi-head attention mechanism, adaptive weight allocation is performed on different types of nodes in the dynamic hypergraph structure through time-varying characteristics; the power flow equation and the traffic flow dynamics equation are used as physical constraints, and an error loss function is constructed based on historical data; the PINN network is trained based on the physical constraints and the error loss function to obtain a power grid-road network coupling data prediction model; the topological relationship of the dynamic hypergraph structure is mapped into an attention association matrix, the delayed attention is determined according to the temporal evolution characteristics of the dynamic hypergraph structure, the data propagation matrix between the power grid and the road network is determined based on the output of the power grid-road network coupling data prediction model, a spatiotemporal transformer network is constructed based on the attention association matrix, the delayed attention and the data propagation matrix, the spatiotemporal transformer network is trained to obtain a disturbance analysis model for performing disturbance analysis on each node; The analysis module is used to obtain the data of each current node and input it into the disturbance analysis model to obtain the disturbance analysis results of each node.
[0012] A computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the disturbance analysis method of the power grid-network coupling system is implemented.
[0013] A computer device includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, the disturbance analysis method for a power grid-network coupled system is implemented.
[0014] The disturbance analysis method of a power grid-network coupling system provided by the present invention has the following beneficial effects: This approach, through a deep learning framework that integrates a dynamic hypergraph structure with physical information, effectively addresses the limitations of traditional static graph models and periodic retraining strategies. First, by extracting the historical time-varying characteristics of power grid, road network, and charging station nodes, a dynamic hypergraph structure is constructed. A multi-head attention mechanism is then used to adaptively assign node weights, capturing system dynamics in real time and avoiding the computational resource consumption and catastrophic forgetting associated with periodic retraining. Second, the power flow equation and traffic flow dynamics equation are embedded as physical constraints within the PINN network, enhancing the model's interpretability of the coupling mechanism and improving decision-making confidence. Furthermore, the attention correlation matrix, delayed attention matrix, and data propagation matrix are integrated through a spatiotemporal Transformer network to achieve joint prediction and disturbance analysis of power grid and road network states. The resulting disturbance analysis model combines dynamic adaptability, physical interpretability, and computational efficiency, providing reliable technical support for real-time optimization and key node diagnosis of coupled power grid and road network systems. BRIEF DESCRIPTION OF THE DRAWINGS
[0015] To more clearly illustrate the embodiments of the present invention and its design, the following briefly introduces the drawings required for this embodiment. The drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be derived from these drawings without inventive effort.
[0016] Figure 1 The present invention is a flowchart of a disturbance analysis method for a power grid-network coupling system according to an exemplary embodiment of the present invention.
[0017] Figure 2 This is a block diagram of a disturbance analysis device for a power grid-network coupling system provided according to an exemplary embodiment of the present invention. DETAILED DESCRIPTION
[0018] In order to enable those skilled in the art to better understand the technical solution of the present invention and to be able to implement it, the present invention is described in detail below with reference to the accompanying drawings and specific embodiments. The following embodiments are only used to more clearly illustrate the technical solution of the present invention and are not intended to limit the scope of protection of the present invention.
[0019] The technical solutions provided by various embodiments of the present invention are described in detail below with reference to the accompanying drawings.
[0020] First, the present invention provides a disturbance analysis method for a power grid-network coupling system, specifically Figure 1 As shown, the following steps are included: S101. Obtain historical data of power grid nodes, road network nodes, and charging station nodes, and extract time-varying features of the historical data.
[0021] In one embodiment, the grid operation data within a preset historical time window can be obtained and time-space aligned and standardized, including electrical quantity data such as voltage, power, and frequency, traffic flow data, including traffic status data such as road flow, vehicle speed, and density, and charging station node attribute data, including operating data such as charging power, charging time, and charging demand.
[0022] For example, based on a preset sampling time interval within a preset historical time window , obtain the power data of the grid node and traffic data of road network nodes ;in, , is the number of sampling points, is the starting time point of the preset sampling time interval; through the formula: , standardize the power data of power grid nodes; among them, is the average power in the historical time window, is the standard deviation of power within the historical time window.
[0023] By formula: , standardize the traffic data of road network nodes; among them, is the average flow rate in the historical time window, is the standard deviation of the flow rate within the historical time window.
[0024] Calculate the spatiotemporal correlation matrix C between nodes, whose elements By formula: Calculated; among them, represents the normalized power of node i at time t, represents the normalized flow of node j at time t. When it is greater than the preset threshold θ, it is determined that there is a significant coupling relationship between node i and node j, which serves as the basis for constructing a cross-network coupling hyperedge.
[0025] Secondly, based on the preprocessed data of each node, the time-varying characteristics of the power grid nodes and road network nodes are extracted, including node load characteristics, time series variation characteristics and spatial distribution characteristics.
[0026] Specifically, first define the hypergraph node set ,in It is a collection of substation nodes, representing the power supply capacity and load distribution of the power grid; It is a collection of charging station nodes, including the capacity and usage status of charging facilities; It is a set of key road network nodes, reflecting the topological structure and flow characteristics of the traffic network. It includes static features (such as geographic location and rated capacity) and dynamic features (such as real-time load and traffic).
[0027] S102. Construct a dynamic hypergraph structure based on the power grid subgraph and the road network subgraph, and perform adaptive weight allocation on different types of nodes in the dynamic hypergraph structure based on a multi-head attention mechanism.
[0028] In this step, in order to accurately capture the dynamic characteristics of the power grid-road network coupling system, it is necessary to construct a multi-dimensional hypergraph structure for the transportation-power coupling system, including a node set, a hyperedge set and a weight matrix. The hyperedge set is constructed based on information of different dimensions, including geographic spatial relationships, traffic flow characteristics, power load characteristics, functional correlation of each node, and time-series evolution characteristics.
[0029] Specifically, a power grid subgraph with substations as nodes and transmission lines as edges, and a road network subgraph with charging stations as nodes and roads as edges are constructed; based on the geographical location relationship, functional correlation and temporal evolution characteristics of the power grid subgraph nodes and the road network subgraph nodes, a cross-network coupling hyperedge is constructed between the power grid subgraph and the road network subgraph to obtain a dynamic hypergraph structure, and based on the multi-head attention mechanism, adaptive weight allocation is performed on different types of nodes in the dynamic hypergraph structure through time-varying features.
[0030] In one embodiment, based on the pre-processed data of each node, the present invention designs a dynamic hypergraph construction method.
[0031] First, construct a hyperedge set that reflects the system coupling relationship Among them, the power supply exceeds the edge Represents the power supply relationship from the substation to the charging station, which is determined based on the power supply range and capacity constraints; spatial association hyperedge Based on the geographical distance and traffic accessibility between nodes, it reflects the spatial service range of the charging station; functional coupling hyperedge Generates functional associations of the system based on load correlation and usage pattern similarity between nodes.
[0032] In order to characterize the dynamic characteristics of hyperedges, a hyperedge weight update mechanism is designed. The power supply hyperedge weight is calculated in combination with the power flow sensitivity: ,in is the sensitivity of the charging load to the power injected by the source node. The spatial correlation hyperedge weight adopts the time-varying importance score based on historical data: ,in is the distance feature, is the speed characteristic, is the density feature.
[0033] In order to implement the dynamic update mechanism of the hypergraph structure, the node attribute update adopts the gated graph neural network: ,in For nodes The hyperedge update includes the generation of hyperedges based on the graph structure entropy: And hyperedge removal based on marginalized mutual information: ,in represents the change in structural entropy caused by adding hyperedges, Represents a hyperedge and the remaining graph structure Mutual information between them.
[0034] To match the spatiotemporal feature mining of dynamic hypergraphs, this paper designs a multi-head attention mechanism. This mechanism first builds a charging demand attention module, which calculates the charging demand correlation between nodes by analyzing the load variation characteristics of charging stations.
[0035] Specifically, a charging demand attention module is constructed, which includes a charging demand attention score , the specific formula is: . Among them, the query matrix Reflects the current node's charging demand status, key matrix Represents historical charging mode information, value matrix Contains charging load characteristics, is the dimension of the attention head, which is used to adjust the scale of the attention score.
[0036] Considering the significant impact of traffic flow on charging demand, the present invention also constructs a traffic flow attention module. This module introduces a mask matrix generated based on the traffic flow time series pattern. , which is used to highlight the impact of peak hours and frequently congested periods. The traffic flow attention module includes the traffic flow attention score , the specific formula is: .in, is the mask matrix generated based on the time-varying characteristics of traffic flow, The elements are obtained based on historical traffic flow data. When the traffic flow in a certain period is significantly higher than the average level, the corresponding mask value will be strengthened, thereby increasing the attention weight of that period.
[0037] In order to characterize the user's charging behavior pattern, the present invention constructs a charging pattern attention module. This module generates a charging behavior pattern mask matrix by analyzing the user's charging time, charging frequency, and charging time selection behavior characteristics. The charging mode attention module includes the attention score , the specific formula is: .in, The mask matrix generated based on the time-varying characteristics of charging behavior, The design takes into account the behavioral differences between weekdays and weekends, as well as the charging habits of different types of users (such as commuter vehicles and logistics vehicles).
[0038] To achieve dynamic fusion of multi-dimensional features and temporal dependency modeling, the present invention designs and constructs a temporal-aware dynamic weight fusion mechanism. This mechanism dynamically adjusts the weight coefficients of each attention module by evaluating its performance at different time periods.
[0039] Among them, the weight update adopts a time series smoothing strategy and realizes a smooth transition through the weight update formula, wherein the weight update formula is: ; ; ; in, Represents three different attention modules, is the time series smoothing factor, for t The weight evaluation value at the moment, for t Attention effect score at each moment, Score historical performance, MLP is a multi-layer perceptron.
[0040] The outputs of each attention module are temporally weighted fused, and the final node representation is obtained by weighted fusion. The formula is: ,in, is the attention score of different dimensions at time t, express The comprehensive representation vector of the time node, which contains the characteristic information of three dimensions: charging demand, traffic flow and charging mode, and the weight coefficient Normalized by softmax function: .
[0041] S103. Using the power flow equation and the traffic flow dynamics equation as physical constraints and constructing an error loss function based on historical data to train the PINN, a power grid-road network coupling data prediction model is obtained.
[0042] In this step, the power flow equation and traffic flow dynamics equation are used as physical constraints, and an error loss function is constructed based on historical data. The PINN network is trained based on the physical constraints and the error loss function to obtain a power grid-road network coupling data prediction model.
[0043] In one embodiment, based on the historical data, the error between the model prediction result and the actual value is calculated. As the error loss function, and the degree of violation of physical constraints is determined by physical constraints ; When the error is greater than the preset threshold When , the parameters of the PINN network are updated by the gradient descent method , the formula for the update process is: ;in is the adaptive learning rate, is the balance factor; the update process is repeated until the error is less than or equal to the preset threshold Or when the maximum number of iterations is reached and the degree of violation of the physical constraints of the output results reaches the preset conditions, the power grid-road network coupling data prediction model is obtained.
[0044] In this step, in order to ensure that the model prediction results meet the physical constraints, the present invention designs a constraint embedding mechanism based on the physical information neural network PINN.
[0045] The constraint embedding mechanism is implemented through a physical constraint module constructed by physical constraint conditions. The power system physical constraint module is constructed, including: Node power balance constraints: ; Branch flow constraints: ; in, is the injected power of node i, is the power generation power, is the load power, is the node voltage, is the admittance matrix element, is the phase angle, These constraints ensure that the prediction results conform to the physical operation laws of the power system.
[0046] Taking into account the dynamic characteristics of the traffic system, the present invention constructs a traffic system physical constraint module. This module includes flow conservation constraints: And the velocity-density relationship constraint: . Where ρ is the traffic density, v is the average speed, is the source and sink term (indicating the entry and exit of vehicles), is the free flow velocity, is the congestion density. Through these constraints, it is ensured that the predicted traffic flow distribution satisfies the traffic flow theory.
[0047] In order to characterize the coupling relationship between the power grid and the road network, the present invention designs a coupling system constraint module. This module first establishes the charging load constraint: ,in is the total load of charging station i, For charging efficiency, is the number of charging vehicles, is the rated charging power.
[0048] At the same time, build charging demand constraints: , the traffic flow density and the vehicle's remaining battery power These constraints enable a dynamic association between traffic flow and charging load.
[0049] Based on the above physical constraints, the present invention designs the PINN loss function: ; in, It is the data-driven loss, which is used to measure the deviation between the model prediction value and the actual observation value; The physical constraint loss includes the degree of violation of the physical constraints of the power system and the transportation system; To evaluate the satisfaction of cross-system constraints for coupling constraint loss; 、 、 is the corresponding weight coefficient. By minimizing this loss function, the unity of prediction accuracy and physical feasibility is achieved.
[0050] S104: constructing a spatiotemporal transformer network based on the dynamic hypergraph structure and the relationship prediction model, training the spatiotemporal transformer network, and obtaining a disturbance analysis model for performing disturbance analysis on each node.
[0051] In this step, to accurately analyze system disturbances, the present invention designs a disturbance analysis model based on a spatiotemporal transformer. Specifically, in this step, the topological relationships of the dynamic hypergraph structure are mapped into an attention association matrix. The delayed attention is determined based on the temporal evolution characteristics of the dynamic hypergraph structure. The data propagation matrix between the power grid and the road network is determined based on the output of the power grid-road network coupling data prediction model. A spatiotemporal transformer network is constructed based on this attention association matrix, delayed attention, and data propagation matrix. The spatiotemporal transformer network is trained to obtain a disturbance analysis model for performing disturbance analysis on each node.
[0052] In one embodiment, the spatiotemporal transformer network includes a delay perception module, a structural perturbation analysis module, an attribute perturbation analysis module, and a cross-domain propagation module. The delay perception module is constructed through the delayed attention, and the delay perception module identifies the perturbation impact under different time steps τ by calculating the delayed attention score D(τ). The specific formula of the delayed attention score is: ; in, Delay mask matrix, ensuring only the maximum delay is considered Internal disturbance effects.
[0053] The structural perturbation analysis module and the attribute perturbation analysis module are constructed through the attention association matrix. The hyperedge evolution rate of the charging station network is calculated through the structural perturbation analysis module. The formula is: ; Among them, E(t) represents the hyperedge set at time t, including the grid connection relationship, transportation connection relationship and charging station service range.
[0054] The structural disturbance analysis module is used to evaluate the degree of change in the connection mode of charging station nodes. , the formula is: ; in, represents the connectivity of charging station node i at time t.
[0055] The property disturbance analysis module is used to calculate the delay The characteristic perturbation intensity is: ; Among them, X(t) is the node feature matrix at time t, including features such as charging load and traffic flow.
[0056] The attribute perturbation analysis module is used to analyze the timing deviation of the feature distribution. The formula is: ; in, represents the KL divergence, Represents the feature distribution.
[0057] The cross-domain propagation module is constructed by using the data propagation matrix. The cross-domain propagation module calculates the cross-domain disturbance propagation matrix , quantifying the intensity and direction of disturbance propagation between the power system and the transportation system; the calculation formula of the disturbance propagation matrix is: ; in, and are the hidden states of the power system and the transportation system, respectively, containing the operating status information of each system, is the propagation weight matrix, is the activation function.
[0058] For example, considering that power grid disturbances (such as voltage fluctuations) and traffic system disturbances (such as congestion propagation) have different propagation speeds and impact ranges, a delay-aware module is constructed by introducing a delay mask matrix into the multi-head self-attention mechanism in the spatiotemporal transformer network to extract the delay characteristics of system disturbances. This delay-aware module identifies the impact of disturbances at different time steps τ by calculating the delay attention score D(τ). The specific formula for the delay attention score is: .
[0059] in, is the delay mask matrix, By formula Generate, where I is an indicator function, which takes the value 1 when the condition in the brackets is met and takes the value 0 when it is not met. This design ensures that the model only focuses on the recent The historical information within a time step can effectively avoid the interference of long-term noise.
[0060] By building a structural perturbation analysis module, we identify and quantify topological changes in dynamic hypergraphs.
[0061] The specific formula for calculating the hyperedge evolution rate of the charging station network through the structural perturbation analysis module is: ; Among them, E(t) represents the hyperedge set at time t, including the grid connection relationship, transportation connection relationship and charging station service range.
[0062] The structural disturbance analysis module is used to evaluate the degree of change in the connection pattern of charging station nodes. , the specific formula is: ; in, represents the connectivity of charging station node i at time t.
[0063] By building a delay-aware attribute perturbation analysis module, the dynamic changes of node and hyperedge features are evaluated.
[0064] The property disturbance analysis module is used to calculate the delay The characteristic disturbance intensity of is: ; Among them, X(t) is the node feature matrix at time t, including features such as charging load and traffic flow.
[0065] The attribute perturbation analysis module is used to analyze the timing deviation of the feature distribution. The specific formula is: ; in, represents the KL divergence, Represents the feature distribution.
[0066] In another embodiment, the present invention analyzes the coupling effect of the traffic-power system by constructing a cross-domain propagation module; the cross-domain propagation module quantifies the mapping relationship between charging load and traffic flow, evaluates the impact of traffic flow changes on charging demand distribution, and the impact of charging station load changes on local power grids; by calculating the cross-domain disturbance propagation matrix , quantifying the intensity and direction of disturbance propagation between the power system and the transportation system, as well as the impact of traffic congestion on the distribution of charging demand.
[0067] The calculation formula of the disturbance propagation matrix is: ; in, and They are the hidden states of the power system and the transportation system, respectively, which contain the operating status information of their respective systems, such as the load level and power distribution of the power grid, and the flow distribution and congestion status of the transportation network. is the propagation weight matrix, which is used to establish the mapping relationship between the two system states. is the activation function.
[0068] To calculate the coupling disturbance intensity of the grid-road network coupling system and obtain disturbance analysis results for each node, the present invention designs a coupling intensity calculation module. This module first analyzes the propagation path of the disturbance within a single system, including the risk of cascading failures in the power grid and the congestion spread effect in the transportation network. It then evaluates the cross-system coupling effect generated by the disturbance through the charging station node and calculates the coupling intensity at different time scales. The coupling intensity is calculated using the formula: Calculated. Among them, is the time delay parameter, which represents the time required for the disturbance to propagate from one system to another, taking into account the hysteresis and cumulative effect of the system response.
[0069] Based on the output of the above modules, the present invention calculates the final disturbance impact by the following formula: ; in, and They are the state vectors of the power system and the transportation system, respectively, which contain information such as node load, network topology and operating parameters. , comprehensively analyze the output of each module, realize the comprehensive assessment of system disturbance, and provide a basis for system operation risk warning.
[0070] In another embodiment, in order to achieve continuous optimization and adaptive update of the model, the present invention designs a sustainable learning mechanism. This mechanism constructs a parameter update strategy: ;
[0071] And adaptive weight adjustment: ; in, are model parameters, is the learning rate, is the adjustment coefficient, represents the relative loss gradient, is the adaptive learning rate, through the formula Dynamic adjustment, where is the initial learning rate, is a comprehensive disturbance index, and its calculation formula is: ; in is the hyperedge evolution rate, is the characteristic disturbance intensity, is the coupling disturbance intensity, and the calculation formula of the coupling disturbance intensity is: ; Among them, w(τ) is the weight coefficient of different delays.
[0072] In addition, in order to balance the stability and adaptability of the model, the present invention designs an adaptive adjustment mechanism for the loss function weight. The weight update adopts the formula: ,in is the adjustment coefficient, Represents the relative loss gradient. When a certain type of loss term (such as physical constraint loss) increases significantly, its corresponding weight will automatically increase to strengthen the optimization efforts in that aspect. At the same time, the memory decay mechanism is introduced: ,in is the forgetting factor, which is used to balance the impact of historical experience and new data.
[0073] In addition, the present invention also constructs a model update trigger mechanism based on performance evaluation. and physical constraint violation , triggering a model update when the following conditions are met:
[0074] ; That is, when the threshold is greater than The model update is triggered when and is the baseline error level, This design avoids unnecessary frequent updates while ensuring timely maintenance of model performance.
[0075] In addition, the present invention also realizes system state evaluation and prediction based on the physical constraint output and sustainability learning framework of the PINN network.
[0076] For example, the degree of violation of the physical constraint output by the PINN network is Combined with the evolution characteristics of the dynamic hypergraph, the system state evaluation index is constructed; by calculating the hypergraph structure stability index ,in for The hypergraph association matrix at each moment quantifies the degree of structural change in the power grid-road network coupling relationship; at the same time, it evaluates the stability index of the node dynamic characteristics. ,in is the characteristic vector of node v at time t, which includes the power load and traffic flow characteristics that meet the physical constraints; further calculate the coupling strength change index considering the physical constraints ,in is the hyperedge weight after PINN correction.
[0077] Based on the parameter update mechanism of the sustainability learning framework, the system state is dynamically predicted; the node state update formula is integrated with physical constraints. Predict the future state of a node, where For sustainable learning models, For nodes Neighborhood information; At the same time, the hyperedge weight update formula considering physical constraints is adopted Predict the evolution trend of coupling strength and realize dynamic tracking of system coupling relationship.
[0078] Based on the aforementioned evaluation indicators and prediction results, combined with the physical constraint output of PINN, the system evolution trend that satisfies power flow constraints and traffic flow constraints is analyzed. This enables dynamic evaluation and prediction of the grid-road network coupling system state, ensuring that the system operating state always meets the physical constraint requirements.
[0079] S105 , obtaining the data of each current node and inputting it into the disturbance analysis model to obtain the disturbance analysis results of each node.
[0080] The power grid operation data, traffic flow data and node attribute data are input into the disturbance analysis model, and the disturbance score of each node is calculated through the disturbance identification module. The mask weights in the multi-head attention mechanism are updated according to the disturbance score to generate an attention graph that takes into account the impact of the disturbance. The updated attention graph is used to analyze the propagation path of the disturbance in the power grid-road network coupling system, and the impact of the disturbance on each node is calculated and output through the cross-network impact assessment module to obtain the disturbance analysis results of each node.
[0081] The final output is the disturbance analysis results for the power grid-road network coupling system, including: 1) Evaluation of charging station network topology changes, including the evolution characteristics of service range and connection relationships.
[0082] 2) Load-flow perturbation analysis considering delay, including the timing pattern of characteristic changes.
[0083] 3) Assessment of grid-road network coupling strength, including quantitative analysis of cross-system impacts.
[0084] 4) Model update strategy, including learning parameter adjustment scheme based on scenario characteristics.
[0085] Based on the above method, the present invention also provides a charging guidance and charging station recommendation method based on the disturbance analysis results and a sustainability learning model. This method constructs system state evaluation indicators based on the evolutionary characteristics of a dynamic hypergraph, uses the sustainability learning model to dynamically predict the system state, and combines the physical constraint output of the PINN to generate an intelligent charging guidance strategy.
[0086] For example, the present invention designs a status evaluation index system for charging guidance. First, the charging station service capability index is constructed: ,in is the hypergraph association matrix at time t, reflecting the dynamic changes in the service scope and access capacity of the charging station. At the same time, the charging demand matching index is constructed: ,in is the feature vector of node v at time t, which includes charging demand and service capability characteristics and is used to evaluate the degree of supply and demand matching.
[0087] In order to achieve accurate charging guidance, the present invention designs a state prediction mechanism based on sustainable learning. The charging station state is updated through the formula: implementation, where For sustainable learning models, is the neighborhood information of charging station v, including local grid capacity and traffic accessibility, is the degree of satisfaction of physical constraints. At the same time, the charging demand distribution is predicted by the formula: implementation, where is the demand forecasting model, It is the set of nodes within the service range of the charging station.
[0088] In addition, the present invention also builds a charging station recommendation mechanism for users. At the charging station level, the service quality indicators are designed:
[0089] ; in, Indicates the availability of charging piles, with a value range of [0,1]; Indicates the expected waiting time, is the time sensitivity coefficient, which reflects the nonlinear impact of waiting time on service quality; Indicates the arrival time, is the maximum travel time acceptable to the user, is the distance decay coefficient. This design takes into account the exponential decay effect of waiting time and the diminishing marginal utility of distance.
[0090] At the path level, a comprehensive evaluation index considering traffic dynamic characteristics is constructed: ; in, is the path congestion, is the congestion penalty coefficient; To estimate energy consumption, is the baseline energy consumption, is the energy consumption sensitivity coefficient. The actual influence of congestion level and energy consumption on path evaluation is characterized by a nonlinear function.
[0091] Based on the above evaluation indicators, the present invention realizes the generation of adaptive charging guidance strategy. The strategy update formula is:
[0092] ,in is the learning rate, For actual service quality, The charging guidance strategy designed can be dynamically optimized according to the actual operation effect to improve user satisfaction.
[0093] Furthermore, to support practical charging decisions, this invention designs a multi-objective recommendation strategy generation mechanism. Based on the current system status and user demand characteristics, it generates personalized charging time and charging station combination recommendations, including the optimal charging time window and the ranking of alternative charging stations. Based on traffic flow forecasts, it provides charging station recommendations that take route planning into account, optimizing the overall efficiency of the charging process. Incorporating grid constraints, it implements differentiated charging guidance based on electricity prices and load levels, promoting balanced utilization of system resources.
[0094] This approach, through a deep learning framework that integrates a dynamic hypergraph structure with physical information, effectively addresses the limitations of traditional static graph models and periodic retraining strategies. First, by extracting the historical time-varying characteristics of power grid, road network, and charging station nodes, a dynamic hypergraph structure is constructed. A multi-head attention mechanism is then used to adaptively assign node weights, capturing system dynamics in real time and avoiding the computational resource consumption and catastrophic forgetting associated with periodic retraining. Second, the power flow equation and traffic flow dynamics equation are embedded as physical constraints within the PINN network, enhancing the model's interpretability of the coupling mechanism and improving decision-making confidence. Furthermore, the attention correlation matrix, delayed attention matrix, and data propagation matrix are integrated through a spatiotemporal Transformer network to achieve joint prediction and disturbance analysis of power grid and road network states. The resulting disturbance analysis model combines dynamic adaptability, physical interpretability, and computational efficiency, providing reliable technical support for real-time optimization and key node diagnosis of coupled power grid and road network systems.
[0095] Secondly, the present invention also provides a disturbance analysis device for a power grid-network coupling system, such as Figure 2 Shown, including: The acquisition module 201 is used to acquire historical data of power grid nodes, road network nodes and charging station nodes, and extract time-varying features of the historical data.
[0096] Construction module 202 is used to construct a power grid subgraph with substations as nodes and transmission lines as edges, and a road network subgraph with charging stations as nodes and roads as edges; construct cross-network coupling hyperedges between the power grid subgraph and the road network subgraph based on the geographical location relationship, functional correlation and temporal evolution characteristics of the power grid subgraph nodes and the road network subgraph nodes to obtain a dynamic hypergraph structure, and adaptively allocate weights to different types of nodes in the dynamic hypergraph structure through time-varying characteristics based on the multi-head attention mechanism; use the power flow equation and traffic flow dynamics equation as physical constraints, and construct an error loss function based on historical data; based on physical constraints, The PINN network is trained with the bundle condition and error loss function to obtain the power grid-road network coupling data prediction model; the topological relationship of the dynamic hypergraph structure is mapped into an attention association matrix, the delayed attention is determined according to the temporal evolution characteristics of the dynamic hypergraph structure, and the data propagation matrix between the power grid and the road network is determined based on the output of the power grid-road network coupling data prediction model. A spatiotemporal transformer network is constructed based on the attention association matrix, delayed attention and data propagation matrix, and the spatiotemporal transformer network is trained to obtain a disturbance analysis model for performing disturbance analysis on each node.
[0097] The analysis module 203 is used to obtain the data of each current node and input it into the disturbance analysis model to obtain the disturbance analysis results of each node.
[0098] Using this device, a deep learning framework that integrates a dynamic hypergraph structure with physical information effectively addresses the limitations of traditional static graph models and periodic retraining strategies. First, a dynamic hypergraph structure is constructed by extracting the historical time-varying characteristics of power grid, road network, and charging station nodes. A multi-head attention mechanism is then used to adaptively assign node weights, capturing system dynamics in real time and avoiding the computational resource consumption and catastrophic forgetting associated with periodic retraining. Second, the power flow equation and traffic flow dynamics equation are embedded as physical constraints within the PINN network, enhancing the model's interpretability of the coupling mechanism and improving decision-making confidence. Furthermore, the attention correlation matrix, delayed attention matrix, and data propagation matrix are integrated through a spatiotemporal Transformer network to achieve joint prediction and disturbance analysis of power grid and road network states. The resulting disturbance analysis model combines dynamic adaptability, physical interpretability, and computational efficiency, providing reliable technical support for real-time optimization and key node diagnosis of power grid-road network coupling systems.
[0099] The present invention also provides a computer-readable storage medium, which stores a computer program, which can be used to execute the above Figure 1 The steps of the disturbance analysis method of the power grid-road network coupling system are provided.
[0100] The present invention also provides a computer device. At the hardware level, the computer device includes a processor, an internal bus, a network interface, a memory, and a non-volatile memory. Of course, it may also include hardware required for other services. The processor reads the corresponding computer program from the non-volatile memory into the memory and then runs it to achieve the above Figure 1 The steps of the disturbance analysis method of the power grid-road network coupling system are provided.
[0101] Those skilled in the art will appreciate that embodiments of the present invention may be provided as methods, systems, or computer program products. Thus, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0102] The present invention is described with reference to flowcharts and / or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowcharts and / or block diagrams, as well as combinations of processes and / or blocks in the flowcharts and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowcharts and / or block diagrams. Figure 1 a process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0103] These computer program instructions may also be stored in a computer readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 a process or multiple processes and / or boxes Figure 1 The function specified in one or more boxes.
[0104] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operational steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing the instructions executed on the computer or other programmable device for implementing the process. Figure 1 a process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.
[0105] It should be noted that the above specific embodiments can enable those skilled in the art to more fully understand the present invention, but do not limit the present invention in any way. Therefore, although this specification has described the present invention in detail, those skilled in the art should understand that the present invention can still be modified or replaced with equivalents; and all technical solutions and improvements that do not depart from the spirit and scope of the present invention are included in the scope of protection of the patent for the present invention. Any reference signs in the claims should not be construed as limiting the claims involved.
Claims
1. A disturbance analysis method for a power grid-network coupling system, characterized in that: The method comprises: Acquire historical data of power grid nodes, road network nodes, and charging station nodes, and extract time-varying features of the historical data; Construct a power grid subgraph with substations as nodes and transmission lines as edges, and a road network subgraph with charging stations as nodes and roads as edges. Based on the geographic location, functional relevance, and temporal evolution characteristics of the nodes in the power grid and road network subgraphs, construct cross-network coupling hyperedges between the power grid and road network subgraphs to obtain a dynamic hypergraph structure. Adaptive weights are then assigned to different types of nodes in the dynamic hypergraph structure using time-varying features based on a multi-head attention mechanism. The power flow equation and traffic flow dynamics equation are used as physical constraints, and an error loss function is constructed based on historical data. The PINN network is trained based on the physical constraints and the error loss function to obtain a power grid-road network coupling data prediction model. Mapping the topological relationship of the dynamic hypergraph structure into an attention association matrix, determining delayed attention based on the temporal evolution characteristics of the dynamic hypergraph structure, determining a data propagation matrix between the power grid and the road network based on the output of the power grid-road network coupling data prediction model, constructing a spatiotemporal transformer network based on the attention association matrix, delayed attention, and data propagation matrix, and training the spatiotemporal transformer network to obtain a disturbance analysis model for performing disturbance analysis on each node; The data of each node is obtained and input into the disturbance analysis model to obtain the disturbance analysis results of each node.
2. The disturbance analysis method of a power grid-network coupling system according to claim 1, characterized in that: The adaptive weight allocation of different types of nodes in the dynamic hypergraph structure based on the multi-head attention mechanism through time-varying features includes: Construct a charging demand attention module, which includes an attention score , the formula is: ; in, 、 、 are query matrix, key matrix and value matrix respectively, is the dimension of the attention head; Construct a traffic flow attention module, which includes an attention score , the formula is: ; in, The mask matrix is generated based on the time-varying characteristics of road network traffic flow; Construct a charging mode attention module, which includes an attention score , the formula is: ; in, The mask matrix generated based on the time-varying characteristics of charging behavior; Construct a time-series-aware dynamic weight fusion mechanism, where the weight update formula is: ; ; ; in, Represents three different attention modules, is the weight coefficient, β is the time series smoothing factor, for t The weight evaluation value at the moment, for t The attention effect score of each moment, To score historical performance, MLP is a multi-layer perceptron; The output of each attention module is temporally weighted fused, and the formula is: ; in, for t Attention scores of different dimensions at the moment, express The comprehensive relationship representation vector of the multi-dimensional node relationship at each moment includes the characteristic relationships of the three dimensions of charging demand, traffic flow, and charging mode.
3. The disturbance analysis method of a power grid-network coupling system according to claim 1, characterized in that: The spatiotemporal transformer network includes a delay perception module, a structural disturbance analysis module, an attribute disturbance analysis module, and a cross-domain propagation module; the construction of the spatiotemporal transformer network based on the attention association matrix, the delayed attention, and the data propagation matrix includes: A delay perception module is constructed by the delayed attention, and the delay perception module identifies the disturbance impact under different time steps τ by calculating the delayed attention score D(τ); The specific formula of the delayed attention score is: ; in, is the delay mask matrix; The structural perturbation analysis module and the attribute perturbation analysis module are constructed by the attention association matrix. The hyperedge evolution rate of the charging station network is calculated by the structural perturbation analysis module. The formula is: ; Where E(t) represents the hyperedge set at time t, including the grid connection relationship, transportation connection relationship and charging station service range; The structural disturbance analysis module is used to evaluate the degree of change in the connection mode of charging station nodes. , the formula is: ; in, represents the connectivity of charging station node i at time t; The attribute disturbance analysis module calculates the delay The characteristic perturbation intensity is: ; Among them, X(t) is the node feature matrix at time t, including charging load, traffic flow and other characteristics; The attribute disturbance analysis module is used to analyze the timing deviation of the feature distribution. The formula is: ; in, represents the KL divergence, Represents feature distribution; The cross-domain propagation module is constructed by the data propagation matrix, and the cross-domain propagation module calculates the cross-domain disturbance propagation matrix , quantifying the intensity and direction of disturbance propagation between the power system and the transportation system; the calculation formula of the disturbance propagation matrix is: ; in, and are the hidden states of the power system and the transportation system, respectively, containing the operating status information of each system, is the propagation weight matrix, is the activation function.
4. The disturbance analysis method of a power grid-network coupling system according to claim 3, characterized in that: After obtaining the disturbance analysis model, the disturbance analysis model is also updated, including: Calculate the comprehensive disturbance index: ; in, 、 、 is the weight coefficient; Adaptively adjust the learning rate according to the degree of disturbance: ; in, is the initial learning rate, is the attenuation coefficient.
5. The disturbance analysis method of a power grid-network coupling system according to claim 1, characterized in that: The power flow equation and traffic flow dynamics equation are used as physical constraints to construct an error loss function based on historical data; The PINN network is trained based on physical constraints and error loss functions to obtain the power grid-road network coupling data prediction model, which includes: Based on the historical data, calculate the error between the model prediction result and the actual value As the error loss function, and the degree of violation of physical constraints is determined by physical constraints ; When the error is greater than the preset threshold When , the parameters of the PINN network are updated by the gradient descent method , the formula for the update process is: ; in is the adaptive learning rate, is the balance factor; the update process is repeated until the error is less than or equal to the preset threshold Or when the maximum number of iterations is reached and the degree of violation of the physical constraints of the output results reaches the preset conditions, the power grid-road network coupling data prediction model is obtained.
6. The disturbance analysis method of a power grid-network coupling system according to claim 1, characterized in that: Obtaining historical data of each node in the power grid-road network coupling system includes: Based on the preset sampling time interval within the preset historical time window , obtain the power data of the grid node and traffic data of road network nodes ;in, , is the number of sampling points, t 0 is the start sampling time; through the formula: , standardize the power data of power grid nodes; among them, is the average power in the historical time window, is the standard deviation of power within the historical time window; By formula: , standardize the traffic data of road network nodes; among them, is the average flow rate in the historical time window, is the standard deviation of the flow rate within the historical time window.
7. A disturbance analysis device for a power grid-network coupling system, characterized in that: The device comprises: An acquisition module is used to acquire historical data of power grid nodes, road network nodes, and charging station nodes, and extract time-varying features of the historical data; A construction module is used to construct a power grid subgraph with substations as nodes and transmission lines as edges, and a road network subgraph with charging stations as nodes and roads as edges; based on the geographical location relationship, functional correlation and temporal evolution characteristics of the power grid subgraph nodes and the road network subgraph nodes, a cross-network coupling hyperedge between the power grid subgraph and the road network subgraph is constructed to obtain a dynamic hypergraph structure, and based on the multi-head attention mechanism, adaptive weight allocation is performed on different types of nodes in the dynamic hypergraph structure through time-varying characteristics; the power flow equation and the traffic flow dynamics equation are used as physical constraints, and an error loss function is constructed based on historical data; the PINN network is trained based on the physical constraints and the error loss function to obtain a power grid-road network coupling data prediction model; the topological relationship of the dynamic hypergraph structure is mapped into an attention association matrix, the delayed attention is determined according to the temporal evolution characteristics of the dynamic hypergraph structure, the data propagation matrix between the power grid and the road network is determined based on the output of the power grid-road network coupling data prediction model, a spatiotemporal transformer network is constructed based on the attention association matrix, the delayed attention and the data propagation matrix, the spatiotemporal transformer network is trained to obtain a disturbance analysis model for performing disturbance analysis on each node; The analysis module is used to obtain the data of each current node and input it into the disturbance analysis model to obtain the disturbance analysis results of each node.
8. A computer-readable storage medium, characterized in that The 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.
9. A computer device, characterized in that: The method comprises a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the processor implements the method according to any one of claims 1 to 6 when executing the program.