Direct drinking water purification system and dynamic regulation and control method
By acquiring influent water quality parameters and pre-membrane fouling index, and combining long short-term memory networks and near-end strategy optimization algorithms, the direct drinking water purification system is dynamically controlled, solving the problem of adapting to multiple water use scenarios and achieving precise control and long-term reliable use of the system.
Patent Information
- Application Number
- CN202511716820.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-21
- Publication Date
- 2026-02-24
AI Technical Summary
The existing control methods for direct drinking water purification systems fail to effectively adapt to multi-water usage scenarios, neglecting the synergistic pollution effects of influent water quality parameters and the performance degradation of nanofiltration membranes after long-term operation. This results in a disconnect between control parameters and the actual operating state of the membrane, decreased prediction accuracy, high operating costs, and rapid membrane wear.
By acquiring influent water quality parameters and pre-membrane fouling index, the fouling load index and historical performance degradation are calculated. Long short-term memory networks are used to predict membrane flux changes. The optimal action vector is constructed by combining a near-end strategy optimization algorithm to achieve dynamic control, meet membrane pressure difference constraints, and optimize energy consumption and membrane lifetime.
It enables precise control of the direct drinking water purification system under different water use scenarios, reduces operating energy consumption and nanofiltration membrane replacement and maintenance costs, and ensures the long-term stability and accuracy of the system.
Smart Images

