Decentralized Management of Commercial HVAC Systems

: With the growth of commercial building sizes, it is more beneﬁcial to make them “smart” by controlling the schedule of the heating, ventilation, and air conditioning (HVAC) system adaptively. Single-building-based scheduling methods are more focused on individual interests and usually result in overlapped schedules that can cause voltage deviations in their microgrid. This paper proposes a decentralized management framework that is able to minimize the total electricity costs of a commercial microgrid and limit the voltage deviations. The proposed scheme is a two-level optimization where the lower level ensures the thermal comfort inside the buildings while the upper level consider system-wise constraints and costs. The decentralization of the framework is able to maintain the privacy of individual buildings. Multiple data-driven building models are developed and compared. The effect of the building modeling on the overall operation of coordinated buildings is discussed. The proposed framework is validated on a modiﬁed IEEE 13-bus system with different connected types of commercial buildings. The results show that coordinated optimization outperforms the commonly used commercial controller and individual optimization of buildings. The results also show that the total costs are greatly affected by the building modeling.


Introduction
Residential and commercial buildings consume a large share of the energy consumption in the E.U. and USA [1]. Heating, ventilation, and air conditioning (HVAC) systems alone consume around 44% of the total energy required in commercial buildings, which necessitates the control of such systems [2]. While the HVAC control in residential buildings and their participation in residential demand response have received a lot of attention [3][4][5], coordination of commercial buildings still needs further research. Unlike residential buildings, commercial buildings are more challenging to optimize and coordinate. This is because a generalized model for commercial buildings cannot be easily achieved due to the complexity and customization of different commercial buildings, which stems from the fact that commercial HVAC systems consist of multiple parts (chillers, air handling units, variable or constant air boxes, etc.) and they can be configured in many ways.
To evaluate the potential of commercial buildings in participating in demand response, two years of smart meter data coming from an urban area in New York was used in [6]. It was found that the demand characteristics of commercial buildings in which the strict temperature requirements coincide with the time of use on-peak period make it challenging for most commercial buildings to participate in demand-side management effectively. Different researchers proposed different control methodologies to help minimze the energy cost of commercial buildings and facilitate their integration into the grid [7][8][9]. Model predictive control (MPC) is one of the most commonly used controllers for commercial HVAC optimization [10]. Data-driven MPC was used in [11] to optimally schedule the heating system in order to save energy while guaranteeing the thermal comfort for the occupants. A linearized random forest model was used to develop the data-driven MPC and it was found that the MPC could provide comparable performance with the conventional physics-based MPC. Stochastic model predictive control (SMPC) for commercial HVAC control was proposed in [12], where a finite probability density function was used to reflect the uncertainties associated with the thermal loads of different zones. In [13], a neural network was deployed to model the building temperature dynamics and a linear regression for the energy consumption. Experimental evaluation of data-driven optimization was conducted, where integer linear programming was used to minimize the energy costs while satisfying the thermal comfort. Other authors considered the use of reinforcement learning for whole-building HVAC control [14,15] to minimize the energy cost while maintaining the thermal comfort. The reinforcement learning allowed for the possibility of adopting more accurate nonlinear models of the HVAC system but the optimiality of the operation is not guaranteed. A virtual battery model for a commercial building was developed in [16], where data-driven and physics based-modeling were used to learn the building's thermal characteristics. Then, a model predictive controller was developed to enable real-time ramping service participation. To ensure a fast response, the MPC was tested under different possible circumstances, where an input-output mapping is recorded and saved in a scheduler that is used for real-time control. All the previous works focused on the optimization of an individual commercial building.
To leverage the use of commercial buildings in providing grid services, some researchers developed more comprehensive controllers that are able to coordinate multiple buildings or resources. Agent-based modeling was proposed in [17] to study the consumption behavior of commercial buildings participating in demand response under different market structures. The results illustrate that there is an obvious impact from commercial buildings with price-responsive demand on the electricity market. In [18], the authors developed a generalized battery model for buildings with the aim of analyzing the buildings' flexibility and ability to provide different grid services. The effect of lock-off time of virtual battery models was assessed in [19]. It was found that with the lock-off time, the flexibility does not greatly change when following slow grid signals, but was much reduced when following fast signals.
Many researchers considered centralized coordination of commercial buildings and resources. Centralized coordination of buildings, thermal energy storage and unit commitment was considered in [20], where buildings were modeled as exponential functions of voltage and non-uniform horizon MPC was used to tackle the uncertainty and ensure load generation balance. Another centralized model predictive control was developed in [21] to reduce the maximum load ramp-rate of the power grid to prevent duck-curve issues associated with the increase in solar PV power penetration in the grid. The MPC was used to maximize the building load penetration while controlling the transformer tab changes and capacitors in the distribution system. Centralized energy management of commercial buildings in a microgrid was considered in [22]. In this work, the authors suggested a pricing model which aims at maintaining low operational costs while utilizing solar generation, stationary battery systems and mobile EV storage as much as possible. The authors in [23] provided a framework for energy optimization in neighborhoods. The authors considered the existence of multiple resources and buildings. Detailed physics-based models via Modelica have been used to represent the buildings' dynamics while a quasi-dynamic approach was used for the load flow of the network.
In [24], centralized, mixed-integer, non-linear programming was suggested to optimize the operation of multiple buildings in a microgrid. Linearization and equivalent representation of a pre-processed building model in Energyplus was used. Game theory was also deployed for optimal allocation of power among the buildings. In [25], RC networks were used for building modeling and a cooperative Nash bargaining formulation was developed to optimally allocate the power among campus buildings. Network constraints were not considered. Other researchers studied hierarchical control approaches. In [26], a hierarchical framework is proposed where the buildings optimize their consumption, taking network constraints into consideration, and send their operational constraint and other information to the distribution system operator. Then, the operator sends a feedback signal that might include other operational constraints for scheduling. An economic framework that solves a bi-level optimization problem was developed in [27]. The framework made sure that the followers/households and the retailers would benefit simultaneously, without unexpected deviations from the household side. However, no highlights on the building models were provided and the network technical constraints were not considered.
In a microgrid framework where multiple resources and loads need to be coordinated, the operator should maintain the technical reliability of its local grid while minimizing the operational costs. In [28], the authors provided insights into the different operational modes of a microgrid consisting of multiple resources and loads. The authors compared four kinds of conditional equations, which are: conditional equations for peak control, power use flattening, power demand response and operation of net zero energy. It was found that the conditional equations were effective when attempting to optimize the microgrid's performance efficiently. The paper did not consider the modeling and control of HVAC systems in the grid. In [29], the authors provided a control algorithm for residential HVAC systems in a microgrid to minimize the cost, minimize the size of the microgrid units and minimize the imported energy from the distribution grid. A physics-based model of the residential HVAC has been adopted where the information about the wall thermal losses was used via the use of transmission coefficient and infiltration of the walls.
In the operation of microgrids that have multiple buildings, the privacy issue of the different buildings arises as a major concern and the microgrid operator should ensure good operation of the system with minimal information about the buildings. Therefore, decentralized coordination alorithms arise as a viable option that can help achieve these goals. Decentralized coordination of commercial buildings has been rarely investigated in the literature. In [30], Dantzig-Wolfe decomposition was used to transform the centralized coordination problem between a building manager and an EV aggregator into a decentralized one. Power flow and grid constraints were not considered in this work. In addition, Dantzig-Wolfe decomposition can only be used with problems with a certain structure where there is a binding constraint between the entities under consideration. Therefore, it can not be used in many cases. In this work, a more comprehensive framework that can handle problems with common objectives is considered. In addition, this work investigates how the building model affects the cost and flexibility of the entire microgrid.
Therefore, in this work, a two-level scheduling framework is proposed to satisfy the system requirements. At the global level, the system operator (i.e., microgrid/enterprise/campus operator) is required to minimize the total cost of the electricity purchased from the utility company as well as maintaining the operating conditions of its power grid within satisfactory conditions. At the local level, the building managers are required to maintain a certain thermal comfort for the occupants of the building during the day. The proposed approach is a decetralized one which minimizes the amount of exchanged data and information with the system operator, which may result in privacy concerns and require extra communication investment. In addition, the buildings' models in this work are based on the building historical data that can be readily available in the building automation system. It is worth highlighting that most commercial buildings are usually equipped with a building automation system that can easily store different historical data about the building performance. This makes the proposed algorithm more generalizable and favorable for most commercial buildings regardless of the building customization.
Based on the above discussion, the main contributions of this paper are: 1. Developing and comparing different data-driven buildings' models; 2. Developing a decentralized coordination among the buildings to reduce the cost and voltage deviations while maintaining the thermal comfort of each building; 3. Analyzing the effect of the building models on the overall costs and flexibility of the microgid.

