PEM water electrolysis hydrogen production multivariable model prediction control method based on improved grey wolf optimization algorithm and hydrogen production system

By improving the predictive control weight matrix of the Gray Wolf Optimization Algorithm Optimization Model, IGWO-MPC dual-ring collaborative control architecture was constructed, and the problem of unstable multivariable coupling control of PEM electrolytic cells was solved, achieving efficient and stable electrolytic efficiency and temperature management.

CN120560033APending Publication Date: 2025-08-29TIANJIN CHENGJIAN UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510697983.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-05-28
Publication Date
2025-08-29

AI Technical Summary

Technical Problem

The existing PEM electrolytic cell control methods cannot effectively coordinate the coupling effects of multivariable variables such as current density, temperature and pressure, resulting in instability and inefficiency of control. The weight matrix selection of traditional MPC lacks theoretical basis, resulting in poor control effect.

Method used

The IGWO-MPC dual-ring collaborative control architecture is constructed by using the improved Gray Wolf Optimization Algorithm (IGWO) optimization model prediction control (MPC) weight matrix, and the PEM electrolytic cell multivariate model prediction control method is established through the linearization of weighted least squares normal and the improved Gray Wolf Optimization Algorithm optimization algorithm.

Benefits of technology

It improves control accuracy and stability, reduces temperature fluctuations, and stabilizes the electrolytic efficiency between 78% and 80%, enhances the robustness of the system and adapts to industrial applications of different scales.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120560033A_ABST
    Figure CN120560033A_ABST
Patent Text Reader

Abstract

The invention discloses a PEM water electrolysis hydrogen production multivariable model prediction control method based on an improved grey wolf optimization algorithm and a hydrogen production system, and belongs to the field of hydrogen energy preparation control. Aiming at the problems of control overshoot and weight matrix randomness caused by multivariable coupling of a PEM hydrogen production system, an IGWO-MPC double-loop control architecture is provided: a global model covering current density, temperature and pressure is constructed, and the voltage, temperature and power of an electrolytic cell are analyzed; carrying out robust linearization on the nonlinear efficiency by adopting a weighted least square method, and establishing a state space model; the MPC weight matrix is dynamically optimized by improving the grey wolf algorithm, and the multi-physics coupling instability is inhibited by combining a convergence factor adaptive adjustment strategy. The method breaks through the limitation of traditional empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical empirical
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to electrolyzer hydrogen production process control technology, and in particular to a multivariable collaborative control method for a PEM water electrolysis hydrogen production system based on a combination of an improved grey wolf optimization algorithm and model predictive control, and a PEM water electrolysis hydrogen production system. Background Art

[0002] As the global energy structure shifts toward cleaner energy, hydrogen energy, as a highly efficient secondary energy source, has attracted considerable attention. Proton exchange membrane (PEM) water electrolysis has become a mainstream technology due to its rapid response and high efficiency. However, its efficiency is affected by the coupling of multiple variables, including current density, temperature, and pressure. Existing control methods have significant shortcomings:

[0003] 1. The efficiency of PEM electrolyzer is affected by the coupling of multiple factors such as current density, temperature, and pressure. Traditional PID control is only designed for a single variable (such as current or temperature) and cannot coordinate the multi-variable coupling effect of the electrolyzer.

[0004] 2. In PEM electrolyzer control, the weighted matrix of traditional MPC is usually given directly, lacking theoretical basis and calculation method, and has great randomness and instability problems. In multivariable systems such as current, temperature, and pressure, empirical weights are difficult to balance the interaction effects between variables, resulting in overshoot or lag. Summary of the Invention

[0005] To address these shortcomings, this application proposes a multivariable model predictive control method for PEM electrolyzers based on improved Gray Wolf optimization. This method utilizes model predictive control to achieve coordinated control of multiple variables in the PEM electrolysis hydrogen production process. Furthermore, considering that traditional MPC relies on empirically selected weight matrices, it is difficult to quantify priorities, which can easily lead to over-compromise or neglect of certain objectives, making the numerical solution of the PEM electrolyzer optimization problem difficult. Therefore, an improved Gray Wolf optimization algorithm is used to optimize the MPC weight matrix calculation process, forming an IGWO-MPC dual-loop collaborative control architecture to optimize the control of the electrolysis hydrogen production process.

[0006] In order to solve the above technical problems, the technical solutions of the present invention are as follows:

[0007] A multivariable model predictive control method for a PEM electrolyzer system based on improved gray wolf optimization, the PEM electrolyzer system comprising a PEM electrolyzer voltage model, a temperature management model, and a pressure management model, the temperature management model comprising a connected water supply pump and a heat exchanger, the water inlet of the water supply pump being connected to the water outlet of the electrolyzer, and the water outlet of the heat exchanger being connected to the water inlet of the electrolyzer; the pressure management model comprising a pressure valve, a dryer, and a hydrogen storage tank; the multivariable model predictive control method comprising the improved gray wolf optimization comprises the following steps:

[0008] Step 1: Considering the synergistic effects of current density, operating temperature, and operating pressure, a global model of the PEM electrolysis hydrogen production process is established;

[0009] Step 2: A robust linearization method based on weighted least squares is proposed to construct a state-space model of hydrogen production efficiency of PEM electrolyzer;

[0010] Step 3: Propose a dual-loop collaborative control framework based on the combination of improved grey wolf optimization algorithm (IGWO) and model predictive control (MPC).

[0011] The preferred method is that the global model of the PEM electrolysis hydrogen production process includes an electrolyzer voltage model, an operating temperature model, an operating pressure model and an electrolyzer power binary decomposition model.

[0012] (1) The electrolytic cell voltage model includes the synergistic effect of variables such as input current, operating temperature, and operating voltage on the electrolytic cell voltage. A PEM electrolytic cell is usually composed of multiple electrolytic cells connected in series. The electrolytic voltage U of a single electrolytic cell is cell It can be decomposed into the Nernst voltage U Nernst , activation overvoltage U act , Ohmic overvoltage U ohm Three parts:

[0013] U cell =U Nernst +U ohm +U act

[0014] U Nernst is the Nernst voltage, and the calculation equation is as follows:

[0015]

[0016] The calculation equation of reversible voltage E0 is as follows:

[0017]

[0018] In the above formula: ΔG 0 =237.18kj / mol is Gibbs free energy, F = 96485C / mol is Faraday constant, R = 8.314J / mol is gas constant, T is the working temperature of the electrolytic cell, and Represent the pressures of hydrogen and oxygen in the electrolyzer respectively.

[0019] U act is the activation overvoltage, and the calculation equation is as follows:

[0020]

[0021] Where: R = 8.314 J / mol is the ideal gas constant, α = 0.43 is the charge transfer coefficient, j0 = 8 × 10-6 A / cm 2 is the exchange current density, z = 2 is the number of moles of transferred electrons, and F = 96485 C / mol is the Faraday constant.

[0022] U ohm is the ohmic overvoltage, and the calculation equation is as follows:

[0023] U ohm =R ohm ×I

[0024] in:

[0025]

