An impedance modeling equivalent method and system for electrolytic cells

By progressively increasing the order of the equivalent circuit model, the problem of embedding fractional-order models in mainstream simulation platforms was solved, enabling accurate modeling and system-level simulation of the impedance characteristics of PEM electrolytic cells, and reducing development costs.

CN122365950APending Publication Date: 2026-07-10SHENZHEN HOPEWIND ELECTRIC CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
SHENZHEN HOPEWIND ELECTRIC CO LTD
Filing Date
2026-06-05
Publication Date
2026-07-10

AI Technical Summary

Technical Problem

In the existing technology, fractional-order equivalent circuit models are difficult to embed in mainstream simulation software, which makes it difficult to accurately model the dynamic impedance characteristics of PEM electrolyzers and perform system-level simulation analysis, thus affecting the controller design and performance optimization of the electrolyzer system.

Method used

The impedance data of the electrolytic cell is curve-fitted using a first-order or multi-order equivalent circuit model. The model order is gradually increased until the fitting error meets the preset range. The generated model contains only conventional circuit components and can be directly applied in simulation software such as Matlab and PSIM.

Benefits of technology

It achieves accurate characterization and system-level simulation of the impedance characteristics of electrolytic cells, reduces development costs, avoids the difficulties of using constant phase components such as CPE, and meets the engineering requirements for accurate modeling of the dynamic impedance characteristics of electrolytic cells.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122365950A_ABST
    Figure CN122365950A_ABST
Patent Text Reader

Abstract

The application discloses an equivalent method and system for modeling impedance of an electrolytic cell, and the method comprises the following steps: applying operating current or operating voltage to the electrolytic cell, and setting measurement parameters of an electrochemical impedance spectrum scanning device; applying an alternating excitation signal to the electrolytic cell through the electrochemical impedance spectrum scanning device based on the measurement parameters, and collecting voltage signal data and current signal data of the electrolytic cell under the alternating excitation signal; extracting frequency domain data of the impedance of the electrolytic cell based on the voltage signal data and the current signal data, and calculating impedance data; performing curve fitting on the impedance data by using a first-order or multi-order equivalent circuit model, obtaining a fitting error, and until the fitting error under the current order satisfies a preset error range, finally obtaining an equivalent circuit model; and simulating the electrolytic cell based on the equivalent circuit model. The model generated by the application only contains conventional circuit elements, and can be directly realized in simulation software such as Matlab and PSIM.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of electrolytic cell technology, and in particular to an equivalent method and system for impedance modeling of electrolytic cells. Background Technology

[0002] As a core component in hydrogen production, the proton exchange membrane (PEM) electrolyzer is crucial for accurate modeling of its electrochemical characteristics, which is essential for system simulation, control strategy optimization, and performance evaluation. Electrochemical impedance spectroscopy (EIS) is a commonly used method for characterizing the electrochemical properties of PEM electrolyzers. By sweeping frequency excitation, the impedance response of the electrolyzer at different frequencies is obtained and presented in the form of Nyquist curves, etc.

[0003] In existing technologies, classical equivalent circuit models (ECMs) are typically used to fit and characterize impedance data obtained from EIS scans. However, in practical applications, it has been found that the Nyquist curves obtained by EIS electrochemical impedance spectroscopy scans of PEM electrolyzers cannot correspond to the classical equivalent circuit model, and the classical model is insufficient to accurately describe the electrochemical behavior of the electrolyzer. To achieve accurate characterization of the electrolyzer's impedance characteristics, it is necessary to replace the double-layer capacitors in the circuit with constant-phase elements such as CPEs (constant-phase-angle elements), constructing a fractional-order equivalent circuit model (FOECM).

[0004] Although fractional-order equivalent circuit models can perfectly characterize the impedance characteristics of electrolyzers, their implementation is difficult. Currently, mainstream simulation software such as Matlab, PSIM, and SPICE do not embed fractional-order component models, making them unusable for system-level simulations. When simulations require accurate modeling of the dynamic impedance characteristics of PEM electrolyzers, existing technologies cannot meet the requirements, posing significant obstacles to the simulation analysis, controller design, and performance optimization of electrolyzer systems. Summary of the Invention

[0005] The purpose of this invention is to provide an equivalent method and system for impedance modeling of electrolytic cells, aiming to solve the problem that existing fractional-order model-based schemes are difficult to embed into mainstream simulation platforms.

[0006] This invention provides an equivalent method for impedance modeling of electrolytic cells, comprising: Control the hydrogen production power supply to apply operating current or operating voltage to the electrolyzer, and set the measurement parameters of the electrochemical impedance spectroscopy scanning device; Based on the measurement parameters, an AC excitation signal is applied to the electrolytic cell using the electrochemical impedance spectroscopy scanning device, and voltage and current signal data at the positive and negative electrodes of the electrolytic cell under the AC excitation signal are acquired by the data measurement and acquisition module. Based on the voltage signal data and the current signal data, the frequency domain data of the electrolytic cell impedance is extracted by the data processing and calculation module, and the impedance data is calculated; wherein, the impedance data includes: the amplitude, phase, real part and imaginary part of the AC impedance; The impedance data is curve-fitted using a first-order or multi-order equivalent circuit model to obtain the fitting error. This process continues until the fitting error at the current order meets the preset error range, thus obtaining the final equivalent circuit model. Based on the final equivalent circuit model, the electrolytic cell is simulated using a simulator.

[0007] Furthermore, the step of extracting frequency domain data of the electrolytic cell impedance through the data processing and calculation module based on the voltage signal data and the current signal data, and calculating the impedance data, includes: Extract voltage samples of an integer number of cycles from the voltage signal data, and extract current samples of an integer number of cycles from the current signal data within the same time interval as the voltage samples. Perform a discrete Fourier transform on the voltage sample to obtain the complex voltage spectrum; The magnitude of the complex voltage spectrum is extracted as the voltage amplitude, and the phase angle of the complex voltage spectrum is extracted as the voltage phase. Perform a discrete Fourier transform on the current sample to obtain the complex current spectrum; The magnitude of the complex current spectrum is extracted as the current amplitude, and the phase angle of the complex current spectrum is extracted as the current phase. The amplitude of the AC impedance is obtained by dividing the voltage amplitude by the current amplitude. The phase of the AC impedance is obtained by subtracting the current phase from the voltage phase. The real part of the AC impedance is obtained by multiplying the amplitude of the AC impedance by the cosine of the phase of the AC impedance. The imaginary part of the AC impedance is obtained by multiplying the amplitude of the AC impedance by the sine of the phase of the AC impedance.

[0008] Furthermore, the step of using a first-order or multi-order equivalent circuit model to perform curve fitting on the impedance data to obtain the fitting error, until the fitting error at the current order meets the preset error range, to obtain the final equivalent circuit model includes: The impedance data is curve-fitted using a first-order equivalent circuit model to obtain the first-order fitting error. Determine whether the first-order fitting error meets the preset error range; If the first-order fitting error meets the preset error range, then the first-order equivalent circuit model is taken as the final equivalent circuit model. If the first-order fitting error does not meet the preset error range, the order of the equivalent circuit model is increased step by step, and the impedance data is curve-fitted using the equivalent circuit model with the increased order to obtain the current fitting error. Determine whether the current fitting error meets the preset error range; If the current fitting error does not meet the preset error range, the order of the equivalent circuit model will continue to be increased step by step. If the current fitting error meets the preset error range, then the equivalent circuit model of the current order is taken as the final equivalent circuit model.

[0009] Furthermore, the step of using a first-order or multi-order equivalent circuit model to perform curve fitting on the impedance data to obtain the fitting error, until the fitting error at the current order meets the preset error range, to obtain the final equivalent circuit model, also includes: A fitting plot is drawn using the amplitude, phase, real part, and imaginary part of the AC impedance; The x-axis parameter values ​​of each data point in the fitted graph are input into the equivalent circuit model of the current order to obtain the predicted value of each data point; The y-axis parameter values ​​of each data point in the fitted graph are used as the observed values ​​of each data point. An optimization problem is constructed for each data point, with the sum of squared residuals between the observed and predicted values ​​as the objective function; The optimization problem is solved iteratively using the least squares optimization algorithm. In each iteration, the parameter vector of the equivalent circuit model of the current order is updated until the difference of the norm square of the residual between the observed value and the predicted value in two adjacent iterations is less than the preset iteration error coefficient, and the iteration terminates to obtain the optimal parameter vector.

[0010] Furthermore, the fitted graph includes: a complex plane graph or a Bode plot.

[0011] Furthermore, the model function of the equivalent circuit model of the current order is as follows: ; Where f represents the output of the equivalent circuit model; x i This represents the x-axis parameter values ​​for each data point in the fitted graph; represents the parameter vector; n represents the order of the parallel resistor-capacitor circuit; s is the differential operator; R represents the resistance value of the i-th parallel resistor; int This indicates the resistance value of the series resistor; This represents the capacitance value of the i-th parallel capacitor.

