A method and system for optimizing simulation results of lake and reservoir water quality models

Through the combination of Monte Carlo sampling method and Bayesian averaging method, the parameter calibration process of the lake reservoir water quality model is optimized, and the problem of uncertainty in parameter calibration and insufficient model robustness in the existing technology is solved, and higher simulation results accuracy and model generalization ability are achieved.

CN119761074BActive Publication Date: 2025-05-13TIANJIN RES INST FOR WATER TRANSPORT ENG M O T
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510253062.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-03-05
Publication Date
2025-05-13
Estimated Expiration
2045-03-05

AI Technical Summary

Technical Problem

There is uncertainty in the parameter calibration process of existing lake reservoir water quality models, resulting in insufficient accuracy and reliability of simulation results, and weak model robustness and generalization capabilities.

Method used

Multiple sets of parameter combinations were generated by Monte Carlo sampling method, and simulated by the lake reservoir water quality model to calculate the root mean square error, Nash efficiency coefficient and average absolute error of each group of simulation results. The weights of each evaluation index were determined using gray correlation analysis, normalization and comprehensive scoring calculations were performed, and the simulation results with good performance were finally integrated through the Bayesian average method.

Benefits of technology

It reduces the uncertainty caused by the combination of single parameters, improves the accuracy of simulation results, the robustness and generalization capabilities of the model, and enhances the simulation capabilities of lake reservoir water quality.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119761074B_ABST
    Figure CN119761074B_ABST
Patent Text Reader

Abstract

The present invention relates to the technical field of water environment management, and discloses a simulation result optimization method and system of a lake water quality model, constructs a lake water quality model; selects parameters and target variables that need to be calibrated; sets the prior distribution of each parameter, and generates m groups of parameter combinations by random sampling; obtains m groups of simulation results according to the m groups of parameter combinations, and calculates the RMSE, NSE and MAE of each target variable in each group of simulation results respectively; uses grey correlation analysis to determine the weight of the RMSE, NSE and MAE of each target variable, and calculates the comprehensive index of each target variable; calculates the comprehensive score of each group of simulation results; and obtains the final simulation result by Bayesian averaging method according to the comprehensive score of the simulation results. The present invention can reduce the uncertainty caused by a single parameter combination, improve the accuracy of the simulation results, enhance the robustness and generalization ability of the model, and improve the model's simulation ability for lake water quality.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of water environment management, and in particular to a method and system for optimizing simulation results of a lake water quality model. Background Art

[0002] Compared with river basins and rivers, lakes and reservoirs are usually static or slow-flow systems with weaker water fluidity and prone to vertical stratification. They require detailed descriptions of the biogeochemical cycle of nutrients and the dynamic changes of algae growth, death, and sedimentation. Therefore, lake and reservoir water quality models are usually the most complex models.

[0003] Since lake water quality models involve a large number of parameters and processes, the parameters are complex and highly correlated with each other, the existing technology usually still mainly uses manual calibration methods. The parameter combination may lack consistency and reliability, and it is impossible to find the global optimal solution, resulting in poor model performance. In the calibration process of the model, there will be multiple parameters with the same effect, that is, different parameter combinations can produce similar simulation results, which makes it difficult to determine a unique set of "optimal" parameter combinations. Even if a single "optimal" parameter combination can be obtained, it may be affected by the limitations of the observation data or optimization algorithm, resulting in insufficient accuracy and reliability of the final simulation results.

[0004] Therefore, there is an urgent need for a simulation result optimization method and system for lake and reservoir water quality models that can reduce the uncertainty brought about by a single parameter combination, improve the accuracy of simulation results, enhance the robustness and generalization ability of the model, and improve the model's ability to simulate lake and reservoir water quality. Summary of the invention

[0005] In order to solve the above technical problems, the present invention provides a method and system for optimizing the simulation results of a lake water quality model, which can reduce the uncertainty caused by a single parameter combination, improve the accuracy of the simulation results, enhance the robustness and generalization ability of the model, and improve the model's simulation ability for unknown data.

[0006] The present invention provides a method for optimizing simulation results of a lake water quality model, comprising the following steps:

[0007] S1. Construct lake and reservoir water quality model;

[0008] S2, select the parameters and target variables to be calibrated;

[0009] S3, setting the prior distribution of each parameter, and generating m groups of parameter combinations by Monte Carlo sampling method;

[0010] S4, respectively bring m groups of parameter combinations into the lake water quality model to obtain m groups of simulation results, each group of simulation results contains the time series of n target variables, and respectively calculate the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable in each group of simulation results;

[0011] S5. Calculate the grey correlation coefficient of the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable by using grey correlation analysis, and determine the weight of the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable according to the grey correlation coefficient;

[0012] S6. Normalize the root mean square error RMSE, Nash efficiency coefficient NSE, and mean absolute error MAE of each target variable, and calculate the comprehensive index of each target variable according to the normalized root mean square error RMSE, Nash efficiency coefficient NSE, mean absolute error MAE and corresponding weights;

[0013] S7, averaging the comprehensive index of each target variable in each group of simulation results to obtain a comprehensive score for each group of simulation results;

