Optimal Model of Desalination Planning Under Uncertainties in a Water Supply System

A requirement for developing desalination efforts in coastal regions suffering water scarcity is proposed to address the increased water demand and limited traditional water supply. The determination of a plant capacity and water allocation scheme in a multiple-source water supply system, as the first problem in planning desalination under streamflow and water demand uncertainties, remains a challenge. To address this gap, an interval-parameter two-stage stochastic programming model is developed in this study. The first-stage problem is to determine a proper desalination plant capacity, and the second is the development of a water allocation scheme under the uncertainties of natural streamflows, water demands, benefits and economic losses. The objective function is to maximize the net benefit of the system, and the cost function of desalination, including capital and operational costs, implying environmental impact, is linearized within a range of plant capacities to solve the model. The proposed approach is applied to an urban area of Weihai in China to illustrate the validity of the model. The results suggest a capacity of 46 × 103 m3/d in 2030 and 55 × 103 m3/d in 2040. Sensitivity analyses of the parameters indicate that a decrease in the unit price of electricity leads to an increase in the utilization level of desalinated seawater. A complementary relationship was observed between reclaimed water and desalinated seawater, in that a decrease in the use rate of reclaimed water from 0.38 to 0.18 led to a 15% increase in desalinated plant capacity.


Introduction
Increased water demand resulting from rapid socioeconomic development, intensive urbanization and the uneven spatiotemporal distribution of natural water resources raised by climate change contributes to water scarcity and introduces difficulties to water resources planning and management (Milly et al. 2008;Mekonnen and Hoekstra 2016). It is thought that traditional water supply sources (WSSs) will gradually fail to fulfil the increased water demand (Paton et al. 2014;Larsen et al. 2016), and nonconventional WSSs such as diverted water (DW), reclaimed water (RW) and desalinated seawater (DS) are being developed and utilized to alleviate water scarcity (Beh et al. 2015;Amos et al. 2020). Compared to surface WSSs, nonconventional sources have better performance in terms of the stability of water quality and water quantity and are less vulnerable to global warming (Beuhler 2003;Su et al. 2020). Especially in economically developed coastal cities with abundant maritime resources, DS, characterized by a small occupation, a high stability and a high water quality, is a popular water supply alternative (Scarborough et al. 2015;Turner et al. 2016). The points of concern in desalination are a high energy consumption and economic cost, along with other environmental concerns (Heihsel et al. 2019). With the technological progress of desalination technology and the attention given to water scarcity, the energy consumption and cost associated with obtaining DS have continually decreased (Bennett 2011;Bhojwani et al. 2019), and the total capacity of all operating desalination plants in the world reached 92.5 million m 3 /d in 2018 (Qasim et al. 2019;Nassrullah et al. 2020).
Nonconventional supply sources can supplement traditional water supplies but cannot totally replace them due to various factors. For example, DW projects occupy large areas, RW is commonly used for non-potable purposes, and the energy consumption in producing DS is high (Aliewi et al. 2017). Hence, multiple water resources constitute a moderate water supply system and are recommended to be prioritized and developed in an integrated manner to maximize the advantages (Beuhler 2003;Shen et al. 2021). The determination of the proper capacity of a desalination plant is one of the key problems encountered during the development and utilization of DS and should be considered in an integrated water supply system (Hadjikakou et al. 2019;Marlow et al. 2013;Marques et al. 2015).
Numerous approaches for DS supply planning can be found in the literature. Research aimed at the determination of desalination plant capacity in water resources planning has been conducted in coastal areas with strong dependency on DS (Mahmoud et al. 2002). In terms of qualitative analysis, scholars have determined the priorities of different WSSs in a multisource water supply system using, for example, the analytic hierarchy process (Moglia et al. 2012). In terms of quantitative methods, other research has aimed to analyse the capacity and positioning of desalination plants using mathematical optimization methods considering cost and energy consumption (Atilhan et al. 2011;Liu et al. 2011;Herrera-León et al. 2019;Shahabi et al. 2017). The appearance of intelligence algorithms has brought considerable research attention to the problem of water resources planning and water allocation schemes in urban multisource water supply systems (Bhushan and Ng 2016;Matrosov et al. 2015). However, the uncertainties of input data are seldom considered in the literature mentioned above (Paton et al. 2014;Triantafyllidis et al. 2018).
Uncertainties in water supply planning arise from multiple aspects, among which the uncertainties in hydrology and water demand present a challenge to obtaining optimal strategies (Milly et al. 2008;Li and Guo 2015;Hui et al. 2018). Given the uncertainty of future events, if the plant capacity is insufficient, large economic losses would cause water shortages when extreme droughts occur, while the cost of DS would increase if there is overcapacity in desalination. Uncertain optimization methods, such as interval programming (Fu et al. 2017), fuzzy programming (Zhang et al. 2015) and stochastic programming (Erfani et al. 2018), are often used to address these uncertainties. Meanwhile, these methods are also used in the allocation of multiple water resources Li et al. 2018;Dadmand et al. 2020) and agricultural water and land allocation (Cai and Rosegrant 2004;Cai et al. 2016;Chen et al. 2017). To the best of our knowledge, there is no optimization model for DS supply planning in an integrated multisource water supply system considering these uncertainties. The aim of this study is to address this gap and to develop a support tool for decision making regarding the development and utilization of DS.
An interval-parameter two-stage stochastic programming (ITSP) model of optimal desalination plant capacity and a water allocation scheme are developed in this study to support urban water resources planning. A novelty of this model is that the uncertainty in water demands, benefits and economic losses caused by water shortages described as intervals and the uncertainty in streamflow described as a probability distribution are handled by introducing an interval in the two-stage stochastic programming (TSP) model. The objective is to maximize the net benefit of the water supply system considering the energy consumption, economic cost and environmental impact of different WSSs. The nonlinear cost function of DS is linearized within the range of desalination plant capacites to solve the established model through linear programming. Eventually, this model is applied to a case study of desalination planning in Weihai, China.

