Inclusion of flood diversion canal operation in the H08 hydrological model with a case study from the Chao Phraya River Basin – Part 1: Model development and validation

Water diversion systems play crucial roles in assuaging flood risk by diverting and redistributing water within and among basins. For flood and drought assessments, including investigations of the effects of diversion systems on river discharge worldwide, the explicit inclusion of these systems into global hydrological models (GHMs) is essential. However, such representation remains in the pioneering stage because of complex canal operations and insufficient data. Therefore, we 15 developed a regionalized canal operation scheme and implemented it in the H08 GHM for flood diversion in the Chao Phraya River Basin (CPRB), Thailand, which is a complex river network with several natural and man-made diversion canals and has been subject to severe flooding in the past, including recent years. Region-specific validation results revealed that the enhanced H08 model with the regionalized diversion scheme could effectively simulate the observed flood diversion pattern in the CPRB. Diverted water comprises approximately 49% of the 20 annual average river discharge in the CPRB. The simulations further confirmed that the presented canal scheme had the potential to reduce flood risk in the basin by significantly reducing the number of flooding days. A generalized canal scheme with simple input data settings was also constructed for future global applications, providing insights into the maximum level of discharge reduction achievable with diversion of nearly 57% of the annual average river discharge of the CPRB. Overall, the enhanced H08 model with canal schemes can be adapted and applied to different contexts and regions, accounting for the 25 characteristics of each river network by maintaining the basic principles unaltered.

extreme flood events have been approximately tens of billions of US dollars; moreover, thousands of people have lost their lives in floods each year (Hirabayashi et al., 2013). Currently, almost 13% of the global population (around one billion people) lives in floodplains (Di Baldassarre et al., 2013); this population are at risk of exposure to river flooding caused by extreme weather events (Alfieri et al., 2017). These flood issues have been addressed in many areas to a greater extent through the construction of 16.7 million reservoirs with a storage volume of nearly 8000 km 3 (Lehner et al., 2011), along 35 with other flood mitigation measures such as retention areas, afforestation, diversion dams, flood channels, etc.
Climate change may increase the intensity and frequency of extreme flood events and the global population exposed to flooding, thereby enhancing the magnitude of losses and fatalities caused by future floods (Dankers et al., 2014;Hirabayashi et al., 2013;Hirabayashi et al., 2021;Jongman et al., 2015;Prein et al., 2017). This possibility has led to growing concern 40 regarding the capacity of existing measures to manage future extreme flood events. Thus, impact studies of such extreme events are essential for developing suitable adaptation strategies towards a warming climate. For impact assessment of human interactions on flood discharge worldwide, the explicit inclusion of such interactions into global hydrological models (GHMs) is necessary (Bierkens, 2015;Boulange et al., 2021;Nazemi and Wheater, 2015a;2015b). GHMs have been progressively updated to include reservoir operations; water withdrawal and supply for irrigation, domestic, and industrial 45 uses; groundwater dynamics; and seawater desalination (Burek et al., 2020;Ehsani et al., 2016;Hanasaki et al., 2018;Müller Schmied et al., 2021;Pokhrel et al., 2015;Sutanudjaja et al., 2018). However, the representation of water diversion systems remains in the pioneering stage because of complex dynamic canal operations and insufficient data.
Water diversion schemes account for about 14% of total global water withdrawal (540 km 3 ) in 2005 (ICID, 2005). Recently, 50 McDonald et al. (2014) reported that nearly 184 km 3 of water is diverted and moved over a distance of approximately 27000 km annually to meet the water demand in large cities globally. Later, Shumilova et al. (2018) presented the first global inventory of 110 water transfer megaprojects (existing, planned, and proposed) that serve multiple purposes including flood control, irrigation supply, industrial and domestic water supply, hydropower generation, habitat restoration, and navigation.
They revealed that the total volume of water transferred by existing systems was nearly 204 km 3 /year and would increase to 55 1910 km 3 /year after the completion of planned and proposed diversion systems. These findings emphasize the necessity of including water diversion schemes in GHMs, which may otherwise overestimate water stress and flood risk.
In recent years, several authors have noted the impacts of water diversion on the status of water quality and groundwater levels in water supplying and receiving areas (Tang et al., 2014;Wang et al., 2019;Ye et al., 2014). Although water 60 diversion also plays a vital role in controlling floods in the water supplying areas, few attempts have been made to assess the effects of diversion canals on flood risk reduction. For instance, the effectiveness of diversion canals in decreasing floodwater levels was evaluated using the HEC-RAS hydraulic model at Pancoran in the Ciliwung River (Indrawati et al., 2018) and Ciliwung-Cipinang River, Indonesia (Nugroho et al., 2018). In addition, Wang et al. (2019) examined the impacts https://doi.org/10.5194/hess-2021-532 Preprint. Discussion started: 2 December 2021 c Author(s) 2021. CC BY 4.0 License. of inter-basin water diversion on flood control and drainage processes in a water-receiving lake basin in China using the 65 MIKE model. Subsequently, Mel et al. (2020a) identified the optimal floodgate operation rules for diverting floodwater in the Bacchiglione-Brenta River network in Italy using the 2DEF hydrodynamic model; they also evaluated the applicability of those rules (Mel et al., 2020b). The use of hydrodynamic models to simulate floodwater diversion has greatly clarified the effects of such operations on flood risk reduction. However, previous studies have mainly considered the relationships between regional flood characteristics and associated diversion canal operation schemes, which have limited applicability in 70 other regions. Floodwater diversion schemes that can be integrated into GHMs are still lacking, and their impacts on global and regional flood control are relatively unexplored.
Although flood damage is expected to increase globally by the end of the 21 st century, countries in Southeast Asia will experience a particularly severe increase in flood risk (Winsemius et al., 2016). Thailand is the second-largest economy in 75 Southeast Asia, and 58% of all disasters in that country have been generated by floods (JICA, 2015). Floods in Thailand have caused 27% of total disaster-related deaths; the greatest proportion can be attributed to the 2011 flood disaster in the Chao Phraya River basin (CPRB), the largest basin in Thailand. The estimated economic losses from the 2011 flood were approximately USD 46.5 billion (JICA, 2015;Komori et al., 2012;World Bank, 2012). The CPRB has been subject to severe flooding in the past, including in recent years (Komori et al., 2012;Kotsuki et al., 2014;Kure and Tebakari, 2012;80 Watanabe et al., 2014). Recent studies have evaluated the applicabilities of various adaptation strategies, including afforestation (Takata and Hanasaki, 2020) and reservoir operation (Padiyedath Gopalan et al., 2021), for reducing flood risk in the CPRB; they concluded that further adaptation measures are needed to address future floods. Although the CPRB has several natural and man-made diversion canals, their adaptation potential remains largely unknown, because these diversion systems have not been integrated into hydrological models. 85 Therefore, the focus of this study was to develop a flood diversion canal operation scheme for the CPRB that was carefully designed to adapt for future global applications. The scheme developed here was implemented in the H08 GHM for future floodwater management in complex river networks worldwide. The H08 GHM is a pioneering model composed of six modules that explicitly consider numerous human interactions with the hydrological cycle (Hanasaki et al., 2008a;2008b;90 2018). The H08 model has been successfully applied at global and regional scales (Hanasaki et al., 2008b;Masaki et al., 2017;Masood et al., 2015;Mateo et al., 2014). It has considered aqueduct water transfer to represent irrigation water supply (Hanasaki et al., 2018). However, floodwater diversion has not been implemented thus far because of the challenges involved in its implementation. Hence, in this study, flood control was considered as the primary feature of diversion canals because of severe flooding issues in the CPRB, although water diversion systems could function as both floodways and 95 irrigation channels. The diversion system could divert floodwater to a downstream section of the same river; to nearby tributaries within or outside the basin; and to retention areas for temporary storage.
The aim and novelty of this study were the construction of a regional floodwater diversion scheme for the CPRB that is flexible and easily modifiable for future application in any region worldwide. Based on the aforementioned discussions, this study is composed of the following objectives: 100 (i) Develop a floodwater diversion scheme for the CPRB and enhance the H08 GHM by incorporating this scheme into the model. The water diversion scheme includes diversion canals and retention areas to divert and store water, respectively.
(ii) Validate the effectiveness of the enhanced H08 model for reproducing the water diversion process in the CPRB.
(iii) Analyze the impacts of diversion canals and retention areas on flood management in the CPRB.

