Mutual inductor data safety monitoring method based on block chain technology

By adopting the transformer data security monitoring method based on blockchain technology in the power system, the problems of data tampering, attacks and illegal access are solved, and efficient, secure and reliable online monitoring of transformer data is achieved, ensuring the stable operation of the power system.

CN120124111APending Publication Date: 2025-06-10国网安徽省电力有限公司营销服务中心 +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510207683.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-25
Publication Date
2025-06-10

AI Technical Summary

Technical Problem

The prior art is difficult to effectively prevent transformer data tampering, malicious attacks and illegal access in power systems, and blockchain technology has problems such as data storage performance bottlenecks, low consensus efficiency and data interaction barriers in actual applications.

Method used

The transformer data security monitoring method based on blockchain technology is adopted to realize the full process and high-precision security monitoring of transformer data by building a blockchain network, collecting and encrypting data in real time, using a hybrid consensus mechanism, combining attribute access control and smart contracts, and a fusion graph convolutional neural network and attention mechanism.

Benefits of technology

Ensure real-time, accurate and secure transmission and storage of transformer data, improve data credibility and integrity, enhance early warning capabilities for fault hazards, reduce data security risks, and ensure the safe and stable operation of the power system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120124111A_ABST
    Figure CN120124111A_ABST
Patent Text Reader

Abstract

The invention discloses a mutual inductor data security monitoring method based on a block chain technology, and relates to the technical field of power system data security monitoring, and the method comprises the steps of block chain network construction, data encryption and online monitoring, multi-modal data fusion and application, and an anomaly detection mechanism. Full-process and high-precision safe monitoring of voltage, current and phase data of the mutual inductor is realized. Through the non-tampering and traceable characteristics of the block chain, the integrity and authenticity of the mutual inductor data in the whole life cycle are ensured, the data are effectively prevented from being maliciously tampered or forged, the credibility and reliability of the data of the power system are improved, the transmission and storage process of the data is monitored in real time, and the reliability of the data is improved. According to the method, data exception is found in time, corresponding measures are taken, advanced encryption, signature and access control technologies are combined, data confidentiality and access safety are guaranteed, only legally authorized users can access corresponding data, illegal access is prevented, and data safety risks are remarkably reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of power system data security monitoring, and particularly to a method for monitoring the data security of transformers based on blockchain technology. Background Art

[0002] In modern power systems, transformers, as core power equipment, are responsible for accurately measuring and converting key electrical quantities such as current and voltage. The data they produce is the cornerstone of the stable operation, fault diagnosis, and accurate power metering of power systems. However, with the deep informatization of power systems, the data security situation of transformers is severe.

[0003] From the perspective of the threat of data tampering, due to the lack of an effective anti-tampering mechanism in traditional security methods, data is easily illegally modified under network attacks, resulting in inaccurate power system control and metering. For example, in remote control scenarios, tampered current and voltage data may mislead dispatching decisions and cause power accidents.

[0004] Regarding malicious attacks, traditional protection is difficult to resist complex attacks. For example, when hackers launch a distributed denial of service (DDoS) attack, it will interfere with the data transmission of transformers and render system monitoring ineffective. Moreover, it is difficult for traditional methods to accurately trace the source of attacks and take effective countermeasures in a timely manner.

[0005] In addition, illegal access is also a thorny issue. The access control of traditional security systems lacks flexibility and is difficult to adapt to the dynamic access requirements of power systems. The management of access permissions among different levels of staff and devices is complex, and traditional methods are prone to permission chaos, increasing the risk of data leakage.

[0006] Although blockchain technology has advantages such as decentralization, immutability, and traceability, providing new opportunities for the data security of transformers. However, in practical applications, there are still many problems in current systems that focus on online monitoring. In terms of data storage, the storage capacity of blockchain ledgers is limited, and storing a large amount of real-time transformer data will bring performance bottlenecks. In terms of consensus mechanisms, existing consensus algorithms such as proof of work (PoW) and proof of stake (PoS) may have problems such as low consensus efficiency and high energy consumption under the real-time requirements of power systems, affecting the timeliness of data monitoring. In addition, it is difficult to integrate blockchain with the existing power system information architecture, and there are obstacles in data interaction and collaboration, making it difficult to fully utilize the advantages of blockchain technology to achieve efficient online monitoring of transformer data security.

[0007] Therefore, the present invention provides a method for monitoring the data security of transformers based on blockchain technology. Summary of the Invention

[0008] (I) Technical Problems to be Solved