[0014] S8. Sort the comprehensive scores of the m groups of simulation results from large to small, use Bayesian averaging to merge the simulation results corresponding to the comprehensive scores of the top K, and use the merged results as the final simulation results.

[0015] Furthermore, in S1, the lake water quality model is the LAKE2K model, and the construction of the lake water quality model includes:

[0016] The dynamic water balance equation of the lake is established, and the expression is as follows:

[0017] ;

[0018] Where V is the lake capacity, t' is the time, Q in represents the inflow flow, Q p represents the precipitation flow, Q e Indicates the evaporation amount, Q out Indicates the outflow flow rate;

[0019] The lake heat balance equation is established and the expression is as follows:

[0020] ;

[0021] Among them, Heat l represents the heat of the water body in the first layer, ρ represents the water body density, C p represents the specific heat of water, T in Indicates the inlet temperature, T lrepresents the temperature of the first layer of water, T air Indicates the air temperature, E ’ l represents the volume diffusion coefficient across the lower boundary of the lth water layer, A 0 represents the surface area of ​​the water body, J h Represents the heat flux between water and air;

[0022] The mass balance equation is established and the expression is as follows:

[0023] ;

[0024] Among them, V l represents the volume of the first layer of water, c l Indicates the concentration of the corresponding pollutant in the water body at layer l (mg / l), c in Indicates the concentration of the corresponding pollutant in the inflow (mg / l), S l Indicates the load of chemical reaction and material exchange in the first layer of water (mg / m 3 / d).

[0025] Furthermore, in S4, m groups of parameter combinations are respectively brought into the lake water quality model to obtain m groups of simulation results, each group of simulation results contains the time series of n target variables, and the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable in each group of simulation results are calculated respectively, including:

[0026] Calculate the root mean square error RMSE of each target variable in each set of simulation results. The calculation formula is as follows:

[0027] ;

[0028] Among them, RMSE ij represents the root mean square error of the i-th target variable under the j-th parameter combination, i represents the i-th target variable, t represents the t-th sampling time point, T represents the total sampling time, P tj,i represents the simulated value of the i-th target variable under the j-th parameter combination at the t-th sampling time point, O tj,i It represents the measured value of the i-th target variable under the j-th parameter combination at the t-th sampling time point;

[0029] Calculate the Nash efficiency coefficient NSE of each target variable in each set of simulation results. The calculation formula is as follows:

[0030] ;

[0031] Among them, NSE ij represents the Nash efficiency coefficient of the i-th target variable under the j-th parameter combination, It represents the average value of the measured value of the i-th target variable at all sampling time points under the j-th group of parameter combinations;

[0032] Calculate the mean absolute error MAE of each target variable in each set of simulation results. The calculation formula is as follows:

[0033] ;

[0034] Among them, MAE ij It represents the mean absolute error of the i-th target variable under the j-th parameter combination.

[0035] Further, in S5, the grey correlation analysis is used to calculate the grey correlation coefficient of the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable, and the weights of the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable are determined according to the grey correlation coefficient, including:

[0036] S51, setting an ideal value for each evaluation index; the evaluation indexes include root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE;

[0037] S52, respectively calculating the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable and the grey correlation coefficient of the ideal value;

[0038] S53, averaging the grey correlation coefficients of the evaluation indicators of the target variable in the m groups of simulation results to obtain the average correlation coefficients of the evaluation indicators of the target variable;

[0039] The calculation formula is as follows:

[0040] ;

[0041] in, represents the average correlation coefficient of the kth evaluation index of the i-th target variable, j represents the jth group of parameter combinations, m represents the total number of parameter combinations, γ ki,j It represents the grey correlation coefficient of the kth evaluation index of the ith target variable under the jth group of parameter combinations;

[0042] S54. Taking the average correlation coefficient of each evaluation index of the target variable as the weight of each evaluation index of the target variable.

[0043] Further, in S52, the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable and the grey correlation coefficient of the ideal value are calculated respectively, and the calculation formula is as follows:

[0044] ;

[0045] Among them, γ ki,j It represents the grey correlation coefficient of the kth evaluation index of the ith target variable under the jth group of parameter combinations, Δ ki,j It represents the difference between the kth evaluation index of the ith target variable and the ideal value under the jth parameter combination, min(|Δ ki |) represents the minimum absolute value of the difference between the kth evaluation index of the i-th target variable and the ideal value among all parameter combinations, max(|Δ ki |) represents the maximum absolute value of the difference between the kth evaluation index of the ith target variable and the ideal value in all parameter combinations, and β represents the resolution coefficient.

[0046] Furthermore, in S6, the root mean square error RMSE, Nash efficiency coefficient NSE, and mean absolute error MAE of each target variable are normalized, and the comprehensive index of each target variable is calculated according to the normalized root mean square error RMSE, Nash efficiency coefficient NSE, mean absolute error MAE and the corresponding weights. The calculation formula is as follows:

[0047] ;

