Performance of a Predictive Model for Calculating Ascent Time to a Target Temperature

The aim of this study was to develop an artificial neural network (ANN) prediction model for controlling building heating systems. This model was used to calculate the ascent time of indoor temperature from the setback period (when a building was not occupied) to a target setpoint temperature (when a building was occupied). The calculated ascent time was applied to determine the proper moment to start increasing the temperature from the setback temperature to reach the target temperature at an appropriate time. Three major steps were conducted: (1) model development; (2) model optimization; and (3) performance evaluation. Two software programs—Matrix Laboratory (MATLAB) and Transient Systems Simulation (TRNSYS)—were used for model development, performance tests, and numerical simulation methods. Correlation analysis between input variables and the output variable of the ANN model revealed that two input variables (current indoor air temperature and temperature difference from the target setpoint temperature), presented relatively strong relationships with the ascent time to the target setpoint temperature. These two variables were used as input neurons. Analyzing the difference between the simulated and predicted values from the ANN model provided the optimal number of hidden neurons (9), hidden layers (3), moment (0.9), and learning rate (0.9). At the study’s conclusion, the optimized model proved its prediction accuracy with acceptable errors.


Introduction
People are now spending around 90% of their time indoors [1]. Therefore, indoor environmental quality (IEQ) has become a significant factor for building occupants' quality of life. Comfort, health, and productivity are affected by IEQ, and it can significantly affect occupant behavior [2]. Properly provided IEQ in commercial buildings can reduce absenteeism rates and employee turnover, and increase productivity. Better IEQ can lead to fewer errors and accidents, and improve product and service quality [3]. In addition, proper IEQ can reduce health hazards [4][5][6][7][8].
Heating and cooling systems account for 58.1% of total energy use in Korean residential buildings [9,10]. Residential thermostats allow occupants to control their setpoint timeframes and temperatures. This allows occupants to manage their personal comfort while reducing energy consumption.
A variety of building control systems using diverse types of energy have been applied to create a comfortable indoor environment. For example, heating and cooling systems, which aim to provide comfortable indoor thermal conditions, primarily account for most of the residential energy consumption. The amount of heating and cooling energy consumption reaches 58.1% of the total energy use in Korean residential buildings [9,10].
For providing comfortable thermal environment in an energy-efficient manner, a variety of theoretical and practical approaches have been studied and applied. The application of the thermostat for heating and cooling systems is one practical example that is widespread as a control method. The thermostat provides a function whereby users can determine their preferable setpoint and setback temperatures and periods. The application of thermostats is expected to provide two principal advantages: (1) improved thermal comfort; and (2) reduced energy consumption [2].
Thermal comfort should be improved for two reasons. The first reason is that the indoor thermal environment can be adjusted to the desired level, and the second reason is that occupants can be psychologically satisfied with having an opportunity to control their thermal environment. In previous studies, occupants expressed increased satisfaction when they could use a thermal control device such as the thermostat to be involved in the thermal control process [11][12][13].
In addition, using a thermostat that employs the setback temperature can save on the energy consumed for the thermal conditioning of the space. The setback temperature can be applied for the day-and nighttime for reducing energy consumption without compromising thermal comfort. In previously conducted experiments, field tests, and computer simulations, a significant energy saving effect of up to 30% for heating and 23% for cooling in residential buildings was reported [14][15][16][17][18][19].
Other types of buildings such as office buildings, hospitals, educational and religious buildings, etc. also achieved remarkable savings in energy consumption for thermal conditioning through the application of energy-conscious thermostats [20,21]. The programmable thermostat was an example of those thermostats, with which occupants could choose normal setpoint and setback temperatures and periods [22].
Advanced strategies for the optimal programming of setback temperature such as adaptive, demand response, and virtual thermostats have been introduced to maximize thermal comfort and increase energy savings [23][24][25][26]. In particular, Yang and Kim investigated a method to determine the optimal start moment of the heating system using an artificial neural network (ANN) model [27,28]. The ANN model was designed to predict the required time for changing the indoor temperature to the desired temperature. Four input variables were employed as input neurons in the ANN model: indoor air temperature, varying rate of room air temperature, outdoor air temperature, and varying rate of outdoor air temperature. Model optimization was conducted for learning rate, momentum, nodes of hidden layer, and use of bias. The optimized model showed statistically meaningful prediction accuracy.
Despite the achievements of this research, two issues still need to be addressed. The first is the selection process for the input variables. In the previous study, the four input variables were selected as input neurons according to the factor analysis affecting room air temperature. However, no statistical analysis on the relationship between the input and output variables was conducted. Thus a simpler model, which excludes input variables having a lesser relationship, could be developed in further study.
The second issue is the optimization process of the model. The objective of the optimization was to find the ANN composition and learning method that would give the most accurate prediction results. For finding the optimized composition and learning method, the parameters to be optimized were tested independently and sequentially. After one factor (e.g., learning rate) was optimized, the next factor (e.g., momentum) was tested, to find the optimal value after fixing the first factor as an optimal value. Thus, an advanced method, such as coupling at least two of the investigated parameters, needs to be considered to provide an overall optimized model.
This study develops an ANN prediction model that calculates the required time to raise indoor temperature during the unoccupied setback period to the designated setpoint temperature for the occupied period (TIME SPT ). The predicted value from the ANN model is used in the control algorithm to compute the optimal end of the setback period.
For example, if the summation of current time of day (TIME CUR ) and predicted time (TIME SPT ) during the setback period reaches the start moment of the normal occupied period, then the setback period is predetermined to actually end before the occupied period begins. As a result, the indoor temperature will rise to the comfort level when the occupied period begins. As the prediction model calculates the optimal moment, it can also reduce the energy that will be consumed for pre-heating unnecessarily early before the normal period.
There are two principal reasons to choose the ANN theory to predict TIME SPT in this study. The first is that the ANN model can adopt input variables flexibly. Unlike fuzzy logic (FL) or adaptive neuro fuzzy inference systems (ANFIS), an ANN model can employ a series of inputs for producing outputs. The second reason is that ANN models have proven their stable prediction accuracy and applicability to building thermal controls in the previous studies. These are summarized in Section 2.1. We therefore selected the ANN model over than other machine learning theories. Figure 1 shows the three major steps followed in this study. The first step was model development. The prediction model using ANN was built with initial composition and learning methods. Statistical analysis of the relationship between the input and output variables was performed to find the input variables that have a strong relationship with the output variable. Input variables with a strong relationship were then used as input neurons of the model. calculates the optimal moment, it can also reduce the energy that will be consumed for pre-heating unnecessarily early before the normal period. There are two principal reasons to choose the ANN theory to predict TIMESPT in this study. The first is that the ANN model can adopt input variables flexibly. Unlike fuzzy logic (FL) or adaptive neuro fuzzy inference systems (ANFIS), an ANN model can employ a series of inputs for producing outputs. The second reason is that ANN models have proven their stable prediction accuracy and applicability to building thermal controls in the previous studies. These are summarized in Section 2.1. We therefore selected the ANN model over than other machine learning theories. Figure 1 shows the three major steps followed in this study. The first step was model development. The prediction model using ANN was built with initial composition and learning methods. Statistical analysis of the relationship between the input and output variables was performed to find the input variables that have a strong relationship with the output variable. Input variables with a strong relationship were then used as input neurons of the model. The next step was model optimization. Model parameters such as the number of number of hidden neurons (NHN), hidden layers (NHL), momentum (MO), and learning rate (LR) were optimized to calculate the most accurate output. Optimization was performed in a coupled fashion, so that a series of NHN and NHL were tested together, followed by a series of MO and LR together. The ANN model employed parameter values for which the model predicted the most accurate output.
The root mean square error (RMSE) between the predicted results (Pi) and the simulated results (Si) was evaluated for each parameter variation. The Pi values were the predicted results from the ANN model, and the Si values were the calculated results from the test module using the MATLAB and TRNSYS software. The values presenting the least RMSE were assigned to the parameters.
The final step was to conduct performance tests on the optimized model. The prediction accuracy of the ANN model was investigated using new data sets. The applicability of the proposed model was presented based on this performance evaluation.
Two major contributions are provided in this study: (1) a method for designing the ANN model and (2) a specific role for the integrated control algorithm. To overcome the limitations of the previous model, this study conducted two steps (the first and second steps in Figure 1) for finding the meaningful input variables and composing the optimal ANN model. In addition, the proposed model will be embedded in the integrated algorithm. This will be introduced in Section 2.3. Flowchart of the Control Algorithm. Three ANN models will be used to determine comfortable thermal environments while saving energy. In particular, the model developed in this study will provide a comfortable thermal environment at the beginning of the normal occupied period minimizing the unnecessary energy consumption.
The development process is presented in Section 2 including previous studies on the predictive controls using ANN in Section 2.1, the flowchart of the control algorithm in Section 2.2, and the artificial neural network model in Section 2.3. The results of the optimized model are described in Section 3, followed by conclusions in Section 4. The next step was model optimization. Model parameters such as the number of number of hidden neurons (NHN), hidden layers (NHL), momentum (MO), and learning rate (LR) were optimized to calculate the most accurate output. Optimization was performed in a coupled fashion, so that a series of NHN and NHL were tested together, followed by a series of MO and LR together. The ANN model employed parameter values for which the model predicted the most accurate output.
The root mean square error (RMSE) between the predicted results (P i ) and the simulated results (S i ) was evaluated for each parameter variation. The P i values were the predicted results from the ANN model, and the S i values were the calculated results from the test module using the MATLAB and TRNSYS software. The values presenting the least RMSE were assigned to the parameters.
The final step was to conduct performance tests on the optimized model. The prediction accuracy of the ANN model was investigated using new data sets. The applicability of the proposed model was presented based on this performance evaluation.
Two major contributions are provided in this study: (1) a method for designing the ANN model and (2) a specific role for the integrated control algorithm. To overcome the limitations of the previous model, this study conducted two steps (the first and second steps in Figure 1) for finding the meaningful input variables and composing the optimal ANN model. In addition, the proposed model will be embedded in the integrated algorithm. This will be introduced in Section 2.3. Flowchart of the Control Algorithm. Three ANN models will be used to determine comfortable thermal environments while saving energy. In particular, the model developed in this study will provide a comfortable thermal environment at the beginning of the normal occupied period minimizing the unnecessary energy consumption. The development process is presented in Section 2 including previous studies on the predictive controls using ANN in Section 2.1, the flowchart of the control algorithm in Section 2.2, and the artificial neural network model in Section 2.3. The results of the optimized model are described in Section 3, followed by conclusions in Section 4.

