Hydrothermal Scheduling in the Continuous-Time Framework

Continuous-time optimization models have successfully been used to capture the impact of ramping limitations in power systems. In this paper, the continuous-time framework is adapted to model flexible hydropower resources interacting with slow-ramping thermal generators to minimize the cost of system operation. To accurately represent the non-linear hydropower production function with forbidden production zones, additional binary variables must be used when linearizing the discharge variables. In addition, the continuity constraints on the individual plants must be relaxed to allow discontinuous jumps in power production. A case study of a hydropower area connected to a thermal area through a controllable high-voltage direct current (HVDC) cable is presented, which shows how the flexibility of the hydropower can reduce the need for ramping by thermal units triggered by intermittent renewable power generation. A reduction of 34% of the structural imbalances in the system is achieved by using the continuous-time model.


I. INTRODUCTION
The Norwegian power system is in an interesting state of transition towards tighter integration to the rest of Europe. New high-voltage direct current (HVDC) cable interconnections to Germany and Great Britain are under construction, which increases the potential of cross-zonal trading of both energy and balancing services. Hydropower dominates the Norwegian generation mix and is well suited to provide system balancing services due to its flexibility. A larger share of intermittent renewable generation means that hydropower will play an increasingly important role in providing flexibility to the interconnected North European system in the future. However, propagating the flexibility across HVDC cables is challenging with current practices related to the hourly day-ahead market structure. According to the Norwegian transmission system operator (TSO) Statnett, changing the HVDC cable flow between areas on an hourly basis has the potential of increasing the structural (or deterministic) imbalances caused by the mismatch in the scheduled hourly production and real-time load [1]. In this paper, a modified version of the continuoustime optimization framework is proposed to impose a smooth and continuous flow of power between a hydropower area and a thermal area connected by an HVDC cable.
Continuous-time optimization was originally used to accurately describe the cost of ramping scarcity in thermal systems with large amounts of renewable power generation, such as the power system in California [2]. Ramping restrictions can be directly applied to the derivatives of the decision variables when they are allowed to be continuous and smooth functions of time instead of the usual piece-wise constant formulation. The continuous-time formulation relies on limiting the decision variables to be polynomials of degree n, which allows the variables to be expressed by the Bernstein polynomials of the same degree. The optimization problem can then be defined in terms of the coefficients of the Bernstein polynomials, which is a mixed-integer linear program (MILP) in the case of the unit commitment problem. The continuous-time framework has lately been expanded in several directions. The existence of a continuous marginal price for the economic dispatch problem was proven and calculated in [3] for a thermal system. This work was later extended to include energy storage devices in [4], which has applications in optimal control of charging electric vehicles according to queue theory [5], [6] and the scheduling of batteries in balancing markets [7]. A stochastic continuous-time model was formulated for unit commitment and reserve scheduling problem in [8], with the inclusion of energy storage in [9] and a method for load estimation and scenario generation in [10]. Applications to other areas within the power system operations field are also emerging, such as the active distribution network model in [11].
Modelling cascaded hydropower in a continuous-time framework requires several alterations to both the standard hydropower scheduling constraints and the usual continuity constraints. The novel contributions of this paper are considered to be the following: • A continuous-time model including hydropower, thermal generation, and HVDC cables is formulated and studied.
To the best of the authors' knowledge, this has not been published previously. • A method for modelling the forbidden production zone of the hydropower production curve in the continuous-time framework is presented. This involves enforcing the continuity constraints on the sum of generated hydropower instead of on the individual plants. • The issue of correct uploading of piece-wise linearized variables in the continuous-time framework is highlighted in relation to the hydropower production function, and a binary variable solution is presented.
Section II presents the novel continuous-time model in detail, which is then solved for a two-area system and compared to a discrete-time model in Section III. Concluding remarks arXiv:1912.06877v1 [math.OC] 14 Dec 2019 are given in Section IV.