Methods
In this study, the optimal model for the planning of urban nonconventional WSSs is developed based on ITSP and the cost function of DS. The development process of the model includes five main steps, as follows: Step 1: Analyse the intervals or the distributions of parameters and variables. The yearly water demands of multiple users in the study area were forecast based on predictions of the population, economic situation, and water use levels of users. These parameters are presented as discrete intervals with lower and upper bounds.
Step 2: Fit the production cost function of desalinated seawater. According to the theory of economies of scale and the data associated with desalinated technology and costs in the study area, the production cost function of DS was fitted based on the function proposed by Druetta et al. (2014).
Step 3: Develop the ITSP model. The ITSP model was developed based on the fitted production cost function of DS.
Step 4: Solve the upper-bound submodel. The ITSP model was transformed from a stochastic model into two deterministic models with upper and lower objective functions and solutions. The first-stage decision regarding the plant capacity in the planning period was determined by solving the upper-bound submodel.
Step 5: Solve the lower-bound submodel. The second-stage decision regarding the water allocation schemes of different kinds of supply sources was derived by solving the lower-bound submodel.

Interval-parameter Two-stage Stochastic Programming
The ITSP model was developed based on TSP and interval-parameter programming (IPP) to address dual uncertainties. Uncertainties are presented as discrete intervals in IPP and as probability distributions in the TSP.
TSP was proposed to address future uncertainties (Danzig 1955), the fundamental idea behind which is the concept of recourse (Maqsood et al. 2005). In the TSP, an initial decision is made before future uncertain events occur, and recourse is taken when these uncertainties are later resolved. The initial decision is called the first-stage decision, and the corrective action is called the second-stage decision. In contrast to deterministic models with perfect knowledge of the future and its parameters, scenario-based TSP supports current decisions with a number of future strategies corresponding to each scenario (Cai and Rosegrant 2004). Generally, a common TSP problem can be defined as follows: where f is the objective function; x is the first-stage decision variable before stochastic variable ω is observed; and Q(x, ω) is the optimal solution of the second-stage problem, as follows: where y is the second-stage decision variable corresponding to a certain stochastic variable; q(y, ω) is the objective function; {W( ), h( ), T( )| ∈ Ω} denotes functions of ω; ω corresponding to a probable level p l is assumed to be ω l ; and Eq. (1) could be expressed as follows: Huang and Loucks (2000) introduced an interval-parameter TSP formulation to address both the inherent parameter uncertainty and the difficulty in approximating the uncertainty with appropriate probability distributions. In addition, Eq. (3) can be expressed as the following ITSP formulation using the interval notation: (1) where f ± , x ± , y ± , and ω ± are interval variables with upper and lower bounds, and A decision variable z is introduced to transform the nonlinear model (4) into a linear model. Let x ± have a deterministic value of x − + Δxz, where Δx = x + -x − and 0 ≤ z ≤ 1. Model (4) can be transformed into two deterministic linear models. The upper-bound submodel is as follows: where z and y + l are decision variables; the optimal solutions of model (5) are z opt , y + l,opt , f + opt , and x ± opt = x − + z opt Δx . The lower-bound submodel can be expressed as follows: where y − is the decision variable; the optimal solutions of model (6) are y − l,opt and f − opt . The optimum solutions of the ITSP model are