[0012] Furthermore, the measurement parameters include: the frequency range, amplitude, and number of points of the AC voltage signal; or the frequency range, amplitude, and number of points of the AC current signal.

[0013] This embodiment also provides an impedance modeling equivalent system for electrolyzers, employing the aforementioned impedance modeling equivalent method for electrolyzers, and includes: an electrolyzer, a hydrogen production power source, an electrochemical impedance spectroscopy scanning device, a data measurement and acquisition module, a data processing and calculation module, and a simulator. The electrolyzer is electrically connected to the hydrogen production power source, the electrochemical impedance spectroscopy scanning device, and the data measurement and acquisition module. The electrochemical impedance spectroscopy scanning device is connected in parallel with the hydrogen production power source. The data processing and calculation module is signal-connected to the data measurement and acquisition module. The simulator is signal-connected to the data processing and calculation module.

[0014] Furthermore, it also includes: a current sensor, the first end of which is electrically connected to the current acquisition unit in the data measurement and acquisition module, the second end of which is electrically connected to the positive input terminal of the electrolytic cell, and the third end of which is simultaneously electrically connected to the electrochemical impedance spectroscopy scanning device and the hydrogen production power supply.

[0015] Furthermore, it also includes a communication module and a host computer, wherein the communication module is connected to the data measurement and acquisition module, the data processing and calculation module, the simulator, and the host computer via signals.

[0016] This invention discloses an equivalent method and system for impedance modeling of an electrolyzer. The method includes controlling a hydrogen production power source to apply operating current or operating voltage to the electrolyzer and setting measurement parameters of an electrochemical impedance spectroscopy (EIS) scanning device; applying an AC excitation signal to the electrolyzer through the EIS scanning device based on the measurement parameters, and acquiring voltage and current signal data at the positive and negative terminals of the electrolyzer under the AC excitation signal through a data measurement and acquisition module; extracting frequency domain data of the electrolyzer impedance through a data processing and calculation module based on the voltage and current signal data, and calculating impedance data; wherein the impedance data includes the amplitude, phase, real part, and imaginary part of the AC impedance; performing curve fitting on the impedance data using a first-order or multi-order equivalent circuit model to obtain the fitting error, until the fitting error at the current order meets a preset error range, thus obtaining the final equivalent circuit model; and simulating the electrolyzer using a simulator based on the final equivalent circuit model. This invention employs a multi-order RC equivalent circuit model to curve-fit the AC impedance of a PEM electrolyzer. By progressively increasing the model order until the fitting error meets a preset range, the final equivalent circuit model is obtained. This method approximates the characteristics of a fractional-order model with an integer-order circuit structure, avoiding the use of constant-phase components such as CPEs. The generated model contains only conventional circuit components and can be directly implemented in simulation software such as Matlab and PSIM, solving the problem of fractional-order models being difficult to embed into mainstream simulation platforms. While ensuring the accuracy of impedance characterization, it meets the engineering requirements for accurate modeling of the dynamic impedance characteristics of electrolyzers and system-level simulation, reducing development costs. Attached Figure Description

[0017] To more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings used in the following description of the embodiments will be briefly introduced. Obviously, the drawings described below are some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0018] Figure 1 A schematic diagram of the equivalent method for impedance modeling of electrolytic cells; Figure 2 A schematic diagram of a sub-process for an equivalent method of impedance modeling for an electrolyzer; Figure 3 This is a schematic diagram of the equivalent circuit model; Figure 4 This is a schematic diagram of another sub-process of the impedance modeling equivalent method for electrolyzers; Figure 5 This is a schematic diagram showing the fitting effect of the second-order equivalent circuit model in a specific embodiment; Figure 6This is a schematic diagram showing the fitting effect of the third-order equivalent circuit model in a specific embodiment; Figure 7 A schematic diagram showing the fitting effect of the sixth-order equivalent circuit model in a specific embodiment; Figure 8 A schematic diagram of the equivalent system for impedance modeling of an electrolytic cell. Detailed Implementation

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

[0020] It should be understood that, when used in this specification and the appended claims, the terms “comprising” and “including” indicate the presence of the described features, integrals, steps, operations, elements and / or components, but do not exclude the presence or addition of one or more other features, integrals, steps, operations, elements, components and / or collections thereof.

[0021] It should also be understood that the terminology used in this specification is for the purpose of describing particular embodiments only and is not intended to limit the invention. As used in this specification and the appended claims, the singular forms “a,” “an,” and “the” are intended to include the plural forms unless the context clearly indicates otherwise.

[0022] It should also be further understood that the term "and / or" as used in this specification and the appended claims refers to any combination of one or more of the associated listed items and all possible combinations, and includes such combinations.

[0023] Please see Figure 1 and Figure 2 This embodiment provides an equivalent method for impedance modeling of electrolytic cells, including: S101: Control the hydrogen production power supply to apply operating current or operating voltage to the electrolyzer, and set the measurement parameters of the electrochemical impedance spectroscopy scanning device; When performing impedance modeling for a PEM electrolyzer, the first step is to establish the steady-state operating point of the device under test and configure the scanning excitation. Specifically, the hydrogen production power supply is controlled to apply operating current or operating voltage to the load of the PEM electrolyzer according to preset DC output parameters, causing the electrolyzer to enter a steady-state operating state. During this process, the operating current value is collected in real time by a current sensor connected to the positive input terminal of the electrolyzer, and the operating voltage value is simultaneously collected by a voltage acquisition channel connected in parallel across the positive and negative terminals of the electrolyzer. The collected current and voltage values ​​are used as the basis for determining whether the electrolyzer has reached steady-state operation, ensuring that the electrolyzer is under stable operating conditions during subsequent impedance scanning.

[0024] After the electrolytic cell enters steady-state operation, set the measurement parameters of the electrochemical impedance spectroscopy scanning device. The measurement parameters include: the frequency range, amplitude, and number of points of the AC voltage signal; or the frequency range, amplitude, and number of points of the AC current signal.

[0025] First, determine the type of excitation signal. Based on the test requirements, choose either an AC voltage signal or an AC current signal as the excitation source. Both methods can be used for subsequent impedance calculations, but consistency in the excitation type must be maintained during the scanning process. Next, set the frequency range of the excitation signal. Set the lower limit frequency of the scan to 0.1Hz and the upper limit frequency to 6000Hz. This frequency band covers the mass transfer process response in the low-frequency range, the charge transfer process response in the mid-frequency range, and the ohmic response in the high-frequency range of the electrolytic cell, ensuring complete acquisition of impedance information characterizing the dynamic characteristics of the electrolytic cell. Then, configure the amplitude of the excitation signal. Set the amplitude of the AC voltage signal or the AC current signal to 3% of the rated output current of the electrolytic cell. This amplitude selection is based on the principle of small-amplitude perturbation, ensuring that the electrolytic cell is in the linear response region under excitation, guaranteeing the signal-to-noise ratio of impedance measurement while avoiding significant interference with the steady-state operation. Finally, set the number of frequency points for scanning. Generally, measure three to five times at each frequency point and take the average value to reduce the impact of random errors on the test results.

[0026] S102: Based on the measurement parameters, an AC excitation signal is applied to the electrolytic cell through the electrochemical impedance spectroscopy scanning device, and the voltage signal data and current signal data of the positive and negative electrodes of the electrolytic cell under the AC excitation signal are collected through the data measurement and acquisition module. Specifically, based on pre-set measurement parameters, the electrochemical impedance spectroscopy (EIS) scanning device initiates the scanning program according to the configured frequency range, AC amplitude, and number of frequency points. This device is connected in parallel with the hydrogen production power supply to the electrolyzer load. While the hydrogen production power supply maintains steady-state DC operation of the electrolyzer, the EIS scanning device superimposes an AC voltage or AC current signal as an excitation source onto the electrolyzer, subjecting it to a small-amplitude AC disturbance at its steady-state operating point. This AC signal is typically a sinusoidal waveform with a frequency range from a set lower limit to a set upper limit. The electrolyzer's response to the AC current is characterized by impedance, which is the ratio between the AC voltage and current, similar to resistance in a DC circuit, but it incorporates both amplitude and phase characteristics and can be expressed in complex form. ; Where Z represents impedance; ω represents frequency; R represents resistance; j is a complex factor; and X represents reactance.