II. MODEL A. Fundamentals of a continuous-time model
The core idea of the continuous-time framework is to represent time-dependent input and decision variables as polynomials of time instead of piece-wise constant functions. This increases the complexity of the model formulation, but sub-hourly effects and constraints related to derivatives with respect to time are easily captured. The motivation behind the original continuous-time unit commitment model in [2] was precisely to incorporate the impact of ramping scarcity into the market clearing. The time-dependent decision variables in the typical continuous-time optimization framework are defined through the Bernstein polynomials of degree r, B r (t), which form a basis for any polynomials of at most degree r on the time interval t ∈ [0, 1]. By splitting the time horizon of the model into N intervals h ∈ T of length δ h , the time-dependent decision variables can be expressed as polynomials of the form where and The vectors x h contain the r + 1 coefficients of the Bernstein polynomials in each time interval, which becomes the decision variables of the continuous-time model. One of the main reason for using Bernstein polynomials is the convex hull property, which makes it possible to impose inequality constraints on x(t) for all times t by directly bounding the coefficients x h . In this work, the Bernstein polynomials of the third degree will be used as a basis: This is a popular choice in the literature, as it keeps the size of the model reasonable without sacrificing the ability to model complex time dependencies. Another advantage is the linear relationship to the cubic Hermite splines H(t), which can be used as an equivalent basis: The coefficients of the Hermite splines have a physical interpretation as the value of x(t) and its derivativeẋ(t) at the start and end of the time interval h: This interpretation is useful for expressing the continuity of x(t) across the time intervals h. The reader is referred to [2] for a more detailed introduction to the continuous-time formulation with further references to the properties of the Bernstein polynomials mentioned in this section.

B. Objective function
The objective of the proposed hydrothermal model is to minimize the future expected cost of the system, the penalties for bypassing and spilling water, and the operational, start and stop costs of the thermal generators: Note that start and stop cost are assumed to be negligible for the hydropower plants. The definite integral of the Bernstein polynomials of the third degree is which simplifies the integrals in (7) to the sums

C. Hydropower topology constraints
The cascaded topology constraints dictate how water moves between the reservoirs. These constraints are equality constraints, see for instance [12], which means that equating the polynomial coefficients are sufficient to satisfy them in the continuous-time framework. The convex hull property of the Bernstein polynomials and the fact that 1 T · B 3 (t) = 1 is used to enforce the physical bounds on the variables: There are three waterways that connect reservoirs; discharge through the turbine, the bypass gate and the spill gate. Figure 1 shows the relationship between the different waterways in addition to where natural inflow enters the system.

D. Volume constraints
The rate of change in the reservoir content is described by the differential equation: As shown for general energy storage devices in [4] and [9], the integral relation between Bernstein polynomials of degree three and four: can be used to show that the volume increase within a time Here, t(h) = i<h δ i and the fact that N · B 4 (0) = 0 was used. Note that the volume variables v mh denotes the volume at the start of interval h. Based on equation (20), the following volume balance constraints can be added to the optimization problem: Constraint (21) sets the initial volume of each reservoir and (22) calculates the volume change from one time interval to the next by inserting N · B 4 (1) = 1 4 · 1. Constraint (23) uses the convex hull property to bound the volume within the limits of the reservoir for all times t.

E. Future cost bounds
The future expected cost of the system is represented by a set of Benders cuts created by a hydrothermal long-term model such as [12]. The cost depends on the state of all hydropower reservoirs in the system at the end of the last time interval N : F. Hydropower production The conversion from discharge through the turbine to generated power is a non-linear function which depends on the effective plant head and the efficiency curves of the turbine and generator. This function is usually approximated as a piecewise linear curve in hydropower scheduling models, where the discharge variable is split into n ∈ N m segments with constant efficiency η n . In a discrete time model, the discharge segments will usually be uploaded in the correct order as long as the efficiency is decreasing for increasing segment number. The exception is extreme situations where it is beneficial to dump as much water as possible while limiting the power produced, which can be the case in high inflow and low load scenarios. A similar effect of incorrect uploading of discharge segments has been observed in this work when the continuous-time framework was implemented. Segments with high efficiency are still favoured but there is no guarantee that segment n is at its maximal capacity for all times that segment n + 1 is being used. The model will often start using the next segment too early to be able to fulfill the continuous power balance described in Section II-G. To remedy this problem, binary variables w mn (t) = h∈T w mnh 1 T · B 3 (τ h )Π(τ h ) are used in this work to force the segments to be fully utilized before the next segment can be used: This modelling choice has the unfortunate effect of introducing additional binary variables into the model but also enables the use of non-concave linearizations of the hydropower production function.

G. Power balance and HVDC power flow
The power balance constraints must be satisfied in each node of the system. In this work, each node represents a larger market area assuming no internal power flow limits. The areas are connected with HVDC cables where the flow can be controlled by the system operator. The power balance constraints are formulated as The coefficient G la dictates the positive and negative direction of flow on each cable l ∈ L by taking the values ±1 or zero if cable l is not connected to area a. M a and J a are the sets of hydropower and thermal units located in area a, respectively. The flow on the HVDC cables is constrained by maximal flow limits and additional limitations on the change of flow is imposed on the derivativeḟ l (t) to stay within the specified HVDC cable ramping limits used in the Nordic system [13]. By using the following property of the Bernstein polynomials, the minimum and maximum ramping limits can be expressed as:

H. Thermal generation constraints
The thermal generators are subject to unit commitment decisions which signify if a generator is offline or producing between the minimal and maximal production limits. The thermal unit commitment constraints are modelled by the use of the binary decision variables u j (t): The choice of the commitment decision vector in (34) allows the thermal generator to use time interval h to ramp up from zero to above G min , or conversely ramp down production to zero. The constraints closely follow the formulation used in for instance [2], [8]. The smooth transition is necessary for the continuity constraints that will be applied to the thermal production variables in Section II-J. Constraint (35) captures the starts and stops of the generator, which are accounted for in the objective function (9). Thermal generators can be slow to change their power output, and so ramping constraints are implemented in a similar way as for the HVDC cables in (32): Note that the ramping ability of the thermal generator is increased whenever it is starting up or shutting down production. Minimum and maximum up-and downtime constraints are not considered in this work.

I. Hydropower unit commitment
Due to operating characteristics such as mechanical vibration or loss of efficiency, some hydropower turbines usually have one or several forbidden production regions depending on the turbine type. It is important to model these regions when looking at short-term scheduling of a hydropower system to have an accurate representation of the operating range of the hydropower plants. The unit commitment constraints of the hydropower plants in the continuous-time optimization model must account for the forbidden production region so that the flexibility of the plant is not overestimated. The hydropower unit commitment decisions z m (t) are used to model this in the following way: In contrast to the choice of the thermal unit commitment vector in (34), the formulation in (41) forces the hydropower unit commitment decisions to be constant for the whole time interval so that the production is never between 0 and P min . However, this formulation is in opposition to the normal continuous-time formulation, as discontinuous jumps in power production must be allowed. If not, the hydropower plants will be unable to start and stop at all. These issues are addressed in Section II-J.

J. Continuity constraints
The standard continuous-time optimization framework builds on the C 1 continuity of all decision variables x(t). This requires both the value x(t) and the value of the derivativeẋ(t) to be continuous over the change of time intervals h ∈ T . Such constraints are enforced by using the relationship between the Bernstein polynomials and the cubic spline functions, shown in (5). The interpretation of the coefficients of H(t) described in (6) simplifies the implementation of the C 1 continuity constraints. By labelling the components of the vector x as x[i] for i ∈ {0, 1, 2, 3}, the continuity constraints become: These constraints are applied to the thermal generation and HVDC flow variables:  [1] ∀l, h ∈ L, T \{N }.
As mentioned in Section II-I, discontinuous jumps in power production are required to model the forbidden production region of hydropower plants. Therefore, enforcing the C 1 continuity constraints on the variables related to the hydropower production is not possible. In addition, requiring continuous derivatives for water flow and hydropower production is strict when δ h is longer than a few minutes. To avoid conservative solutions underestimating the ramping capabilities of hydropower, (46) is not implemented for any variable related to hydropower. The bypass and overflow variables are full C 0 continuous and the reservoir volume continuity is already secured by (22). The hydropower production is forced to be C 0 continuous unless a start or stop happens in the time interval. This is modelled by replacing (45) by the two inequalities: which is consistent with the unit commitment constraints imposed in (40) to (44). Note that this relaxation produces a more constrained problem, as production in the forbidden region is impossible. Due to the connection between production and discharge in (26), the discharge variables q s must also be allowed to have discontinuous jumps. However, the binary definitions of the discharge bounds in (27) and (28) take care of continuity when the hydropower plant is producing, so there is no need to apply any further constraints to the discharge variables. The continuity properties of the derived flow variables q net , q out , q in , and q rel are also implicitly accounted for through (10) to (13).
It is important to note that even though the individual hydropower plants may have discontinuous jumps and discontinuous derivatives in the power production curve between time intervals, their sum is still forced to be C 1 continuous. This is automatically satisfied through the power balance constraint (29) since all other quantities in the equation are C 1 continuous. The C 1 continuity constraints of the flexible hydropower have effectively been lifted from the individual plant to the sum on an area level. The hydropower model formulation presented in this paper can be seen as an approximation of a fully C 1 continuous model where short time intervals have been inserted around every major time interval shift. By forcing the hydropower plants to only start or stop in these short intervals, an accurate production profile spending minimal time in the forbidden production zone would be achieved. By letting the length of the short intervals go to zero, the partially C 0 continuous hydropower formulation used in this paper is recovered. Therefore, the alterations made to the continuity constraints for the hydropower related variables will not drastically impact the operation of the hydropower, as long as δ h is long compared to the time it takes to ramp up and down a hydropower plant, which is usually only a few minutes.

III. CASE STUDY
A small scale case study with two areas connected by a single HVDC cable is presented in this section. The continuous model proposed in Section II and an analogous discrete-time model are both solved to show and compare the interaction between fast and slow ramping components in the system. Both models have been implemented in Pyomo and solved with CPLEX 12.8. One area contains only hydropower, while the other only contains thermal generation. The hydropower topology is based on a real Norwegian water course consisting of 12 reservoirs and plants, and the future expected cost of the hydropower system is calculated based on the long-term model described in [12]. The inflow is considered piece-wise constant within each hour in the entire hydropower area, which has a total hydropower production capacity of 537 MW. The thermal area contains four thermal generators with a total of 256 MW of production capacity and varying ramping capabilities and marginal, start and stop costs. The areas are connected by an HVDC cable with a flow limit of 50 MW in either direction. The ramping limitations of the cable are based on the current practice of how fast the flow on an HVDC cable can be changed in the Nordic market, which is 600 MW/h [13]. The flow change is performed in a 20 min window around hourly shifts, which gives an effective ramping rate of 30 MW/min or 1800 MW/h [1]. The time horizon is set to 24 hours with hourly time intervals for both the discrete and the continuous model. The scaled net load profiles for the two areas are shown in Figure 2. The peak net load value in each area is used as a scale in the figure, which is 450 MW and 160 MW in the hydropower and thermal areas, respectively. The net load profiles are based on measured data from NYISO and CAISO from 1/1-2019, available at [14], [15] with a 5minute resolution. The CAISO net load has been used for the thermal area, which experiences significant ramping events in the morning and afternoon as solar plants start and stop producing power. The continuous-time load was calculated from the raw data by a standard least-squares error fit to the Bernstein polynomials, while the piece-wise discrete load is the average hourly load. The structural imbalances in both areas go down in the continuous-time model compared to the discrete model, with a reduction of 34% on system level. This represents 97 MWh of saved balancing energy, which is 0.9% of the total daily net system load. The reduction of imbalances is higher in the thermal area (87%) than the hydropower area (20%) because B 3 (t) provides a better fit to the CAISO load data.
Both models are solved to optimality, meaning that an absolute MIP gap of zero was reached. The continuous-time model is far more time consuming to solve to optimality, though it reaches a MIP gap of 0.28% within one minute. The resulting sum production of hydropower and thermal generators are shown in Figure 3. The figure shows that the discrete model overestimates the ramping capabilities of the thermal system during the extreme ramping events. Thermal production is shut down in the morning and turned back on in the afternoon, while the hydropower producers increase their production to cover the load in both areas in the meantime. This is not the case in the continuous model, as shutting down all thermal generators is either infeasible or very costly when following the net load during the ramping events. The cheapest and slowest thermal generator stays on for the whole 24 hours in the continuous model, contributing to the ramping in a modest way. Most of the ramping is carried out by the hydropower system through the HVDC cable, which can be seen in Figure 4. The figure shows how the hydropower system is able to mitigate the ramping in net load in both directions while keeping the thermal generator online. The power flow is kept close to 50 MW throughout the day in the discrete model since the hydropower is generally cheaper than the thermal generators. However, two major changes in flow occur when the thermal generators are shut down and started back up in the thermal system. This behaviour is undesirable, as it can increase the structural imbalances in the system [1].

IV. CONCLUSION
Hydropower is considered an important balancing resource due to its flexibility. A continuous-time hydrothermal unit commitment model with HVDC cables was formulated in this paper to show how excessive ramping in the thermal system can be avoided by hydropower and active use of the HVDC cables. The structural imbalances in the system are reduced by 34% in the continuous-time model compared to the discrete model since sub-hourly effects are captured by the polynomial expansion. Several modelling issues related to incorporating hydropower into the continuous-time framework have been uncovered in the process. The linearization of the hydropower production curve requires binary variables to avoid unphysical uploading, and modelling the forbidden production zone requires the relaxation of the continuity constraints of the individual hydropower plants. The overall continuity of the model is still preserved on a system level, as the power balance forces the sum of hydropower production to be C 1 continuous. Investigating other potential modelling choices of the hydropower production curve, calculating system prices, and expanding the model to cover cross-zonal reserve capacity procurement are interesting avenues of further research.