Cost Function of Desalinated Seawater
Generally, the production cost of DS includes capital expenditure and operation and maintenance expenditure. The former is dependent mainly on plant capacity and desalination technology, and the latter is affected by energy consumption and the utilization ratio. The production cost of DS is considered a variable cost that can be reduced by increasing production efficiency when plant capacity is expanded and increased due to the decreasing marginal benefit when plant capacity reaches a certain level. Therefore, the cost function of DS is expressed as a function of plant capacity and production yield, as follows (Druetta et al. 2014): where CDW is the production cost of desalinated seawater; AF is the amortization factor; g(Cap) denotes the unit capital cost of the desalination plant as a function of plant capacity (Cap); PY represents the production yield; h(Cap, PY) denotes the unit operation and maintenance cost as a function of Cap and PY; IR and L denote the annual interest rate and plant lifetime, respectively; and the values of IR and L are 0.049 and 25 in this paper. The unit capital cost function g(Cap) is expressed as follows (Lapuente 2012;Yu et al. 2017): where α and β are fixed coefficients equal to 0.37 and 0.95; φ denotes the unit capital cost when the plant capacity is equal to Cap0, where the values of φ and Cap0 are 10496 Ұ and 3 × 10 4 m 3 /d, respectively; and ξ is the minimum unit capital cost, which is equal to 6325 Ұ.
The unit operational cost function h(Cap, PY) is as follows: where δ is an empirical coefficient equal to 0.975.

Overall Description of the Study Area
The optimal model was applied in the urban area of Weihai, the central city of the Shandong Peninsula in eastern China. Weihai, an important marine industry base and a tourist city, is located east of the Shandong Peninsula and is surrounded by the Yellow Sea on three sides (see Fig. 1). The urban area of Weihai is composed of two districts, Huancui and Wendeng. The annual average precipitation in Weihai is 770.6 mm, and the precipitation during the flood season from June to September accounts for 71.3% of the annual precipitation. Surface water (SW) resources occupy 37.7% of the annual average precipitation. The uneven spatiotemporal distribution of SW and rivers in the city featuring large gradients result in difficulty in utilizing SW resources. The vulnerabilities of the current urban water supply system make it necessary to develop nontraditional WSSs to ensure water use security. The current WSSs in Weihai include SW, groundwater (GW), DW and a small amount of RW. In this study, RW was assumed to undergo simple treatment and was allocated to users with a lower quality requirement, such as industrial and environmental sectors. It is a typical multiple water source and user system, and the logical relationship between water users and sources is presented in Table 1.
The Mishan reservoir plays a dominant role in the local water supply system, in which water diverted from the Yangtze River and the Yellow River is delivered when droughts occur. The utilization of GW is limited for protection purposes. In accordance with the relative planning report of Weihai, a reverse-osmosis facility is planned to be constructed in Huanchui to address its increased water use demand and land use situation.