[0048] Among them, CI ij represents the comprehensive index of the i-th target variable under the j-th group of parameter combinations, ω i1 ,ω i2 ,ω i3 They represent the weights of the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of the i-th target variable, RMSE ij,norm Represents the root mean square error of the i-th target variable under the j-th group of parameter combinations after normalization, NSE ij,norm Represents the Nash efficiency coefficient of the i-th target variable under the j-th group of parameter combinations after normalization, MAE ij,norm It represents the normalized mean absolute error of the i-th target variable under the j-th parameter combination.

[0049] Further, in S8, the comprehensive scores of the m groups of simulation results are sorted from large to small, and the simulation results corresponding to the comprehensive scores ranked in the top K are fused using Bayesian averaging, and the fused results are used as the final simulation results including:

[0050] S81, sort the comprehensive scores of the m groups of simulation results from largest to smallest, and obtain the comprehensive scores of the top K;

[0051] S82, converting each comprehensive score into a corresponding likelihood value;

[0052] The conversion formula is as follows:

[0053] ;

[0054] Among them, P(y|M j ) represents the likelihood function, α represents the scaling factor, SI j represents the comprehensive score of the jth group of simulation results, M j represents the lake water quality model corresponding to the jth group of parameter combinations, y represents M j The corresponding simulation results;

[0055] S83, calculating the posterior weight of the parameter combination corresponding to each comprehensive score according to the likelihood value corresponding to each comprehensive score;

[0056] The calculation formula is as follows:

[0057] ;

[0058] in, represents the posterior weight of the jth group of parameter combinations;

[0059] S84, fusing the posterior weight of each parameter combination and the simulation results corresponding to each parameter combination through Bayesian averaging to obtain a final simulation result;

[0060] The calculation formula is as follows:

[0061] ;

[0062] in, It represents the final simulation result after Bayesian average fusion, and K represents the total number of selected parameter combinations.

[0063] The present invention also provides a system for optimizing the simulation results of a lake water quality model, which is used to execute any one of the above-mentioned methods for optimizing the simulation results of a lake water quality model. The system includes the following modules:

[0064] Model building module, used to obtain the hydrological, water quality and meteorological data of lakes and reservoirs, and build lake and reservoir water quality models based on the hydrological, water quality and meteorological data;

[0065] The parameter selection module is used to select the parameters and target variables that need to be calibrated; set the prior distribution of each parameter, and generate m groups of parameter combinations through random sampling;

[0066] The performance index calculation module is connected with the parameter selection module and the model construction module, and is used to bring m groups of parameter combinations into the lake water quality model respectively, and obtain m groups of simulation results. Each group of simulation results contains the time series of n target variables, and the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable in each group of simulation results are calculated respectively;

[0067] A weight calculation module is connected to the performance index calculation module, and is used to calculate the root mean square error RMSE, Nash efficiency coefficient NSE and the grey correlation coefficient of the mean absolute error MAE of each target variable by using grey correlation analysis, and determine the weight of the root mean square error RMSE, Nash efficiency coefficient NSE and the mean absolute error MAE of each target variable according to the grey correlation coefficient;

[0068] The comprehensive index calculation module is connected with the weight calculation module and the performance index calculation module, and is used to normalize the root mean square error RMSE, Nash efficiency coefficient NSE, and mean absolute error MAE of each target variable, and calculate the comprehensive index of each target variable according to the normalized root mean square error RMSE, Nash efficiency coefficient NSE, mean absolute error MAE and the corresponding weight;

[0069] A comprehensive score calculation module is connected to the comprehensive index calculation module and is used to average the comprehensive index of each target variable in each group of simulation results to obtain a comprehensive score for each group of simulation results;

[0070] The output module is connected to the comprehensive score calculation module and is used to sort the comprehensive scores of the m groups of simulation results from large to small, and use Bayesian averaging to fuse the simulation results corresponding to the comprehensive scores ranked in the top K, and use the fused results as the final simulation results.

[0071] The embodiments of the present invention have the following technical effects:

[0072] The present invention simultaneously considers three performance indicators, namely, root mean square error, Nash efficiency coefficient and mean absolute error. These three performance indicators can evaluate the quality of simulation results from different angles, making parameter calibration more comprehensive. The weight of each evaluation indicator to each target variable is determined by grey correlation analysis. Multiple evaluation indicators can be considered at the same time, and their importance is determined by calculating the correlation between these indicators and the ideal value, avoiding model bias caused by a single evaluation indicator and ensuring the comprehensiveness and rationality of weight distribution. The simulation results obtained by combining multiple groups of parameters with better performance are integrated by the Bayesian averaging method, which can reduce the uncertainty brought by a single parameter combination, effectively alleviate the problems of multi-parameter equivalence and overfitting, improve the accuracy of simulation results, and enhance the robustness and generalization ability of the model. BRIEF DESCRIPTION OF THE DRAWINGS

[0073] In order to more clearly illustrate the specific implementation methods of the present invention or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0074] Figure 1 It is a flow chart of a method for optimizing simulation results of a lake water quality model provided by an embodiment of the present invention;

[0075] Figure 2 A lake depth-volume curve diagram provided by an embodiment of the present invention;

[0076] Figure 3 is a comparison diagram of simulation results of nitrate nitrogen provided by an embodiment of the present invention;