Previous Studies on the Predictive Controls Using Artificial Neural Network (ANN)
McCulloch and Pitts suggested a computational model ANN that artificially employs the human neural systems and their learning process [29]. Diverse studies have been conducted for developing ANN models that can predict thermal conditions such as indoor temperature and humidity [30] as well as outdoor temperature [31]. In addition, ANN models were proposed to forecast load and energy for building thermal conditioning [32][33][34][35][36]. The values predicted from the ANN model worked as fundamental determinants for controlling building thermal conditions more comfortably and energy-efficiently.
ANN models present the potential to provide comfortable and energy-efficient thermal environments. Moon et al. [2,37] suggested the use of ANN models to control a variety of thermal targets, such as indoor temperature, humidity, and predicted mean vote (PMV) of a residential building. The predicted future thermal conditions from the ANN model were useful to maintain a more comfortable and stable thermal environment. In addition, a variety of heating and cooling systems were controlled by ANN models, including: the hydronic heating system of solar buildings [38,39], radiant heating system [40,41], evaporative condenser [42], absorption chiller system [43], ground coupled heat pump [44][45][46][47], integrated control of heating or cooling systems and the opening of double skin envelope (DSE) buildings [48][49][50][51][52], photovoltaic module efficiency estimation [53], etc. In addition, the collaborative approach that employed several theories, such as ANN and fuzzy logic, presented successful results to supply thermal comfort [40,54]. These studies demonstrated the superiority of ANN methods over conventional mathematical models, such as proportional-integral-derivative (PID) controllers and regression models. Algorithms employing ANN models accurately predict the thermal loads and proper control of heating and cooling systems resulting in more comfortable thermal environments with energy savings.