Model Development
According to the ITSP, the planning of DS utilization can be described as a two-stage problem: the first-stage problem is to determine an appropriate desalination plant capacity to satisfy water demand during the planning period; the second-stage problem is to generate water supply schemes under multiple uncertainties.
The objective of the optimal model in this paper is to maximize the system net benefits, which can be expressed as Eq. (11). where f ± , W ± , WS ± , and L ± represent intervals of parameters and variables; i, j, and s denote indexes of water sources (i = 1 SW, 2 GW, 3 RW, 4 DW, 5 DS), users (j = 1 household, 2 urban productive, 3 rural household, 4 agricultural) and scenarios (s = 1 wet, 2 normal, 3 dry); CI is the capital cost of a seawater desalination plant, which is a function of Cap; p is the probability of each scenario; W is the water amount supplied from a certain water source to a user; B denotes the benefit of water use; CO is the operation and maintenance costs of water supplies; and L is economic losses caused by water shortage, WS.

Fig. 1 Location and division of Weihai
A decision variable of z is introduced to solve the model by transforming the original stochastic model into two deterministic submodels representing the upper and lower bounds. Let Cap ± have a deterministic value of Cap − + ΔCap·z, where ΔCap = Cap + -Cap − and 0 ≤ z ≤ 1. The upper-bound submodel is as follows: where D is the water demand; WE represents the water supply capacity; WA represents the water availability of water supply sources; k represents the ratio of desalinated seawater to fresh water (k = 3.5 in this paper); and z and W + i,j,s are decision variables of the upper-bound submodel. The optimal solutions are expressed as z opt and W + i,j,s,opt , and the lower-bound submodel is expressed as: The ITSP model can be solved through the above two submodels via linear programming, and the final optimal solutions are:

Data
The base year and the planning years in this study are 2018 and 2030 and 2040, respectively. The main data for ITSP model establishment include the water demand forecast for five water users, the water availability and costs of five WSSs and the benefits and economic losses of water shortages for different water users. Three scenarios were defined based on annual inflows: wet, normal and dry.

Water Demand Forecast
The upper-bound water demand in the planning years was determined according to the water security planning of the Water Supplies Bureau and the Hydrographic Office of Weihai. The lower-bound water demand forecast was performed at the district scale for different water users. The household water demand was determined by multiplying the projected population and average household water demand per capita. The water demand for production was derived by multiplying the projected added value and average unit water consumption of different sectors (Shahabi et al. 2017b). These parameters of the two districts in the planning year were derived by fitting the trends based on the data during 2001-2018. The agricultural water demands, consisting of irrigation and livestock, were determined based on the forecasts of cultivated area, average irrigation water demand per acre in all scenarios, quantity of livestock and average water demand for livestock. These parameters were projected based on the present values of 2018 with an assumed increasing rate over the planning horizon. The water demand intervals are shown in Table 2.

Water Availability
According to the analysis of the historical precipitation and streamflow data in the study area, the probabilities of the wet, normal and dry scenarios are assumed to be 0.2, 0.6 and 0.2, respectively. The available water supply data of the surface reservoirs under different scenarios are shown in Table 3. Other water sources are treated as stable water supplies in this study. The availability of those water sources was determined according to the water resources planning book established by the Water Supplies Bureau of Weihai and the Hydrographic Office of Weihai. The total available DW for Weihai is 102 × 10 6 m 3 in planning years. The GW supply for Huancui is 30 × 10 6 m 3 in planning years, and that for Wendeng is 62 × 10 6 m 3 and 81.96 × 10 6 m 3 in 2030 and 2040, respectively. The installed capacity of RW in Huancui is 98 × 10 3 m 3 /d and 132 × 10 3 m 3 /d in 2030 and 2040, respectively; that in Wendeng is 42 × 10 3 m 3 /d and 57 × 10 3 m 3 /d in 2030 and 2040, respectively. Table 4 shows the unit economic losses for different users when water demands are not satisfied. The economic losses were determined based on economic data and water demand forecasts. The unit loss is larger than the unit benefit; if the water demand is not fulfilled, higher-priced alternatives would be chosen to satisfy the demand, or a reduction in benefit would be caused by a water shortage. Due to the difficulty in obtaining these parameters, the unit economic losses were calculated as the unit benefits multiplied by a coefficient of 1.2. The economic parameters of environmental and ecological users were set as the average level of agriculture.