[0027] During the application of the excitation signal, the data measurement and acquisition module simultaneously starts its acquisition operation. This module includes a voltage acquisition unit and a current acquisition unit. The voltage acquisition unit is directly connected to the positive and negative terminals of the electrolytic cell via wires, acquiring the voltage signal data between the positive and negative terminals of the electrolytic cell in real time under AC excitation. The current acquisition unit is connected to a current sensor connected in series at the positive input terminal of the electrolytic cell, simultaneously acquiring the current signal data flowing through the electrolytic cell. For each preset frequency point, the data measurement and acquisition module records the waveform data of the voltage response and current response at the corresponding frequency, ensuring a one-to-one correspondence between the voltage signal and the current signal on the time axis, providing synchronous and complete raw data for subsequent extraction of impedance information at each frequency point.

[0028] S103: Based on the voltage signal data and the current signal data, the frequency domain data of the electrolytic cell impedance is extracted by the data processing and calculation module, and the impedance data is calculated; wherein, the impedance data includes: the amplitude, phase, real part and imaginary part of the AC impedance; In this embodiment, based on voltage signal data and current signal data, the frequency domain data of the electrolytic cell impedance is extracted by the data processing and calculation module, and the impedance data is calculated as follows: Extract voltage samples of an integer number of cycles from the voltage signal data, and extract current samples of an integer number of cycles from the current signal data within the same time interval as the voltage samples. Perform a discrete Fourier transform on the voltage sample to obtain the complex voltage spectrum; The magnitude of the complex voltage spectrum is extracted as the voltage amplitude, and the phase angle of the complex voltage spectrum is extracted as the voltage phase. Perform a discrete Fourier transform on the current sample to obtain the complex current spectrum; The magnitude of the complex current spectrum is extracted as the current amplitude, and the phase angle of the complex current spectrum is extracted as the current phase. The magnitude of the AC impedance is obtained by dividing the voltage magnitude by the current magnitude. The phase of the AC impedance is obtained by subtracting the current phase from the voltage phase. The real part of the AC impedance is obtained by multiplying the amplitude of the AC impedance by the cosine of the phase of the AC impedance. The imaginary part of the AC impedance is obtained by multiplying the amplitude of the AC impedance by the sine of the phase of the AC impedance.

[0029] This embodiment extracts samples of integer period lengths from both voltage and current signal data, ensuring that the voltage and current samples are taken from the same time interval. This fundamentally avoids the spectral leakage problem caused by non-integer period extraction and guarantees strict synchronization of the voltage and current signals on the time axis, laying a data foundation for the accuracy of subsequent impedance calculations. The discrete Fourier transform is used to convert the time-domain samples into frequency-domain complex spectra, enabling precise extraction of amplitude and phase information at each frequency point. Compared to time-domain fitting or correlation detection methods, this approach offers higher frequency resolution and noise immunity. The impedance amplitude is obtained by division after calculating the voltage and current amplitudes separately, and the impedance phase is obtained by subtraction after calculating the voltage and current phases separately. This decouples the amplitude and phase characteristics of the impedance, avoiding numerical instability issues that may occur in complex division, while also providing clear physical meaning for subsequent error analysis. Furthermore, the real and imaginary parts of the impedance are obtained through trigonometric function calculations of the impedance amplitude and phase, thus fully preserving the complex information of the impedance. This provides directly usable complex impedance data for subsequent Nyquist plotting and curve fitting. The entire process forms a systematic processing link from the original time-domain waveform to complete frequency-domain impedance parameters. The data processing process is repeatable and traceable, ensuring the accuracy and consistency of impedance modeling.

[0030] Specifically, after receiving voltage and current signal data, the data processing and calculation module extracts and calculates impedance frequency domain data for each preset excitation frequency point. For voltage signal data, the module first determines the period length at the current frequency point and extracts voltage samples of an integer number of complete periods from the continuously acquired voltage waveform, such as extracting 5 or 10 complete periods. This ensures that the extracted samples cover an integer multiple of the period on the time axis, thus avoiding spectral leakage errors that may be introduced by non-integer period extraction. For current signal data, the module extracts current samples of an integer number of periods within the same time interval as the voltage samples, ensuring that the voltage and current samples are strictly consistent in terms of start time, duration, and number of periods, providing synchronized time domain data pairs for subsequent complex calculations.

[0031] Next, the data processing and calculation module performs discrete Fourier transform operations on the single-frequency voltage samples of integer period lengths at each excitation frequency. Before the operation, the sampling frequency and number of sampling points of the voltage sample are matched with the parameters of the corresponding excitation frequency to ensure the accuracy of the transformation parameters. Through this transformation, the voltage sample data in the time domain dimension is converted into complex form data in the frequency domain dimension, and finally the unique voltage complex spectrum V(f) corresponding to each excitation frequency is obtained. This spectrum fully represents the frequency domain characteristics of the voltage response at the corresponding frequency in the complex form of the real and imaginary parts. The module performs complex feature analysis on the generated complex voltage spectrum. Following the rules for calculating complex modulus, it squares the real and imaginary parts of the voltage spectrum, sums them, and then takes the square root of the sum. The calculated value is determined as the modulus of the complex voltage spectrum and directly used as the voltage amplitude |V| at the corresponding excitation frequency, accurately reflecting the magnitude of the voltage response at that frequency. Simultaneously, based on the rules for calculating complex phase angles, the module uses the arctangent function to calculate the imaginary part img(V) and the real part real(V) of the complex voltage spectrum, obtaining the angle... The value is determined as the phase angle of the voltage complex spectral line, i.e., arctan(imag(V) / real(V)), and this phase angle is directly used as the voltage phase ∠V at the corresponding excitation frequency, accurately characterizing the phase characteristics of the voltage response at that frequency. The module performs discrete Fourier transform, voltage complex spectral line generation, and voltage amplitude and phase extraction for all voltage samples in the full frequency range of the electrochemical impedance spectroscopy scan according to this process, and stores the voltage complex spectral line, voltage amplitude, and voltage phase corresponding to each frequency point one by one, providing accurate voltage frequency domain data for subsequent impedance parameter calculation.

[0032] Then, the data processing and calculation module performs frequency domain transformation processing on the current samples of integer period lengths at each excitation frequency, which are simultaneously extracted with the voltage samples, according to the frequency order of the electrochemical impedance spectroscopy scan. Before the operation, the sampling frequency and number of sampling points of the current samples are matched with the parameters of the corresponding excitation frequency to ensure that the operation parameters of the discrete Fourier transform are compatible with the time domain characteristics of the current samples. Then, the discrete Fourier transform operation is performed on the current samples at a single frequency to transform the current signal data in the time domain dimension into complex form data in the frequency domain dimension. Finally, the unique current complex spectrum line I(f) corresponding to each excitation frequency is obtained. This spectrum line completely represents the frequency domain characteristics of the current response at the corresponding frequency in the complex form of the real and imaginary parts. The module extracts complex characteristic parameters from the generated complex current spectrum at each frequency point. Following the standard calculation rules for complex modulus, it squares the real and imaginary parts of the complex current spectrum, sums them, and then takes the square root of the sum. The calculated value is determined as the modulus of the complex current spectrum and directly used as the current amplitude |I| at the corresponding excitation frequency, accurately reflecting the magnitude of the current response at that frequency. Simultaneously, based on the standard calculation rules for complex phase angles, the module calculates the imaginary and real parts of the complex current spectrum using the arctangent function, determining the resulting angle value as the phase angle of the complex current spectrum. This phase angle is directly used as the current phase ∠I at the corresponding excitation frequency, accurately characterizing the phase characteristics of the current response at that frequency. The module performs discrete Fourier transform, complex current spectrum generation, and current amplitude and phase extraction operations on all current samples across the full frequency range of the electrochemical impedance spectroscopy scan according to this process. It also stores the current complex spectrum, current amplitude, current phase, and voltage frequency domain parameters at the same frequency corresponding to each frequency point, providing accurate and synchronous current frequency domain data for subsequent calculation of AC impedance parameters.

[0033] After obtaining the amplitude and phase of the voltage and current at the same frequency, the components of the AC impedance can be calculated. The amplitude of the AC impedance, |Z|, is obtained by dividing the voltage amplitude by the current amplitude, i.e., |Z| = |V| / |I|. The phase of the AC impedance, ∠Z, is obtained by subtracting the current phase from the voltage phase, i.e., ∠Z = ∠V - ∠I. Furthermore, the real and imaginary parts of the impedance can be obtained by converting from polar coordinates to rectangular coordinates. Specifically, the real part of the impedance, Re(Z), is equal to the impedance amplitude |Z| multiplied by the cosine of the impedance phase angle ∠Z, i.e., Re(Z) = |Z| * cos(∠Z); the imaginary part of the impedance, Im(Z), is equal to the impedance amplitude |Z| multiplied by the sine of the impedance phase angle ∠Z, i.e., Im(Z) = |Z| * sin(∠Z).