[0009] Aiming at the deficiencies of the existing technology, the present invention provides a method for safe monitoring of transformer data based on blockchain technology, which deeply integrates cutting-edge technologies and innovative mechanisms to achieve full-process and high-precision safe monitoring of transformer voltage, current, and phase data. Through an enhanced blockchain architecture and optimized online monitoring strategies, it ensures real-time, accurate monitoring and secure transmission and storage of data, improving data credibility and integrity; with the help of advanced encryption and access control means, it strictly guards data confidentiality and legitimate access rights; by using efficient and intelligent anomaly detection algorithms, it enhances the ability to warn of potential faults and comprehensively guarantees the safe and stable operation of the power system.

[0010] (II) Technical Solutions

[0011] To achieve the above objectives, the present invention is realized through the following technical solutions:

[0012] A method for safe monitoring of transformer data based on blockchain technology, including:

[0013] Construct a blockchain network, set network nodes for transformer data acquisition devices, power data processing centers, power management terminals, and relevant regulatory agencies respectively, and adopt a hybrid consensus mechanism that combines proof of work and proof of stake;

[0014] Real-time collect the electrical parameters, environmental parameters, and operating parameters of the transformer, and then regularly group and package the processed data to form a structured data packet containing multi-parameter continuous sampling values, and use relevant information combinations such as timestamps, device numbers, and data sequence numbers to generate a unique data identifier;

[0015] Use the ECDSA asymmetric encryption algorithm to process the structured data packet;

[0016] After the network node receives the encrypted data, signature value, and data identifier, it first verifies the validity of the signature with the sender's public key. If valid, it queries the data hash value stored in the previous block on the blockchain according to the data identifier, and compares it with the hash value recalculated from the received data. If the two are the same, it stores it in the local blockchain ledger, otherwise it triggers an anomaly alarm;

[0017] Establish a dynamic association model for voltage, current, and phase at the data acquisition end of the transformer;

[0018] Use time-frequency analysis technology to jointly extract features from voltage, current, and phase data, and obtain the amplitude and phase information of each frequency component at different times, as well as the energy distribution and change trend characteristics of voltage, current, and phase within different frequency bands;

[0019] The attribute-based access control model is combined with blockchain smart contracts. Attributes are defined for users and data resources respectively, and access control policy rules are set in the blockchain smart contract. When a user initiates a data access request, the smart contract evaluates based on the attributes of the user and the data and predefined rules to decide whether to grant access rights;

[0020] Define the voltage, current, and phase data collected by the transformer at different time points as graph nodes, construct edges according to the time series and physical association of the data to form a data graph structure, and perform normalization processing and model training on the transformer data collected in S21;

[0021] The transformer data collected in real time first undergoes data preprocessing, and then is input into the trained model for analysis and prediction, and early warning of abnormal signals is carried out.

[0022] Optionally, in the proof-of-work part in S1, the network nodes compete for the right to record transactions by calculating hash puzzles, and the calculation formula is as follows:

[0023] Hash(block_header) ≤ target

[0024] Among them, block_header is the block header information, including the hash value of the previous block, timestamp, and Merkle root, and it is the target hash value dynamically adjusted according to the network difficulty; the node finds the hash value that satisfies the above formula by continuously changing the nonce in the block header. The node that finds it first obtains the right to record transactions and adds the new block to the blockchain.

[0025] Optionally, in the proof-of-work part, the network nodes compete for the right to record transactions by calculating hash puzzles, and the calculation formula is as follows:

[0026] Hash(block_header) ≤ target

[0027] Among them, block_header is the block header information, including the hash value of the previous block, timestamp, and Merkle root, and it is the target hash value dynamically adjusted according to the network difficulty; the node finds the hash value that satisfies the above formula by continuously changing the nonce in the block header. The node that finds it first obtains the right to record transactions and adds the new block to the blockchain.

[0028] Optionally, in the proof-of-stake part, the calculation formula for the selection probability of the network node being selected to verify the block is:

[0029]

[0030] Among them, Pi is the probability that node i is selected, and stake i is the stake of node i, and stake jis the right of node j, and n is the total number of nodes in the network.

[0031] Optionally, after collecting the electrical parameters, environmental parameters, and operating parameters of the real-time acquisition transformer, the 3σ principle based on statistics is used to remove outliers and noise data. Let a certain data sequence collected be x 1 , x 2 , x 3 ,..., x n , whose mean is and the standard deviation is σ. Then the data point x that satisfies i is regarded as an outlier and excluded.

[0032] Optionally, the ECDSA asymmetric encryption algorithm uses the private key d to sign each group of data M to generate a signature value S. The calculation formula is as follows:

[0033] S = d·k -1 (H(M)+r·d)modn

[0034] where k is a randomly generated integer, H(M) is the hash value of data M, r = (k·G) i modn, G is the generating point of the elliptic curve, and n is the order of the elliptic curve;

[0035] Use the public key Q of the receiver to encrypt the data to obtain the ciphertext C: C = E Q (M). Send the encrypted data C, signature value S, and data identifier to the blockchain network. E represents the encryption operation. Through the encryption algorithm, the original data M is converted into the ciphertext C. The receiver with the private key corresponding to the public key Q has the permission to decrypt the ciphertext C to obtain the original data M.

[0036] Optionally, the algorithm for the sender's public key to verify the signature validity is:

[0037] r ′ =(S·G + H(M)·Q)modn

[0038] If r′=(k·G) x modn is valid, the signature is valid.

[0039] Optionally, by calculating the ratio relationship between the voltage amplitude and the current amplitude in real time and combining the phase information, an equivalent impedance model of the power system is constructed. The formula is as follows:

[0040]

[0041] where Z is the equivalent impedance, V and I are the voltage and current amplitudes respectively, and θ V , θ Iis the corresponding phase angle.

[0042] Optionally, the time-frequency analysis technology includes short-time Fourier transform and wavelet packet transform. For the current data i(t), the energy E of the j-th frequency band after wavelet packet transform decomposition is ij calculated by the following formula:

[0043]

[0044] where c ij (k) is the wavelet packet coefficient of the j-th frequency band, N is the coefficient length, and k is an index value representing the serial number of the coefficient.

[0045] Optionally, the access control policy rule defined in the smart contract is expressed as:

[0046] AccessGranted = (R = ADMIN) ∨ ((D = Monitoring Department) ∧ (P ≥ 3) ∧ (S ≤ 2))

[0047] R represents the user role, D represents the user's department, P represents the permission level, and S represents the data sensitivity level. When the user role is an administrator, or the user's department is the monitoring department and the permission level is greater than or equal to 3, and the data sensitivity level is less than or equal to 2, the user has the permission to access the data.

[0048] Optionally, after forming the data graph structure, use the graph convolutional neural network layer to aggregate neighbor node information to learn the global feature representation of the data, and then automatically focus on the key data changes through the attention mechanism layer. Let H be the final output feature matrix of the GCN layer, and the attention mechanism calculates the attention weight a of each node:

[0049] a = softmax(W a ·tanh(W h H + b h ))

[0050] where, W a 、W h are weight matrices, and b h is the bias vector;

[0051] Then, perform weighted summation on the node features through the attention weights to obtain the final feature representation Z:

[0052]

[0053] where N is the number of nodes, a idenotes the attention weight of the i-th node, which reflects the importance of the i-th node in the calculation of the final feature representation. The greater the weight, the greater the contribution of the node to the final feature representation; H i represents the feature vector of the i-th node.

[0054] Optionally, the data of the instrument transformer is normalized so that the voltage, current, and phase data are within the same numerical range. For the voltage data V, the min-max normalization formula is as follows:

[0055]

[0056] where V min and V max are the minimum and maximum values of the voltage data respectively.

[0057] Optionally, after the normalization process, the mean squared error loss function is combined with adversarial training to optimize the model. The mean squared error loss function is used to measure the error between the predicted value and the true value:

[0058]

[0059] where, y t is the true data, is the predicted data, and N is the number of data samples.

[0060] Optionally, after analyzing and predicting the data of the instrument transformer, according to the deviation ΔV of the voltage amplitude from the set reference value and the phase change situation, the switching and adjustment amount of the reactive power compensation device are intelligently controlled. The formula is as follows:

[0061]

[0062] where Q comp is the reactive power compensation amount, α and β are adjustment coefficients, dθ represents the small change in phase, which reflects the change degree of the phase within a very small time interval; dt represents the small change in time, which is used to measure the very small interval in time; The whole represents the phase change rate, that is, how fast the phase changes with time.

[0063] (III) Beneficial Effects

[0064] The present invention provides a method for safe monitoring of instrument transformer data based on blockchain technology, which has the following beneficial effects:

[0065] 1. Through the immutable and traceable characteristics of the blockchain, the integrity and authenticity of the instrument transformer data throughout its life cycle are ensured, effectively preventing the data from being maliciously tampered with or forged, and improving the credibility and reliability of the power system data.