Materials and methods 105
2.1 H08 model H08 is an integrated global water resources model that consists of six modules: land surface hydrology, river routing, crop growth, reservoir operation, environmental water, and anthropogenic water withdrawal (Hanasaki et al., 2008a;2008b) to quantify natural as well as anthropogenic water availability and use in the past, present, and future. Each of the modules can run separately with spatial and temporal resolutions of 0.5° × 0.5° and 1 day, respectively. The land surface hydrology 110 module is based on a bucket model (Manabe, 1969) that simulates the energy and water balances at the land surface from forcing data. Runoff, the major output from the land surface hydrology module, is then fed into the river routing module, which accumulates the runoff and outputs as streamflow along the river network from upstream to downstream. This module does not account for the effect of water infrastructures and thereby simulates the natural water cycle in cooperation with the land surface hydrology module. Evapotranspiration, another major product of the land surface hydrology module, is used in 115 the crop growth module to estimate global cropping calendars and crop yields. The reservoir operation module follows operating rules for individual reservoirs based on their primary purpose (i.e., irrigation or non-irrigation water supply). The environmental water module receives streamflow estimates from the river routing module and calculates the river flow that should be maintained in the river channel to support the aquatic ecosystem. Finally, the six modules are coupled to run all processes (including anthropogenic water withdrawal) in an integrated manner. In the coupled model, irrigation water 120 demand (simulated by the crop growth module) and streamflow (estimated by the river routing and reservoir operation modules) are utilized to estimate anthropogenic water withdrawal. For a detailed description of the H08 hydrological model, please see https://h08.nies.go.jp/h08/index.html.