[0034] Subsequently, after acquiring the AC impedance amplitude, phase, real part, and imaginary part of all data points within the full scan frequency range, the data processing and calculation module immediately initiates the abnormal data point removal process. First, all impedance data are arranged in ascending order according to the frequency of the electrochemical impedance spectroscopy scan, ensuring a one-to-one correspondence between the four impedance parameters at each frequency point. Simultaneously, the original voltage and current signal data corresponding to each data point are stored in association, providing a basis for tracing the source of anomalies. Firstly, the module uses the 3σ criterion as the core anomaly judgment standard, independently calculating and analyzing the four parameters of AC impedance amplitude, phase, real part, and imaginary part. The mean and standard deviation of all data points for each parameter are calculated first, where the mean is the arithmetic mean of all data points for that parameter, and the standard deviation characterizes the dispersion of the data points. Three times the standard deviation is used as the anomaly judgment threshold, thus determining the normal data range for each parameter to be the mean ± 3 times the standard deviation. Subsequently, the module verifies each of the four impedance parameters at each frequency point, comparing the amplitude, phase, real part, and imaginary part of each data point with the normal data range of the corresponding parameter. If a parameter value exceeds the range, the data point is temporarily marked as a suspected anomaly. Simultaneously, the module combines the frequency domain characteristics of the impedance data to supplement the correlation judgment of adjacent data points. Because the impedance characteristics of the PEM electrolyzer exhibit a smooth transition trend with frequency, if the difference between any impedance parameter of a data point and the corresponding parameter of the two adjacent frequency points exceeds five times the average difference between adjacent data points, even if the data point does not exceed the normal range of the 3σ criterion, it is still marked as a suspected anomaly to avoid missing anomalies due to fluctuations in local frequency bands. After marking, the module performs a secondary review of all suspected anomalies, retrieving the original voltage and current signal data and discrete Fourier transform process data corresponding to the suspected anomalies to check whether the data anomalies are caused by sampling interference, excitation signal fluctuations, or calculation errors, eliminating misjudgments caused by accidental factors. After confirmation, the suspected anomalies that pass the review are officially determined as abnormal data points. Next, the module performs an abnormal data point removal operation, removing all formal abnormal data points from the overall impedance frequency domain dataset. At the same time, it records the information of the removed abnormal data points, including the corresponding frequency, the values ​​of various impedance parameters, and the reason for the abnormality, which is convenient for subsequent test review and data traceability.After the removal is completed, the module reorganizes the remaining normal data points, reorders them in ascending frequency order, and calculates the parameter change gradients of adjacent data points to confirm that the remaining data points show a smooth and continuous trend without obvious abrupt changes. At the same time, it checks whether the number of remaining data points meets the requirements for subsequent curve fitting of the equivalent circuit model. If the number of remaining data points is less than 80% of the total data points, it is determined to be an abnormal data acquisition, and the electrochemical impedance spectroscopy scanning process needs to be restarted to acquire data. If the number of remaining data points meets the requirements, the reorganized normal impedance frequency domain data is stored as input data for subsequent curve fitting using first-order or multi-order equivalent circuit models, ensuring that the fitting process is not affected by abnormal data and guaranteeing the fitting accuracy and reliability of the final equivalent circuit model.

[0035] S104: The impedance data is curve-fitted using a first-order equivalent circuit model or a multi-order equivalent circuit model to obtain the fitting error until the fitting error at the current order meets the preset error range, thus obtaining the final equivalent circuit model. In this embodiment, please refer to Figure 2 and Figure 3 The impedance data is curve-fitted using a first-order or multi-order equivalent circuit model to obtain the fitting error. This process continues until the fitting error at the current order meets a preset error range, resulting in the final equivalent circuit model, which includes: The impedance data were curve-fitted using a first-order equivalent circuit model to obtain the first-order fitting error. Determine whether the first-order fitting error meets the preset error range; If the first-order fitting error meets the preset error range, then the first-order equivalent circuit model will be used as the final equivalent circuit model. If the first-order fitting error does not meet the preset error range, the order of the equivalent circuit model is increased step by step, and the impedance data is curve-fitted using the equivalent circuit model with increased order to obtain the current fitting error. Determine whether the current fitting error meets the preset error range; If the current fitting error does not meet the preset error range, the order of the equivalent circuit model will continue to be increased step by step. If the current fitting error meets the preset error range, then the equivalent circuit model of the current order will be used as the final equivalent circuit model.

[0036] This embodiment employs an adaptive fitting strategy that progressively increases the order of the model, starting from a first-order equivalent circuit model. Prioritizing the lowest-order model while meeting error requirements avoids parameter redundancy and overfitting issues associated with directly using higher-order models, achieving an optimal balance between accuracy and complexity in the final equivalent circuit model. By setting a preset error range as the fitting termination condition, an objective and quantitative basis for model order selection is provided, eliminating the subjectivity and uncertainty of manual order selection. Progressively increasing the order and refitting at each level allows the parameter values ​​obtained from the previous order fitting to serve as the initial values ​​for the next order fitting, improving the convergence speed and numerical stability of parameter identification for higher-order models. The entire process achieves adaptive matching between model order and fitting error, ensuring that the final output equivalent circuit model accurately represents the impedance characteristics of the electrolytic cell while possessing a simple circuit structure, facilitating direct application in mainstream simulation software.

[0037] Specifically, after obtaining the impedance data after removing outliers, the data processing and calculation module initiates the curve fitting process for the equivalent circuit model. The data processing and calculation module first constructs a first-order equivalent circuit model, which consists of a parallel resistor R and a parallel capacitor C (referred to as RC) connected in parallel, and then connected in series with another resistor R. int The circuit is constructed in series, and the model contains a parameter vector to be identified, including series resistance, parallel resistance, and parallel capacitance values. The data processing and calculation module performs curve fitting on the first-order equivalent circuit model and calculates the first-order fitting error (the fitting error represents the difference in the norm squares of the residuals between the observed and predicted values ​​in two consecutive iterations). Then, the first-order fitting error is compared with a preset error range. If the first-order fitting error is within the preset error range, the first-order equivalent circuit model and its parameters are output as the final equivalent circuit model, ending the fitting process.

[0038] If the first-order fitting error exceeds the preset error range, the data processing and calculation module will increase the model order by one level and construct a second-order equivalent circuit model. This model consists of two parallel resistors R and two parallel capacitors C connected in series, and then connected in series with a resistor R. intThe circuit is constructed in series, and the parameters to be identified in the model include the series resistance value, two parallel resistance values, and two parallel capacitance values. The data processing and calculation module uses the optimal parameter vector obtained by fitting the first-order equivalent circuit model as the initial parameter vector for fitting the second-order equivalent circuit model. Specifically, the series resistance value of the first-order model is used as the initial value of the series resistance in the second-order model, and the parallel resistance and capacitance values ​​of the first-order model are used as the initial values ​​of the first RC element in the second-order model. The initial resistance and capacitance values ​​of the second RC element are set separately based on the low-frequency characteristics of the impedance data. The data processing and calculation module uses the same least-squares optimization algorithm (such as the Levenberg-Marquardt algorithm) to perform curve fitting on the second-order equivalent circuit model, obtaining the second-order fitting error. The data processing and calculation module compares the second-order fitting error with a preset error range. If the second-order fitting error meets the preset error range, the second-order equivalent circuit model and its parameters are output as the final equivalent circuit model.

[0039] If the second-order fitting error still exceeds the preset error range, the data processing and calculation module will continue to increase the model order to the third order, constructing a model consisting of three parallel RC circuits connected in series with a series resistor R. int A third-order equivalent circuit model consisting of series connections is constructed. The data processing and calculation module uses the optimal parameter vector obtained by fitting the second-order equivalent circuit model as the initial parameter vector for fitting the third-order equivalent circuit model. All parameters of the second-order model are used as the initial values ​​for the first two RC elements and the series resistance of the third-order model. The initial values ​​for the resistance and capacitance of the newly added third RC element are set based on the low-frequency characteristics of the impedance data. The data processing and calculation module performs curve fitting on the third-order equivalent circuit model, obtaining the third-order fitting error and comparing it with a preset error range. The data processing and calculation module progressively increases the order of the RC parallel elements in the above manner. After each increase in order, the optimal parameter vector obtained from the previous order fitting is used as the initial parameter vector for the current order fitting. Curve fitting and error judgment are performed sequentially on the fourth-order, fifth-order, and higher-order equivalent circuit models until the fitting error at the current order meets the preset error range. At this point, the increase in order stops, and the equivalent circuit model and its parameters at the current order are output as the final equivalent circuit model.

