A power grid fault measurement system and method based on hydrogen production by electrolyzing water
By designing a grid fault measurement system in the electrolytic water hydrogen production system, using harmonic analysis and adaptive filtering technology to monitor the power quality of the grid in real time, and dynamically adjusting the hydrogen production process through the decision tree algorithm, the impact of power grid faults on the hydrogen production process is solved, and efficient and stable hydrogen production is achieved.
Patent Information
- Application Number
- CN202410992233.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-23
- Publication Date
- 2025-05-30
- Estimated Expiration
- 2044-07-23
AI Technical Summary
The existing power grid fault detection technology cannot effectively monitor and respond to changes in the grid quality in real time, resulting in the impact of the efficiency and stability of the electrolytic hydrogen production process.
A power grid fault measurement system based on electrolytic water hydrogen production is designed, including power input module, fault detection module, hydrogen production unit, control center and communication module. The system monitors the power quality of the power grid in real time through harmonic analysis algorithm, adaptive filtering technology and asymmetric fault monitoring algorithm, and dynamically adjusts the operating status of the hydrogen production unit through the control center and decision tree algorithm.
It realizes rapid identification and response to power grid faults, ensures efficient and stable operation of the hydrogen production process, improves hydrogen yield and reduces energy consumption.
Smart Images

Figure CN119199372B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of power grid fault detection, and particularly to a power grid fault measurement system and method based on electrolytic water hydrogen production. Background Art
[0002] The electrolytic water hydrogen production technology is a method of decomposing water into hydrogen and oxygen, which is widely used in the energy industry, especially in the fields of renewable energy and green energy. Hydrogen, as a clean energy carrier, is of great significance for achieving the low-carbon transformation of the energy structure. However, the efficiency and stability of electrolytic water hydrogen production highly depend on the quality of the power supply system, especially the stable supply of electricity.
[0003] In the prior art, power fluctuations and faults in the power grid, such as voltage instability, frequency fluctuations, harmonic interference, and unbalanced loads, often affect the operation efficiency and lifespan of electrolytic equipment. Especially when the power grid is unstable or fails, the electrolytic equipment may not be able to effectively adjust its operating parameters, resulting in a decrease in hydrogen production rate and even equipment damage.
[0004] Current power grid fault detection technologies are usually limited to basic monitoring, such as simple measurement of voltage and current, and cannot comprehensively reflect the specific impact of the power grid state on the electrolytic water hydrogen production process. In addition, existing fault response measures are often slow to respond and lack targeted automatic adjustment strategies, making it difficult for hydrogen production facilities to maintain an optimal operating state in the face of power grid fluctuations and faults.
[0005] Therefore, there is an urgent need to develop a system that can monitor and respond to changes in power grid quality in real time to ensure the efficient and stable operation of the electrolytic water hydrogen production process. Summary of the Invention
[0006] Based on the above objectives, the present invention provides a power grid fault measurement system and method based on electrolytic water hydrogen production.
[0007] A power grid fault measurement system based on electrolytic water hydrogen production includes a power input module, a fault detection module, a hydrogen production unit, a control center, and a communication module, where:
[0008] The power input module is used to receive the power signal provided by the external power grid and is equipped with voltage and current sensors for real-time monitoring of the voltage, current, and frequency of the power system;
[0009] The fault detection module specifically includes:
[0010] Harmonic analysis algorithm: Based on the discrete Fourier transform (DFT), extract and analyze the harmonic components from the power signal, identify and quantify the harmonics in real time, and promptly detect the harmonic levels exceeding the standard;
[0011] Harmonic filtering unit: Adopts adaptive filtering technology, dynamically adjusts filtering parameters according to the output of the harmonic analysis algorithm, reduces harmonic interference, and protects the hydrogen production unit from the influence of harmonics;
[0012] Asymmetric fault monitoring algorithm: Adopts vector combination and phase angle analysis methods to detect and evaluate the phase imbalance in the power grid, and quickly identifies single-phase grounding and two-phase short-circuit asymmetric faults;
[0013] The hydrogen production unit is connected to the power input module, and electrolyzes water according to the received processed power to generate hydrogen. This unit is equipped with inverter technology to adapt to the power quality received from the power input module;
[0014] The control center receives the output results of the asymmetric fault monitoring algorithm in the fault detection module, and adjusts the working state of the hydrogen production unit to cope with the impact brought by the power grid fault;
[0015] The communication module is used to feedback the decisions of the control center and the status information of the hydrogen production unit, as well as the power grid faults and their handling status to the power grid operator or maintenance personnel.
[0016] Preferably, the power input module further includes a power interface, which is designed to be connected to the external power grid and receive the AC power signal provided by the external power grid through a circuit configuration including switches and protection devices.
[0017] Preferably, the discrete Fourier transform DFT extracts and analyzes the harmonic components from the power signal specifically including:
[0018] For a signal sequence composed of N sample points , its DFT is defined as: , where, is the kth point in the frequency domain, representing the complex form of the frequency component, j is the imaginary unit, N is the total number of samples, k is the frequency index, ;
[0019] In harmonic analysis, DFT is used to identify and quantify the harmonic components in the power grid signal:
[0020] Signal sampling: Convert the power signal of the power grid into a discrete signal through a preset sampling frequency f s ; ;
[0021] Apply DFT: Perform DFT calculation on the sampled signal to obtain the amplitude and phase of each frequency component;
[0022] Harmonic identification: By analyzing the results of, identify the fundamental wave;
[0023] Quantized harmonics: Calculate the amplitude of each harmonic frequency component , and compare it with the threshold of the harmonics.
[0024] Preferably, the adaptive filtering technology specifically includes:
[0025] According to the calculated amplitude of each harmonic frequency component , use an adaptive infinite impulse response filter to compensate for and suppress harmonic components by dynamically adjusting the filter parameters;
[0026] Implement the least mean square error algorithm to optimize the adaptive adjustment of the filter parameters, and dynamically update the filter coefficients by minimizing the error between the filtered signal and the ideal signal.
[0027] Preferably, the output of the adaptive infinite impulse response filter depends not only on the input signal but also on the past output, and the expression is:
[0028] , where is the input signal, is the output signal, b i is the forward filter coefficient, a j is the feedback filter coefficient, and M and Z are the numbers of the forward and feedback filter coefficients respectively.
[0029] Preferably, the asymmetric fault monitoring algorithm in the fault detection module uses the vector combination and phase angle analysis method to detect and evaluate the phase imbalance in the power grid, calculates the vector sum and phase angle of the three-phase voltage or current signals received from the power input module, calculates whether there is an imbalance between the phases by comparing the vector lengths and included angles of the phase voltages or currents, and determines the fault type according to the deviation of the vector angle.
[0030] Preferably, the calculation of the asymmetric fault monitoring algorithm includes:
[0031] Obtain the real-time data of the three-phase currents I A , I B and I C from the power input module;
[0032] Calculate the phase vectors: For each sampling point, calculate the instantaneous values of the three-phase currents, and calculate the phase vectors V A , V B and V C :
[0033] ; where is the phase factor, which is used to convert the real current value into a phase vector on the complex plane;
[0034] Phase imbalance detection: Calculate the balance of the three-phase current vectors, using the modulus of the vector sum: ;
[0035] Fault type identification: Use the angle and modulus of the vector sum to identify specific asymmetric fault types.
[0036] Preferably, the control center further includes a machine learning model. The machine learning model receives the asymmetric fault input data from the fault detection module, including the phase imbalance degree, the actual phase angle difference, and the voltage deviation, and uses the input data to predict and calculate the optimal voltage and current output settings of the hydrogen production unit, as well as the recommended rate of hydrogen production;
[0037] The machine learning model adopts a decision tree. According to the severity and type of the asymmetric fault, it dynamically adjusts the output parameters of the inverter, and optimizes the operation efficiency of the hydrogen production unit in real time. It also adjusts the electrolysis current density and electrolysis time during the hydrogen generation process to adapt to the changes in the grid conditions.
[0038] Preferably, the decision tree specifically includes:
[0039] Define the input features of the decision tree model as follows:
[0040] Phase imbalance degree: Characterize the imbalance degree of the voltage or current between the three-phase electricity;
[0041] Actual phase angle difference: The phase angle difference between the three phases, used to identify the type and severity of the asymmetry;
[0042] Voltage deviation: The deviation between the phase voltage and its ideal value, which is an absolute value or a relative value;
[0043] Decision tree model training: Use historical data to train a decision tree model. The historical data includes different types of asymmetric faults and their impacts on the performance of the hydrogen production unit. During the training process, the model learns how to predict the optimal parameter adjustments of the hydrogen production unit according to the input asymmetric fault features, including the inverter output voltage, the inverter output current, the hydrogen production rate, the electrolysis current density, and the electrolysis time;
[0044] Real-time prediction and adjustment: When the system receives the data from the fault detection module in real time, the decision tree model immediately calculates and outputs the corresponding adjustment suggestions. Using the input phase imbalance degree, actual phase angle difference, and voltage deviation, it predicts and recommends the optimal output voltage and current settings of the inverter, and at the same time provides adjustment suggestions on the hydrogen production rate, electrolysis current density, and electrolysis time;
[0045] Based on the output of the decision tree model, the control system dynamically adjusts the settings of the inverter: adjusts the voltage output ΔV and current output ΔI of the inverter to ensure maximizing the production and quality of hydrogen under the current grid state, adjusts the production rate of hydrogen and the electrolysis current density, and adjusts the electrolysis time to adapt to the impact of asymmetric loads on the electrolysis process;
[0046] The process of constructing the decision tree is as follows:
[0047] Select the best splitting feature and splitting point: Entropy or Gini impurity is the criterion for determining how to select the splitting feature and splitting point. For each node, the decision tree algorithm traverses all features and their splitting points to calculate the information gain or the reduction of Gini impurity. The entropy calculation formula:
[0048] , where p i is the proportion of the i-th class target value in the set S;
[0049] Information gain calculation: , where A is the feature under consideration, and S v is the subset of feature A at value v, is the entropy of the subset. The Gini impurity calculation formula:
[0050] ;
[0051] Recursively construct the tree: For each node, use the above formula to select the best splitting feature and point, and divide the data set into two subsets;
[0052] Recursively apply the same method to each subset until the stopping condition is met;
[0053] To prevent overfitting, pruning of the tree is required. Cost complexity pruning is used, where a parameter is used to balance the depth of the tree and the training error.
[0054] A method for measuring grid faults based on hydrogen production by electrolyzing water is implemented by the above-mentioned grid fault measurement system for hydrogen production by electrolyzing water, and includes the following steps:
[0055] S1: Power reception and monitoring. Connect to the external grid, receive AC power signals through the power interface, and use voltage and current sensors to monitor and record the voltage, current, and frequency data of the power system in real time;
[0056] S2: Fault data processing and analysis. Use the harmonic analysis algorithm to process the received power signals, digitize the continuous power signals, apply the discrete Fourier transform to calculate their spectral data, identify and analyze the harmonic components in the power signals, calculate the amplitude and phase of each harmonic frequency component, and compare with the preset harmonic threshold to monitor and quantify the harmonic levels exceeding the standard in real time;
[0057] S3: Harmonic filtering and compensation. If the harmonics exceed the safety threshold, use the adaptive infinite impulse response filter in the harmonic filtering unit to dynamically adjust the filtering parameters according to the output of the harmonic analysis algorithm, and compensate and suppress the harmonic components.
[0058] S4: Asymmetric fault monitoring and response. Apply the asymmetric fault monitoring algorithm. By calculating the vector sum and phase angle of the three-phase current or voltage, detect and evaluate the phase imbalance in the power grid. According to the comparison of the vector length and angle, identify whether there is an asymmetric fault.
[0059] S5: Control and adjustment. According to the output result of S4, adjust the working state of the hydrogen production unit to cope with the impact brought by the power grid fault.
[0060] Advantages of the present invention:
[0061] By integrating advanced fault detection modules and adaptive control algorithms, the present invention can monitor the power quality of the power grid in real time and quickly respond to the detected power grid faults (such as asymmetric faults and harmonic interference). The control center predicts and adjusts the output parameters of the inverter through the decision tree algorithm to ensure that the hydrogen production unit can maintain the optimal operating conditions when a power grid fault occurs. This dynamic adjustment mechanism greatly improves the power utilization efficiency and reaction stability in the process of electrolytic water hydrogen production, thereby increasing the hydrogen production rate and reducing the energy consumption.
[0062] By implementing fault detection and response, the electrolytic water hydrogen production facility can detect and respond to power grid faults at the initial stage, significantly improving the reliability of the system. Especially when dealing with the asymmetric load and harmonic problems of the power grid, it can avoid equipment damage or operation failures caused by unstable power supply, ensuring the continuity and safety of the entire hydrogen production process. In addition, the adaptive adjustment of the inverter output also helps to optimize the working state of the electrolytic cell, avoiding safety risks caused by abnormal voltage or current.
[0063] The intuitive decision-making path and prediction results provided by the decision tree algorithm of the present invention not only enable operators to understand and track the adjustment logic of the system, but also provide a scientific basis for daily maintenance, reducing the operation risk and improving the maintenance efficiency. In addition, the intelligent design of the system helps to identify potential fault risks in advance, providing support for formulating preventive maintenance strategies, thereby reducing the incidence of unexpected shutdowns and maintenance costs. Description of the Drawings
[0064] To more clearly illustrate the technical solutions in the present invention or the prior art, the following will briefly introduce the accompanying drawings required for the description of the embodiments or the prior art. Obviously, the accompanying drawings in the following description are only those of the present invention. For those of ordinary skill in the art, without creative efforts, other drawings can also be obtained based on these drawings.
[0065] Figure 1 Schematic diagram of the functional modules of the measurement system according to an embodiment of the present invention;
[0066] Figure 2 Schematic diagram of the measurement method process according to an embodiment of the present invention. Detailed implementation manners
[0067] The following further elaborates on the present invention in conjunction with specific embodiments.
[0068] As Figure 1 shown, a power grid fault measurement system based on hydrogen production by electrolysis of water includes a power input module, a fault detection module, a hydrogen production unit, a control center, and a communication module, where:
[0069] The power input module is used to receive the power signal provided by the external power grid and is equipped with voltage and current sensors for real-time monitoring of the voltage, current, and frequency of the power system.
[0070] The fault detection module specifically includes:
[0071] Harmonic analysis algorithm: Based on the discrete Fourier transform (DFT), extract and analyze the harmonic components from the power signal, identify and quantify the harmonics in real time, and promptly detect the harmonic levels exceeding the standard.
[0072] Harmonic filtering unit: Adopt adaptive filtering technology to dynamically adjust the filtering parameters according to the output of the harmonic analysis algorithm, reduce harmonic interference, and protect the hydrogen production unit from the influence of harmonics.
[0073] Asymmetric fault monitoring algorithm: Adopt the vector combination and phase angle analysis method to detect and evaluate the phase imbalance in the power grid, and quickly identify single-phase grounding and two-phase short-circuit asymmetric faults.
[0074] The hydrogen production unit is connected to the power input module and performs the electrolysis reaction of water based on the received processed power to generate hydrogen. This unit is equipped with inverter technology to adapt to the power quality received from the power input module.
[0075] The hydrogen production unit includes an electrolyzer and an inverter, and this hydrogen production unit is connected to the power input module. The power input module receives and processes the power signal provided by the external power grid. After harmonic filtering and handling of asymmetric faults, it transmits the optimized power to the hydrogen production unit. The inverter technology within the hydrogen production unit is used to convert the received alternating current into direct current suitable for water electrolysis, ensuring a stable supply of current and voltage. The output parameters (voltage and current) of the inverter are dynamically adjusted according to the power quality data received from the fault detection module to adapt to changes in power quality and maximize hydrogen production rate and energy efficiency. The electrolyzer uses the adjusted direct current to carry out the electrolysis reaction of water, thereby producing hydrogen.
[0076] The control center receives the output results of the asymmetric fault monitoring algorithm in the fault detection module and adjusts the operating state of the hydrogen production unit to cope with the impact brought by grid faults;
[0077] The communication module is used to feedback the decisions of the control center, the status information of the hydrogen production unit, as well as the grid faults and their handling status to the grid operator or maintenance personnel.
[0078] The power input module also includes a power interface, which is designed to be connected to the external power grid and receive the alternating current power signal provided by the external power grid through a circuit configuration including switches and protection devices.
[0079] The harmonic analysis algorithm in the fault detection module processes the power signal received by the power input module by using the discrete Fourier transform (DFT) to extract and analyze the harmonic components in the power signal. First, the continuous power signal is digitized, and then the DFT is applied to calculate its spectrum, thereby separating and identifying harmonics of different frequencies, further calculating the amplitude and phase of each harmonic, and comparing them with the preset harmonic thresholds to monitor and quantify the harmonic levels exceeding the standard in real time.
[0080] The extraction and analysis of harmonic components from the power signal by the discrete Fourier transform DFT specifically include:
[0081] For a signal sequence consisting of N sample points , its DFT is defined as: , where is the k-th point in the frequency domain, representing the complex form of the frequency component, j is the imaginary unit, N is the total number of samples, k is the frequency index, ;
[0082] In harmonic analysis, the DFT is used to identify and quantify the harmonic components in the grid signal:
[0083] Signal sampling: The power signal of the power grid is converted into a discrete signal through a preset sampling frequency f s ;
[0084] Apply DFT: For the sampled signal perform DFT calculation to obtain the amplitude and phase of each frequency component;
[0085] Harmonic identification: By analyzing the results, identify the fundamental wave (50 Hz or 60 Hz);
[0086] Quantify harmonics: Calculate the amplitude of each harmonic frequency component
[0087] and compare it with the threshold of the harmonics. The judgment of harmonic over - standard is based on comparison with the set safety threshold. When the amplitude of one or more harmonics exceeds the threshold, the algorithm reports this information to the control center of the system, triggering necessary response measures such as adjusting the load, starting the harmonic filtering device, etc.
[0088] In the electrolytic water hydrogen production system, when analyzing harmonic components, it is necessary to focus on the influence of low - order harmonics (such as the third, fifth, and seventh harmonics), which have a more direct impact on the efficiency and lifespan of the electrolyzer. Compared with high - order harmonics, low - order harmonics are more likely to cause thermal effects and electrochemical instabilities in the electrolysis reaction. Therefore, the harmonic analysis algorithm should be specifically designed to identify and quantify these key harmonic components and take corresponding measures to reduce their influence. The value of k corresponds to an integer multiple of the fundamental wave frequency of 50 Hz, such as k = 3, 5, 7, etc., which are the harmonics that most affect the system performance during the hydrogen production process.
[0089] The adaptive filtering technology specifically includes:
[0090] According to the calculated amplitude of each harmonic frequency component use an adaptive infinite impulse response filter to compensate for and suppress harmonic components by dynamically adjusting the filter parameters;
[0091] Implement the least mean square error algorithm to optimize the adaptive adjustment of the filter parameters, and dynamically update the filter coefficients by minimizing the error between the filtered signal and the ideal signal.
[0092] The output of the adaptive infinite impulse response filter depends not only on the input signal but also on the past output, and the expression is:
[0093] , where is the input signal, is the output signal, b i are the forward filter coefficients, a j are the feedback filter coefficients, and M and Z are the numbers of the forward and feedback filter coefficients respectively.
[0094] The least mean square error algorithm is used to dynamically update the coefficients of the filter to minimize the mean square value of the error signal, and the steps are as follows:
[0095] Initialize parameters: Select the step size μ (learning rate) and initialize the filter coefficients b i and a j ;
[0096] Iterative process: For each sample n, perform the following operations:
[0097] 1. Calculate the output: Calculate the output using the current filter coefficients .
[0098] 2. Calculate the error: The error is the difference between the desired signal (i.e., the ideal signal output) and the actual output : .
[0099] 3. Update the filter coefficients:
[0100] Update the forward coefficient b i : ;
[0101] Update the feedback coefficient a j : ; where μ needs to be refined to ensure the stability and convergence of the system.
[0102] The parameters of the filter are updated in real time according to the data obtained from harmonic analysis to ensure the optimization of power quality during the electrolytic water hydrogen production process. The system continuously monitors the quality of the output signal and adjusts the filter coefficients according to the difference between the actual output and the desired output to achieve the best harmonic suppression effect.
[0103] The asymmetric fault monitoring algorithm in the fault detection module uses vector combination and phase angle analysis methods to detect and evaluate the phase imbalance in the power grid. First, calculate the vector sum and phase angle of the three-phase voltage or current signals received from the power input module. By comparing the vector lengths and angles of the voltages or currents of each phase, calculate and detect whether there is an imbalance between the phases, such as a single-phase voltage being significantly lower than the other two phases or the voltages of two phases being close while the third phase deviates from these values. In addition, determine the fault type according to the deviation of the vector angle. For example, a single-phase ground fault usually shows a large difference in the vector angle between one phase and the other two phases, while a two-phase short circuit fault shows that the vectors of two phases are almost coincident and the third phase deviates. This algorithm can process signals in real time to ensure the rapid identification and accurate evaluation of power grid faults.
[0104] The calculations included in the asymmetric fault monitoring algorithm are as follows:
[0105] Obtain the three-phase current I from the power input module A , I B and I C of real-time data. The sampling frequency should be high enough to ensure the time resolution and accuracy of the signal;
[0106] Calculate the phase vector: For each sampling point, calculate the instantaneous values of the three-phase current and calculate the phase vectors V A , V B and V C :
[0107] ; where is the phase factor used to convert the real current value into a phase vector on the complex plane;
[0108] Phase imbalance detection: Calculate the balance of the three-phase current vectors using the modulus of the vector sum: , for a completely balanced three-phase system, should be close to zero;
[0109] Fault type identification: Use the angle and modulus of the vector sum to identify specific asymmetric fault types, specifically including:
[0110] Single-phase ground fault: If the vector amplitude of a certain phase is much smaller than the other two phases, and is significantly non-zero;
[0111] Two-phase short circuit fault: If the vector directions of two phases are close or coincide, and the vector of the third phase forms a large angle with the vector sum of these two phases.
[0112] The control center also includes a machine learning model. The machine learning model receives the asymmetric fault input data from the fault detection module, including the phase imbalance degree, actual phase angle difference, and voltage deviation, and uses the input data to predict and calculate the optimal voltage and current output settings of the hydrogen production unit, as well as the recommended rate of hydrogen production;
[0113] The machine learning model uses a decision tree. According to the severity and type of asymmetric faults, it dynamically adjusts the output parameters of the inverter, and optimizes the operating efficiency of the hydrogen production unit in real time. It also adjusts the electrolysis current density and electrolysis time during the hydrogen generation process to adapt to the changes in grid conditions, ensuring the continuous production and stable quality of hydrogen. This algorithm enables the hydrogen production unit not only to respond to the current grid state but also to predict future changes, thereby achieving higher operation flexibility and overall system robustness.
[0114] The decision tree specifically includes:
[0115] Define the input features of the decision tree model as follows:
[0116] Phase unbalance degree: Characterizes the degree of voltage or current imbalance between three-phase electricity;
[0117] Actual phase angle difference: The phase angle difference between three phases, used to identify the type and severity of asymmetry;
[0118] Voltage deviation: The deviation between the voltage of each phase and its ideal value, which can be an absolute value or a relative value;
[0119] Decision tree model training: Use historical data to train a decision tree model. The historical data includes different types of asymmetry faults and their impacts on the performance of the hydrogen production unit. During the training process, the model learns how to predict the optimal adjustment of hydrogen production unit parameters based on the input asymmetry fault characteristics, including the inverter output voltage, inverter output current, hydrogen production rate, electrolysis current density, and electrolysis time;
[0120] Real-time prediction and adjustment: When the system receives data from the fault detection module in real time, the decision tree model immediately calculates and outputs the corresponding adjustment suggestions. Using the input phase unbalance degree, actual phase angle difference, and voltage deviation, it predicts and recommends the optimal output voltage and current settings of the inverter, and at the same time provides adjustment suggestions for the hydrogen production rate, electrolysis current density, and electrolysis time;
[0121] According to the output of the decision tree model, the control system dynamically adjusts the settings of the inverter: Adjust the voltage output ΔV and current output ΔI of the inverter to ensure maximizing the production and quality of hydrogen under the current grid state, adjust the hydrogen production rate and electrolysis current density, and adjust the electrolysis time to adapt to the impact of asymmetric loads on the electrolysis process.
[0122] The process of constructing the decision tree is as follows:
[0123] Select the best splitting feature and splitting point: Entropy or Gini impurity is the criterion for determining how to select the splitting feature and splitting point. For each node, the decision tree algorithm traverses all features and their splitting points to calculate the reduction of information gain or Gini impurity. The entropy calculation formula:
[0124] where p i is the proportion of the i-th class target value in the set S;
[0125] Information gain calculation: where A is the feature under consideration, and S v is the subset of feature A at value v, is the entropy of the subset. The Gini impurity calculation formula:
[0126] ;
[0127] Recursively construct the tree: For each node, use the above formula to select the best splitting feature and point, and divide the dataset into two subsets;
[0128] Recursively apply the same method to each subset until the stopping condition is met (such as the number of samples under the node is less than a certain threshold, or the preset depth of the tree is reached).
[0129] To prevent overfitting, pruning of the tree is required. Cost complexity pruning is used, where a parameter is used to balance the depth of the tree and the training error.
[0130] The decision tree is trained as follows:
[0131] The decision tree model needs to learn from historical data. Prepare a set of historical fault data and the corresponding optimal hydrogen production unit response parameters. Each data point includes:
[0132] Input features: x 1 : Phase unbalance; x 2 : Actual phase angle difference; x 3 : Voltage deviation;
[0133] Output response: y 1 : Inverter output voltage adjustment (ΔV); y 2 : Inverter output current adjustment (ΔI); y 3 : Hydrogen production rate; y 4 : Electrolysis current density; y 5 : Electrolysis time;
[0134] Decision tree splitting: The decision tree minimizes the impurity of the target variable within the node by selecting the best splitting feature and splitting point at each node. For example, the decision tree selects x 1 (Phase unbalance) as the splitting feature and divides the data into two parts according to the magnitude of the unbalance. Each branch continues to split until the stopping condition is met (such as the maximum depth of the tree or the minimum number of samples in the node);
[0135] Decision rules and output prediction: Once the decision tree is established, for new input data, the tree will classify the data along the path from the root to the leaf until the leaf node is reached. Each leaf node stores the average value of the optimal response output corresponding to the historical data of the input features based on this path. If the new input data falls into a specific leaf node, the node recommends the following response:
[0136] ; ; The hydrogen production rate increases by 5%; the electrolysis current density is adjusted by 20%; the electrolysis time is extended by 10%.
[0137] Such as Figure 2As shown, a power grid fault measurement method based on electrolytic water hydrogen production is implemented by the above-mentioned power grid fault measurement system based on electrolytic water hydrogen production, and includes the following steps:
[0138] S1: Power reception and monitoring. Connect to the external power grid, receive AC power signals through the power interface, and use voltage and current sensors to monitor and record the voltage, current, and frequency data of the power system in real time.
[0139] S2: Fault data processing and analysis. Use the harmonic analysis algorithm to process the received power signals, digitize the continuous power signals, apply the discrete Fourier transform to calculate their spectral data, identify and analyze the harmonic components in the power signals, calculate the amplitude and phase of each harmonic frequency component, and compare them with the preset harmonic thresholds to monitor and quantify the harmonic levels exceeding the standards in real time.
[0140] S3: Harmonic filtering and compensation. If the harmonics exceed the safety threshold, use the adaptive infinite impulse response filter in the harmonic filtering unit to dynamically adjust the filtering parameters according to the output of the harmonic analysis algorithm, and compensate and suppress the harmonic components.
[0141] S4: Asymmetric fault monitoring and response. Apply the asymmetric fault monitoring algorithm to detect and evaluate the phase imbalance in the power grid by calculating the vector sum and phase angle of the three-phase current or voltage, and identify whether there is an asymmetric fault according to the comparison of the vector length and angle.
[0142] S5: Control and adjustment. According to the output result of S4, adjust the working state of the hydrogen production unit to cope with the impact brought by the power grid fault.
Claims
1. A power grid fault measurement system based on water electrolysis to produce hydrogen, characterized in that: It includes power input module, fault detection module, hydrogen production unit, control center and communication module, among which: The power input module is used to receive power signals provided by the external power grid and is equipped with voltage and current sensors to monitor the voltage, current and frequency of the power system in real time; The fault detection module specifically includes: Harmonic analysis algorithm: Based on discrete Fourier transform (DFT), it extracts and analyzes harmonic components from power signals, identifies and quantifies harmonics in real time, and promptly detects harmonic levels that exceed the standard; Harmonic filtering unit: Adaptive filtering technology is used to dynamically adjust filtering parameters according to the output of the harmonic analysis algorithm to reduce harmonic interference and protect the hydrogen production unit from harmonic influence; Asymmetric fault monitoring algorithm: uses vector combination and phase angle analysis methods to detect and evaluate phase imbalance in the power grid and quickly identify single-phase grounding and two-phase short circuit asymmetric faults; The hydrogen production unit is connected to the power input module, and performs a water electrolysis reaction according to the processed power received to produce hydrogen. The hydrogen production unit is equipped with inverter technology to adapt to the power quality received from the power input module; The control center receives the output result of the asymmetric fault monitoring algorithm in the fault detection module and adjusts the working state of the hydrogen production unit to cope with the impact of the power grid fault; The control center also includes a machine learning model that receives asymmetric fault input data from the fault detection module, including phase imbalance, actual phase angle difference, and voltage deviation, and uses the input data to predict and calculate optimal voltage and current output settings for the hydrogen production unit, as well as a recommended rate of hydrogen production; The machine learning model uses a decision tree to dynamically adjust the inverter output parameters according to the severity and type of asymmetric faults and optimize the operating efficiency of the hydrogen production unit in real time. It also adjusts the electrolysis current density and electrolysis time during the hydrogen generation process to adapt to changes in grid conditions. The communication module is used to feed back the decision of the control center and the status information of the hydrogen production unit, as well as the grid fault and its processing status to the grid operator or maintenance personnel.
2. A power grid fault measurement system based on water electrolysis for hydrogen production according to claim 1, characterized in that: The power input module also includes a power interface, which is designed to be connected to an external power grid and receive an AC power signal provided by the external power grid through a circuit configuration including a switch and a protection device.
3. A power grid fault measurement system based on water electrolysis hydrogen production according to claim 1, characterized in that: The discrete Fourier transform DFT extracts and analyzes harmonic components from the power signal specifically including: For a signal sequence consisting of N sample points , whose DFT is defined as: ,in, is the kth point in the frequency domain, representing the complex form of the frequency component, j is the imaginary unit, N is the total number of samples, k is the frequency index, ; In harmonic analysis, DFT is used to identify and quantify the harmonic components in power grid signals: Signal sampling: The power signal of the power grid By presetting the sampling frequency f s Convert to discrete signal ; Apply DFT: to the sampled signal Perform DFT calculation to obtain the amplitude and phase of each frequency component; Harmonic Identification: By Analyzing As a result, the fundamental wave is identified; Quantizing Harmonics: Calculating the amplitude of each harmonic frequency component , and compared with the threshold value of the harmonic.
4. A power grid fault measurement system based on water electrolysis hydrogen production according to claim 3, characterized in that: The adaptive filtering technology specifically includes: Calculate the amplitude of each harmonic frequency component , using adaptive infinite impulse response filters to compensate and suppress harmonic components by dynamically adjusting filter parameters; A minimum mean square error algorithm is implemented to optimize the adaptive adjustment of the filter parameters and dynamically update the filter coefficients by minimizing the error between the filtered signal and the ideal signal.
5. A power grid fault measurement system based on water electrolysis hydrogen production according to claim 4, characterized in that: The output of the adaptive infinite impulse response filter depends not only on the input signal, but also on the past output, and the expression is: ,in, is the input signal, is the output signal, b i is the forward filter coefficient, a j is the feedback filter coefficient, M and Z are the number of forward and feedback filter coefficients, respectively.
6. A power grid fault measurement system based on water electrolysis for hydrogen production according to claim 1, characterized in that: The asymmetric fault monitoring algorithm in the fault detection module adopts vector combination and phase angle analysis methods to detect and evaluate phase imbalance in the power grid, calculates the vector and phase angle of the three-phase voltage or current signal received from the power input module, and calculates and detects whether there is an imbalance between the phases by comparing the vector length and angle of each phase voltage or current, and determines the fault type based on the deviation of the vector angle.
7. A power grid fault measurement system based on water electrolysis for hydrogen production according to claim 6, characterized in that: The asymmetric fault monitoring algorithm calculation includes: Get three-phase current I from the power input module A ,I B and I C Real-time data; Calculate the phase vector: For each sampling point, calculate the instantaneous value of the three-phase current and the phase vector V of the three-phase current A ,V B and V C : ;in , is the phase factor used to convert the real current value into a phase vector on the complex plane; Phase imbalance detection: Calculate the balance of the three-phase current vectors using the modulus of the vector sum: ; Fault type identification: Use the angle and modulus of the vector sum to identify the specific asymmetric fault type.
8. A power grid fault measurement system based on water electrolysis for hydrogen production according to claim 7, characterized in that: The decision tree specifically includes: The input features of the decision tree model are defined as follows: Phase imbalance: It indicates the imbalance degree of voltage or current between three-phase electricity; Actual phase angle difference: The phase angle difference between the three phases, used to identify the type and severity of asymmetry; Voltage deviation: the deviation between each phase voltage and its ideal value, which is an absolute value or a relative value; Decision tree model training: A decision tree model is trained using historical data, which includes different types of asymmetric faults and their impact on the performance of the hydrogen production unit. During the training process, the model learns how to predict the optimal hydrogen production unit parameter adjustment based on the input asymmetric fault characteristics, including inverter output voltage, inverter output current, hydrogen production rate, electrolysis current density, and electrolysis time; Real-time prediction and adjustment: When the system receives data from the fault detection module in real time, the decision tree model instantly calculates and outputs corresponding adjustment suggestions, using the input phase imbalance, actual phase angle difference and voltage deviation to predict and recommend the optimal output voltage and current settings of the inverter, while providing adjustment suggestions on hydrogen production rate, electrolysis current density and electrolysis time; According to the output of the decision tree model, the control system dynamically adjusts the inverter settings: adjusts the inverter voltage output ΔV and current output ΔI to ensure that the hydrogen production and quality are maximized under the current grid state, adjusts the hydrogen production rate and electrolysis current density, and adjusts the electrolysis time to adapt to the impact of asymmetric load on the electrolysis process; The decision tree construction process is as follows: Select the best split features and split points: Entropy or Gini impurity is the criterion for determining how to select split features and split points. For each node, the decision tree algorithm traverses all features and their split points to calculate the information gain or the reduction of Gini impurity. The entropy calculation formula is: , where p i is the proportion of target values of the i-th category in the set S; Information gain calculation: , where A is the feature considered and S v is a subset of feature A under value v, is the entropy of the subset, and the Gini impurity calculation formula is: ; Recursively build the tree: For each node, use the above formula to select the best split feature and point to divide the data set into two subsets; Recursively apply the same method to each subset until the stopping condition is met; To prevent overfitting, the tree needs to be pruned using cost complexity pruning, in which a parameter is used to balance the depth of the tree and the training error.
9. A method for measuring power grid faults based on water electrolysis for hydrogen production, implemented by a power grid fault measurement system based on water electrolysis for hydrogen production according to any one of claims 1 to 8, characterized in that: The following steps are involved: S1: Power reception and monitoring, connected to the external power grid, receiving AC power signals through the power interface, using voltage and current sensors to monitor and record the voltage, current and frequency data of the power system in real time; S2: Fault data processing and analysis: Use harmonic analysis algorithm to process received power signals, digitize continuous power signals, calculate their spectrum data using discrete Fourier transform, identify and analyze harmonic components in power signals, calculate the amplitude and phase of each harmonic frequency component, and compare them with preset harmonic thresholds to monitor and quantify harmonic levels that exceed the standards in real time; S3: Harmonic filtering and compensation. If the harmonic exceeds the safety threshold, the adaptive infinite impulse response filter in the harmonic filtering unit is used to dynamically adjust the filtering parameters according to the output of the harmonic analysis algorithm to compensate and suppress the harmonic components. S4: Asymmetric fault monitoring and response, applying the asymmetric fault monitoring algorithm, by calculating the vector and phase angle of the three-phase current or voltage, to detect and evaluate the phase imbalance in the power grid, and identify whether there is an asymmetric fault based on the comparison of the vector length and angle; S5: Control and adjustment. According to the output result of S4, the working state of the hydrogen production unit is adjusted to cope with the impact of power grid failure.
Citation Information
Patent Citations
Surrogate-based safety failure prediction method for alkaline electrolytic cell of hydrogen energy system
CN113724804A
Water electrolysis hydrogen production power supply, control method and hydrogen production system
CN115912944A