Methodology
The proposed methodology aims at minimizing the total cost of the purchased electricity by the microgrid as well as improving the voltage deviations of the power network. The voltage deviation is considered in this work as a main concern for the microgrid operator where the voltage should be within the ANSI standards between 0.95 p.u and 1.05 p.u. Based on that, this consideration of voltage deviations can only be made by the microgrid operator as the building operator does not have access to system-wide information such as the voltages at different buses.
In addition, the proposed method ensures that the temperature in different buildings, coordinated by the microgrid operator, is maintained within the comfort range required by each building manager. The coordination occurs in a decentralized way. This helps alleviate the need for investments in the communication infrastructure as well as maintaining the privacy of different buildings. Figure 1 shows the architecture of the proposed optimization framework. It is a twolevel framework where the system-level optimization is responsible for limiting the voltage deviations in the network as well as minimizing both the energy and demand charges of the purchased electricity. The decision variables at the upper level are the virtual price signals that will guide the consumption of different buildings, while the decision variables at the lower levels are the switching statuses of the HVACs in different buildings. The upper level receives the actual time of use (ToU) signal and tries to come up with a synthetic set of virtual prices that will be sent to the different buildings in the lower-level optimization. The idea of virtual prices has been considered in a variety of different studies [31][32][33] ranging from relieving network congestion to other cost related objectives. The advantage of a virtual price signal is that it provides a cheap and effective way to coordinate and harness the flexibility of multiple entities in the grid. It alleviates the need for high investment in the communication infrastructure to share large amounts of data. It also helps to maintain the privacy of different users in the grid since only the expected total demand is shared with the upper-level operator. When the virtual price signals become decision variables in the optimization problem, they can be optimally determined by the optimizer.
The objective of the lower-level optimization is to minimize its operating costs while maintaining the required temperature comfort range. In doing so, it is assumed that the building manager does not want to expose any detailed information about the building, e.g., HVAC system structure, its schedules or temperature comfort range. Therefore, the only outcome of the building-level optimization that is shared with the system operator is the expected building power profile. The decision variables at the building level are the switching statuses of the HVAC system. Different buildings will submit their power profiles, and load flow analysis for the power network will be performed. Then, the total system power profile as well as the line flows and voltages at the different buses will be sent to the upper layer, which will evaluate the different objectives and adjust the virtual price signals and send them back to building levels. This iterative process will continue until a stopping criterion is achieved.
The main intuition behind this proposed methodology is to prevent the rebound effect that might occur if all the building received the same actual ToU. The rebound effect happens when multiple loads defer their demand during the peak time of the ToU signal; then, all the loads are connected at the same time with the start of the off-peak period, which introduces another peak in the system. This phenomenon was confirmed by many researchers [34][35][36]. In the case of a microgrid operator, the introduced peaks in the system will cause an increase in the demand charge (a cost that is a function of the system peak), which is usually paid by the commercial building operator. In addition, it can cause undesirable voltage deviations in the system. Thus, the proposed methodology attempts to synthesize virtual price signals that will help to minimize the energy cost and avoid introducing such system peaks as much as possible, which in turn will reduce the total costs of the purchased electricity and improve the voltage deviations of the system. For any building optimization, building models are needed. Therefore, the next section will introduce the three types of data-driven models adopted in this work.