H08 model enhancement for flood diversion canals
The latest version of the H08 model enables water abstraction from various water sources (e.g., surface water and 125 groundwater); it explicitly includes groundwater recharge, groundwater abstraction, aqueduct water transfer, local reservoirs, irrigation return flow and delivery loss, and seawater desalination schemes (Hanasaki et al., 2018). These changes transform H08 into one of the most detailed GHMs for attributing different water sources available to human society. However, the https://doi.org/10.5194/hess-2021-532 Preprint. Discussion started: 2 December 2021 c Author(s) 2021. CC BY 4.0 License. model still lacks representation of floodwater diversion systems; the implementation of this representation will provide viable adaptation scenarios towards a warming climate. 130 To overcome this limitation, we enhanced the H08 model by implementing diversion canal schemes. Although the primary objective of diversion canals assessed in this study is flood control, the implemented canal schemes could function as both floodways (offering different routes for excess water flow) and water supply canals (redistributing water from one region to another region that is experiencing water shortage) in future global applications. If flood control is the primary purpose of a 135 canal, the river flow is diverted to the floodway (flood diversion canals) only during the wet season. In contrast, river flow is diverted to water supply canals during the dry season to supply water for various purposes, including irrigation. The schematic diagram of canal operation for the wet and dry seasons are shown in Fig. 1. For multi-purpose canals, river flow is diverted throughout the year to provide water supply during the dry season and flood control during the wet season. Because this study included flood diversion, water supply, and multi-purpose canals in the implemented diversion scheme, this 140 scheme can be applied to any region based on the prevalence of each canal type and the context in which canal operations are needed.
During the dry season, the diversion system operates in a manner such that, if river discharge is greater than the environmental flow requirement ( > ) at the origin, a minimum amount of flow ( ) is diverted from the river 145 channel to the canal system. This operation leads to the emergence of two cases concerning river discharge after diversion ( − ), which are expressed as follows: where is water diversion during the dry season; is minimum flow diversion; is the environmental flow requirement; and is the river discharge at the origin of diversion. These two cases represent low flow scenarios 150 (Supplementary Fig. S1a and b) and can be explained as follows: (i) if the river discharge after diversion − > , then is diverted, and (ii) if the river discharge after diversion − < ; under such circumstances, the remaining river discharge after meeting the environmental flow requirement ( − ) is diverted into the canal. Using these criteria, environmental flow is maintained in both cases. No flow is diverted to the canal if river discharge is lower than environmental flow. After the diversion into canals, a portion of the diverted water (either a fixed percentage or based on the 155 water supply needs including irrigation) is supplied to nearby areas ( ) along its flow route until flow either diminishes to zero or reaches its destination. The surplus water supply that was not completely utilized for irrigation ( During the wet season, diversion canals are designed to divert the floodwater from the main channel. Typically, a flood occurs when river discharge exceeds the river channel carrying capacity. From this perspective, two relevant cases can be identified based on whether river discharge ( ) is greater or smaller than the river channel carrying capacity ( ). Each of these cases includes two sub-cases, leading to the following four cases: retention areas will move toward the destination when the storage capacity of the retention areas becomes full. These retention areas or ponds store water temporarily to reduce the flood peak; thus, they extend flow duration (Tourment et al., 2016). At the end of each year, retention storage is assumed to evaporate ( ) fully and retention storage at the beginning of the following year is assumed to be zero.

180
Flow that is diverted from the main channel into canals eventually splits into four major components, as shown in Fig. 2. The first component is "returned discharge" (A), which is the canal flow returning to destinations such as the downstream section of the same river or nearby rivers or tributaries within the basin. This returned discharge increases flow at the destination and reduces flow at the origin. The second component is "supply to near grids" (B), which is the portion of the diverted water supplied to each grid cell along its flow route. This component is enabled only during the dry season to augment water 185 supply needs. At some point, the diverted water flows to nearby river basins or drains into the sea. This component is designated as "flow out of the basin" (C); it alters the water balance of the river system in question and should be included in water budget analysis to avoid unexplained water imbalance. A portion of the diverted canal flow drains into the retention areas, and the floodwater stored in these areas are called the "retention storage" (D). The storage of floodwater in retention areas is allowed only during the wet season to supplement flood control capacity alongside diversion systems. All of these 190 components can be customized (enabled/disabled) for each basin under consideration.

Input data for canal operations
To conduct canal operations, the following data are needed: (i) Geographic location of the canal: The geographic locations of the canal's origin and destination are needed to identify the donor and recipient systems; this is the minimum information required to proceed further. In addition, the location of 195 the entire canal route enables the identification of areas receiving water from the canal system.
(ii) Location and areal extent of retention areas: The geographic locations of possible retention areas (e.g., ponds, wetlands, and low-lying areas) and their areal extents available for storage of floodwater.
(iii) River channel carrying capacity: The carrying capacity of the river channel at the origin of the canal diversion should be obtained. When river discharge at the diversion point is greater than the carrying capacity, water is diverted into the 200 canal.
(iv) Canal carrying capacity: The carrying capacity of the canal should be noted; this represents the maximum flow that can be diverted under flood conditions.
(v) Minimum flow diversion: A minimal amount of flow is diverted from the river channel to reduce downstream flooding under non-flood conditions in the wet season and supply water during the low flow conditions in the dry season. 205 (vi) Days of diversion per year: Regional wet and dry seasons must be identified to enable the diversion of water under flood, non-flood, and low flow conditions.

Canal operation schemes
A canal diversion scheme that utilizes the observed values of all input data (described in section 2.3) specific to a particular region is described hereafter as the regionalized canal scheme. However, when the model is applied to data-scarce regions 210 and periods, implementation of the diversion system using the input data described in section 2.3 becomes strenuous. In addition, when this diversion scheme is implemented in GHMs for global analysis, extensive data are needed for each river basin, further hampering the application of GHMs. To overcome these difficulties and support the future global application of the canal diversion scheme, we tested the H08 model with simple input data settings that can be derived from river discharge alone (hereafter designated as the generalized canal scheme). 215 The generalized canal scheme is regarded as the preliminary survey for future global applications. In the generalized scheme, the geographic location of the canal, as well as the locations and areal extents of retention areas, should be estimated for the study region in a manner similar to the regionalized scheme. Information regarding canal systems can be collected from peer-reviewed articles, official websites, reports from governmental and non-governmental organizations, and newspapers 220 (Shumilova et al., 2018). Based on this information, the geographic locations of the canal origin, flow path, and destination can be extracted using the Google Earth application. Similarly, low-lying areas, ponds, and lakes can be recognized as retention areas, if present. https://doi.org/10.5194/hess-2021-532 Preprint. Discussion started: 2 December 2021 c Author(s) 2021. CC BY 4.0 License.
The input data for river carrying capacity, canal carrying capacity, and minimum flow of diversion is difficult to collect for all canal systems to support the global application of the model. The river channel carrying capacity ( ) is the 225 maximum flow that a channel cross-section can accommodate. When river discharge exceeds , flooding occurs. This relationship indicates that the at any station is closely associated with the high flow of that cross-section. Therefore, the Q5 value (high flow) derived from pristine flow was used in the generalized scheme to represent . Flow values above Q5 will create flood flow conditions at specified locations, thus requiring the diversion of water from the main channel to reduce flood risk. Additionally, the Q50 value (median flow) is used to illustrate the canal carrying capacity that supports 230 the diversion of the approximate long-term mean daily flow in the generalized scheme. This flow level ensures that a substantial amount of water is diverted to the canal system during floods. Lastly, the minimum flow diversion is represented by the Q90 value, which is a direct indication of low flow. The number of days of diversion is based on the lengths of the wet and dry seasons; therefore, region-specific data are needed under both diversion schemes.

Study area
The diversion canal system was developed for the CPRB, which is the largest river basin in Thailand, with an area of approximately 158,000 km 2 that covers more than one-third of the total area of Thailand (Fig. 3). The CPRB is home to about 30 million people (40% of the country's population) and includes the capital city, Bangkok, which is located at the Chao Phraya River delta. Bangkok contains 50% of the basin's population; generates almost 80% of the basin's gross 240 domestic product; and is the political, commercial, industrial, and cultural hub of Thailand (Bond et al., 2018).
The CPRB is divided into an upper and a lower basin at Nakhon Sawan, (C.2 station) as shown in Fig. 3 (Komori et al., 2012). The upper basin includes four major tributaries (i.e., Ping, Wang, Yom, and Nan) that have headwaters originating from the northern part of the country. The Wang joins with the Ping River and the Yom joins with the Nan River; the 245 subsequent confluence of the Ping and Nan Rivers at Nakhon Sawan is the beginning of the Chao Phraya River. From Nakhon Sawan, the river flows to the lower basin through Bangkok and finally drains into the Gulf of Thailand . Other tributaries (i.e., Pasak and Sakae Krang Rivers) join the Chao Phraya River in the lower basin.
Thailand experiences two seasons: a wet season (May-October) and a dry season (November-April). The rainfall 250 distribution over the basin significantly varies, ranging from 1,000 to 2,000 mm. Nearly 90% of total annual rainfall is received during the wet season, leading to increased flood risk (Bond et al., 2018). The lower basin and downstream parts of the Yom basin have gentle slopes (Fig. 3) and reduced channel carrying capacity; this makes the region highly prone to flooding (Komori et al., 2012). The severe flooding that occurred during the 2011 monsoon season inundated the lower basin https://doi.org/10.5194/hess-2021-532 Preprint. Discussion started: 2 December 2021 c Author(s) 2021. CC BY 4.0 License. and downstream parts of the Yom and Nan Rivers , causing over 800 deaths and substantial economic 255 losses of USD 46.5 billion (World Bank, 2012). To minimize flooding caused by reduced channel carrying capacity and gentle slopes at various locations, the Thai government has implemented measures to protect the CPRB by constructing dams and numerous diversion canals (both natural and man-made).

Canal system 260
The CPRB is a complex river network with several natural and man-made diversion canals, as shown in Fig. 4. These canals are either for flood diversion or multi-purpose; they were implemented to mitigate extreme flood events, protect high-density business and residential areas, and provide irrigation water supply. Water diversion into these canal systems is controlled by barrages installed on the Chao Phraya River. Based on the literature review (JICA, 2013;Tamada et al., 2013) and maps collected from the Royal Irrigation Department (RID) of Thailand, 11 canal systems were identified in the CPRB with direct 265 intakes from the main river channel (Fig. 4). Details of these canal systems are provided in Table 1. Of these 11 canal systems, two are in the Yom basin; flooding is common in that basin because (i) large-scale flow regulating structures are absent, (ii) the downstream area exhibits a gentle slope, and (iii) various locations have low channel carrying capacities. To alleviate these issues, two diversion canals have been implemented to divert water from the Yom River to the Nan River, downstream reaches of the Yom River, and nearby low-lying paddy fields during floods (Fig. 4a). 270 The remaining nine canal systems are in the lower CPRB, where flood hazards are frequent because the channel's carrying capacity progressively decreases from Nakhon Sawan (C.2 station) to Ayutthaya (C.35 station) as shown in Fig. 4b. To reduce downstream flooding near Ayutthaya, the Chao Phraya diversion dam on the Chao Phraya River allocates water to multiple canals (i.e., Chainat-Pasak, Makham Thao-Uthong, Tha Chin, Noi, and Chainat-Ayutthaya), immediately upstream 275 of the diversion dam (canals 3-7, respectively, in Fig. 4b). Among these five canals, the Tha Chin River is a major distributary of the Chao Phraya River that flows through Bangkok and drains into the Gulf of Thailand. This river is considered as a canal system because of its ability to carry floodwater away from the Chao Phraya River. Similarly, the Noi River, which diverts water from the main channel, is considered as a diversion canal. Together, these 5 canals limit flow to approximately 2840 m 3 /s at the Chao Phraya diversion dam (Fig. 4b). Downstream of the Chao Phraya Dam, the Lopburi 280 River splits off from the Chao Phraya River after receiving surplus water; it then joins the Pasak River. The Lopburi River has one short tributary, the Bang Kaeo River, which originates from the Chao Phraya River. These two canal systems together control floods between Sing-Buri and Ang-Thong. Finally, the Phong Pheng and Bang Ban canals divert water from the main channel to reduce the flow at Ayutthaya; they then join the Noi River, which subsequently recombines with the Chao Phraya River at Bang-Sai.  Table 1).
However, the gravity transfer of water occurs at the origins of the Phong Pheng and Bang Ban canals.
Timely diversion of flood flows from the main channel is essential for controlling flooding downstream of the lower CPRB, which is a flood-prone area affected by strong tides. Therefore, two questions arise at the time of diversion: when to divert 295 and how much water to divert. Whenever river discharge exceeds the channel carrying capacity at the origin of a diversion canal, an amount no greater than the canal carrying capacity should be diverted to control flooding. Furthermore, to enable irrigation water supply because canals in the CPRB are solely used to provide water for irrigation and not for other sectors, a minimum flow amount is diverted during the dry season. Table S1 shows the observed river channel carrying capacity, canal carrying capacity, and minimum flow of diversion at the origins of the 11 canal systems (Tamada et al., 2013). 300

Reservoirs
Several dams have been constructed in the CPRB since 1950 to store water from the wet to the dry season, providing flood control and water supply (Bond et al., 2018;Tebakari et al., 2012). Therefore, the Chao Phraya River is highly regulated by existing reservoirs. The GRanD global dam database (Lehner et al., 2011) lists 39 dams in Thailand, in which Bhumibol and Sirikit are the two major reservoirs in the Chao Phraya River. Together, the Bhumibol and Sirikit control approximately 22% 305 of runoff from the basin, with a combined storage capacity of 23 billion m 3 (Bond et al., 2018;Komori et al., 2012). There are six other large-scale reservoirs in the Chao Phraya River system, each with a storage capacity greater than 0.1 billion m 3 .
Detailed information regarding the reservoirs along the CPRB is provided in supplementary material S2.2; reservoir locations in the basin are shown in Figure 4.

Input data sources and assumptions for canal operation in the CPRB 310
Prior to beginning model setup and simulation, the input data required for simulations in the CPRB were finalized for both regionalized and generalized canal schemes, as follows: (i) Geographic location of the canal: The origin, destination, and flow path of each canal system were identified using the Google Earth application and digitized into the H08 model. Both regionalized and generalized schemes employed the same geographic location data for simulations. 315 (ii) Location and areal extent of retention areas: In the H08 model, land grid cells are divided into four sub-cell types: double-crop irrigated, single-crop irrigated, rainfed cropland, and non-cropland (Hanasaki et al., 2008a). Irrigation water https://doi.org/10.5194/hess-2021-532 Preprint. Discussion started: 2 December 2021 c Author(s) 2021. CC BY 4.0 License.
is applied to the irrigation sub-cells to maintain appropriate soil moisture during the cropping period, while no irrigation is supplied to rainfed and non-cropland sub-cells (Hanasaki et al., 2018). In most Southeast Asian countries, rainfed cropland comprises low-lying paddy fields that are natural floodplains and cannot be cultivated during the rainy season 320 because of flooding (Jamrussri et al., 2018). Thus, for the sake of brevity, the areal fraction of rainfed croplands (Siebert et al., 2010) presumedly located near the canal route was regarded as the areal fraction of retention areas for both canal schemes because our region of interest is in a Southeast Asian country. The retention areas modeled under the regionalized scheme were then refined by matching the areal extent of rainfed croplands near the canal networks with the data provided by the RID (geographic location and areal extent of several lowland areas, such as paddy fields, that 325 are currently used as flood retention areas in the basin).
In both schemes, the area of retention ponds in each grid cell was obtained by multiplying the area of that grid cell with the areal fraction of rainfed cropland. Then, this area was multiplied with the depth of water storage (assumed to be 1 m in this study based on recommendations from the RID) to calculate the storage capacity of the retention ponds. The diverted canal flow was assumed to be temporarily stored in these rainfed croplands until their storage capacity was 330 reached. Further details regarding the inclusion of canal systems and retention areas in the H08 model are provided in supplementary material S3.
(iii) River channel carrying capacity: A slightly adjusted version of the observed channel carrying capacity was used for the regionalized canal scheme. Because the simulated streamflow is slightly underestimated, the river carrying capacity was adjusted to avoid overestimation of canal effects. This adjustment was conducted by matching the simulated and 335 observed fractions of river flow that are diverted into the canals during the wet and dry seasons. In contrast, Q5 values derived from natural flow levels at various stations were used for the channel carrying capacity in the generalized canal scheme. Further details are provided in supplementary material S3.
(iv) Canal carrying capacity: Similar to the river carrying capacity, a slightly adjusted version of the observed canal carrying capacity was used in the regionalized scheme, while Q50 values represented carrying capacity in the generalized scheme. 340 (v) Minimum flow diversion: For the regionalized scheme, the minimum flow to be diverted was obtained from historic canal operation data provided by the RID; these flow data were then adjusted. Under the generalized scheme, these data comprised Q90 values, as explained in section 2.4.
Canal water can be supplied to grid cells near the canal flow route based on the water requirement of each grid cell (i.e., 345 supply to near grids). However, for simplicity, 10% of diverted water is supplied to each of the nearby grid cells in this modelling approach that was further utilized for irrigation. A detailed comparison of the two schemes in terms of input data is provided in Table 2.

Model setup and simulations
We previously adapted the H08 model to the calculation domain of 13-20°N and 97-102°E at a spatial resolution of 5 350 arcmins for application in the CPRB (Padiyedath Gopalan et al., 2021). In that model setup, only three modules (land surface hydrology, river routing, and reservoir operation) of the H08 model were enabled. Four key parameters of the land surface hydrology module were derived for the CPRB region by calibrating the model at Nakhon Sawan, while generic operation rules of reservoirs in the global setup were improved by including release rates for the wet and dry seasons, as well as an upper rule curve based on observed historical reservoir operations in the CPRB. The simulations were conducted using the 355 IMPAC-T dataset (Kotsuki et al., 2014), which comprises seven meteorological variables including temperature, specific humidity, short-wave radiation, long-wave radiation, atmospheric pressure, wind speed, and precipitation from 1980-2004.
In that study, we successfully validated river discharge and dam operation in the basin.
For simulations in the present study, we maintained the same model setup for the CPRB, except for model calibration. The 360 H08 model was recalibrated for the CPRB because the present study uses an upgraded version of the H08 model that includes four additional parameters (a total of eight parameters) in the land surface hydrology module, representing groundwater recharge and abstraction (Hanasaki et al., 2018). The eight key parameters of the land surface hydrology module were derived through calibration of the model at Nakhon Sawan. The calibrated parameters and their values are shown in Table S4. Furthermore, five types of discharge simulation were conducted (Table 3) from 1980 to 2004 (total 365 duration of 25 years as follows: (i) naturalized discharge, where all types of water infrastructure were disabled; (ii) regulated discharge, where the reservoir operation module was enabled; (iii) irrigated discharge, where both the reservoir operation module and irrigation water abstraction module were enabled; (iv) regionalized discharge, which is irrigated discharge with the regionalized canal scheme enabled; and (v) generalized discharge, which is irrigated discharge with the generalized canal scheme enabled. Equilibrium for all model state variables was achieved using spin-up calculations. 370 Initially, model calibration and validation were conducted using naturalized discharge, and the efficacy was evaluated based on Nash-Sutcliffe efficiency (NSE; Nash & Sutcliffe, 1970). For model validation, daily river discharge data at various locations in the CPRB (green colour gauging stations in Fig. 4) were collected from the RID. In addition, the capability of the H08 model to reproduce regulated and irrigated discharges at Nakhon Sawan using the calibrated parameters was 375 examined. Regionalized canal operations were calibrated for each diversion canal system to mimic the available observed data provided by the RID. Calibration was conducted by controlling the fraction of river flow to be diverted into the canals during the wet and dry seasons, with reference to the observed fraction of water diverted. Although the wet season ends in October (section 3.1), May-December was regarded as the wet season in this study based on observed reservoir release

Results
The H08 model was calibrated and validated for naturalized, regulated, and irrigated discharges in the CPRB; the results are shown in supplementary material S4.

Validation of seasonal water diversion 385
The observed and simulated fractions of river flow diverted into the canals with respect to a reference gauging station are listed in Table 4 for the wet and dry seasons. For each canal system, the nearest upstream gauging station was used as the reference gauging station (Column 2 of Table 4; Fig. 4) to determine the fraction of water diverted. The regionalized simulation closely agreed with the observed diverted fraction for all canal systems considered during both dry and wet seasons. In the generalized simulation, the diverted fraction was reasonably reproduced at many stations; it substantially 390 differed from the observations at some stations during both seasons. On average, the regionalized and generalized simulations diverted 8.78% and 22.55% of river discharge, respectively, compared with the observed dry-season discharge diversion of 9.25%. The average values of observed, regionalized, and generalized diverted fractions during the wet season were 11.24%, 11.90%, and 11.71%, respectively.

395
Simulated monthly mean canal flows (generalized and regionalized) at 11 canal origins (Table 1)  The H08 model accurately reproduced canal operations in the CPRB under the regionalized canal scheme. Although the primary purpose of the implemented canal scheme was flood control during the wet season (May-December), the model was also able to replicate the diversion pattern during the dry season (January-April). This result reveals that the regionalized canal scheme can also be successfully used to provide water supply during the dry season in addition to the flood control 410 during the wet season.

Breakdown of the diverted canal flow
The four components of diverted canal flow are returned discharge, supply to near grids, flow out of the basin, and retention storage, as described in section 2.2. Fig. 6(a) Table S3). Therefore, nearly 67% and 69% of the retention storage was utilized to store floodwater in the regionalized and generalized schemes, respectively. 435 In practice, water stored in low-lying retention areas of the CPRB (paddy fields) drains into canals and rivers after the flood, thereby creating space for water from upcoming floods in the same year. This process was not considered in the simulations, and the retention areas were assumed to accommodate floodwater only once per year until they became full. Because of this simplification, neither diversion canal scheme was able to reach the observed potential storage capacity (1701 MCM; Table  440 S3). In addition, in the enhanced H08 model, retention areas are modeled such that the retention areas receive runoff in each grid cell; this runoff constitutes a portion of retention pond storage. Therefore, the maximum storage capacity of retention ponds (615 MCM and 935 MCM; Table S3) cannot be utilized for the storage of diverted floodwater. The storage capacity of the retention areas can be increased by changing the maximum water depth based on regional characteristics.

Impact of canal systems on flood control
Initially, the impact of canal systems and retention areas on reducing the annual average discharge of the CPRB was analyzed. Fig. 7 shows discharge in the CPRB for various simulations averaged from 1980 to 2004; the regulated discharge simulation was excluded because of its negligible effect on annual average discharge. The maximum annual average discharge under the naturalized simulation was approximately 850 m 3 /s in the basin, which may lead to devastating impacts 450 in the lower basin, including Bangkok City. A marked reduction in discharge, with values ranging between 500 m 3 /s and 583 m 3 /s, occurred after enabling irrigation water abstraction (Fig. 7b). The impact of water diversion on annual average discharge shows that diversion has a great potential in the lower CPRB ( Fig. 7c and d). In the regionalized simulation, the annual average discharge of the CPRB was approximately 523 m 3 /s, a reduction of 10% from the irrigated simulation. In contrast, the generalized simulation portrayed a reduction of 28% in basin annual average discharge, compared with the 455 irrigated simulation.
Although water diversion occurred from the Yom River to the Nan River, the impact of this diversion on annual average discharge was negligible. Moreover, the effect of this water diversion in the upper basin was nullified at C.2 station, where the Yom and Nan Rivers join. This finding elucidates the need for (i) water diversion systems to divert floodwater from the 460 upper to lower basin, (ii) more retention areas to store floodwater, and (iii) other structural and non-structural measures. average discharge reduction was relatively small because most diverted water was returned to the river channel at some point downstream of the diversion.

480
Overall, both canal schemes reduced the flood risk, bringing the number of flooding days to nearly zero. Therefore, the incorporation of diversion canals in combination with reservoir operation could mitigate historic floods. However, climate change will aggravate the risk of flooding in the basin (Padiyedath Gopalan et al., 2021). In light of future climate change, new approaches combining structural and non-structural measures must be adopted in the CPRB.

Applicability of the generalized canal scheme 485
Although the generalized scheme showed some differences from the observations and regionalized scheme, it was able to identify the general pattern of flow diversion. The combined effect of canal systems in the generalized scheme was identical and comparable with the observations and regionalized scheme during the wet season, even though the effect of individual canals differs (Fig. 5; Table 4). However, it overestimated values during the dry season. Considerable overestimation of simulated canal flow was observed mainly for the Makham Thao-Uthong and Chainat-Ayutthaya canals (Fig. 5) during the 490 wet season. This result was obtained because the main purpose of these canals is irrigation water supply, and they have low observed canal carrying capacities (Table S1). However, the generalized scheme considers the primary purpose of all canals to be flood control (because flood control is the primary objective of this study) and fixes the canal carrying capacity at the Q50 value, leading to the overestimation of canal flow. This generalized scheme can be improved by differentiating the purpose of each canal in the simulations, similar to the approach in the regionalized simulations. 495 The generalized canal scheme was able to produce an annual diversion pattern similar to the annual diversion pattern of the regionalized scheme (Fig. 6); diverted water comprised approximately 57% of the annual average river discharge in the CPRB. Although this result represents a slightly exaggerated discharge reduction scenario compared with the regionalized scheme (wherein 49% of annual average river discharge is diverted), it provides insight into the maximum level of discharge 500 reduction that is achievable by maintaining environmental flow levels in the river channel. The generalized scheme showed a greater reduction of basin-wide annual average discharge, which can be attributed to the (i) increased carrying capacity of canals flowing out of the basin (Fig. S3), and (ii) greater retention area for storage of floodwater (Table S3). This finding reveals that the generalized scheme provides more control over the annual average discharge reduction, compared with the regionalized scheme (Fig. 7). Furthermore, the generalized scheme has a reasonable effect on the flood risk reduction, 505 considerably reducing the number of flooding days (Fig. 8); thus, it can be regarded as the preliminary survey of future global applications using simple input data settings that can be derived from river discharge alone.

Discussion
To our knowledge, this study is the first attempt to include flood diversion canals and retention areas into GHMs for controlling flood risk. The enhanced H08 model with the regionalized canal scheme successfully reproduced the observed 510 flood diversion scenario in the study region. The generalized canal scheme exhibited performance comparable with the regionalized scheme for floodwater diversion. Using existing canal systems, both schemes could divert at least half of the annual average discharge in the CPRB, although some of the diverted discharge gradually returns to the river network. This return flow will increase the subsequent flood risk in downstream areas of the river, although the retention areas will reduce the magnitude of flooding. This finding calls for additional water diversion systems that divert water out of the basin and 515 into nearby basins or the Gulf of Thailand, thereby reducing overall flood risk in the basin (JICA, 2018). Impact assessment of both canal schemes in terms of river discharge revealed that the number of flooding days could be considerably reduced. Therefore, the enhanced H08 model provides a new tool for assessing future adaptation possibilities of the diversion canal systems. However, several uncertainties and limitations remain to be addressed in future studies. The 520 limitations mainly arise from the assumptions made for river channel carrying capacity, canal carrying capacity, minimum flow of diversion, and the areal extent and depth of retention areas in generalized canal scheme simulations. Acquisition of observations and accurate representation of these variables in GHMs remain challenging tasks; this study represents a first step toward developing and incorporating a diversion scheme into the H08 GHM. The robustness of this scheme can be improved by adapting and applying it to different contexts and regions, accounting for the characteristics of each river 525 network while maintaining the basic principles unaltered.

Conclusions
Assessing the impacts of flood diversion canals on flood risk reduction worldwide remains challenging. To overcome this issue, we developed a flood diversion canal operation scheme for the CPRB, a complex river network in Thailand with several natural and man-made diversion canals. The developed scheme was carefully designed and implemented into the 530 H08 GHM for future floodwater management in complex river networks worldwide. A generalized canal scheme was also introduced with simple input data settings that can be derived from river discharge alone for application to data-scarce regions and periods. The major conclusions from this study can be summarized as follows: 1. A regionalized water diversion scheme was developed for the CPRB and incorporated into the H08 GHM to evaluate the effects of floodwater diversion on water-donating and its downstream areas, with the primary purpose of flood 535 management. The validation results show that the diversion scheme can effectively simulate the observed flood diversion scenario in the CPRB. The generalized water diversion scheme with simple input data settings also exhibited comparable performance, especially during the wet season.
2. The major share of the diverted water gradually returns to the destination points under both canal schemes. This indicates that although flood risk is reduced at the point of diversion, some risk remains in the destination area. If 540 retention areas were able to hold more water, flood damage to residential and commercial areas of the lower CPRB could be reduced. This change can be achieved by (i) considering retention areas in irrigated and non-irrigated croplands simultaneously, (ii) assuming that the water from retention areas can be drained into canals and rivers after the floods using pumps; this makes the retention areas available for future floods in the same year, and (iii) increasing the depth of water stored in the retention areas (a depth of 1 m was assumed in this study). 545 3. Water diversion led to a marked reduction in the annual average discharge of the CPRB, which was much greater under the generalized canal scheme than the regionalized scheme. Furthermore, both canal schemes reduced the number of flooding days to nearly zero at most of the gauging stations considered. The overall simulation results indicate that currently implemented canal schemes have the potential to reduce flood risk in the upper and lower CPRB, where many industrial and residential areas are located. However, their abilities to overcome severe flooding should be further 550 evaluated in the context of climate change.
Therefore, we emphasize that the regionalized canal scheme described herein was successfully applied to the CPRB, whereas the generalized scheme requires further validation to evaluate its applicability in other regions worldwide with slight modification. The water diversion rules implemented in the H08 model (during wet and dry seasons) can be easily adapted to 555 different GHMs and should be examined for their applicability. In future research, we will expand upon these schemes for future applications by considering various adaptation scenarios.

Code availability
The source code and operation manual of H08 model is freely available from the following website: https://h08.nies.go.jp/h08/index.html. The code for the diversion canal systems used in this study are available from the 560 authors upon reasonable request.

Data availability
The meteorological data used in study is available from IMPAC-T project website (http://impact.eng.ku.ac.th/cc/). The remaining data that support the findings of this study are available from the authors upon reasonable request.