Real-time correction method of Muskingum model based on Kalman filter

. In flood forecasting, general flood forecasting models or empirical forecasts reflect the average optimal value or relationship curve under the previous data. However, in the operation forecast, the forecast plan value often deviates from the actual situation. This paper takes Muskingum model as an example, and uses the Kalman filter algorithm to correct the forecast results. The algorithm structure and principles were described detailed, and the numerical simulation test was set to verify the efficiency of the Kalman filter algorithm. The correct results with corrected method were compared. The results indicated that the efficiency of the updating system using Kalman filter algorithm was improved. Conclusively, the proposed method could be widely applied in real-time flood forecast updating.


Introduction
Watershed hydrological system is a very complex natural system. When using the hydrological model for flood forecasting, due to various reasons, the actual situation is that each forecast has more or less errors (Bogner et.al 2008) . Traditional hydrological forecasting methods are difficult to make up for some errors in the actual situation. Real-time forecasting is not appropriate for such considerations that were not considered in the original model, cannot be considered, or even considered, and there is a certain amount of flood estimation (Madsen, 2005). The factors that cause certain errors in the forecast, such as the structure, parameters, state variables, or input values of the model, are considered. In addition to a reasonable and effective model of river basin hydrological forecasting for flood forecasting, a set of reasonable and effective real-time correction techniques is also needed.
The research of traditional real-time correction technology mainly focuses on the improvement of correction methods and correction contents, such as Kalman filter technology (Babovic 2001;Komma, 2008; Trushnamayee 2019) etc. The improvement of research technology has shown obvious results in industrial automatic control and national defense cutting-edge science. The reason is that the former has a large amount of information that can be used, and simple technology cannot be fully utilized (Kidanidis, 1980). When the structure of the correction technology is complicated and the amount of information used is increased, the correction effect is improved. The amount of information on flood forecast errors is only sufficient to provide simple correction technology. Or even the amount of information required for simple correction methods is not enough. For complex correction techniques, the amount of available real-time information has not been increased, and the correction effect naturally cannot be improved. In the real-time flood forecasting system, there are many reasons for the error, and the mechanism that affects the error is very complicated. Although the model calculates the real-time error series, although it contains all the error information, the amount of information that can be distinguished is too small to be able to reach the model parameters, Input errors, etc. Therefore, the expansion of real-time correction information utilization and improvement of utilization technology is the key to real-time flood forecast correction technology.

Algorithm of Kalman Filtering
In the absence of external disturbances, the future state of the dynamic system can be determined based on the current state using a motion equation that describes the dynamic change of the system. Unfortunately, for an actual physical system, it is inevitable that there is some external interference, or people's description of the dynamic changes of the system is not very accurate enough. Therefore, the behavior of any actual physical system can be considered as consisting of two parts: one is predicted from a known equation of motion, and the other is a random component whose mean can be regarded as zero. Such a system can be regarded as a Markov sequence. If the dynamic system is assumed to be linear, its system equations and measurement equations are: Among them,  k represents the linear state equation at time k under the condition of time k-1; Hkis the linear observation equation at time k; X and Y are state variables and measured variables; dynamic noise Wk and measurement noise Vk are A white noise sequence with zero mean, and the two are uncorrelated, that is, for all i and j: Where ij is the Keronecker function, ie let the initial state X0 are a normal random variable, and its statistical characteristics are: The recurrence formula of kalman filtering is: Filtering： State vector error covariance: Filtering error covariance: In addition, the initial filtering value of the recursive algorithm generally includes the first and second moments of the initial state value:

Kalman Filtering for Muskingum Model (KFMM)
The prerequisite for the application of Kalman filtering is that the system must be linear, and river confluence can be viewed as a time-varying linear system in hydrology. The Muskingum model is the only model that can rely on hydrological methods to derive the parameter matrix. The mathematical form conforming to the linear system equations provides the basis for the application of Kalman filtering. Muskingum's matrix solution is as follows: A long reach is used as the research system, which is divided into n sub river sections. For the linear flow calculation, the calculation parameters i K and of each sub river section is equal. For the i-th sub-reach, the Muskingum equation is: It can be found that the expression of the Muskingum matrix equation is a linear dynamic system: 1 1 Based on the Muskingum matrix method, the state equations and measurement equations of the Kalman filter are constructed, and the default initial value 0 X and state vector filter error covariance matrix 0 P is given. The initial values of Q and R can be obtained from the statistical variance of the historical data samples of the actual measurement stations.

Study basin and data
The basin considered in following example is the Tingxia, located in the southeast of China, with a drainage area of 176 km 2 .The climate is relatively humid and belongs to the semi-humid region. From the analysis of observed data, 70% of the mean annual rainfall falls between March and June, while evaporation is greatest between May and September. In this study, 13 years of historical data, 1988-2000, including hourly precipitation, pan evaporation and discharge, were used for parameter calibration while the data between1999 and 2000were used for the parameter validation. Hydrological data are used for calibration and validation of the hydrological model's parameters, including daily and hourly rainfall and runoff and daily evaporation rate. The runoff data are calculated based on the change in the water level of the reservoirs. The rainfall data are obtained from rain gauges near the dams. The daily evaporation data are obtained by using daily evaporation pan data from evaporation station near the dams.

Numerical Results and discussion
In order to confirm the advantage and evaluation of the selected method (KFMM), the performance of the error correction flood forecasting system with KFMM is compared with that uncorrected. 26 flood events during 1988-2000 are used in numerical study. The Nash-Sutcliffe efficiency (NSE), the relative error of peak flow (ΔQm), and the relative error of runoff depth (ΔR) were used as evaluation criteria.
The The detailed results obtained by application of the KFMM, compared with uncorrected is displayed in Table 1. Notes: ΔRu and ΔRc mean the relative error of runoff depth without and with correction; ΔQmu and ΔQmc indicate the relative error of peak flow without and with correction.
Results analysis and discussion: 1. On the whole, the forecast of hydrological element state quantity correction is more accurate than the forecast without correction. Relative errors (ΔR and ΔQm) have been reduced.In particular, the certainty coefficient NSE, which reflects the consistency of the overall process of the sub-flood, has been improved after each flood.
2. However, the peak relative error of some floods increased after correction. The author made a detailed analysis of the Kalman filtering principle and the Muskingum matrix solution to draw the following conclusions: (1) Kalman filtering is mainly corrected by (Equ.4) and Prediction (Equ.5) consists of two major steps. The correction is to use the measured section state value at this moment to correct the outflow value of the upper section, and predict the exit section state value at the next moment based on the corrected outflow value; (2) The state equation of the Kalman filter constructed by the Muskingum matrix solution has input terms and the inflow of each interval; (3) Kalman filtering can only modify the state quantity that can be expressed in a matrix, that is, the section Outflow, it is not possible to modify the interval inflow obtained through the sloping field convergence calculation, and the existence of inflow errors will lead to unsatisfactory Kalman filtering prediction.

Summary and Conclusion
Real-time correction of flood forecast is an important link to improve forecast accuracy. The real-time flood forecasting correction models also have their own advantages and disadvantages. How to combine rich practical experience with modern control theory to develop a real-time correction model suitable for the characteristics of flood forecasting in this area is an important issue for forecasters and also improves the development direction of flood forecast accuracy.
Kalman filtering technology, because of its scientific design ideas and design institutions, is widely used in hydrology. The correction effect of the Kalman filter technology has a certain effect in general, especially the improvement of the NSE. However, due to the existence of interval inflow errors, the correction effect is not particularly significant. Therefore, further research is needed on the applicability of Kalman filters in real-time correction of hydrological models and how to correct interval inflows that cannot be expressed by a matrix.