Method for processing real-time data fault hours based on interpolation algorithm
By employing a multi-level decision-making mechanism based on interpolation algorithms and a detailed classification method, the problem of insufficient interpolation accuracy in real-time data processing of power systems and new energy power plants is solved, enabling higher-precision fault time value processing, adapting to various data types, and improving the stability and accuracy of the system.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- CHINA DATANG CORPORATION SCIENCE AND TECHNOLOGY GENERAL RESEARCH INSTITUTE
- Filing Date
- 2025-12-26
- Publication Date
- 2026-05-08
AI Technical Summary
Existing technologies, when processing real-time data from power systems and new energy power plants, do not fully consider the special attributes of power data, have a single algorithm selection, resulting in insufficient interpolation accuracy, and lack a mechanism to verify the physical laws of the interpolation results.
The real-time data fault time value processing method based on interpolation algorithm includes real-time database modeling and attribute configuration, real-time acquisition and fault detection, interpolation algorithm decision, interpolation calculation, result verification and output, and dual-track data storage. It selects a suitable interpolation algorithm through a multi-level decision mechanism and performs detailed classification by combining multi-dimensional attributes such as industrial data quality code and step attribute.
It improves the accuracy of interpolation results, enabling more accurate processing of fault time values, adapting to Boolean remote signaling, multi-state remote signaling, and various types of analog data, thereby enhancing the accuracy and stability of system judgment.
Smart Images