Data-Driven Models
The lower-level optimization is responsible for maintaining the building temperature within the comfort range at the lowest possible cost. Numerical optimization techniques, including mixed-integer linear programming (MILP) and linear programming (LP), are commonly used in the literature. This is because optimality is guaranteed and most of the developed HVAC models are linear in nature or can be linearized [37,38]. Therefore, MILP is adopted in this work at the building level. In order to optimize the HVAC consumption, it is important to characterize/model the internal building dynamics in terms of the temperature behavior as well as the energy consumption. To make the proposed methodology generalizable, data-driven models are adopted in this work. The adoption of data-driven models relies on the availability of the historical data in the building automation system (BAS) in most commercial buildings. Unlike physics-based models, data-driven models do not need detailed information about the physical parameters of the building, such as the construction materials, lighting and equipment schedules, etc. In addition, physics-based models require large amounts of time and effort to develop and calibrate [39,40]. In this work, three different data-driven models are developed and compared. The effect of the accuracy of the different models on the total energy and demand costs of the entire microgrid will be discussed. The three models are the linear regression model, polynomial regression and support vector regression. Details about each of them are provided below.

Linear Regression
Linear regression is one of the most commonly used methods in HVAC system modeling. The linear regression model represents a weighted linear combination of the features, where the weight of each feature determines the impact of this feature on the modeled variable. The objective of the trained model is to minimize the sum of the least square errors between the target value and the modeled one. In this work, the same set of features is used for both the temperature and consumption models. The selected features are the building temperature in the previous time step (T t−1 ), the ambient temperature (T t amb ) and the switching status of the HVAC systems (O t ). Though the selected features do not directly include the set-point temperature, it is implicitly included in the switching status. In commercial buildings, the switching status does not mean fully turning on/off the HVAC. It reflects a temperature set-point that the chiller and the cooling coil should achieve. According to the American Society of Heating, Refrigerating and Air-Conditioning Engineers (ASHRAE) standards, the 'on' status can mean a working-hour temperature set-point of 74 • F (23.3 • C) or 75 • F ( 23.9 • C), while the 'off' status means a setback temperature of 80 • F ( 26.7 • C). These numbers are adopted by many researchers [41]. Of course, other features such as the air flow rate, fan power of the air handling units and other variables can be added as features, but, in this work, only the three basic features are chosen because they are readily available in all BASs. Other variables may or may not exist depending on how advanced the BAS system is. The developed linear regression models are illustrated by Equations (1) and (2), where b i and c i are the regression model coefficients and the subscript k refers to the building number.