The Artificial Neural Network Model (ANN)
The ANN model in this study focused on calculating the time (TIMP SPT ) required for the current indoor temperature during the unoccupied setback period to ascend to the target setpoint temperature of the occupied period. Figure 2 shows the flow of the ANN model development process. The ANN model in this study incorporated Transient Systems Simulation (TRNSYS 16.1) software [55] and Matrix Laboratory (MATLAB) [56] programming software. The test module was modelled using the TRNSYS software where data sets for ANN model training, optimization, and prediction performance tests were collected. After completion of the data collection, the ANN model was developed using MATLAB off-line.

Previous Studies on the Predictive Controls Using Artificial Neural Network (ANN)
McCulloch and Pitts suggested a computational model ANN that artificially employs the human neural systems and their learning process [29]. Diverse studies have been conducted for developing ANN models that can predict thermal conditions such as indoor temperature and humidity [30] as well as outdoor temperature [31]. In addition, ANN models were proposed to forecast load and energy for building thermal conditioning [32][33][34][35][36]. The values predicted from the ANN model worked as fundamental determinants for controlling building thermal conditions more comfortably and energy-efficiently.
ANN models present the potential to provide comfortable and energy-efficient thermal environments. Moon et al. [2,37] suggested the use of ANN models to control a variety of thermal targets, such as indoor temperature, humidity, and predicted mean vote (PMV) of a residential building. The predicted future thermal conditions from the ANN model were useful to maintain a more comfortable and stable thermal environment. In addition, a variety of heating and cooling systems were controlled by ANN models, including: the hydronic heating system of solar buildings [38,39], radiant heating system [40,41], evaporative condenser [42], absorption chiller system [43], ground coupled heat pump [44][45][46][47], integrated control of heating or cooling systems and the opening of double skin envelope (DSE) buildings [48][49][50][51][52], photovoltaic module efficiency estimation [53], etc. In addition, the collaborative approach that employed several theories, such as ANN and fuzzy logic, presented successful results to supply thermal comfort [40,54]. These studies demonstrated the superiority of ANN methods over conventional mathematical models, such as proportional-integralderivative (PID) controllers and regression models. Algorithms employing ANN models accurately predict the thermal loads and proper control of heating and cooling systems resulting in more comfortable thermal environments with energy savings.