[0040] In this embodiment, the impedance data is curve-fitted using a first-order equivalent circuit model or a multi-order equivalent circuit model to obtain the fitting error. The process continues until the fitting error at the current order meets a preset error range, resulting in the final equivalent circuit model. Plot the fitting graph using the amplitude, phase, real part, and imaginary part of the AC impedance; Input the x-axis parameter values ​​of each data point in the fitted graph into the equivalent circuit model of the current order to obtain the predicted value of each data point; The y-axis parameter values ​​of each data point in the fitted graph are used as the observed values ​​of each data point. For each data point, construct an optimization problem with the sum of squared residuals between observed and predicted values ​​as the objective function; The optimization problem is solved iteratively using the least squares optimization algorithm. In each iteration, the parameter vector of the equivalent circuit model of the current order is updated until the difference of the norm square of the residuals between the observed and predicted values ​​of two adjacent iterations is less than the preset iteration error coefficient, at which point the iteration terminates and the optimal parameter vector is obtained.

[0041] This embodiment obtains predicted values ​​by inputting the x-axis parameter values ​​of each data point in the fitted graph into the equivalent circuit model, and uses the y-axis parameter values ​​of the corresponding data points in the fitted graph as observed values. This achieves a direct graphical correspondence between the model output and the measured data, making the fitting process intuitively reflect the model's ability to reproduce impedance spectrum characteristics. The objective function is constructed using the sum of squared residuals between the observed and predicted values, transforming model parameter identification into a clear optimization problem, providing mathematical rigor and quantifiability for the solution process. An iterative solution using a least squares optimization algorithm updates the parameter vector in each iteration and gradually approaches the optimal solution, avoiding the subjectivity and inefficiency of manual parameter trial and error. The iteration termination condition is set at the difference of the squared norms of the residuals between two adjacent iterations being less than a preset iteration error coefficient, providing an objective quantitative basis for convergence judgment and avoiding invalid iterations while ensuring fitting accuracy. The final optimal parameter vector ensures that the equivalent circuit model achieves the best match with the measured impedance data across the entire frequency band, guaranteeing the uniqueness and reliability of the model parameters.

[0042] Specifically, after completing impedance data calculation and outlier removal, the data processing and calculation module initiates the fitting plot drawing process. The module first extracts four key parameters of the AC impedance from the valid dataset: amplitude, phase, real part, and imaginary part. These parameters are stored in different data arrays, each array mapping to a corresponding frequency point. Based on the requirements of subsequent equivalent circuit model fitting, the module determines the coordinate axis configuration scheme of the fitting plot, typically using either a Nyquist plot or a Bode plot; that is, the fitting plot includes either a complex plane plot or a Bode plot.

[0043] For the complex plane diagram, the data processing and calculation module constructs a rectangular coordinate system with the real part of the impedance as the abscissa and the negative value of the imaginary part of the impedance as the ordinate. The real part and the negative value of the imaginary part of the impedance corresponding to each excitation frequency point are marked in this coordinate system one by one to form discrete data points. The data points of adjacent frequency points are connected by line segments in order from high to low frequency, and finally a continuous trajectory curve is formed. This trajectory curve is the Nyquist plot. The high frequency region in the figure corresponds to the points where the real part of the impedance is small and the imaginary part is close to zero, reflecting the ohmic response characteristics of the electrolyzer. The mid frequency region presents an arc shape, reflecting the coupling effect of charge transfer process and electric double layer effect. The low frequency region presents an approximately straight diffusion tail, reflecting the impedance characteristics of mass transfer process. For the Bode plot, the data processing and calculation module plots the amplitude-frequency response curve with the logarithm of frequency as the x-axis and the impedance amplitude as the y-axis, and plots the phase-frequency response curve with the logarithm of frequency as the x-axis and the impedance phase as the y-axis. The two curves are arranged side by side on the same frequency axis to form a complete Bode plot. The amplitude-frequency response curve shows the overall trend of the impedance amplitude decreasing with increasing frequency and the transition characteristics of different frequency bands. The phase-frequency response curve shows the change law of the impedance phase gradually approaching zero as the frequency changes.

[0044] The x-axis parameter values ​​of each data point in the fitted plot (such as a Nyquist plot or Bode plot) are used as inputs to the model. For a Nyquist plot, the x-axis parameter value is the real part of the impedance calculated at the corresponding frequency; for an amplitude-frequency response plot, the x-axis parameter value is usually the frequency value itself. These specific values ​​are extracted one by one.

[0045] Subsequently, these extracted x-axis parameter values ​​are systematically input into the equivalent circuit model of the current order for calculation to obtain the predicted values ​​of each data point; Furthermore, the model function for the equivalent circuit model of the current order is as follows: ; Where f represents the output of the equivalent circuit model; x i This represents the x-axis parameter values ​​for each data point in the fitted plot; represents the parameter vector; n represents the order of the parallel resistor-capacitor circuit; s is the differential operator; R represents the resistance value of the i-th parallel resistor; int This indicates the resistance value of the series resistor; This represents the capacitance value of the i-th parallel capacitor.

[0046] ; in, for Figure 4 The resistance values ​​of each resistor and the capacitance values ​​of each capacitor in a mid-to-high-order RC circuit; T is the vector transpose.

[0047] Then, the y-axis parameter values ​​for each data point in the fitted graph are explicitly specified as the observed values ​​y for the corresponding data points. i These observations are real physical quantities derived directly from experimental measurement data. Specifically, in the Nyquist plot, the y-axis parameter value is the imaginary part of the impedance calculated at the corresponding frequency; in the amplitude-frequency response plot, the y-axis parameter value is the impedance amplitude at the corresponding frequency.

[0048] For each data point, the model prediction obtained in the previous step is compared with the corresponding observed value. The difference is the residual for that point. The calculation formula is as follows: ; Where, r i y represents the residual between the observed value and the predicted value; i This represents the y-axis parameter values ​​for each data point in the fitted graph.

[0049] like Figure 4 As shown, a mathematical optimization problem is then constructed. The core of this problem is to define an objective function, namely the cost function J(θ). This function is constructed as the sum of squares of the residuals between the observed values ​​and their corresponding predicted values ​​for all data points. Its calculation formula is as follows: ; Where N is the number of data sets input to the least squares algorithm.

[0050] Subsequently, the algorithm updates the current parameter vector according to the iterative formula of least squares optimization. The iterative update formula adopts the Levenberg-Marquardt iterative algorithm, specifically as follows: ; Where k is the current iteration number, θ k Let θ be the parameter vector for the k-th iteration. k+1 Let T be the parameter vector for the (k+1)th iteration, λ be the vector transpose, λ be the damping coefficient used to adjust the convergence speed of the iteration, and I be the identity matrix. r represents the current residual vector, i.e., the residual between the current observation and the predicted value. During the update process, the constraints on the circuit component parameters are strictly followed to ensure that each updated resistor and capacitor parameter remains positive. If a negative parameter appears after the update, it is automatically adjusted to the minimum positive value (e.g., 1e-8) to avoid parameters violating physical characteristics.

[0051] The data processing and calculation module uses this update formula to calculate the parameter vector θ for the next iteration step. k+1The updated parameter vector is then used to recalculate the predicted values, residual vectors, and sum of squared residuals for each data point. After each iteration, the data processing module calculates the difference in the norm squares of the residuals between the observed and predicted values ​​from two adjacent iterations. The iteration terminates when: ; Where, r k+1 The value represents the residual between the observed and predicted values ​​in the (k+1)th iteration; ||.|| represents the norm, such as the L1 norm and L2 norm; r k This represents the residual between the observed and predicted values ​​in the k-th iteration; This represents the preset iteration error coefficient.

[0052] When the difference in the norm square of the residuals between the observed and predicted values ​​in two consecutive iterations is less than the preset iteration error coefficient, the data processing module determines that the iteration has converged, terminates the iteration process, and sets the current parameter vector... The optimal parameter vector output is the equivalent circuit model parameter that best matches the measured impedance data.

[0053] In some embodiments, the intersection of the high-frequency region and the real axis is identified from the real part and the imaginary part of the impedance as the high-frequency intersection point, the point with the largest absolute value of the imaginary part of the impedance in the mid-frequency region is identified as the mid-frequency arc vertex, and the turning point where the imaginary part of the impedance in the low-frequency region deviates from the arc trajectory is identified as the low-frequency diffusion tail starting point. The initial resistance value of the newly added RC parallel link is determined based on the real part of the impedance at the high-frequency intersection point, and the initial capacitance value of the newly added RC parallel link is determined based on the frequency value of the mid-frequency arc vertex and the imaginary part of the impedance. The initial resistance value and the initial capacitance value are used as the initial parameter values ​​of the newly added RC parallel link and merged with the parameter vector obtained from the previous order fitting to form the initial parameter vector of the current order fitting.