Figure CN121554045A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of direct drinking water treatment technology, and in particular to a direct drinking water purification system and a dynamic control method. Background Technology
[0002] In direct drinking water purification systems, nanofiltration membranes have become the mainstream purification component due to their core advantages of precisely removing pollutants and retaining beneficial minerals. With the development of water treatment technology, system control methods have gradually evolved from traditional models to intelligent ones. Early systems primarily used fixed parameter control, pre-setting parameters such as the frequency of the variable frequency booster pump and the opening degree of the solenoid valve based on design conditions, without any dynamic adjustments. Later, feedback control based on real-time monitoring data was developed, using real-time acquisition of parameters such as membrane pressure difference and membrane flux to perform simple closed-loop adjustments to the control components. In recent years, machine learning technology has begun to be applied to membrane system control, with some solutions attempting to predict membrane flux changes using machine learning models, providing a reference for control and initially improving the foresight of the control process.
[0003] Although existing technologies have upgraded from fixed control to feedback control and then to predictive-assisted control, significant limitations still exist. Most existing solutions only focus on single parameters such as real-time membrane flux and membrane pressure difference, ignoring the synergistic pollution effects of influent water quality parameters and the cumulative effect of pollution load, as well as the impact of performance degradation of nanofiltration membranes after long-term operation on regulation, resulting in a disconnect between regulation parameters and the actual operating state of the membrane. At the same time, in-depth time-series analysis of historical water use data is not conducted, differentiated water use scenarios are not classified, and a uniform regulation strategy is adopted, which cannot take into account the water use needs under different scenarios.
[0004] The prediction model and control algorithm are independent of each other. The model parameters and algorithm configuration are not dynamically updated according to the actual operating deviation. After long-term operation, the prediction accuracy and control effect will gradually decrease due to factors such as membrane performance degradation and fluctuations in influent conditions. At the same time, the existing control focuses on a single objective and ignores the synergy between operating energy consumption control and nanofiltration membrane life protection, resulting in high system operating costs or excessively rapid membrane wear.
[0005] In view of the shortcomings of the existing technology, the technical problem to be solved by this application is how to adapt to multiple water use scenarios to achieve accurate adaptation and control and long-term reliable use of the direct drinking water purification system. Summary of the Invention
[0006] To address the shortcomings of existing technologies, this application provides a direct drinking water purification system and a dynamic control method.
[0007] In a first aspect, this application provides a dynamic control method for a direct drinking water purification system. The method includes: acquiring the inlet water quality parameters and the pre-membrane fouling index of the nanofiltration membrane inlet side at the inlet, calculating the current inlet fouling load index based on the inlet water quality parameters and the pre-membrane fouling index, and calculating the historical performance degradation based on the historical water production data of the nanofiltration membrane.
[0008] The pollution load index, historical performance degradation index, and pre-membrane fouling index are input into a long short-term memory network to predict the membrane flux change sequence. The time-series features of the membrane flux change sequence are extracted to form a membrane flux degradation risk index. Time-series analysis of historical water use data is performed to identify water use feature vectors.
[0009] The state vector is formed by combining the pollution load index, the decay risk index and the water use characteristic vector. The action vector is constructed by combining the target frequency of the variable frequency booster pump and the target opening degree of the control solenoid valve. The state vector is then processed based on the near-end strategy optimization algorithm to output the optimal action vector that satisfies the membrane pressure difference constraint.
[0010] The optimal action vector is simulated and verified in a simulation environment. When the stability of the produced water quality and the performance indicators of the nanofiltration membrane both meet the standards, control commands are generated and sent to the execution components. Simultaneously, simulation verification data is recorded periodically to optimize the near-end strategy optimization algorithm and the long short-term memory network.
[0011] As an optional implementation, the calculation of the current influent pollution load index includes:
[0012] The pollution types of influent water quality parameters are classified according to the nature of the pollution on nanofiltration membranes, and the corresponding pollution impact weights are determined according to the pollution intensity of the influent water quality parameters.
[0013] The synergistic pollution effects among influent water quality parameters corresponding to different pollution types are analyzed. The pollution contribution value is calculated based on the product of the influent water quality parameter and the corresponding pollution impact weight. The pollution contribution value is then adjusted according to the synergistic pollution effects to obtain the water quality pollution contribution.
[0014] The pre-membrane fouling index is correlated with the contribution to water pollution, and the contribution to water pollution is proportionally corrected based on the instantaneous fouling state of the nanofiltration membrane feed side reflected by the pre-membrane fouling index.
[0015] By combining historical pollution data of nanofiltration membranes, the cumulative effect adjustment is made to the proportionally corrected water pollution contribution, and the adjusted result represents the pollution load index of the current influent.
[0016] As an optional implementation, the predicted membrane flux change sequence includes:
[0017] The pollution load index, historical performance degradation rate and membrane pre-fouling index are converted into time series according to the time dimension. The time series includes the trend data of change within a preset historical time period.
[0018] The time series is input into the Long Short-Term Memory (LSTM) network. The parameter features in the trend data are extracted through the multiple hidden layers of the LSM network. The output of the LSM network is calibrated and constrained by combining the historical membrane flux data of the nanofiltration membrane in order to predict the membrane flux change sequence.
[0019] As an optional implementation, the risk index for the decline of membrane flux includes:
[0020] The membrane flux change sequence predicted by the Long Short-Term Memory Network is decomposed into time-series features including short-term and long-term fluctuation characteristics according to the time scale.
[0021] Extract the fluctuation amplitude of short-term fluctuation characteristics, adjust the risk weight of short-term fluctuation characteristics based on the correlation between fluctuation amplitude and pollution load index, and extract the decay rate of long-term fluctuation characteristics, adjust the risk weight of long-term fluctuation characteristics based on the coupling relationship between decay rate and historical performance decay.
[0022] Based on the time-series characteristics after adjusting the risk weights, the membrane flux decay stages are divided, and different decay stages are assigned to preset basic risk values.
[0023] By combining the pre-membrane fouling index with the baseline risk values of different decay stages, the baseline risk values of the modified baseline risk values are weighted and summed to form the membrane flux decay risk index.
[0024] As an optional implementation, the water use feature vector identification includes:
[0025] Time-series analysis of historical water use data is performed, and scenario types are clustered according to water use behavior patterns over time. Water use duration, peak water use, and water use rate are extracted for different scenarios to obtain water use behavior characteristics.
[0026] The coupling relationship between the temporal variation of water usage duration and membrane flux decay under different scenarios, as well as the temporal correlation between the occurrence time of water usage peak and the pollution load index, were analyzed and quantified into correlation characteristics.
[0027] The time-series mean of water usage rate under different scenarios is calculated and the historical average water production rate of nanofiltration membrane is compared to extract the matching characteristics of water demand and supply capacity under different scenarios.
[0028] Based on the pollution load index and the membrane flux decay risk index, the weights of water use behavior characteristics, correlation characteristics and matching characteristics under the corresponding scenarios are dynamically adjusted, and the weighted integration is used to form a water use feature vector.
[0029] As an optional implementation, the optimal action vector that satisfies the membrane pressure difference constraint includes:
[0030] The constraint threshold for membrane pressure difference is adjusted based on the pollution load index and decay risk index in the state vector.
[0031] An optimization function for a near-end strategy optimization algorithm is constructed based on permeate water quality, operating energy consumption, and nanofiltration membrane lifetime, and membrane pressure difference constraint is embedded as a penalty term into the optimization function;
[0032] The search partitions for action vectors are divided based on the scene type of water use feature vectors, and candidate action vectors with membrane pressure difference within the constraint threshold range are searched in different partitions.
[0033] The action vector with the optimal function value is selected from the candidate action vectors and used as the optimal action vector that satisfies the membrane pressure difference constraint.
[0034] As an optional implementation, the generation control instructions include:
[0035] The optimal action vector is simulated and verified in a simulation environment. Based on the pollution load index and membrane flux decay risk index in the state vector, the stability of the product water quality and the threshold for the performance indicators of the nanofiltration membrane are dynamically adjusted.
[0036] When the threshold for compliance is met, based on the scenario type of water use feature vector, the frequency of the variable frequency booster pump and the opening degree of the control solenoid valve in the optimal action vector are adapted to form control parameters for different scenarios.
[0037] By comparing the operational deviations between the simulation environment and the actual environment, the control parameters for different scenarios are corrected based on historical simulation verification data. The corrected control parameters are then encapsulated into control commands and sent to the execution components.
[0038] As an optional implementation, the optimized proximal strategy optimization algorithm includes:
[0039] The cumulative execution deviation is calculated based on regularly recorded simulation verification data, and the trigger threshold for algorithm optimization is dynamically set in combination with the pollution load index and the membrane flux decay risk index.
[0040] When the cumulative deviation reaches the trigger threshold, the target weight and search range parameters of the near-end strategy optimization algorithm are dynamically adjusted according to the water demand under different scenario types.
[0041] By combining the consistency between the membrane flux change sequence predicted by the Long Short-Term Memory Network and the actual membrane flux, the update step size of the proximal strategy optimization algorithm is calibrated in reverse.
[0042] As an optional implementation, optimizing the long short-term memory network includes:
[0043] When the cumulative deviation reaches the trigger threshold, the error weighting coefficient of the long short-term memory network is determined according to the water demand under different scenario types.
[0044] By combining the actual membrane pressure difference of the nanofiltration membrane with the prediction errors in historical simulation verification data, the effective prediction errors are screened according to the time decay coefficient, and the effective prediction errors are weighted according to the error weighting coefficient. The parameters of the long short-term memory network are corrected through error backpropagation.
[0045] The input weights of the Long Short-Term Memory network are corrected based on the action vector output by the optimized proximal policy optimization algorithm.
[0046] Secondly, this application provides a direct drinking water purification system, which includes: a water quality sensing module, a trend prediction module, a target optimization module, and an execution optimization module;
[0047] The water quality sensing module is used to acquire the influent water quality parameters at the inlet and the pre-membrane fouling index on the nanofiltration membrane inlet side. Based on the influent water quality parameters and the pre-membrane fouling index, it calculates the current influent fouling load index and calculates the historical performance degradation based on the historical water production data of the nanofiltration membrane.
[0048] The trend prediction module inputs the pollution load index, historical performance degradation degree, and pre-membrane fouling index into the long short-term memory network to predict the membrane flux change sequence, extracts the time-series features of the membrane flux change sequence to form the membrane flux degradation risk index, and performs time-series analysis on historical water use data to identify water use feature vectors.
[0049] The target optimization module combines the pollution load index, the decay risk index, and the water use characteristic vector to form a state vector, constructs an action vector by combining the target frequency of the variable frequency booster pump with the target opening degree of the control solenoid valve, and processes the state vector based on the near-end strategy optimization algorithm to output the optimal action vector that satisfies the membrane pressure difference constraint.
[0050] The execution optimization module is used to simulate and verify the optimal action vector in a simulation environment. When the stability of the produced water quality and the performance indicators of the nanofiltration membrane meet the standards, control commands are generated and sent to the execution components. Simulation verification data is recorded periodically to optimize the near-end strategy optimization algorithm and the long short-term memory network.
[0051] Compared with existing technologies, the beneficial effects of this application are as follows: by combining influent water quality parameters and pre-membrane fouling index to calculate the pollution load index, and extracting historical performance degradation based on historical permeate data, it comprehensively covers the dynamic characteristics of influent pollution and the long-term wear status of nanofiltration membranes, avoiding the one-sidedness of information caused by a single parameter, and providing accurate and comprehensive basic data support for subsequent regulation; by performing time-series analysis on historical water use data, it identifies water use characteristic vectors and classifies different scenarios, enabling regulation strategies to be specifically adapted to the water use needs of different scenarios, solving the problem that traditional unified regulation cannot adapt to complex operating conditions.
[0052] Based on the near-end strategy optimization algorithm, a state vector is constructed using the pollution load index, the decay risk index, and the water use characteristic vector. The product water quality, operating energy consumption, and nanofiltration membrane lifespan are incorporated into the optimization objectives. At the same time, membrane pressure difference constraints are embedded to avoid the unintended consequences of optimizing a single objective, achieving a triple balance of water quality compliance, controllable energy consumption, and extended membrane lifespan. By regularly recording simulation verification data, the near-end strategy optimization algorithm and long short-term memory network are dynamically optimized, enabling the system to adapt to long-term changes such as membrane performance decay and fluctuations in influent conditions. This avoids the control effect from decaying over time and ensures the stability and accuracy of the system's long-term operation.
[0053] By simulating and verifying the actual environment and correcting for deviations, the reliability of control commands is improved and abnormal fluctuations in operation are reduced. At the same time, precise regulation reduces ineffective energy consumption, extends the service life of nanofiltration membranes, and significantly reduces the long-term energy consumption cost of the system and the replacement and maintenance cost of nanofiltration membranes. Attached Figure Description
[0054] To more clearly illustrate the technical solutions of the embodiments of this application, the drawings used in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort. Wherein:
[0055] Figure 1 A flowchart illustrating a dynamic control method for a direct drinking water purification system provided in this application embodiment;
[0056] Figure 2 A flowchart illustrating the attenuation risk index of membrane flux in a dynamic control method for a direct drinking water purification system provided in this application embodiment;
[0057] Figure 3 The flowchart shows the logic of the optimal action vector that satisfies the membrane pressure difference constraint in the dynamic control method of a direct drinking water purification system provided in this application embodiment. Detailed Implementation
[0058] To make the objectives, technical solutions, and advantages of the embodiments of this application more apparent and understandable, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments.
[0059] Example 1
[0060] like Figure 1 The diagram shown is a flowchart of a dynamic control method for a direct drinking water purification system according to an embodiment of this application. The method includes:
[0061] S1. Obtain the influent water quality parameters at the inlet and the pre-membrane fouling index on the nanofiltration membrane inlet side. Calculate the current influent fouling load index based on the influent water quality parameters and the pre-membrane fouling index, and calculate the historical performance degradation based on the historical permeate data of the nanofiltration membrane.
[0062] Specifically, calculating the current pollution load index of the influent includes:
[0063] The pollution types of influent water quality parameters are classified according to the nature of the pollution on nanofiltration membranes, and the corresponding pollution impact weights are determined according to the pollution intensity of the influent water quality parameters.
[0064] The synergistic pollution effects among influent water quality parameters corresponding to different pollution types are analyzed. The pollution contribution value is calculated based on the product of the influent water quality parameter and the corresponding pollution impact weight. The pollution contribution value is then adjusted according to the synergistic pollution effects to obtain the water quality pollution contribution.
[0065] The pre-membrane fouling index is correlated with the contribution to water pollution, and the contribution to water pollution is proportionally corrected based on the instantaneous fouling state of the nanofiltration membrane feed side reflected by the pre-membrane fouling index.
[0066] By combining historical pollution data of nanofiltration membranes, the cumulative effect adjustment is made to the proportionally corrected water pollution contribution, and the adjusted result represents the pollution load index of the current influent.
[0067] Before calculation, the influent water quality parameters must first be classified according to the nature of the pollutants' impact on the nanofiltration membrane. This is because the influent contains a variety of pollutants, some of which can clog membrane pores, some can be adsorbed onto the membrane surface, and others can chemically react with the membrane material. Different mechanisms of action have significantly different effects on membrane performance, and without classification, it is difficult to accurately measure the pollution contribution of each pollutant. Specifically, the influent water quality parameters can be divided into colloidal pollutants, organic pollutants, and inorganic pollutants. Colloidal pollutants include suspended microparticles and colloidal substances in the water, organic pollutants include natural organic matter and artificially synthesized organic matter, and inorganic pollutants include metal ions such as calcium, magnesium, and iron, as well as anions such as sulfate and nitrate.
[0068] Based on this, the corresponding pollution impact weights are determined according to the pollution intensity of various pollutants. For example, pollutants that can quickly lead to a decrease in membrane flux, such as high-concentration colloids, should have a higher pollution impact weight than those pollutants that have a slower impact on membrane performance. This process can refer to the conventional understanding of nanofiltration membrane fouling control to ensure that the pollution impact weights can truly reflect the potential hazards of different pollutants. This avoids the assessment distortion caused by simply adding up pollutants of different properties, lays the foundation for accurate calculation of pollution contribution in the subsequent step, and also provides a clear weight basis for the next step of calculating the product of each parameter and the pollution impact weight.
[0069] Then, the synergistic pollution effects between parameters corresponding to different pollution types are analyzed, and the pollution contribution values are adjusted accordingly. This is because when multiple pollutants coexist, they often produce mutually reinforcing pollution effects. For example, colloidal particles adsorb organic matter to form larger pollution clusters, which will accelerate membrane pore blockage; or metal ions combine with organic matter and are more likely to deposit on the membrane surface. The degree of pollution under such synergistic pollution effects usually exceeds the superposition effect of a single pollutant. If ignored, the actual pollution risk will be underestimated.
[0070] In practice, historical operational data is analyzed to identify common synergistic combinations, such as the combined pollution of colloidal and macromolecular organic matter, and the scaling synergy of metal ions and sulfates. The initial pollution contribution value is then adjusted based on the strength of these synergistic effects. The initial pollution contribution value is derived by multiplying each influent water quality parameter by its corresponding pollution impact weight. The adjusted pollution contribution is then obtained by appropriately increasing the correction ratio based on the degree of enhancement of the synergistic pollution effect, for example, when significant synergy exists. This makes the calculation of the pollution contribution value more closely reflect the actual pollution mechanism, avoiding assessment bias caused by ignoring synergistic effects, and providing more reliable basic data for correction based on the pre-membrane fouling index.
[0071] Next, the pre-membrane fouling index is correlated with the water pollution contribution, and the water pollution contribution is proportionally corrected based on the instantaneous pollution state reflected by the pre-membrane fouling index. This is because the water pollution contribution mainly reflects the potential pollution capacity of the influent itself, while the pre-membrane fouling index directly reflects the current actual pollution state on the nanofiltration membrane influent side, such as the amount of pollutants already adsorbed on the membrane surface and the degree of membrane pore blockage. If the two are not correlated, the assessment results will be out of touch with the actual pollution pressure borne by the nanofiltration membrane. The pre-membrane fouling index is obtained by detecting the flux decay rate of the nanofiltration membrane during the filtration process or the water quality changes before and after filtration. Its value can intuitively reflect the immediate pollution pressure faced by the nanofiltration membrane.
[0072] Based on the level of the pre-membrane fouling index, the contribution of water pollution is proportionally adjusted. For example, when the pre-membrane fouling index is high, it indicates that the surface fouling of the nanofiltration membrane is more serious and the actual pollution pressure of the influent is greater, so the adjustment ratio of the water pollution contribution needs to be increased accordingly; conversely, it should be appropriately reduced. This adjustment makes the pollution assessment shift from potential capacity to actual pressure, which is more in line with the real-time operating status of the nanofiltration membrane, avoids the lag in pollution control caused by static assessment, and provides an accurate real-time pollution benchmark for subsequent cumulative effect adjustments.
[0073] Finally, by combining historical pollution data of nanofiltration membranes, the cumulative effect adjustment of the proportionally corrected water pollution contribution is performed to obtain the current pollution load index of the influent. This is because nanofiltration membrane pollution is a long-term cumulative process, and short-term immediate pollution contribution cannot fully reflect the irreversible impact of long-term pollution on membrane performance. For example, the continuous adsorption of certain organic matter will gradually change the pore size and surface properties of nanofiltration membranes. Even if the short-term pollution contribution is not high, long-term accumulation will lead to a significant decline in nanofiltration membrane performance. In practice, the pollution records of nanofiltration membranes over a period of time are retrieved, including changes in membrane flux, cleaning frequency, and pollution type distribution at different time periods, to analyze the cumulative pattern of historical pollution. For example, when a certain type of pollution appears frequently in historical pollution data, its cumulative effect is often more significant.
[0074] Based on these patterns, the proportion of water pollution contribution is adjusted. For example, a certain proportion of the cumulative impact of similar historical pollution is superimposed on the water pollution contribution, with the specific proportion determined according to the degree of membrane performance degradation caused by historical accumulation. This adjustment ensures that the final pollution load index can reflect both the current pollution pressure and the potential impact of long-term pollution, providing comprehensive and accurate pollution baseline data for subsequent prediction of membrane flux changes through long short-term memory networks, and ensuring that the prediction results can more realistically reflect the actual operating status of nanofiltration membranes.
[0075] When calculating historical performance degradation, it is crucial to recognize that historical permeate data of nanofiltration membranes is key to reflecting long-term performance changes. This is because, during long-term operation, nanofiltration membranes are affected by factors such as fouling, chemical cleaning, and material aging, causing their permeate-related performance to gradually decline. Historical permeate data can comprehensively record this process. Specifically, it is necessary to extract indicators directly related to nanofiltration membrane performance from historical permeate data, including membrane flux data, permeate water quality rejection rate data, and operating pressure data for different time periods. The permeate water quality rejection rate data includes the rejection effect on organic matter and heavy metal ions. During the extraction process, abnormal data, such as instantaneous data fluctuations caused by equipment failure and sudden pollution events, are eliminated to avoid such atypical data interfering with the judgment of degradation trends and to ensure that the selected data truly reflects the normal operating status of the membrane. This provides a clean and effective data foundation for subsequent degradation trend analysis, avoids distortion of degradation calculations caused by outliers, and also provides a clear analytical object for the next step of identifying degradation patterns.
[0076] Next, based on the extracted effective historical permeate data, the performance degradation trend of nanofiltration membranes is analyzed. This is because discrete historical permeate data cannot directly reflect the degree of degradation. Trend analysis transforms the data into quantifiable degradation characteristics. Specifically, the historical permeate data is divided into multiple continuous time periods according to the time dimension, and the changing patterns of performance indicators in each time period are analyzed. For example, whether the membrane flux gradually decreases with operating time, whether the rejection rate gradually decreases, and whether the operating pressure required to maintain the rated permeate volume continuously increases.
[0077] Simultaneously, by combining historical operational events, including the number of membrane cleanings, cleaning methods, and long-term fluctuations in influent water quality, the driving factors of degradation can be identified. For example, flux reduction due to fouling accumulation and a decrease in retention rate due to slight damage to the membrane material caused by chemical cleaning can be identified. This allows for the extraction of overall trend characteristics of performance degradation, such as uniform degradation and phased accelerated degradation. In this way, scattered data can be transformed into clear degradation patterns, avoiding one-sided judgments on performance changes. At the same time, it provides a clear trend basis for subsequent quantification of historical performance degradation, ensuring that historical performance degradation can truly reflect the long-term loss status of nanofiltration membranes.
[0078] Finally, based on the identified degradation trend, the historical performance degradation degree is quantified. This is because the degradation trend needs to be transformed into a characterization parameter in order to serve as the input for subsequent membrane flux prediction. Taking the initial performance of the nanofiltration membrane as a benchmark, combined with the performance change trend at different times, the overall performance loss after long-term operation is comprehensively evaluated. The initial performance of the nanofiltration membrane is the membrane flux, rejection rate, and operating pressure when it is first put into use. If the membrane flux shows a continuous downward trend and the rejection rate decreases simultaneously, it indicates that the degradation degree is significant.
[0079] If only the flux decreases slightly but the rejection rate remains stable, the degree of degradation is relatively mild. In the quantification process, the degradation weights of various indicators need to be comprehensively considered to avoid evaluation bias caused by a single indicator, and finally form a historical performance degradation degree that can comprehensively reflect the long-term performance loss of the membrane. This yields a standard and quantifiable degradation characterization parameter, which not only reflects the historical operating loss of the nanofiltration membrane, but also facilitates subsequent input into the long short-term memory network in conjunction with the pollution load index and the pre-membrane pollution index. Its accuracy directly affects the prediction accuracy of the membrane flux change sequence, ensuring that the prediction results can fully take into account the historical loss status of the nanofiltration membrane and are more in line with the actual operating scenario.
[0080] S2. Input the pollution load index, historical performance degradation degree and pre-membrane pollution index into the long short-term memory network to predict the membrane flux change sequence, extract the time series features of the membrane flux change sequence to form the membrane flux degradation risk index, and perform time series analysis on historical water use data to identify water use feature vectors.
[0081] Furthermore, the predicted membrane flux change sequence includes:
[0082] The pollution load index, historical performance degradation rate and membrane pre-fouling index are converted into time series according to the time dimension. The time series includes the trend data of change within a preset historical time period.
[0083] The time series is input into the Long Short-Term Memory (LSTM) network. The parameter features in the trend data are extracted through the multiple hidden layers of the LSM network. The output of the LSM network is calibrated and constrained by combining the historical membrane flux data of the nanofiltration membrane in order to predict the membrane flux change sequence.
[0084] When predicting membrane flux change sequences, the fouling load index, historical performance degradation, and in-membrane fouling index must first be converted into time series, and the time series must include trend data within a preset historical time period. This is because membrane flux changes are not isolated but are directly related to the dynamic changes in the fouling load index, the historical performance degradation of the nanofiltration membrane, and the immediate degree of in-membrane fouling. Moreover, these influencing factors all exhibit continuous changes over time. Long Short-Term Memory Networks can only capture the dynamic correlation between each factor and membrane flux through time-series data. If discrete data is used directly, the changing trends cannot be reflected, leading to prediction results that deviate from reality.
[0085] In practice, continuous monitoring data of the three parameters within a preset historical time period are retrieved, arranged and integrated in chronological order to form a complete time series. At the same time, abnormal fluctuations caused by equipment failures and signal interference during data acquisition are removed to ensure that the time series can truly reflect the natural changing trends of each parameter. This provides structured and trend-based input data for the Long Short-Term Memory (LSTM) network, avoiding interference from discrete or abnormal data on the LTM network's learning. This allows the network to accurately capture the temporal evolution characteristics of each influencing factor. As the input to the LTM network, the completeness and authenticity of this time series directly determine the effectiveness of subsequent feature extraction, laying the foundation for LTM network operations.
[0086] Next, the constructed time series is input into a Long Short-Term Memory (LSTM) network. The LTM network's multiple hidden layers extract parameter features from the trend data, and the output of the LTM network is calibrated and constrained by combining historical membrane flux data of the nanofiltration membrane. This is because time series contain information on changes in different dimensions; some reflect short-term fluctuations, while others reflect long-term evolutionary trends. Single-level feature extraction cannot comprehensively cover key information, while the multiple hidden layers of the LTM network have the ability to extract complex features layer by layer, capturing different dimensional features of each parameter and the correlations between features. Furthermore, relying solely on feature extraction from the input parameters for prediction risks deviating from the actual changes in membrane flux. Historical membrane flux data, as a direct record of nanofiltration membrane performance changes, provides a true reference benchmark for the prediction results. Calibration constraints prevent excessive prediction bias.
[0087] In practice, the first hidden layer of the Long Short-Term Memory (LSTM) network extracts the basic change features of each parameter. The intermediate hidden layers further explore the coupling relationships between different parameter features, such as the temporal correspondence between a sudden increase in pollution load and a decrease in membrane flux. The deep hidden layers integrate comprehensive features directly related to membrane flux changes. Then, the membrane flux prediction results initially output by the LSTM network are compared with historical membrane flux data to analyze the trend differences. Based on the differences, the weight parameters of the LSTM network are adjusted to make the prediction results closer to the actual change patterns, ensuring that the predicted trend is consistent with the evolution logic of historical membrane flux. This fully explores the key features and correlation patterns of each influencing factor. At the same time, the reliability of the prediction results is ensured by calibration with historical membrane flux data, avoiding idealization bias caused by pure model calculations. The output membrane flux change sequence will be directly used to extract time-series features to form a membrane flux decay risk index. The accuracy and trend completeness of the prediction will directly affect the accuracy of the decay risk index, ensuring that the risk assessment can truly reflect the future change trend of membrane flux.
[0088] Specifically, such as Figure 2 As shown, the risk index for the decline of membrane flux includes:
[0089] The membrane flux change sequence predicted by the Long Short-Term Memory Network is decomposed into time-series features including short-term and long-term fluctuation characteristics according to the time scale.
[0090] Extract the fluctuation amplitude of short-term fluctuation characteristics, adjust the risk weight of short-term fluctuation characteristics based on the correlation between fluctuation amplitude and pollution load index, and extract the decay rate of long-term fluctuation characteristics, adjust the risk weight of long-term fluctuation characteristics based on the coupling relationship between decay rate and historical performance decay.
[0091] Based on the time-series characteristics after adjusting the risk weights, the membrane flux decay stages are divided, and different decay stages are assigned to preset basic risk values.
[0092] By combining the pre-membrane fouling index with the baseline risk values of different decay stages, the baseline risk values of the modified baseline risk values are weighted and summed to form the membrane flux decay risk index.
[0093] When formulating the membrane flux decay risk index, the membrane flux change sequence predicted by the Long Short-Term Memory Network (LSTM) must first be decomposed into short-term fluctuation characteristics and long-term fluctuation characteristics according to the time scale. This is because the change in membrane flux contains two different types of trends. In the short term, there will be instantaneous fluctuations due to fluctuations in influent water quality and changes in water demand. In the long term, there will be continuous decay due to the accumulation of nanofiltration membrane fouling and performance aging. The two characteristics have different mechanisms of influence on membrane operation risk. Short-term fluctuations will lead to unstable immediate water production, while long-term decay is related to the service life and operating cost of nanofiltration membranes. If they are not distinguished, the source of risk will be blurred, resulting in a lack of targeted risk assessment.
[0094] Specifically, based on the time span, the scale is divided into short-term fluctuation characteristics, which focus on flux fluctuations within a short period of time, such as fluctuations within a single day or several hours, capturing their sudden rises and falls; long-term fluctuation characteristics focus on the overall trend over a longer period of time, such as weekly or monthly membrane flux changes, extracting the rate and magnitude of their continuous decline. This decomposition can clearly separate the independent effects of the two characteristics, avoid mutual interference, lay the foundation for subsequent targeted risk assessment, and provide a clear analytical object for adjusting risk weights.
[0095] Next, the fluctuation amplitude of short-term fluctuation characteristics is extracted, and the risk weight is adjusted based on its correlation with the pollution load index. At the same time, the decay rate of long-term fluctuation characteristics is extracted, and the risk weight is adjusted according to its coupling relationship with the historical performance decay. This is because the risk level of short-term fluctuations mainly depends on the correlation between the fluctuation amplitude and the pollution load. If the short-term fluctuation amplitude is large and the pollution load index is high in the same period, it indicates that the flux has dropped sharply due to sudden pollution, and the risk is higher. The risk level of long-term decay is closely related to the historical performance decay. If the long-term decay rate is fast and the historical performance decay is severe, it indicates that the membrane performance is deteriorating faster, and the risk is more significant. If the weights are not adjusted in conjunction with these related factors, the risk assessment will be disconnected from the actual driving factors.
[0096] In practice, by analyzing historical data to identify patterns, when short-term fluctuations are positively correlated with the pollution load index (i.e., the higher the pollution load, the more drastic the fluctuations), the risk weight of this fluctuation amplitude is increased; when long-term decay rate is positively correlated with historical performance decay (i.e., the more severe the historical decay, the faster the current decay), the risk weight of this decay rate is increased. This ensures that the risk weights can truly reflect the actual risk contribution of different characteristics, avoid assessment bias caused by a single weight, and provide a weighted characteristic basis for the next step of dividing decay stages, ensuring that stage division can focus on high-risk characteristics.
[0097] Then, based on the time-series characteristics after adjusting the risk weights, the membrane flux decay stages are divided, and a preset basic risk value is assigned to each stage. This is because the weighted time-series characteristics still need to be converted into structured risk levels in order to achieve quantitative risk assessment. Different decay stages correspond to different risk levels. By dividing the stages, continuous feature changes can be converted into discrete risk levels, which is convenient for subsequent unified calibration and summarization. The decay stages include the stable stage, the slow decay stage, and the accelerated decay stage.
[0098] Specifically, the risk levels are divided into stages based on the weighted combination of short-term volatility and long-term decay rate. For example, when short-term volatility is small and long-term decay is slow, it is classified as a low-risk stable stage; when short-term volatility increases or long-term decay accelerates, it is classified as a medium-risk slow decay stage; and when short-term volatility is drastic and long-term decay accelerates, it is classified as a high-risk accelerated decay stage. At the same time, each stage is preset with a corresponding basic risk value to reflect its inherent risk level. This transforms complex characteristic data into a clear risk level framework, avoids ambiguity in risk assessment, and provides a standardized basic risk benchmark for subsequent correction based on the pre-membrane fouling index, ensuring that the correction process has a clear reference.
[0099] Finally, the baseline risk values for different decay stages are proportionally adjusted by combining the pre-membrane fouling index, and then the adjusted baseline risk values are weighted and summed to form the membrane flux decay risk index. This is because the pre-membrane fouling index directly reflects the immediate fouling pressure faced by the membrane. Under the same decay stage, if the pre-membrane fouling index is high, it means that the current fouling is more serious and the actual risk should be higher than the baseline risk value; conversely, the risk is lower. If this immediate factor is ignored, the risk index will become disconnected from the real-time status of the nanofiltration membrane.
[0100] Specifically, the correction ratio is determined based on the level of the pre-membrane fouling index. When the pre-membrane fouling index is higher than the normal level, the correction ratio of the corresponding stage's basic risk value is increased; when it is lower than the normal level, the correction ratio is decreased. After correction, the risk values of each stage are summarized according to their risk weights to form the final decay risk index. This integrates the impact of the immediate fouling state, so that the decay risk index can reflect both long-term trends and current pressures, and the assessment results are more in line with the actual operating risks of the membrane. The output decay risk index will be used as one of the parameters for the subsequent construction of the state vector. Its accuracy directly affects the decision accuracy of the near-end strategy optimization algorithm on the action vector, ensuring that the control strategy can specifically address the decay risk of membrane flux.
[0101] Specifically, identifying water use feature vectors includes:
[0102] Time-series analysis of historical water use data is performed, and scenario types are clustered according to water use behavior patterns over time. Water use duration, peak water use, and water use rate are extracted for different scenarios to obtain water use behavior characteristics.
[0103] The coupling relationship between the temporal variation of water usage duration and membrane flux decay under different scenarios, as well as the temporal correlation between the occurrence time of water usage peak and the pollution load index, were analyzed and quantified into correlation characteristics.
[0104] The time-series mean of water usage rate under different scenarios is calculated and the historical average water production rate of nanofiltration membrane is compared to extract the matching characteristics of water demand and supply capacity under different scenarios.
[0105] Based on the pollution load index and the membrane flux decay risk index, the weights of water use behavior characteristics, correlation characteristics and matching characteristics under the corresponding scenarios are dynamically adjusted, and the weighted integration is used to form a water use feature vector.
[0106] When identifying water use feature vectors, it is first necessary to perform time-series analysis on historical water use data, cluster and classify scenario types according to water use behavior patterns over time, and extract water use duration, peak water use, and water use rate under different scenarios to obtain water use behavior features. This is because water use behavior is not random and disordered, but rather exhibits regular patterns over time. For example, water use times differ between weekdays and weekends, and water use peaks occur in the morning and evening. The load on the system varies significantly under different user behavior patterns. If scenarios are not classified, feature extraction will lack specificity and will fail to reflect the impact of specific scenarios on the system.
[0107] Specifically, by analyzing the temporal distribution patterns of historical water usage data, time periods with similar water usage behavior patterns are grouped into the same scenario, such as peak hours and stable hours. Then, user behavior features are extracted from each scenario. Water usage duration reflects the duration of water usage in that scenario, peak water usage reflects the maximum water demand in that scenario, and water usage rate reflects the intensity of water usage per unit time. This process separates the behavioral differences between different scenarios, avoids feature ambiguity caused by mixed data, lays the foundation for subsequent targeted analysis, and provides scenario-based behavioral evidence for further exploring the correlation between water usage and system status.
[0108] Next, we analyzed the coupling relationship between the temporal variation of water usage duration and membrane flux decay under different scenarios, as well as the temporal correlation between the occurrence time of water usage peaks and the pollution load index. We quantified these relationships as correlation characteristics. This is because water usage behavior is not isolated but closely related to the system state. For example, long-term continuous water usage will lead to continuous high-load operation of the membrane, accelerating membrane flux decay. If the occurrence of water usage peaks coincides with an increase in influent pollution load, it will exacerbate the risk of membrane fouling. If these correlations are ignored, water usage characteristics will not be able to reflect their actual impact on the system.
[0109] By comparing historical water use data to identify patterns, we can observe whether membrane flux shows a more significant decline trend when water use duration increases in a certain scenario, thereby measuring the coupling strength between the two. We can also analyze whether the time point of peak water use coincides with the time point of pollution load index increase, thereby determining the temporal correlation between the two. These patterns are then transformed into quantifiable correlation features. This allows water use behavior features to go beyond simple behavioral descriptions, adding interactive information with system status, making the features more meaningful, providing a correlation background for extracting supply and demand matching features, and ensuring that matching analysis can be combined with the actual carrying capacity of the system.
[0110] Then, the time-series average water usage rate under different scenarios is calculated as the difference between the historical average water production rate of the nanofiltration membrane, and the matching characteristics of water demand and supply capacity are extracted. This is because the stable operation of the system depends on the balance between water demand and the water production capacity of the nanofiltration membrane. If the water usage rate in a certain scenario is consistently higher than the water production rate of the nanofiltration membrane, it will lead to insufficient water supply; if it is significantly lower, it will cause energy waste. This supply and demand matching state is the basis for the formulation of control strategies. If it is not extracted separately, information on system adaptability will be missing.
[0111] The time-series average water usage rate under different scenarios is calculated and compared with the average water production rate of nanofiltration membranes in the same historical period. The difference between the two is used to determine the supply and demand relationship. A positive difference indicates that demand exceeds supply, while a negative difference indicates that supply exceeds demand, thus forming a matching feature. This clearly reflects the supply and demand balance of the system under different scenarios, supplements the information on system adaptability in water usage behavior characteristics, and provides a characteristic basis for dynamic weight adjustment in terms of supply and demand dimensions, ensuring that weight adjustment can take into account the actual carrying capacity of the system.
[0112] Finally, based on the pollution load index and the membrane flux decay risk index, the weights of water use behavior characteristics, correlation characteristics, and matching characteristics under the corresponding scenarios are dynamically adjusted and weighted to form a water use feature vector. This is because the pollution pressure and decay risk faced by the system are different under different scenarios, and the importance of each feature also varies. For example, when the pollution load is high and the decay risk is high, the correlation characteristics between water use behavior and membrane flux decay have a more significant impact on the control decision. When the pollution load and decay risk are low, the matching characteristics of supply and demand will be more important. If a fixed weight is used, the water use feature vector will not be able to adapt to the real-time system state.
[0113] Based on the current pollution load index and the level of the decay risk index, the weight allocation of the three types of features is adjusted. When the pollution load is high, the weight of the associated features is increased; when the decay risk is high, the weight of the indicators related to the nanofiltration membrane load in the behavioral features is strengthened; when the supply and demand contradiction is prominent, the weight of the matching features is increased. The adjusted features are then weighted and integrated into a water use feature vector. This allows the feature vector to dynamically adapt to the real-time risk status of the system, ensuring that the information contained therein is highly consistent with the current control requirements. As an important component in constructing the state vector, the water use feature vector's relevance and adaptability directly affect the decision accuracy of the near-end strategy optimization algorithm on the action vector, ensuring that the control strategy can accurately respond to water demand and system risks under different scenarios.
[0114] S3. Combine the pollution load index, the decay risk index, and the water use characteristic vector to form a state vector. Construct the action vector by combining the target frequency of the variable frequency booster pump and the target opening degree of the control solenoid valve. Then, process the state vector based on the near-end strategy optimization algorithm to output the optimal action vector that satisfies the membrane pressure difference constraint.
[0115] Specifically, such as Figure 3 As shown, the optimal action vector that satisfies the membrane pressure difference constraint includes:
[0116] The constraint threshold for membrane pressure difference is adjusted based on the pollution load index and decay risk index in the state vector.
[0117] An optimization function for a near-end strategy optimization algorithm is constructed based on permeate water quality, operating energy consumption, and nanofiltration membrane lifetime, and membrane pressure difference constraint is embedded as a penalty term into the optimization function;
[0118] The search partitions for action vectors are divided based on the scene type of water use feature vectors, and candidate action vectors with membrane pressure difference within the constraint threshold range are searched in different partitions.
[0119] The action vector with the optimal function value is selected from the candidate action vectors and used as the optimal action vector that satisfies the membrane pressure difference constraint.
[0120] When outputting the optimal action vector that satisfies the membrane pressure difference constraint, the constraint threshold of the membrane pressure difference must first be adjusted according to the fouling load index and the decay risk index in the state vector. This is because the membrane pressure difference is an indicator that reflects the operating state of the nanofiltration membrane, and its reasonable range is not fixed. When the fouling load is high and the risk of membrane flux decay is high, the nanofiltration membrane is more likely to be damaged due to excessive pressure, and the constraint threshold needs to be tightened to reduce the operating pressure. When the fouling load is low and the risk of decay is low, the constraint threshold can be appropriately relaxed to improve water production efficiency. If a fixed threshold is used, it will cause the constraint to be out of touch with the actual state of the nanofiltration membrane, which will excessively limit the water production capacity or increase the risk of membrane damage.
[0121] Specifically, by combining the adaptation patterns of pollution load, degradation risk, and membrane pressure difference in historical data, the upper limit threshold of membrane pressure difference is lowered when the pollution load index or degradation risk index increases; and the threshold is appropriately raised when both decrease, so that the constraint threshold always matches the current bearing capacity of the nanofiltration membrane. This allows the membrane pressure difference constraint to dynamically adapt to the system risk state, avoiding the imbalance between operating efficiency and nanofiltration membrane protection caused by a one-size-fits-all constraint. At the same time, it provides realistic boundary conditions for the next step of searching for candidate action vectors, ensuring that the search range of candidate vectors is both safe and efficient.
[0122] Next, an optimization function for the near-end strategy optimization algorithm is constructed based on the product water quality, operating energy consumption, and nanofiltration membrane lifespan. The membrane pressure difference constraint is embedded as a penalty term in the function. This is because system regulation needs to take multiple objectives into account simultaneously: ensuring that the product water quality meets the standards, reducing operating energy consumption, and extending the lifespan of the nanofiltration membrane. Optimizing a single objective will lead to neglecting one aspect while pursuing another. At the same time, the membrane pressure difference constraint is a bottom-line requirement that must be met, and a penalty mechanism is needed to ensure that the optimization process does not exceed this constraint.
[0123] Specifically, the stability of permeate water quality, the level of operating energy consumption, and the degree of nanofiltration membrane lifespan loss are transformed into evaluation indicators that can be incorporated into the optimization function, so that the optimization function value can comprehensively reflect the optimization degree of these three objectives. Then, whether the membrane pressure difference exceeds the constraint threshold is used as a penalty term. If the constraint threshold is exceeded, the optimization function value will deteriorate significantly, so as to guide the near-end strategy optimization algorithm to prioritize satisfying the membrane pressure difference constraint during the optimization process. Thus, a multi-objective collaborative optimization evaluation system is constructed, and the rigidity of the membrane pressure difference constraint is strengthened through the penalty mechanism to avoid the situation where the optimization result meets the objective but damages the safety of the nanofiltration membrane. This optimization function will serve as the evaluation standard for subsequent selection of the optimal action vector, and its rationality directly affects the comprehensive performance of the final action vector.
[0124] Then, the search partitions of action vectors are divided based on the scenario type of water use feature vectors, and candidate action vectors with membrane pressure difference within the constraint threshold are searched in different partitions. This is because the water demand in different scenarios is significantly different. For example, high flow water supply is required during peak hours, while energy saving is more important during stable hours. The effective range of the corresponding action vectors is also different. If the search is conducted indiscriminately in the global scope, it will increase the amount of invalid computation and make it difficult to find the optimal solution that fits the scenario.
[0125] Specifically, based on the scenario types categorized by water usage feature vectors, a targeted search range for action vectors is set for each scenario. For example, in peak scenarios, the search range for the frequency of the variable frequency booster pump is biased towards a higher range to meet flow requirements, while in stable scenarios, it is biased towards a medium-low range to reduce energy consumption. Within each partition, only action vectors whose membrane pressure difference calculation results are within the constraint threshold range are retained as candidates, while invalid action vectors exceeding the constraint threshold are eliminated. This narrows the search range, improves algorithm efficiency, ensures that candidate action vectors are highly adapted to scenario requirements, avoids invalid searches that are detached from the actual scenario, and provides high-quality alternatives for selecting the optimal solution, ensuring that the final result satisfies both constraints and scenario requirements.
[0126] Finally, the action vector with the best optimization function value is selected from the candidate action vectors as the optimal action vector that satisfies the membrane pressure difference constraint. This is because although the candidate action vectors all satisfy the membrane pressure difference constraint, there are still differences in the balance between product water quality, operating energy consumption and nanofiltration membrane life. The vector with the best overall performance needs to be selected through the evaluation of the optimization function. If it is selected randomly, the control effect will deviate from the optimal target.
[0127] The optimal function value corresponding to each candidate action vector is determined. The action vector with the optimal function value is the final output optimal action vector. The optimal function value means comprehensively satisfying stable product water quality, low operating energy consumption, and minimal nanofiltration membrane lifespan loss. Thus, under the premise of meeting membrane pressure difference constraints, the optimal balance of multiple objectives is achieved, ensuring that the control strategy can protect membrane safety while taking into account operating efficiency and cost. The optimal action vector will be directly used as the control parameter for simulation verification. Its quality directly affects the effect of subsequent simulation verification and the rationality of the final control command, ensuring that the system can achieve optimal operation under safety constraints.
[0128] S4. Simulate and verify the optimal action vector in the simulation environment. When the stability of the produced water quality and the performance indicators of the nanofiltration membrane both meet the standards, generate control commands and send them to the execution components. At the same time, record the simulation verification data periodically to optimize the near-end strategy optimization algorithm and the long short-term memory network.
[0129] Furthermore, the generation of control commands includes:
[0130] The optimal action vector is simulated and verified in a simulation environment. Based on the pollution load index and membrane flux decay risk index in the state vector, the stability of the product water quality and the threshold for the performance indicators of the nanofiltration membrane are dynamically adjusted.
[0131] When the threshold for compliance is met, based on the scenario type of water use feature vector, the frequency of the variable frequency booster pump and the opening degree of the control solenoid valve in the optimal action vector are adapted to form control parameters for different scenarios.
[0132] By comparing the operational deviations between the simulation environment and the actual environment, the control parameters for different scenarios are corrected based on historical simulation verification data. The corrected control parameters are then encapsulated into control commands and sent to the execution components.
[0133] When generating control commands, the optimal action vector must first be simulated and verified in a simulation environment. Based on the pollution load index and membrane flux decay risk index in the state vector, the threshold values for the stability of permeate water quality and the performance indicators of nanofiltration membrane are dynamically adjusted. This is because although the optimal action vector is optimized by the near-end strategy optimization algorithm, the actual operating effect needs to be verified through simulation. The compliance standards are not fixed. When the pollution load is high and the risk of membrane flux decay is high, the system is more vulnerable, and the threshold values for the stability of permeate water quality and the performance indicators of nanofiltration membrane need to be increased to ensure safety. When the pollution load is low and the risk is small, the threshold values can be appropriately reduced to improve operational flexibility. If a fixed threshold is used, the verification results will be out of sync with the actual risk state, resulting in overly stringent restrictions on operation or excessively low standards that may create hidden dangers.
[0134] Specifically, the current system state is reproduced in the simulation environment, and the optimal action vector is run. At the same time, the adaptation pattern of pollution load, decay risk and compliance threshold in historical verification is referenced. When the pollution load index or decay risk index increases, the allowable fluctuation range of water quality stability and the minimum standard of nanofiltration membrane performance are adjusted upward; conversely, they are appropriately adjusted downward, so that the judgment threshold always matches the current risk tolerance of the system. In this way, the standards of simulation verification are closely aligned with actual risks, avoiding misjudgments caused by one-size-fits-all verification, ensuring that the verified action vector can play a stable role in real scenarios, providing a reliable verification basis for the next step of forming scenario-based control parameters, and ensuring the safety of control parameters.
[0135] Next, when the simulation verification shows that the threshold for compliance is met, it is necessary to adapt the frequency of the variable frequency booster pump and the opening degree of the control solenoid valve in the optimal action vector based on the scenario type of water use characteristic vector, and form control parameters for different scenarios. This is because the water demand of different scenarios is significantly different, and the adaptability of the same set of action vector parameters is different in different scenarios. For example, peak water use scenarios require a higher frequency of variable frequency booster pump and a higher opening degree of control solenoid valve to meet the flow demand, while off-peak scenarios require a lower frequency and opening degree to save energy. If uniform parameters are used directly, it will lead to a disconnect between control and scenario requirements and affect operating efficiency.
[0136] Based on the scenario types categorized by water usage characteristic vectors, the parameters in the optimal action vector are adjusted accordingly. In peak scenarios, the frequency of the variable frequency booster pump is appropriately increased to enhance the water production rate, and the opening of the control solenoid valve is widened to reduce water flow resistance. In off-peak scenarios, the frequency of the variable frequency booster pump is reduced to decrease energy consumption, and the opening of the control solenoid valve is fine-tuned to maintain stable pressure. Through this adaptation, the control parameters are precisely matched with the characteristics of the scenario, such as water usage intensity and duration. This allows the control parameters to overcome the limitations of generalization and become scenario-specific, ensuring that water demand is met while maintaining operational economy. The resulting control parameters will provide specific adjustment targets for deviation correction, ensuring that the corrected parameters are more in line with the actual environment.
[0137] Finally, the operational deviations between the simulation environment and the actual environment were compared. Based on historical simulation verification data, the control parameters for different scenarios were corrected. The corrected control parameters were then encapsulated into control commands and sent to the execution components. This is because the simulation environment cannot fully reproduce the complex factors in actual operation, such as pipeline resistance fluctuations and sensor errors. Directly using simulation parameters would cause the actual operating effect to deviate from expectations. The deviation patterns accumulated in historical simulation verification data can provide a reliable basis for correction. If no correction is made, the gap between theory and reality will be amplified.
[0138] By retrieving historical records of discrepancies between simulation parameters and actual operating data in similar scenarios, common types of deviations are analyzed, such as simulated water production exceeding actual levels and differences in pressure fluctuation amplitude. Based on these patterns, control parameters for the current scenario are fine-tuned. If historical simulation data shows that the simulated frequency of the variable frequency booster pump in a certain scenario leads to excessive actual water production, the frequency parameter of the current variable frequency booster pump is appropriately reduced. If the opening of the control solenoid valve causes excessive pressure fluctuations in reality, the opening is fine-tuned to stabilize the pressure. After correction, the control parameters are encapsulated into control commands according to the interface specifications of the actuators and sent to the variable frequency booster pump and control solenoid valve, etc. By correcting deviations, the gap between theory and reality is narrowed, the accuracy and reliability of control commands are improved, and operational anomalies caused by discrepancies between simulation and reality are avoided. The control commands directly drive the actions of the actuators, and their accuracy directly affects the real-time operating status of the system. This provides actual operational feedback for subsequent periodic recording of simulation verification data to optimize algorithms and networks, forming a closed-loop control system.
[0139] Specifically, the optimization algorithms for near-end strategies include:
[0140] The cumulative execution deviation is calculated based on regularly recorded simulation verification data, and the trigger threshold for algorithm optimization is dynamically set in combination with the pollution load index and the membrane flux decay risk index.
[0141] When the cumulative deviation reaches the trigger threshold, the target weight and search range parameters of the near-end strategy optimization algorithm are dynamically adjusted according to the water demand under different scenario types.
[0142] By combining the consistency between the membrane flux change sequence predicted by the Long Short-Term Memory Network and the actual membrane flux, the update step size of the proximal strategy optimization algorithm is calibrated in reverse.
[0143] When optimizing the near-end strategy optimization algorithm, the first step is to calculate the cumulative execution deviation based on regularly recorded simulation verification data. Then, the trigger threshold for algorithm optimization is dynamically set in conjunction with the pollution load index and the membrane flux decay risk index. This is because the execution effect of the near-end strategy optimization algorithm will gradually accumulate deviations as the system operates. For example, after long-term operation, the adaptability of the action vector output by the near-end strategy optimization algorithm to the actual system may decrease. If optimization is not performed in time, the control effect will deviate from expectations. The timing for triggering the optimization of the near-end strategy optimization algorithm cannot be fixed; it must be combined with the current risk status of the system. When the pollution load is high and the risk of membrane flux decay is significant, optimization should be performed promptly, even if the accumulated deviation is small, to avoid further risk expansion. When the risk is low, a slightly larger accumulation of deviation can be allowed before optimization to reduce unnecessary computational costs.
[0144] By summarizing the deviations between the expected and actual results of the near-end strategy optimization algorithm in regularly recorded simulation verification data, the cumulative execution deviation is calculated. Then, referring to the adaptation patterns between risk levels and optimization timing in historical simulation verification data, the trigger threshold is lowered when the pollution load index increases or the decay risk index rises, i.e., optimization is initiated earlier; conversely, the trigger threshold is appropriately increased. This ensures that the triggering timing neither increases the computational burden too frequently nor lags behind changes in system risk. This ensures that the initiation timing of the near-end strategy optimization algorithm precisely matches the actual needs of the system, avoiding blind optimization or delayed optimization. It provides a clear initiation signal for adjusting the parameters of the near-end strategy optimization algorithm, ensuring that the optimization process is initiated promptly when necessary.
[0145] Then, when the cumulative deviation reaches the trigger threshold, the target weight and search range parameters of the near-end strategy optimization algorithm need to be dynamically adjusted according to the water demand under different scenario types. This is because the needs of different scenarios are different. For example, peak water demand scenarios focus more on water production efficiency to meet the demand, while off-peak scenarios focus more on reducing energy consumption and reducing nanofiltration membrane loss. If the near-end strategy optimization algorithm always uses a fixed target weight and search range, the optimization results will not be able to fit the scenario requirements and reduce the targeting of regulation.
[0146] Parameters are adjusted based on the scenario types defined by water usage feature vectors. In peak scenarios, the target weight of water production stability in the near-end strategy optimization algorithm is increased, while the search range of the frequency of the variable frequency booster pump and the opening of the control solenoid valve in the action vector is expanded to adapt to high flow rate demands. In off-peak scenarios, the target weights of operating energy consumption control and nanofiltration membrane life protection are increased, and the search range is narrowed to focus on the energy-saving parameter range. Through this adjustment, the optimization direction and search boundary of the near-end strategy optimization algorithm are highly aligned with the scenario requirements. This makes the near-end strategy optimization algorithm scenario-adaptive, avoiding the neglect of requirements caused by one-size-fits-all optimization, and significantly improving the control effect under different scenarios. The adjusted target weights and search range will provide an optimization basis for calibrating the update step size of the near-end strategy optimization algorithm, ensuring that the step size calibration can be carried out based on the near-end strategy optimization algorithm framework that fits the scenario.
[0147] Finally, by combining the agreement between the membrane flux change sequence predicted by the Long Short-Term Memory (LSTM) network and the actual membrane flux, the update step size of the proximal policy optimization (PPO) algorithm is calibrated in reverse. This is because the update step size of the PPO algorithm determines the magnitude of parameter adjustment. If the step size is too large, the PPO algorithm will deviate from the stable solution during the optimization process; if the step size is too small, the optimization efficiency will be low. The agreement between the predicted and actual membrane flux directly reflects the model's ability to capture system changes. A low agreement indicates that the LSM network prediction has a bias. In this case, if the PPO algorithm updates with a large step size, it will amplify the error. A high agreement indicates that the LSM network is reliable, and the update step size of the PPO algorithm can be appropriately widened to accelerate the optimization.
[0148] By comparing the membrane flux prediction sequence output by the Long Short-Term Memory (LSTM) network with the actual membrane flux data acquired by the system, the degree of agreement between the two is determined, including trend consistency and fluctuation amplitude matching. If the agreement is low, the update step size of the proximal policy optimization algorithm is reduced to decrease the magnitude of a single adjustment and avoid optimization instability caused by the bias of the LSTM network. If the agreement is high, the update step size of the proximal policy optimization algorithm can be appropriately increased to accelerate its convergence to the optimal solution. Thus, the update step size is dynamically adjusted based on the reliability of the LSTM network prediction, ensuring that the proximal policy optimization algorithm maintains both stability and optimization efficiency, avoiding over-adjustment or under-adjustment. The calibrated proximal policy optimization algorithm will serve as the tool for generating the optimal action vector in the next iteration. Its optimization accuracy directly affects the rationality of subsequent control commands, ensuring that the system regulation forms a closed loop of optimization, verification, and re-optimization, continuously improving the operational performance.
[0149] Specifically, optimizing long short-term memory networks includes:
[0150] When the cumulative deviation reaches the trigger threshold, the error weighting coefficient of the long short-term memory network is determined according to the water demand under different scenario types.
[0151] By combining the actual membrane pressure difference of the nanofiltration membrane with the prediction errors in historical simulation verification data, the effective prediction errors are screened according to the time decay coefficient, and the effective prediction errors are weighted according to the error weighting coefficient. The parameters of the long short-term memory network are corrected through error backpropagation.
[0152] The input weights of the Long Short-Term Memory network are corrected based on the action vector output by the optimized proximal policy optimization algorithm.
[0153] When optimizing a Long Short-Term Memory (LSTM) network, the first step is to determine the network's error weighting coefficient based on the water demand under different scenario types when the accumulated deviation reaches the trigger threshold. This is because the prediction performance of the LSM network will gradually deviate as the system operates, and the water demand in different scenarios has different requirements for prediction accuracy. For example, in peak water demand scenarios, the prediction of short-term fluctuations in membrane flux needs to be more accurate to ensure stable water supply, while in off-peak scenarios, more attention is paid to long-term trends to balance energy consumption and membrane protection. If a fixed error weighting method is used, the optimization of the LSM network will not be able to meet the needs of the scenario, reducing the predictive relevance.
[0154] Specifically, based on the scenario types categorized by water feature vectors, error weighting coefficients are set accordingly. In peak scenarios, the weighting coefficient for short-term prediction errors is increased to strengthen the correction of instantaneous fluctuations; in off-peak scenarios, the weighting coefficient for long-term prediction errors is increased to optimize trend capture. This allows the focus of Long Short-Term Memory Network optimization to precisely match the scenario requirements, avoiding prediction index deviations caused by indiscriminate corrections. It also provides a clear coefficient basis for subsequent error screening and weighting, ensuring that error processing can focus on the scenario.
[0155] Next, by combining the actual membrane pressure difference of the nanofiltration membrane with the prediction errors in historical simulation verification data, effective prediction errors are screened according to the time decay coefficient and weighted according to the error weighting coefficient. Then, the network parameters are corrected through error backpropagation. This is because in the historical prediction errors, long-term data will lose its reference value due to changes in system state. It is necessary to screen out recent effective data to avoid interference. Changes in system state include nanofiltration membrane performance degradation and changes in feed water conditions. At the same time, the actual membrane pressure difference can reflect the current true operating state of the membrane and can be used to verify the rationality of the prediction error. For example, the prediction error when the membrane pressure difference suddenly increases will be more valuable for correction. If only historical errors are used without combining them with the actual state, the correction direction will be out of sync with the current membrane state.
[0156] Membrane flux prediction errors are extracted from historical simulation validation data. Recent errors are retained based on a time decay coefficient, while the weight of long-term errors decreases over time until they are eliminated. Combined with real-time measured actual membrane pressure differences, abnormal errors that contradict the trend of membrane pressure difference changes are removed, such as unreasonable data where the membrane pressure difference increases but the prediction error shows stable flux. Then, error weighting coefficients are used to weight the filtered effective errors. The hidden layer weights and biases of the Long Short-Term Memory (LSTM) network are adjusted through an error backpropagation mechanism, i.e., the weighted error signal is transmitted back from the output layer of the LTM network to the input layer. This ensures that the error data used for correction both reflects the current state of the nanofiltration membrane and focuses on recent effective information, making the parameter correction of the LTM network more accurate and avoiding model shifts caused by outdated or abnormal data. The corrected LTM network parameters provide a more reliable model basis for adjusting the input weights, ensuring that the input weight correction can be performed on the optimized LTM network framework.
[0157] Finally, based on the action vectors output by the optimized proximal policy optimization algorithm, the input weights of the Long Short-Term Memory (LSTM) network are corrected. This is because action vectors directly affect the operating state of the nanofiltration membrane, thereby changing the membrane flux. The input layer of the LTM network needs to accurately capture the correlation between action vectors and membrane flux. If the input weights do not reflect this correlation, the LTM network prediction will ignore the actual impact of policy intervention, leading to a disconnect between the prediction results and actual operation. The action vectors output by the optimized proximal policy optimization algorithm are extracted, and their correspondence with actual membrane flux changes is analyzed. For example, the response pattern of membrane flux after action vector adjustment is analyzed. Based on this, the weights of the features corresponding to the action vectors in the input layer of the LTM network are adjusted. If a certain type of action vector has a significant impact on membrane flux, such as pump frequency adjustment causing a significant change in membrane flux, its input weight is increased to strengthen the LTM network's learning of this correlation; otherwise, the weight is decreased.
[0158] This allows the Long Short-Term Memory (LSTM) network to accurately capture the complete chain of policy actions, nanofiltration membrane state changes, and membrane flux response, avoiding a disconnect between prediction and actual control actions and significantly improving the practicality of prediction. The optimized LSM network will serve as a tool for predicting the membrane flux change sequence in the next cycle. Its prediction accuracy directly affects the determination of subsequent attenuation risk index, the optimization of action vectors, and the generation of control commands, ensuring that the entire control process forms a closed loop of prediction, optimization, correction, and re-prediction, continuously improving the stability and economy of system operation.
[0159] Example 2
[0160] This application provides a direct drinking water purification system, which includes a water quality sensing module, a trend prediction module, a target optimization module, and an execution optimization module.
[0161] The water quality sensing module is used to acquire the influent water quality parameters at the inlet and the pre-membrane fouling index on the nanofiltration membrane inlet side. Based on the influent water quality parameters and the pre-membrane fouling index, it calculates the current influent fouling load index and calculates the historical performance degradation based on the historical water production data of the nanofiltration membrane.
[0162] The trend prediction module inputs the pollution load index, historical performance degradation degree, and pre-membrane fouling index into the long short-term memory network to predict the membrane flux change sequence, extracts the time-series features of the membrane flux change sequence to form the membrane flux degradation risk index, and performs time-series analysis on historical water use data to identify water use feature vectors.
[0163] The target optimization module combines the pollution load index, the decay risk index, and the water use characteristic vector to form a state vector, constructs an action vector by combining the target frequency of the variable frequency booster pump with the target opening degree of the control solenoid valve, and processes the state vector based on the near-end strategy optimization algorithm to output the optimal action vector that satisfies the membrane pressure difference constraint.
[0164] The execution optimization module is used to simulate and verify the optimal action vector in a simulation environment. When the stability of the produced water quality and the performance indicators of the nanofiltration membrane meet the standards, control commands are generated and sent to the execution components. Simulation verification data is recorded periodically to optimize the near-end strategy optimization algorithm and the long short-term memory network.
[0165] Since the principle of the system in this application embodiment is similar to the method described above in this application embodiment, the implementation of the system is the same as the implementation of the method, and the repeated parts will not be described again.
Claims
1. A dynamic control method for a direct drinking water purification system, characterized in that, include: Obtain the influent water quality parameters at the inlet and the pre-membrane fouling index on the nanofiltration membrane inlet side. Calculate the current influent fouling load index based on the influent water quality parameters and the pre-membrane fouling index, and calculate the historical performance degradation based on the historical permeate data of the nanofiltration membrane. The pollution load index, historical performance degradation index, and pre-membrane fouling index are input into a long short-term memory network to predict the membrane flux change sequence. The time-series features of the membrane flux change sequence are extracted to form a membrane flux degradation risk index. Time-series analysis of historical water use data is performed to identify water use feature vectors. The state vector is formed by combining the pollution load index, the decay risk index and the water use characteristic vector. The action vector is constructed by combining the target frequency of the variable frequency booster pump and the target opening degree of the control solenoid valve. The state vector is then processed based on the near-end strategy optimization algorithm to output the optimal action vector that satisfies the membrane pressure difference constraint. The optimal action vector is simulated and verified in a simulation environment. When the stability of the produced water quality and the performance indicators of the nanofiltration membrane both meet the standards, control commands are generated and sent to the execution components. Simultaneously, simulation verification data is recorded periodically to optimize the near-end strategy optimization algorithm and the long short-term memory network.
2. The dynamic control method for a direct drinking water purification system as described in claim 1, characterized in that, The calculation of the current influent pollution load index includes: The pollution types of influent water quality parameters are classified according to the nature of the pollution on nanofiltration membranes, and the corresponding pollution impact weights are determined according to the pollution intensity of the influent water quality parameters. The synergistic pollution effects among influent water quality parameters corresponding to different pollution types are analyzed. The pollution contribution value is calculated based on the product of the influent water quality parameter and the corresponding pollution impact weight. The pollution contribution value is then adjusted according to the synergistic pollution effects to obtain the water quality pollution contribution. The pre-membrane fouling index is correlated with the contribution to water pollution, and the contribution to water pollution is proportionally corrected based on the instantaneous fouling state of the nanofiltration membrane feed side reflected by the pre-membrane fouling index. By combining historical pollution data of nanofiltration membranes, the cumulative effect adjustment is made to the proportionally corrected water pollution contribution, and the adjusted result represents the pollution load index of the current influent.
3. The dynamic control method for a direct drinking water purification system as described in claim 2, characterized in that, The predicted membrane flux change sequence includes: The pollution load index, historical performance degradation rate and membrane pre-fouling index are converted into time series according to the time dimension. The time series includes the trend data of change within a preset historical time period. The time series is input into the Long Short-Term Memory (LSTM) network. The parameter features in the trend data are extracted through the multiple hidden layers of the LSM network. The output of the LSM network is calibrated and constrained by combining the historical membrane flux data of the nanofiltration membrane in order to predict the membrane flux change sequence.
4. The dynamic control method for a direct drinking water purification system as described in claim 3, characterized in that, The risk index for the decline of membrane flux includes: The membrane flux change sequence predicted by the Long Short-Term Memory Network is decomposed into time-series features including short-term and long-term fluctuation characteristics according to the time scale. Extract the fluctuation amplitude of short-term fluctuation characteristics, adjust the risk weight of short-term fluctuation characteristics based on the correlation between fluctuation amplitude and pollution load index, and extract the decay rate of long-term fluctuation characteristics, adjust the risk weight of long-term fluctuation characteristics based on the coupling relationship between decay rate and historical performance decay. Based on the time-series characteristics after adjusting the risk weights, the membrane flux decay stages are divided, and different decay stages are assigned to preset basic risk values. By combining the pre-membrane fouling index with the baseline risk values of different decay stages, the baseline risk values of the modified baseline risk values are weighted and summed to form the membrane flux decay risk index.
5. The dynamic control method for a direct drinking water purification system as described in claim 4, characterized in that, The water use feature vector for identification includes: Time-series analysis of historical water use data is performed, and scenario types are clustered according to water use behavior patterns over time. Water use duration, peak water use, and water use rate are extracted for different scenarios to obtain water use behavior characteristics. The coupling relationship between the temporal variation of water usage duration and membrane flux decay under different scenarios, as well as the temporal correlation between the occurrence time of water usage peak and the pollution load index, were analyzed and quantified into correlation characteristics. The time-series mean of water usage rate under different scenarios is calculated and the historical average water production rate of nanofiltration membrane is compared to extract the matching characteristics of water demand and supply capacity under different scenarios. Based on the pollution load index and the membrane flux decay risk index, the weights of water use behavior characteristics, correlation characteristics and matching characteristics under the corresponding scenarios are dynamically adjusted, and the weighted integration is used to form a water use feature vector.
6. The dynamic control method for a direct drinking water purification system as described in claim 5, characterized in that, The optimal action vector that satisfies the membrane pressure difference constraint includes: The constraint threshold for membrane pressure difference is adjusted based on the pollution load index and decay risk index in the state vector. An optimization function for a near-end strategy optimization algorithm is constructed based on permeate water quality, operating energy consumption, and nanofiltration membrane lifetime, and membrane pressure difference constraint is embedded as a penalty term into the optimization function; The search partitions for action vectors are divided based on the scene type of water use feature vectors, and candidate action vectors with membrane pressure difference within the constraint threshold range are searched in different partitions. The action vector with the optimal function value is selected from the candidate action vectors and used as the optimal action vector that satisfies the membrane pressure difference constraint.
7. The dynamic control method for a direct drinking water purification system as described in claim 6, characterized in that, The generation control instructions include: The optimal action vector is simulated and verified in a simulation environment. Based on the pollution load index and membrane flux decay risk index in the state vector, the stability of the product water quality and the threshold for the performance indicators of the nanofiltration membrane are dynamically adjusted. When the threshold for compliance is met, based on the scenario type of water use feature vector, the frequency of the variable frequency booster pump and the opening degree of the control solenoid valve in the optimal action vector are adapted to form control parameters for different scenarios. By comparing the operational deviations between the simulation environment and the actual environment, the control parameters for different scenarios are corrected based on historical simulation verification data. The corrected control parameters are then encapsulated into control commands and sent to the execution components.
8. The dynamic control method for a direct drinking water purification system as described in claim 7, characterized in that, The optimized near-end strategy optimization algorithm includes: The cumulative execution deviation is calculated based on regularly recorded simulation verification data, and the trigger threshold for algorithm optimization is dynamically set in combination with the pollution load index and the membrane flux decay risk index. When the cumulative deviation reaches the trigger threshold, the target weight and search range parameters of the near-end strategy optimization algorithm are dynamically adjusted according to the water demand under different scenario types. By combining the consistency between the membrane flux change sequence predicted by the Long Short-Term Memory Network and the actual membrane flux, the update step size of the proximal strategy optimization algorithm is calibrated in reverse.
9. The dynamic control method for a direct drinking water purification system as described in claim 8, characterized in that, Optimizing the Long Short-Term Memory network includes: When the cumulative deviation reaches the trigger threshold, the error weighting coefficient of the long short-term memory network is determined according to the water demand under different scenario types. By combining the actual membrane pressure difference of the nanofiltration membrane with the prediction errors in historical simulation verification data, the effective prediction errors are screened according to the time decay coefficient, and the effective prediction errors are weighted according to the error weighting coefficient. The parameters of the long short-term memory network are corrected through error backpropagation. The input weights of the Long Short-Term Memory network are corrected based on the action vector output by the optimized proximal policy optimization algorithm.
10. A direct drinking water purification system, used to implement the dynamic control method of the direct drinking water purification system according to any one of claims 1-9, characterized in that, include: Water quality sensing module, trend prediction module, target optimization module, and execution optimization module; The water quality sensing module is used to acquire the influent water quality parameters at the inlet and the pre-membrane fouling index on the nanofiltration membrane inlet side. Based on the influent water quality parameters and the pre-membrane fouling index, it calculates the current influent fouling load index and calculates the historical performance degradation based on the historical water production data of the nanofiltration membrane. The trend prediction module inputs the pollution load index, historical performance degradation degree, and pre-membrane fouling index into the long short-term memory network to predict the membrane flux change sequence, extracts the time-series features of the membrane flux change sequence to form the membrane flux degradation risk index, and performs time-series analysis on historical water use data to identify water use feature vectors. The target optimization module combines the pollution load index, the decay risk index, and the water use characteristic vector to form a state vector, constructs the target frequency of the variable frequency booster pump and the target opening degree of the control solenoid valve into an action vector, and processes the state vector based on the near-end strategy optimization algorithm to output the optimal action vector that satisfies the membrane pressure difference constraint. The execution optimization module is used to simulate and verify the optimal action vector in a simulation environment. When the stability of the produced water quality and the performance indicators of the nanofiltration membrane meet the standards, control commands are generated and sent to the execution components. At the same time, simulation verification data is recorded periodically to optimize the near-end strategy optimization algorithm and the long short-term memory network.
Citation Information
Patent Citations
Intelligent regulation and control method for three-stage constructed wetland recirculating aquaculture system
CN120406176A
Membrane control method and system based on multi-parameter intelligent perception
CN120541767A
Intelligent energy-saving control system and method based on multi-parameter coupling analysis and predictive maintenance
CN120949562A
KR20250141476A
Cited By
Printing and dyeing wastewater reuse RO membrane cleaning intelligent decision-making method and system
CN121944800A