The Artificial Neural Network Model (ANN)
The ANN model in this study focused on calculating the time (TIMPSPT) required for the current indoor temperature during the unoccupied setback period to ascend to the target setpoint temperature of the occupied period. Figure 2 shows the flow of the ANN model development process. The ANN model in this study incorporated Transient Systems Simulation (TRNSYS 16.1) software [55] and Matrix Laboratory (MATLAB) [56] programming software. The test module was modelled using the TRNSYS software where data sets for ANN model training, optimization, and prediction performance tests were collected. After completion of the data collection, the ANN model was developed using MATLAB off-line.    Four hidden neurons were used in each of the three hidden layers based on the findings of a previous study [52], that proposed four hidden neurons and three hidden layers as the optimal composition to predict the future temperature. The hidden neurons used the tangent-sigmoid transfer function to transfer calculation results in the neuron. Each hidden layer repeats the identical process. Lastly, the output layer employs one output neuron TIMESPT, and uses the pure linear transfer function to produce the final output.
One hundred training data sets were prepared for the training model. Each data set was composed of six input values (TEMPIN, ΔTEMPIN, TEMPOUT, ΔTEMPOUT, TEMPDIF, and SOL) and one output value (TIMESPT). The sliding-window method was used to manage the training data sets. Therefore, when a new data set was acquired, the new set replaced the oldest set. Then training was conducted. The Levenberg-Marquardt algorithm was used for the model training with a 0.0-min goal, 1000-times epoch, 0.2-momentum, and 0.6-learning rate, which were found to be the optimal values by a previous study [57]. Figure 4 shows the test module in which the data sets were acquired and Table 1 summarizes the detailed features of the module. The location of the test module was assumed to be in Seoul, South Korea, where winters are cold and dry. Data sets were collected from 1 November to 28 February.
Typical meteorological year (TMY2) data was used as weather data. Four data sets were collected per day. For example, the setback temperature was applied at 08:00 a.m. After one hour, the normal setpoint temperature was set at 09:00 a.m. and the six input values were collected at that time. After a certain period (e.g., 30 min), the indoor temperature will reach the normal setpoint temperature. In this case, the output value was 30 min, and one set of data was prepared. After data set acquisition, the set temperature for the heating system is returned to the setback temperature. Then the same process is repeated three times (at 12:00, 15:00, and 18:00) a day. Therefore, 480 data sets were collected, and one hundred sets were randomly selected for initial training. Four hidden neurons were used in each of the three hidden layers based on the findings of a previous study [52], that proposed four hidden neurons and three hidden layers as the optimal composition to predict the future temperature. The hidden neurons used the tangent-sigmoid transfer function to transfer calculation results in the neuron. Each hidden layer repeats the identical process. Lastly, the output layer employs one output neuron TIME SPT , and uses the pure linear transfer function to produce the final output.
One hundred training data sets were prepared for the training model. Each data set was composed of six input values (TEMP IN , ∆TEMP IN , TEMP OUT , ∆TEMP OUT , TEMP DIF , and SOL) and one output value (TIME SPT ). The sliding-window method was used to manage the training data sets. Therefore, when a new data set was acquired, the new set replaced the oldest set. Then training was conducted. The Levenberg-Marquardt algorithm was used for the model training with a 0.0-min goal, 1000-times epoch, 0.2-momentum, and 0.6-learning rate, which were found to be the optimal values by a previous study [57]. Figure 4 shows the test module in which the data sets were acquired and Table 1 summarizes the detailed features of the module. The location of the test module was assumed to be in Seoul, South Korea, where winters are cold and dry. Data sets were collected from 1 November to 28 February.
Typical meteorological year (TMY2) data was used as weather data. Four data sets were collected per day. For example, the setback temperature was applied at 08:00 a.m. After one hour, the normal setpoint temperature was set at 09:00 a.m. and the six input values were collected at that time. After a certain period (e.g., 30 min), the indoor temperature will reach the normal setpoint temperature. In this case, the output value was 30 min, and one set of data was prepared. After data set acquisition, the set temperature for the heating system is returned to the setback temperature. Then the same process is repeated three times (at 12:00, 15:00, and 18:00) a day. Therefore, 480 data sets were collected, and one hundred sets were randomly selected for initial training.   The dimension of the module was 4.2 m (width), 3.6 m (depth), and 3.05 m (height) approximating the basic and the simplest residential space. The envelope components were assumed to have 3.72, 0.71, 6.80, 3.70 m 2 ·K/W thermal resistance for the wall, windows, roof, and floor, respectively. The thermal resistances of the envelope were greater than required in Korea (2.78, 0.41, 5.00, and 2.32 m 2 ·K/W for each envelope component). A radiant heating system that could supply 12,000 kJ/h of heat. No windows were installed on the east or west walls, and the window-to-wall ratios were 0.20 and 0.10 for the southern and northern walls, respectively. The moderate value for the infiltration rate was assumed to be 2.0 air changes per hour (ACH), which is a normal value. Two occupants, lighting fixtures, and equipment were considered for calculating the internal heat gain.
The model development process continued with a statistical analysis to investigate the relationship between the initial input variables and the output variable. This relationship analysis determined that the input variables that had a strong relevance (R 2 ) to be used as input neurons. One hundred new data sets were used for the analysis.
The second step of the ANN model development was the optimization of the model structure and learning method. The purpose of the optimization was to modify the model to calculate the output more accurately. The structure and the learning method affect the prediction performance and therefore need to be adjusted to produce accurate and stable output [27]. The ANN model structure is determined with a series of input, hidden, and output layers and neurons. The number of input and output layers and neurons were fixed in this study. The optimization factors for this study were the number of hidden neurons (NHN) and hidden layers (NHL).
Learning Rate (LR) and Momentum (MO) are the principal two factors for the ANN model learning method. The LR controls the impact degree of the new data set on the weight changes between neurons when the iterative training is conducted. The LR is related to the degree of adaptation to the new data set as well as the stability of the prediction results. MO considers the trend of the weight changes on the previous training process when the current training is conducted. Proper  The dimension of the module was 4.2 m (width), 3.6 m (depth), and 3.05 m (height) approximating the basic and the simplest residential space. The envelope components were assumed to have 3.72, 0.71, 6.80, 3.70 m 2 ·K/W thermal resistance for the wall, windows, roof, and floor, respectively. The thermal resistances of the envelope were greater than required in Korea (2.78, 0.41, 5.00, and 2.32 m 2 ·K/W for each envelope component). A radiant heating system that could supply 12,000 kJ/h of heat. No windows were installed on the east or west walls, and the window-to-wall ratios were 0.20 and 0.10 for the southern and northern walls, respectively. The moderate value for the infiltration rate was assumed to be 2.0 air changes per hour (ACH), which is a normal value. Two occupants, lighting fixtures, and equipment were considered for calculating the internal heat gain.
The model development process continued with a statistical analysis to investigate the relationship between the initial input variables and the output variable. This relationship analysis determined that the input variables that had a strong relevance (R 2 ) to be used as input neurons. One hundred new data sets were used for the analysis.
The second step of the ANN model development was the optimization of the model structure and learning method. The purpose of the optimization was to modify the model to calculate the output more accurately. The structure and the learning method affect the prediction performance and therefore need to be adjusted to produce accurate and stable output [27]. The ANN model structure is determined with a series of input, hidden, and output layers and neurons. The number of input and Learning Rate (LR) and Momentum (MO) are the principal two factors for the ANN model learning method. The LR controls the impact degree of the new data set on the weight changes between neurons when the iterative training is conducted. The LR is related to the degree of adaptation to the new data set as well as the stability of the prediction results. MO considers the trend of the weight changes on the previous training process when the current training is conducted. Proper MO prevents the model from falling into local minima. Since the LR and MO significantly affect the prediction results, these two factors were optimized in this study. Table 2 summarizes the tested values of each parameter. A coupled fashion was employed for the parametrical optimization. That is, a series of NHN and NHL were tested in combination with each other, then a series of MO and LR were tested in combination. During the optimization process of the first two parameters (i.e., NHN and NHL), the other two parameters (i.e., MO and LR) were fixed as the initial values (0.2 for momentum and 0.6 for learning rate, as suggested in the previous study [54]). Once the optimal values for the first two parameters (NHN and NHL) were found, then the tests for the last two parameters were conducted. During the tests for the last two parameters, the values of the first two parameters were fixed as optimal values found in the previous process. Another 100 data sets were newly collected for the optimization using the identical method to collect data sets for the initial model training and relationship analysis. After optimization, the third development step tested the prediction accuracy of the optimized ANN model. A further hundred checking data sets were acquired from the identical test module. The statistical correlation (R 2 ) between P i and S i was analyzed to investigate the prediction accuracy.