Figure CN121997118A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of real-time data processing technology for power plants, specifically relating to a method for processing real-time data fault time values based on interpolation algorithms. Background Technology
[0002] In industrial monitoring fields such as power systems and new energy power plants, systems rely on massive amounts of real-time data for operational decisions. Real-time data includes telemetry data and remote signaling data. However, sensors, instruments, and signal transmission channels may malfunction, resulting in "fault-time values" in the collected data points. "Fault-time values" refer to the measured values collected when the signal measurement, processing, and transmission equipment at the measurement point fails—such as sensors, instruments, signal measurement and processing devices, signal transmission devices, or signal transmission channels. If this abnormal data is directly applied to monitoring, analysis, and diagnostic models, it will severely impact the accuracy of system judgments and the stability of operation.
[0003] Existing data interpolation or imputation techniques often have the following shortcomings when processing such real-time industrial data: First, they do not fully consider the special attributes of power data, such as remote signaling / telemetry differences, quality codes, and step characteristics; second, the algorithm selection is singular and not adapted to the dynamic characteristics of the data, resulting in insufficient interpolation accuracy; third, there is a lack of a mechanism to verify the physical laws governing the interpolation results. Therefore, there is an urgent need for a method that can combine the characteristics of industrial data to dynamically, accurately, and in real-time process fault time values. Summary of the Invention
[0004] The purpose of this invention is to provide a method for processing real-time data fault time values based on interpolation algorithms, which solves the problem of insufficient interpolation accuracy caused by the single algorithm selection and failure to adapt to the dynamic characteristics of the data in the prior art.
[0005] The technical solution adopted in this invention is a method for processing real-time data fault time values based on interpolation algorithms, comprising the following steps: Step 1, Real-time Database Modeling and Attribute Configuration: Pre-configure attribute sets for each data acquisition point in the real-time database; Step 2, Real-time Data Acquisition and Fault Detection: Acquire real-time data from the data acquisition points in Step 1, and determine whether the current data is a fault value based on preset rules; Step 3, Interpolation Algorithm Decision: When the fault time value is determined to be a fault time value, an interpolation algorithm is selected for the fault time value based on a multi-level decision-making mechanism; Step 4, Interpolation Calculation: Calculate the correction value using valid historical data based on the interpolation algorithm selected in Step 3; Step 5, Result Verification and Output: Verify the reasonableness of the correction value calculated in Step 4. After verification, update its quality code and output it. Step 6, Dual-track data storage: Associate and store the original fault value with the corrected value verified in Step 5.
[0006] The invention is further characterized in that, The attribute set in step 1 includes data type, normal value range, fault value handling strategy, interpolation quality code identifier, data step attribute, effective dataset size, default interpolation algorithm, fault quality code definition, and acquisition period.
[0007] The specific process of step 2 is as follows: Step 2.1 Real-time data acquisition: Collect real-time data containing numerical fields and quality code fields from industrial field devices through the industrial bus interface according to the pre-configured acquisition cycle; Step 2.2, Parallel Data Verification and Fault Determination: After acquiring the real-time data from Step 2.1, simultaneous verification and parsing operations are performed. Based on the results, a comprehensive determination is made as to whether the current real-time data is a faulty value. The specific steps are as follows: Step 2.2.1, Data Validity Verification: Compare the numerical fields of the real-time data with the predefined normal value range for the data point, and verify the validity of its data format; Step 2.2.2, Quality Code Status Parsing: Parse the quality code field in the real-time data that conforms to the industry standard protocol to obtain the data acquisition status it represents; Step 2.2.3: Determine whether the current real-time data is a fault value based on preset rules; Step 2.3, Process Trigger: When a fault value is determined, proceed with the subsequent Step 3 operation.
[0008] Step 2.2.3 The preset rules include at least one of the following conditions: The value of the real-time data exceeds the threshold range calculated based on the normal value range; The quality code of real-time data is matched with the fault quality code identifier; The real-time data is in an invalid floating-point format.
[0009] The interpolation algorithms in step 3 include linear interpolation, forward nearest neighbor interpolation, multi-state weighted voting interpolation, weighted moving average interpolation, adaptive exponential smoothing interpolation, and mutation suppression interpolation.
[0010] The specific process of selecting the interpolation algorithm for the fault time value based on the multi-level decision-making mechanism in step 3 is as follows: Step 3.1 Quality Code Filtering: Define the valid dataset based on the set valid dataset size, as follows: (1) in, Indicates a valid dataset. This represents the data at time i. The selection condition is that the quality code of the data at time i is GOOD, where i represents a certain time, t represents the previous valid sampling time before the current fault time, n represents multiple consecutive past times, and the value is the size of the valid dataset in the collection point attribute. If the number of valid historical data selected is less than the preset threshold, the default interpolation algorithm configured for the collection point will be used. The default interpolation algorithm is either the linear interpolation algorithm or the forward nearest neighbor interpolation algorithm; otherwise, proceed to the next step attribute judgment process. Step 3.2, Step Attribute Judgment: If the step attribute of the sampling point is ON, then the forward nearest neighbor interpolation algorithm is selected; if it is OFF, then the dynamic data classification process is entered. Step 3.3, Dynamic Data Classification: Select an algorithm based on the data type of the data collection points; If the data type is a digital quantity, it is further divided into Boolean remote signaling data (BOOL) and multi-state remote signaling data (INT). If the data type is BOOL, the forward nearest neighbor interpolation algorithm is selected; if the data type is INT, the multi-state weighted voting interpolation algorithm is selected. If the data is analog, the relative rate of change and coefficient of variation of the historical valid data are calculated. Based on the calculation results of the relative rate of change and coefficient of variation, the data is divided into stationary, fluctuating, and abrupt types. If the data is stationary, the weighted moving average interpolation algorithm is selected; if the data is fluctuating, the adaptive exponential smoothing interpolation algorithm is selected; and if the data is abrupt, the abrupt suppression interpolation algorithm is selected.
[0011] Step 3.3 calculates the relative rate of change and coefficient of variation of the historical valid data. Based on the calculation results of the relative rate of change and coefficient of variation, the data is divided into stationary, fluctuating, and abrupt changes. The specific process is as follows: Calculate the relative rate of change and coefficient of variation, using a sliding window to fix at least 5 most recent valid data points; The relative rate of change is calculated as follows:
[0012] in, This represents the average value. This represents the i-th value, where i represents the position index and n represents the total number of values.
[0013] in, The value represents the average, and r% represents the relative rate of change. , These represent the value at the last moment and the value at the previous moment in the valid data points, respectively. This represents the time difference between two data points, where t represents the last moment among the valid data points. The coefficient of variation is calculated as follows:
[0014] in, Let represent the standard deviation, n represent the total number of values, and i represent the position index. This represents the i-th value. This represents the average value;
[0015] Where CV represents the coefficient of variation. Indicates standard deviation, This represents the average value; Classification judgment: Stationary type: Coefficient of variation (CV) <C %, and the relative rate of change r% < % / Second; Volatility type: A stock is considered volatile if it meets any of the following conditions: Coefficient of variation: C %≤CV <C %; Relative rate of change: % / second ≤ r%< % / Second; Mutant: A mutant is defined as one that meets any of the following conditions: Coefficient of variation: CV > C %; Relative rate of change: r%≥ % / Second.
[0016] The linear interpolation algorithm has the following specific calculation formula:
[0017] Where r is the slope, , The interpolated value represents the value at the time of the fault. This represents the value at the last moment among the valid data points, where t represents the last moment among the valid data points; The forward nearest neighbor interpolation algorithm is calculated using the following formula:
[0018] in, The interpolated value represents the value at the time of the fault. This represents the value at the last moment among the valid data points, where t represents the value at the last moment among the valid data points; The multi-state weighted voting interpolation algorithm has the following specific calculation formula:
[0019] in, The interpolated value represents the time of the fault, and t represents the last time among the valid data points. This represents the input parameter that makes the entire summation expression reach its maximum value; n represents the amount of historical data used for analysis; This represents the weight of the i-th historical state, and the weight is decayed over time. It is the Kronecker function, when When =s, =1; when When ≠s, =0; i represents the position index; The weighted moving average interpolation algorithm is calculated using the following formula:
[0020] in, The interpolated value represents the value at the time of the fault. This represents the value at the last moment among the valid data points. This indicates the value at the second-to-last time step among the valid data points. This represents the value at the third-to-last time point in the effective data set. The value at the fourth-to-last time step among the valid data points. This represents the value at the fifth-to-last time point among the valid data points; t represents the last time point among the valid data points; The adaptive exponential smoothing interpolation algorithm is calculated using the following formula:
[0021] in, This represents the predicted value at time t+1. This represents the predicted value at time t. This represents the actual observed value at time t, where t represents the last time among the valid data points. This represents the smoothing coefficient, and its value ranges from 0.3 to 1. ≤0.5, as detailed below:
[0022] Where CV represents the coefficient of variation; C C represents the minimum coefficient of variation. Indicates the maximum coefficient of variation; The mutation suppression interpolation algorithm, specifically the calculation formula, is as follows:
[0023] in, The interpolated value represents the value at the time of the fault. This represents the value at the last moment among the valid data points. This represents the value at the second-to-last time point among the valid data points. This represents the value at the third-to-last time point among the valid data points, and t represents the last time point among the valid data points; median(...) represents the median function, which takes the median. It is the attenuation factor, a coefficient between 0 and 1, as follows:
[0024] Where max(...) represents taking the maximum value, min(...) represents taking the minimum value, and r% represents the relative rate of change; This represents the space consistency check function, specifically a discriminant function that outputs either True or False, as follows:
[0025] in, This represents the value at the last moment among the valid data points. This represents the value at the second-to-last time point among the valid data points; Indicates the threshold for the difference in rate of change; r% represents the relative rate of change. This represents the relative rate of change of neighboring data collection points with strong correlations; =True: If the difference in the rate of change between the local device and neighboring devices is less than the threshold. It is determined that the spaces are consistent; =False: If the difference in the rate of change is greater than or equal to the threshold This indicates a spatial inconsistency.
[0026] Step 5, the rationality verification, includes: Physical constraint verification: Check whether the correction value is within the normal range; Trend consistency verification: Calculate the deviation between the corrected value and the trend of historical valid data. If the deviation is less than the preset threshold, the verification is passed.
[0027] In step 6, the data is stored in a dual-track manner: the original fault time value record with fault quality code and the corrected value record with interpolated quality code are associated with the same timestamp and stored together; different query interfaces are provided, the default query returns the corrected value record, and a specified query can return the original fault time value record.
[0028] The beneficial effects of this invention are: This invention presents a method for processing real-time data fault time values based on interpolation algorithms. By meticulously classifying the data and selecting appropriate interpolation algorithms according to different data types and pre-fault data conditions, it can process fault time values more accurately and improve the precision of interpolation results. At the same time, this method fully integrates multi-dimensional attributes such as industrial data quality codes, step attributes, and data types, and can adaptively process various types of analog data, including Boolean remote signaling, multi-state remote signaling, and stable, fluctuating, and abrupt analog data, demonstrating strong versatility. Attached Figure Description
[0029] Figure 1 This is a flowchart of a method for processing real-time data fault time values based on interpolation algorithms; Figure 2 This is the interpolation algorithm decision process for a real-time data fault time value processing method based on interpolation algorithms. Detailed Implementation
[0030] The present invention will now be described in detail with reference to the accompanying drawings and specific embodiments.
[0031] This invention relates to a method for processing real-time data fault time values based on interpolation algorithms, such as... Figure 1 and Figure 2 As shown, it includes the following steps: Step 1, Real-time Database Modeling and Attribute Configuration: Pre-configure attribute sets for each data acquisition point in the real-time database; In step 1, the attribute set includes data types, which include analog quantities and digital quantities. Analog quantities are continuously changing physical quantities, such as temperature, pressure, flow rate, and power. Digital quantities are discrete state quantities, such as switch status and alarm signals.
[0032] The normal value range is limited according to the actual working conditions. For example, the normal current value range is 200-250A.
[0033] The fault value handling strategy, such as enabling interpolation algorithm replacement, defines the core response action to be taken when a fault value is detected. This invention is configured to enable the interpolation algorithm replacement strategy. When data is determined to be a fault value at a certain moment, the subsequent interpolation algorithm decision and calculation process will be triggered, and the calculated correction value will replace the original fault value for use by downstream systems such as monitoring and analysis.
[0034] The interpolation quality code identifier defines a unique identifier used to mark and distinguish the corrected value generated by the interpolation algorithm. For example, it can be configured as the hexadecimal value 0x0A. After the data is processed and output by the real-time data fault value processing method based on the interpolation algorithm of this invention, its quality code will be updated to this identifier. Downstream systems can recognize this identifier to know that the data point is the interpolation result, rather than the original collected value, and thus take different confidence assessment or display strategies as needed, such as gray-out or annotation. This mechanism ensures the traceability and transparency of the data.
[0035] The data step attribute is set during system configuration based on signal characteristics. Setting it to ON indicates that the signal has step characteristics, meaning its value may change instantaneously, and the new state value does not depend on the previous state value. For example, the open / closed state of a circuit breaker or switch, where the value jumps from 0 to 1 or vice versa at the moment of action; such signals should be configured as ON. Setting it to OFF indicates that the signal has continuous variation characteristics, its value changes continuously or smoothly over time, and the current value is strongly correlated with the previous value. For example, analog quantities such as voltage, current, temperature, and power should be configured as OFF.
[0036] The effective dataset size defines the spatiotemporal range of historical valid data that needs to be backtracked and relied upon when making interpolation algorithm decisions. It is typically expressed in the format M / N seconds, where: N seconds: represents the length of the backtracking time window, i.e., the time period N seconds backward from the current failure time; M points: represents the minimum number of consecutive valid data points required within this time window, and these data points must have a quality code of GOOD (qualified status). For example, a configuration of "5 / 10s" means that when interpolation decisions are needed, the system will attempt to find at least 5 consecutive historical data points with a valid quality code within 10 seconds prior to the failure time.
[0037] The default interpolation algorithm is either linear interpolation or forward nearest neighbor interpolation, and the user can choose the appropriate one based on the actual working conditions.
[0038] The fault quality code definition is a specific identifier used to explicitly mark the fault value in the raw acquired data. For example, it can be configured as the hexadecimal value 0x80.
[0039] The data acquisition period defines a fixed time interval at which the system reads data from the data source, for example, set to 1 second. By meticulously classifying the data and selecting appropriate interpolation algorithms based on different data types and pre-fault data conditions, fault values can be processed more accurately, improving the precision of the interpolation results. This effectively solves the problem of insufficient interpolation accuracy caused by the single algorithm selection and failure to adapt to the dynamic characteristics of the data in existing technologies.
[0040] Step 2, Real-time Data Acquisition and Fault Detection: Collect real-time data from the data acquisition points in Step 1, and determine whether the current data is a fault value based on preset rules. The specific process is as follows: Step 2.1 Real-time data acquisition: Collect real-time data, including numerical fields and quality code fields, from industrial field devices via the industrial bus according to the pre-configured acquisition cycle; In actual working conditions, data acquisition can be achieved by selecting the appropriate industrial bus based on the communication protocol supported by the field equipment. For example, one of the common industrial buses or communication protocols such as Modbus TCP / IP or OPC DA / UA can be used.
[0041] Step 2.2, Parallel Data Verification and Fault Determination: After acquiring the real-time data from Step 2.1, simultaneous verification and parsing operations are performed. Based on the results, a comprehensive determination is made as to whether the current real-time data is a faulty value. The specific steps are as follows: Step 2.2.1, Data Validity Verification: Compare the numerical fields of the real-time data with the predefined normal value range for the data point, and verify the validity of its data format; Step 2.2.2, Quality Code Status Parsing: Parse the quality code field in the real-time data that conforms to the industry standard protocol to obtain the data acquisition status it represents; Step 2.2.3: Determine whether the current real-time data is a fault value based on preset rules; Preset rules include at least one of the following conditions: The value of the real-time data exceeds the threshold range calculated based on the normal value range; The quality code of real-time data is matched with the fault quality code identifier; The real-time data is in an invalid floating-point format.
[0042] Step 2.3, Process Trigger: When a fault value is determined, proceed with the subsequent Step 3 operation.
[0043] Step 3, Interpolation Algorithm Decision: When the fault time value is determined to be fault time value, an interpolation algorithm is selected for the fault time value based on a multi-level decision-making mechanism. The specific process is as follows: Step 3.1 Quality Code Filtering: Define the valid dataset based on the set valid dataset size, as follows: (1) in, Indicates a valid dataset. This represents the data at time i. The selection condition is that the quality code of the data at time i is GOOD, where i represents a certain time, t represents the previous valid sampling time before the current fault time, n represents multiple consecutive past times, and the value is the size of the valid dataset in the collection point attribute. If the number of valid historical data selected is less than the preset threshold, the default interpolation algorithm configured for the collection point will be used. The default interpolation algorithm is either the linear interpolation algorithm or the forward nearest neighbor interpolation algorithm, and the user can set it according to the actual working conditions. Otherwise, the next step attribute judgment process will be entered. Step 3.2, Step Attribute Judgment: If the step attribute of the sampling point is ON, then the forward nearest neighbor interpolation algorithm is selected; if it is OFF, then the dynamic data classification process is entered. Step 3.3, Dynamic Data Classification: Select an algorithm based on the data type of the data collection points; If the data type is a digital quantity, such as remote signaling data, then the data type is further divided into Boolean remote signaling data (BOOL) and multi-state remote signaling data (INT). If the data type is BOOL, then the forward nearest neighbor interpolation algorithm is selected; if the data type is INT, then the multi-state weighted voting interpolation algorithm is selected. If the data is analog, such as telemetry data, the relative rate of change and coefficient of variation of the historical valid data are calculated. Based on the calculation results of the relative rate of change and coefficient of variation, the data is divided into stationary, fluctuating, and abrupt types. If the data is stationary, the weighted moving average interpolation algorithm is selected; if the data is fluctuating, the adaptive exponential smoothing interpolation algorithm is selected; and if the data is abrupt, the abrupt suppression interpolation algorithm is selected.
[0044] The process involves calculating the relative rate of change and coefficient of variation of historical valid data. Based on the results of these calculations, the data is categorized into stationary, fluctuating, and abrupt changes. The specific steps are as follows: Calculate the relative rate of change and coefficient of variation, and use a sliding window to fix at least 5 recent historical valid data points. The recent historical valid data points specifically refer to the data points selected by continuously backtracking along the time axis from the previous valid sampling time before the current fault time. The relative rate of change is calculated as follows: (2) in, This represents the average value. This represents the i-th value, where i represents the position index and n represents the total number of values. (3) in, The value represents the average, and r% represents the relative rate of change. , These represent the value at the last moment and the value at the previous moment in the valid data points, respectively. This represents the time difference between two data points, where t represents the last moment among the valid data points. The coefficient of variation is calculated as follows: (4) in, Let represent the standard deviation, n represent the total number of values, and i represent the position index. This represents the i-th value. This represents the average value; (5) Where CV represents the coefficient of variation. Indicates standard deviation, This represents the average value; Classification judgment: Stationary type: Coefficient of variation (CV) <C % and the relative rate of change r% < % / Second; Volatility type: A stock is considered volatile if it meets any of the following conditions: Coefficient of variation: C %≤CV <C %; Relative rate of change: % / second ≤ r%< % / Second; Mutant: A mutant is defined as one that meets any of the following conditions: Coefficient of variation: CV > C % Relative rate of change: r%≥ % / Second; The numerical limits of the coefficient of variation and the relative rate of change can be customized in the label point attribute. It fully integrates multi-dimensional attributes such as industrial data quality code, step attribute, and data type, and can adaptively process various types of analog data such as Boolean remote signaling, multi-state remote signaling, and stable, fluctuating, and abrupt data, making it highly versatile.
[0045] Step 4, Interpolation Calculation: Calculate the correction value using valid historical data based on the interpolation algorithm selected in step S3; Interpolation algorithms include at least one of the following: linear interpolation algorithm, forward nearest neighbor interpolation algorithm, multi-state weighted voting interpolation algorithm, weighted moving average interpolation algorithm, adaptive exponential smoothing interpolation algorithm, and mutation suppression interpolation algorithm.
[0046] The linear interpolation algorithm has the following specific calculation formula: (6) Where r represents the slope, , The interpolated value represents the value at the time of the fault. This represents the value at the last moment among the valid data points, where t represents the last moment among the valid data points; The forward nearest neighbor interpolation algorithm is calculated using the following formula: (7) in, The interpolated value represents the value at the time of the fault. This represents the value at the last moment among the valid data points, where t is the last moment among the valid data points; The multi-state weighted voting interpolation algorithm has the following specific calculation formula: (8) in, The interpolated value represents the time of the fault, and t represents the last time among the valid data points. This represents the input parameter that makes the entire summation expression reach its maximum value; n represents the amount of historical data used for analysis; This represents the weight of the i-th historical state, and the weight is decayed over time. It is the Kronecker function, when When =s, =1; when When ≠s, =0; i represents the position index; The weighted moving average interpolation algorithm is calculated using the following formula: (9) in, The interpolated value represents the value at the time of the fault. This represents the value at the last moment among the valid data points. This indicates the value at the second-to-last time step among the valid data points. This represents the value at the third-to-last time point in the effective data set. The value at the fourth-to-last time step among the valid data points. This represents the value at the fifth-to-last time point among the valid data points; t represents the last time point among the valid data points; The adaptive exponential smoothing interpolation algorithm is calculated using the following formula: (10) in, This represents the predicted value at time t+1. This represents the predicted value at time t. This represents the actual observed value at time t, where t represents the last time among the valid data points. This represents the smoothing coefficient, and its value ranges from 0.3 to 1. ≤0.5, as detailed below: (11) Where CV represents the coefficient of variation; C C represents the minimum coefficient of variation. Indicates the maximum coefficient of variation; The mutation suppression interpolation algorithm, specifically the calculation formula, is as follows: (12) in, The interpolated value represents the value at the time of the fault. This represents the value at the last moment among the valid data points. This represents the value at the second-to-last time point among the valid data points. This represents the value at the third-to-last time point among the valid data points, and t represents the last time point among the valid data points; median(...) represents the median function, which takes the median. It is the attenuation factor, a coefficient between 0 and 1, as follows: (13) Where max(...) represents taking the maximum value, min(...) represents taking the minimum value, and r% represents the relative rate of change; This represents the space consistency check function, specifically a discriminant function that outputs either True or False, as follows: (14) in, This represents the value at the last moment among the valid data points. This represents the value at the second-to-last time point among the valid data points; Indicates the threshold for the difference in rate of change; r% represents the relative rate of change. This represents the relative rate of change of neighboring data collection points with strong correlations; =True: If the difference in the rate of change between the local device and neighboring devices is less than the threshold. It is determined that the spaces are consistent; =False: If the difference in the rate of change is greater than or equal to the threshold This indicates a spatial inconsistency.
[0047] Step 5, Result Verification and Output: Verify the reasonableness of the correction value calculated in Step 4. After verification, update its quality code and output it. Reasonableness verification includes: Physical constraint verification: Check whether the correction value is within the normal range; Trend consistency verification: Calculate the deviation between the corrected value and the trend of historical valid data. If the deviation is less than the preset threshold, the verification is passed.
[0048] Step 6, Dual-track data storage: The original fault time value is associated with the corrected value verified in Step 5 and stored together. Specifically, the original fault time value record with fault quality code and the corrected value record with interpolation quality code are associated with the same timestamp and stored together. Different query interfaces are provided. The default query returns the corrected value record, while a specified query can return the original fault time value record.
[0049] The method for processing real-time data fault time values based on interpolation algorithms in Embodiment 1 above is illustrated in the following specific embodiments for different application scenarios: Example 2 Application scenario: 110kV bus voltage remote signaling fault handling; data type: analog quantity. (1) Real-time database modeling and attribute configuration: Pre-configure attribute sets for each data acquisition point in the real-time database; (2) Data acquisition and fault detection, as detailed below: Data type: Analog (FLOAT32); Step attribute: OFF; Normal value range: 100-121kV; Fault time value handling strategy: Enable interpolation algorithm replacement; Interpolation quality code identifier: 0x0A; Effective dataset size: 5 / 10 seconds; Default interpolation algorithm: linear interpolation algorithm; Fault quality code definition: 0x80; Acquisition period: 1 second; Fault details: A fault occurred at 12:00:00. The fault value was invalid, the quality code was 0x80, and the last valid data was the voltage of 109.7kV at 11:59:59.
[0050] The specific input data is shown in Table 1 below: Table 1 Input Data Table
[0051] (3) Algorithm decision-making process: Quality code filtering: The number of valid historical data is 3, which is less than the preset threshold of 5, so the default interpolation algorithm is used; Default algorithm selection: The user specifies the default algorithm as the linear interpolation algorithm.
[0052] (4) Interpolation calculation: According to the linear interpolation formula: The slope is ; in, , This is the last valid data value before the failure.
[0053] Substitute the data from the input data table:
[0054]
[0055] (5) Result verification: Physical constraints: 109.8kV is within the normal range of 100-121kV, so the result is valid; Consistency of trend: 109.6, 109.7, 109.8, the data trend is consistent; Quality code marker: Interpolation result quality code = 0x0A (interpolation identifier).
[0056] (6) Dual-track data storage: The original fault value and the correction value are stored together.
[0057] Example 3 Application scenario: Remote signaling fault handling for 220kV line circuit breakers; Remote signaling type: Boolean. (1) Real-time database modeling and attribute configuration: Pre-configure attribute sets for each data acquisition point in the real-time database; (2) Data acquisition and fault detection: Data type: numeric, BOOL; Step attribute: ON; Normal value range: 0~1; Fault time value handling strategy: Enable interpolation algorithm replacement; Interpolation quality code identifier: 0x0A; Effective dataset size: 5 / 10 seconds; Default interpolation algorithm: Forward nearest neighbor interpolation; Fault quality code definition: 0x80; Acquisition period: 1 second; Fault details: A fault occurred at 12:00:00. The fault value was invalid, the quality code was 0x80, and the last valid data was the closing status 1 at 11:59:59.
[0058] The specific input data is shown in Table 2 below: Table 2 Input Data Table
[0059] (3) Algorithm decision-making process: Quality code filtering: If the number of valid historical data is 10, which is greater than the preset threshold of 5, a step attribute judgment will be performed; Step attribute: When the step attribute is ON, forward nearest neighbor interpolation is selected.
[0060] (4) Interpolation calculation: According to the forward nearest neighbor interpolation formula:
[0061] in, This is the last valid data value before the failure.
[0062] Substitute the data from the input data table:
[0063] (5) Result verification: Physical constraint: The circuit breaker state can only be 0 or 1 for the result to be valid; Quality code marker: Interpolation result quality code = 0x0A (interpolation identifier); (6) Dual-track data storage: The original fault value and the correction value are stored together.
[0064] Example 4 Application scenario: Handling remote signaling faults at the tap changer position of the main transformer; Type: INT. (1) Real-time database modeling and attribute configuration: Pre-configure attribute sets for each data acquisition point in the real-time database; (2) Data acquisition and fault detection: Data type: numeric, INT; Step attribute: OFF; Normal value range: 0~15; Fault time value handling strategy: Enable interpolation algorithm replacement; Interpolation quality code identifier: 0x0A; Effective dataset size: 5 / 10 seconds; Default interpolation algorithm: Forward nearest neighbor interpolation; Fault quality code definition: 0x80; Acquisition period: 1 second; Fault details: A fault occurred at 12:00:00. The fault value was invalid, the quality code was 0x80, and the last valid data was the main transformer tap position 4 at 11:59:59.
[0065] The specific input data is shown in Table 3 below: Table 3 Input Data Table
[0066] (3) Algorithm decision-making process: Quality code filtering: If the number of valid historical data is 10, which is greater than the preset threshold of 5, a step attribute judgment will be performed; Step attribute: When the step attribute is OFF, proceed to the dynamic data classification process; Data type: The data type is a numeric type, and it is further divided into multi-state remote signaling data. Therefore, the multi-state weighted voting interpolation algorithm is selected.
[0067] (4) Interpolation calculation: According to the weighted voting formula:
[0068] in: For time decay weight, Indicates a historical state.
[0069] The distance step number i is defined as follows: i=0 is the closest time (11:59:59), i=1 is the second closest time (11:59:58), and so on.
[0070] The historical state sequence is obtained from the most recent to the oldest: [4, 4, 3, 3, 3], which represents the 5 most recent valid states.
[0071] Weight calculation: State 4 weights (i=0 and i=1):
[0072] State 3 weights (i=2 to i=4, a total of 3 values):
[0073] Voting results:
[0074] (5) Result verification: Physical constraints: The result is valid if tap position 4 is within the range of 0-15. Trend verification: State 4 has appeared for two consecutive cycles, forming a short-term stable trend; Quality code marker: Interpolation result quality code = 0x0A (interpolation identifier).
[0075] (6) Dual-track data storage: The original fault value and the correction value are stored together.
[0076] Example 5 Application scenarios: Fault handling for remote sensing of ambient temperature; stable analog quantity. (1) Real-time database modeling and attribute configuration: Pre-configure attribute sets for each data acquisition point in the real-time database; (2) Data acquisition and fault detection: Data type: Analog (FLOAT32); Step attribute: OFF; Normal range: -40~85℃; Fault time value handling strategy: Enable interpolation algorithm replacement; Interpolation quality code identifier: 0x0A; Effective dataset size: 5 / 10 seconds; Default interpolation algorithm: linear interpolation; Fault quality code definition: 0x80; Acquisition period: 1 second; Feature calculation comparison standard: CV: 5-20; r: 0.5-2 (Ambient temperature changes relatively slowly, with small short-term fluctuations).
[0077] Fault details: A fault occurred at 12:00:00. The fault value was invalid, the quality code was 0x80, and the last valid data was 23.3℃ at 11:59:59.
[0078] The specific input data is shown in Table 4 below: Table 4 Input Data Table:
[0079] (3) Algorithm decision-making process: Quality code filtering: If the number of valid historical data is 10, which is greater than the preset threshold of 5, a step attribute judgment will be performed; Step attribute: When the step attribute is OFF, proceed to the dynamic data classification process; Data type: The data type is analog quantity, and the data is further divided based on the calculation results of relative rate of change and coefficient of variation; Data characteristics: Calculate the relative rate of change and coefficient of variation; average value:
[0080] Standard deviation:
[0081] Coefficient of variation:
[0082] Relative rate of change:
[0083] Feature identification: ,and The analog quantity is determined to be of a stationary type. Algorithm selection: The analog quantity type is further divided into stationary type, and the weighted moving average interpolation algorithm is adopted.
[0084] (4) Interpolation calculation: Based on the weighted moving average interpolation formula, the five most recent data points are selected with weights of 5:4:3:2:1, as follows:
[0085] Substitute the data from 11:59:55 to 11:59:59 into the input data table:
[0086] (5) Result verification: Physical constraints: 23.31℃ is within the reasonable range of ambient temperature; reasonable range of ambient temperature: -40-85℃; the result is valid. Trend verification: The deviation from the average of the most recent 5 data points (23.3℃) is 0.01℃, which is consistent with the trend. Quality code marker: Interpolation result quality code = 0x0A (interpolation identifier).
[0087] (6) Dual-track data storage: The original fault value and the correction value are stored together.
[0088] Example 6 Application scenarios: Wind speed telemetry fault handling in wind farms, fluctuating analog quantities; (1) Real-time database modeling and attribute configuration: Pre-configure attribute sets for each data acquisition point in the real-time database; (2) Data acquisition and fault detection: Data type: Analog quantity; Step attribute: OFF; Normal value range: 0-25m / s; Fault time value handling strategy: Enable interpolation algorithm replacement; Interpolation quality code identifier: 0x0A; Effective dataset size: 5 / 10 seconds; Default interpolation algorithm: linear interpolation; Fault quality code definition: 0x80; Acquisition period: 1 second; Feature calculation comparison standard: CV: 5-20; r: 0.5-5, wind speed changes relatively quickly, with large short-term fluctuations; Fault details: A fault occurred at 12:00:00. The fault value was invalid, the quality code was 0x80, and the last valid data was the wind speed of 8.5 m / s at 11:59:59.
[0089] The specific input data is shown in Table 5 below: Table 5 Input Data Table
[0090] (3) Algorithm decision-making process: Quality code filtering: If the number of valid historical data is 10, which is greater than the preset threshold of 5, a step attribute judgment will be performed; Step attribute: When the step attribute is OFF, proceed to the dynamic data classification process; Data type: The data type is analog quantity, and the data is further divided based on the calculation results of relative rate of change and coefficient of variation; Data characteristics: Calculate the relative rate of change and coefficient of variation; average value:
[0091] Standard deviation:
[0092] Coefficient of variation:
[0093] Relative rate of change:
[0094] Feature identification: ,and The analog quantity is determined to be of a fluctuating type. Algorithm selection: The analog quantity type is further divided into fluctuation type, and the adaptive exponential smoothing interpolation algorithm is adopted.
[0095] (4) Interpolation calculation: According to the adaptive exponential smoothing interpolation formula:
[0096] Wherein the smoothing coefficient is:
[0097] The iterative calculation process is detailed in Table 6 below: Table 6. Statistics of Iterative Calculation Process
[0098] Final result:
[0099] (5) Result verification Physical constraint: 8.55 m / s is within a reasonable wind speed range (0-25 m / s), so the result is valid; Trend verification: The deviation from the average of the most recent 5 data points (8.44 m / s) is 0.11 m / s, which is consistent with the trend; Quality code marker: Interpolation result quality code = 0x0A (interpolation identifier); (6) Dual-track data storage: The original fault value and the correction value are stored together.
Claims
1. A method for processing real-time data fault time values based on interpolation algorithms, characterized in that, Includes the following steps: Step 1, Real-time Database Modeling and Attribute Configuration: Pre-configure attribute sets for each data acquisition point in the real-time database; Step 2, Real-time data acquisition and fault detection: Acquire real-time data from the data acquisition points mentioned in Step 1, and determine whether the current data is a fault value based on preset rules; Step 3, Interpolation Algorithm Decision: When the fault time value is determined to be a fault time value, an interpolation algorithm is selected for the fault time value based on a multi-level decision-making mechanism; Step 4, Interpolation Calculation: Calculate the correction value using valid historical data based on the interpolation algorithm selected in Step 3; Step 5, Result Verification and Output: Verify the reasonableness of the correction value calculated in Step 4. After verification, update its quality code and output it. Step 6, Dual-track data storage: Associate and store the original fault value with the corrected value verified in Step 5.
2. The method for processing real-time data fault time values based on interpolation algorithm according to claim 1, characterized in that, The attribute set mentioned in step 1 includes data type, normal value range, fault value handling strategy, interpolation quality code identifier, data step attribute, effective dataset size, default interpolation algorithm, fault quality code definition, and collection period.
3. The method for processing real-time data fault time values based on interpolation algorithm according to claim 1, characterized in that, The specific process of step 2 is as follows: Step 2.1 Real-time data acquisition: Collect real-time data containing numerical fields and quality code fields from industrial field devices through the industrial bus interface according to the pre-configured acquisition cycle; Step 2.2, Parallel Data Verification and Fault Determination: After acquiring the real-time data described in Step 2.1, verification and parsing operations are performed simultaneously, and a comprehensive determination is made based on the results to determine whether the current real-time data is a faulty value. The specific steps are as follows: Step 2.2.1, Data validity verification: Compare the numerical field of the real-time data with the normal value range predefined for the data point, and verify the validity of its data format; Step 2.2.2, Quality Code Status Parsing: Parse the quality code field in the real-time data that follows the industry standard protocol to obtain the data acquisition status it represents; Step 2.2.3: Determine whether the current real-time data is a fault value based on preset rules; Step 2.3, Process Trigger: When a fault value is determined, proceed with the subsequent Step 3 operation.
4. The method for processing real-time data fault time values based on interpolation algorithm according to claim 3, characterized in that, The preset rule in step 2.2.3 includes at least one of the following conditions: The value of the real-time data exceeds the threshold range calculated based on the normal value range; The quality code of the real-time data is matched with the fault quality code identifier; The real-time data is in an invalid floating-point format.
5. The method for processing real-time data fault time values based on interpolation algorithm according to claim 1, characterized in that, The interpolation algorithms mentioned in step 3 include linear interpolation, forward nearest neighbor interpolation, multi-state weighted voting interpolation, weighted moving average interpolation, adaptive exponential smoothing interpolation, and mutation suppression interpolation.
6. The method for processing real-time data fault time values based on interpolation algorithm according to claim 5, characterized in that, The specific process of selecting the interpolation algorithm for fault time value based on the multi-level decision-making mechanism in step 3 is as follows: Step 3.1 Quality Code Filtering: Define the valid dataset based on the set valid dataset size, as follows: (1) in, Indicates a valid dataset. This represents the data at time i. The selection condition is that the quality code of the data at time i is GOOD, where i represents a certain time, t represents the previous valid sampling time before the current fault time, n represents multiple consecutive past times, and the value is the size of the valid dataset in the collection point attribute. If the number of valid historical data selected is less than the preset threshold, the default interpolation algorithm configured for the collection point will be used. The default interpolation algorithm is either the linear interpolation algorithm or the forward nearest neighbor interpolation algorithm; otherwise, proceed to the next step attribute judgment process. Step 3.2, Step Attribute Judgment: If the step attribute of the collection point is ON, then the forward nearest neighbor interpolation algorithm is selected; if it is OFF, then the dynamic data classification process is entered. Step 3.3, Dynamic Data Classification: Select an algorithm based on the data type of the collected data points; If the data type is numeric, it is further divided into BOOL and INT. If the data type is BOOL, the forward nearest neighbor interpolation algorithm is selected, and if the data type is INT, the multi-state weighted voting interpolation algorithm is selected. If the data is analog, the relative rate of change and coefficient of variation of the historical valid data are calculated. Based on the calculation results of the relative rate of change and the coefficient of variation, the data is divided into stationary, fluctuating, and abrupt types. If the data is stationary, the weighted moving average interpolation algorithm is selected; if the data is fluctuating, the adaptive exponential smoothing interpolation algorithm is selected; and if the data is abrupt, the abrupt suppression interpolation algorithm is selected.
7. The method for processing real-time data fault time values based on interpolation algorithm according to claim 6, characterized in that, Step 3.3 involves calculating the relative rate of change and coefficient of variation of historical valid data. Based on the calculation results of the relative rate of change and the coefficient of variation, the data is classified into stationary, fluctuating, and abrupt changes. The specific process is as follows: Calculate the relative rate of change and coefficient of variation, using a sliding window to fix at least 5 most recent valid data points; The relative rate of change is calculated as follows: (2) in, This represents the average value. This represents the i-th value, where i represents the position index and n represents the total number of values. (3) in, The value represents the average, and r% represents the relative rate of change. , These represent the value at the last moment and the value at the previous moment in the valid data points, respectively. This represents the time difference between two data points, where t represents the last moment among the valid data points. The coefficient of variation is calculated as follows: (4) in, Let represent the standard deviation, n represent the total number of values, and i represent the position index. This represents the i-th value. This represents the average value; (5) Where CV represents the coefficient of variation. Indicates standard deviation, This represents the average value; Classification judgment: Stationary type: Coefficient of variation (CV) <C %, and the relative rate of change r% < % / Second; Volatility type: A stock is considered volatile if it meets any of the following conditions: Coefficient of variation: C %≤CV <C %; Relative rate of change: % / second ≤ r%< % / Second; Mutant: A mutant is defined as one that meets any of the following conditions: Coefficient of variation: CV > C %; Relative rate of change: r%≥ % / Second.
8. The method for processing real-time data fault time values based on interpolation algorithm according to claim 6, characterized in that, The specific calculation formula for the linear interpolation algorithm is as follows: (6) Where r is the slope, , The interpolated value represents the value at the time of the fault. This represents the value at the last moment among the valid data points, where t represents the last moment among the valid data points; The forward nearest neighbor interpolation algorithm is specifically calculated using the following formula: (7) in, The interpolated value represents the value at the time of the fault. This represents the value at the last moment among the valid data points, where t represents the value at the last moment among the valid data points; The specific calculation formula for the multi-state weighted voting interpolation algorithm is as follows: (8) in, The interpolated value represents the time of the fault, and t represents the last time among the valid data points. This represents the input parameter that makes the entire summation expression reach its maximum value; n represents the amount of historical data used for analysis; This represents the weight of the i-th historical state, and the weight is decayed over time. It is the Kronecker function, when When =s, =1; when When ≠s, =0; i represents the position index; The specific calculation formula for the weighted moving average interpolation algorithm is as follows: (9) in, The interpolated value represents the value at the time of the fault. This represents the value at the last moment among the valid data points. This indicates the value at the second-to-last time step among the valid data points. This represents the value at the third-to-last time point in the effective data set. The value at the fourth-to-last time step among the valid data points. This represents the value at the fifth-to-last time point among the valid data points; t represents the last time point among the valid data points; The adaptive exponential smoothing interpolation algorithm is specifically calculated using the following formula: (10) in, This represents the predicted value at time t+1. This represents the predicted value at time t. This represents the actual observed value at time t, where t represents the last time among the valid data points. This represents the smoothing coefficient, and its value ranges from 0.3 to 1. ≤0.5, as detailed below: (11) Where CV represents the coefficient of variation; C C represents the minimum coefficient of variation. Indicates the maximum coefficient of variation; The specific calculation formula for the mutation suppression interpolation algorithm is as follows: (12) in, The interpolated value represents the value at the time of the fault. This represents the value at the last moment among the valid data points. This represents the value at the second-to-last time point among the valid data points. This represents the value at the third-to-last time point among the valid data points, and t represents the last time point among the valid data points; median(...) represents the median function, which takes the median. It is the attenuation factor, a coefficient between 0 and 1, as follows: (13) Where max(...) represents taking the maximum value, min(...) represents taking the minimum value, and r% represents the relative rate of change; This represents the space consistency check function, specifically a discriminant function that outputs either True or False, as follows: (14) in, This represents the value at the last moment among the valid data points. This represents the value at the second-to-last time point among the valid data points; Indicates the threshold for the difference in rate of change; r% represents the relative rate of change. This represents the relative rate of change of neighboring data collection points with strong correlations; =True: If the difference in the rate of change between the local device and neighboring devices is less than the threshold. It is determined that the spaces are consistent; =False: If the difference in the rate of change is greater than or equal to the threshold This indicates a spatial inconsistency.
9. The method for processing real-time data fault time values based on interpolation algorithm according to claim 1, characterized in that, The rationality verification in step 5 includes: Physical constraint verification: Check whether the correction value is within the normal range; Trend consistency verification: Calculate the deviation between the corrected value and the trend of historical valid data. If the deviation is less than a preset threshold, the verification is passed.
10. The method for processing real-time data fault time values based on interpolation algorithm according to claim 1, characterized in that, The dual-track data storage in step 6 specifically involves: storing the original fault time value record with the fault quality code and the corrected value record with the interpolated quality code together with the same timestamp; and providing different query interfaces, with the default query returning the corrected value record and a specified query returning the original fault time value record.