[0077] Figure 4 This is a comparison diagram of simulation results of ammonia nitrogen provided by an embodiment of the present invention;

[0078] Figure 5 It is a structural schematic diagram of a simulation result optimization system for a lake water quality model provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0079] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be described clearly and completely below. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work belong to the scope of protection of the present invention.

[0080] The present invention proposes a method for optimizing the simulation results of a lake water quality model. Figure 1 This is a flow chart of a method for optimizing the simulation results of a lake water quality model provided by an embodiment of the present invention, see Figure 1 , specifically including:

[0081] S1. Construct lake and reservoir water quality model.

[0082] In some embodiments, the lake water quality model is a LAKE2K model.

[0083] The construction of lake water quality model specifically includes:

[0084] S11. Obtain hydrological data, water quality data and meteorological data of lakes and reservoirs;

[0085] Hydrological data may include inflow and outflow, reservoir capacity and water depth curves, etc.;

[0086] Water quality data may include water quality monitoring data of inflowing rivers and lakes;

[0087] Meteorological data can include air temperature, radiation, precipitation, wind speed, cloud cover, dew point temperature, etc.

[0088] S12. Determine the lake depth-volume curve based on the lake's hydrological data, water quality data and meteorological data; Figure 2 As shown, Figure 2 It is a lake water depth-volume curve diagram provided by an embodiment of the present invention.

[0089] S13, according to the hydrological data, water quality data, meteorological data and lake depth-volume curve of the lake, a dynamic water balance equation of the lake, a heat balance equation of the lake and a mass balance equation are established to obtain a lake water quality model;

[0090] The dynamic water balance equation of the lake is established, and the expression is as follows:

[0091] ;

[0092] Where V is the lake capacity, t' is the time, Q in represents the inflow flow, Q p represents the precipitation flow, Q e Indicates the evaporation amount, Q out Indicates the outflow flow rate;

[0093] The lake heat balance equation is established and the expression is as follows:

[0094] ;

[0095] Among them, Heat l represents the heat of the water body in the first layer, ρ represents the water body density, C p represents the specific heat of water, T in Indicates the inlet temperature, T l represents the temperature of the first layer of water, T air Indicates the air temperature, E ’ l represents the volume diffusion coefficient across the lower boundary of the lth water layer, A 0 represents the surface area of ​​the water body, J h represents the heat flux between water and air, and Indicates unit conversion;

[0096] The mass balance equation is established and the expression is as follows:

[0097] ;

[0098] Among them, Vl represents the volume of the first layer of water, c l Indicates the concentration of the corresponding pollutant in the water body at layer l (mg / l), c in Indicates the concentration of the corresponding pollutant in the inflow (mg / l), S l Indicates the load of chemical reaction and material exchange in the first layer of water (mg / m 3 / d).

[0099] S2. Select the parameters and target variables to be calibrated.

[0100] In some embodiments, the parameters and target variables that need to be calibrated can be determined based on literature and expert experience. For example, the organic nitrogen hydrolysis rate k can be selected hn , ammonia nitrogen hydrolysis rate k n , nitrate nitrogen denitrification rate k dn As parameters that need to be calibrated, ammonia nitrogen and nitrate nitrogen were selected as target variables.

[0101] S3. Set the prior distribution of each parameter and generate m groups of parameter combinations through Monte Carlo sampling method.

[0102] In some embodiments, the prior distribution of each parameter can be set according to actual conditions or expert experience, and the types of prior distributions include but are not limited to uniform distribution, normal distribution, lognormal distribution, exponential distribution, and gamma distribution. For example, the organic nitrogen hydrolysis rate k hn , ammonia nitrogen hydrolysis rate k n , nitrate nitrogen denitrification rate k dn The prior distribution of is shown in the following table:

[0103] Table 1 Prior distribution of parameters

[0104]

[0105] For example, 1000 sets of organic nitrogen hydrolysis rates k are generated by random sampling. hn , ammonia nitrogen hydrolysis rate k n , nitrate nitrogen denitrification rate k dn The parameter distribution of is shown in the following table:

[0106] Table 2 Distribution of parameters

[0107]

[0108] S4. Bring m groups of parameter combinations into the lake water quality model respectively to obtain m groups of simulation results. Each group of simulation results contains the time series of n target variables. Calculate the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable in each group of simulation results.

[0109] In some embodiments, the root mean square error RMSE of each target variable in each set of simulation results is calculated using the following formula:

[0110] ;

[0111] Among them, RMSE ij represents the root mean square error of the i-th target variable under the j-th parameter combination, i represents the i-th target variable, t represents the t-th sampling time point, T represents the total sampling time, P tj,i represents the simulated value of the i-th target variable under the j-th parameter combination at the t-th sampling time point, O tj,i It represents the measured value of the i-th target variable under the j-th parameter combination at the t-th sampling time point;

[0112] Calculate the Nash efficiency coefficient NSE of each target variable in each set of simulation results. The calculation formula is as follows:

[0113] ;

[0114] Among them, NSE ij represents the Nash efficiency coefficient of the i-th target variable under the j-th parameter combination, It represents the average value of the measured value of the i-th target variable at all sampling time points under the j-th group of parameter combinations;

