## Stochastic modeling, control and optimization of district heating systems

Olafur Petur Palsson

AbstractThe present thesis consists of 9 research papers published in the period 1991-1993 together with a summary report. The thesis discusses different aspects in connection with stochastic modeling, control and optimization of district heating systems. The main part of the papers have their background in research projects at The Institute of Mathematical Statistics and Operations Research, entitled "Models and Methods for Optimization of District Heating Systems" and "Operational Optimization of District Heating Systems".

The thesis divides into three parts, where the first part deals with dynamic modeling of heat exchangers, together with estimation of the parameters in these models. The second part is concerned with control of supply temperatures from district heating plants, in particular prediction based controllers for non-stationary systems. The third part treats operational optimal loading and unloading of a heat storage tank, which is connected to a combined heat and power (CHP) extraction plant, and examines the stochastic optimization method applied.

The summary report is initiated by a general description of district heating systems and the relevant components, and a brief description of district heating systems in the Nordic countries. This is followed by summaries of the papers from the three previously mentioned parts.

In papers (A1), (A2), and (A3) modeling of heat exchangers and the parameter estimation in these models are described. The distributed system which the heat exchanger constitutes, is described by a number of sections (compartments) . The models are established as a set of differential equations, which approximate the energy conservation in each section, and where process and observation noise are introduced. This leads to stochastic state space models in continuous time of the outlet temperature from the heat exchanger. The models are made applicable over the whole operation area by using the structure of known empirical relations for the total heat transfer coefficient thereby making it both massflow and temperature dependent. Carrying out the parameter estimation in the time-continuous model formulation means that the parameters are directly physically interpretable, and can therefore be compared with parameters obtained from dimensions of the heat exchanger, physical properties, etc. Models where the influence of the intermediate metal is considered are described in (A1). In this paper the estimation procedure, which minimizes a score function consisting of the sum of the squared one-step prediction residuals of the outlet temperatures, with respect to the parameters, is described. The one-step predictions are obtained by using a standard Kalman filter. In (A2) the main stress is attached to the incorporation of empirical relations, in order to describe the massflow dependence of the heat transfer coefficient, the score function in this paper consists of the multi-step prediction error. Paper (A3) descusses the incorporation of the temperature dependence in the heat transfer coefficient, leading to a model non-linear in the states. In this case an extended Kalman filter is applied.

Optimal control of supply temperature in district heating systems is the main subject of (B1) - (B4). In district heating systems where the heat is produced at a CHP plant it is most economical to keep the supply temperature as low as possible, thereby minimizing the heat losses from the pipes but also reducing the production cost. This is due to the fact that the ratio between electricity and heat is increased with decreasing supply temperature, and since the electricity is more valuable than heat, a more economical operation is achieved . This minimization is subject to some restrictions, such as that the system is to be supplied by the necessary amount of heat, and the consumers require some minimum ambient air dependent supply temperature. The general control concept is described in (B4). Papers (B1) -(B3) discuss controllers for controlling the supply temperature. In (B1) a linear-quadratic controller is investigated, which is based on a cost function that keeps the supply temperature in the network close to the desired temperature, but penalizes large changes in the supply temperature from the district heating plant. In (B2) a modified version of the Generalized Predictive Controller is proposed, the modifications consider, e.g., the non-stationarities seen in district heating systems. This modified controller is applied in connection with supply temperature control in (B3).

A recently developed method for solving stochastic optimization problems is described in (C1). The method is based on scenario analysis where each scenario is assigned with a given probability. The method is called Progressive Hedging Algorithm. The method is tested and analyzed by simple numerical examples. Paper (C2) illustrates how the method described in (C1) can be used in order to find an operational optimal loading and unloading of a heat storage combined with CHP extraction plant. In this paper the future power production is assumed known with some uncertainty, described by a number of scenarios, but the future heat consumption is assumed known. In the paper the Progressive Hedging Algorithm is connected with a receding horizon idea, meaning that the problem can be solved on-line.