[0054] This embodiment identifies high-frequency intersections, mid-frequency arc apexes, and low-frequency diffusion tail start points from the real and imaginary parts of impedance, introducing physically significant feature points from the Nyquist plot into the initial parameter estimation process. This ensures that the initial resistance and capacitance values ​​of the newly added RC parallel circuit directly correspond to the actual impedance response characteristics of the electrolytic cell in the corresponding frequency band, avoiding the blindness caused by random settings or rough estimations. The initial resistance value is determined based on the real part of the impedance at the high-frequency intersection, ensuring that the initial resistance value of the newly added RC circuit accurately reflects the impedance boundary characteristics between the high-frequency ohmic region and the charge transfer region. The initial capacitance value is determined based on the frequency value of the mid-frequency arc apex and the imaginary part of the impedance, matching the initial capacitance value with the time constant of the charge transfer process. By merging these initial values ​​with the optimal parameter vector obtained from the previous order fitting, the initial parameter vector of the current order fitting is closer to the global optimum, significantly shortening the iteration path of the Levenberg-Marquardt algorithm, improving the convergence speed of high-order model parameter identification, and reducing the risk of getting trapped in local optima due to excessive deviations in initial values.

[0055] Specifically, after calculating the real and imaginary parts of impedance at each frequency point and plotting the Nyquist plot, the data processing and calculation module enters the feature point identification stage. The Nyquist plot uses the real part of impedance as the horizontal axis and the negative value of the imaginary part as the vertical axis. The data processing and calculation module starts scanning from the high-frequency region, which corresponds to the highest frequency segment in the scanning frequency range. In this region, the imaginary part of impedance approaches zero, and the data points are densely distributed near the real axis. The data processing and calculation module calculates the distance between adjacent data points and the real axis sequentially along the direction of transition from high to mid-frequency. When the distance between a data point and the real axis is less than a set threshold and its adjacent data points begin to deviate from the real axis, the intersection point of that data point and the real axis is determined as the high-frequency intersection point, and the real part of the impedance corresponding to this intersection point is recorded as the high-frequency intersection point impedance value. The data processing module then scans the mid-frequency region, which corresponds to the area forming the arc trajectory in the Nyquist plot. The module iterates through all data points within the mid-frequency region, calculating the absolute value of the imaginary part of the impedance for each data point. The data point with the largest absolute value of the imaginary part is identified as the vertex of the mid-frequency arc, and the frequency value of this vertex, along with the real and imaginary impedance values ​​at that vertex, are recorded. Finally, the module scans the low-frequency region, which corresponds to the lowest frequency segment in the scanning frequency range. Within this region, impedance data points extend outwards from the end of the arc trajectory, forming an approximately straight diffusion tail. The module calculates the rate of change of the slope of the line connecting adjacent data points sequentially from the end of the arc trajectory towards the low-frequency direction. When the rate of change of the slope exceeds a set threshold, this turning point is identified as the starting point of the low-frequency diffusion tail. This point marks the end of the arc trajectory and the beginning of the diffusion tail, and the frequency value at this starting point, along with the corresponding real and imaginary impedance values, are recorded. After identifying the above three feature points, the data processing and calculation module uses the high-frequency intersection point, the mid-frequency arc vertex, and the low-frequency diffusion tail start point as the basis for setting the initial values ​​of the parameters of the newly added RC parallel circuit.

[0056] Next, after identifying the high-frequency intersection point and the mid-frequency arc apex, the data processing and calculation module enters the stage of setting the initial values ​​of the parameters for the newly added RC parallel link. For the initial resistance value of the newly added RC parallel link, the data processing and calculation module extracts the real part of the impedance at the high-frequency intersection point. This intersection point is located at the intersection of the high-frequency band and the real axis of the Nyquist plot, corresponding to the total resistance response of the electrolytic cell under high-frequency excitation, including the ohmic resistance and the combined contribution of each RC link at high frequencies. The data processing and calculation module uses the real part of the impedance at this high-frequency intersection point as the initial resistance value of the newly added RC parallel link, so that the initial resistance value of the newly added link directly reflects the impedance characteristics in the high-frequency region. For the initial capacitance value of the newly added RC parallel link, the data processing and calculation module extracts the frequency value and the imaginary part of the impedance at the mid-frequency arc apex. The mid-frequency arc apex corresponds to the highest point of the arc trajectory in the Nyquist plot, and the frequency value at this point is denoted as f. peak The absolute value of the imaginary part of the impedance is denoted as |Im(Z). peakThe data processing and calculation module calculates the initial value of the capacitor using the following formula, based on the time constant characteristics of the RC parallel circuit: ; Where C is the capacitance value to be determined; R is the initial resistance value of the newly added RC parallel circuit; and f peak Given the frequency value at the apex of the mid-frequency arc, to ensure the initial capacitor value more accurately matches the curvature characteristics of the mid-frequency arc, the data processing and calculation module further calibrates the initial capacitor value by incorporating the imaginary part of the impedance at the apex of the mid-frequency arc, using the following formula for adjustment: ; Where k is a correction coefficient related to the number of RC components, ensuring that the initial value of the capacitor matches the radius and vertex position of the arc of the mid-frequency impedance response. The data processing and calculation module uses the determined initial values ​​of the resistor and capacitor as the initial parameters of the newly added RC parallel component, merges them with the optimal parameter vector obtained from the previous order fitting, and appends the initial values ​​of the resistor and capacitor of the newly added component to the end of the previous order parameter vector to form the complete initial parameter vector for the current order fitting, which is used to start the Levenberg-Marquardt iterative solution for the current order.

[0057] Please see Figures 5-7 The red dots (Z, Msd.) represent the original frequency sweep data of the electrolytic cell, and the green dots (Z, Calc.) represent the frequency sweep data of the higher-order RC equivalent circuit. The horizontal axis represents the resistance parameter of the electrolytic cell, and the vertical axis represents the reactance parameter of the electrolytic cell. In a specific embodiment, a first-order RC equivalent circuit model is used to perform curve fitting on the original frequency domain impedance data obtained by electrochemical impedance spectroscopy scanning.

[0058] When the first-order RC equivalent circuit model does not meet the requirements, a second-order RC equivalent circuit model is used to perform curve fitting on the original frequency domain impedance data obtained through electrochemical impedance spectroscopy scanning. Specifically, the data processing and calculation module, based on the acquired impedance real and imaginary part data, uses the transfer function of a second-order RC network as the model structure and employs a least-squares optimization algorithm for parameter identification. After fitting, the module generates a corresponding fitting comparison graph. Figure 5 In this figure, the scatter points representing the measured data and the fitting curve representing the theoretical response of the second-order model are plotted in the same complex plane coordinate system, clearly showing the degree of agreement and the deviation area between the two, thus completing the first fitting verification.

[0059] Based on the fitting results of the second-order model, the system automatically calculates its fitting error and compares it with a preset accuracy threshold. When it is determined that the fitting residual of the second-order model fails to meet the preset error range, the implementation process proceeds to the next step. The system increases the model order to third order, that is, adds a set of parallel RC components to the original second-order RC structure to enhance the model's descriptive ability, and sets initial values ​​for the new parameters based on the previous fitting results and impedance spectrum characteristics. Subsequently, using the same measured data as input, the complete curve fitting and parameter optimization are re-executed on the third-order model. After the fitting is completed, a corresponding fitting comparison graph is generated, i.e. Figure 6 The figure shows that the fitting curve of the third-order model is closer to the measured data points in more frequency bands than the second-order curve, indicating that the fitting accuracy is improved due to the increase in order.

[0060] However, the fitting error of the third-order model may still be higher than the preset requirements, so the process continues with fitting and verification. When the model order is increased to sixth order, a more complex sixth-order RC equivalent circuit network is constructed, and parameter fitting optimization is performed again. After the sixth-order model fitting is completed, a corresponding comparison graph is generated. Figure 7 As can be observed in the final figure, the theoretical fitting curve of the sixth-order model almost spans all the measured data points, exhibiting extremely high overlap across the entire frequency band. This directly demonstrates that by increasing the model order, the resulting high-order model can reproduce the actual impedance characteristics of the electrolyzer with extremely high accuracy. This sequence of images constitutes a complete fitting implementation process from initial attempts, gradual optimization, to finally meeting the high-precision requirements.

[0061] S105: Based on the final equivalent circuit model, the electrolytic cell is simulated using a simulator.