Cost of Water Supply
The full costs of the water supply from different sources were determined as the sum of the resource cost, supply cost and environmental cost. The full costs of SW, GW, RW and DW are 3.2 Ұ/m 3 , 4.5 Ұ/m 3 , 3.6 Ұ/m 3 and 7.6 Ұ/m 3 , respectively, and the detailed calculation can be found in Zhang et al. (2020). The resource cost and environmental cost of DS are 0.12 Ұ/m 3 and 0.20Ұ/m 3 , respectively. The unit supply cost of DS was determined according to the cost function mentioned above. Then, the cost function was transformed into two linear functions to solve the ITSP model. The interval of plant capacity was first determined: the lower bound was set to 30 × 10 3 m 3 /d based on Cap0, and the upper bound was set to 120 × 10 3 m 3 /d by multiplying the plant capacity derived according to the forecasted water shortage by a coefficient of 1.2. The unit cost of DS includes chemical consumption, membrane consumption, energy consumption, labour cost, maintenance cost and miscellaneous expenses, where the labour and maintenance costs and miscellaneous expenses are assumed to be a linear function of the plant capacity and are included in the capital cost. The new capital cost function CI(Cap), including g(Cap) and a proportion of the operational costs, was linearized within the interval of plant capacity [30,120] as follows: where CI is the annual capital cost of DW, 10 6 Ұ, and Cap is the desalinated plant capacity, 10 3 m 3 /d.

Capacity of Desalinated Plant and Water Strategies
The optimal capacities of desalination plants in the planning years were derived by solving the two deterministic linear submodels, and the optimal capacity was 46 × 10 3 m 3 /d in 2030 and 55 × 10 3 m 3 /d in 2040. The results revealed a larger capacity to fulfil the increasing water demand. As shown in Fig. 2, the SW supply decreases significantly with decreasing flow levels, and the SW supply differs in the three scenarios due to the high uncertainty of streamflow. The GW supply was relatively stable in normal and dry scenarios since the GW in the study area was limited to exact conditions for protective purposes.
(17) CI = 0.6152Cap + 6.3824 The DW supplies accounted for the majority of the total water supply under the dry scenario, especially when the streamflow reached the lower bound. The proportion of water supplied by DW in 2040 declined compared to that in 2030 since the cost of DW was higher than that of RW. The intervals of DS were [16.36, 0] × 10 6 m 3 and [16.36, 16.27] × 10 6 m 3 in 2030 under the normal and dry scenarios, respectively, where the former values in square brackets correspond to the water allocation when the objective value reached the lower bound. The proportion of water supplied by DS increased  in Huancui with the decrease in natural water availability, and the desalinated plant operated at almost full load under the dry scenario. Furthermore, the use of DS is also limited by the ratio of DS and fresh water to protect water supply pipes from erosion. Hence, the integrated optimization of the water strategy in a multisource water supply system is important.

(b)
H UEn I EcH UEn I EcH UEn I EcH UEn I EcH UEn I EcH UEn I Ec

Water Allocation and Risk Analysis
The optimal water allocation schemes in 2030 and the water shortage situation under the three inflow levels are shown in Fig. 3. The desalinated supply was constrained by the amount of fresh water, which resulted in more DS supplied to household users under the dry scenario when solving the upper bound submodel than when solving the lower bound submodel. The water supply of urban productive users was also guaranteed in most scenarios in the two districts, except that a water shortage of [0, 1.21] × 10 6 m 3 was observed under the dry scenario in Wendeng in 2040. The large agricultural water demand in Wendeng and the limited natural water supply under the dry scenario resulted in the high water shortage observed in Wendeng compared to Huancui. In the model, GW availability was determined according to the exploitation and replenishment balance, while a risk for GW overexploitation for irrigation existed. To address this situation, appropriate future development of water saving irrigation technology is important, and the construction of desalination plants in Wendeng is worth consideration to transform the structure of the water supply and fill the gap between the water demand and supply. Meanwhile, since some urban water demand could be satisfied by DS, limited natural water could be allocated to agricultural users to ensure regional water and food security.