Polynomial Linear Regression
Polynomial linear regression is an extension of the conventional linear regression. It is used to show that even with limited features, more complex models can be developed. The main difference between the conventional linear and polynomial regressions is the set of features that is used. The polynomial regression uses extra synthetic features that are generated from the basic features by using polynomial functions of the given features. In this work, a polynomial of degree 2 is used in addition to the basic features. Examples of the extra added higher-order features are ( It is worth highlighting that no extra data or sensors are needed to have a polynomial regression model because the synthetic polynomial regressors are merely functions of the given basic set of features. The main intuition behind the polynomial regression is to have a more flexible model that can capture the non-linear relationships between the target/output and the feature set. Based on this, the obtained polynomial regression models are: where d i and e i are the polynomial regression model coefficients.

Support Vector Regression
Support vector regression belongs to the general umbrella of support vector machines, where the objective is to find a function of the form shown in Equation (5) to mimic the building dynamics. In this equation, φ(x) corresponds to the mapped features using a kernel function. A linear kernel is used in this work. The model parameters Z and Ψ are found by solving the optimization problem in (6), where L (Y i − f xi ) is the loss term, which is a function of the difference between the target value and the modeled one. is a control variable that controls the number of support vectors used in the training. A small value is used in this work to avoid over-fitting. H is the number of training samples and M is a penalty for large errors. The second norm Z is meant to ensure smooth fitting. More information about support vector machines can be found in [42]. min.

Building-Level Optimization
The main objective of the building-level optimization is to minimize the energy cost while ensuring that the building temperature is within the comfort range required by the building manager. The main objective is formulated in Equation (7), where π v,k represents the virtual price signal for building k that is received from the higher-level optimization. P k is the power consumption of the building that is modeled in Section 3. D is the temperature deviation outside the comfort range while F is a penalty value to penalize any temperature deviation. The second part of Equation (7) is added to ensure that a feasible solution will exist while the upper optimization is scanning the search space. A high value of F is used to ensure that the deviation will only be allowed if the building optimization problem becomes infeasible. It is worth highlighting that the cost obtained by (7) is not the actual cost of purchased power by the microgrid operator.
The building is subject to constraints defined by constraints (8)- (10). Constraint (8) enforces the temperature to be between minimum and maximum values. These minimum and maximum values are not constant across the day. Mostly, they differ between the working and non-working hours of the day. In addition, they are different from one building to another.
The case study under consideration is for a hot region. Therefore, the HVAC is required to cool down the building. Based on this, the deviation term is added to the right-hand side of the constraint to relax the upper bound in case of infeasability. This means that the temperature can go beyond the maximum allowed temperature if the problem becomes infeasible due to a modeling error or tight values of the virtual prices. Bounds on the deviation are enforced by constraint (9), which limits the maximum temperature deviation at any time step to be less than 0.5 • C. The building temperature T t k is forecast based on the models in Section 3.
To limit excessive cycling of the HVAC equipment, which can reduce its life time, constraint (10) puts a limit on the minimum up and down times, where O is the switching status of the HVAC, which is the main decision variable in the lower-level optimization. This constraint ensures that if the HVAC is switched on, it will be on for at least some time, which is defined to be 20 min in this paper. The same applies for the switching-off periods.

Problem Formulation
One of the motivations for implementing the control scheme is to coordinate the conflict between cost, voltage deviations and system-wise losses. Without proper coordination from the microgrid operator, each building will optimize its own energy cost without considering the system demand charges and voltage deviation issues. The resulting HVAC schedules will be highly similar because the buildings are more or less subjected to the same weather conditions of the geographical area, and the ToU peak time periods, which they try to avoid, are exactly the same. Such scheduling will result in similar load profiles among the buildings and an accumulated high peak load of the entire microgrid would occur. This could cause an increase in the total electricity cost.
The electricity cost of commercial buildings contains two charges that can be reduced through proper scheduling, energy charges and demand charges [43]. The minimization of energy cost and demand charges is contradictory. Their lower bounds cannot be achieved at the same time because the energy cost is calculated upon the total energy consumption and demand charges are related to the peak load power. In other words, if the buildings were allowed to individually optimize their consumption and costs, the decrease in the optimized energy costs may be counteracted by the increase in the demand charge. An extension to this contradictory relationship is the relation between the voltage deviations of the network and the minimization of the energy costs, where the increase in the system peaking might cause voltage deviations. Hence, energy charge, demand charge, and the voltage deviations are considered as the main objectives in this work. These objectives are the most common concerns in microgrid operations [44]. The three objectives are formulated in Equations (11)-(13), where π a refers to the actual energy price signal that is received by the microgrid operator and P sub is the total power consumed by the entire microgrid. r base in (12) refers to the base demand charge rate and r peak is the cost of kW of electricity during the peak period. The tariff structure adopted here follows the Duke energy tariff for commercial buildings [43]. Finally, Equation (13) refers to the sum of voltage deviations from the standard values. ANSI standards for distribution systems [45] are followed in this work, where the voltage should be limited between V = 0.95 p.u and V = 1.05 p.u.
DC = r base max P t sub |t ∈ TS + r peak max P t sub |t ∈ TS peak (12) As mentioned in Section 2, the system-wise constraints are considered in the upper level. Equation (14) describes the power flow model of the microgrid. The P i and Q i are the real and reactive power consumptions at bus i and Equation (15) represents the line flow limits [46].
P t l ≤ P l,max

Multi-Objective Optimization
The upper layer of the proposed framework generates virtual price signals, which are used in the lower buildings' layer, by solving a multi-objective problem that aims at minimizing the energy charge, demand charge and voltage deviations associated with different HVAC schedules. Generally speaking, there are two methodologies in the literature that are usually used to solve multi-objective problems: the aggregate weight functions and Pareto optimization. In this work, Pareto optimization is used because in a Pareto optimality, a set of optimal points that meet the constraints are obtained, which gives a comprehensive picture about different possible solutions and the correlation among the different objectives. Unlike the aggregate sum method, Pareto optimization eliminates the need for deciding on and assigning different weights to the different objectives. In addition, Pareto optimization does not fail to generate feasible solutions on the non-convex portions of the optimum solution front [47]. In this work, non-dominated sorting genetic algorithm II (NSGA-II) [48] is used to generate the Pareto solutions, known as the Pareto Front. In NSGA-II, the genetic algorithm is first used to scan the entire search space and find the different possible optimal solutions that can be obtained if certain control signals are used. Then, a sorting algorithm is used to eliminate the dominated solutions (those solutions that are less optimal in one objective or another compared to the others). This will result in a set of optimal solutions, which the decision-maker can use based on his/her preference. Genetic algorithm consists of three main operators, which are the crossover, mutation and selection. In this work, simulated binary crossover (SBX), in which the search power of a crossover operator is defined in terms of the probability of creating an arbitrary child solution from a given pair of parent solutions, is used. SBX is found to be useful in problems having multiple optimal solutions with a narrow global basin [49]. For the mutation operator, a polynomial probability distribution is used to perturb the solution in a parent's vicinity [50]. The commonly used tournament selection is adopted for the selection process. Information about the details and parameters of the simulated binary crossover and polynomial probability mutation can be found in [49,50].

Optimal Point Selection
Once the set of optimal solutions is obtained, the system operator needs to select one solution to operate the system. In this work, Technique of Order Preference Similarity to the Ideal Solution (TOPSIS) is used. TOPSIS is based on finding an ideal and an anti-ideal solution and comparing the distance of each one of the alternatives to those points [51]. The technique consists of six main steps, which are: Step 1: the obtained optimal solutions are normalized to get rid of the units and a normalized matrix is obtained. Vector normalization is used in this work.
Step 2: the decision-maker decides on the importance of each objective. Then, the wighted normalization decision matrix is calculated by multiplying the normalized decision matrix with the weight associated with each of the objective. Equal weights for the different objectives are used in this work.
Step 3: determine the ideal and anti-ideal solution. This is done by selecting the best performance of each objective from the normalized decision matrix. In this work, all the objectives are to be minimized so the ideal solution will be the one with the lowest value of the objective and the anti-ideal will be the one with the highest value for each objective.
Step 4: calculate the Euclidean distance of each of the alternatives in the normalized decision matrix to the ideal and anti-ideal values to find the separation measures.
Step 5: calculate the degree of closeness to the ideal solution based on the calculated separation measures.
Step 6: rank the degree of closeness and choose the closest solution to one which will be the best solution of all solutions.

Case Study
In this case study, the microgrid operator is assumed to have five different buildings under its jurisdiction. The HVAC systems of these buildings are assumed to be the only controllable loads in the system. The considered buildings represent different types of commercial buildings, which are a large office, a medium office, a strip mall, a super market and a restaurant. These buildings represent five of the thirteen reference buildings considered by the US department of energy. Their data are obtained from running the Ener-gyPlus models available in [52]. The buildings have different HVAC structure, occupancy, schedules and comfort temperatures. The buildings are connected to a modified IEEE 13-bus system, as shown in Figure 2. The numbers shown in the figure are the original ones used in the 13-bus standard system. Some fixed loads are replaced in the original system by the buildings' loads. The buildings are connected to the 3-phase buses in the system as it is the conventional norm for commercial buildings. The demand profiles of the uncontrolled loads in the different buildings are shown in Figure 3. It is assumed that the buildings have a 0.95 power factor. Other fixed loads connected to other buses in the network are shown in Table 1. The optimization part of the algorithm has been implemented in Python version 3.5.1, where the Gurobi solver was used to solve the cost minimization of the buildings. OpenDSS has been used for simulating the power network and was interfaced with Python through the COM module. In this case study, the accuracy of the data-driven models will be assessed. Then, the results from the multi-objective optimization will be presented and discussed.    -I  ----170  80  645  Y-PQ  --170  125  --646  D-Z  --230  132  --652  Y-Z  128  86 ----

Accuracy of Data-Driven Models
All the data-driven models are trained using the same set of weather data, which represent a typical summer month. It is assumed that the buildings are located in Orlando, Florida. Hence, a typical yearly weather dataset for Orlando was used in EnergyPlus to generate the training data. Each of the models uses the set of features that was discussed in Section 3 for training. Then, the models are used to predict the temperature and consumption of a different day that does not exist in the training samples. A graphical representation of the different predictions is shown in Figure 4. The figure illustrates that the models perform well in modeling the buildings' temperature. However, they are less accurate in predicting the buildings' power consumption, where they usually underestimate the power consumption in general.
To have a more qualitative measure of the modeling accuracy, Table 2 depicts the root mean squared errors for the different models of different buildings. The table confirms that the models perform better in terms of predicting the building temperature compared to the building consumption. This may be attributed to the slow changes in the building temperature from one time step to another. In addition, usually, the building temperature changes in a very narrow range, close to the upper value of the comfort temperature, as shown in the left part of Figure 4. The table also shows that the polynomial regression has the highest accuracy in general compared to the other two methodologies. This is because of the use of higher-order and more complex features in the polynomial regression, which helps it to capture the non-linear relations in the dynamics.
It is worth mentioning that other advanced machine learning algorithms such as support vector machine with Gaussian kernels or random forests can be used to develop more accurate models, as suggested in [53,54]. However, the developed models are highly non-linear, not convex, and cannot be used in optimization problems solved by most commercial solvers; this is why linear regression is still considered the most common type of data-driven model in the literature.
The table also illustrates that improvements in the modeling are not guaranteed for different types of buildings. For example, while the polynomial regression greatly improves the modeling of the medium office and the supermarket modeling, there is only a marginal improvement for the case of the large office and the mall. This highlights the fact that different building types may require different sets of features or different modeling methodologies for better modeling of the building dynamics.

Optimization Results
This subsection presents the results obtained from the decentralized multi-objective framework. In obtaining these results, the initial population of the genetic algorithm is chosen to be 500 and the number of generations is selected to 2000. Three cases are tested and compared. In each case, one of the proposed modeling methods is used for all buildings. This is to show how the accuracy of the building model affects the overall expected system costs. In the different cases, the outside ambient temperature is assumed to be that of a summer day, as shown in Figure 5. The uncoordinated case is also considered and presented. The uncoordinated case here refers to the case where the all the buildings receive the same ToU signal. It is to be observed that the results of the uncoordinated case also depend on the adopted building model. This is why three uncoordinated cases are used, where the multi-objective optimization and the uncoordinated case using the same building models are compared.  In addition, on each of the projections, the selected optimal point obtained by TOPSIS as well as the benchmark point are plotted. The figure shows that the way the buildings are modeled greatly affects the optimization results and expected costs. For example, the high accuracy of the polynomial regression leaves narrow room, and hence low flexibility, for controlling the HVAC consumption and minimizing the cost. The middle row of Figure 6 shows that the obtained Pareto Front is a constant line with an extremely narrow range. For example the range of change in the energy cost is around USD 4 and there is no variation at all in the demand charge cost or any improvement in the voltage profile. This mainly happens due to the very high accuracy of the building models, which results in almost no change from the benchmark case. In other words, no matter how the upper layer changes the virtual price signals sent to the different buildings, the optimized building schedules, and hence the load profile, are more or less the same. This mostly happens because the temperature predictions developed by the building models result in values very close to the temperature comfort boundary, which means that any switching off of the HVAC will make the building temperature higher than the required comfort temperature (constraint violation), which will make the optimizer turn on the HVAC. It is worth mentioning that the temperature relaxation in constraint (8) in the building-level optimization is not activated because of the high associated penalty, which is higher than the electricity cost.  Figure 6 also depicts the inverse relationship between the different objectives, where it is most obvious in the third rows of the figure and less obvious in the first row. The Pareto Fronts in these two rows illustrate that the lower the energy costs are, the higher the demand charge paid by the microgrid operator and vice versa. The same inverse relation between the energy costs and the voltage regulation is observed. The lowest demand charge occurs when all buildings try to avoid the peak period of the price signal simultaneously, which results in the lowest energy cost but will lead to a high system peak when all the buildings turn on the HVAC in the next time step simultaneously. The increase in the system peak will lead to worse bus voltages as well as higher charge demands.
The fact that the optimizer was able to generate compromises for the case of conventional linear and support vector regressions compared to the polynomial regression means that the building modeled flexibility is a function of the modeling accuracy. To improve energy-saving and limit the voltage deviations, it might come at the expense of minor temperature deviations at the building level. This also necessitates the importance of validating building models against actual data to investigate the possible flexibility that certain buildings can yield as well as the range of possible temperature deviations, if any. Figure 7 shows the different building temperatures for the selected optimal points. The figure shows that the temperature is always maintained below the required cooling limit. Indeed, temperature deviations are not expected to occur in the final optimized solution because of the high penalty associated with temperature deviation. The next subsection quantifies the possible savings associated with the different models based on the optimal point selected by TOPSIS.

Numerical Comparison of Optimized Schedules
In this section, the numerical results associated with the coordinated and uncoordinated cases are compared. In addition, a base case is also compared. The base case here refers to the common bang-bang controller usually used in commercial buildings. The objective of the controller is maintain the temperature comfort. Table 3 shows the voltage regulation defined by objective (13). In general, the table illustrates that lower modeling flexibility (associated with higher accuracy) results in higher voltage deviations due to narrower controlling temperature boundaries. The voltage regulation in the coordinated case using the proposed framework is always better than the uncoordinated case and both optimizations are better than the base case, which results in a 1.03 voltage regulation value. Moreover, the table shows that support vector regression results in sensible coordinated voltage improvement compared to the other modeling methodologies where the voltage regulation is 0.353 p.u with an improvement of 18.4% compared to the uncoordinated case. Table 4 shows the different costs of the uncoordinated cases where all the buildings receive the same ToU signal. Regardless of the building modeling methodology, the uncoordinated optimization is always better than the base case. Table 5 shows the different costs associated with the optimal points selected by TOPSIS. In comparison with the uncoordinated cases in Table 4, the point selected by TOPSIS always results in lower costs, except for the support vector regression cost. The reduction in costs for the polynomial regression is very small compared to the uncoordinated case as the building's flexibility is very limited by the building models. The increase in costs associated with the support vector regression stems from the sensible improvement in voltage regulation in Table 3. This happened because the selection of the optimal points by TOPSIS partly depends on the importance of each objective for the decision-maker reflected in the weights associated with different objectives. Since all the objectives are given the same weights in this case study, the improvements in the voltage by the support vector regression case came at the expense of the total cost. This means that the weights assigned by the decision-maker play an important role in the selection of the final operating point.

Conclusions
This paper presented and compared three data-driven models, which are the linear regression, polynomial regression and support vector regression. The three methods are convex and compatible with numerical optimization. They were used to model the temperature and consumption dynamics of commercial buildings. The accuracy of the different models was compared and assessed. It was found that polynomial regression can better capture the non-linear relationships between the features and the targets and can better mimic the building dynamics compared to the other two methods. In addition, a multi-objective optimization formulation, which coordinates and considers the requirements of the building managers as well as the microgrid operator, was developed. The formulation used NSGAII as the main technique because of its ability to handle the non-linearity associated with the load flow of the power grid and eliminate the need to assign subjective weights to the different objectives. The proposed framework handles the objectives in a decentralized manner, which is advantageous as it reduces the need for expensive communication infrastructure and maintains the privacy and data of different buildings. The proposed framework optimizes the energy costs, demand charge costs and voltage regulation of the system simultaneously, which achieves Pareto optimality under different building modeling and operating conditions. The three developed data-driven models have been used in the multi-objective formulation one at a time to see how the modeling of buildings will affect the optimized objectives. The results showed that lower modeling flexibility resulted in higher voltage deviations. The results also showed that coordinated optimization results in lower costs, except for the support vector regression cost, when compared to the uncoordinated case.
A future extension of this paper is how to deploy relaxation techniques of the power flow to allow the use of the numerical optimization for both the building and network levels simultaneously. This will help to ensure faster and better convergence of the optimization and allow the algorithm to be used in real-time applications.
Author Contributions: Conceptualization, S.F. and G.T.; methodology, S.F.; validation, S.F. and G.T. and Q.Z.; formal analysis, Q.Z.; investigation, S.F. and Q.Z.; writing-review and editing, S.F. and Q.Z. All authors have read and agreed to the current version of the manuscript.
Funding: This research received no external funding.

Conflicts of Interest:
The authors declare no conflict of interest.

Abbreviations
The following abbreviations are used in this manuscript: