An energy function based method for locating the source of disturbances in power systems

By combining the energy function with a logistic regression classifier, the problem of the traditional energy function method being unable to quickly, accurately, and automatically locate disturbance sources in complex power grids is solved, thus achieving rapid, accurate, and automated disturbance source identification in power systems.

CN122171902APending Publication Date: 2026-06-09ZHEJIANG UNIV OF SCI & TECH

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
ZHEJIANG UNIV OF SCI & TECH
Filing Date
2026-02-28
Publication Date
2026-06-09

AI Technical Summary

Technical Problem

Traditional energy function methods cannot achieve rapid, accurate, and automated location of disturbance sources in complex power grids, and their reliance on human experience can lead to misjudgments, making it difficult to meet the timeliness requirements of online real-time location.

Method used

By combining energy functions and logistic regression classifiers, an automated method for locating disturbance sources is constructed through data cleaning, energy calculation, statistical modeling, and iterative localization. The method utilizes energy flow direction for preliminary localization and logistic regression classifiers for accurate identification.

Benefits of technology

It enables rapid, accurate, and automated disturbance source location in complex power grids, adapts to different operating conditions, reduces human experience-based misjudgments, and meets the real-time location requirements of power systems.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122171902A_ABST
    Figure CN122171902A_ABST
Patent Text Reader

Abstract

This invention discloses a power system disturbance source localization method based on energy functions. The method first collects response data of the power system after a disturbance, and then calculates the output energy of each generator unit and the potential energy of each load using energy functions. Next, a statistical model is used to perform preliminary analysis of the energy data to screen candidate disturbance sources. Finally, the labeled energy data is fed into a logistic regression classifier for training and online application, constructing a unified disturbance source localization model. This invention combines energy analysis with machine learning to achieve rapid, accurate, and automated localization of different types of disturbance sources, such as random load fluctuations and forced power oscillations of generators. It avoids the problems of misjudgment and insufficient timeliness caused by reliance on human experience in traditional methods, and is particularly suitable for complex power grid environments with a high proportion of renewable energy integration.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of power system detection technology and relates to a method for locating power system disturbance sources based on energy functions. Background Technology

[0002] As power systems transition towards a higher proportion of renewable energy and power electronic equipment, their dynamic characteristics are becoming increasingly complex, posing new challenges to stable system operation. Low-frequency oscillations, as a typical stability problem, have long threatened grid security. Based on their generation mechanisms, low-frequency oscillations can be mainly divided into two categories: negatively damped low-frequency oscillations and forced power oscillations. The former stems from insufficient inherent damping in the system, and relatively mature suppression strategies already exist; the latter is triggered by continuous periodic disturbance sources (such as periodic fluctuations in the generator excitation system, specific load switching, etc.), and the fundamental solution lies in accurately identifying and eliminating the disturbance source. Therefore, achieving rapid and accurate location of the disturbance source is a key link in suppressing forced power oscillations and ensuring the safe and stable operation of high-voltage power systems.

[0003] Traditional methods for locating disturbance sources mainly include hybrid dynamic simulation based on physical simulation, traveling wave detection based on measurement signal analysis, and energy function methods based on energy calculation. Among these, the energy function method, as a response-driven approach, infers the location of the disturbance source by calculating and analyzing the potential energy changes of key nodes and connecting branches in the system during a disturbance. This method typically records the active power and frequency deviation of the nodes, integrates their product to obtain an energy function curve, and ultimately relies on technicians' manual observation and experience-based judgment of the curve shape for location.

[0004] However, in modern high-voltage power grids with complex structures and diverse operating modes, the limitations of the traditional energy function method are becoming increasingly apparent. First, the dynamic characteristics of new energy generating units differ significantly from those of traditional synchronous generating units, and a single energy function model may fail to accurately depict the energy distribution and transfer process of the entire system, easily leading to calculation errors. Second, this method lacks objective and unified quantitative criteria, and the positioning results heavily rely on subjective interpretations of curve trends based on human experience, posing a significant risk of misjudgment. Furthermore, the entire process from data acquisition and energy calculation to manual analysis and judgment is time-consuming, making it difficult to meet the timeliness requirements for online real-time location of disturbance sources.

[0005] Therefore, how to achieve rapid, accurate, and automated location of disturbance sources in complex power grid environments has become a pressing technical challenge in the field of power system security and defense. Summary of the Invention

[0006] To address the problems existing in the background technology, this invention proposes a power system disturbance source localization method based on energy function.

[0007] To achieve the above objectives, the present invention adopts the following technical solution: a power system disturbance source localization method based on energy function, comprising:

[0008] Collect response data from the power system and perform data cleaning and filtering preprocessing;

[0009] Based on the preprocessed response data, the output energy of each generator set and the load potential energy of each load are calculated using the energy function.

[0010] The calculated generator set outlet energy and load potential energy data are input into the statistical model for analysis. Based on the analysis results, the corresponding generator set or load is marked as a disturbance source candidate or a non-disturbance source candidate.

[0011] The labeled generator outlet energy and load potential energy data are fed into a logistic regression classifier for training to obtain a disturbance source localization model.

[0012] Using the disturbance source localization model, the response data of the power system is analyzed, and the disturbance source localization results are output.

[0013] Specifically, the preprocessed response data uses the generator's active power and node voltage frequency as input on the generator side, and the load's active power and node voltage frequency as input on the load side.

[0014] Specifically, the energy function is a potential energy function, and its expression is:

[0015] ;

[0016] in, and Branch roads At the node End and node Changes in active power at the terminal; and It is a node and nodes The phase angle; and They are branch roads exist End and The potential energy function value at the end.

[0017] Specifically, a power system disturbance source localization method based on energy function also includes a preliminary localization step based on energy flow direction: dividing the power system into several regions and calculating the net dissipated energy of the interconnection lines between regions;

[0018] If the net dissipated energy flows from the first region to the second region, then the first region is determined to be a candidate region containing the disturbance source.

[0019] Specifically, the formula for calculating the net dissipated energy is as follows:

[0020] ;

[0021] in, and These represent the changes in active power at both ends of the tie line. and The phase angles at both ends;

[0022] Furthermore, the initial positioning is an iterative process, in which the candidate region is further divided and the energy flow direction is calculated to gradually narrow down the range of the disturbance source.

[0023] Specifically, the analysis and labeling steps include:

[0024] Calculate the standard deviation of the energy data sequence for each generator set or load;

[0025] The standard deviation is compared with a threshold, which is set to three times the standard deviation of the corresponding equipment energy data sequence under historical normal operating conditions.

[0026] If the standard deviation of a device's energy data sequence exceeds the threshold, it is marked as a candidate disturbance source.

[0027] Specifically, the logistic regression classifier employs the Sigmoid function. The model parameters are optimized using gradient descent as the gradient descent method, with cross-entropy as the loss function and cross-entropy as the decision function.

[0028] Furthermore, before training, the generator outlet energy and load potential energy data are normalized to have a mean of 0 and a variance of 1.

[0029] Specifically, the logistic regression classifier is trained using a 5-fold cross-validation method, and the cross-entropy loss function includes an L2 regularization term with a regularization coefficient of 0.01.

[0030] Specifically, in the application phase of the logistic regression classifier, the sample category marked as a perturbation source candidate is set to 1, and the sample category as a non-perturbation source candidate is set to 0.

[0031] The logistic regression classifier outputs the probability that a sample belongs to class 1. ,when When this happens, the corresponding device is identified as the source of the disturbance.

[0032] Specifically, the analysis of the power system response data using the disturbance source localization model is performed in a real-time operating environment, with an online analysis response time not exceeding 500 milliseconds.

[0033] Compared with existing technologies, this invention has the following advantages: by combining energy function analysis with statistical index-based screening, an objective quantitative evaluation system is constructed, which can accurately identify the generator set or load with the most concentrated oscillation energy, thereby avoiding misjudgments caused by reliance on human experience in traditional methods. Whether it is random fluctuation on the load side or forced power oscillation on the generator side, this method can achieve effective location and shows good adaptability to different operating conditions.

[0034] This method demonstrates good adaptability to high-voltage power grids with a high proportion of renewable energy sources. Simulation and case studies show that after the integration of renewable energy sources such as wind turbines, the disturbance source localization effect of this method remains consistent with that in traditional power grid scenarios, and the localization accuracy is not affected by the integration of renewable energy sources. This solves the problems of poor model adaptability and easy inaccuracy in calculations of traditional methods in complex power grids.

[0035] By introducing a logistic regression classifier to train offline historical data, a unified discrimination model is formed, enabling automated analysis of different types of disturbances. In online applications, the response data, collected in real-time and calculated using an energy function, is directly input into the trained model to quickly output location results. This process automates analysis and judgment, improves location timeliness, and meets the power dispatching requirements for rapid and accurate decision-making. Attached Figure Description

[0036] Figure 1 This invention is a flowchart of a method for locating power system disturbance sources based on energy functions;

[0037] Figure 2 This is a schematic representation of the generator and load potential energy data in an embodiment of the present invention;

[0038] Figure 3 This is a representation of the model training data in an embodiment of the present invention. Detailed Implementation

[0039] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0040] like Figures 1-3 As shown, the technical solution adopted in this invention is as follows: A method for locating power system disturbance sources based on energy functions, comprising:

[0041] S1: Collect response data from the power system and perform data cleaning and filtering preprocessing.

[0042] A power system refers to an electrical energy production and consumption network consisting of power generation, transmission, transformation, distribution, and consumption equipment. Response data refers to the time series of physical quantities reflecting the dynamic behavior of a power system, collected and recorded in real time by monitoring devices deployed within the system (such as phasor measurement units (PMUs) and supervisory control and data acquisition (SCADA) systems) after the power system experiences disturbances such as power oscillations. The data acquisition operation in this step obtains the raw response data from the aforementioned monitoring devices via a data communication network.

[0043] Data cleaning refers to the process of verifying and correcting the quality of the collected raw response data. Its purpose is to identify and process missing values, outliers, and noise data caused by communication interference. Data filtering refers to selecting effective data segments suitable for subsequent analysis from the continuous response data stream after data cleaning, based on at least one of the following: a preset time window, a data missing rate threshold, or a lower limit of the signal-to-noise ratio.

[0044] Preprocessing is a collective term for the two sub-steps of data cleaning and data filtering. Its output is a valid response dataset that has undergone quality processing and filtering, which serves as the input for subsequent energy function calculations.

[0045] Specifically, the preprocessed response data uses the generator's active power and node voltage frequency as input on the generator side, and the load's active power and node voltage frequency as input on the load side.

[0046] The generator side refers to the collection of all generator nodes in a power system. For each generator node, its input response data includes the generator's active power (in megawatts, MW) and the voltage frequency of the node to which the generator is connected (in hertz, Hz).

[0047] The load side refers to the collection of all load nodes in a power system. For each load node, its input response data includes the active power of the load and the voltage frequency of the nodes connected to the load.

[0048] Active power and node voltage frequency are fundamental physical quantities in power system dynamic analysis, obtained directly from monitoring devices. The time-series data of these physical quantities together constitute the basic input data for energy function calculation in subsequent steps.

[0049] S2: Based on the preprocessed response data, calculate the output energy of each generator set and the load potential energy of each load using the energy function.

[0050] Based on the preprocessed response data, calculations are performed using an energy function. In this invention, the energy function specifically refers to a mathematical model used to quantify the accumulated or dissipated oscillatory energy of each device node in a power system during disturbances. The calculation objects are each generator set and each load. For each generator set, its outlet energy is calculated. Outlet energy is a scalar representing the net oscillatory energy flowing from the generator set to the connected power grid during the observation period, and its unit is megajoules (MJ). For each load, its load potential energy is calculated. Load potential energy is a scalar representing the oscillatory energy absorbed or released by the load node during the observation period, and its unit is also megajoules (MJ). The outlet energy and load potential energy together constitute the input feature data for subsequent analysis steps.

[0051] Specifically, the energy function is a potential energy function, and its expression is:

[0052] ;

[0053] in, and Branch roads At the node End and node Changes in active power at the terminal; and It is a node and nodes The phase angle; and They are branch roads exist End and The potential energy function value at the end.

[0054] The mathematical expression for the potential energy function consists of two integrals, which calculate the potential energy changes at the two endpoints of the branch. In the expression, The time variable is used for integration, with units in seconds (s). The lower limit of integration (0) represents the moment the disturbance begins, and the upper limit is... This represents the current calculation time. It is the integral variable. Indicates a branch At the node The change in active power at the terminal is expressed in megawatts (MW). The value is obtained by analyzing the nodes. The deviation of the measured active power time series relative to the steady-state reference value is obtained by calculating the value. Indicates a branch At the node The change in active power at the terminal is expressed in the same unit and calculation method as above. Side road Connecting nodes With nodes The power transmission line or transformer branch. It is a node The voltage phase angle, in radians (rad), is measured directly by a phasor measuring device or obtained through state estimation. It is a node The voltage phase angle.

[0055] Represents a node The rate of change of voltage phase angle, i.e. The unit is radians per second (rad / s). Represents a node The rate of change of voltage phase angle. It is a side road exist The potential energy function value, that is, the value obtained by integration from time 0 to... node Along the side road Accumulated potential energy, measured in megajoules (MJ). It is a side road exist The potential energy function value at the end.

[0056] The generator set's output energy is transmitted through all its connected branches, with the generator node as the endpoint. The load potential energy is obtained by algebraic summation. It is calculated through all its connected branches, with the load node as the endpoint. It is obtained by algebraic summation.

[0057] Specifically, a power system disturbance source localization method based on energy function also includes a preliminary localization step based on energy flow direction: dividing the power system into several regions and calculating the net dissipated energy of the interconnection lines between regions;

[0058] If the net dissipated energy flows from the first region to the second region, then the first region is determined to be a candidate region containing the disturbance source.

[0059] First, the entire power system is divided into several regions based on grid topology, administrative management, or electrical coupling relationships. A region is a set of subnetworks consisting of one or more electrical nodes (including generators, loads, and substations). Transmission lines connecting two different regions are called tie lines. For each tie line, the net dissipated energy through the line during a specific observation period is calculated. Net dissipated energy is a scalar quantity measured in megajoules (MJ), used to quantify the total amount of energy flowing net from one end of the line to the other. Then, a logical judgment is made: for a tie line connecting the first and second regions, if the calculated net dissipated energy is greater than zero, and its physical direction is determined to be from the first region to the second region via the tie line, then a judgment operation is performed, marking the first region as a candidate region containing a disturbance source. A candidate region is a subset of regions marked as potentially containing the final disturbance source device.

[0060] Specifically, the formula for calculating the net dissipated energy is as follows:

[0061] ;

[0062] in, and These represent the changes in active power at both ends of the tie line. and The phase angles at both ends;

[0063] Furthermore, the initial positioning is an iterative process, in which the candidate region is further divided and the energy flow direction is calculated to gradually narrow down the range of the disturbance source.

[0064] In the formula, and These represent the start and end times of the energy integral, respectively, in seconds (s). This indicates the node on the first side of the connection line. The change in active power at a given location is expressed in megawatts (MW). This indicates the nodes on the second side of the same connection line. The change in active power at a given point. The change in active power is obtained by calculating the deviation of the measured node active power time series from the steady-state value before the disturbance.

[0065] It is a node The voltage phase angle, in radians (rad). It is a node The voltage phase angle. The integral operation in the formula represents the product of the difference in active power change across the tie line and the difference in voltage phase angle across the tie line over the time interval. The energy is accumulated within the internal system, and the result is the net energy dissipation. When When, it indicates that the net energy from the node The region (i.e., the first region flow node) The area in question is the second region.

[0066] Furthermore, the initial localization is an iterative process, in which the candidate region is further subdivided and the energy flow direction is calculated to gradually narrow down the range of the disturbance source.

[0067] The iterative process refers to a computational flow that repeatedly executes a series of identical or similar operations until specific conditions are met. The specific logic is as follows: Within the candidate region obtained in the previous round of judgment, this candidate region is treated as a new power system to be analyzed, and the region division operation is performed again to form smaller sub-regions.

[0068] Subsequently, the net dissipated energy of the connecting lines between these new sub-regions is calculated, and a smaller range of candidate regions is determined according to the same judgment rule (if the net dissipated energy flows from sub-region A to sub-region B, then sub-region A is determined as a new candidate region). This iterative process is repeated, with each iteration performing a more refined division and energy flow calculation within the candidate regions of the current round, thereby gradually narrowing down the electrical range of the disturbance source.

[0069] S3: Input the calculated generator set outlet energy and load potential energy data into the statistical model for analysis, and mark the corresponding generator set or load as a disturbance source candidate or a non-disturbance source candidate based on the analysis results.

[0070] The calculated generator set outlet energy data sequence and load potential energy data sequence are jointly input into a statistical model. In this invention, the statistical model refers to a set of rules or algorithms based on mathematical statistics principles used to identify abnormal data patterns. Its function is to perform statistical analysis on the input equipment energy data sequence and output a binary classification judgment on whether the equipment is a potential disturbance source. The analysis process is executed by the statistical model, specifically including internal data processing and logical judgment. Based on the analysis results, a labeling operation is performed on each generator set or load with input energy data. The labeling operation is an assignment process, assigning a category label to each device. If the statistical model determines that the device is abnormal, it is labeled as a disturbance source candidate; if it determines that it is normal, it is labeled as a non-disturbance source candidate. A disturbance source candidate is a label indicating that the generator set or load is initially suspected as a disturbance source. A non-disturbance source candidate is a label indicating that the generator set or load is initially excluded as a disturbance source.

[0071] Specifically, the analysis and labeling steps include:

[0072] Calculate the standard deviation of the energy data sequence for each generator set or load;

[0073] The standard deviation is compared with a threshold, which is set to three times the standard deviation of the corresponding equipment energy data sequence under historical normal operating conditions.

[0074] If the standard deviation of a device's energy data sequence exceeds the threshold, it is marked as a candidate disturbance source.

[0075] For each generator set or load, the sampled values ​​of its continuous generator set outlet energy or load potential energy over a period of time constitute an energy data sequence in chronological order. For each device's energy data sequence, its standard deviation is calculated. The standard deviation is a statistic used to quantify the dispersion of data points in the energy data sequence from its mean; its unit is the same as the unit of the energy data sequence (e.g., megajoules, MJ). The formula for calculating the standard deviation is well-known. ,in For sequence length, For the first in the sequence One energy value, This is the arithmetic mean of the sequence.

[0076] Preset a threshold for each generator set or load. Threshold The threshold is determined by: collecting the energy data sequence corresponding to the device under historical normal operating conditions and calculating its standard deviation; multiplying this historical standard deviation by a factor of three; and obtaining the result is the threshold for the device. Historical normal operating conditions refer to the period of stable operation of the power system without forced power oscillations or other target disturbances. The multiplier of three is based on the statistical concept of 3. The outlier criterion (also known as the Raida criterion) is a commonly used outlier identification method in engineering and quality management, used to determine whether data points deviate from the normal fluctuation range. Subsequently, the standard deviation of the energy data sequence of the device calculated in the current disturbance event is compared with a preset threshold.

[0077] The judgment condition is: if the standard deviation of the energy data sequence of a certain generator set or load is greater than the threshold set for that equipment. That is, satisfying If the condition is met, the condition is deemed valid. When this condition is met, a marking operation is performed, marking the generator set or load as a potential disturbance source. If this condition is not met (i.e., ... If the value is 0, no action is taken, or it is marked as a non-disturbance source candidate according to the default rules.

[0078] S4: The labeled generator outlet energy and load potential energy data are fed into a logistic regression classifier for training to obtain a disturbance source localization model.

[0079] The labeled generator outlet energy data and load potential energy data, along with their previously assigned disturbance source or non-disturbance source candidate labels, constitute the training dataset. This training dataset is then fed into a logistic regression classifier for training. A logistic regression classifier is a statistical machine learning model used to solve binary classification problems; its function is to predict the probability of a given category (disturbance source or non-disturbance source) based on the input feature data (here, generator outlet energy and load potential energy).

[0080] Training is an iterative computational process aimed at automatically adjusting the internal model parameters of the logistic regression classifier based on the provided training dataset. This allows the model to learn the mapping relationship from energy features to perturbation source labels. Once the training process is complete, a logistic regression classifier with determined parameters is obtained and can be used to classify new data. This model is called the perturbation source localization model.

[0081] Specifically, the logistic regression classifier employs the Sigmoid function. The model parameters are optimized using gradient descent as the gradient descent method, with cross-entropy as the loss function and cross-entropy as the decision function.

[0082] Furthermore, before training, the generator outlet energy and load potential energy data are normalized to have a mean of 0 and a variance of 1.

[0083] A decision function maps the linear combination of input features to a probability value between 0 and 1. This scheme uses the Sigmoid function as the decision function. Its mathematical expression is ,in It is a linear weighted sum of the input features, i.e. , For the weight vector, For bias terms, The input feature vector contains the generator outlet energy and load potential energy. The output of the Sigmoid function is... The probability that the sample belongs to the positive class (the source of the disturbance) is interpreted as such.

[0084] The loss function measures the difference between the model's predicted probabilities and the true labels, guiding the optimization of model parameters. This approach uses cross-entropy as the loss function. For a single sample, the formula for calculating cross-entropy loss is:

[0085] ;

[0086] in It is the true label (0 or 1) of the sample. This represents the probability predicted by the model. Gradient descent is an iterative algorithm used to optimize model parameters. In each iteration, the gradient (partial derivative) of the loss function with respect to the model parameters is calculated, and then the model parameters are updated in the reverse direction of the gradient to reduce the value of the loss function. The goal of optimization is to find a set of model parameters that minimizes the average cross-entropy loss across the entire training dataset.

[0087] Before inputting generator outlet energy data and load potential energy data into the logistic regression classifier for training, these two types of feature data need to be normalized. Normalization is a data scaling technique aimed at eliminating the adverse effects of differences in the units and numerical ranges of different features on model training.

[0088] The specific normalization method is as follows: for each feature in the training dataset (i.e., the generator outlet energy sequence of all samples or the load potential energy of all samples), calculate the mean of the feature data. and variance Then, for each sample, the original value for that feature is... Using formula Perform the conversion, where It is variance The arithmetic square root (i.e., standard deviation) of the feature. After this processing, the distribution of each feature dimension in the training dataset is adjusted to the mean. =0, variance It follows a standard normal distribution with a value of 1.

[0089] Specifically, the logistic regression classifier is trained using a 5-fold cross-validation method, and the cross-entropy loss function includes an L2 regularization term with a regularization coefficient of 0.01.

[0090] First, the logistic regression classifier is trained using a 5-fold cross-validation method. 5-fold cross-validation is a model evaluation and parameter selection strategy, and its execution process is as follows: The total training dataset prepared in steps S3 and S4 is randomly and uniformly divided into five non-overlapping subsets (called folds). Then, five iterations are performed. In each iteration, one subset is selected sequentially as the validation set, and the remaining four subsets are combined as the training set. The logistic regression classifier is trained using this training set, and the model performance (e.g., accuracy) is evaluated on the validation set.

[0091] After five rounds of iteration, the average of the five validation performance metrics is used as the final estimate of the logistic regression classifier's performance under this training configuration. This estimate guides model selection or parameter tuning, ultimately training the optimal perturbation source localization model using all the data. Secondly, during the optimization of the logistic regression classifier, the cross-entropy loss function is modified to include an L2 regularization term. L2 regularization is a technique to prevent overfitting, implemented by adding a penalty term proportional to the sum of the squares of the model parameters to the original cross-entropy loss function.

[0092] The total loss function expression including the L2 regularization term is: .in, For the original cross-entropy loss, It is the L2 regularization term, which is the sum of squares of all weight components in the model parameter vector. It is the regularization coefficient, used to control the strength of the regularization penalty.

[0093] In this method, the regularization coefficient is set to 0.01. The regularization coefficient λ=0.01 is a typical value widely used in machine learning model training. It is based on common engineering practices in the field of machine learning and aims to effectively control model complexity and prevent overfitting while avoiding excessive interference with the main training objective of the model. It is a recognized empirical parameter value in this technical field.

[0094] Specifically, in the application phase of the logistic regression classifier, the sample category marked as a perturbation source candidate is set to 1, and the sample category as a non-perturbation source candidate is set to 0.

[0095] The logistic regression classifier outputs the probability that a sample belongs to class 1. ,when When this happens, the corresponding device is identified as the source of the disturbance.

[0096] The application phase refers to the stage where the pre-trained disturbance source localization model is used to classify and predict new data. When preparing training data, for each sample (i.e., a device and its corresponding energy data) from the previous steps, a class value is assigned based on its labeling result: if the sample is labeled as a disturbance source candidate, its class is set to the value 1; if the sample is labeled as a non-disturbance source candidate, its class is set to the value 0. Value 1 represents the positive class "disturbance source," and value 0 represents the negative class "non-disturbance source." This encoding rule is the standard form for binary classification learning in logistic regression classifiers.

[0097] In the application phase, for a new input sample (i.e., the energy characteristic data of a device to be judged), the output of the disturbance source localization model (i.e., the trained logistic regression classifier) ​​is a scalar value between 0 and 1, called the probability P that the sample belongs to category 1. The probability P is calculated by the Sigmoid function and represents the confidence level of the model in classifying the input device as a disturbance source (i.e., category 1).

[0098] The following decision operation is then performed: the probability P is compared with the threshold 0.5. If the probability P is greater than or equal to 0.5, the decision condition is met, and the final classification is performed, classifying the corresponding device as a disturbance source. If the probability P is less than 0.5, the decision condition is not met, and the corresponding device is classified as a non-disturbance source. The threshold of 0.5 is the most commonly used decision boundary in binary classification problems. Its basis is that when the prior probabilities of the positive and negative classes are similar and the classification costs are the same, this threshold can minimize the classification error rate.

[0099] S5: Using the disturbance source location model, analyze the power system response data and output the disturbance source location results.

[0100] The newly generated response data in the power system is analyzed using a trained disturbance source localization model. This analysis is an automated process executed by a software module deployed on a computing server.

[0101] First, real-time monitoring data of the current power system is collected, and data cleaning, filtering, and preprocessing are performed according to the same procedure to obtain the preprocessed response data at the current moment. Then, based on the energy function and specific calculation formula, the output energy data of each generator unit and the load potential energy data of each load are calculated based on the current preprocessed response data.

[0102] Next, the calculated generator set outlet energy and load potential energy data are input into the trained disturbance source localization model, either by comparing the standard deviation with the threshold as described above or by directly using them as feature vectors. The disturbance source localization model is the trained logistic regression classifier, which internally executes the defined Sigmoid function to calculate and output the probability P of each device (generator set or load) belonging to the disturbance source.

[0103] Finally, based on the defined judgment rules (a device is judged as a disturbance source when the probability P ≥ 0.5), a final determination is made as to whether each device is a disturbance source. The disturbance source location result is output as a well-defined, structured data list or signal, which contains the unique identifiers of all generator sets or loads identified as disturbance sources and their location information in the power system.

[0104] Specifically, the analysis of the power system response data using the disturbance source location model is performed in a real-time operating environment, and the response time of the online analysis does not exceed 500 milliseconds.

[0105] A real-time operating environment is a computing environment specifically designed for industrial control and monitoring. Its core characteristic is the ability to ensure that computing tasks are completed within strictly defined time limits. In this invention, it specifically refers to a computing platform deployed in a power system dispatch center or substation, equipped with a real-time operating system or a high-performance server with real-time processing capabilities.

[0106] Online analysis refers to the entire process of analyzing power system response data using the aforementioned disturbance source localization model and outputting disturbance source localization results. This process is synchronized with the actual operation of the power system, forming a closed loop: monitoring data continuously flows in, the localization algorithm is periodically or event-triggered, and the analysis results are continuously output to the monitoring interface or the higher-level control system.

[0107] In this invention, response time is defined as the total computational delay from the moment the latest batch of preprocessed response data for a given disturbance event is submitted to the disturbance source localization model until the model completes its calculations and outputs the final disturbance source localization result. This response time shall not exceed 500 milliseconds (i.e., 0.5 seconds).

[0108] The specific value requirement of 500 milliseconds is based on practical engineering standards in the field of power system stability control, which typically requires completion within hundreds of milliseconds. Technical reports from the International Conference on Large Electric Systems (CIGRE) and the Institute of Electrical and Electronics Engineers (IEEE) also indicate that for source location of fast dynamic processes such as forced power oscillations, a sub-second (less than 1000 milliseconds) response is crucial to ensuring the effectiveness of control measures. Therefore, 500 milliseconds is a widely recognized and adopted typical real-time performance indicator in online dynamic security assessment and control applications of power systems, capable of meeting the timeliness requirements of power dispatch for rapid and accurate location of disturbance sources.

[0109] To further illustrate the optimality of the logistic regression classifier used in this invention, several other typical classification models that may be used in the field of power system disturbance source localization are briefly described here for comparison. These models include linear discriminant analysis models, quadratic discriminant analysis models, and support vector machine classifier models.

[0110] Linear discriminant analysis (LDA) is a supervised learning algorithm that combines dimensionality reduction and classification. Its mathematical principle is analogous to matrix factorization. The model takes all energy data with class labels (such as generator outlet energy and load potential energy) as input. Its core objective is to find an optimal projection direction to project high-dimensional data into a low-dimensional space (such as a one-dimensional line), and to optimize the clustering of data points of the same class (minimum intra-class divergence) and the distance between data points of different classes (maximum inter-class divergence) after projection. The trained LDA model can then classify new data based on this projection relationship.

[0111] Quadratic discriminant analysis is a classification method based on Bayesian theory, achieving quadratic discrimination through matrix probability analysis. This model assumes that the data for each class follows a multivariate normal distribution, and that for each class… Calculate its probability density function The key difference between quadratic and linear discriminant analysis models is that quadratic discriminant analysis models allow each class to have its own distinct covariance matrix. Its discriminant function It is about a sample The model assigns samples to the category with the largest discriminant function value, which is a quadratic function.

[0112] The core of the Support Vector Machine (SVM) classifier model is the SVM algorithm. The goal of this model is to construct an optimal hyperplane in the feature space as a decision boundary, separating sample data in a way that maximizes the margin between samples of different classes. During model training, the model identifies the sample points closest to the boundary, i.e., the support vectors. When classifying new samples, they are mapped to the same feature space, and their class is determined based on their position relative to the optimal hyperplane (i.e., which side of the hyperplane they are on).

[0113] Compared to the models mentioned above, the logistic regression classifier used in this invention, combined with specific energy function feature preprocessing and regularization training strategies, demonstrates better interpretability, training efficiency, and robustness to complex operating conditions of high-voltage and high-efficiency power grids in the specific problem of power system disturbance source localization. The logistic regression model's direct probability output also facilitates the setting of clear decision thresholds, meeting the intuitive requirements of scheduling decisions.

[0114] In one specific embodiment, a real-world regional power grid system with 197 nodes is used. This system is connected to a high proportion of wind turbine generators to verify the effectiveness of the proposed method in high-voltage power systems.

[0115] S1: Collect response data from the power system and perform data cleaning and filtering preprocessing.

[0116] Dynamic response data after a disturbance is acquired using phasor measurement units (PMUs) deployed at key nodes in the power grid. This response data includes the active power and terminal voltage frequency of all generators, as well as the active power and node voltage frequency of all load nodes. Data cleaning algorithms are used to remove missing data points caused by communication interruptions, and filters are employed to eliminate measurement noise. Subsequently, based on the disturbance initiation time, valid data sequences within a subsequent 5-second time window are extracted to form a preprocessed response dataset, which serves as input for subsequent calculations.

[0117] S2: Based on the preprocessed response data, calculate the output energy of each generator set and the load potential energy of each load using the energy function.

[0118] For each transmission branch in the power grid The potential energy changes at both ends are calculated according to formulas (1) and (2):

[0119] ;

[0120] in, and Branch roads At the node End and node The change in active power at the terminal is obtained by subtracting the active power value measured by the PMU from the steady-state value before the disturbance, and the unit is megawatts (MW). and It is a node and nodes The voltage phase angle, in radians (rad). and This represents the corresponding voltage phase angle change rate. Then, for each generator set, its connection points with all connected branches are calculated. The output energy of the generator unit is obtained by algebraically summing the values. For each load node, the same applies to the nodes of its connected branches. The load potential energy is obtained by algebraically summing the values. Calculated and All data are time series data.

[0121] S3: Input the calculated generator set outlet energy and load potential energy data into the statistical model for analysis, and mark the corresponding generator set or load as a disturbance source candidate or a non-disturbance source candidate based on the analysis results.

[0122] For each generator set or load, extract the energy time series calculated in step S2. or Calculate the standard deviation of this energy sequence. Simultaneously, the standard deviation of the energy sequence of the device under historical normal operating conditions (stable operation data over the past 30 days) was retrieved. The current standard deviation With threshold The threshold is compared. Set to three times the historical standard deviation, i.e. If the current standard deviation of a certain device Greater than its corresponding threshold If the condition is met, the device is marked as a disturbance source candidate; otherwise, it is marked as a non-disturbance source candidate.

[0123] To verify the effectiveness of this step, two simulation conditions were set: Condition 1 involved forced power oscillations in load Load 1A-14; Condition 2 involved forced power oscillations simultaneously in loads Load 1A-10 and Load 1A-14. The above simulation was conducted using a 3D-based... The statistical model analysis of the criteria yielded the following location verification results, as shown in the table below:

[0124] Table 1, Load-forced power oscillation on the load side 3 Value Result Table:

[0125] load Operating Condition 1 Operating Condition 2 Load 1A-10 0 359 Load 1A-14 1671 1377 All other loads 0 0

[0126] The results show that in operating condition 1, only Load 1A-14 was marked as a candidate disturbance source, while in operating condition 2, Load 1A-14 and Load 1A-10 were marked as candidates for disturbance sources simultaneously, which is completely consistent with the preset disturbance sources. This proves that the method of combining energy function and statistical identification can accurately and initially locate the disturbance source of the measured system.

[0127] S4: The labeled generator outlet energy and load potential energy data are fed into a logistic regression classifier for training to obtain a disturbance source localization model.

[0128] First, the output energy of all generators calculated in step S2 is... and load potential energy The data is normalized so that the mean of each energy feature data type is 0 and the variance is 1 across the entire training set. The normalized energy data is then combined with the perturbation source candidate (encoded as 1) and non-perturbation source candidate (encoded as 0) labels obtained in step S3 to form training samples. This sample set is used to train a logistic regression classifier. This classifier uses the Sigmoid function... The decision function is defined by cross-entropy. Using θ as the loss function, gradient descent is employed to optimize the model parameters. After training, a disturbance source localization model suitable for online detection is obtained.

[0129] The model achieved learning accuracy of 96.8% and 96.1% for the data in working conditions 1 and 2, respectively, demonstrating high training accuracy and good adaptability.

[0130] S5: Using the disturbance source location model, analyze the power system response data and output the disturbance source location results.

[0131] When the power grid experiences forced power oscillation again, the system executes steps S1 to S2 in real time to obtain the latest generator output energy reflecting the current disturbance. and load potential energy The data is processed and normalized in the same way. Then, the processed data is input into the disturbance source localization model trained in step S4. The model calculates the probability P that each device belongs to the disturbance source. A decision threshold of 0.5 is set; if the probability P of a device is ≥ 0.5, then the device is determined to be the source of the disturbance. The entire online analysis process from new data input to result output is completed within 500 milliseconds, a time requirement that meets the typical needs of power system stability control for rapid decision-making. Finally, the system highlights the located disturbance source unit or load on the dispatcher's monitoring interface and issues an alarm.

[0132] Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing embodiments or make equivalent substitutions for some of the technical features. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.

Claims

1. A method for locating power system disturbance sources based on energy functions, characterized in that, include: Collect response data from the power system and perform data cleaning and filtering preprocessing; Based on the preprocessed response data, the output energy of each generator set and the load potential energy of each load are calculated using the energy function. The calculated generator set outlet energy and load potential energy data are input into the statistical model for analysis. Based on the analysis results, the corresponding generator set or load is marked as a disturbance source candidate or a non-disturbance source candidate. The labeled generator outlet energy and load potential energy data are fed into a logistic regression classifier for training to obtain a disturbance source localization model. Using the disturbance source localization model, the response data of the power system is analyzed, and the disturbance source localization results are output.

2. The method for locating power system disturbance sources based on energy functions according to claim 1, characterized in that, The preprocessed response data is input at the generator side using the generator's active power and node voltage frequency, and at the load side using the load's active power and node voltage frequency.

3. The method for locating power system disturbance sources based on energy functions according to claim 1, characterized in that, The energy function is a potential energy function, and its expression is: ; in, and Branch roads At the node End and node Changes in active power at the terminal; and It is a node and nodes The phase angle; and They are branch roads exist End and The potential energy function value at the end.

4. The method for locating power system disturbance sources based on energy functions according to claim 1, characterized in that, It also includes a preliminary positioning step based on energy flow direction: dividing the power system into several regions and calculating the net energy dissipation of the interconnection lines between regions; If the net dissipated energy flows from the first region to the second region, then the first region is determined to be a candidate region containing the disturbance source.

5. The power system disturbance source localization method based on energy function according to claim 4, characterized in that, The formula for calculating the net dissipated energy is as follows: ; in, and These represent the changes in active power at both ends of the tie line. and The phase angles at both ends; Furthermore, the initial positioning is an iterative process, in which the candidate region is further divided and the energy flow direction is calculated to gradually narrow down the range of the disturbance source.

6. The method for locating power system disturbance sources based on energy functions according to claim 1, characterized in that, The analysis and labeling steps include: Calculate the standard deviation of the energy data sequence for each generator set or load; The standard deviation is compared with a threshold, which is set to three times the standard deviation of the corresponding equipment energy data sequence under historical normal operating conditions. If the standard deviation of a device's energy data sequence exceeds the threshold, it is marked as a candidate disturbance source.

7. The method for locating power system disturbance sources based on energy function according to claim 1, characterized in that, The logistic regression classifier uses the Sigmoid function. The model parameters are optimized using gradient descent as the gradient descent method, with cross-entropy as the loss function and cross-entropy as the decision function. Furthermore, before training, the generator outlet energy and load potential energy data are normalized to have a mean of 0 and a variance of 1.

8. The method for locating power system disturbance sources based on energy functions according to claim 7, characterized in that, The logistic regression classifier is trained using a 5-fold cross-validation method, and the cross-entropy loss function includes an L2 regularization term with a regularization coefficient of 0.

01.

9. The method for locating power system disturbance sources based on energy functions according to claim 1, characterized in that, During the application phase of the logistic regression classifier, the sample class labeled as a perturbation source candidate is set to 1, and the sample class of a non-perturbation source candidate is set to 0. The logistic regression classifier outputs the probability that a sample belongs to class 1. ,when When this happens, the corresponding device is identified as the source of the disturbance.

10. The method for locating power system disturbance sources based on energy functions according to claim 1, characterized in that, The analysis of the power system response data using the disturbance source location model is performed in a real-time operating environment, and the online analysis response time does not exceed 500 milliseconds.