A gas-liquid two-phase continuous flow reactor and liquid level control method
By combining the multi-layer stirring paddle structure of magnetic stirring reactor and tubular reactor, combined with intelligent optimization algorithm and PID control, the liquid level stability control of the gas-liquid two-phase continuous flow reactor is achieved, solving the problem of liquid level in the gas-liquid two-phase reactor of traditional PID control algorithm, and improving the reaction effect and safety.
Patent Information
- Application Number
- CN202510202659.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-24
- Publication Date
- 2025-09-05
- Estimated Expiration
- 2045-02-24
AI Technical Summary
The existing PID control algorithms are difficult to achieve stable liquid level control in a two-phase continuous flow reactor of gas-liquid, resulting in a decrease in reaction effect or an increase in safety risks.
Combining the magnetic stirring reactor and the tubular reactor, a multi-layer stirring paddle structure is adopted, and the liquid level, pressure and magnetic stirrer loop current data are obtained in real time. The intelligent optimization algorithm and PID control algorithm are used to optimize the parameter vector to stabilize the liquid level.
The liquid level control stability of the gas-liquid two-phase continuous flow reactor is improved, the influence of liquid level fluctuations on the reaction effect is reduced, and safety is enhanced.
Smart Images

Figure CN120037839B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of reactor liquid level control, and in particular to a gas-liquid two-phase continuous flow reactor and a liquid level control method. Background Art
[0002] A continuous flow reactor is a device in which reactants flow into the reactor continuously and reaction products flow out of the reactor continuously. Its working principle is to maintain stable reaction conditions in the reactor and keep the reaction going by continuously inputting reactants and collecting products.
[0003] Liquid level is a key control parameter in gas-liquid reactions. If too little material is fed, the liquid level in the reactor is too low, resulting in insufficient stirring of the mixed reactants in the gas-liquid two-phase continuous flow reactor, which in turn reduces the reaction efficiency. If too much material is fed, the liquid level in the reactor is too high, and the reactor pressure is too high, which increases safety risks. However, due to the stirring action of the magnetic stirrer in the gas-liquid two-phase continuous flow reactor and the vigorous flow of the reactants in the gas-liquid two-phase state, the liquid level in the reactor fluctuates greatly. Existing PID (Proportional Integral Derivative) control algorithms have difficulty achieving relatively stable liquid level control, which affects the reaction efficiency. Summary of the Invention
[0004] In view of the above, it is necessary to provide a gas-liquid two-phase continuous flow reactor and a liquid level control method, which improves the stability of the liquid level control of the reactor compared with the traditional liquid level control method:
[0005] In the first aspect, an embodiment of the present application provides a gas-liquid two-phase continuous flow reactor, which is a new type of continuous flow reaction device that combines a magnetic stirring reactor and a tubular reactor. All parts of the gas-liquid two-phase continuous flow reactor that contact the reactants are made of C276 Hastelloy material; a magnetic stirrer is present in the gas-liquid two-phase continuous flow reactor; the reactants of the gas-liquid two-phase continuous flow reactor include liquid reactants and gaseous reactants, wherein the mixed reactants of the liquid reactants and the gaseous reactants in the reaction process are called gas-liquid two-phase mixed reactants.
[0006] In one embodiment, there are multiple layers of stirring paddles in the gas-liquid two-phase continuous flow reactor, wherein the stirring paddles above the feed inlet are push-down type, and the stirring paddles below the feed inlet are push-up type, and a static mixer is provided in the tubular reactor.
[0007] In a second aspect, an embodiment of the present application further provides a liquid level control method for a gas-liquid two-phase continuous flow reactor, the method comprising the following steps:
[0008] Real-time acquisition of the liquid level data, pressure data, loop current of the magnetic stirrer, and feed flow rates of liquid reactants and gaseous reactants of the gas-liquid two-phase continuous flow reactor, and the ideal liquid level, ideal pressure, and ideal loop current of the magnetic stirrer of the gas-liquid two-phase continuous flow reactor;
[0009] Based on the distribution of all liquid level data within a preset time period adjacent to the current moment, and the difference between the liquid level data and the ideal liquid level, a stable liquid level value of the reactor at the current moment is obtained;
[0010] Based on the liquid level stability value, combined with the degree of deviation of the liquid level data from the ideal liquid level, the degree of deviation of the pressure data from the ideal pressure, and the degree of deviation of the loop current from the ideal loop current, the liquid level deviation value of the reactor at the current moment is obtained;
[0011] Preset multiple parameter vectors of the PID control algorithm, based on the current pressure data, the feed flow rates of the liquid reactant and the gaseous reactant, and the average level of the liquid level data within the preset time period, and in combination with the parameters of the stirring paddle, the electrical parameters of the magnetic stirrer, and the viscosity and elastic coefficient of the gas-liquid two-phase mixed reactant, model the flow field of the gas-liquid two-phase mixed reactant and the magnetic stirrer, evaluate the control effect of each parameter vector based on the obtained model, and obtain the fitness of each parameter vector;
[0012] Iteratively obtaining an optimal parameter vector at a current moment based on the multiple parameter vectors using an intelligent optimization algorithm, wherein a convergence factor adjustment rate at each iteration is obtained based on the closeness between the fitness of the parameter vectors at each iteration and the distance between the parameter vectors;
[0013] Based on the convergence factor adjustment rate at each iteration and the preset minimum convergence factor, the convergence factor at each iteration is obtained;
[0014] The optimal parameter vector is used in combination with a PID control algorithm to control the liquid level of a gas-liquid two-phase continuous flow reactor.
[0015] In one embodiment, the process of obtaining the liquid level stability value is as follows:
[0016] The discrete degree of each liquid level data and its multiple neighboring liquid level data is recorded as the neighboring discrete degree of each liquid level data;
[0017] All liquid level data within a preset time period adjacent to the current moment are combined into a liquid level data sequence, and the liquid level data sequence is equally divided into a preset number of subsequences;
[0018] The expression of the liquid level stability value of the reactor at the current moment is:
[0019] Where S represents the liquid level stability value of the reactor at the current moment; exp() represents the exponential function with a natural constant as the base; C represents the sum of the nearest discrete degrees of all liquid level data in the liquid level data sequence; L represents the number of subsequences; σ i 、 They represent the discrete degree and mean value of all liquid level data in the i-th subsequence respectively; h0 represents the ideal liquid level of the reactor.
[0020] In one embodiment, the process of obtaining the liquid level deviation value is as follows:
[0021] The difference between the liquid level data and the ideal liquid level, the difference between the pressure data and the ideal pressure, and the difference between the loop current and the ideal loop current are used to form a liquid level deviation vector;
[0022] The expression of the liquid level deviation value of the reactor at the current moment is:
[0023] Where E represents the liquid level deviation value of the reactor at the current moment; A represents the modulus of the liquid level deviation vector at the current moment; S represents the liquid level stability value of the reactor at the current moment; and f represents the difference between the liquid level data at the current moment and the ideal liquid level.
[0024] In one embodiment, the method for obtaining the fitness is: based on the obtained model, the liquid level deviation value under the control of each parameter vector is obtained, and the time of the liquid level deviation value under the control of each parameter vector is multiplied by the calculation result of the absolute error integral index as the fitness of each parameter vector.
[0025] In one embodiment, the expression of the convergence factor adjustment rate is:
[0026] Where R j Indicates the convergence factor adjustment rate at the jth iteration; norm() indicates the normalization operation; F j,min represents the minimum value of the fitness of all parameter vectors at the jth iteration; W represents the number of parameter vectors in the population of the particle swarm algorithm; D j,w F represents the distance between the wth parameter vector and the parameter vector with the minimum fitness at the jth iteration; j,w represents the fitness of the wth parameter vector at the jth iteration; ε represents a preset value greater than 0.
[0027] In one embodiment, the process of obtaining the convergence factor is as follows:
[0028] Calculating the product of the convergence factor adjustment rate and the preset convergence factor adjustment value at each iteration;
[0029] The convergence factor is the sum of the product and a preset minimum convergence factor.
[0030] In one embodiment, the method for controlling the liquid level of a gas-liquid two-phase continuous flow reactor is as follows: the three components in the optimal parameter vector are used as the proportional parameter, integral parameter and differential parameter of a PID control algorithm, respectively; the liquid level deviation value of the reactor at the current moment is used as the input of the PID control algorithm; the opening of the valve of the liquid reactant feed port is output to control the liquid level of the gas-liquid two-phase continuous flow reactor.
[0031] In one embodiment, the method for controlling the feed flow rate of the gaseous reactant while controlling the liquid level of the gas-liquid two-phase continuous flow reactor is:
[0032] Based on the feed flow rate of the liquid reactant at the current moment, the required flow rate of the gaseous reactant at the current moment is calculated, and the difference between the feed flow rate of the gaseous reactant at the current moment and the required flow rate is used as the input of the PID control algorithm. The opening of the valve of the gaseous reactant feed port is output to control the feed flow rate of the gaseous reactant.
[0033] This application has at least the following beneficial effects:
[0034] The gas-liquid two-phase continuous flow reactor of the present application combines a magnetic stirring reactor and a tubular reactor, successfully integrating the advantages of both. The use of magnetic stirring effectively solves the pressure resistance limitations and heat generation due to friction of traditional mechanical stirring. In addition, all parts of the gas-liquid two-phase continuous flow reactor that come into contact with the reactants are made of C276 Hastelloy alloy, making the gas-liquid two-phase continuous flow reactor corrosion-resistant and pressure-resistant.
[0035] Furthermore, in terms of liquid level control, we conducted an in-depth analysis of the mechanism by which the reactor stirring structure affects the degree of liquid level fluctuation. We fully utilized the correlation between the magnetic stirrer's loop current, the reactor's pressure data, and the liquid level to accurately obtain the liquid level deviation value and reduce the impact of the eddy current of the gas-liquid two-phase mixed reactants on the liquid level deviation estimation.
[0036] Furthermore, with the help of the model simulation platform and particle swarm algorithm, the control parameters of the PID control algorithm are determined more accurately. The liquid level deviation value is combined with the PID control algorithm to control the valve opening of the liquid reactant feed port, thereby improving the stability of the liquid level control of the reactor. BRIEF DESCRIPTION OF THE DRAWINGS
[0037] In order to more clearly illustrate the technical solutions and advantages of the embodiments of the present application or the prior art, the following is a brief introduction to the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0038] Figure 1 A structural diagram of a gas-liquid two-phase continuous flow reactor provided in one embodiment of the present application;
[0039] Figure 2 A flow chart showing the steps of a liquid level control method for a gas-liquid two-phase continuous flow reactor provided in one embodiment of the present application;
[0040] Figure 3 This is a control flow chart of the electric proportional control valve for the liquid reactant feed port;
[0041] Figure 4 This is the control flow chart of the electric proportional control valve at the gaseous reactant feed port. DETAILED DESCRIPTION
[0042] In the description of the embodiments of this application, words such as "exemplary," "or," and "for example" are used to indicate examples, illustrations, or descriptions. Any embodiment or design described as "exemplary" or "for example" in the embodiments of this application should not be construed as being preferred or advantageous over other embodiments or designs. Rather, the use of words such as "exemplary," "or," and "for example" is intended to present the relevant concepts in a concrete manner.
[0043] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those skilled in the art to which this application relates. The terms used in this application are for the purpose of describing specific embodiments only and are not intended to limit this application. It should be understood that, unless otherwise indicated, " / " represents or.
[0044] It should also be noted that the terms "first" and "second" in this application are used to distinguish similar objects, rather than to describe a specific order or sequence.
[0045] The structure of a gas-liquid two-phase continuous flow reactor provided by the present application is described in detail below with reference to the accompanying drawings.
[0046] See also Figure 1 , which shows a structural diagram of a gas-liquid two-phase continuous flow reactor provided by one embodiment of the present application, Figure 1The names of the various components of the gas-liquid two-phase continuous flow reactor are: 1. Coil, 2. Tank head, 3. Tank cylinder, 4. Flange, 5. Magnetic stirrer; the names of the various pipe openings of the gas-liquid two-phase continuous flow reactor are: a. discharge port, b. medium inlet, c. medium outlet, d. liquid reactant feed port, e. gaseous reactant feed port, f. stirring port, where the nominal size of the discharge port Φ12 means the nominal diameter of the pipe is 12 mm, the nominal size of the medium inlet Φ22×3.5 means the nominal diameter of the pipe is 22 mm and the wall thickness is 3.5 mm. The specific size information of the gas-liquid two-phase continuous flow reactor is as follows: Figure 1 As shown, this application will not be repeated.
[0047] The gas-liquid two-phase continuous flow reactor is a novel continuous flow reaction device that combines a magnetic stirring reactor with a tubular reactor. It combines the advantages of both reactor types. Magnetic stirring solves the pressure resistance issues and frictional heat generation associated with mechanical stirring. Furthermore, all parts of the gas-liquid two-phase continuous flow reactor that come into contact with the reactants are made of corrosion-resistant and pressure-resistant C276 Hastelloy. Furthermore, the right-hand coil is raised to the ideal liquid level in the reactor, ensuring that the mixed reactant level at the stirring paddle remains near the ideal level when sufficient reactant feed is present.
[0048] The gas-liquid two-phase continuous flow reactor has six layers of stirring paddles, of which the two layers above the feed port are push-down type, and the four layers below the feed port are push-up type. Under the high-speed stirring of the magnetic stirrer, the gaseous reactants and liquid reactants are rapidly dispersed and fully mixed in the reaction chamber. The mixed reactants then enter the tubular reactor, which contains a special static mixer to mix the reactants again. After the reaction is complete, the material is discharged at the discharge port to complete the gas-liquid two-phase reaction. The mixed reactants of liquid reactants and gaseous reactants during the reaction process are called gas-liquid two-phase mixed reactants.
[0049] To achieve stable liquid level control within the reactor and high-purity reaction products, it is necessary to perform different PID controls on the feed valves for the liquid reactants and the gaseous reactants. The liquid level within the reactor is primarily affected by the feed flow rate of the liquid reactants. This application achieves stable liquid level control by controlling the feed valves for the liquid reactants, and ensures that the gaseous reactants enter in equal proportions by controlling the feed valves for the gaseous reactants, thereby improving the purity of the reaction products.
[0050] The specific scheme of the liquid level control method of a gas-liquid two-phase continuous flow reactor provided by the present application is described in detail below with reference to the accompanying drawings.
[0051] like Figure 2, which shows a flow chart of the steps of a liquid level control method for a gas-liquid two-phase continuous flow reactor provided by one embodiment of the present application, the method comprising the following steps:
[0052] Step S1, real-time acquisition of liquid level data, pressure data, loop current of the magnetic stirrer, and feed flow rates of liquid reactants and gaseous reactants of the gas-liquid two-phase continuous flow reactor, and the ideal liquid level, ideal pressure, and ideal loop current of the magnetic stirrer of the gas-liquid two-phase continuous flow reactor.
[0053] A liquid level sensor is installed on the side wall of the gas-liquid two-phase continuous flow reactor to obtain the liquid level data of the gas-liquid two-phase continuous flow reactor in real time; a pressure sensor is installed on the side wall of the gas-liquid two-phase continuous flow reactor to obtain the pressure data of the gas-liquid two-phase continuous flow reactor in real time; a flow meter is installed at the liquid reactant feed port of the gas-liquid two-phase continuous flow reactor to obtain the feed flow rate of the liquid reactant of the gas-liquid two-phase continuous flow reactor in real time; a gas flow meter is installed at the gaseous reactant feed port of the gas-liquid two-phase continuous flow reactor to obtain the feed flow rate of the gaseous reactant of the gas-liquid two-phase continuous flow reactor in real time; a current sensor is installed on the power supply circuit of the magnetic stirrer to obtain the loop current of the magnetic stirrer in real time.
[0054] In this embodiment, the collection frequency of liquid level data, pressure data, loop current, feed flow rate of liquid reactants and feed flow rate of gaseous reactants is once every 3 seconds. The value of the collection frequency is preset manually and can be set by the implementer. This application does not impose any special restrictions.
[0055] Ideally, the liquid level in the reactor should be at the feed inlet, allowing for thorough mixing of the gaseous and liquid reactants. Simultaneously, due to the action of the upward and downward push-type agitators, the liquid level in the reactor fluctuates minimally. Therefore, the liquid level in the reactor at the feed inlet is taken as the ideal liquid level. The pressure in the reactor at this ideal liquid level is taken as the ideal pressure, and the magnetic stirrer circuit current at this ideal liquid level is taken as the ideal circuit current.
[0056] Step S2: Based on the distribution of all liquid level data within a preset time period adjacent to the current moment, and the difference between the liquid level data and the ideal liquid level, a stable liquid level value of the reactor at the current moment is obtained.
[0057] Due to the unique stirring structure of the gas-liquid two-phase continuous flow reactor, when the liquid level is higher than the ideal level, it exceeds the gaseous reactant feed port, causing the mixed reactants to flood. Bubbles rise and break up under the shear action of the agitator, gradually dispersing and disturbing the liquid surface, causing an increase in small, instantaneous fluctuations in the liquid level data. The degree of dispersion of each liquid level data point and its multiple adjacent levels is recorded as the nearest neighbor dispersion degree of each liquid level data point, which is used to reflect the instantaneous fluctuations in the liquid level data.
[0058] In this embodiment, the number of neighboring moments is 4. The number of neighboring moments can be set by the implementer and is not particularly limited in this application.
[0059] In this embodiment, the degree of discreteness of each liquid level data and its multiple neighboring liquid level data is the coefficient of variation. As other implementation methods, on the basis of being able to measure the uneven distribution of liquid level data, the implementer can use other existing technologies for measurement, such as variance, standard deviation, etc., and this application does not impose any special restrictions.
[0060] When the liquid level in the reactor is lower than the ideal liquid level, the liquid level data fluctuates greatly over a longer time scale due to the effect of the push-up stirring paddle. All liquid level data within the preset time period adjacent to the current moment are arranged according to the data size to form a liquid level data sequence, and the liquid level data sequence is divided into a preset number of subsequences. Due to the effect of multiple stirring paddles in the reactor, the lower the liquid level, the greater the fluctuation amplitude of the obtained liquid level data, and the greater the difference between the average value of the liquid level data in each subsequence and the ideal liquid level. In addition, considering the aggravating effect of gaseous reactants on the fluctuation of liquid level in local areas in gas-liquid two-phase reactions, the lower the liquid level, the stronger the degree of liquid level fluctuation, and the greater the discreteness of all liquid level data in each subsequence.
[0061] In this embodiment, all liquid level data within a preset time period adjacent to the current moment are arranged in ascending order to form a liquid level data sequence.
[0062] In another embodiment, all liquid level data within a preset time period adjacent to the current moment are arranged in descending order to form a liquid level data sequence.
[0063] In this embodiment, the preset time period is before the current moment, the length of the preset time period is 2 minutes, and the value of the preset number is 4. The length of the preset time period and the value of the preset number are both preset manually, and the implementer can set them by himself. This application does not impose any special restrictions.
[0064] In this embodiment, the degree of dispersion of all liquid level data in each subsequence is the coefficient of variation. As other implementation methods, on the basis of being able to measure the degree of uneven distribution of liquid level data in each subsequence, the implementer may adopt other existing technologies for measurement, such as variance, standard deviation, etc., and this application does not impose any special restrictions.
[0065] Based on the discrete degree of the neighbor of each liquid level data in the liquid level data sequence, the discrete degree of all liquid level data in each subsequence, and the difference between each liquid level data in each subsequence and the ideal liquid level, the liquid level stability value of the reactor at the current moment is obtained. The expression is:
[0066] Where S represents the liquid level stability value of the reactor at the current moment; exp() represents the exponential function with natural constant as the base, which is used to convert Mapped to a positive number; C represents the sum of the discrete degrees of the neighbors of all liquid level data in the liquid level data sequence, reflecting the small fluctuations of the liquid level data; L represents the number of subsequences; σ i 、 They represent the discrete degree and mean value of all liquid level data in the i-th subsequence respectively; h0 represents the ideal liquid level of the reactor.
[0067] It should be noted that the more minute instantaneous fluctuations in the liquid level data, the greater the sum of the nearest neighbor discreteness of all liquid level data within the liquid level data sequence, and the smaller the obtained liquid level stability value; the more the mean of all liquid level data within each subsequence deviates from the ideal liquid level, the greater the amplitude of the liquid level fluctuation caused by the action of the stirring paddle, and the more aggravated the fluctuation caused by the influence of gaseous reactants, and the smaller the obtained liquid level stability value. By analyzing the impact of the reactor's stirring structure on the degree of liquid level fluctuation, the degree of deviation of the liquid level in the reactor from the ideal liquid level is reflected, the impact of large errors in individual liquid level data is reduced, the accuracy of subsequent estimation of the current liquid level deviation is improved, and the liquid level control effect is improved.
[0068] Step S3, based on the liquid level stability value, combined with the degree of deviation of the liquid level data from the ideal liquid level, the degree of deviation of the pressure data from the ideal pressure, and the degree of deviation of the loop current from the ideal loop current, obtain the liquid level deviation value of the reactor at the current moment.
[0069] Due to the stirring action of the magnetic stirrer in a gas-liquid two-phase continuous flow reactor and the vigorous flow of the reactants in the gas-liquid two-phase state, the liquid level in the reactor fluctuates greatly, and there is a large error between the acquired liquid level data and the actual liquid level in the reactor. The magnetic stirrer uses feedback control to maintain a constant stirring blade speed. The higher the liquid level, the greater the resistance to the stirring blade, and the corresponding loop current of the magnetic stirrer increases. Therefore, the loop current can be used as a feedback control factor for the reactor liquid level. In addition, in a gas-liquid two-phase reaction, gaseous reactants and liquid reactants enter the reactor in proportion. The lower the liquid level, the less liquid reactant there is, and the corresponding gas reactant is less. At the same time, the gas volume in the reactor increases, and the pressure in the reactor decreases. Therefore, the pressure data can be used as a feedback control factor for the reactor liquid level.
[0070] The difference between the liquid level data and the ideal liquid level is recorded as the liquid level data difference, the difference between the pressure data and the ideal pressure is recorded as the pressure data difference, and the difference between the loop current and the ideal loop current is recorded as the loop current difference. The liquid level data difference, pressure data difference, and loop current difference are used as components to construct a liquid level deviation vector to reflect the deviation between the liquid level in the reactor and the ideal liquid level.
[0071] Based on the above analysis, according to the correlation between the loop current of the magnetic stirrer, the pressure data of the reactor and the liquid level data, the deviation between the actual liquid level and the ideal liquid level is analyzed, and the influence of the eddy current of the mixed reactants on the liquid level deviation estimation is reduced, so as to improve the accuracy of the liquid level deviation estimation and thus improve the accuracy of the subsequent liquid level control.
[0072] Based on the liquid level stability value of the reactor and the liquid level deviation vector at the current moment, the liquid level deviation value of the reactor at the current moment is obtained. The expression is:
[0073] Where E represents the current reactor level deviation; A represents the modulus of the current level deviation vector; S represents the current reactor level stability; and f represents the difference between the current level data and the ideal level. Maintaining the positive and negative values of the level deviation and the level data difference is crucial to ensure that the reactor maintains the ideal level during subsequent level control.
[0074] It should be noted that the liquid level stability value reflects the degree of fluctuation of the current liquid level, and also reflects the gap between the liquid level and the ideal liquid level. The smaller the liquid level stability value, the greater the gap between the liquid level in the reactor and the ideal liquid level; the larger the modulus of the liquid level deviation vector, the greater the deviation of the liquid level in the reactor reflected by the liquid level data, pressure data of the reactor at the current moment and the loop current of the magnetic stirrer.
[0075] Step S4, preset multiple parameter vectors of the PID control algorithm, based on the current pressure data, the feed flow rate of the liquid reactant and the gaseous reactant, and the average level of the liquid level data within the preset time period, and combined with the parameters of the stirring paddle, the electrical parameters of the magnetic stirrer, the viscosity and elastic coefficient of the gas-liquid two-phase mixed reactant, the flow field of the gas-liquid two-phase mixed reactant and the magnetic stirrer are modeled, and the control effect of each parameter vector is evaluated based on the obtained model to obtain the fitness of each parameter vector.
[0076] This example uses a PID control algorithm to control the valve opening of the liquid reactant feed port, thereby stabilizing the liquid level in the reactor at the desired level. Three random numbers are randomly selected W times within the open interval (0, 100). Each of these three random numbers is used as the proportional, integral, and differential parameters of the PID control algorithm, forming W parameter vectors. The liquid level deviation is used as the input to the PID control algorithm, which outputs the valve opening of the liquid reactant feed port.
[0077] In this embodiment, the value of W is 30. The value of W is preset manually and can be set by the implementer. This application does not impose any special restrictions.
[0078] Considering the complex changes in the flow field of the gas-liquid two-phase mixed reactant due to changes in the reactant flow rate, a particle swarm optimization algorithm was used to tune the control parameters of the PID control algorithm. W parameter vectors were used as the initial population of the particle swarm optimization algorithm. To evaluate the control effect of any parameter vector on the reactor liquid level, a model simulation platform was used to model the flow field of the gas-liquid two-phase mixed reactant in the reactor and the magnetic stirrer. The specific process is as follows:
[0079] The mean of all liquid level data in the liquid level data sequence is used as the reference liquid level of the reactor at the current moment. Based on the current reference liquid level, pressure data, feed flow rate of liquid reactants, feed flow rate of gaseous reactants, parameters of the stirring paddle in the reactor, and viscosity and elastic coefficient of the gas-liquid two-phase mixed reactant, a VOF (Volume of Fluid) model is used as the flow field model of the gas-liquid two-phase mixed reactant. The flow field of the gas-liquid two-phase mixed reactant in the reactor is simulated using Ansys-Fluent software, and liquid level data, pressure data, and fluid resistance experienced by the stirring paddle are output. When simulating the flow field of the gas-liquid two-phase mixed reactant in the reactor, a delayed detached eddy simulation (DDES) model is used as the turbulence model, and a hexahedral grid is used as the grid unit. The specific establishment process of the VOF model and the DDES model is well known to those skilled in the art and will not be described in detail in this application. The method for obtaining the viscosity and elastic coefficient of the gas-liquid two-phase mixed reactant is well known in the art and will not be described in detail in this application. The parameters of the stirring paddle include: blade diameter, blade angle, and layer spacing of the stirring paddle.
[0080] According to the fluid resistance exerted on the stirring paddle and the electrical parameters of the magnetic stirrer, Simulink is used to build an electrical simulation model of the magnetic stirrer, and the loop current of the magnetic stirrer is output. The specific process of establishing the electrical simulation model is a well-known technology for those skilled in the art and will not be described in detail in this application. The electrical parameters of the magnetic stirrer include: the number of motor poles, slip rate and electrical time constant of the magnetic stirrer.
[0081] A step response test is performed on the flow field model and electrical simulation model of the gas-liquid two-phase mixed reactant, and the liquid level data, pressure data and loop current under the step response test are obtained. The liquid level deviation value under the control of any of the parameter vectors is calculated, and then the calculation result of the time multiplication of the integral of absolute error (ITAE) of the liquid level deviation value is obtained. The calculation result is used as the fitness of the any of the parameter vectors, reflecting the control effect of the any of the parameter vectors on the liquid level in the reactor.
[0082] Step S5, based on the multiple parameter vectors, an intelligent optimization algorithm is used to iteratively obtain the optimal parameter vector at the current moment, wherein the convergence factor adjustment rate at each iteration is obtained based on the degree of closeness between the fitness of the parameter vectors at each iteration, and the distance between the parameter vectors; based on the convergence factor adjustment rate at each iteration, combined with a preset minimum convergence factor, the convergence factor at each iteration is obtained.
[0083] Based on the closeness between the fitness of the parameter vectors at each iteration and the distance between the parameter vectors, the convergence factor adjustment rate at each iteration is obtained, and the expression is:
[0084] Where R j Indicates the convergence factor adjustment rate at the jth iteration; norm() indicates the normalization operation; F j,min represents the minimum value of the fitness of all parameter vectors at the jth iteration; W represents the number of parameter vectors in the population of the particle swarm algorithm; D j,w F represents the distance between the wth parameter vector and the parameter vector with the minimum fitness at the jth iteration; j,w represents the fitness of the wth parameter vector at the jth iteration; ε represents a value preset greater than 0 to prevent the denominator from being 0. The value of ε is manually preset and can be set by the implementer. In this embodiment, the value of ε is 0.01. In this embodiment, the inverse tangent normalization function is used for normalization.
[0085] In this embodiment, the distance between the parameter vectors is the Euclidean distance. As other implementation methods, on the basis of being able to measure the distance between the parameter vectors, the implementer may adopt other existing technologies for measurement, such as Manhattan distance, cosine distance, etc., and this application does not impose any special restrictions.
[0086] Furthermore, based on the convergence factor adjustment rate at each iteration and the preset minimum convergence factor, the convergence factor at each iteration is obtained, and the expression is:
[0087] Where, represents the convergence factor at the jth iteration; represents the preset minimum convergence factor; δ represents the preset convergence factor adjustment value; R j Indicates the convergence factor adjustment rate at the jth iteration. In the particle swarm algorithm, the two learning factors have the same value, and the sum of the two learning factors is equal to the convergence factor.
[0088] Since a convergence factor that is too small will limit the update speed of the parameter vector, the movement range of the parameter vector in the search space will be reduced, resulting in a decrease in the global search ability of the algorithm and an inability to explore a better solution space, the value of the preset minimum convergence factor should not be too small. In this embodiment, the value of the preset minimum convergence factor is 4; when the convergence factor changes too much, it may cause the speed update amplitude of the parameter vector to be too large, thereby causing the parameter vector to move too fast in the search space, which may easily cause the parameter vector to pass the optimal solution and reduce the search accuracy of the algorithm. When the convergence factor changes too little, it may cause the speed update amplitude of the parameter vector to be too small, thereby causing the parameter vector to move too slowly in the search space and reduce the search efficiency of the algorithm. Therefore, the value of the preset convergence factor adjustment value should not be too large or too small. In this embodiment, the value of the preset convergence factor adjustment value is 4; the values of the preset minimum convergence factor and the preset convergence factor adjustment value are both preset manually, and the implementer can set them according to actual conditions. This application does not impose any special restrictions.
[0089] In this embodiment, the maximum number of iterations of the particle swarm algorithm is 100. The maximum number of iterations of the particle swarm algorithm is preset manually and can be set by the implementer. This application does not impose any special restrictions.
[0090] It should be noted that: the larger the liquid level deviation value at the current moment, the greater the gap between the liquid level in the reactor and the ideal liquid level, the greater the adjustment degree of the valve, the greater the influence of the flow field of the gas-liquid two-phase mixed reactant on the reactant flow rate, and the greater the difficulty in finding the optimal parameter vector. The convergence factor is used to reflect the optimization range at each iteration. Therefore, a larger convergence factor is set at the current moment to expand the optimization range and obtain a more accurate liquid level control effect. At the jth iteration, the larger the minimum value of the fitness of all parameter vectors in the population of the particle swarm algorithm, the worse the control effect of the parameter vector at the jth iteration, the need to expand the optimization range and set a larger convergence factor. In order to prevent the particle swarm algorithm from falling into the local optimum, the distance D between the remaining parameter vectors in the population and the parameter vector with the minimum fitness at the jth iteration is set. j,w The larger the fitness difference F j,w ―F j,min The smaller it is, the larger the convergence factor should be set.
[0091] The process of using the particle swarm algorithm to obtain the optimal parameter vector at the current moment is: taking the initial population as the input of the particle swarm algorithm, and outputting the optimal parameter vector based on the calculated convergence factor and fitness.
[0092] Step S6: Using the optimal parameter vector in combination with a PID control algorithm, the liquid level of the gas-liquid two-phase continuous flow reactor is controlled.
[0093] The three components of the optimal parameter vector are used as the proportional parameter, integral parameter and differential parameter of the PID control algorithm in sequence. The liquid level deviation value of the reactor at the current moment is used as the input of the PID control algorithm. The opening of the electric proportional control valve at the liquid reactant feed port is output to achieve stable control of the liquid level of the gas-liquid two-phase continuous flow reactor.
[0094] Figure 3 This is the control flow chart of the electric proportional control valve for the liquid reactant feed port. Figure 3 Where h0 represents the ideal liquid level of the reactor, p0 and i0 represent the ideal pressure in the reactor and the ideal loop current of the magnetic stirrer respectively, p and h represent the pressure data and liquid level data of the reactor at the current moment respectively, i represents the loop current of the magnetic stirrer at the current moment, E represents the liquid level deviation value of the reactor at the current moment; u1 represents the opening of the electric proportional control valve at the liquid reactant feed port at the current moment.
[0095] To ensure the purity of the reaction product, liquid reactants and gaseous reactants need to be delivered to the reactor in proportion. The purity of the reaction product is ensured by controlling the feed valve of the gaseous reactant. The specific process of PID control of the feed valve of the gaseous reactant is as follows:
[0096] The required flow rate of the gaseous reactant at the current moment is calculated based on the feed flow rate of the liquid reactant, the density and molar mass of the liquid reactant, and the density and molar mass of the gaseous reactant. The specific method for calculating the required flow rate of the gaseous reactant is a well-known technology for those skilled in the art and will not be repeated in this application.
[0097] The difference between the flow rate of the gaseous reactant at the current moment and the required flow rate is used as the input of the PID control algorithm, and the opening of the electric proportional control valve of the gaseous reactant feed port is output. Among them, for the PID control algorithm used to control the electric proportional control valve of the gaseous reactant feed port, the control parameter adjustment method of the PID control algorithm is the trial and error method. The trial and error method is a well-known technology and will not be repeated in this application. Figure 4 This is the control flow chart of the electric proportional control valve for the gaseous reactant feed port. Figure 4 Where q0 represents the required flow rate of the gaseous reactant at the current moment, q represents the feed flow rate of the gaseous reactant at the current moment, e represents the difference between the feed flow rate of the gaseous reactant at the current moment and the required flow rate, which is calculated as e=q-q0, and u2 represents the opening of the electric proportional control valve at the gaseous reactant feed port at the current moment.
[0098] In summary, the gas-liquid two-phase continuous flow reactor of the present application combines a magnetic stirring reactor and a tubular reactor, successfully integrating the advantages of both. The use of magnetic stirring effectively solves the pressure resistance limitations and heat generation due to friction of traditional mechanical stirring. In addition, all parts in contact with the reactants in the gas-liquid two-phase continuous flow reactor are made of C276 Hastelloy alloy, which makes the gas-liquid two-phase continuous flow reactor corrosion-resistant and pressure-resistant.
[0099] Furthermore, in terms of liquid level control, we conducted an in-depth analysis of the mechanism by which the reactor stirring structure affects the degree of liquid level fluctuation. We fully utilized the correlation between the magnetic stirrer's loop current, the reactor's pressure data, and the liquid level to accurately obtain the liquid level deviation value and reduce the impact of the eddy current of the gas-liquid two-phase mixed reactants on the liquid level deviation estimation.
[0100] Furthermore, with the help of the model simulation platform and particle swarm algorithm, the control parameters of the PID control algorithm are determined more accurately. The liquid level deviation value is combined with the PID control algorithm to control the valve opening of the liquid reactant feed port, thereby improving the stability of the liquid level control of the reactor.
[0101] The flowcharts and block diagrams in the accompanying drawings show the possible implementation architectures, functions and operations of the systems, methods and computer program products according to the embodiments of the present disclosure. In this regard, each box in the flowchart or block diagram can represent a module, program segment or part of the code, and the module, program segment or part of the code contains one or more executable instructions for implementing the specified logical functions. In some alternative implementations, the functions marked in the box can also occur in an order different from that marked in the accompanying drawings. For example, two consecutive boxes can actually be executed substantially in parallel, or they can sometimes be executed in the opposite order, which can depend on the functions involved. In the descriptions corresponding to the flowcharts and block diagrams in the accompanying drawings, the operations or steps corresponding to different boxes can also occur in an order different from that disclosed in the description, and sometimes there is no specific order between different operations or steps. For example, two consecutive operations or steps can actually be executed substantially in parallel, or they can sometimes be executed in the opposite order, which can depend on the functions involved. Each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, may be implemented by a dedicated hardware-based system that performs the specified function or action, or may be implemented by a combination of dedicated hardware and computer instructions.
[0102] It is obvious to those skilled in the art that the present application is not limited to the details of the above exemplary embodiments, and that the present application can be implemented in other specific forms without departing from the basic characteristics of the present application. Therefore, from all perspectives, the above embodiments of the present application should be regarded as exemplary and non-restrictive.
Claims
1. A liquid level control method for a gas-liquid two-phase continuous flow reactor, characterized in that: The method comprises the following steps: The gas-liquid two-phase continuous flow reactor includes a magnetic stirrer and multi-layer stirring paddles; the reactants of the gas-liquid two-phase continuous flow reactor include liquid reactants and gaseous reactants, wherein the mixed reactants of the liquid reactants and the gaseous reactants during the reaction process are referred to as gas-liquid two-phase mixed reactants; the liquid level data, pressure data, loop current of the magnetic stirrer, and feed flow rates of the liquid reactants and the gaseous reactants of the gas-liquid two-phase continuous flow reactor are obtained in real time, and the ideal liquid level, ideal pressure, and ideal loop current of the magnetic stirrer of the gas-liquid two-phase continuous flow reactor are obtained; Based on the distribution of all liquid level data within a preset time period adjacent to the current moment, and the difference between the liquid level data and the ideal liquid level, a stable liquid level value of the reactor at the current moment is obtained; Based on the liquid level stability value, combined with the degree of deviation of the liquid level data from the ideal liquid level, the degree of deviation of the pressure data from the ideal pressure, and the degree of deviation of the loop current from the ideal loop current, the liquid level deviation value of the reactor at the current moment is obtained; Preset multiple parameter vectors of the PID control algorithm, based on the current pressure data, the feed flow rates of the liquid reactant and the gaseous reactant, and the average level of the liquid level data within the preset time period, and in combination with the parameters of the stirring paddle, the electrical parameters of the magnetic stirrer, and the viscosity and elastic coefficient of the gas-liquid two-phase mixed reactant, model the flow field of the gas-liquid two-phase mixed reactant and the magnetic stirrer, evaluate the control effect of each parameter vector based on the obtained model, and obtain the fitness of each parameter vector; Iteratively obtaining an optimal parameter vector at a current moment based on the multiple parameter vectors using an intelligent optimization algorithm, wherein a convergence factor adjustment rate at each iteration is obtained based on the closeness between the fitness of the parameter vectors at each iteration and the distance between the parameter vectors; Based on the convergence factor adjustment rate at each iteration and the preset minimum convergence factor, the convergence factor at each iteration is obtained; The optimal parameter vector is used in combination with a PID control algorithm to control the liquid level of a gas-liquid two-phase continuous flow reactor.
2. The liquid level control method of a gas-liquid two-phase continuous flow reactor according to claim 1, characterized in that: The process of obtaining the liquid level stability value is as follows: The discrete degree of each liquid level data and its multiple neighboring liquid level data is recorded as the neighboring discrete degree of each liquid level data; All liquid level data within a preset time period adjacent to the current moment are combined into a liquid level data sequence, and the liquid level data sequence is equally divided into a preset number of subsequences; The expression of the liquid level stability value of the reactor at the current moment is: ; Where S represents the liquid level stability value of the reactor at the current moment; exp( ) represents the exponential function with the natural constant as the base; C represents the sum of the nearest discrete degrees of all liquid level data in the liquid level data sequence; L represents the number of subsequences; Respectively represent the discrete degree and mean value of all liquid level data in the i-th subsequence; Indicates the ideal liquid level of the reactor.
3. The liquid level control method of a gas-liquid two-phase continuous flow reactor according to claim 1, characterized in that: The process of obtaining the liquid level deviation value is as follows: The difference between the liquid level data and the ideal liquid level, the difference between the pressure data and the ideal pressure, and the difference between the loop current and the ideal loop current are used to form a liquid level deviation vector; The expression of the liquid level deviation value of the reactor at the current moment is: ; In the formula, E represents the liquid level deviation value of the reactor at the current moment; A represents the modulus of the liquid level deviation vector at the current moment; S represents the liquid level stability value of the reactor at the current moment; f represents the difference between the liquid level data at the current moment and the ideal liquid level.
4. The liquid level control method of a gas-liquid two-phase continuous flow reactor according to claim 1, characterized in that: The method for obtaining the fitness is: obtaining the liquid level deviation value under the control of each parameter vector based on the obtained model, and multiplying the time of the liquid level deviation value under the control of each parameter vector by the calculation result of the absolute error integral index as the fitness of each parameter vector.
5. The liquid level control method of a gas-liquid two-phase continuous flow reactor according to claim 1, characterized in that: The expression of the convergence factor adjustment rate is: Where, represents the convergence factor adjustment rate at the jth iteration; norm() represents the normalization operation; Represents the minimum value of the fitness of all parameter vectors at the jth iteration; W represents the number of parameter vectors in the population of the particle swarm algorithm; Represents the distance between the wth parameter vector and the parameter vector with the minimum fitness at the jth iteration; represents the fitness of the wth parameter vector at the jth iteration; ε indicates a preset value greater than 0.
6. The liquid level control method of a gas-liquid two-phase continuous flow reactor according to claim 1, characterized in that: The process of obtaining the convergence factor is as follows: Calculating the product of the convergence factor adjustment rate and the preset convergence factor adjustment value at each iteration; The convergence factor is the sum of the product and a preset minimum convergence factor.
7. The liquid level control method of a gas-liquid two-phase continuous flow reactor according to claim 1, characterized in that: The method for controlling the liquid level of the gas-liquid two-phase continuous flow reactor is as follows: the three components in the optimal parameter vector are used as the proportional parameter, integral parameter and differential parameter of the PID control algorithm, the liquid level deviation value of the reactor at the current moment is used as the input of the PID control algorithm, the opening of the valve of the liquid reactant feed port is output, and the liquid level of the gas-liquid two-phase continuous flow reactor is controlled.
8. The liquid level control method for a gas-liquid two-phase continuous flow reactor according to claim 1, characterized in that: The method for controlling the feed flow rate of the gaseous reactant while controlling the liquid level of the gas-liquid two-phase continuous flow reactor is: Based on the feed flow rate of the liquid reactant at the current moment, the required flow rate of the gaseous reactant at the current moment is calculated, and the difference between the feed flow rate of the gaseous reactant at the current moment and the required flow rate is used as the input of the PID control algorithm. The opening of the valve of the gaseous reactant feed port is output to control the feed flow rate of the gaseous reactant.
9. The liquid level control method of a gas-liquid two-phase continuous flow reactor according to claim 1, characterized in that: The gas-liquid two-phase continuous flow reactor is a new type of continuous flow reaction device that combines a magnetic stirring reactor and a tubular reactor. All parts in the gas-liquid two-phase continuous flow reactor that come into contact with reactants are made of C276 Hastelloy alloy. The stirring paddle on the upper side of the feed inlet in the gas-liquid two-phase continuous flow reactor is a push-down type, and the stirring paddle on the lower side of the feed inlet is an push-up type. There is a static mixer in the tubular reactor.
Citation Information
Patent Citations
Convertible batch / continuous reactor and use of the same
EP1889659A1