Anatomy of a Hydrological Model: A case study of the Athi and Tana River Basins Balla Maggero Marine & Oceanography Services. Ngong road 30259 Nairobi. e-mail: nambuye@yahoo.com Abstract: An algorithm is presented for reconstructing historical rainfall from few observation sites within the Athi-Tana river basins (coastal Kenya). The Kalman filter Hydrologic Atmosphere Model (KHAM) algorithm is based on the state-space model that constitutes two modules; the first one for determining the state of the hydrologic phenomena and the system noise, and the second one for determining observation noise. Using observed data from only six locations as input parameters in the KHAM algorithm, both spatial and temporal distribution of the hydrologic state is estimated for the whole basin. On the other hand, it is shown that the KHAM can be a suitable tool for rainfall and flow prediction in the ungaged basins. Verification of this results is made with the actual observations. Keywords: state-space model, system noise, observation noise, Kalman filter, 1 Introduction Inundation of vast alluvial lowlands is a complex process involving local generation of runoff from rainfall or precipitation, flow from surrounding highlands, overbabank, spilling along floodplains channels, and tidal and storm influences near coastlines. The interplay of these processes depends upon the timing of hydrologic events and their alteration by engineered structures. A contributing factor is the intricate geometry of the low-lands themselves, composed of tidal channels, levees, distributory channels, scroll bars, and floodplain lakes. Predicting areas of inundation is limited by inaccuracies of hydrologic routing in areas of low relief and of poor spatial resolution of precipitation data. To asses, forecast and predict hydrologic responses, it is vital to understand how the amount, rate and duration of precipitation are distributed in both space and time. As such it is also a key to improving the specifity, accuracy and reliability of weather/climate forecasts. Precipitation climatology may come to be important as are temperature anomalies in the current debate about climate change and its impact on critical human infrastructures because of those systems’ sensitivity to rapid change (Shuttleworth,1996). Outside of the developed world, hydrologic data are the newly endangered species because of the declining number of ground-based observation sites. It’s obvious that it’s impossible to create models that would reproduce to the perfection the behaviour of nature. For a selected study basin, the accuracy of collected data has the same importance as the model itself. Even when the fastest computers are used, their solutions are only approximation; they cannot cope with the complexity of the world and especially in the ability to capture all the details of the hydrologic system to be modelled. Therefore, data assimilation methods to integrate all the current and potentially available information hold great promise. These methods in hydrology uses algorithms that have been tailored for signal processing, oceanography or meteorology. The models generate an effective simulation for exploring wetland processes and provide quantitative predictions and field interpolation via model physics, which ultimately increase our insight on the processes on the ground (Troch et al., 2003). The Kalman filter is a one most well-known sequential data assimilation scheme. It has been commonly used in stream flow modelling (e.g. Chui and Chen, 1999). Also, some recent studies in assimilating remotely sensed rainfall observations with Kalman filtering reveal that short-term corrected forecast represents improvement over raw model results within a limited spatial domain The objective of this article is to introduce the standard Kalman Filter in its original form (Brown, and Hwang, 1996), herein referred to as the Kalman Hydrologic Atmospheric Model (KHAM) and presents some preliminary results for the Tana-Athi river delta using six gage points. 2. The Probabilistic Model The KHAM method employs a Kalman filter in a linear fashion. It is a mathematical procedure that provides an efficient computational (recursive) method for least square estimation of a system. It does so in a predictor-corrector style (see fig. 1), predicting short-term (from observed to unobserved in both space and time) changes in the state using a state space model. The time update projects the current state estimate ahead in time. The measurement update adjusts the projected estimate by an actual measurement at that time. The state-space constitute two modules, the first being the dynamical (system) model, which expresses the state of hydrologic phenomena, and the other is the observation equation. measurements in y. The weights are determined by the error covariance for the model predicted onto the measurement, the measurement error covariance and the innovation : y - Hf. 4. The KHAM Algorithm Given an initial state estimate f and error covariance estimate Pf, the KHAM algorithm proceeds through the following steps whenever measurement y is provided. Figure 1. The Kalman filter cycle. The dynamic model is governed by the linear stochastic relation: (t +t) = (t) +G (t)…………1 (t) is state vector (rainfall in this case) at time t. The observation equation is expressed as; y(t) = H(t) + v(t)……………..2 y is the observation vector at time t , where random variables (t) and v(t) are white Gaussian noises with zero mean and covariances Q and R, respectively. A, G and H are matrices with appropriate sizes. 5. Study Area 3. The variance-minimizing analysis The model is integrated forward in time and whenever measurements are available, these are used to re-initialise the model before the integration continues. Neglecting the time index the model forecast, and analysis are denoted as f and a respectively. The respective covariances for model forecast, analysis and measurements are denoted Pf , Pa and R. The analysis equations is represented as: a = f + PfHT(HPfHT + R)(y – H f)……..3 the analysis error covariance are given as: Pa = Pf - PfHT(HPfHT + R)-1H Pf……..4 a is determined as a weighted linear combination of the model prediction f and covariances PfHT corresponding to each Figure 2. Map of Kenya and the location of the study area the blue box inside the projected map. within The study area selected for this test of the model and the analysis of rainfall prediction is the coastal Athi-Tana Delta (Kenya) where the two rivers meet the Indian ocean (see fig. 2). The hydrology of this area can best be viewed by examining the drainage patterns of these rivers that extent far from the coastal hinterlands. The Tana discharges an average of 4,000 million cubic metres of freshwater and about 3 million tonnes of sediment into the ocean annually. Before it enters the ocean it gives off a branch which leads to the complex system of tidal creeks, floodplains, coastal lakes and mangrove swamps. Its delta covers some 1,300 km2 behind a 50m high sand dune system, which protects it from the open ocean in Ungwana Bay. In total, the high sediment loads carried by the Tana and Athi rivers are attributable to floods caused by both heavy rains and poor land use practices. Such a high rate of sediment discharge are a threat to marine and coastal ecological biotopes. estimation of rainfall and its consequent mapping. The model is based on the dynamical assimilation of sequences of gage observation from different site points. The application of the KHAM for 4-year run has shown a consistency. The assimilation model falls within the range of values measured 6. Results Figure 2. Autocorrelation of the resulting noises on the ground. Since it is impossible to set up uniform network of rain-gages, algorithms such as the Kalman filter may play a vital role in producing realistic rainfall distributions and filling missing gaps. Therefore, the synergistic use of a modelbased information is now of paramount importance. Indeed, , monthly spatial and temporal distribution of past rainfall estimated is in good agreement with observed data. Figure 1 comparisons of monthly observed and model results for the six station Figure 3 showss the relation between the observed and model results. Except for the third station which is showing some differences during the March to July, the rest depicts a close fit, with the first , second and the fifth revealing a small overestimation. The fourth and the sixth station have an underestimation The observed amplitude variations are not exactly fitted due to considerable noises (residuals). These noises should be random and with a normal distribution. The autocorrelation results are illustrated in Fig. 4 7.0 Summery The Kalman filter discussed here allows Acknowledgment: This work was performed within the framework of the Oceanography & Marine Service of the Kenya Meteorological Department. The author would like to thank Mr. Kibue, with whom they have had many fruitful discussions, and Dr. Chadih for reviewing this manuscript and many constructive comments. References: Brown, R. G., & Hwang, P. Y. C. (1996). Introduction to Random Signals and Applied Kalman Filtering: with MATLAB Exercises and Solutions (Third ed.): Wiley & Sons, Inc. (1996). Chui and Chen: Kalman filtering with real time Application. Springer-Verlag 3rd edition. 1999 McLaughlin,D.,An integrated approach to hydrologic data assimilation: Interpolation, smoothing,and forecasting,Adv.Water Resour.,25, 1275–1286,2002. Reichle,R. H.,D.B. McLaughlin, and D. Entekhabi, Hydrologic data assimilation with the ensemble Kalman filter,Mon.Weath.Rev.,130, 103–114, 2002. Shuttleworth: Macrohydrology-The new challenges for process hydrology . J. Hydrology 100 31-56. 1996 Troch,P.A., C.Paniconi, and D.B. McLaughlin, Catchment- scale hydrological modeling and data assimilation, Adv .Water Resour.,26, 131–217, 2003.