[0115] Calculate the mean absolute error MAE of each target variable in each set of simulation results. The calculation formula is as follows:

[0116] ;

[0117] Among them, MAE ij It represents the mean absolute error of the i-th target variable under the j-th parameter combination.

[0118] S5. Grey correlation analysis is used to calculate the grey correlation coefficient of the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable, and the weight of the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable is determined according to the grey correlation coefficient.

[0119] RMSE is sensitive to large errors and is highly intuitive, making it suitable for evaluating models that are sensitive to large errors. NSE is used to measure the degree of improvement of model simulation results relative to the mean of observed values ​​and has strong relative evaluation capabilities. MAE is not as sensitive to outliers as MSE and RMSE and is more robust. Comprehensive consideration of the three performance indicators avoids model bias caused by a single evaluation criterion and ensures that the model performs well under different circumstances.

[0120] Specifically include:

[0121] S51. Set an ideal value for each evaluation indicator.

[0122] Among them, the evaluation indicators include root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE. Since RMSE measures the square root of the average of the squares of the differences between the simulated values ​​and the observed values, the smaller the square error, the smaller the gap between the simulated values ​​and the observed values. Therefore, the ideal value of RMSE is 0, indicating that the model simulation is completely accurate and there is no error; MAE measures the average of the absolute values ​​of the differences between the simulated values ​​and the observed values. The smaller the absolute error, the smaller the gap between the simulated values ​​and the observed values. Therefore, the ideal value of MAE is also 0; and NSE measures the performance of the model simulation values ​​relative to the average of the observed values. When all simulated values ​​are exactly equal to the observed values, NSE is equal to 1. Therefore, the ideal value of NSE is 1.

[0123] S52. Calculate the grey correlation coefficient between the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable and the ideal value respectively.

[0124] The calculation formula is as follows:

[0125] ;

[0126] Among them, γ ki,j It represents the grey correlation coefficient of the kth evaluation index of the ith target variable under the jth group of parameter combinations, Δ ki,j It represents the difference between the kth evaluation index of the ith target variable and the ideal value under the jth parameter combination, min(|Δ ki |) represents the minimum absolute value of the difference between the kth evaluation index of the i-th target variable and the ideal value among all parameter combinations, max(|Δ ki |) represents the maximum absolute value of the difference between the kth evaluation index of the ith target variable and the ideal value in all parameter combinations, and β represents the resolution coefficient.

[0127] S53, averaging the grey correlation coefficients of the evaluation indicators of the target variable in the m groups of simulation results to obtain the average correlation coefficients of the evaluation indicators of the target variable.

[0128] The calculation formula is as follows:

[0129] ;

[0130] in, represents the average correlation coefficient of the kth evaluation index of the i-th target variable, j represents the jth group of parameter combinations, m represents the total number of parameter combinations, γ ki,jIt represents the grey correlation coefficient of the kth evaluation index of the ith target variable under the jth parameter combination.

[0131] S54. Taking the average correlation coefficient of each evaluation index of the target variable as the weight of each evaluation index of the target variable.

[0132] S6. Normalize the root mean square error RMSE, Nash efficiency coefficient NSE, and mean absolute error MAE of each target variable, and calculate the comprehensive index of each target variable based on the normalized root mean square error RMSE, Nash efficiency coefficient NSE, mean absolute error MAE and the corresponding weights.

[0133] In some embodiments, the normalized formula of RMSE is as follows:

[0134] ;

[0135] Among them, RMSE ij,norm Represents the root mean square error of the i-th target variable under the j-th group of parameter combinations after normalization, RMSE ij,min 、RMSE ij,max They respectively represent the minimum and maximum root mean square error of the i-th target variable under the j-th group of parameter combinations after normalization.

[0136] In some embodiments, the normalized formula of NSE is as follows:

[0137] ;

[0138] Among them, NSE ij,norm Represents the Nash efficiency coefficient of the i-th target variable under the j-th group of parameter combinations after normalization, NSE ij,min 、NSE ij,max They respectively represent the minimum and maximum values ​​of the Nash efficiency coefficient of the ith target variable under the jth group of parameter combinations after normalization.

[0139] In some embodiments, the normalized formula of MAE is as follows:

[0140] ;

[0141] Among them, MAE ij,norm Represents the mean absolute error of the i-th target variable under the j-th group of parameter combinations after normalization, MAE ij,min 、MAE ij,max They respectively represent the minimum and maximum mean absolute errors of the i-th target variable under the j-th group of parameter combinations after normalization.

[0142] In some embodiments, the calculation formula of the comprehensive index of each target variable is as follows:

[0143] ;

[0144] Among them, CI ij represents the comprehensive index of the i-th target variable under the j-th group of parameter combinations, ω i1 ,ω i2 ,ω i3 They respectively represent the weights of the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of the i-th target variable.

[0145] S7. Average the comprehensive index of each target variable in each group of simulation results to obtain a comprehensive score for each group of simulation results.

[0146] In some embodiments, the calculation formula is as follows:

[0147] ;

[0148] Among them, SI j Represents the comprehensive score of the jth group of simulation results.