Flowchart of the Control Algorithm
Multiple ANN models including the one developed in this study will be embedded in the control algorithm, which we will develop in further studies. Figure 5 shows the conceptual flowchart of the control algorithm for the heating system. In order to determine the working condition of the heating system, the algorithm uses the period of the day, TIME CUR , TEMP IN , ∆TEMP, TIME SBT , and TIME SPT as determinants. Three ANN models are applied to predict ∆TEMP, TIME SBT , TIME SPT , respectively. Table 3 summarizes their purpose. Two of the ANN models have already been developed, and previous studies introduced their purpose and performance. Those models are ∆TEMP to determine the working mode of the heating system, and TIME SBT to determine the optimal start of the setback period. The last ANN model proposed in this study is applied to determine the optimal end of the setback period based on the predicted TIME SPT . as determinants. Three ANN models are applied to predict ΔTEMP, TIMESBT, TIMESPT, respectively. Table 3 summarizes their purpose. Two of the ANN models have already been developed, and previous studies introduced their purpose and performance. Those models are ΔTEMP to determine the working mode of the heating system, and TIMESBT to determine the optimal start of the setback period. The last ANN model proposed in this study is applied to determine the optimal end of the setback period based on the predicted TIMESPT. Figure 5. The control algorithm. Figure 5. The control algorithm. Figure 6 conceptually shows the temperature profile of the day. By providing the predicted values-∆TEMP, TIME SBT , and TIME SPT , the three ANN models can help to create more comfortable and stable thermal conditions. In particular, the ANN model (ANN 3) developed in this study predicts the TIME SPT , and this predicted value is used to predetermine the end of setback. By predetermining the end of the setback period, the temperature at the beginning moment of the occupied period is closer to the normal range. For example, if the current indoor temperature is 19.0 • C during the unoccupied setback period and the designated target setpoint temperature is 23.0 • C, the TIME SPT is the amount of minutes needed to raise the current indoor temperature from 19.0 to 23.0 • C. If the sum of TIMP SPT and the current time reaches the beginning moment of the normal setpoint period (i.e., the occupied period), the algorithm determines the normal setpoint temperature to be employed at that moment before the actual occupied period begins.   Figure 6 conceptually shows the temperature profile of the day. By providing the predicted values-ΔTEMP, TIMESBT, and TIMESPT, the three ANN models can help to create more comfortable and stable thermal conditions. In particular, the ANN model (ANN 3) developed in this study predicts the TIMESPT, and this predicted value is used to predetermine the end of setback. By predetermining the end of the setback period, the temperature at the beginning moment of the occupied period is closer to the normal range. For example, if the current indoor temperature is 19.0 °C during the unoccupied setback period and the designated target setpoint temperature is 23.0 °C, the TIMESPT is the amount of minutes needed to raise the current indoor temperature from 19.0 to 23.0 °C. If the sum of TIMPSPT and the current time reaches the beginning moment of the normal setpoint period (i.e., the occupied period), the algorithm determines the normal setpoint temperature to be employed at that moment before the actual occupied period begins.  Figure 7 shows the flow of algorithm operation. As with the ANN model development process, the algorithm development and operation were conducted using TRNSYS and MATLAB. The building and system were modelled using the TRNSYS software. The current indoor and outdoor thermal conditions were collected and transferred to the control algorithm developed using MATLAB. The data was used for the iterative training of the ANN model and for predicting TIMESPT. Based on the TIMESPT, the algorithm decided how to operate the heating system, which would be transferred to the system in the TRNSYS. This process was repeated in a closed loop. Figure 8 shows the modeling results in the TRNSYS, while Table 4 summarizes the types and roles used in the TRNSYS modeling result.  Figure 7 shows the flow of algorithm operation. As with the ANN model development process, the algorithm development and operation were conducted using TRNSYS and MATLAB. The building and system were modelled using the TRNSYS software. The current indoor and outdoor thermal conditions were collected and transferred to the control algorithm developed using MATLAB. The data Energies 2016, 9, 1090 9 of 16 was used for the iterative training of the ANN model and for predicting TIME SPT . Based on the TIME SPT , the algorithm decided how to operate the heating system, which would be transferred to the system in the TRNSYS. This process was repeated in a closed loop. Figure 8 shows the modeling results in the TRNSYS, while Table 4 summarizes the types and roles used in the TRNSYS modeling result. Figure 6. A conceptual temperature profile with the predictive control algorithm. Figure 7 shows the flow of algorithm operation. As with the ANN model development process, the algorithm development and operation were conducted using TRNSYS and MATLAB. The building and system were modelled using the TRNSYS software. The current indoor and outdoor thermal conditions were collected and transferred to the control algorithm developed using MATLAB. The data was used for the iterative training of the ANN model and for predicting TIMESPT. Based on the TIMESPT, the algorithm decided how to operate the heating system, which would be transferred to the system in the TRNSYS. This process was repeated in a closed loop. Figure 8 shows the modeling results in the TRNSYS, while Table 4 summarizes the types and roles used in the TRNSYS modeling result.

