Issues of Heat Supply Quality Improvement Based on Ambient Air Temperature Forecasts and Account of the Heat Supply System Particularity

The paper studies the issues of temperature regimes selection of the heat supply system operation through the shared use of the heat transfer medium, which is heated in the central boiler plant, by a group of consumers. They have different levels of heat consumption with various ways of their connection (directly or through heat exchangers) under the conditions of their variable amount of return heat to the system. The purpose of the work is to develop a technique of the model development for the temperature condition control of a heat supply system, which helps to minimize the temperature deviation from standard temperature under conditions of outdoor air temperature change and inertia of the controlled object. For the achievement of the target goal, the paper suggests an approach based on the use of statistical models and forecasts in control tasks on the base of the optimality criterion. The outcome of using the approach proposed in the article is a model that allows you to determine amount of thermal energy that should be produced to maintain the target temperature values in heating circuits of the district heating system.


INTRODUCTION
Issues of improving the efficiency of the district heating control are faced with a number of the following difficulties and barriers [1]. The first is the need to take into account the type of the heating system of the consumer either with a direct connection to the pipeline or through a heat exchanger. The second is the heat losses and heat transfer associated with connecting points of customers which are their distances from the boiler plant. The third is the contribution to the heat removal of different consumers which may have different characteristics of the energy efficiency and level of heat consumption. Among others are the length and diameter of pipelines, ambient conditions, the number of heating circuits and their characteristics. Building the model by reference to these specific features is a time-consuming task, which is complicated by the impossibility of the performance of experiments, because the heating system in regions with cold winters belongs to life support systems. In such conditions, the study of the system and justification of decision making are possible only on models using statistical data accumulated in registration log books.
Abdur Mazhar et al. in his work [2] gives an overview of district heating systems from which it follows that often systems may require different temperature of the heat transfer medium, a wide variety of structures and loads in terms of consumers, external operating conditions and useful heat transmission factors as well as the whole group of various heat generation systems.
Due to the complexity of the heat supply centralized control system as a subject to control, in the paper [3] the use of intelligent control methods of operating modes, changing the structure of the heat supply system and the location of heat generating facilities as well as transition to low-temperature modes of operation are considered promising. In some cases, changing the structure of the heat supply system includes combining the circuits of different heat generating facilities. Such solutions, as a rule, are expensive, but the use of intelligent systems, in contrast with the change in the structure and principles of heat supply, can be used both in systems with different levels of automation and can be focused on improving operational efficiency of the heat supply system without changing the existing structure of the heat supply system. For example, the paper [4] by Martins Miezis et al., presents a model of the predictive control of a multi-flat building (MFB) heating system, and the paper [5] presents an application of the predicted effect on the subject to control during periods of lowest load on the support systems. The effectiveness of intelligent control systems depends on their operating procedures. In the paper [6], Nora Cadau et al. call attention to the fact that the use of intelligent control methods for solving local control problems is not effective, because it deprives the system of flexibility due to the fact that it leads to the use of information about the past behavior of the system. Using the same predictive control, based on forecasting the future development of the control system, and constant additional training of the model on the incoming data allows you to achieve the necessary flexibility, as well as, as shown in the paper of Gohar Gholamibozanjani et al. [7], to obtain more efficient and economical use of thermal energy. The use of predictive models, as shown by Sven Fielsch et al. in the paper [8] by the example of several premises heating, also allows you to take into account specific features of heated premises.
Claudia Fabbri et al. in the paper [9] draws attention to the complex interaction of the parameters characterizing the heat supply system, and shows that the parameter values directly affect the issues of energy efficiency and comfort. At the same time, attempts are made in personal consumption systems to predict the necessary behavior on the base of machine learning methods. For example, in the paper Katharina Katic et al. [10] user behavior and capabilities of the automatic prediction of user behavior depending on external factors is studied.
Energy efficiency of the heat generating facilities operation depends on the temperature difference between upstream and downstream of the boiler plant. The smaller the temperature drop, the less energy is spent for heating. In the paper [11] it is proposed to transfer heat, generated as a result of the cooling system operation, to the district heating system, and in the paper [12] the influence of various heat sources, giving energy to the district heating system, is analyzed on the system functioning as a whole. In this regard, the presence of direct in cuts into the heat supply system of small buildings and structures should increase energy efficiency. However, if there are objects in the same circuit that consume a large amount of heat, the use of regulators based upon the difference of this temperature becomes ineffective. It's happening because the regulators hold that heat consumption is small and begin to reduce the amount of heat produced in the boiler plant. As can be seen from the above, the implementation of energy efficiency improvement measures on the basis of temperature increase of the heat transfer medium returned to the heat generation system is possible by the use of intelligent control methods of the heat supply system operation. This is also explained by the fact that the system functions under conditions of changeable outdoor environment and heat consumption volumes, that requires adaptation of operating modes of the heat supply system. In this case, the system must remain sustainable [13].
In the case of the district heating system discrete control, good results can be achieved by the use of machine learning methods for building models of the system [14] and using these models for prediction of the system behavior [15]. At the same time, the use of such models is not theoretically justified and analytical models are highly complex and cumbersome, which makes it difficult to apply them in practice. Due to this, attempts are being made to use combined models. The combination of several approaches permits the use of forecasts and statistical models that describe the relationship between system parameters in optimal control problems.