[0149] S8. Sort the comprehensive scores of the m groups of simulation results from large to small, use Bayesian averaging to merge the simulation results corresponding to the comprehensive scores of the top K, and use the merged results as the final simulation results.

[0150] Specifically include:

[0151] S81. Sort the comprehensive scores of the m groups of simulation results from largest to smallest, and obtain the comprehensive scores of the top K groups.

[0152] In some embodiments, 10% of the total number of parameter combinations may be selected as the value of K. For example, if there are 20 parameter combinations in total, the comprehensive scores ranked in the top two are selected.

[0153] S82. Convert each comprehensive score into a corresponding likelihood value.

[0154] In some embodiments, the conversion formula is as follows:

[0155] ;

[0156] Among them, P(y|M j ) represents the likelihood function, α represents the proportional factor, which is used to set the weight difference of different parameter combinations and is set according to the actual situation. For example, it can also be set to 1. j represents the comprehensive score of the jth group of simulation results, M j represents the lake water quality model corresponding to the jth group of parameter combinations, y represents M j The corresponding simulation results.

[0157] S83. Calculate the posterior weight of the parameter combination corresponding to each comprehensive score according to the likelihood value corresponding to each comprehensive score.

[0158] In some embodiments, the calculation formula is as follows:

[0159] ;

[0160] in, represents the posterior weight of the jth group of parameter combinations.

[0161] S84. According to the posterior weight of each parameter combination and the simulation results corresponding to each parameter combination, the simulation results are integrated through Bayesian averaging to obtain the final simulation result.

[0162] In some embodiments, the calculation formula is as follows:

[0163] ;

[0164] in, It represents the final simulation result after Bayesian average fusion, and K represents the total number of selected parameter combinations.

[0165] For example, the posterior distribution of the parameters obtained by Bayesian averaging is shown in the following table:

[0166]

[0167] Figure 3 is a comparison diagram of simulation results of nitrate nitrogen provided by an embodiment of the present invention, Figure 4 This is a comparison chart of ammonia nitrogen simulation results provided by an embodiment of the present invention, see Figure 3 and Figure 4 In the figure, the gray curve and the blue curve are the simulation results corresponding to the comprehensive scores of the top K in the 1000 parameter distributions, among which the blue is the optimal value in the simulation results corresponding to the comprehensive scores of the top K. The Bayesian average is performed based on the simulation results represented by the gray curve and the blue curve to obtain the red curve (Bayesian average). It can be seen that the optimal value and the Bayesian average are closer to the measured value than the results before calibration, which can reflect the fluctuation of the measured value. In addition, when the uncertainty of the simulation results is large, Bayesian fusion can reduce the uncertainty caused by a single parameter combination and improve the robustness of the simulation results.

[0168] The present invention simultaneously considers three performance indicators, namely, root mean square error, Nash efficiency coefficient and mean absolute error. These three performance indicators can evaluate the quality of simulation results from different angles, making parameter calibration more comprehensive. The weight of each evaluation indicator to each target variable is determined by grey correlation analysis. Multiple evaluation indicators can be considered at the same time, and their importance is determined by calculating the correlation between these indicators and the ideal value, avoiding model bias caused by a single evaluation indicator and ensuring the comprehensiveness and rationality of weight distribution. The simulation results obtained by combining multiple groups of parameters with better performance are integrated by the Bayesian averaging method, which can reduce the uncertainty brought by a single parameter combination, effectively alleviate the problems of multi-parameter equivalence and overfitting, improve the accuracy of simulation results, and enhance the robustness and generalization ability of the model.

[0169] Figure 5 is a schematic diagram of the structure of a system for optimizing the simulation results of a lake water quality model provided by an embodiment of the present invention, the system is used to execute a method for optimizing the simulation results of a lake water quality model described in the above embodiment, such as Figure 5 As shown, the system includes the following modules:

[0170] Model building module, used to obtain the hydrological, water quality and meteorological data of lakes and reservoirs, and build lake and reservoir water quality models based on the hydrological, water quality and meteorological data;

[0171] The parameter selection module is used to select the parameters and target variables that need to be calibrated; set the prior distribution of each parameter, and generate m groups of parameter combinations through random sampling;

[0172] The performance index calculation module is connected with the parameter selection module and the model construction module, and is used to bring m groups of parameter combinations into the lake water quality model respectively, and obtain m groups of simulation results. Each group of simulation results contains the time series of n target variables, and the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable in each group of simulation results are calculated respectively;

[0173] A weight calculation module is connected to the performance index calculation module, and is used to calculate the root mean square error RMSE, Nash efficiency coefficient NSE and the grey correlation coefficient of the mean absolute error MAE of each target variable by using grey correlation analysis, and determine the weight of the root mean square error RMSE, Nash efficiency coefficient NSE and the mean absolute error MAE of each target variable according to the grey correlation coefficient;

[0174] The comprehensive index calculation module is connected with the weight calculation module and the performance index calculation module, and is used to normalize the root mean square error RMSE, Nash efficiency coefficient NSE, and mean absolute error MAE of each target variable, and calculate the comprehensive index of each target variable according to the normalized root mean square error RMSE, Nash efficiency coefficient NSE, mean absolute error MAE and the corresponding weight;