System Benefits and Costs of Water Supply
The costs of water supplies, the benefits and losses of water shortages and the net system benefits are presented in Fig. 4 Ұ in 2040, which revealed that the water supply system showed less robustness in 2040. According to the water shortage situation, the economic losses were caused mainly by the agricultural water shortage under the normal scenario and the losses due to water shortages in households and urban productivity under the dry scenario.

Sensitivity Analysis
The cost of energy consumption accounts for over 55% of the operational cost of DS in this model under the condition that the unit price of electricity is 0.6 Ұ/kWh. This price was determined according to the average price of the electricity supplied to the industrial and commercial sectors in Weihai. To assess the influence of the unit electricity price on the results, a series of unit price values were set in the model. The variation in the mean DS use and the average unit price of the water supply are presented in Fig. 5. As the unit electricity price decreased, the mean DS use increased, and the unit price of DS decreased linearly. The variation in the average unit price of the water supply among all water sources barely changed with the variation in the unit electricity price because DS accounted for less than [0.9%, 4.1%] of the total water supply.
The use rate of RW was assumed to be 0.35 in 2030 and 0.40 in 2040 according to RW planning in Weihai. This parameter represents the utilization level, equipped capacity and technology of RW, and the values used in the model are relatively ideal since the use rate of RW in urban productive water was 0.11 in 2018. A series of use rates was set to explore the influence on DS planning. A complementary relationship between the RW supply and the other two nonconventional water supplies is observed in Fig. 5. Furthermore, a larger water shortage of household users occurred in Wendeng under the dry scenario when the use rate of RW decreased further.

Limitations and Further Possible Extensions
This study has some limitations. The cost of different water supplies, excluding that of DS, was considered constant in the model due to data availability and the linear requirement of the model. The nonlinearity of the water supply cost and other parameters, such as the benefit, economic loss caused by water shortage and variable cost of all water supplies, are worth consideration in future research. The ITSP model developed in this study was implemented on yearly scale, and the unevenness of natural streamflow within a year was generalized. Further possible extension of the optimal model of water supply planning could include consideration of the supplement of nonconventional water supplies to natural water supplies under the influence of climate change  and operation of engineering. Factors that could be further considered in future studies include water quality, greenhouse gas emissions, uncertainty in RW use and social acceptance. In addition, in light of the complementary relationship among nonconventional water supplies, the model framework could be extended from desalination to multiple WSS planning.

Conclusion
This study offers a novel approach contributing to urban nonconventional water resources planning and management under uncertainties in water systems by establishing an ITSP model and introducing a linear cost function of DS. The uncertainties in the water supply system, described as discrete intervals and probability distributions, including water demand, water use benefit, economic loss caused by water shortage and water availability of SW resources, were addressed by introducing an interval parameter into a TSP model. The model developed in this study requires no detailed technological data and can be extended to similar coastal regions suffering water scarcity where data of the capital and operational costs of water supplies are available.
Three key insights were obtained by applying the developed model to a realistic case in Weihai, China, where natural water and nonconventional water compose the multiplesource water supply system. From a WSS point of view, this model could find a combined nonconventional water supply scheme with a heightened robustness and more net benefits. Second, when the unit electricity price was lower than 0.5 Ұ/kWh, an obvious increase in DS use was found. The influence of the unit price of electricity on the operation cost of desalination is reflected in the utilization level of DS, and a preferential policy of the unit electricity price contributes to the utilization level of DS. Finally, a complementary relationship was found among nonconventional water supplies, especially between RW and DS, in that a decrease in the use rate of RW from 0.38 to 0.18 led to a 15% increase in desalinated plant capacity. The desalinated plant capacity revealed the high sensitivity of the use rate of RW. This implies the importance of integrated planning and management of nonconventional water supplies, which need further research in the future. Availability of data and material Some or all data that support the findings of this study are available from the corresponding author upon reasonable request.
Code availability Some or all code that supports the findings of this study is available from the corresponding author upon reasonable request.

Conflicts of interest
There are no conflicts of interest.