Two-stage checking method for node water demand and pipe section friction resistance coefficient of water supply network
Through the two-stage verification method, combined with sequential data assimilation and iterative calculation, the problem of insufficient calibration accuracy of the water supply pipeline model parameter in the existing technology is solved, and high-precision verification of parameters within the prior range is achieved.
Patent Information
- Application Number
- CN202510481970.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-16
- Publication Date
- 2025-07-25
AI Technical Summary
The prior art is difficult to effectively combine historical information with current monitoring information, and the filtering algorithm cannot iteratively optimize within the prior range of parameters, resulting in insufficient calibration accuracy of the water supply pipeline model parameter.
The two-stage verification method is adopted, firstly, using historical information to perform preliminary calculations through the sequential data assimilation method, and then iterative optimization is performed using the range of prior information in iterative calculations. Combining the advantages and disadvantages of sequential data assimilation and iterative calculations, the parameter verification accuracy is improved.
The calibration accuracy of the water demand for the water supply network nodes and the friction coefficient of the pipe section is improved, ensuring that the parameters are optimized within the prior range, and improving the calibration accuracy and stability of the model.
Smart Images

Figure CN120373197A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of real-time online calibration of water supply network model parameters, and more specifically to a two-stage calibration method for the water demand of water supply network nodes and the pipe friction coefficient. Background Art
[0002] With the advancement of urbanization, the scale of the water supply network, as an urban infrastructure, is also increasing rapidly, which brings an increase in the tasks of network scheduling and emergency monitoring. With the development of intelligent systems, a water network hydraulic model that meets the accuracy requirements is an important prerequisite for subsequent operations of the water network.
[0003] Before the hydraulic model is put into online use, it is necessary to calibrate the accuracy of the model parameters to ensure that the state parameter values simulated by the model and the measured point values are close to the actual state parameter values and monitoring values of the water network within a given accuracy range. Model calibration is divided into two parts: macroscopic calibration and microscopic calibration. Since the macroscopic calibration stage is the preliminary preparation work and can be carried out through the already measured data, the calibration of the water network model is concentrated in the second stage, that is, microscopic calibration. Since the number of measuring points in the water network is much smaller than the number of nodes and pipe segments, in order to make the calibration results solvable, calculations are generally carried out in the form of parameter grouping.
[0004] For common heuristic algorithms (such as genetic algorithms) and inversion algorithms (such as least squares algorithms), they cannot combine historical information with monitoring information at the current moment, which hinders the improvement of calibration accuracy. For the filtering algorithm in sequential data assimilation, during the process of parameter calibration, it cannot use the prior information interval of the parameters to limit the range of the parameters, and when the final calibration result does not meet the expectations, it cannot perform iterative optimization of the parameters, resulting in a decrease in the accuracy of the Kalman filter. Therefore, how to provide a calibration method that can not only make full use of historical information but also iteratively optimize the water demand of water network nodes and the pipe friction coefficient within the prior range interval of the parameters is an urgent problem to be solved by those skilled in the art. Summary of the Invention
[0005] In view of this, the present invention provides a two-stage calibration method for the water demand of water supply network nodes and the pipe friction coefficient. Based on sequential data assimilation (ensemble Kalman filter) and iterative calculation (Levenberg-Marquardt), two-stage calibration is carried out. The sequential data assimilation in the first stage makes full use of historical information and performs preliminary calculation of parameters in the form of prediction-correction. The iterative calculation in the second stage takes the results of the first stage as empirical values and initial values and performs iterative fine-tuning within the prior range interval of the parameters. The two methods improve the parameter calibration accuracy in a complementary way of advantages and disadvantages, providing basic support for the preliminary modeling and subsequent management and regulation of the water supply network.
[0006] To achieve the above object, the present invention provides the following technical solutions:
[0007] A two-stage calibration method for the water demand of water supply network nodes and the friction coefficient of pipeline segments, comprising the following steps:
[0008] S1. Obtain the historical fluctuation ranges of the measurement values of user water meters, water bills, user group type information, the materials, pipe diameters and service times of pipeline segments, and network pressure and flow sensors;
[0009] S2. Aggregate the water-using nodes with similar characteristics together according to the water-using characteristics and relative positions of the nodes; group the pipelines according to the characteristics of the pipelines, and all the pipelines in each group have the same friction coefficient;
[0010] S3. Calculate the covariance matrix of the pressure and flow monitoring points based on the historical fluctuation ranges of the measurement values obtained in S1;
[0011] S4. Calculate the values of the water demand of nodes and the friction coefficient of pipeline segments at the first stage at time t and their covariances by using the sequential data assimilation method;
[0012] S5. Take the parameter values and their covariances at the first stage as empirical values, and perform iterative optimization of the water demand of nodes and the friction coefficient of pipeline segments at the second stage within the range of parameter prior information based on the iterative optimization method of empirical information;
[0013] S6. Judge whether the values of the calibration parameters meet the iterative stop condition. If not, repeat steps S5 and S6. If so, stop the iterative calculation and output the optimal values of the calibration parameters at time t;
[0014] S7. Calculate the corresponding optimal covariance according to the optimal values of the calibration parameters;
[0015] S8. For the calculation of the optimal values and their covariances of the calibration parameters at time t+1, repeat steps S4-S7.
[0016] Optionally, S4 is specifically:
[0017] S41. Initialize the values qC0 of the parameters at time t=0 and the corresponding covariance P0;
[0018] S42. Calculate the sampling points χ fi at the prediction stage at time t, and then calculate the predicted parameter values qc fi and variance P t|t-1 according to the sampling points χ t|t-1 ;
[0019] S43. According to the predicted parameter values qc t|t-1 and variance P t|t-1 , calculate the volume points χ mi, and according to the volume point χ mi perform the calculation of the predicted measured value HQ t|t-1 .
[0020] S44. Calculate the calibration parameter and the measurement covariance P (qc)(HQ) and the measurement covariance P (HQ)(HQ) , and then calculate the parameter calibration value qC′ t of the first stage and its covariance P′ t .
[0021] Optionally, S42 is specifically:
[0022] Assume that the water demand of the node group estimated at time t-1 is q t-1 , the friction coefficient of the pipe section group is c t-1 , and they are combined and denoted as the parameter state value qc t-1 , the covariance of the water demand of the corresponding node group is P q(t-1) , the covariance of the pipe section friction coefficient is P c(t-1) , and they are combined and denoted as the parameter covariance P t-1 , and then generate the sampling points χ fi of the calibration parameter:
[0023]
[0024] In the formula, and are the sampling points of the parameters, and each sampling point is a column vector, which is denoted as χ fi , the number of sampling points is 2n, n is the number of parameters to be calibrated, n = l q +l C , l q is the number of node groups, l C is the number of pipe groups, I i represents the i-th column of the identity matrix. Calculate the parameter values qc fi and the covariance P t|t-1 predicted according to the sampling points χ t|t-1 :
[0025]
[0026]
[0027] In the formula, f(χ fi ) represents the parameter prediction equation, F f is a diagonal matrix, and the first l qThe value is the ratio of the water demand at time t and t-1 for the corresponding node group. For the pipe friction coefficient, since it changes slowly, it is defaulted that the pipe friction coefficients at the previous and current times are the same, that is, the ratios of the pipe friction coefficients at time t and t-1 are both 1, which means that the values from the (l q +1)th to the (l q +l C )th in the diagonal are all 1. U t is the covariance matrix of the prediction process.
[0028] Optionally, S43 is specifically:
[0029] Calculate the volume points χ mi at the measurement stage:
[0030]
[0031] In the formula, and are the volume points of the parameters. Each volume point is a column vector, denoted as χ mi . The number of volume points is 2n, where n is the number of calibration parameters, that is, n = l q +l C . I i represents the i-th column of the identity matrix. Predict the measured value according to the volume point χ mi :
[0032]
[0033] In the formula, HQ t (χ mi ) is the predicted measured value obtained by substituting the volume point χ mi into the pipe network model.
[0034] Optionally, S44 is specifically:
[0035] Perform the calculation of the calibration parameter and the measurement covariances P (qc)(HQ) and the measurement covariance P (HQ)(HQ) :
[0036]
[0037] In the formula, R t is the combined covariance matrix of the pressure measurement points and the flow measurement points. σ P is the covariance matrix of the pipe network pressure measurement points, and σ Q is the covariance matrix of the pipe network flow measurement points;
[0038] Perform the calculation of the parameter state value qC′ t at time t in the first stage and its covariance P t ′:
[0039]
[0040] Wherein, HQ t is the combined column vector of the actual measured values of the pressure measurement point and the flow measurement point at the current moment.
[0041] Optionally, S5 is specifically:
[0042] S51. Define the target parameter value of the iterative optimization method as the extended matrix based on the empirical information parameter value qC′ t and its covariance P t ′;
[0043] S52. Derive the iterative calculation formula according to the calculation process of the Levenberg-Marquardt algorithm, and calculate the parameter value of the (i + 1)-th iterative calculation
[0044] S53. Limit the upper and lower limits of the values in the parameter vector of the (i + 1)-th iteration. If it exceeds the upper limit, it is equal to the upper limit; if it is lower than the lower limit, it is equal to the lower limit value.
[0045] Optionally, S51 is specifically:
[0046] Define the extended vector group:
[0047]
[0048] The extended covariance matrix of the parameters and the measurement points in the objective function is:
[0049]
[0050] Wherein, is the parameter value calculated at the i-th iteration, HQ t is the combined column vector of the measured values of the pressure measurement point and the flow measurement point at the current moment, is the corresponding measured value obtained by substituting the i-th iteration value into the pipe network model; then the extended objective function matrix based on the empirical information is defined as:
[0051]
[0052] Wherein, V t 、Y t 、 all represent intermediate variables.
[0053] Optionally, S52 is specifically:
[0054] According to the Levenberg-Marquardt algorithm, the iterative calculation formula of the parameter can be derived as:
[0055]
[0056] In the formula, I is the identity matrix, λ is a minimum value to prevent the matrix in the intermediate process from being non-invertible, and J HQ represents the Jacobian matrix of the pipe network, Substitute the Jacobian matrix corresponding to the i-th iteration value into the pipe network model for calculation, which is the process variable.
[0057] Optionally, S53 is specifically:
[0058]
[0059]
[0060] In the formula, represents the water demand node group m at time t, 1 ≤ m ≤ l q , the water demand check value for the (i + 1)-th iteration, and represent the minimum and maximum values of the prior water demand range of node group m, represents the pipe segment group s at time t, 1 ≤ s ≤ l C , the friction coefficient check value for the (i + 1)-th iteration, and represent the minimum and maximum values of the prior friction coefficient range of pipe segment group s. This step ensures that the checked parameters are all within the prior range, avoiding parameter check values that do not conform to engineering significance.
[0061] Optionally, the iteration stop condition in S6 is the error of the checked parameter value or i ≥ i max One of them, where ξ is the set error range value, and i max is the maximum number of iterations. Denote the optimal check value of the parameter when the stop condition is reached as qC t ;
[0062] Specifically, the calculation of the optimal covariance in S7 is:
[0063]
[0064] In the formula, P t is the optimal covariance of the checked parameter, is the Jacobian matrix obtained by substituting the optimal value qC of the checked parameter t into the pipe network model for calculation.
[0065] As can be seen from the above technical solutions, compared with the prior art, the present invention provides a two-stage verification method for the water demand of water supply network nodes and the pipe friction coefficient, having the following beneficial effects:
[0066] 1. The present invention uses methods with different principles to simultaneously verify two parameters in a complementary form of advantages and disadvantages, improving the final verification accuracy of the parameters;
[0067] 2. The filtering algorithm of the present invention makes full use of historical information to obtain a relatively accurate preliminary estimated value of the verification parameter as the empirical value and initial value of iterative optimization, improving the accuracy of iterative optimization;
[0068] 3. The present invention uses an iterative algorithm to perform secondary correction on the filtering result, making up for the disadvantages that the filtering result cannot be embedded in the prior information range and multiple iterative optimizations, and improving the final verification accuracy of the parameters. BRIEF DESCRIPTION OF THE DRAWINGS
[0069] In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings required for use in the description of the embodiments or the prior art. Obviously, the drawings in the following description are only the embodiments of the present invention. For those of ordinary skill in the art, other drawings can be obtained according to the provided drawings without creative efforts.
[0070] Figure 1 is the general flow chart of the two-stage verification method of the present invention;
[0071] Figure 2 is a schematic diagram of the structure of the water supply network and the positions of monitoring points in the embodiments of the present invention;
[0072] Figure 3 is a schematic diagram of the grouping of water supply network nodes and pipe segments in the embodiments of the present invention;
[0073] Figure 4 is a schematic diagram of the process values of the friction parameters verified by the iterative algorithm in the embodiments of the present invention;
[0074] Figure 5 is a schematic diagram of the comparison results of the verification errors of the pressure monitoring points of the volume Kalman and the two-stage verification method in the embodiments of the present invention;
[0075] Figure 6 is a schematic diagram of the comparison results of the verification errors of the flow monitoring points of the volume Kalman and the two-stage verification method in the embodiments of the present invention;
[0076] Figure 7 is a schematic diagram of the comparison results of the verification errors of the friction coefficients of the volume Kalman and the two-stage verification method in the embodiments of the present invention;
[0077] Figure 8 Schematic diagram of the comparison result of the water demand verification error of the node group in the volume Kalman and two-stage verification method in the embodiment of the present invention;
[0078] Figure 9 Schematic diagram of the verification process of the friction coefficient of the first group of pipe sections by the volume Kalman and two-stage verification method in the embodiment of the present invention;
[0079] Figure 10 Schematic diagram of the verification process of the water demand of the ninth group of node groups by the volume Kalman and two-stage verification method in the embodiment of the present invention. Detailed implementation manners
[0080] Next, the technical solutions in the embodiments of the present invention will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts shall fall within the protection scope of the present invention.
[0081] The embodiment of the present invention discloses a two-stage verification method for the water demand of nodes and the friction coefficient of pipe sections in a water supply network, as Figure 1 shown, including the following steps:
[0082] S1. Obtain the user water meter, water bill, user group type information, the material, diameter and service life of the pipe section, and the historical fluctuation range of the measured values of the network pressure and flow sensors;
[0083] S2. Aggregate the water-using nodes with similar characteristics according to the water-using characteristics and relative positions of the nodes; group the pipes according to the characteristics of the pipes, and all the pipes in each group have the same friction coefficient;
[0084] S3. Calculate the covariance matrix of the pressure and flow monitoring points based on the historical fluctuation range of the measured values obtained in S1;
[0085] S4. Use the sequential data assimilation method to calculate the values and covariances of the water demand of the nodes and the friction coefficient of the pipe sections at the first stage at time t;
[0086] S5. Take the parameter values and covariances at the first stage as empirical values, and perform iterative optimization of the water demand of the nodes and the friction coefficient of the pipe sections at the second stage within the range of the prior information of the parameters based on the iterative optimization method of empirical information;
[0087] S6. Determine whether the values of the verification parameters meet the iterative stop condition. If not, repeat steps S5 and S6. If so, stop the iterative calculation and output the optimal values of the verification parameters at time t;
[0088] S7. Calculate the corresponding optimal covariance according to the optimal value of the calibration parameter;
[0089] S8. For the calculation of the optimal value and its covariance of the calibration parameter at time t+1, repeat steps S4 - S7.
[0090] In the embodiment of the present invention, the total number of pressure measurement points is NH, and the total number of flow measurement points is NQ. The standard deviation of the pressure measurement points collected according to historical data is σ H = diag[A1, A2, K, A NH , where diag represents constructing a diagonal matrix, and A i (1 ≤ i ≤ NH) represents the standard deviation of the i-th pressure measurement point. The standard deviation of the flow measurement points is σ Q = diag[B1Q1, B2Q2, K, B NQ Q NQ , B j Q j (1 ≤ j ≤ NQ) represents the standard deviation of the j-th flow measurement point, Q j is the monitoring value of the j-th flow measurement point, and B j is the variance percentage of the j-th flow measurement point;
[0091] Group the water demand of nodes according to information such as user remote water meters, water bills, and user distributions. The water consumption change curves of nodes within the same group are the same, and the number of groups is l q , for time t, the water demand fluctuation range of node group l i (1 ≤ i ≤ l q ) is D ti (0 ≤ D ti ≤ 1) is the percentage of Gaussian error. Then the Gaussian standard deviation of the prior water demand of node group l i is Group the pipe friction according to the characteristics of the pipeline (pipe material, pipe age, pipe diameter). The pipe friction within the same group is the same, and the number of groups is l C , the prior friction fluctuation range of pipe section group l Cj (1 ≤ j ≤ l C ) is r j (0 ≤ r j ≤ 1) is the percentage of Gaussian error. Then the Gaussian standard deviation of the friction of pipe section group l Cj is r j Cj; The initial value of the parameter at t = 0 is denoted as qC0, and its corresponding initial error variance can be randomly given a relatively large variance P0 according to the actual situation.
[0092] Furthermore, S4 is specifically:
[0093] S41. Initialize the values of the parameters \(qC0\) and the corresponding covariance \(P0\) at time \(t = 0\);
[0094] S42. Calculate the sampling points \(\chi\) in the prediction stage at time \(t\) fi , and then calculate the predicted parameter value \(qc\) fi and the variance \(P\) t|t-1 according to the sampling points \(\chi\); t|t-1 ;
[0095] S43. Calculate the cubature points \(\chi\) in the measurement stage according to the predicted parameter value \(qc\) t|t-1 and the variance \(P\) t|t-1 , and calculate the predicted measurement value \(HQ\) mi according to the cubature points \(\chi\); mi t|t-1 (qc)(HQ) ;
[0096] S44. Calculate the verification parameters and the measurement covariance \(P\) (qc)(HQ) and the measurement covariance \(P\) (HQ)(HQ) , then calculate the parameter verification value \(qC'\) t and its covariance \(P'\) t .
[0097] Furthermore, S42 is specifically as follows:
[0098] Assume that the estimated water demand of the node group at time \(t - 1\) is \(q\) t-1 , and the friction coefficient of the pipe group is \(c\) t-1 , which are combined and denoted as the parameter state value \(qc\) t-1 , the covariance of the water demand of the corresponding node group is \(P\) q(t-1) , and the covariance of the pipe friction coefficient is \(P\) c(t-1) , which are combined and denoted as the parameter covariance \(P\) t-1 , and then generate the sampling points \(\chi\) of the verification parameters: fi :
[0099]
[0100] where and are the sampling points of the parameters, and each sampling point is a column vector, denoted as \(\chi\) fi , the number of sampling points is \(2n\), \(n\) is the number of parameters to be verified, \(n = l\) q + l C , \(l\) q is the number of node groups, \(l\) C is the number of pipe groups, \(I\) i represents the \(i\)-th column of the identity matrix, and calculate the predicted parameter value \(qc\) fi and the covariance \(P\) according to the sampling points \(\chi\); t|t-1 t|t-1 Calculation of:
[0101]
[0102] In the formula, f(χ fi ) represents the prediction equation of the parameter, F f is a diagonal matrix, and the first l q values on the diagonal are the ratios of the water demand at time t and time t - 1 for the corresponding node groups. For the pipe friction coefficient, since it changes slowly, it is defaulted that the pipe friction coefficients at the previous and current times are the same, that is, the ratios of the pipe friction coefficients at time t and time t - 1 are both 1. That is, the values from the (l q +1)th to the (l q +l C )th on the diagonal are all 1, and U t is the covariance matrix of the prediction process.
[0103] Furthermore, S43 is specifically:
[0104] Calculate the volume points χ mi in the measurement stage:
[0105]
[0106] In the formula, and are the volume points of the parameter. Each volume point is a column vector, denoted as χ mi . The number of volume points is 2n, where n is the number of calibration parameters, that is, n = l q +l C . I i represents the i-th column of the identity matrix. Predict the measured value according to the volume point χ mi :
[0107]
[0108] In the formula, HQ t (χ mi ) is the predicted measured value obtained by substituting the volume point χ mi into the pipe network model.
[0109] Furthermore, S44 is specifically:
[0110] Perform the calculation of the calibration parameter and the measurement covariance P (qc)(HQ) and the measurement covariance P (HQ)(HQ) :
[0111]
[0112] In the formula, R tis the combined covariance matrix of the pressure measurement points and the flow measurement points, σ P is the covariance matrix of the pipeline network pressure measurement points, and σ Q is the covariance matrix of the pipeline network flow measurement points;
[0113] Calculate the parameter state value qC′ t at time t in the first stage and its covariance P t ′:
[0114]
[0115] In the formula, HQ t is the combined column vector of the actual measured values of the pressure measurement points and the flow measurement points at the current moment.
[0116] Furthermore, S5 is specifically as follows:
[0117] S51. Define the target parameter value of the iterative optimization method as the extended matrix based on the empirical information parameter value qC′ t and its covariance P′ t ;
[0118] S52. Derive the iterative calculation formula according to the calculation process of the Levenberg-Marquardt algorithm, and calculate the parameter value of the (i + 1)-th iterative calculation
[0119] S53. Limit the upper and lower limits of the values in the parameter vector of the (i + 1)-th iteration. If it exceeds the upper limit, it is equal to the upper limit; if it is lower than the lower limit, it is equal to the lower limit value.
[0120] Furthermore, S51 is specifically as follows:
[0121] Define the extended vector group:
[0122]
[0123] The extended covariance matrix of the parameters and the measurement points in the objective function is:
[0124]
[0125] In the formula, is the parameter value calculated at the i-th iteration, HQ t is the combined column vector of the measured values of the pressure measurement points and the flow measurement points at the current moment, is the corresponding measured value obtained by substituting the i-th iteration value into the pipeline network model; then the extended objective function matrix based on the empirical information is defined as:
[0126]
[0127] In the formula, V t , Y t , all represent intermediate variables.
[0128] Furthermore, S52 is specifically as follows:
[0129] According to the Levenberg-Marquardt algorithm, the iterative calculation formula for the parameters can be derived as:
[0130]
[0131] In the formula, I is the identity matrix, λ is a very small value to prevent the matrix in the intermediate process from being irreversible, and J HQ represents the Jacobian matrix of the pipe network, Substitute the i-th iteration value into the corresponding Jacobian matrix calculated by the pipe network model, which is the process variable.
[0132] Furthermore, S53 is specifically as follows:
[0133]
[0134] In the formula, represents the water demand node group m at time t, 1 ≤ m ≤ l q , the water demand check value for the (i + 1)-th iteration, and represent the minimum and maximum values of the prior water demand range of node group m, represents the pipe section group s at time t, 1 ≤ s ≤ l C , the friction coefficient check value for the (i + 1)-th iteration, and represent the minimum and maximum values of the prior friction coefficient range of pipe section group s. This step ensures that the checked parameters are all within the prior range, avoiding parameter check values that do not conform to engineering significance.
[0135] Furthermore, the iteration stop condition in S6 is the error of the checked parameter value or i ≥ i max where one of them, ξ is the set error range value, and i max is the maximum number of iterations. Denote the optimal check value of the parameter when the stop condition is reached as qC t ;
[0136] The specific calculation of the optimal covariance in S7 is as follows:
[0137]
[0138] In the formula, P tis the optimal covariance of the verification parameters, is to substitute the optimal value qC of the verification parameters t into the Jacobian matrix obtained by calculating with the pipe network model
[0139] In an embodiment of the present invention, the node water demand and the pipe section friction coefficient of the water supply pipe network of a certain city are verified. The water supply pipe network is as Figure 2 shown, including 2 reservoirs, 349 water demand nodes and 509 pipes, with 11 pressure measuring points and 13 flow measuring points placed; according to the water use characteristics and node positions of the pipe network node water demand, the pipe network is aggregated into 11 groups of node water demand groups, and the pipe section friction is also divided into 11 groups. The grouping results are as Figure 3 shown;
[0140] The standard deviation A of the pressure measuring points of this pipe network i = 0.2 m, the standard deviation percentage coefficient B of the flow measuring points j = 1.5%, the random fluctuation percentage coefficient D of the ratio of the node water demand ti = 10%, the standard deviation percentage coefficient r of the friction error j = 10%. The acquisition time interval of the measuring point data is 15 min, and the monitoring values of 672 time acquisition points in one week are used to verify the verification effect. Since the scale of this pipe network is large, the convergence of the parameters is slow, and if the filtering effect is not good, it will gradually diverge with time. Therefore, the results of the last day of one week are used to calculate the verification error. The verification error of the measuring points is calculated by the mean absolute residual of the pressure measuring points and the average absolute residual percentage of the flow measuring points. For the friction and the node group water demand, the group mean absolute residual percentage is used to calculate the error of the verification parameters.
[0141] In the calculation results, the sequential data assimilation algorithm volume Kalman filter is represented by CKF in the figure, the iterative algorithm Levenberg-Marquardt is represented by LS in the figure, and the two-stage combination algorithm proposed in this paper is represented by CKFLS. The verification process values of the friction parameters calculated by the iterative optimization algorithm are as Figure 4 shown. It can be seen from the figure that the iterative algorithm Levenberg-Marquardt cannot utilize the data of historical moments, so its verification effect is poor, and the time-invariant friction parameters are optimized into time-varying parameters throughout the process. By Figures 5 - 8 comparing the verification results of the measuring points and parameters by the volume Kalman filter and the two-stage verification method of this paper, it can be seen that the two-stage algorithm is better than the volume Kalman filter in both the verification of the measuring points and parameters. The first group with the worst friction verification effect of the volume Kalman filter and the ninth group with the worst verification effect of the node group water demand are used for process description. As Figure 9 and Figure 10From the comparison of the parameter verification process, it can be seen that since the cubature Kalman filter cannot utilize the prior information range and perform iterative calculation of parameters, the parameters diverge as the verification time increases. The verification accuracy of the two-stage verification method proposed in this paper is significantly improved, verifying the effectiveness of this method.
[0142] The various embodiments in this specification are described in a progressive manner. Each embodiment focuses on the differences from other embodiments. For the same and similar parts among the various embodiments, reference can be made to each other.
[0143] The above description of the disclosed embodiments enables those skilled in the art to implement or use the present invention. Various modifications to these embodiments will be obvious to those skilled in the art. The general principles defined herein can be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention will not be limited to these embodiments shown herein, but rather to the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A two-stage verification method for the water demand at the nodes of a water supply pipe network and the friction coefficient of pipe segments, characterized in that, It includes the following steps: S1. Obtain the user water meter, water bill, user group type information, the material, pipe diameter and service time of the pipe section, and the historical fluctuation range of the measured values of the pipe network pressure and flow sensors; S2. Aggregate the water-using nodes with similar characteristics together according to the water-using characteristics and relative positions of the nodes; Group the pipes according to the characteristics of the pipes, and all the pipes in each group have the same friction coefficient; S3. Calculate the covariance matrix of the pressure and flow monitoring points based on the historical fluctuation range of the measured values obtained in S1; S4. Use the sequential data assimilation method to calculate the water demand of the nodes in the first stage and the values of the pipe section friction coefficients at time t and their covariances; S5. Take the parameter values and their covariances in the first stage as empirical values, and perform iterative optimization of the water demand of the nodes and the pipe section friction coefficients in the second stage within the range of the prior information of the parameters based on the iterative optimization method of empirical information; S6. Judge whether the value of the verification parameter meets the iteration stop condition. If not, repeat steps S5 and S6. If it meets, stop the iterative calculation and output the optimal value of the verification parameter at time t; S7. Calculate the corresponding optimal covariance according to the optimal value of the verification parameter; S8. For the calculation of the optimal value and its covariance of the verification parameter at time t + 1, repeat steps S4 - S7.
2. The two-stage checking method for the water demand at the nodes of the water supply pipe network and the pipe section friction coefficient according to claim 1, characterized in that Specifically, S4 is as follows: S41. Initialize the values of the parameters qC0 and the corresponding covariance P0 at time t = 0; S42. Calculate the sampling point χ at the prediction stage at time t fi , and then calculate the predicted parameter value qc fi based on the sampling point χ t|t-1 and the variance P t|t-1 ; S43. Calculate the volume points χ in the measurement stage based on the predicted parameter value qc t|t-1 and the variance P t|t-1 , and calculate the predicted measurement value HQ mi based on the volume points χ mi ; t|t-1 S44. Perform the calculation of the verification parameters and the measurement covariance P (qc)(HQ) and the measurement covariance P (HQ)(HQ) to calculate the parameter verification value qC' t of the first stage and its covariance P t '.
3. The two-stage checking method for the water demand of the water supply network node and the pipe section friction coefficient according to claim 2, characterized in that, Specifically, S42 is as follows: Assume that the estimated water demand of the node group at time t-1 is q t-1 , the friction coefficient of the pipe section group is c t-1 , combined and denoted as the parameter state value qc t-1 , the covariance of the water demand of the corresponding node group is P q(t-1) , the covariance of the pipe section friction coefficient is P c(t-1) , combined and denoted as the parameter covariance P t-1 , then generate the sampling point χ of the verification parameter fi : In the formula, and are sampling points of parameters. Each sampling point is a column vector, and the column vector is denoted as χ fi . The number of sampling points is 2n, where n is the number of parameters to be verified, and n = l q +l C , l q is the number of node groups, and l C is the number of pipeline groups. I i represents the i-th column of the identity matrix. According to the sampling point χ fi , the parameter value qc t|t-1 and the covariance P t|t-1 are calculated as follows: where f(χ fi ) represents the prediction equation of the parameter, F f is a diagonal matrix, and the first l q values on the diagonal are the ratios of the water demand at time t and time t - 1 for the corresponding node groups. For the pipe friction coefficient, since it changes slowly, it is defaulted that the pipe friction coefficients at the previous and current times are the same, that is, the ratios of the pipe friction coefficients at time t and time t - 1 are both 1, which means that the values from the (l q +1)-th to the (l q +l C )-th on the diagonal are all 1, and U t is the covariance matrix of the prediction process.
4. A two-stage verification method for the water demand at the nodes of a water supply pipe network and the pipe friction coefficient, according to claim 2, characterized in that Specifically, S43 is as follows: Calculate the volumetric point χ in the measurement phase mi : In the formula, and are volume points of parameters. Each volume point is a column vector, denoted as χ mi . The number of volume points is 2n, where n is the number of verification parameters, i.e., n = l q +l C , and I i represents the i-th column of the identity matrix. Based on the volume point χ mi , the measurement value is predicted: where, HQ t (χ mi ) is the predicted measured value obtained by substituting the volume point χ mi into the pipe network model.
5. A two-stage verification method for the water demand at the nodes of a water supply pipe network and the pipe section friction coefficient according to claim 2, characterized in that, Specifically, S44 is as follows: Check the calibration parameters and the measurement covariance P (qc)(HQ) and the measurement covariance P (HQ)(HQ) for calculation: where, R t is the combined covariance matrix of the pressure measurement points and the flow measurement points, σ P is the covariance matrix of the pipe network pressure measurement points, and σ Q is the covariance matrix of the pipe network flow measurement points; Calculate the parameter state value \(q_{C}^{\prime}\) and its covariance \(P^{\prime}\) at time \(t\) for the first stage: t and its covariance \(P\) t ′: where, HQ t is the combined column vector of the actual measured values of the pressure measurement point and the flow measurement point at the current moment.
6. The two-stage checking method for the water demand of the water supply network node and the pipe section friction coefficient according to claim 1, characterized in that Specifically, S5 is as follows: S51. Define the target parameter value of the iterative optimization method as the extended matrix of the empirical information parameter value qC′ t and its covariance P t ′; S52. Derive the iterative calculation formula according to the calculation process of the Levenberg-Marquardt algorithm, and calculate the parameter value of the (i + 1)-th iterative calculation S53. Limit the upper and lower bounds of the values in the parameter vector for the (i + 1)-th iteration. If the value exceeds the upper bound, it is equal to the upper bound; if it is lower than the lower bound, it is equal to the lower bound value. 7. A two-stage checking method for the water demand at the nodes of a water supply pipe network and the pipe friction coefficient, according to claim 6, characterized in that, Specifically, S51 is as follows: Define the extended vector group: The extended covariance matrix of the parameters and the measuring points in the objective function is: In the formula, is the parameter value calculated at the i-th iteration, and HQ t is the combined column vector of the measured values of the pressure measurement point and the flow measurement point at the current moment, is the corresponding measured value obtained by substituting the i-th iteration value into the pipe network model; then the extended objective function matrix based on the empirical information is defined as: V t = Y t -Y t i (16) In the formula, V t , Y t , Y t i all represent intermediate variables.
8. A two-stage verification method for the water demand at the nodes of a water supply pipe network and the pipe friction coefficient, according to claim 6, characterized in that, Specifically, S52 is as follows: According to the Levenberg-Marquardt algorithm, the iterative calculation formula of the parameters is obtained as: Where \(I\) is the identity matrix, \(\lambda\) is a very small value to prevent the matrix in the intermediate process from being non - invertible, and \(J\) HQ represents the Jacobian matrix of the pipe network, Substitute the \(i\) - th iteration value into the corresponding Jacobian matrix obtained by calculating the pipe network model, is the process variable.
9. The two-stage verification method for the water demand at the nodes of the water supply pipe network and the pipe section friction coefficient according to claim 6, characterized in that Specifically, S53 is as follows: In the formula, represents the water demand node group m at time t, where 1 ≤ m ≤ l q , the water demand verification value at the (i + 1)-th iteration, and represent the minimum and maximum values of the prior water demand range of node group m, represents the pipe section group s at time t, where 1 ≤ s ≤ l C , the friction coefficient verification value at the (i + 1)-th iteration, and represent the minimum and maximum values of the prior friction coefficient range of pipe section group s. This step ensures that the verified parameters are all within the prior range, avoiding parameter verification values that do not conform to engineering significance.
10. A two-stage checking method for the water demand of water supply network nodes and the pipe friction coefficient according to claim 1, characterized in that, The iteration stop condition in S6 is the error of the calibration parameter value or i ≥ i max where ξ is the set error range value, and i max is the maximum number of iterations. Denote the optimal calibration value of the parameter when the stop condition is reached as qC t ; Specifically, the calculation of the optimal covariance in S7 is as follows: where P t is the optimal covariance of the verification parameter, and t is the Jacobian matrix obtained by substituting the optimal value qC of the verification parameter into the pipe network model.
Citation Information
Cited By
Two-stage water supply network hydraulic model parameter checking method based on graph nerves
CN121118324A
A two-stage water supply network hydraulic model parameter checking method based on graph neural network
CN121118324B