[0026] R ohm is the ohmic resistance of the proton exchange membrane (PEM), I is the electrolyzer current, and t membrane is the thickness of the proton membrane, σ is the conductivity, σ 30 The conductivity at the reference temperature of 30°C, lambda membrane is the water content of the proton membrane, lambda acl Anode water content, lambda ccl Cathode water content, T cell is the electrolytic cell temperature.

[0027] (2) The operating temperature model includes the mathematical relationship between temperature and electrolyzer current, water supply flow rate, and water supply valve opening. The electrolyzer operating temperature plays an important role in the PEM electrolysis hydrogen production process. Selecting the appropriate electrolyzer operating temperature is an important factor in optimizing hydrogen production. To protect the proton membrane structure from damage, the PEM electrolyzer operating temperature is usually maintained at 55°C to 65°C.

[0028]

[0029] in

[0030]

[0031] Therefore, the electrolytic cell temperature T cell :

[0032] T cell =T0+ΔT

[0033]

[0034] In the above formula, S MEA is the electrolysis area, is the thermal neutral voltage, C pω is the specific heat capacity of water at standard temperature, Q cis the water mass flow rate, S1 is the cross-sectional area of ​​the circulating pump water supply pipe, V1 is the water supply flow rate, D1 is the opening of the water supply valve, T0 is the standard temperature of 20℃, ΔT is the increase in electrolytic cell temperature, I is the electrolytic cell current, ΔT is the increase in electrolytic cell temperature, and ρ is the density of water.

[0035] (3) The operating pressure model includes the mathematical relationship between pressure and input current, operating temperature, hydrogen flow rate, and pressure valve opening. In the process of hydrogen electrolysis, hydrogen pressure is an important operating parameter. It not only affects hydrogen output and energy efficiency, but is also closely related to equipment safety and system design.

[0036] The pressure in the electrolyzer is adjusted by controlling the hydrogen flow rate through a regulating valve.

[0037]

[0038] in,

[0039]

[0040] The operating pressure p of the electrolytic cell is:

[0041] p=p0+Δp

[0042]

[0043] Where t is the time step in seconds, p(t) is the pressure value at t, p(t-1) is the pressure value at t-1, R=8.314 J / mol is the gas constant, and T cell is the electrolytic cell temperature, is the volume of hydrogen, is the amount of hydrogen produced, Δt is the unit time, N cell is the number of electrolytic chambers, MW H2 is the molar mass of hydrogen, I is the electrolytic cell current, S MEA is the electrolysis area, is the lower heating value of hydrogen, S2 is the cross-sectional area of ​​the tube, V2 is the hydrogen flow rate, D2 is the pressure valve opening, and ρ is the density of water.

[0044] (4) The binary decomposition model of electrolyzer power analyzes the total input electrical power into hydrogen production power (effective power) and heat generation power (loss power), breaking through the modeling limitations of a single power indicator.

[0045] Electrolyzer hydrogen production efficiency η cell Depends on the current efficiency η c and voltage efficiency η v , current efficiency η c Using Faraday efficiency η F It means that when the temperature and pressure are constant, the voltage efficiency ηv The calculation equation is as follows:

[0046]

[0047] Current efficiency η c The calculation equation is as follows:

[0048] η c =η F =(-0.0034p-0.001711)·(I) -1 +1

[0049] Electrolyzer efficiency η cell The calculation equation is as follows:

[0050]

[0051] Among them, N cell is the number of electrolysis chambers, is the thermal neutral voltage, U cell is the cell voltage, p is the cell pressure, and I is the cell current.

[0052] Hydrogen production power refers to the electrical energy consumed per unit time by the water electrolysis hydrogen production system, which is used to decompose water into hydrogen and oxygen. The calculation equation is as follows:

[0053]

[0054] During the electrolysis process, the part of the total electrical energy (total power) that is not converted into hydrogen energy is lost in the form of heat energy, and the waste heat power is the recyclable part. By increasing the waste heat power recovery and reducing the heating power, the efficiency of the electrolyzer can be improved. The calculation equation is as follows:

[0055]

[0056]

[0057] The second step includes:

[0058] (1) Initial value calculation: Use the traditional least squares method to fit the initial linear model and calculate the residual r g ;

[0059] (2) Weight update: Dynamically adjust the weight according to the residual, and reduce the weight of points with large residuals;

[0060] (3) Model refitting: refitting the linear model with the new weights and repeating until convergence;

[0061] Calculate the residual for each data point (actual value - predicted value).

[0062] Dynamic weight function:

[0063]

[0064] in, is the actual value, is the predicted value, τ is the set threshold, and g is the measured data point;

[0065] Construct a weighted objective function:

[0066]

[0067] After linearization processing using weighted least squares method, the nonlinear electrolyzer efficiency is transformed into a linear relationship.

[0068] η cell =0.2246p+0.0003T cell -0.0001I-0.0543

[0069] Since the electrolyzer efficiency η cell is a nonlinear relationship. The computational complexity of nonlinear models in MPC is usually much higher than that of linear models. In order to simplify the calculation, η cell Perform linearization. Assign lower weights to data points with larger linearization residuals and higher weights to data points with smaller residuals, in order to suppress the influence of outliers on the model. Through multiple iterations, the interference of outliers is gradually weakened.

[0070] When the model is linearized using the traditional least squares method, even a small number of outliers may significantly affect the estimation of the regression coefficient, causing the linearization result to deviate too much and making it impossible to accurately control the model. cell The linearization process is performed using the formula. The weight of points with large residual values ​​is reduced to reduce the impact of outliers on the linearization results and improve the accuracy of the linearization results.

[0071] According to η cell The linear relationship is combined with the PEM electrolyzer voltage model, operating temperature model, and operating pressure model to establish the state space expression of the electrolyzer hydrogen production efficiency model.

[0072] The step three includes:

[0073] (1) Construct a cost function for the efficiency model of the PEM electrolyzer hydrogen production system and transform the cost function minimum solution into a quadratic programming problem;

[0074] (2) An improved grey wolf algorithm is proposed to optimize the state weight matrix Q and control weight matrix R in the MPC controller;

[0075] (3) Based on the improved grey wolf algorithm proposed in (2), the IGWO-MPC composite algorithm is proposed.

[0076] The cost function of the efficiency model of the PEM electrolyzer hydrogen production system is:

[0077]

[0078] in

[0079]

[0080] Where: k is the time step index, i is the prediction time domain step index, N p is the prediction time domain, N c For the control time domain, λ1 and λ2 are the weight factors of the state increments of the tank pressure and the tank temperature, respectively. ρ1 and ρ2 are the weight factors of the state increments of pressure and temperature, respectively. Q is the state weight matrix, R is the control weight matrix, and x c is the predicted state value, x ref is the reference state value, the population size of IGWO is 50, and the prediction time domain of MPC is N p =10, control time domain N c =8.

[0081] The cost function minimum solution is transformed into a quadratic programming problem. The quadratic objective term H is composed of the control matrix B, the state matrix A, the state increment weighting matrix Q and the control increment. Finally, the cost function is simplified to:

[0082]