[0175] A comprehensive score calculation module is connected to the comprehensive index calculation module and is used to average the comprehensive index of each target variable in each group of simulation results to obtain a comprehensive score for each group of simulation results;

[0176] The output module is connected to the comprehensive score calculation module and is used to sort the comprehensive scores of the m groups of simulation results from large to small, and use Bayesian averaging to fuse the simulation results corresponding to the comprehensive scores ranked in the top K, and use the fused results as the final simulation results.

[0177] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the technical solutions of the embodiments of the present invention.

Claims

1. A method for optimizing simulation results of a lake water quality model, characterized in that: The steps include: S1. Construct lake and reservoir water quality model; S2, select the parameters and target variables to be calibrated; S3, setting the prior distribution of each parameter, and generating m groups of parameter combinations by Monte Carlo sampling method; S4, respectively bringing m groups of parameter combinations into the lake water quality model to obtain m groups of simulation results, each group of simulation results containing n time series of target variables, and respectively calculating the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable in each group of simulation results; S5. Calculate the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable using grey correlation analysis, and determine the weight of the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable according to the grey correlation coefficient; S6. Normalize the root mean square error RMSE, Nash efficiency coefficient NSE, and mean absolute error MAE of each target variable, and calculate the comprehensive index of each target variable according to the root mean square error RMSE, Nash efficiency coefficient NSE, mean absolute error MAE and corresponding weights; S7, averaging the comprehensive index of each target variable in each group of simulation results to obtain a comprehensive score for each group of simulation results; S8. Sort the comprehensive scores of the m groups of simulation results from large to small, use Bayesian averaging to merge the simulation results corresponding to the comprehensive scores of the top K, and use the merged results as the final simulation results.

2. The method for optimizing the simulation results of a lake water quality model according to claim 1, characterized in that: In S1, the lake water quality model is a LAKE2K model, and constructing the lake water quality model includes: The dynamic water balance equation of the lake is established, and the expression is as follows: ; Where V is the lake capacity, t' is the time, Q in represents the inflow flow, Q p represents the precipitation flow, Q e Indicates the evaporation amount, Q out Indicates the outflow flow rate; The lake heat balance equation is established and the expression is as follows: ; Among them, Heat l represents the heat of the water body in the first layer, ρ represents the water body density, C p represents the specific heat of water, T in Indicates the inlet temperature, T l represents the temperature of the first layer of water, T air Indicates the air temperature, E ’ l represents the volume diffusion coefficient across the lower boundary of the lth layer of water, A0 represents the surface area of ​​the water body, J h Represents the heat flux between water and air; The mass balance equation is established and the expression is as follows: ; Among them, V l represents the volume of the first layer of water, c l represents the concentration of the corresponding pollutant in the water body at layer l, c in represents the concentration of the corresponding pollutant in the inflow, S l Represents the load of chemical reaction and material exchange in the first layer of water.

3. The method for optimizing the simulation results of a lake water quality model according to claim 1, characterized in that: In S4, m groups of parameter combinations are respectively introduced into the lake water quality model to obtain m groups of simulation results, each group of simulation results contains a time series of n target variables, and the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable in each group of simulation results are calculated respectively, including: Calculate the root mean square error RMSE of each target variable in each set of simulation results. The calculation formula is as follows: ; Among them, RMSE ij represents the root mean square error of the i-th target variable under the j-th parameter combination, i represents the i-th target variable, t represents the t-th sampling time point, T represents the total sampling time, P tj,i represents the simulated value of the i-th target variable under the j-th parameter combination at the t-th sampling time point, O tj,i It represents the measured value of the i-th target variable under the j-th parameter combination at the t-th sampling time point; Calculate the Nash efficiency coefficient NSE of each target variable in each set of simulation results. The calculation formula is as follows: ; Among them, NSE ij represents the Nash efficiency coefficient of the i-th target variable under the j-th parameter combination, It represents the average value of the measured value of the i-th target variable at all sampling time points under the j-th group of parameter combinations; Calculate the mean absolute error MAE of each target variable in each set of simulation results. The calculation formula is as follows: ; Among them, MAE ij It represents the mean absolute error of the i-th target variable under the j-th parameter combination.

4. The method for optimizing the simulation results of a lake water quality model according to claim 3, characterized in that: In S5, the grey correlation coefficient of the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable is calculated by grey correlation analysis, and the weight of the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable is determined according to the grey correlation coefficient, including: S51, setting an ideal value for each evaluation index; the evaluation indexes include root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE; S52, respectively calculating the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable and the grey correlation coefficient of the ideal value; S53, averaging the grey correlation coefficients of the evaluation indicators of the target variable in the m groups of simulation results to obtain the average correlation coefficients of the evaluation indicators of the target variable; The calculation formula is as follows: ; in, represents the average correlation coefficient of the kth evaluation index of the i-th target variable, j represents the jth group of parameter combinations, m represents the total number of parameter combinations, γ ki,j It represents the grey correlation coefficient of the kth evaluation index of the ith target variable under the jth group of parameter combinations; S54. Taking the average correlation coefficient of each evaluation index of the target variable as the weight of each evaluation index of the target variable.