[0062] Specifically, after obtaining the final equivalent circuit model and its optimal parameter vector, the data processing and calculation module transmits the model parameters to the simulator for electrolyzer simulation. The simulator is pre-configured with a hydrogen production power supply model, a programmable high-order RC equivalent circuit model, an impedance spectrum scanning model, and a data acquisition and analysis calculation model. The programmable high-order RC equivalent circuit model receives the parameter vector of the final equivalent circuit model output by the data processing and calculation module. This parameter vector includes the series resistance value and the resistance and capacitance values ​​of each RC parallel link. Based on these parameter values, the simulator constructs a circuit structure in the simulation environment that is completely consistent with the final equivalent circuit model. The hydrogen production power supply model is connected to the programmable high-order RC equivalent circuit model, making the high-order RC equivalent circuit model the equivalent load of the electrolyzer connected to the simulation loop. During simulation, the hydrogen production power supply model applies operating current to the high-order RC equivalent circuit model according to the set DC output parameters, simulating the steady-state operation of the electrolyzer. Simultaneously, the impedance spectrum scanning model superimposes AC excitation signals onto the higher-order RC equivalent circuit model according to the set frequency range, amplitude, and number of points. The data acquisition, analysis, and calculation model simultaneously acquires voltage and current signal data across the higher-order RC equivalent circuit model, calculates the impedance amplitude, impedance phase, real part, and imaginary part at each frequency point, and outputs impedance spectrum data for the entire scanning frequency range. Through the above simulation, the simulator can reproduce the impedance response characteristics of the electrolyzer under hydrogen production power supply based on the final higher-order RC equivalent circuit model without the need for an actual physical prototype of the electrolyzer. This provides a simulation platform for verifying hydrogen production power supply control strategies, analyzing system dynamic characteristics, and optimizing operation.

[0063] This embodiment employs a multi-order RC equivalent circuit model to curve-fit the AC impedance of a PEM electrolyzer. By progressively increasing the model order until the fitting error meets a preset range, the final equivalent circuit model is obtained. This method approximates the characteristics of a fractional-order model with an integer-order circuit structure, avoiding the use of constant-phase components such as CPEs. The generated model contains only conventional circuit components and can be directly implemented in simulation software such as Matlab and PSIM, solving the problem of fractional-order models being difficult to embed into mainstream simulation platforms. While ensuring the accuracy of impedance characterization, it meets the engineering requirements for accurate modeling of the dynamic impedance characteristics of electrolyzers and system-level simulation, reducing development costs.

[0064] Please see Figure 8 This embodiment also provides an equivalent system for impedance modeling of an electrolyzer, employing the impedance modeling equivalent method for an electrolyzer described above. The system includes: an electrolyzer, a hydrogen production power source, an electrochemical impedance spectroscopy scanning device, a data measurement and acquisition module, a data processing and calculation module, and a simulator. The electrolyzer is electrically connected to the hydrogen production power supply, the electrochemical impedance spectroscopy scanning device, and the data measurement and acquisition module. The electrochemical impedance spectroscopy scanning device is connected in parallel with the hydrogen production power supply. The data processing and calculation module is connected to the data measurement and acquisition module via signal connection. The simulator is also connected to the data processing and calculation module via signal connection.

[0065] Specifically, the electrolyzer is electrically connected to the hydrogen production power supply, the electrochemical impedance spectroscopy (EIS) scanning device, and the data measurement and acquisition module, forming a complete hardware testing link. The hydrogen production power supply applies a steady-state operating current to the electrolyzer, bringing it into a stable working state. The EIS scanning device is connected in parallel with the hydrogen production power supply to the electrolyzer, superimposing an AC excitation signal onto it while the electrolyzer is operating in a steady state. The data measurement and acquisition module is connected to the positive and negative terminals of the electrolyzer via wires, simultaneously acquiring voltage and current signal data under AC excitation. The EIS scanning device outputs AC voltage or current signals according to the set frequency range, AC amplitude, and number of frequency points. This signal, superimposed with the DC current provided by the hydrogen production power supply, acts together on the electrolyzer. The data measurement and acquisition module acquires the voltage waveform at the positive and negative terminals of the electrolyzer and the current waveform flowing through the electrolyzer at each frequency point, forming complete raw time-domain data.

[0066] The data processing and calculation module is signal-connected to the data measurement and acquisition module, receiving voltage and current signal data transmitted from the data measurement and acquisition module. For each excitation frequency point, the data processing and calculation module extracts voltage samples of an integer number of cycles from the voltage signal data and current samples of an integer number of cycles from the current signal data within the same time interval as the voltage samples. It then performs Discrete Fourier Transform on the voltage and current samples respectively to obtain the complex voltage and current spectra. It extracts the voltage amplitude and phase, and the current amplitude and phase. The amplitude of the AC impedance is obtained by dividing the voltage amplitude by the current amplitude, and the phase of the AC impedance is obtained by subtracting the current phase from the voltage phase. Finally, it calculates the real and imaginary parts of the AC impedance at each frequency point, completing the extraction of frequency domain impedance data. The data processing and calculation module plots Nyquist and Bode plots based on the impedance data at each frequency point, identifies and removes outlier data points that deviate from the main trajectory (the order of plotting Nyquist and Bode plots and removing outlier data points can be chosen arbitrarily). Then, it uses a first-order equivalent circuit model to perform curve fitting on the impedance data after removing outliers, obtains the first-order fitting error, and determines whether the first-order fitting error meets the preset error range. If not, it increases the order of the RC parallel circuit step by step, uses the optimal parameter vector obtained from the previous order fitting as the initial parameter vector for the current order fitting, and uses the Levenberg-Marquardt algorithm to iteratively solve the parameter vector until the fitting error at the current order meets the preset error range, thus obtaining the final equivalent circuit model and its optimal parameter vector.

[0067] The simulator is signal-connected to the data processing and calculation module, receiving the final equivalent circuit model and its optimal parameter vector output by the module. Internally, the simulator includes a hydrogen production power supply model, a programmable high-order RC equivalent circuit model, an impedance spectrum scanning model, and a data acquisition and analysis calculation model. Based on the received parameter vector, the simulator sets the series resistance value and the resistance and capacitance values ​​of each RC parallel link in the programmable high-order RC equivalent circuit model, constructing a circuit structure completely identical to the final equivalent circuit model. During simulation, the hydrogen production power supply model applies operating current to the programmable high-order RC equivalent circuit model according to the set DC output parameters, simulating the steady-state operation of the electrolyzer. The impedance spectrum scanning model superimposes AC excitation signals onto the programmable high-order RC equivalent circuit model according to the set frequency range, amplitude, and number of points. The data acquisition and analysis calculation model simultaneously acquires voltage and current signal data from both ends of the high-order RC equivalent circuit model, calculates the impedance amplitude, impedance phase, real part, and imaginary part at each frequency point, and outputs impedance spectrum data across the entire scanning frequency range, completing the simulation of the dynamic impedance characteristics of the electrolyzer.

[0068] In this embodiment, the device further includes a current sensor, the first end of which is electrically connected to the current acquisition unit in the data measurement and acquisition module, the second end of which is electrically connected to the positive input terminal of the electrolyzer, and the third end of which is simultaneously electrically connected to the electrochemical impedance spectroscopy scanning device and the hydrogen production power supply.

[0069] Specifically, the third terminal of the current sensor is electrically connected to both the electrochemical impedance spectroscopy (EIS) scanning device and the hydrogen production power supply, receiving the superimposed current of the DC current from the hydrogen production power supply and the AC excitation signal from the EIS scanning device. The second terminal of the current sensor is electrically connected to the positive input terminal of the electrolyzer, transmitting the superimposed total current to the electrolyzer load. The first terminal of the current sensor is electrically connected to the current acquisition unit in the data measurement and acquisition module, used to synchronously transmit the real-time current signal flowing through the electrolyzer to the current acquisition unit. When the hydrogen production power supply applies a steady-state operating current to the electrolyzer, the current sensor is connected in series in the loop at the positive input terminal of the electrolyzer, sensing the current signal flowing through the electrolyzer in real time and converting this current signal into a standard analog or digital signal for transmission to the current acquisition unit in the data measurement and acquisition module. During the process of superimposing an AC excitation signal onto the electrolytic cell using an electrochemical impedance spectroscopy (EIS) scanning device, a current sensor simultaneously acquires the total current signal superimposed with the AC component. The current acquisition unit and voltage acquisition unit of the data measurement and acquisition module work together to synchronously record the voltage signal data at the positive and negative terminals of the electrolytic cell and the current signal data flowing through the electrolytic cell at each excitation frequency point, ensuring a strict temporal correspondence between the voltage and current data. When the data processing and calculation module receives the voltage and current signal data from the data measurement and acquisition module, the voltage signal data comes from the signal directly acquired by the voltage acquisition unit from the positive and negative terminals of the electrolytic cell via wires, and the current signal data comes from the signal transmitted by the current sensor through the current acquisition unit. These two types of data together constitute a complete input data pair, used for subsequent discrete Fourier transform and impedance parameter calculation. Through the access of the current sensor, the data measurement and acquisition module can accurately obtain the real-time current information of the electrolytic cell under steady-state operation and AC excitation superposition conditions, providing accurate current amplitude and current phase data for impedance calculation.