Selection of Input Neurons
To select the meaningful input neurons for calculating the output neuron, the coefficient of determination (R 2 ) between TEMPIN, ΔTEMPIN, TEMPOUT, ΔTEMPOUT, TEMPDIF, and SOL (input variables) and TIMESPT (output variable) of the initial model were investigated. The results are summarized in Table 5. The coefficient of determination (R 2 ) was calculated for the diverse cases of applying different setback temperatures from 16.5 (setback operating range: 15.0 to 18.0 °C) to 20.5 °C (setback operating range: 19.0 to 22.0 °C).

Selection of Input Neurons
To select the meaningful input neurons for calculating the output neuron, the coefficient of determination (R 2 ) between TEMP IN , ∆TEMP IN , TEMP OUT , ∆TEMP OUT , TEMP DIF , and SOL Energies 2016, 9, 1090 10 of 16 (input variables) and TIME SPT (output variable) of the initial model were investigated. The results are summarized in Table 5. The coefficient of determination (R 2 ) was calculated for the diverse cases of applying different setback temperatures from 16.5 (setback operating range: 15.0 to 18.0 • C) to 20.5 • C (setback operating range: 19.0 to 22.0 • C). The R 2 between two inputs (TEMP IN and TEMP DIF ) and TIME SPT was relatively strong. As the lower setback temperature was applied, the correlation results were higher. When the setback temperature was set to 16.5 • C (the normally recommended setback temperature), the correlation was 0.9330. When the setback temperature was 20.5 • C, it decreased to 0.1435 because the setback temperature was not significantly different from the 21.5 • C setpoint temperature.
Meanwhile, the R 2 between other input variables and output variable were unstable and less significant. They ranged from 0.0008 to 0.4768. The input variables with higher R 2 were determined as final input neurons of the initial ANN model. Therefore, the new model had two input neurons: TEMP IN and TEMP DIF . Table 6 summarizes the root mean square error (RMSE) results between the P i and S i for the different combinations of NHN and NHL. The RMSE for a different number of hidden neurons (1 to 10) and hidden layers (1 to 10) presented a wide range of difference. The RMSE for all test cases ranged from 0.74740 min to 1688.48783 min. The case presenting the least RMSE was the model employing 3 NHN and 9 NHL. Therefore, the optimal composition regarding NHN and NHL was determined to be 3 and 9, respectively.  Table 7 summarizes the RMSE results for the different MO (0.1 to 1.0) and LR (0.1 to 1.0). The values for NHN and NHL were fixed as 3 and 9, as found in the previous step. The least RMSE was presented by a model with 0.9 MO and 0.9 LR. For this case, the RMSE was 0.74739 min. Thus, the optimized ANN model employed these values for momentum and learning rate. Figure 9 shows the ANN model after correlational analysis for the input selection, as well as optimization for the composition and learning method. The final model had two input neurons-TEMP IN and TEMP DIF ; 3 NHN; 9 NHL; 0.9 MO; and 0.9 LR.  Figure 9. The optimized ANN model.