[0083] Since different state weight matrices Q directly affect the performance of the MPC controller, the weight matrix Q selected based on experience is subject to significant randomness and instability. Therefore, a reasonable design of the Q matrix is ​​necessary to strike a balance between the system's response speed and input smoothness, thereby optimizing the MPC control effect. This paper proposes an improved gray wolf algorithm to optimize the MPC controller state weight matrix Q.

[0084] The gray wolf unified position update formula is:

[0085]

[0086] Where: is the distance between the gray wolf and its prey, For prey location, and are the positions of the gray wolf in generation i and generation i+1. A and C are coefficient vectors, with a being a linearly decreasing convergence factor between 2 and 0. r1 and r2 are random numbers between [0,1].

[0087] The convergence factor a is dynamically adjusted using the improved grey wolf optimization algorithm (IGWO). The convergence factor a1 based on the cosine function and the exponential function is expressed as follows:

[0088]

[0089] Where a ini =2 is the initial value, a fin =0 is the final value, j is the current iteration number, j max is the maximum number of iterations.

[0090] The formula for updating the gray wolf's position is as follows:

[0091]

[0092] In the formula Represent α, β, and δ, respectively, the distance between the wolf and the prey. are the current positions of α, β, and δ wolves respectively. is a random vector, and X is the current position of the gray wolf individual.

[0093]

[0094] The positions of the three levels of gray wolves are used to update the positions of other ω gray wolves according to the above formula.

[0095] The present invention also provides a PEM water electrolysis hydrogen production system, which is used to implement the aforementioned PEM electrolyzer multivariable model predictive control method based on the improved gray wolf optimization algorithm. The electrolyzer membrane area of ​​the system is 280-500cm 2 , the operating temperature range is 55-65℃, and the pressure range is 0.1-3MPa.

[0096] Preferably, the system comprises:

[0097] Temperature management module: It consists of a water supply pump, a heat exchanger, and valves. The IGWO-MPC dual-loop controller adjusts the circulation pump flow rate and the water supply flow rate to control the electrolyzer temperature.

[0098] Pressure management module: It consists of a pressure valve, a dryer and a hydrogen storage tank. The IGWO-MPC dual-loop controller is used to adjust the opening of the hydrogen discharge valve and the hydrogen flow rate to control the pressure in the tank.

[0099] Compared with the prior art, the present invention has the following beneficial effects:

[0100] 1. Improved dynamic control accuracy: The temperature fluctuation amplitude is reduced by 56.8%, and the electrolysis efficiency is stabilized at 78%-80%, avoiding the overshoot and lag problems of traditional control.

[0101] 2. Enhanced robustness: The improved Grey Wolf optimization algorithm is combined with a dynamic weight matrix to effectively suppress the cross-interference effects of multi-physics field coupling current, temperature, and pressure.

[0102] 3. Engineering practicality: The electrolyzer has a wide range of parameters (area, temperature, pressure), is compatible with industrial applications of different scales, and can be easily integrated into existing energy systems.

[0103] Through the above improvements, the present invention solves the control instability problem caused by multivariable coupling in the PEM water electrolysis hydrogen production system, and provides an efficient and reliable solution for the clean energy transition. BRIEF DESCRIPTION OF THE DRAWINGS

[0104] Figure 1 This is a schematic diagram of the IGWO-MPC composite algorithm flow in the present invention;

[0105] Figure 2 This is the basic structure of the PEM water electrolysis hydrogen production system in the present invention;

[0106] Figure 3 This is a comparison chart of the change curves of different convergence factor types in the improved GWO of the present invention;

[0107] Figure 4 : is a comparison diagram of the results of the PEM electrolysis hydrogen production control method of the present invention, wherein (a) is a schematic diagram of 24-hour photovoltaic power generation, (b) and (c) are schematic diagrams of the electrolyzer input current and input voltage, (d) and (e) are schematic diagrams of the electrolyzer temperature and pressure changes under three control methods, (f) and (g) are schematic diagrams of hydrogen production rate and hydrogen production amount, (h) and (i) are schematic diagrams of electrolyzer hydrogen production power and waste heat power, and (j) is a schematic diagram of electrolyzer efficiency;

[0108] Figure 5 This is a comparison chart of the residuals of the weighted least squares linearization results in the present invention;

[0109] Figure 6 is the electrolytic cell efficiency surface considering the current density and the temperature in the cell in the present invention;

[0110] Figure 7 is the electrolytic cell efficiency surface considering the current density and the pressure in the cell in the present invention;

[0111] Figure 8 It is a comparison diagram of the polarization curves of the PEM electrolyzer simulation and experiment in the present invention. DETAILED DESCRIPTION

[0112] In order to make the technical solutions, innovative points and technical effects of the present invention clearer, the implementation methods of the present application are now described in detail in conjunction with the accompanying drawings and specific examples. It should be clearly stated that the described embodiments are only exemplary presentations of the preferred implementation methods of the present invention, not all possible implementation methods. Based on the technical solutions disclosed in this application, all equivalent implementation cases or improvement plans obtained by those skilled in the art without creative work fall within the scope of protection of the present invention.

[0113] The technical parameters, control logic and hardware configuration described in the embodiment (such as the electrolytic cell membrane area of ​​280cm 2 IGWO population size 30, MPC prediction time domain N p =10, etc.) is only a preferred embodiment, and can be adjusted according to needs in actual application (such as expanding the membrane area to 500cm 2 To adapt to a larger-scale hydrogen production system, or adjust the gray wolf population size to 50 to improve optimization accuracy), such adjustments are all within the scope of protection of the present invention.

[0114] Those skilled in the art can implement the present invention by replacing equivalent components (such as using particle swarm optimization (PSO) instead of IGWO to achieve weight matrix optimization) or adjusting the system architecture (such as expanding the control of a single electrolyzer to parallel control of multiple electrolyzers). As long as the technical solution does not deviate from the core innovation defined in the present invention (i.e., "multivariable coupling control method based on improved gray wolf optimization"), it shall fall within the scope of protection of the present invention.

[0115] The technical parameters, experimental conditions, and algorithm configurations involved in the examples may be adaptively adjusted according to actual application scenarios. Such adjustments do not constitute a substantial modification to the technical solutions of the present invention. The structural relationships, control processes, and data curves shown in the drawings may be scaled or partially simplified for graphical purposes. The details should be based on the text descriptions and formula derivations.

[0116] Example 1

[0117] Based on the problems of the prior art, the present invention provides a multivariable model predictive control method for a PEM electrolyzer system based on improved gray wolf optimization. The PEM electrolyzer system includes a PEM electrolyzer voltage model, a temperature management model, and a pressure management model. The temperature management model includes a connected water supply pump and a heat exchanger, the water inlet of the water supply pump is connected to the water outlet of the electrolyzer, and the water outlet of the heat exchanger is connected to the water inlet of the electrolyzer; the pressure management model includes a pressure valve, a dryer, and a hydrogen storage tank; the multivariable model predictive control method based on improved gray wolf optimization includes the following steps:

[0118] Step 1: Considering the synergistic effects of current density, operating temperature, and operating pressure, a global model of the PEM electrolysis hydrogen production process is established;

[0119] Step 2: A robust linearization method based on weighted least squares is proposed to construct a state-space model of hydrogen production efficiency of PEM electrolyzer;

[0120] Step 3: Propose a dual-loop collaborative control framework based on the combination of improved grey wolf optimization algorithm (IGWO) and model predictive control (MPC).

[0121] The preferred method is that the global model of the PEM electrolysis hydrogen production process includes an electrolyzer voltage model, an operating temperature model, an operating pressure model and an electrolyzer power binary decomposition model.

[0122] (1) The electrolytic cell voltage model includes the synergistic effect of variables such as input current, operating temperature, and operating voltage on the electrolytic cell voltage. A PEM electrolytic cell is usually composed of multiple electrolytic cells connected in series. The electrolytic voltage U of a single electrolytic cell is cell It can be decomposed into the Nernst voltage U Nernst , activation overvoltage U act , Ohmic overvoltage U ohm Three parts:

[0123] U cell =U Nernst +U ohm +U act

[0124] U Nernst is the Nernst voltage, and the calculation equation is as follows:

[0125]

[0126] The calculation equation of reversible voltage E0 is as follows:

[0127]

[0128] In the above formula: ΔG 0 =237.18kj / mol is Gibbs free energy, F = 96485C / mol is Faraday constant, R = 8.314J / mol is gas constant, T is the working temperature of the electrolytic cell, and Represent the pressures of hydrogen and oxygen in the electrolyzer respectively.

[0129] U act is the activation overvoltage, and the calculation equation is as follows:

[0130]

[0131] Where: R = 8.314 J / mol is the ideal gas constant, α = 0.43 is the charge transfer coefficient, j0 = 8 × 10-6 A / cm 2 is the exchange current density, z = 2 is the number of moles of transferred electrons, and F = 96485 C / mol is the Faraday constant.

[0132] U ohm is the ohmic overvoltage, and the calculation equation is as follows:

[0133] U ohm =R ohm ×I

[0134] in:

[0135]

[0136] R ohm is the ohmic resistance of the proton exchange membrane (PEM), I is the electrolyzer current, and t membrane is the thickness of the proton membrane, σ is the conductivity, σ 30 The conductivity at the reference temperature of 30°C, lambda membrane is the water content of the proton membrane, lambda acl Anode water content, lambda ccl Cathode water content, T cell is the electrolytic cell temperature.

[0137] (2) The operating temperature model includes the mathematical relationship between temperature and electrolyzer current, water supply flow rate, and water supply valve opening. The electrolyzer operating temperature plays an important role in the PEM electrolysis hydrogen production process. Selecting the appropriate electrolyzer operating temperature is an important factor in optimizing hydrogen production. To protect the proton membrane structure from damage, the PEM electrolyzer operating temperature is usually maintained at 55°C to 65°C.

[0138]

[0139] in

[0140]

[0141] Therefore, the electrolytic cell temperature T cell :

[0142] T cell =T0+ΔT

[0143]

[0144] In the above formula, S MEA is the electrolysis area, is the thermal neutral voltage, C pω is the specific heat capacity of water at standard temperature, Q cis the water mass flow rate, S1 is the cross-sectional area of ​​the circulating pump water supply pipe, V1 is the water supply flow rate, D1 is the opening of the water supply valve, T0 is the standard temperature of 20℃, ΔT is the increase in electrolytic cell temperature, I is the electrolytic cell current, ΔT is the increase in electrolytic cell temperature, and ρ is the density of water.

[0145] (3) The operating pressure model includes the mathematical relationship between pressure and input current, operating temperature, hydrogen flow rate, and pressure valve opening. In the process of hydrogen electrolysis, hydrogen pressure is an important operating parameter. It not only affects hydrogen output and energy efficiency, but is also closely related to equipment safety and system design.

[0146] The pressure in the electrolyzer is adjusted by controlling the hydrogen flow rate through a regulating valve.

[0147]

[0148] in,

[0149]

[0150] The operating pressure p of the electrolytic cell is:

[0151] p=p0+Δp

[0152]

[0153] Where t is the time step in seconds, p(t) is the pressure value at t, p(t-1) is the pressure value at t-1, R=8.314 J / mol is the gas constant, and T cell is the electrolytic cell temperature, is the volume of hydrogen, is the amount of hydrogen produced, Δt is the unit time, N cell is the number of electrolytic chambers, MW H2 is the molar mass of hydrogen, I is the electrolytic cell current, S MEA is the electrolysis area, is the lower heating value of hydrogen, S2 is the cross-sectional area of ​​the tube, V2 is the hydrogen flow rate, D2 is the pressure valve opening, and ρ is the density of water.

[0154] (4) The binary decomposition model of electrolyzer power analyzes the total input electrical power into hydrogen production power (effective power) and heat generation power (loss power), breaking through the modeling limitations of a single power indicator.

[0155] Electrolyzer hydrogen production efficiency η cell Depends on the current efficiency η c and voltage efficiency η v , current efficiency η c Using Faraday efficiency η F It means that when the temperature and pressure are constant, the voltage efficiency ηv The calculation equation is as follows:

[0156]

[0157] Current efficiency η c The calculation equation is as follows:

[0158] η c =η F =(-0.0034p-0.001711)·(I) -1 +1

[0159] Electrolyzer efficiency η cell The calculation equation is as follows:

[0160]

[0161] Among them, N cell is the number of electrolysis chambers, is the thermal neutral voltage, U cell is the cell voltage, p is the cell pressure, and I is the cell current.

[0162] Hydrogen production power refers to the electrical energy consumed per unit time by the water electrolysis hydrogen production system, which is used to decompose water into hydrogen and oxygen. The calculation equation is as follows:

[0163]

[0164] During the electrolysis process, the part of the total electrical energy (total power) that is not converted into hydrogen energy is lost in the form of heat energy, and the waste heat power is the recyclable part. By increasing the waste heat power recovery and reducing the heating power, the efficiency of the electrolyzer can be improved. The calculation equation is as follows:

[0165]

[0166] The second step includes:

[0167] (1) Initial value calculation: Use the traditional least squares method to fit the initial linear model and calculate the residual r g ;

[0168] (2) Weight update: Dynamically adjust the weight according to the residual, and reduce the weight of points with large residuals;

[0169] (3) Model refitting: refitting the linear model with the new weights and repeating until convergence;

[0170] Calculate the residual for each data point (actual value - predicted value).

[0171] Dynamic weight function:

[0172]

[0173] in, is the actual value, is the predicted value, τ is the set threshold, and g is the measured data point;

[0174] Construct a weighted objective function:

[0175]

[0176] After linearization processing using weighted least squares method, the nonlinear electrolyzer efficiency is transformed into a linear relationship.

[0177] η cell =0.2246p+0.0003T cell -0.0001I-0.0543

[0178] Since the electrolyzer efficiency η cell is a nonlinear relationship. The computational complexity of nonlinear models in MPC is usually much higher than that of linear models. In order to simplify the calculation, η cell Perform linearization. Assign lower weights to data points with larger linearization residuals and higher weights to data points with smaller residuals, in order to suppress the influence of outliers on the model. Through multiple iterations, the interference of outliers is gradually weakened.

[0179] When the model is linearized using the traditional least squares method, even a small number of outliers may significantly affect the estimation of the regression coefficient, causing the linearization result to deviate too much and making it impossible to accurately control the model. cell The linearization process is performed using the formula. The weight of points with large residual values ​​is reduced to reduce the impact of outliers on the linearization results and improve the accuracy of the linearization results.

[0180] According to η cell The linear relationship is combined with the PEM electrolyzer voltage model, operating temperature model, and operating pressure model to establish the state space expression of the electrolyzer hydrogen production efficiency model.

[0181] The step three includes:

[0182] (1) Construct a cost function for the efficiency model of the PEM electrolyzer hydrogen production system and transform the cost function minimum solution into a quadratic programming problem;

[0183] (2) An improved grey wolf algorithm is proposed to optimize the weight matrix Q in the MPC controller;

[0184] (3) Based on the improved grey wolf algorithm proposed in (2), the IGWO-MPC composite algorithm is proposed.

[0185] The cost function of the efficiency model of the PEM electrolyzer hydrogen production system is:

[0186]

[0187] in

[0188]

[0189] Where: N p is the prediction time domain, N c For the control time domain, λ1 and λ2 are the weight factors of the state increments of the tank pressure and the tank temperature, respectively. ρ1 and ρ2 are the weight factors of the state increments of pressure and temperature, respectively. Q is the state weight matrix, R is the control weight matrix, and x c is the predicted state value, x ref is the reference state value, the population size of IGWO is 50, and the prediction time domain of MPC is N p =10, control time domain N c =8.

[0190] The cost function minimum solution is transformed into a quadratic programming problem. The quadratic objective term H is composed of the control matrix B, the state matrix A, the state weight matrix Q and the control increment. Finally, the cost function is simplified to:

[0191]

[0192] Since different state weight matrices Q directly affect the performance of the MPC controller, the state weight matrix Q selected empirically is subject to significant randomness and instability. Therefore, a reasonable design of the Q matrix is ​​necessary to strike a balance between the system's response speed and input smoothness, thereby optimizing the MPC control effect. This paper proposes an improved gray wolf algorithm to optimize the MPC controller state weight matrix Q.

[0193] The gray wolf unified position update formula is:

[0194]

[0195] Where: is the distance between the gray wolf and its prey, For prey location, and are the positions of the gray wolf in generation i and generation i+1. A and C are coefficient vectors, with a being a linearly decreasing convergence factor between 2 and 0. r1 and r2 are random numbers between [0,1].

[0196] The convergence factor a is dynamically adjusted using the improved grey wolf optimization algorithm (IGWO). The convergence factor a1 based on the cosine function and the exponential function is expressed as follows:

[0197]

[0198] Where a ini =2 is the initial value, a fin =0 is the final value, j is the current iteration number, j max is the maximum number of iterations.

[0199] The formula for updating the gray wolf's position is as follows:

[0200]

[0201] In the formula Represent α, β, and δ, respectively, the distance between the wolf and the prey. are the current positions of α, β, and δ wolves respectively. is a random vector, and X is the current position of the gray wolf individual.

[0202]

[0203] The positions of the three levels of gray wolves are used to update the positions of other ω gray wolves according to the above formula.

[0204] Example 2

[0205] Based on the first embodiment, this example provides a PEM electrolyzer control method based on the IGWO-MPC composite algorithm. The flow chart of the IGWO-MPC composite algorithm in the present invention is as follows: Figure 1 As shown, the basic structure of the PEM water electrolysis hydrogen production system can be found in Figure 2 , including solar energy supply part, PEM electrolyzer electrolysis hydrogen production part, and MPC control part.

[0206] In this example, the state space construction of the electrolyzer hydrogen production efficiency model includes:

[0207] Weighted least squares method for η cell The linearized residuals are compared to Figure 5 As shown. Figure 5 Comparing the residuals, the weighted least squares method significantly reduces the abnormal residual value of the least squares method, the residual fluctuation is small, and the linearization accuracy is improved. cell The coefficient of determination (R 2 ) is 0.8940, and the coefficient of determination of the weighted least squares method (R 2 ) is 0.9895.

[0208] The state space of a linear discrete system is expressed as:

[0209]

[0210] in,

[0211]

[0212] Where: x is the state variable, u is the control variable, A is the state matrix, B is the control matrix; p is the pressure in the tank, T cell is the temperature in the cell, I is the input current of the electrolytic cell, η cell is the electrolytic cell efficiency; R = 8.314 J / mol is the gas constant, is the hydrogen production, is the hydrogen flow rate, S MEA is the electrolysis area, U cell is the electrolytic cell voltage, Q c is the water mass flow rate, D2 and D1 are the valve openings of the pressure valve and the water supply valve.

[0213] The improvement of the Grey Wolf Algorithm (IGWO) of the present invention specifically includes:

[0214] In the GWO algorithm, the value of the convergence coefficient A influences both the algorithm's global and local search capabilities. When |A| > 1, the wolf pack conducts a global search to find other prey; when |A| < 1, the wolf pack conducts a local search to attack its prey. The magnitude of A is controlled by the convergence factor a. During the iteration process, the convergence factor a linearly decreases from 2 to 0, causing the algorithm to lose balance between local and global search. Therefore, the convergence factor proposed in this paper is shown in equation a1 below. To further verify the effectiveness of this convergence factor on algorithm search, other types of convergence factors were selected for comparative experiments. The remaining convergence factors are shown in the equation below.

[0215]

[0216] Where a ini =2 is the initial value, a fin =0 is the final value, j is the current iteration number, j max is the maximum number of iterations.

[0217] The comparison of the change curves of different convergence factor types is shown in the figure below: Figure 3As shown. The convergence factor of the GWO algorithm (i.e., a2) decreases at a uniform rate, and it cannot balance the global and local searches well during the search process. a3 and a4 can both maintain large values ​​in the early iterations, but a3 stops searching in the later iterations, and a4 is prone to miss the optimal solution in the later stages due to the large step size, thus falling into the local optimum. The convergence factor a1 proposed in the present invention shows a trend of slow decrease in the early stages of the iteration, ensuring that the convergence factor can maintain a high value within a certain period of time, thereby prompting the A value to remain large, and the algorithm performs a global search; as the iteration enters the later stages, the convergence factor gradually decreases to a smaller value, and the algorithm performs local exploration to prevent the optimal solution from being missed due to the large step size.

[0218] The IGWO-MPC composite control method in this example includes the following:

[0219] The IGWO-MPC composite algorithm proposed in this invention (such as Figure 1 The outer algorithm is the MPC algorithm, and the inner algorithm is the IGWO algorithm.

[0220] The inner layer adopts an improved gray wolf optimization algorithm, searches for the optimal control parameters through group intelligence, takes the rolling optimization cost function value of model predictive control as the fitness benchmark, and uses a hunting mechanism guided by the group optimal solution α, suboptimal solution β, and third solution δ wolves. The population is initialized to 50 gray wolves, each representing a set of Q, R parameter combinations. The α wolf dominates the search direction according to the current optimal solution, the β wolf adjusts the search step size through the dynamic convergence factor, and the δ wolf introduces the Levy flight strategy to avoid falling into local optimality, and globally optimizes the state weight matrix Q and the control weight matrix R.

[0221] The outer layer uses a model predictive control algorithm to construct a quadratic programming problem based on a state-space model, transforming the optimization problem of the PEM electrolysis system into a quadratic programming problem. The optimal control sequence in the future time domain is solved in a rolling manner. In each control cycle, the model predictive control constructs a prediction model based on the current state, solves the quadratic programming problem in a finite time domain online, dynamically optimizes the weight matrix and processes constraints, and updates the state in a rolling manner after executing the first control variable. Through closed-loop feedback, precise tracking and stable control of multiple variables are achieved.

[0222] The outer MPC algorithm is used to transform the optimization problem of the PEM electrolysis system into a QP problem. The MPC cost function is used as the fitness formula of the inner IGWO. The fitness value is calculated and the Q and R of the MPC algorithm are automatically iteratively adjusted to obtain the optimal control input sequence and state output sequence of the optimization problem.

[0223] In order to verify the effectiveness and efficiency of the proposed multivariable coordinated control strategy for the PEM electrolysis system, a simulation model of the PEM electrolysis hydrogen production system was developed in the MATLAB / SIMULINK platform. Photovoltaic input data were selected from the all-day solar profile recorded on December 14, 2024 at the National Renewable Energy Laboratory (NREL) location (39.74°N, 105.18°W). Figure 4 As shown in (a) in Figure 1, the photovoltaic output curve shows characteristic fluctuations affected by local meteorological conditions.

[0224] In order to verify the efficacy of the IGWO-MPC strategy, a comparative analysis was conducted between conventional PID control and traditional MPC methods. The results are shown in Figure 2. Figure 4 shown.

[0225] (1) In the traditional PID control strategy, a PID controller is designed to regulate the electrolyzer water supply pump and exhaust valve to achieve hydrogen production control by maintaining the internal temperature and pressure.

[0226] (2) In the traditional model predictive control (MPC) strategy, a prediction model is adopted that considers the multivariable coupling effects (current, temperature, and pressure), and the electrolyzer operation is coordinated through rolling horizon optimization.

[0227] (3) In the IGWO-MPC composite strategy, the improved grey wolf optimization algorithm (IGWO) is used to optimize the state weight matrix and control weight matrix of the MPC controller. By using the maximum hydrogen production utilization rate as the evaluation coefficient, this strategy achieves better dynamic response and operational stability in the proton exchange membrane (PEM) hydrogen production system.

[0228] Table 1 details the simulation parameters of the three PEM electrolysis hydrogen production system control methods: PID, MPC, and IGWO-MPC.

[0229] Table 1

[0230]

[0231] In this example, the coupling relationship between the main variables such as current density, operating temperature, operating pressure and hydrogen production power and heating power in the PEM electrolyzer is as follows: Figure 6 、 Figure 7 shown.

[0232] The efficiency of the electrolytic cell does not change monotonically with the change of current density, temperature in the electrolytic cell and pressure in the cell. Figure 6 It can be seen that the current density I directly affects the temperature ΔT through the heat generated by the electrolysis reaction, and the temperature T reacts on the ohmic overvoltage U through the conductivity σ ohm , which in turn affects the electrolytic cell voltage U cellWhen the temperature in the cell is fixed, the hydrogen production efficiency of the electrolyzer first increases rapidly and then decreases slowly with the increase of current density. 2 The maximum hydrogen production efficiency point is achieved within the range, but the input current at this time is low, the unit hydrogen production is small, and it cannot meet the demand for electrolytic hydrogen production; when the current density is fixed, the hydrogen production efficiency increases with the increase of the temperature in the cell, and the maximum hydrogen production efficiency point appears in the range of 336K~340K, which is about 73.2%. As the temperature continues to rise, the proton membrane is easily affected by the temperature, and the hydrogen production efficiency begins to decline, but the efficiency is still higher than when the temperature is lower.

[0233] The pressure p is converted to Nernst voltage U Nernst Directly affects voltage efficiency η v The Faraday efficiency affects the efficiency of the electrolyzer. When the pressure in the cell is fixed, although the current density is low and the electrolytic hydrogen production efficiency is high, the low input power leads to low electrolyzer power and low hydrogen production, which cannot meet the hydrogen production demand. At the same time, when the current density is high, the electrolysis efficiency decreases, but the increase in input power increases the hydrogen production of the electrolyzer.

[0234] Current density, operating temperature, and operating pressure are the three main factors affecting electrolytic hydrogen production efficiency. There is a complex coupling relationship between these three factors, and changes in one will also affect changes in the others, thereby affecting the electrolysis efficiency of the electrolyzer. Therefore, selecting the appropriate current density, operating temperature, and operating pressure is crucial to improving the efficiency and yield of hydrogen production through electrolysis.

[0235] The PEM electrolyzer model outputs polarization curves and simulation curves under experimental conditions (60℃ and 0.1MPa) as shown below: Figure 8 shown.

[0236] In order to verify the accuracy of the constructed PEM electrolyzer model, this study simulated and compared the polarization curves under experimental conditions (60°C and 0.1MPa). The results are as follows: Figure 8 The mean absolute error (MAE) between the simulation curve and the experimental data is 0.023V, and the determination coefficient R 2 =0.986. From the UI polarization curve, the PEM electrolyzer model has high accuracy.

[0237] The control results of the PEM electrolyzer in this example are compared as follows Figure 4 shown.

[0238] (1) Comparative analysis of the temperature and pressure control results in the tank:

[0239] The performance indicators of the three control methods of PID, MPC and IGWO-MPC in the temperature and pressure control of PEM electrolyzer are shown in Table 2.

[0240]

[0241] Steady-state maximum temperature T max The upper limit of the temperature allowed to be reached during the steady-state operation of the system, the minimum steady-state temperature T min is the lower limit of temperature to be maintained during the steady-state operation of the system, and the temperature stabilization time t sT The adjustment time required for the system to recover from the disturbance state to the set temperature, the temperature drop starting time t dT is the initial delay time for the temperature to drop from the set point, and the pressure stabilization time t sp The time required for the system pressure to adjust to the set value and remain stable.

[0242] As shown in Table 3, the IGWO-MPC control method proposed in this invention significantly outperforms the PID and MPC strategies in terms of performance. By optimizing the control weight matrix and the state weight matrix through the IGWO algorithm, the system temperature fluctuation amplitude is reduced from 13.37°C for the PID strategy and 7°C for the MPC strategy to 3.02°C, and the temperature fluctuation coefficient (calculated by ) decreased from 20.57% for PID and 10.77% for MPC to 4.65%. This effectively suppressed temperature oscillations and ensured stable internal temperature regulation. Compared with MPC, the system's operating time in the optimal temperature range was extended by 11.53%, significantly increasing the electrolyzer's effective operating time within the ideal thermodynamic range.

[0243] like Figure 4 As shown in the pressure dynamics in Figure (e), the proposed IGWO-MPC strategy significantly reduces the impact of power fluctuations on pressure stability. Compared to PID and MPC strategies, IGWO-MPC extends the time the pressure remains stable within the set range and maintains a stable electrolysis system efficiency of 70% to 80% (compared to 65% to 75% with the MPC strategy).

[0244] (2) Comparative analysis of hydrogen production rate and hydrogen production results:

[0245] The hydrogen production rate and hydrogen output of the three control methods were compared, and the hydrogen production rate and hydrogen production curve were drawn, as shown in Figure 2. Figure 4 (f) and (g) in .

[0246] Table 3

[0247]

[0248] For the multivariable coupling control of the electrolytic hydrogen production system, compared with the PID control method, MPC control and the IGWO-MPC control proposed in the present invention have improved the hydrogen production rate and hydrogen production. Compared with PID control, the cumulative hydrogen production of MPC control in 24 hours increased by 0.504 kg, an increase of 4.89%; compared with PID control, the cumulative hydrogen production of IGWO-MPC control increased by 0.698 kg, an increase of 6.78%.

[0249] At the same time, relying on the GWO optimized control weighted matrix and the control weighted matrix, compared with PID control and MPC control, the hydrogen production rate under IGWO-MPC control fluctuates less, with a standard deviation of 0.007, the standard deviation of the hydrogen production rate under MPC control is 0.020, and the standard deviation of PID control is 0.082, which prevents the hydrogen generation rate from fluctuating violently and causing problems such as reduced hydrogen purity.

[0250] (3) Comparative analysis of hydrogen production power, heating power, and electrolyzer efficiency results:

[0251] Figure 4 (h), (i) and (j) are the changing curves of hydrogen production power, heating power and electrolyzer efficiency under the three control methods of PID, MPC and GWO-MPC, respectively.

[0252] Comparing PID control and MPC control, IGWO-MPC control effectively reduces the fluctuation of hydrogen production power. The standard deviation of hydrogen production power is 0.7476, the standard deviation of MPC control is 1.451, and the standard deviation of PID control is 7.872. Figure 4 As can be seen from (i) and (j) in the figure, compared with traditional PID control and MPC control, the IGWO-MPC control proposed in the present invention adjusts the water supply flow rate and the hydrogen flow rate to promptly remove excess reaction heat, reduce the heating power of hydrogen production by electrolysis in the electrolyzer, and thus improve the efficiency of the electrolyzer. Its electrolyzer efficiency is higher than that of the electrolyzer under PID control and MPC control, and is maintained at a high level in the range of 78% to 80%.

[0253] (4) Analysis of control results

[0254] From the above analysis, it can be seen that compared with traditional methods, IGWO-MPC significantly improves the control performance of the electrolysis system by constructing a predictive model that explicitly combines the coupled dynamics of current, temperature and pressure. This method effectively solves the core problem of multivariable coupling interference in proton exchange membrane (PEM) electrolyzer systems.

[0255] Furthermore, compared with traditional MPC, IGWO-MPC uses an improved Grey Wolf Optimizer (IGWO) to solve the optimal control and state weight matrices in the MPC framework, achieving precise regulation of multiple variables and ensuring the efficient operation of the electrolysis hydrogen production system. At the same time, it solves the inherent limitations of traditional MPC, namely, the empirically selected weight matrix introduces a large amount of randomness and instability.

[0256] In summary, this application focuses on the multivariable coupling modeling and optimization control of the proton exchange membrane (PEM) water electrolysis hydrogen production system. The main research results are as follows:

[0257] (1) A three-variable dynamic coupling model integrating current density, operating temperature, and operating pressure was constructed, breaking through the limitations of traditional single-variable modeling. By introducing the dynamic equation of proton membrane water content and the coupling mechanism of heat and mass transfer, the model's prediction accuracy was improved by 23.6%, effectively characterizing the multi-physics coupling characteristics of electrochemical reactions, thermodynamic properties, and fluid dynamics during the electrolysis process.

[0258] (2) A weighted least squares linearization strategy based on dynamic weight allocation is proposed to overcome the problem of outlier sensitivity in nonlinear models. By constructing a residual feedback adjustment mechanism, the model linearization coefficient of determination is increased from 0.894 to 0.989, improving control stability under abnormal conditions and laying the foundation for robust control under complex conditions.

[0259] (3) An IGWO-MPC dual-loop collaborative architecture is proposed to achieve deep integration of dynamic optimization of control parameters and real-time decision-making. The improved convergence factor design improves the global search efficiency of the Grey Wolf optimization algorithm by 35%. By adaptively adjusting the MPC weight matrix, the problem of excessive operation caused by traditional experience empowerment is solved. Simulation results show that the algorithm reduces the temperature fluctuation amplitude from 7°C (61.9°C to 68.9°C) to 3.02°C (63.50°C to 66.52°C), which is 56.8% lower than that of traditional MPC. The cumulative hydrogen production increases by 0.504kg, which is 4.89% higher than that of traditional MPC.

[0260] Example 3

[0261] The present invention also provides a PEM water electrolysis hydrogen production system for engineering applications of the methods of Examples 1 and 2. Its technical features are as follows: the electrolytic cell membrane area of ​​the system is 280-500 cm 2 , the operating temperature range is 55-65℃, and the pressure range is 0.1-3MPa.

[0262] The system comprises:

[0263] Temperature management module: It consists of a water supply pump, a heat exchanger, and valves. The IGWO-MPC dual-loop controller adjusts the circulation pump flow rate and the water supply flow rate to control the electrolyzer temperature.

[0264] Pressure management module: It consists of a pressure valve, a dryer and a hydrogen storage tank. The IGWO-MPC dual-loop controller is used to adjust the opening of the hydrogen discharge valve and the hydrogen flow rate to control the pressure in the tank.

[0265] The above embodiments are merely preferred examples of the technical solutions of the present invention. Their purpose is to clearly demonstrate the technical principles and implementation paths, and they do not constitute any limitation on the scope of protection of the present invention. Any reasonable variations or improvements based on the essence of the technical solutions defined by the present invention through the following methods shall fall within the scope of protection of the present invention:

[0266] (1) Technical solution adjustment: including but not limited to algorithm optimization (such as the dynamic adjustment mechanism of the convergence factor of the Grey Wolf optimization algorithm), parameter adaptation (such as the expansion or compression of the MPC prediction time domain and the control time domain), and hardware equivalent replacement (such as the change of the circulation pump model);

[0267] (2) Application scenario expansion: Apply the control method to other electrolysis hydrogen production systems (such as alkaline electrolyzers, solid oxide electrolyzers) or coupled energy systems (such as wind-solar-hydrogen storage integrated systems);

[0268] (3) Implementation variants: adjustments to the control architecture, system topology, or component configuration (such as adding redundant sensors, modifying data communication protocols), as long as they do not deviate from the technical solution of the present invention.

Claims

1. A multivariable model predictive control method for hydrogen production by PEM water electrolysis based on an improved gray wolf optimization algorithm, characterized in that: The following steps are involved: Step 1: Establish a global model of the PEM electrolysis hydrogen production process. The global model integrates the synergistic effects of current density, operating temperature, and operating pressure to construct a multivariable coupled dynamic model of the proton exchange membrane electrolyzer. The global model includes: Electrolytic cell voltage model, including: electrolytic cell voltage U of a single electrolytic cell cell It can be decomposed into the Nernst voltage U Nernst , activation overvoltage U act and ohmic overvoltage U ohm , IN cell =U Nernst +U ohm +U act in, Ohmic overvoltage U ohm The calculation equation is: U ohm =R ohm ×I R ohm is the ohmic resistance of the proton exchange membrane, I is the electrolyzer current, t membrane is the thickness of the proton exchange membrane, σ is the conductivity, σ 30 The conductivity at the reference temperature of 30°C, lambda membrane is the water content of the proton exchange membrane, lambda acl Anode water content, lambda ccl Cathode water content, T cell is the electrolytic cell temperature; The working temperature model establishes the relationship between temperature and electrolytic cell current, water flow rate and valve opening through the following formula: Among them, T0 is the standard temperature of 20℃, ΔT is the increase in electrolytic cell temperature, S MEA is the electrolysis area, I is the electrolytic cell current, U cell is the electrolytic cell voltage, is the thermal neutral voltage, C pω is the specific heat capacity of water at standard temperature, S1 is the cross-sectional area of ​​the water supply pipe of the circulation pump, V1 is the water supply flow rate, and ρ is the density of water; Operating pressure model, dynamic balance is achieved by controlling the hydrogen flow rate through the regulating valve, and the pressure change equation is: Where t is the time step in seconds, p(t) is the pressure value at time t, p(t-1) is the pressure value at time t-1, R=8.314 J / mol is the gas constant, T cell is the electrolytic cell temperature, is the volume of hydrogen, is the amount of hydrogen produced, Δt is the unit time, N cell is the number of electrolytic cells, MW H2 is the molar mass of hydrogen, I is the electrolytic cell current, S MEA is the electrolysis area, is the lower heating value of hydrogen, S2 is the cross-sectional area of ​​the tube, V2 is the hydrogen flow rate, D2 is the pressure valve opening, and ρ is the density of water; Electrolyzer power binary decomposition model, electrolyzer hydrogen production efficiency η cell The model depends on the current efficiency η c and voltage efficiency η v , current efficiency η c Using Faraday efficiency η F It means that when the temperature and pressure are constant, the voltage efficiency η v The calculation equation is as follows: Current efficiency η c The calculation equation is as follows: or c =the F =(-0.0034p-0.001711)·(I) -1 +1 Electrolyzer efficiency η cell The calculation equation is as follows: Among them, N cell is the number of electrolysis chambers, is the thermal neutral voltage, U cell is the cell voltage, p is the cell pressure, and I is the cell current; Step 2: linearize the nonlinear relationship in step 1 using a robust linearization method based on weighted least squares to construct a state space model of the hydrogen production efficiency of the electrolyzer. The robust linearization method includes: Initial value calculation: Fit the initial linear model using the least squares method and calculate the residuals Dynamic weight adjustment: Set a threshold based on the residual distribution and reduce the weight coefficient w for data points outside the threshold g ; Iterative refitting: multiple rounds of model fitting are performed using a dynamic weight function until convergence; Dynamic weight function: in, is the actual value, is the predicted value, τ is the set threshold, and g is the measured data point; Step 3: Construct a dual-loop collaborative control framework combining IGWO and MPC, optimize the weight matrix calculation process of MPC through IGWO, and realize multivariable dynamic coupling control; The outer layer uses a model predictive control algorithm to construct a quadratic programming problem based on a state-space model, transforming the optimization problem of the PEM electrolysis system into a quadratic programming problem. The optimal control sequence in the future time domain is solved in a rolling manner. In each control cycle, the model predictive control constructs a prediction model based on the current state, solves the quadratic programming problem in a finite time domain online, dynamically optimizes the weight matrix and processes constraints, and updates the state in a rolling manner after executing the first control variable. Through closed-loop feedback, precise tracking and stable control of multiple variables are achieved. The inner layer uses an improved gray wolf optimization algorithm, searches for optimal control parameters through swarm intelligence, uses the rolling optimization cost function value of model predictive control as the fitness benchmark, and uses a hunting mechanism guided by the first solution α, second solution β, and third solution δ wolves in the swarm. The population is initialized to 50 gray wolves, each representing a set of Q and R parameter combinations. The α wolf leads the search direction based on the current optimal solution, the β wolf adjusts the search step size through a dynamic convergence factor, and the δ wolf introduces a Levy flight strategy to avoid falling into local optimality. The state weight matrix Q and the control weight matrix R are globally optimized. Online optimization of control parameters is achieved by dynamically adjusting the convergence factor.

2. The multivariable model predictive control method for hydrogen production by PEM water electrolysis based on the improved gray wolf optimization algorithm according to claim 1 is characterized in that: The improved grey wolf optimization algorithm in step 3 dynamically adjusts the convergence factor, based on the convergence factor a1 of the cosine function and the exponential function, and its expression is: Where a ini =2 is the initial value, a fin =0 is the final value, j is the current iteration number, j max is the maximum number of iterations.

3. The multivariable model predictive control method for hydrogen production by PEM water electrolysis based on the improved gray wolf optimization algorithm according to claim 1 is characterized in that: The weight matrices Q and R of the MPC are optimized by IGWO, and the cost function is: Among them, the weight matrices of the state increment Δx and the control increment Δu are: Among them, k is the time step index, i is the prediction time domain step index, N p is the prediction time domain, N c For the control time domain, λ1 and λ2 are the weight factors of the state increments of the tank pressure and the tank temperature, respectively. ρ1 and ρ2 are the weight factors of the state increments of pressure and temperature, respectively. Q is the state weight matrix, R is the control weight matrix, and x c is the predicted state value, x ref is the reference state value.

4. The multivariable model predictive control method for hydrogen production by PEM water electrolysis based on the improved gray wolf optimization algorithm according to claim 1 is characterized in that: The population size of IGWO in the method is 30-50, and the prediction time domain of MPC is N p =10, control time domain N c =8.

5. A PEM water electrolysis hydrogen production system, the system is used to implement the PEM water electrolysis hydrogen production multivariable model predictive control method based on the improved gray wolf optimization algorithm according to any one of claims 1 to 4, characterized in that: The electrolytic cell membrane area of ​​the system is 280-500cm 2 , the operating temperature range is 55-65℃, and the pressure range is 0.1-3MPa.

6. The PEM water electrolysis hydrogen production system according to claim 5, characterized in that: The system comprises: Temperature management module: It consists of a water supply pump, a heat exchanger, and valves. The IGWO-MPC dual-loop controller adjusts the circulation pump flow rate and the water supply flow rate to control the electrolyzer temperature. Pressure management module: It consists of a pressure valve, a dryer and a hydrogen storage tank. The IGWO-MPC dual-loop controller is used to adjust the opening of the hydrogen discharge valve and the hydrogen flow rate to control the pressure in the tank.