THE PROBLEM STATEMENT
Let us consider the heat supply system shown in Figure 1. The problem faced by the heat energy producer occurs due to the fact that the consumer either does not receive the necessary amount of thermal energy or receives its excess amount. The problem arises as an assessment result of the amount of heat consumed to make a decision on the amount of thermal energy that should be generated to bring the temperature of the heat transfer medium to the standard difference between temperatures of the return heat transfer medium and the heat transfer medium fed into the system. As a result of connecting engineering systems without a heat exchanger with low heat consumption, it becomes impossible to assess the amount of heat consumed by other consumers connected through the central heating station (CHS) in terms of the temperature drop. The problem strongly appears during periods of large outdoor temperature drops.
It is known that the temperature of the heat transfer medium coming from the boiler plant must be in a specific range depending on the ambient air temperature (see Table 1). For this purpose, in the district heating system a high-quality regulation is applied, based on the temperature value, which is necessary to achieve downstream the boiler plant to reach the target temperature value upstream the CHS (Table 1). This temperature is set taking into account losses in heat transfer. This temperature is set with a margin for thermal energy transmission loss without taking into account specific features of the district heating system.
The control task comes down to maintenance of the required inlet temperature in the CHS, which supplies the domestic premises with heat at a level that allows you to maintain the target temperature of the heated space in all circuits. In flow chart the presented in Figure 1, the CHSs, which provide heat to residential estates and follow the regulatory rules, are the CHS#1 and CHS#2. The first one has its own circuit, and the second one is connected downstream of a large number of heat consumers and far apart from the heat producer. Taking into account different configuration of connection with consumers, the temperature level of the heat transfer medium coming to the considered CHSs will be different. In this case the target temperature maintenance will come down to the total error minimization in temperature deviation of the heat transfer medium entering the CHS for each point of time.
The state of the district heating system is described by a set of parameters: {T amb , T tag , T #1,in , T #2,in , Q} (Figure 2), where T amb is the ambient air temperature, T amb (t+1), T tag is the target temperature of the heat transfer medium, Q is the heat output, T #1,in and T #2,in are the temperatures of the heat transfer medium, entering to the CHS#1 and CHS#2.

METHODOLOGY
Let us write the search problem of the system target state: in the form of a problem with an optimality criterion: where m is the number of CHS in which the target temperature must be maintained or the number of heating circuits, is the permissible deviation from the target value of the heat transfer medium temperature in the CHS and is the value of the forecast of ambient air temperature for the next point of time. The particularity of the district heating system affects the relationship between the search values. For the scheme shown in Figure 1 and the amount of heat that must be generated to achieve the target temperature Determination of the required amount of heat Q(t) makes it possible to determine the operation mode of equipment for the state S(t+1) [16]. Taking into account that where is the number of boilers in the boiler plant, the volume of the heat transfer medium and the rate of its supply to the heat supply system are constant, let us write down: where i index is a number of the boiler, C G is the price per a cubic meter of gas, is the amount of gas consumed by i-boiler, Q k#i is the amount of heat generated by i-boiler, T k#i,in is the temperature of the incoming heat transfer medium to i-boiler, ε 2 is the value of the permissible error, is the characteristic function of the equipment unit. The presented problem statement requires the definition of dependencies the generation of which is analytically an extremely time-consuming task due to the complex interaction of heat exchange processes, the inertness of ongoing processes, dependence on the types and brands of equipment used. The availability of statistical data (Figure 3) opens the potential for the construction of these dependencies with the use of statistical methods. In order to do that let us divide the available statistical data into two sets in the ratio of 2/3 to 1/3 [17]. These sets are, accordingly, the data set on which we will train the model and the data set on which we will test the model in order to choose the method that gives the best forecast results.  The values of the desired parameters, as can be seen from the diagram in Figure 3, significantly change themselves at each time step, besides, due to the physical factors of the examined processes, the new values will depend on the previous ones. Under such conditions, the use of models for multiple regression on the base of many members and autoregressive models gives poor results. For this reason, the search of dependencies should be searched on the base of methods such as partial least squares regression (PLS), lasso and machine learning methods. They are applicable to solve regression problems such as k-nearest neighbors algorithm (kNN), support vector machine (SVM) and neural networks. Their use allows us to obtain algorithms describing the output-input dependence on the base of collected statistical data and to correct or check them in the process of new data emergence (to retrain), and, therefore, to take into account features of the system [18].
To test the significance of the models, we will compare the results of prediction y with historical data on the test set. The use of qualitative tests of fit is ineffective for this, because they give a negative result due to the large amount of data. For these reasons it is necessary to use parametric criteria that give a numerical evaluation of the significance of the hypothesis, an assessment of the accuracy or the receiver operating characteristic curve (ROC curve) where n is the number of points in matched test sets. By value of F and the number of degrees of freedom (n -1) we will determine the value of the probability of the hypothesis (p) and make a conclusion about the hypothesis significance. For this purpose it is necessary that p > 0.5. Two hypotheses satisfy this condition: based on the kNN method and Bayesian Regularized Neural Networks (BRNN) method (see Table 2 for the dependence of At the same time p-value for the kNN method is larger, so we will use the models obtained by this method and use it for model refinement. The practical implementation of the solution to the regression problem by way of specified methods was carried out in R language using the Caret Package [20].
When solving the regression problem by the kNN method, the model parameter is the number of the nearest neighboring points k used to obtain new values. For example, if we need to evaluate the value of y 0 at the point x 0 , then we take the values of y closest to x 0 k points and calculate the value The training process comes down to the selection of the k value, which will give the best result [21], for which purpose various methods can be used (for example, the cross-checking method).
Building of the dependence gives the possibility to write the optimal temperature search problem in the following form:  f(T#1,in,T#2,in,Q(t-1)   5. Determination of heat amount Q(t) that must be generated. 7. Providing control action (supply of the determined value Q(t) intothe supply heating system).
8. Time shift t = t -1. 9. Obtaining new response data about the system reaction and addition them to a variety of statistical data. 10. IF ( completion time of the heating season), THEN algorithm halt, OTHERWISE back to step 2.
The only desired variable remains T #1,in (t+1). The presence of a statistical model in the criterion function and in constraints makes it impossible to solve the problem using precise methods. For this reason, it is necessary to use heuristic methods. In case if in the solution of the problem heuristic methods are used or combinatorial methods are supplemented with elements of heuristics, the proof of the completeness of the method used is complicated. The heuristic search methods are mostly incomplete. The obtained problem can be solved with the use of the genetic algorithm, for some modifications of which the finding of the extremum has been proved [22]. In addition, the use of a genetic algorithm allows you, in the absence of a solution, to violate some restrictions, as well as to find a solution under the conditions of a limited time (when inertia of the system is small). The practical implementation of the problem solution is carried out in R language with the use of the R Genoud Package [23], which implements the solution of optimization problems with the help of a genetic algorithm. Entirely obtained model can be represented by the scheme shown in Figure 4, and the sequence of actions while working with it can be represented by the algorithm shown in Figure 5.

RESULTS AND DISCUSSION
For test purposes of the proposed model we will use retrospective data on the functioning of the system to build a model. Then we'll be able to compare the obtained results with the results obtained with the use of the temperature responsive control. It means the control of the difference between temperatures of the heat transfer medium downstream the boiler plant and the return heat transfer medium. During the calculation, the obtained model data will be taken as real and used for the next calculation cycle (see the algorithm in Figure  5). The number of calculation cycles will correspond to the number of records in the test set (there are 113 calculation cycles in our case).
As a result of the model experiment of the algorithm application shown in Figure 4 on the retrospective data constituting the test sample (Figure 1), the proposed approach shows greater efficiency compared to the existing control system. It can be seen from the diagrams that it took place a decrease in the magnitude of the deviations from the target temperature ( Figures  6a, 6b, 6c, 6d), and there is also an effect resulting in saving of the amount of thermal energy produced. The total positive balance (the amount of energy saved) for the period under review was 9572.22469686637 Gcal, which at market price of 1 Gcal in the Russian Federation costs about $ 18.5 per Gcal (in fact, for a boiler plant as a manufacturer, the price per 1Gcal will be less), then the economic effect will be $ 177,086.16 in a period of incomplete four months (from February to May). Reduction of the amount of energy generated (Figure 6f) indirectly affects other efficiency indicators, such as the reduction of CO 2 emissions, efficiency of energy output use and equipment wear. These depend on both the magnitude of the heat energy produced and the error rate leading to more intensive use of equipment and sudden temperature drops in the heat supply system (Figures 6c, 6d).
It is clearly seen in Figure 1 that when using control by temperature drop value of the heat transfer medium in the system, sharp outliers are observed, which are related to the fact that the heat transfer medium with an elevated temperature enters the return circuit. The use of the model proposed in the work excludes such situations, as can be seen from the amplitude of the change in the values of heat generated in Figure 6e.

FME Transactions
The above formalization when considering for one time interval in the future, solves the control problem, but on the other hand it gives the possibility to consider more remote time intervals. It makes it possible to plan the operation of the boiler plant and thus to resource its operation in advance, choose the time for maintenance of equipment depending on thermal energy need. On the other hand, it should be borne in mind that this increases the role of forecasting quality of both temperature and the system behavior. The task uses forecast data that at the present time is accurate for the time interval that is less than one day (inertia of the heat supply system under consideration is one day) and can be used in control tasks. The model combines different types of formalization (the statistical model, the criterion problem statement) and uses the ∆t principle for its operation, where ∆t is a time step equal to the magnitude of inertia of the system. This combination of approaches develops methods of predictive control used for control in heat supply systems [6,24].The presence of the criterion problem statement allows you to perform changes to the criterion function and to supplement the task with new restrictions and by that to find solutions that satisfy the specified key performance indicator (KPI) [25,26]. Consideration of temperature as a target value, which is a variable value with interrelated indicators of the problem (T #1,in and T #2,in parameters), open the potential for solving a whole class of control and planning problems in various problem domains [27,28].

CONCLUSION
The article presents a method for algorithm design for controlling the amount of thermal energy generated to maintain the target temperature value in a district heating system with several circuits and consumers having different connection methods and thermal energy needs. Comparison of the obtained results with the retrospective data has shown the possibility of obtaining the temperature of the heat transfer medium entering the CHS in all circuits (Figures 6c, 6d) closer to the target value. At the same time thermal energy economy and smoother change in thermal energy generation (Figure 5d) is achieved. These effects can be achieved through the use of predicted values of ambient air temperature in the control process and taking into account the specifics of the heat supply system under consideration. For this purpose, a statistical model has been built to find dependencies of temperatures from each other, whose maintenance is necessary at the target level. The task has been set to choose the optimal combination of them by the minimum total deviation from the target values. The resulting model can also be used to control individual heat points when using the desired temperature as a target temperature in a heated space.
Further improvement of the model can be associated with the selection of the amount of statistical data in use to achieve the desired effect in sensitivity of the model to changes in the system behavior. These occurs due to connecting new consumers to the circuits and CHS, wear, change of characteristics during maintenance, etc. Assessing the quality of the statistical model online gives the possibility to select the best method along in case of significant changes in the structure of the system [29]. Apart from that, the model helps to increase the number of controlled interdependent parameters. In particular, during the temperature monitoring of the heat transfer medium, entering and leaving the consumer, it is possible to make allowance for the influence of consumers which transfer excess heat to the district heating system as well as small heat generators. This makes it possible to control heat supply systems of 4 th generation [30].
The implementation of the model described in the article has been put into practice in R language, which opens up the possibility of its use in embedded systems based on real-time operating systems such as Windows IoT, Kaspersky OS, and Unix-based systems. Such opportunities are well combined with the development of the concept of Industry 4.0 and IIoT whereas it is necessary to collect information and because of the capability of operational production control [31].
The proposed approach allows you to take into account the specifics of the system and can be used in control systems in contrast to models and systems that let study heat exchange processes on the base of physical principles. Despite that fact its disadvantage is unavailability for design of new systems and for preliminary impact assessment on the processes of change incurred in the configuration of the heat supply system and boiler plant [32].