Prediction Accuracy
To investigate the accuracy of the prediction results from the optimized ANN model, Pi and Si for the new 100 checking data sets were compared. Figure 10 shows that the results of Pi and Si display a similar pattern. The average difference between them was 0.45 min, which ranged from 0.0 min to 3.9 min. In addition, Figure 11 summarizes the distribution of difference. For 87 of the cases, the difference between Pi and Si was less than 1.0 min. Nine cases were between 1 and 2 min, and four cases were over 2 min.

Prediction Accuracy
To investigate the accuracy of the prediction results from the optimized ANN model, P i and S i for the new 100 checking data sets were compared. Figure 10 shows that the results of P i and S i display a similar pattern. The average difference between them was 0.45 min, which ranged from 0.0 min to 3.9 min. In addition, Figure 11 summarizes the distribution of difference. For 87 of the cases, the difference between P i and S i was less than 1.0 min. Nine cases were between 1 and 2 min, and four cases were over 2 min. Figure 12 presents the correlation (R 2 ) between P i and S i . The P i and S i show similarity with 0.7697 R 2 . The time required to raise the indoor temperature to the normal setpoint temperature was not as big as expected. The longest period was 7 min in the simulation in Figure 10. Therefore, a small difference between the simulated and predicted values could cause a significant decrease in R 2 . When the model is applied to the actual building where longer time is required to raise the temperature to the normal setpoint temperature, R 2 is expected to increase. In addition, the CVRMSE (coefficient of variation root mean squared error) between P i and S i was calculated as 22.74%. According to the ASHRAE Guideline14-Measurement of energy and demand savings [59], the prediction model can prove its prediction accuracy with a CVRMSE value under 30%. Thus, the ANN model in this study proved its prediction accuracy.
To investigate the accuracy of the prediction results from the optimized ANN model, Pi and Si for the new 100 checking data sets were compared. Figure 10 shows that the results of Pi and Si display a similar pattern. The average difference between them was 0.45 min, which ranged from 0.0 min to 3.9 min. In addition, Figure 11 summarizes the distribution of difference. For 87 of the cases, the difference between Pi and Si was less than 1.0 min. Nine cases were between 1 and 2 min, and four cases were over 2 min.   a similar pattern. The average difference between them was 0.45 min, which ranged from 0.0 min to 3.9 min. In addition, Figure 11 summarizes the distribution of difference. For 87 of the cases, the difference between Pi and Si was less than 1.0 min. Nine cases were between 1 and 2 min, and four cases were over 2 min.   The time required to raise the indoor temperature to the normal setpoint temperature was not as big as expected. The longest period was 7 min in the simulation in Figure 10. Therefore, a small difference between the simulated and predicted values could cause a significant decrease in R 2 . When the model is applied to the actual building where longer time is required to raise the temperature to the normal setpoint temperature, R 2 is expected to increase. In addition, the CVRMSE (coefficient of variation root mean squared error) between Pi and Si was calculated as 22.74%. According to the ASHRAE Guideline14-Measurement of energy and demand savings [59], the prediction model can prove its prediction accuracy with a CVRMSE value under 30%. Thus, the ANN model in this study proved its prediction accuracy. The analysis results about the prediction accuracy and correlation between Pi and Si implies that the ANN model can properly predict the ascending time for the pre-determined operation of the heating system during the unoccupied period. Based on the findings, the model presented its potential to be applied in the control algorithm for suggesting the optimal ending moment of the setback temperature for the heating system.