[0066] 2. The innovative online monitoring mechanism can monitor the data transmission and storage process in real time, promptly detect data anomalies and take corresponding measures, significantly reducing data security risks and ensuring the safe and stable operation of the power system.

[0067] 3. Combining advanced encryption, signature, and access control technologies to ensure data confidentiality and access security. Only legally authorized users can access the corresponding data, preventing data leakage and illegal access.

[0068] 4. The anomaly detection algorithm of the graph convolutional neural network integrating the attention mechanism significantly improves the accuracy and timeliness of fault prediction, accurately captures potential fault features such as voltage sudden changes and current harmonics, early warns of potential hazards in the power system, provides key decision-making support for power operation and maintenance, and improves the intelligent level and reliability of power system operation and maintenance. BRIEF DESCRIPTION OF THE DRAWINGS

[0069] Figure 1 It is a schematic flowchart of a method for monitoring the data security of an instrument transformer based on blockchain technology according to the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0070] Next, the technical solutions in the embodiments of the present invention will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.

[0071] Please refer to Figure 1 , the present invention provides a method for monitoring the data security of an instrument transformer based on blockchain technology, which mainly includes five steps:

[0072] S1. Blockchain network construction

[0073] Build a private blockchain network, and use the data acquisition devices of instrument transformers, the power data processing center, the security management department of power enterprises, and relevant regulatory agencies as network nodes. Adopt a hybrid consensus mechanism combining Proof of Work (PoW) and Proof of Stake (PoS). In the PoW link, network nodes need to calculate complex hash puzzles by continuously changing the random number in the block header to compete for the right to record accounts; in the PoS link, determine the rights and interests of network nodes based on factors such as resource contributions and reputations in the system, and then calculate the probability of network nodes being selected to verify blocks according to a specific formula, so as to ensure the efficient operation of the network and data consistency.

[0074] Specifically, in the PoW part, network nodes need to calculate complex hash puzzles to compete for the right to record accounts, and the calculation formula is as follows:

[0075] Hash(block_header) ≤ target

[0076] Among them, block_header is the block header information, which contains the hash value of the previous block, timestamp, Merkle root, etc., and is the target hash value dynamically adjusted according to the network difficulty. Network nodes try to find the hash value that satisfies the above formula by continuously changing the nonce in the block header. The network node that finds it first obtains the right to record accounts and adds the new block to the blockchain.

[0077] In the PoS part, the stake of network nodes is determined according to factors such as their resource contributions and reputations in the system. Nodes with higher stakes have a greater probability of being selected to verify blocks. The specific selection probability calculation formula is:

[0078]

[0079] Among them, Pi is the probability that node i is selected, stacki is the stake of node i, stake j is the stake of node j, and n is the total number of nodes in the network. Through this hybrid consensus mechanism, both the decentralization characteristics of the blockchain network can be ensured and the overall performance of the system can be improved.

[0080] S2, Data Encryption and Online Monitoring

[0081] 2.1 Data Collection and Preprocessing

[0082] The intelligent collection device can not only collect basic electrical parameters such as voltage, current, and phase of the transformer in real time, but also collect environmental parameters such as temperature, humidity, and vibration of the transformer, as well as operation parameters such as the operation time and start / stop status of the transformer. The collection device performs preliminary cleaning on the data to remove obvious outliers and noise data. The 3σ principle based on statistics is used to remove data points that exceed the normal data range. Suppose a certain data sequence collected is x 1 , x 2 , x 3 ,..., x n , whose mean is and the standard deviation is σ. Then the data point x

[0083]

[0084] that satisfies i is regarded as an outlier and is excluded.

[0085] After the data cleaning is completed, the processed data is grouped and packaged at fixed time intervals (every 5 seconds). Each group of data contains consecutive sampled values of multiple parameters such as the voltage, current, and phase of the transformer over a period of time, forming a structured data packet. To ensure the traceability and uniqueness of the data, a unique identifier (ID) is generated for each group of data. This ID can be a combination of various information such as timestamps, device numbers, and data sequence numbers, and a unique hash value is generated through a hash algorithm as the unique identifier of the data packet.

[0086] The intelligent acquisition device also has the functions of data caching and preliminary analysis. During the data transmission process, network latency or interruption may occur. The device will temporarily cache the data that fails to be sent in time in the local memory and resend it after the network returns to normal to ensure the continuity and integrity of the data. At the same time, the device can also perform preliminary analysis and processing on the acquired data, such as calculating statistical indicators such as the average, maximum, and minimum values of voltage and current, and performing simple fault diagnosis, such as determining whether the voltage exceeds the rated range and whether the current has a sudden change, providing a preliminary reference basis for subsequent in-depth analysis and decision-making.

[0087] 2.2 Data Encryption and Signing

[0088] The ECDSA asymmetric encryption algorithm is used to encrypt and sign the data. First, use the private key d to sign each group of data M to generate a signature value S, and the calculation formula is as follows:

[0089] S = d·k -1 (H(M)+r·d)modn

[0090] Among them, k is a randomly generated integer, H(M) is the hash value of the data M (calculated using the SHA-256 algorithm), r = (k·G) i modn, G is the generating point of the elliptic curve, and n is the order of the elliptic curve.

[0091] At the same time, use the public key Q of the recipient to encrypt the data to obtain the ciphertext C: C = E Q (M). Send the encrypted data C, signature value S, and data identifier ID to the blockchain network together. E represents the encryption operation (Encryption operation), which means the process of encrypting the data M using the recipient's public key Q. Through a specific encryption algorithm, the original data M is converted into the ciphertext C. Only the recipient who has the private key corresponding to the public key Q can decrypt the ciphertext C to obtain the original data M, thus ensuring the security and privacy of the data during the transmission process.

[0092] 2.3 Blockchain Node Verification and Storage

[0093] After receiving the data, the blockchain node first verifies the validity of the signature using the sender's public key. By calculating:

[0094] r′ = (S·G + H(M)·Q) mod n

[0095] If r′ = (k·G) x mod n is valid, then the signature is valid, indicating that the data source is reliable.

[0096] Next, the node checks the integrity of the data according to the data identifier ID. By querying the data hash value stored in the previous block corresponding to this ID on the blockchain and comparing it with the hash value recalculated from the received data. If the two are consistent, it means the data has not been tampered with during transmission, and the data is stored in the local blockchain ledger; otherwise, a data anomaly alert is triggered.

[0097] S3. Multi-modal Data Fusion and Application

[0098] 3.1 Data Fusion and Feature Extraction Mechanism

[0099] At the data acquisition end, in addition to high-precision acquisition of voltage, current, and phase data, a dynamic association model among the three is established. For example, the phase difference information between voltage and current is used to judge the power factor and load characteristic changes of the power system. By calculating the ratio relationship between the voltage amplitude and the current amplitude in real time and combining the phase information, an equivalent impedance model of the power system is constructed, and the formula is as follows:

[0100]

[0101] where Z is the equivalent impedance, V and I are the voltage and current amplitudes respectively, and θ V 、θ I are the corresponding phase angles. This multi-modal data association not only enriches the amount of information in the data but also provides a more comprehensive perspective for subsequent analysis.

[0102] 3.2 Co-extraction of Time-frequency Domain Features

[0103] Time-frequency analysis techniques such as the Short-Time Fourier Transform (STFT) and Wavelet Packet Transform (WPT) are used to jointly extract features from voltage, current, and phase data. In STFT, by setting appropriate time windows and frequency resolutions, the data is transformed into the time-frequency domain to obtain the amplitude and phase information of each frequency component at different times, thereby capturing the transient changes and frequency fluctuation characteristics of the power signal. For WPT, it can perform more refined frequency band decomposition on the signal and extract the energy distribution and change trend characteristics of voltage, current, and phase within different frequency bands.

[0104] For the current data i(t), the energy E of the j-th frequency band after its wavelet packet decomposition ij can be calculated by the following formula:

[0105]

[0106] where c ij (k) is the wavelet packet coefficient of the j-th frequency band, N is the coefficient length. k is an index value representing the serial number of the coefficient, and its value range is from 1 to N, which is used to traverse the wavelet packet coefficient c ij (k) of the j-th frequency band to calculate the energy E ij of this frequency band. It takes values in sequence and is used to sum all the wavelet packet coefficients within a specific frequency band. These time-frequency domain features can effectively reflect the operation state differences of the current transformer under different working conditions and provide an important basis for fault diagnosis and condition assessment.

[0107] S4. (Blockchain network data) Access control system

[0108] The Attribute-Based Access Control (ABAC) model combined with blockchain smart contracts is used to implement data access control. A set of attributes is defined for each user and data resource, such as the user's role, department, permission level, and the sensitivity of the data, the affiliated device, etc.

[0109] Access control policy rules are defined in the smart contract, for example:

[0110] AccessGranted = (R = ADMIN) ∨ ((D = Monitoring Department) ∧ (P ≥ 3) ∧ (S ≤ 2))

[0111] R represents the user role, D represents the user's department, P represents the permission level, and S represents the data sensitivity level

[0112] According to the above formula, data access is allowed only when the user role is an administrator, or the user's department is the monitoring department and the permission level is greater than or equal to 3, and the data sensitivity level is less than or equal to 2.

[0113] When a user initiates a data access request, the smart contract evaluates based on the attributes of the user and the data and the predefined policy rules to decide whether to grant access permission.

[0114] S5. Anomaly detection mechanism

[0115] 5.1 GCN and attention mechanism fusion model architecture

[0116] Graph construction: The voltage, current, and phase data collected by the mutual inductor at different time points are regarded as the nodes of the graph, and the edges are constructed according to the time series and physical association of the data.

[0117] GCN layer: Let X be the input data matrix, where each row represents the feature vector of a node (including voltage, current, and phase information), and A be the adjacency matrix representing the connection relationship between nodes. The forward propagation formula of the GCN layer is as follows:

[0118]

[0119] where, (I is the identity matrix), is the degree matrix of, H(l) is the hidden state of the l-th layer, W(l) is the weight matrix of the l-th layer, and σ is the activation function (such as the ReLU function). Through the propagation of the GCN layer, the information of neighboring nodes can be aggregated to learn the global feature representation of the data.

[0120] Attention mechanism layer: Based on the output of the GCN layer, an attention mechanism is introduced to automatically focus on key data changes. Let H be the final output feature matrix of the GCN layer, and the attention mechanism calculates the attention weight a of each node:

[0121] a = softmax(W a ·tanh(W h H + b h ))

[0122] where, W a 、W h are the weight matrices, and b h is the bias vector. Then, the node features are weighted and summed through the attention weights to obtain the final feature representation Z:

[0123]

[0124] where N is the number of nodes, a i represents the attention weight of the i-th node, which reflects the importance of the i-th node in the calculation of the final feature representation. The larger the weight, the greater the contribution of the node to the final feature representation. H i represents the feature vector of the i-th node, which contains the relevant information of the node. For example, in the scenario of mutual inductor data security monitoring based on blockchain technology, it may contain data information such as voltage, current, and phase related to the mutual inductor. This attention mechanism can highlight important data nodes and improve the sensitivity of the model to abnormal data.

[0125] 5.2 Model training and optimization

[0126] First, collect a large amount of voltage, current, and phase data of the mutual inductor at different time points. After normalization, divide the data into training set, validation set, and test set according to a certain proportion. Initialize the weight matrices and bias vectors of the graph convolutional neural network layer and the attention mechanism layer, input the training set data into the model, calculate the error using the mean squared error loss function combined with adversarial training, and adjust the parameters through the Adam optimizer for iterative training. During the training process, evaluate with the validation set and adopt the early stopping method to prevent overfitting, and finally obtain a trained model. Specifically:

[0127] Perform normalization processing on the mutual inductor data collected in step 2 to make the voltage, current, and phase data within the same numerical range, which is convenient for model training. For example, for voltage data V, use the min-max normalization formula:

[0128]

[0129] where V min and V max are the minimum and maximum values of the voltage data respectively.

[0130] Optimize the model by combining the mean squared error (MSE) loss function with adversarial training. The MSE loss function is used to measure the error between the predicted value and the true value:

[0131]

[0132] where yt is the true data, is the predicted data, and N is the number of data samples. At the same time, introduce an adversarial training mechanism to enhance the robustness of the model through a generative adversarial network (GAN). The generator G attempts to generate fake data similar to the true data to deceive the discriminator D, and the discriminator D tries to distinguish between the true data and the generated data. Through this adversarial training process, the model can learn more stable and accurate feature representations, further improving the anomaly detection performance.

[0133] Finally, use the Adam optimizer to train the model and set an appropriate learning rate. During the training process, continuously adjust the weight matrices and bias vectors of the GCN layer and the attention mechanism layer to minimize the loss function. At the same time, adopt the early stopping method (EarlyStopping) to prevent overfitting. When the loss on the validation set no longer decreases, stop the training.

[0134] 5.3 Anomaly Detection and Warning Process

[0135] During the online monitoring process, the voltage, current, and phase data of the mutual inductor collected in real time first go through the same preprocessing steps as the training data, and then are input into the trained GCN-attention mechanism model. The model analyzes and predicts the input data according to the learned features and patterns.

[0136] When data anomalies are detected, the system immediately triggers a warning signal. According to preset rules, the smart contract accurately pushes notifications to relevant personnel such as operation and maintenance, scheduling, etc. The notification content includes the type of abnormal data (such as sudden voltage drop, excessive current harmonics, etc.), location, time, and possible analysis of the cause of the fault.

[0137] 5.4 Auxiliary for Optimized Operation of Power System

[0138] Using the real-time monitoring and analysis results of voltage, current, and phase data to provide decision-making support for the optimized operation of the power system. By analyzing the distribution of voltage amplitude and phase, dynamic compensation of reactive power and voltage regulation of the power system are realized. For example, according to the deviation ΔV of the voltage amplitude from the set reference value and the phase change, the switching and adjustment amount of reactive power compensation equipment are intelligently controlled. The formula is as follows:

[0139]

[0140] Where Q comp is the reactive power compensation amount, α and β are adjustment coefficients, dθ represents the small change in phase, which reflects the change in phase within a very small time interval; dt represents the small change in time, used to measure the very small interval in time; The whole represents the phase change rate, that is, how fast the phase changes with time. At the same time, combined with current data to monitor the load conditions of power equipment, optimize the operation and scheduling strategies of power equipment, improve the overall operation efficiency and reliability of the power system, and reduce energy consumption.

[0141] As described above, it is only the specific implementation manner of this application, but the protection scope of this application is not limited thereto. Any person skilled in the art within the technical scope disclosed in this application can easily think of changes or substitutions, which should all be covered within the protection scope of this application. Therefore, the protection scope of this application should be subject to the protection scope of the claimed rights.

Claims

1. A data security monitoring method for mutual inductor based on blockchain technology, characterized in that: include: Build a blockchain network, set up network nodes for transformer data collection equipment, power data processing center, power management terminal and relevant regulatory agencies, and adopt a hybrid consensus mechanism combining proof of work and proof of stake; Collect the electrical parameters, environmental parameters and operating parameters of the transformer in real time, and then group and package the processed data regularly to form a structured data packet containing continuous sampling values ​​of multiple parameters, and use the relevant information combination of timestamp, equipment number and data sequence number to generate a unique data identifier; The structured data packet is processed using an ECDSA asymmetric encryption algorithm; After receiving the encrypted data, signature value and data identifier, the network node first verifies the validity of the signature with the sender's public key. If it is valid, it queries the data hash value stored in the previous block on the blockchain based on the data identifier and compares it with the hash value recalculated from the received data. If the two are consistent, they are stored in the local blockchain ledger, otherwise an abnormal alarm is triggered; Establish a dynamic correlation model of voltage, current and phase at the data acquisition end of the transformer; Use time-frequency analysis technology to perform joint feature extraction on voltage, current, and phase data to obtain the amplitude and phase information of each frequency component at different times, as well as the energy distribution and change trend characteristics of voltage, current, and phase in different frequency bands; The attribute-based access control model is combined with blockchain smart contracts to define attributes for users and data resources respectively, and set access control policy rules in blockchain smart contracts. When a user initiates a data access request, the smart contract evaluates the attributes of the user and data and the predefined rules to decide whether to grant access rights. The voltage, current, and phase data collected by the transformer at different time points are defined as graph nodes, and edges are constructed according to the time series and physical association of the data to form a data graph structure. The transformer data collected in S21 are normalized and the model is trained. The transformer data collected in real time is first preprocessed and then input into the trained model for analysis and prediction, and abnormal signal warning is performed.

2. According to a method for monitoring data security of a mutual inductor based on blockchain technology according to claim 1, it is characterized in that: In the proof of work part, the network nodes compete for the right to record accounts by calculating hash puzzles. The calculation formula is as follows: Hash(block_header)≤target Among them, block_header is the block header information, including the hash value of the previous block, timestamp, and Merkle root. It is the target hash value dynamically adjusted according to the network difficulty. The node finds the hash value that satisfies the above formula by continuously changing the random number in the block header. The node that finds it first obtains the accounting right and adds the new block to the blockchain.

3. According to a method for monitoring data security of a mutual inductor based on blockchain technology as claimed in claim 2, it is characterized in that: In the proof of stake part, the probability of the network node being selected as the verification block is calculated as follows: Among them, Pi is the probability of node i being selected, stake i is the equity of node i, stake j is the stake of node j, and n is the total number of nodes in the network.

4. According to a method for monitoring data security of a mutual inductor based on blockchain technology as claimed in claim 1, it is characterized in that: After real-time acquisition of the electrical parameters, environmental parameters and operating parameters of the transformer, the 3σ principle based on statistics is used to remove abnormal values ​​and noise data. Assume that a certain data sequence collected is x1, x2, x3, ..., x n , whose mean is The standard deviation is σ, then Data point x i were considered as outliers and removed.

5. According to a method for monitoring data security of mutual inductors based on blockchain technology according to claim 1, it is characterized in that: The ECDSA asymmetric encryption algorithm uses the private key d to sign each set of data M and generate a signature value S. The calculation formula is as follows: S=d·k -1 (H(M)+r·d)modn Where k is a randomly generated integer, H(M) is the hash value of data M, and r = (k·G) i modn, G is the generator point of the elliptic curve, n is the order of the elliptic curve; Use the recipient's public key Q to encrypt the data and obtain the ciphertext C: C = E Q (M), sending the encrypted data C, signature value S and data identifier to the blockchain network E represents an encryption operation. Through the encryption algorithm, the original data M is converted into ciphertext C. The recipient who has the private key corresponding to the public key Q has the authority to decrypt the ciphertext C, thereby obtaining the original data M.

6. According to claim 5, a method for monitoring data security of mutual inductors based on blockchain technology is characterized in that: The algorithm for verifying the validity of the signature by the sender's public key is: r′=(S·G+H(M)·Q)modn If r′=(k·G) x If modn is valid, the signature is valid.

7. According to a method for monitoring data security of mutual inductors based on blockchain technology as claimed in claim 1, it is characterized in that: By calculating the ratio of voltage amplitude to current amplitude in real time and combining phase information, an equivalent impedance model of the power system is constructed. The formula is as follows: Where Z is the equivalent impedance, V and I are the voltage and current amplitudes respectively, θ V ,θ I is the corresponding phase angle.

8. According to a method for monitoring data security of a mutual inductor based on blockchain technology as claimed in claim 1, it is characterized in that: The time-frequency analysis technology includes short-time Fourier transform and wavelet packet transform, wherein for the current data i(t), the j-th frequency band energy E after wavelet packet transform decomposition is ij Calculated by the following formula: where c ij (k) is the wavelet packet coefficient of the jth frequency band, N is the coefficient length, and k is an index value indicating the sequence number of the coefficient.

9. The method for data security monitoring of mutual inductors based on blockchain technology according to claim 1 is characterized in that: The access control policy rules defined in the smart contract are expressed as: AccessGranted=(R=ADMIN)∨((D=Monitoring Department)∧(P≥3)∧(S≤2)) R represents the user role, D represents the user's department, P represents the permission level, and S represents the data sensitivity level. When the user role is administrator, or the user's department is the monitoring department and the permission level is greater than or equal to 3, and the data sensitivity level is less than or equal to 2, the user has permission to access the data.

10. The method for data security monitoring of mutual inductors based on blockchain technology according to claim 1 is characterized in that: After the data graph structure is formed, the graph convolutional neural network layer is used to aggregate neighbor node information to learn the global feature representation of the data, and then the attention mechanism layer is used to automatically focus on key data changes. Let H be the final output feature matrix of the GCN layer, and the attention mechanism calculates the attention weight a of each node: a=softmax(W a ·tanh(W h H+b h )) Among them, W a , W h is the weight matrix, b h is the bias vector; Then, the node features are weighted and summed by the attention weights to obtain the final feature representation Z: Where N is the number of nodes, a i H represents the attention weight of the ith node, which reflects the importance of the ith node in the calculation of the final feature representation. The larger the weight, the greater the contribution of the node to the final feature representation. i Represents the feature vector of the i-th node.

11. The method for data security monitoring of mutual inductors based on blockchain technology according to claim 1 is characterized in that: The transformer data is normalized so that the voltage, current and phase data are within the same numerical range. For the voltage data V, the minimum-maximum normalization formula is: Where V min and V max are the minimum and maximum values ​​of the voltage data respectively.

12. The method for data security monitoring of mutual inductors based on blockchain technology according to claim 11 is characterized in that: After normalization, the model is optimized by combining the mean square error loss function with adversarial training. The mean square error loss function is used to measure the error between the predicted value and the true value: Among them, y t It is real data. is the predicted data, and N is the number of data samples.

13. The method for data security monitoring of mutual inductors based on blockchain technology according to claim 1 is characterized in that: After analyzing and predicting the transformer data, the switching and adjustment of the reactive compensation equipment are intelligently controlled according to the deviation ΔV between the voltage amplitude and the set reference value and the phase change. The formula is as follows: Where Q comp is the reactive compensation amount, α and β are adjustment coefficients, dθ represents the small change in phase, which reflects the degree of change in phase within a very small time interval; dt represents the small change in time, which is used to measure the very small interval in time; The overall value represents the phase change rate, that is, how fast the phase changes over time.