[0070] In this embodiment, it also includes a communication module and a host computer. The communication module is connected to the data measurement and acquisition module, the data processing and calculation module, the simulator, and the host computer via signals.

[0071] Specifically, the communication module is connected to the data measurement and acquisition module, the data processing and calculation module, the simulator, and the host computer, forming a complete information interaction network. The communication module establishes a connection with the data measurement and acquisition module via Ethernet. After acquiring voltage and current signal data, the data measurement and acquisition module transmits the raw time-domain data to the data processing and calculation module through the communication module. The communication module is also connected to the data processing and calculation module. Upon receiving the voltage and current signal data from the data measurement and acquisition module, the data processing and calculation module performs operations such as impedance frequency domain data extraction, outlier removal, and high-order RC equivalent circuit model curve fitting. The intermediate data generated during the operations and the final equivalent circuit model parameters are transmitted to the host computer through the communication module. The communication module connects to the host computer via signal transmission. The host computer receives impedance frequency domain data, fitting error, and equivalent circuit model parameters from the data processing and calculation module through the communication module. It then visualizes the impedance amplitude, impedance phase, real part, imaginary part, Nyquist plot, Bode plot, and fitting error curve at each frequency point on the host computer's display interface. Simultaneously, the host computer sends test parameter configuration commands to the data processing and calculation module via the communication module, including the frequency range of the electrochemical impedance spectroscopy scan, AC amplitude, number of frequency points, and the preset error range for curve fitting. The communication module also connects to the simulator via signal transmission. After obtaining the final equivalent circuit model and its optimal parameter vector, the data processing and calculation module transmits the model parameters to the simulator via the communication module. The simulator receives the parameters and builds the corresponding high-order RC equivalent circuit model for simulation. The simulated impedance data generated by the simulator is transmitted back to the host computer via the communication module for display and storage. Through this communication module connection, bidirectional data interaction is achieved between the data measurement and acquisition module, the data processing and calculation module, the simulator, and the host computer. Each module independently completes its own function while maintaining data synchronization and collaborative work through the communication module.

[0072] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on its differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. For the apparatus disclosed in the embodiments, since it corresponds to the method disclosed in the embodiments, the description is relatively simple; relevant parts can be referred to in the method section. It should be noted that those skilled in the art can make various improvements and modifications to this invention without departing from its principles, and these improvements and modifications also fall within the protection scope of the claims of this invention.

[0073] It should also be noted that, in this specification, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusivity.

[0074] The term "comprises" implies that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Unless otherwise specified, an element defined by the phrase "comprises a..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

Claims

1. An equivalent method for impedance modeling of electrolytic cells, characterized in that, include: Control the hydrogen production power supply to apply operating current or operating voltage to the electrolyzer, and set the measurement parameters of the electrochemical impedance spectroscopy scanning device; Based on the measurement parameters, an AC excitation signal is applied to the electrolytic cell using the electrochemical impedance spectroscopy scanning device, and voltage and current signal data at the positive and negative electrodes of the electrolytic cell under the AC excitation signal are acquired by the data measurement and acquisition module. Based on the voltage signal data and the current signal data, the frequency domain data of the electrolytic cell impedance is extracted by the data processing and calculation module, and the impedance data is calculated; wherein, the impedance data includes: the amplitude, phase, real part and imaginary part of the AC impedance; The impedance data is curve-fitted using a first-order or multi-order equivalent circuit model to obtain the fitting error. This process continues until the fitting error at the current order meets the preset error range, thus obtaining the final equivalent circuit model. Based on the final equivalent circuit model, the electrolytic cell is simulated using a simulator. The step of using a first-order or multi-order equivalent circuit model to perform curve fitting on the impedance data to obtain the fitting error, until the fitting error at the current order meets the preset error range, to obtain the final equivalent circuit model, further includes: A fitting plot is drawn using the amplitude, phase, real part, and imaginary part of the AC impedance; The x-axis parameter values ​​of each data point in the fitted graph are input into the equivalent circuit model of the current order to obtain the predicted value of each data point; The y-axis parameter values ​​of each data point in the fitted graph are used as the observed values ​​of each data point. An optimization problem is constructed for each data point, with the sum of squared residuals between the observed and predicted values ​​as the objective function; The optimization problem is solved iteratively using the least squares optimization algorithm. In each iteration, the parameter vector of the equivalent circuit model of the current order is updated until the difference of the norm square of the residual between the observed value and the predicted value in two adjacent iterations is less than the preset iteration error coefficient, and the iteration terminates to obtain the optimal parameter vector.

2. The impedance modeling equivalent method for electrolytic cells according to claim 1, characterized in that, The step of extracting frequency domain data of the electrolytic cell impedance through a data processing and calculation module based on the voltage signal data and the current signal data, and calculating the impedance data includes: Extract voltage samples of an integer number of cycles from the voltage signal data, and extract current samples of an integer number of cycles from the current signal data within the same time interval as the voltage samples. Perform a discrete Fourier transform on the voltage sample to obtain the complex voltage spectrum; The magnitude of the complex voltage spectrum is extracted as the voltage amplitude, and the phase angle of the complex voltage spectrum is extracted as the voltage phase. Perform a discrete Fourier transform on the current sample to obtain the complex current spectrum; The magnitude of the complex current spectrum is extracted as the current amplitude, and the phase angle of the complex current spectrum is extracted as the current phase. The amplitude of the AC impedance is obtained by dividing the voltage amplitude by the current amplitude. The phase of the AC impedance is obtained by subtracting the current phase from the voltage phase. The real part of the AC impedance is obtained by multiplying the amplitude of the AC impedance by the cosine of the phase of the AC impedance. The imaginary part of the AC impedance is obtained by multiplying the amplitude of the AC impedance by the sine of the phase of the AC impedance.

3. The impedance modeling equivalent method for electrolytic cells according to claim 1, characterized in that, The process of using a first-order or multi-order equivalent circuit model to perform curve fitting on the impedance data to obtain the fitting error continues until the fitting error at the current order meets a preset error range, resulting in the final equivalent circuit model. The impedance data is curve-fitted using a first-order equivalent circuit model to obtain the first-order fitting error. Determine whether the first-order fitting error meets the preset error range; If the first-order fitting error meets the preset error range, then the first-order equivalent circuit model is taken as the final equivalent circuit model. If the first-order fitting error does not meet the preset error range, the order of the equivalent circuit model is increased step by step, and the impedance data is curve-fitted using the equivalent circuit model with the increased order to obtain the current fitting error. Determine whether the current fitting error meets the preset error range; If the current fitting error does not meet the preset error range, the order of the equivalent circuit model will continue to be increased step by step. If the current fitting error meets the preset error range, then the equivalent circuit model of the current order is taken as the final equivalent circuit model.

4. The impedance modeling equivalent method for electrolytic cells according to claim 1, characterized in that, The fitted graph includes: a complex plane graph or a Bode plot.

5. The impedance modeling equivalent method for electrolytic cells according to claim 1, characterized in that, The model function of the equivalent circuit model of the current order is as follows: ; Where f represents the output of the equivalent circuit model; x i This represents the x-axis parameter values ​​for each data point in the fitted graph; represents the parameter vector; n represents the order of the parallel resistor-capacitor circuit; s is the differential operator; R represents the resistance value of the i-th parallel resistor; int This indicates the resistance value of the series resistor; This represents the capacitance value of the i-th parallel capacitor.

6. The impedance modeling equivalent method for electrolytic cells according to claim 1, characterized in that, The measurement parameters include: the frequency range, amplitude, and number of points of the AC voltage signal; or the frequency range, amplitude, and number of points of the AC current signal.

7. An impedance modeling equivalent system for electrolytic cells, employing the impedance modeling equivalent method for electrolytic cells as described in any one of claims 1-6, characterized in that, include: The system includes an electrolyzer, a hydrogen production power supply, an electrochemical impedance spectroscopy (EIS) scanning device, a data measurement and acquisition module, a data processing and calculation module, and a simulator. The electrolyzer is electrically connected to the hydrogen production power supply, the EIS scanning device, and the data measurement and acquisition module. The EIS scanning device is connected in parallel with the hydrogen production power supply. The data processing and calculation module is signal-connected to the data measurement and acquisition module, and the simulator is signal-connected to the data processing and calculation module.

8. The impedance modeling equivalent system for electrolytic cells according to claim 7, characterized in that, Also includes: The current sensor has its first end electrically connected to the current acquisition unit in the data measurement and acquisition module, its second end electrically connected to the positive input terminal of the electrolytic cell, and its third end electrically connected to both the electrochemical impedance spectroscopy scanning device and the hydrogen production power supply.

9. The impedance modeling equivalent system for electrolytic cells according to claim 7, characterized in that, Also includes: The communication module is connected to the data measurement and acquisition module, the data processing and calculation module, the simulator, and the host computer, respectively.