5. The method for optimizing the simulation results of a lake water quality model according to claim 4, characterized in that: In S52, the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable and the grey correlation coefficient of the ideal value are calculated respectively, and the calculation formula is as follows: ; Among them, γ ki,j It represents the grey correlation coefficient of the kth evaluation index of the ith target variable under the jth group of parameter combinations, Δ ki,j It represents the difference between the kth evaluation index of the ith target variable and the ideal value under the jth parameter combination, min(|Δ ki |) represents the minimum absolute value of the difference between the kth evaluation index of the i-th target variable and the ideal value among all parameter combinations, max(|Δ ki |) represents the maximum absolute value of the difference between the kth evaluation index of the ith target variable and the ideal value in all parameter combinations, and β represents the resolution coefficient.

6. The method for optimizing the simulation results of a lake water quality model according to claim 5, characterized in that: In S6, the root mean square error RMSE, Nash efficiency coefficient NSE, and mean absolute error MAE of each target variable are normalized, and the comprehensive index of each target variable is calculated according to the normalized root mean square error RMSE, Nash efficiency coefficient NSE, mean absolute error MAE and corresponding weights. The calculation formula is as follows: ; Among them, CI ij represents the comprehensive index of the i-th target variable under the j-th group of parameter combinations, ω i1 ,ω i2 ,ω i3 They represent the weights of the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of the i-th target variable, RMSE ij,norm Represents the root mean square error of the i-th target variable under the j-th group of parameter combinations after normalization, NSE ij,norm Represents the Nash efficiency coefficient of the i-th target variable under the j-th group of parameter combinations after normalization, MAE ij,norm It represents the normalized mean absolute error of the i-th target variable under the j-th parameter combination.

7. The method for optimizing the simulation results of a lake water quality model according to claim 5, characterized in that: In S8, the comprehensive scores of the m groups of simulation results are sorted from large to small, and the simulation results corresponding to the comprehensive scores ranked in the top K are fused using Bayesian averaging, and the fused results are used as the final simulation results including: S81, sort the comprehensive scores of the m groups of simulation results from largest to smallest, and obtain the comprehensive scores of the top K; S82, converting each of the comprehensive scores into a corresponding likelihood value; The conversion formula is as follows: ; Among them, P(y|M j ) represents the likelihood function, α represents the scaling factor, SI j represents the comprehensive score of the jth group of simulation results, M j represents the lake water quality model corresponding to the jth group of parameter combinations, y represents M j The corresponding simulation results; S83, calculating the posterior weight of the parameter combination corresponding to each comprehensive score according to the likelihood value corresponding to each comprehensive score; The calculation formula is as follows: ; in, represents the posterior weight of the jth group of parameter combinations; S84, fusing the posterior weight of each parameter combination and the simulation results corresponding to each parameter combination through Bayesian averaging to obtain a final simulation result; The calculation formula is as follows: ; in, It represents the final simulation result after Bayesian average fusion, and K represents the total number of selected parameter combinations.

8. A system for optimizing simulation results of a lake water quality model, used to implement a method for optimizing simulation results of a lake water quality model as described in any one of claims 1 to 7, characterized in that: The system includes the following modules: A model building module is used to obtain the hydrological, water quality and meteorological data of the lake and reservoir, and to build a lake and reservoir water quality model based on the hydrological, water quality and meteorological data; The parameter selection module is used to select the parameters and target variables that need to be calibrated; set the prior distribution of each parameter, and generate m groups of parameter combinations through random sampling; A performance index calculation module is connected to the parameter selection module and the model construction module, and is used to bring m groups of parameter combinations into the lake water quality model to obtain m groups of simulation results, each group of simulation results contains a time series of n target variables, and calculates the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable in each group of simulation results; A weight calculation module, connected to the performance index calculation module, is used to calculate the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable using grey correlation analysis, and determine the weight of the root mean square error RMSE, Nash efficiency coefficient NSE and mean absolute error MAE of each target variable according to the grey correlation coefficient; A comprehensive index calculation module, connected to the weight calculation module and the performance index calculation module, is used to normalize the root mean square error RMSE, Nash efficiency coefficient NSE, and mean absolute error MAE of each target variable, and calculate the comprehensive index of each target variable according to the normalized root mean square error RMSE, Nash efficiency coefficient NSE, mean absolute error MAE and corresponding weights; A comprehensive score calculation module, connected to the comprehensive index calculation module, is used to average the comprehensive index of each target variable in each group of simulation results to obtain a comprehensive score for each group of simulation results; The output module is connected to the comprehensive score calculation module and is used to sort the comprehensive scores of the m groups of simulation results from large to small, and use Bayesian averaging to fuse the simulation results corresponding to the top K comprehensive scores, and use the fused results as the final simulation results.

Citation Information

Patent Citations

  • Short-term Load Forecasting Method Based on TCN and IPSO-LSSVM Combined Model

    AU2020104000A4

  • Method for sustainability evaluation of power grid construction project

    CN109034625A