Conclusions
In order to develop an ANN prediction model for calculating the time (TIMESPT) required to raise The analysis results about the prediction accuracy and correlation between P i and S i implies that the ANN model can properly predict the ascending time for the pre-determined operation of the heating system during the unoccupied period. Based on the findings, the model presented its potential to be applied in the control algorithm for suggesting the optimal ending moment of the setback temperature for the heating system.

Conclusions
In order to develop an ANN prediction model for calculating the time (TIME SPT ) required to raise indoor temperature during the unoccupied setback period to the designated target setpoint temperature, three major steps were completed in this study: (1) model development; (2) model optimization; and (3) performance evaluation. Our findings are summarized as follows: (1) The correlation analysis (R 2 ) between input variables and output variable (1st step) revealed that TEMP IN and TEMP DIF (input variables) presented relatively strong relationships with TIMP SPT (output variable). Therefore, these two variables were selected as input neurons for the initial ANN model. (2) Using RMSE to analyze the difference between the simulated outputs (S i ) and predicted outputs (P i ) from the ANN model for different ANN parameter values (2nd step) revealed that the least RMSE was produced when applying nine hidden neurons in each hidden layer, three hidden layers, a 0.9 momentum, and a 0.9 learning rate to the ANN model. Therefore, the ANN model was optimized with these final values. (3) From the performance tests, the proposed ANN model proved its prediction accuracy.
The CVRMSE between the simulated outputs and predicted outputs (22.74%) was lower than the generally accepted level (30.0%). In addition, the difference between them for most of the cases was less than 1 min.
In conclusion, based on the previous study [27,28], the more progressive methodology was applied for composing and optimizing the ANN model in this study. First, the meaningful input variables were selected based on their statistical relationship analysis. Then structure and learning methods for the model were optimized in a coupled fashion. The model developed using the new method showed an acceptable prediction accuracy, therefore it was applied to the control algorithm.
The control algorithm employed multiple ANN models. As summarized in Table 1, each model had its prediction target. Using the predicted values from three ANN models, the heating system will start and stop the setback period more accurately as well as create more comfortable and stable indoor temperature conditions.
Overall, we used limited boundary conditions for the performance tests in this study. To ensure that the potential results can be achieved, these performance tests should be conducted in an actual building. Along with the field tests, additional performance tests should be conducted. To provide a solid basis for the proposed method, using other types of simulation methods should also be undertaken. Using MATLAB and EnergyPlus software, and incorporating it with Building Controls Virtual Test Bed (BVCTB) for connecting the two, is proposed as the good method to test the predictive control strategies [60,61].
In addition, the proposed ANN model performance needs to be comparatively investigated by using diverse optimization schemes such as the constructal theory or entropy generation minimization methods. Also, other machine learning methods such as support vector machine (SVM), random neural network (RNN), and model predictive controller (MPC), should be compared to the proposed model. Those methods were stated to predict the indoor temperature conditions more accurately and to maintain indoor temperature more stably in a couple of studies [62,63]. Through these comparative tests, the most applicable method will be found. Finally, the control algorithm, as previously shown in Figure 2, needs to be organized to employ the proposed prediction model and tested for its performance in further studies.