Intelligent Systems for Building Energy and Occupant Comfort Optimization: A State of the Art Review and Recommendations

Today, buildings consume more than 40% of primary energy in and produce more than 36% of CO2. So, an intelligent controller applied to the buildings for energy and comfort management could achieve significant reduction in energy consumption while improving occupant’s comfort. Conventional on/off controllers were only able to automate the tasks in building and were not well suited for energy optimization tasks. Therefore, building energy management has become a focal point in recent years, promising the development of various technologies for various scenarios. This paper deals with a state of the art review on recent developments in building energy management system (BEMS) and occupants comfort, focusing on three model types: white box, black box, and gray box models. Through a comparative study, this paper presents pros and cons of each model.


Introduction
Currently, buildings are responsible for preeminent amount of world's energy consumption and CO 2 emission. According to the European Energy Efficiency Commission (EEEC), buildings in the EU represent 40% of total primary energy consumption [1] and nearly 36% of CO 2 emission [2]. The energy generated from fossil fuels contributes considerable CO 2 emission and causes global warming. Consequently, the government authorities, regulators and policy makers have been influencing people in the direction of sustainable buildings by introducing energy efficiency policies. The International Energy Agency (IEA) specifies: "Globally, the wide deployment of best available technologies and energy efficiency policies could yield annual savings in buildings final energy use of roughly 53 exajoules (EJ) by 2050" [3]. This amount is equivalent to cumulative energy consumption by buildings in China, France, Germany, Russia, the United Kingdom and the United States in 2012 [4]. Therefore, optimization of energy consumption is crucial for healthy environment and sustainable development. Integration of renewable energies [5] and intelligent systems [6] to the buildings could achieve the estimated savings in energy consumption. However, efficient building energy consumption optimization is still a challenging task because of various parameters that affecting building energy consumption. These influential factors can be divided into major five types: 1. Building physical and thermal properties (thermal conductivity, specific heat, thickness, density, etc.) [7]. 2. Occupancy behaviour (occupancy activities, interaction with the building, etc.) [8]. 3. Building sector type and building energy policies (type of building, location, respective regional policies, etc.) [9]. 4. Population size (number of occupants presence, indoor activities) [10]. 5. Climatic conditions (outdoor dry bulb temperature, wind speed, outdoor relative humidity, solar radiation, etc.) [3].
Among these five influential factors, building physical properties, climatic conditions and occupancy behaviour have a direct impact on energy consumption. At the same time other parameters represents slightly minimal effect on the energy consumption. A study conducted on university buildings to evaluate the relationship between energy consumption and population size, user activities, and demand profiles reveals population size have a minimal impact on electrical energy consumption as compared to other parameters [10]. Generally, people spend 90% of their life in buildings [11], hence the maintenance of comfortable environment is important to assure occupants' health and productivity. The quality of occupants' living is determined by three comfort parameters: thermal comfort, indoor air quality and visual comfort. These three comforts are achievable by exploiting Heating, Ventilation and Air-Conditioning (HVAC) controller and lighting systems with natural resources (day lighting, outside temperature, etc.).
A Building Energy Management System (BEMS) is required to improve energy performance meanwhile ensuring improved occupants' comfort. Conversely, realisation of indoor comfort environments draws more energy to achieve and maintain the optimal comfort. Therefore a proper trade-off is required between energy and indoor comfort [12]. In this context, recent developments in the BEMS are focusing on smart technologies to address the gap between energy consumption and occupants' comfort.

Building Modelling Approach
Three main approaches have been used for building energy management systems: white box models, black box models and gray box models. White box models [13,14] are a physical modelling approach relying on thermodynamic and/or mathematical equations and engineering methods for energy modelling, analysis and control. White box-based modelling approach examples are the building energy analysis simulation software such as: EnergyPlus [15], Transient System Simulation Tool (TRNSYS) [16], eQuest [17], etc. These software tools basically are used during building planning and designing phases, prior to the building construction. They calculate overall energy consumption [18], HVAC design [19], operation scheduling, lighting information [20], etc., based on the detailed building physical properties [21], occupancy schedule, geographical conditions, and type of building and climatic parameters. However, availability of such precise data for the simulation is troublesome and in some cases impossible to obtain. Also, due to the non-linear behaviour of building parameters, white box models are suitable for simple models and as when applied to complex buildings, the model tends to be thermodynamically complex.
Black box models are data driven building energy models, which are built on data basis [22][23][24][25][26] often considered as easy to model over physics-based white box models. Generally, black box models are applied for prediction of energy consumption [25], HVAC operation scheduling [27], and adaptive control systems [28]. Black box models methods examples are Artificial Neural Networks (ANNs), Support Vector Machine (SVM), Genetic Algorithms (GAs), Reinforcement Learning (RL), deep machine learning [29], etc. Aside from the ease to apply, black box models require large input data to train the model [30]. This data may not be available in buildings in which sensors are not installed, thereby limiting their application to the few buildings with installed sensors.
To overcome white box and black box models drawbacks, hybrid models were introduced [31]. Hybrid models (gray box models) are combination of physics-based models (white box models) and statistical methods (black box models). Gray box modelling is found out as robust and accurate for building systems modelling and in building performance improvement [31].

Indoor Comfort Parameters
People spend most of their time in buildings. Maintenance of indoor comfort parameters is therefore significant to improve occupants productivity, health, and comfort feeling [32]. Thermal comfort in indoor environment is the principal component for ensuring indoor environment quality. Thermal comfort is generally expressed as the satisfaction of thermal environment, usually referred as psychological sensation of thermal environment [33]. Visual comfort is another parameter affecting the indoor environment quality. Basically, proper illumination level is essential for commercial, institutional, and industrial buildings to preserve inhabitants working efficiency.

Objectives and Motivation
Several literature reviews have been previously published in building energy and comfort management context. Dounis and Caraiscos [34], reviewed advanced control systems for energy and comfort optimization covering various control strategies, whereas Lombard et al. [35] detailed building energy consumption by building types and HVAC systems. Zhao and Magoulès [36] summarized various building energy consumption prediction methods based on classification; engineering model, statistical model, neural networks, support vector machines, and gray models. Amasyali and El-Gohary [37] elaborated data driven prediction methods and in addition, Wei et al. [38] discussed classification of building energy consumption. Previous literature studies have discussed various building energy management systems, prediction of energy consumption, and occupancy relation with buildings. However, a clear gap is observed for the consideration of recent developments in control strategies for optimal energy and comfort management in buildings. In this state of the art paper, the recent developments in BEMS methods along with indoor comfort conditions were discussed in detail and critically reviewed. Besides, the review papers are selected from the year 2013 onwards (around 80% papers) for clearly focus on recent developments. An elementary related research was conducted by using search engine and scientific websites: Google scholar, Science Direct and IEE explore digital library. The keywords 'building energy management', 'building comfort management', 'intelligent systems for buildings', and 'building control' were used for filtering papers to perform the review process. Papers were only selected from top international journals and indexed conference proceedings. Based on the selection criteria, 90 papers were further considered for this state of the art review.
The content of the paper is organised as follows: Section 2 reviews studies of recent developments in building energy management systems based on their model type, Section 3 details and discusses the literature review observations. Main conclusions and future investigations are described in Section 4.

Building Energy Management Systems-BEMS
BEMS are generally installed in buildings to monitor and control indoor comfort conditions and energy consumption [18]. These systems are mainly based on sensors, actuators, software, and hardware networks [6,39]. Normally, buildings with few occupants (residential, and office buildings) may permit to interact with BEMS technologies via a human machine interface (HMI) [40] to control electrical appliances and HVAC system operation. These interactions could be restricted in institutional, commercial, and industrial buildings because of the large number of occupants, where each may posses a unique set point, resulting in higher energy consumption. Hence, HVAC system operating values are set to a standard range to maintain indoor comfort in such buildings. However, heterogeneous parameters affecting building energy and comfort hinder the performance of BEMS models.

White Box Models
White box models are thermal dynamics modelling, which are based on fundamental laws of physics, thermodynamics, and heat transfer. Generally this approach can be roughly classified into two types: physics-based models using simulation tools such as: TRNSYS, EnergyPlus, etc., and physics governing laws-based thermal dynamics state-space equation or lumped capacitance model [41].
Due to the diversified and heterogeneous behaviour of building parameters, complexity of hardware network (sensors, and actuators), and occupants interaction with buildings, it is difficult to carry out full scale experiments. Hence, software tools are affordable and ease-to-use platforms that can be used for building dynamics evaluation and analysis. Numerous software tools have been developed over the last few decades for the analysis of energy consumption, HVAC design, operation scheduling, lighting information, renewable energies, etc., Regular up-gradation is performed on these simulation tools to improve the performance efficiency and decreasing computational cost. The list of US Department of Energy (DOE) organisation approved building simulation tools is available in [42].
EnergyPlus is a building energy performance analysis simulation software and console-based program that reads inputs and writes outputs in text files, developed based on DOE-2 [43] and the Building Loads Analysis and System Thermodynamics (BLAST) by National Renewable Energy Laboratory(NREL) and U.S. DOE Building Technologies Office (BTO) [15]. Zhao et al. [44] used EnergyPlus to procure raw data for commercial building to perform overall energy performance and dynamic pricing by using Cyber Physical Systems (CPS)-enabled BEMS [45]. Furthermore, a fuzzy logic controller (FLC) is initially designed based on the data probation from EnergyPlus and a GA method applied to FLC for evolution of improved member functions population for improved comfort control energy optimization of a food service center. The results were compared with stand-alone EnergyPlus output and investigated that the GA-FLC-based method resulted notable decrease in energy consumption during both cooling and heating [46]. This shows that EnergyPlus lacks interactive control optimization techniques and would be coupled with other dynamic computational software (Matlab, Modelica [47]) via co-simulation software building controls virtual test bed (BCVTB). Kim et al. [19] used EnergyPlus for training ANNs and coupled GA for optimization of integrated daylighting and HVAC systems. This was performed to ensure large database available for training ANNs in less time, otherwise 3 months would have been needed to procure data from sensors. A multi-objective optimization strategy is validated using non-dominated sorting genetic algorithm (NSGA), implemented in the GenOpt [48] optimization engine through the Java genetic algorithms package, to instruct the EnergyPlus simulation tool [12]. Meanwhile, Huh et al. [49] developed a system to generate predicted real-time weather data for 24 h duration using EnergyPlus coupled with GenOpt through BCVTB [50]. This approach improves the building energy control optimization based on real time prediction control.
TRNSYS (Transient systems simulation program) is a dynamic computational software for building energy performance analysis [16]. It is incorporated with Matlab for database generation to train 2 ANNs used for predictive and adaptive approach applied to hotel building. The developed model efficiently improved thermal comfort and building energy optimization during summer season resulting in 18-38% energy savings over the simulation period [28]. TRNSYS was used for determining building cooling load needed from the chiller plant, Later, these data were fed to Matlab for performing optimization analysis [51].
BCVTB is used for coupling various simulation tools for co-simulation and co-simulation to hardware. Refs. [13,46,52] used BCVTB to ease the simulation process by coupling EnergyPlus, Matlab in their model for building energy performance analysis. Meanwhile, BCVTB was coupled with EnergyPlus to generate real-time weather data file for energy consumption prediction in one day [49]. Figure 1 shows the process of generating a weather data file based on the forecasted weather using BCVTB as a coupling platform between EnergyPlus and other tools. The weather elements from weather forecast by national weather station, calculated weather parameters, measured weather elements, and default parameters are coupled together in BCVTB platform for generating weather forecast. Although simulation tools are the first choice for building energy performance analysis because of accuracy and effectiveness, they require proper data of building, weather parameters, and physical properties. However, collecting appropriate data is always difficult and in some cases these data are not available. This is the major challenge in retrofitting existing buildings. In addition, these tools lack controller development flexibility and absence of high performance controller systems in their libraries yields difficulty to develop and integrate in practical application/implementation [53].

Black Box Models
These are also known as data-driven models and are developed based on statistical models by quantifying historical data parameters and correlating between building performance and data to find optimal pattern. Data-driven model approach is often considered as less complex with high accuracy and low computational cost. However, the inner process is mostly unknown, leading to reduced control flexibility of the overall process. The primary requirement of black box models are pre-collected data. These can be obtained from following sources: • Real data collected from existing building through sensors, smart meters, and other smart systems [54]. • Simulated data collected from the simulation tools such as EnergyPlus, BCVTB, etc., [30]. • Standard data available in public benchmark datasets such as ASHRAE's data [23].
Indoor comforts are influenced by various parameters, especially weather conditions (e.g., wind speed, air temperature, and humidity) that are volatile in nature. In such conditions, indoor thermal comfort can be rapidly affected and could cause excessive energy consumption to maintain temperature range. To maintain indoor thermal comfort under a given range despite of rapid changes in influential parameters, a prediction model and temperature controller is introduced by Marvuglia et al. [54]. In this framework, outdoor temperature, air relative humidity, wind speed, and indoor temperature data are used to train artificial neural network with external inputs (NNARX) model and predicted values fed to fuzzy logic controller to maintain indoor temperature in a given range. Results show good efficiency of predictions and temperature controller. Mararulla et al. [27] implemented ANN-based predictive controller to a commercial building energy management system for operation of boilers in buildings, shown in Figure 2. This method resulted in around 20% reduction in energy required to heat the building. The ANN implementation is illustrated in Figure 2, where data obtained from the simulation tool are fed to the ANN with 10 neurons in each hidden layer and predicted results are given to BEMS for optimal operation. In 2016, Ascione et al. [22] used feed-forward multilayer perceptron (MLP) ANN structure to predict building energy and thermal behaviour in retrofit scenarios, which produced significant prediction values. Furthermore, the authors indicated that the number of hidden layers highly influences the ANN performance. Additionally, the importance of training data size is discussed in [30,63], both concluded that larger the training data sample is, the better the performance of ANN model.
Normally, residential buildings have non-constant occupancy and maintenance of thermal comfort for whole day leads energy wastage. Hence prediction of unoccupied hours was performed by [28] by using ANN algorithm and prediction of time required for restoration of indoor temperature to set-point temperature using another ANN model. Multi-Objective Genetic Algorithm (MOGA) controller have been efficient technologies in attaining balance between energy consumption and thermal comfort [64] and with hybrid MOGA author achieved around 31.6% energy management efficiency and 71.8% comfort index efficiency. Triple objective controller using particle swarm optimization (PSO) has been developed by [21], which achieved 19.8-33.3% decrease in annual cooling energy, while increasing in annual heating and lighting: 1.7-4.8% and 0.5-2.6% respectively. Final optimization resulted 1.6-11.3% reduction in annual electricity consumption for four climate regions in Iran. Whereas, O'Neill et al. [65] developed Bayesian networks (BNs) [66] model to predict hourly building energy performance with associated uncertainties. The BNs-based building energy performance prediction system can be applied in various scenarios: (1) Retrofitting buildings; (2) Model-based optimization systems; and (3) Energy diagnostics.
Occupancy's thermal comfort sensation of hot or cold mainly depends on subjective parameters (metabolic rate and clothing insulation) and physical ones (mean radiant temperature, air temperature, air velocity, and relative humidity) as described by Fanger's predicted mean vote (PMV) and predicted percentage of dissatisfied (PPD) model-ISO 7730. This method was developed in 1960-1970 and is still used as a baseline model for comfort measurement. Fanger's base model advancements over the last 40 years are critically reviewed in [67]. An existing HVAC system can optimize PMV index with conventional controller, however, a fuzzy logic-based system is integrated to existing HVAC system to maintain PMV, CO 2 , and energy consumption for efficient building performance [68]. This fuzzy logic's member function together with rule selection were then tuned by multi-objective evolutionary algorithms (MOEA-GA) to minimize number of rules and thus maximizing system performance. This proved to be the best combination for FLC's with reduced number of rules to maintain PMV and optimizing energy consumption. Table 1 gives the standard values for thermal sensation scale of PMV in which +3 being very hot and −3 being very cold. It is always suggested that the PMV value should be maintained within −0.5 to +0.5 to achieve better thermal comfort. The comfort classification based on relationship between PMV and PPD is shown in Table 2 [69]. Chen et al. [70] developed data-driven state-space Weiner model to evaluate the dynamic relation between dry bulb temperature variation and occupant thermal sensation. Later they compared developed model to dynamic thermal sensation (DTS). The DTS model is a reactive thermal comfort system with constantly changing its values based on the dynamic variation of weather conditions and occupant preferred thermal sensation votes delivered by an extended Kalman filer (EKF) with feedback system. Furthermore, predicted mean vote and dynamic thermal sensation models were compared by developing MPC-DTS and MPC-PMV. Results indicated that the MPC-DTS achieved better thermal comfort and energy optimisation than the MPC-PMV model, but both efficiently maintained thermal comfort compared to the baseline model using proportional integral (PI) controller. However, they assumed that there is a feedback system in BEMS, which actually is not the case. Later, Chen et al. [71] conducted the same experiment to investigate the performance difference between MPC-DTS and MPC-PMV with real time actual mean vote feedback values, in addition authors detailed the probable reasons for performance difference.
The above mentioned researches mainly focus on optimization techniques used to achieve comfort measurement. However, the accuracy of subjective and physical parameters measurement taken from sensors has a significant impact ion the PMV index evaluation. These measurement uncertainties can be evaluated using efficient tools such as: monte carlo analysis (MCA) [72], guide to the expression of uncertainty in measurement (GUM) [73], and sensitivity analysis (SA) [69]. These studies show that the proper handling of measurement uncertainties is essential in PMV index model.

Class Percentage of Dissatisfied (%) Predicted Mean Vote
Black box models are less complex, does not need complete data of building physical parameters, efficient performance, and easy to build. Nevertheless, they require huge building operational and environmental parameter data for training in order to have efficient prediction values. These data are however difficult to obtain, while low quality data can cause huge prediction error. Even though, these models are accurate and less complex, the lack of knowledge/explanation of the inner processes from the point of view of physics, there is some reluctance towards black box model implementation over physics-based model.

Gray Box Models
The third category of BEMS is known as gray box models. These are hybrid ones combining simplified physics-based models and data-driven ones. In a gray box model, the process is expressed in mathematical expression that may be based on the physics and/or thermodynamics laws. They consist expressions that have physical explanation (e.g., resistor capacitance network) and a part of the model may be obtained through regression from the available data.
A gray box model is a balanced model between the white box model and black box model. This combination ensures that the non-linearities in white box model can be handled using black box models and lack of laws of physics reasoning in black model can be represented through white box models, but extra effort is required to design and develop these models. However, selection of suitable gray box model structure for developing a good performance system is still a difficult task. Bacher and Madsen, ref. [7] proposed an approach to find appropriate heat dynamics of a building. Indeed, a set of different RC network models have been configured and compared using likelihood ratio tests. The study concludes that significant improvements can be obtained as the model order increases, while no further notable improvements can be expected beyond a model order of 3. Široký et al. [74] proposed an experimental analysis of a heating system using lumped capacitance network in a university building and analysis was carried out for two months. Through this approach they were able to achieve around 15% and 28% energy savings. The experimental analysis not only investigated the performance of MPC but also detailed the issues that can be encountered in its application. Figure 3 illustrates the basic principle of MPC model structure [74], the inputs of the systems are time varying parameters: energy price can be taken from energy market, comfort conditions set by the occupants, occupancy prediction, and environmental parameters. The MPC system formulates the optimization of an objective function by using building dynamic model, a cost-function and constraints. After each time sample formulation, feedback from occupants and weather conditions are fed back to MPC for the formulation of next time sample, which ensures that unanticipated disturbances are taken in consideration through feedback loop. A simplified low order gray box modelling has been introduced in [75]. The study considered a whole building as single zone building (Figure 4) neglecting the inter-zone heat exchange. Most of the studies in literature did not take account of inter-zone thermal interactions as it increases the complexity of the model and includes numerous uncertainties. In addition, the model perform-ability declines with the increase of the number of zone. However, Cai and Braun [76] proposed a resistance capacitance thermal network model for multi-zone buildings ( Figure 5) with a unique three-step estimation approach to reduce the complexity of the model and thus improving the performance of BEMS system, through: • De-grouping weakly linked zones and grouping strongly linked zones.
• Sensitivity analysis to identify and eliminate non-influential variables. • Correlation analysis to eliminate Non-correlated variables. Performance of BEMS system is significantly increased because of the above-considered three steps, which have simplified the estimation problem by eliminating non-influential parameters. In general, gray box models can be used for predictions of energy consumption, thermal comfort conditions, occupancy, and heating/cooling load of buildings. These applications leads to use gray box modelling to building in smart Grid context for dynamic load management and energy storage. The reduced order gray box model for buildings connected to smart Grid was investigated in [31], where it is applied on two buildings types (insulated and uninsulated). Furthermore, Sharma et al. [77] presented a study of MPC controller implementation for buildings in centralized energy management system framework (CEMS). In addition, The insulated buildings opens the possibilities of enabling demand-side management (DSM) by exploiting heat capacity flexibility in building thermal wall mass. Harb et al. [78] developed gray-box models for forecasting the building thermal response. The analysis was conducted on four gray box models and data from three building. Building areas varied from 3000 to 30,000 m 2 and data duration from 39 to 110 days. To determine thermal behaviour of the building, three forcing functions were used in this paper:

•
Radiative building environment is expressed as the solar irradiation.

•
Building thermal environment is represented by the outdoor air dry temperature.

•
Various heat sources consists of heating elements.
From the above a three-function input vector is constructed: where T a -outdoor dry bulb temperature, Q irrad -global solar radiation on horizontal surface, and φ h -Building thermal consumption. Four gray box model structures were developed in this paper: (1) 1R1C-the simplest structure characterizes the whole building into a single parameter ( Figure 6); (2) 3R2C-consists of three resistors and two capacitors. Three resistors indicate convective and radiative heat exchange, and heat exchange between interior to environment, two capacitor indicates interior and exterior thermal mass (   The achieved results show that the 1R1C model produced more harmonics in the prediction values due to its simple structure, the 3R2C have produced similar disturbances in indoor air temperature prediction, due to the lack of consideration of heat exchange between indoor and outdoor air temperature. The 4R2C produced accurate prediction in daily indoor temperature prediction, due to the consideration of heat exchange between various parameters. The 8R3C produced similar accurate prediction values with no significant improvements in the results despite the detailed model. The 4R2C model can thus be considered as the suitable structure for implementation because of its accuracy and low complexity. From the achieved results it can be concluded that the addition of indoor air temperature node (4R2C and 8R3C) provides stable prediction values compared to model without indoor air temperature node (1R1C and 3R2C).
Meanwhile, application of MPC systems for building energy and comfort management has gained larger attention, Sturzenegger et al. [79] applied MPC strategy on commercial building of 6000 m 2 area for energy and comfort control. The results are later compared with existing rule-based control systems. The analysis of MPC implementation proved that energy savings were around 17% with an improved comfort level.
The above-described studies have shown that gray box models are robust, accurate, and applicable to complex buildings. However, these models posses high computational cost making them only profitable in applications for commercial buildings. Further investigations are needed to ensure adaptability and application for small buildings.

Observations and Discussion
This paper mainly focused on review of recent development in intelligent controller systems applied to building energy and comfort management. Several papers have been reviewed in this paper and around 80% of the papers are from the year 2013 onwards. The reviewed papers are arranged in descending chronological order in Table 3, which highlights the carried out review. The listed papers does not consider the total number of reviewed papers. Indeed, these ones have different control strategies, methods, objective parameters, and applications. Some assumptions are made for this literature review's observations:

•
Buildings in the context of smart-grid are considered as residential ones.

•
Apartments with large commercial space are considered as non-residential buildings.

•
Grid is considered to be a supply source for papers without specific indication on the supply source.

•
Demand side management and load shifting are considered as dynamic pricing.
Based on the above-given assumptions, the following observations have been made. The carried out review shows that research majority is conducted on non-residential buildings, around 66%, and residential ones, being 34% ( Figure 8). Non-residential buildings include: institutional, public, office, swimming pool, hospital, and hotel buildings. This lack of research may be due to the unavailability of data or controller systems. Figure 9 illustrates control strategies applied for both building types, where black box models are dominating with 74% and 67% of the overall applied controllers for residential and non-residential buildings, respectively. Significant researches have therefore been conducted on black box models due to their ease of application. Around 21% and 27% gray box models were applied to residential and non-residential building, respectively, while gray box models were less used in residential cases compared to non-residential ones mainly because of their high computational and design costs. Simulation tools combined with other control strategies are used for building energy performance analysis but the standalone use is low because of their complexity and high data acquisition cost. Cluster analysis Residential n/a n/a n/a n/a n/a n/a n/a WEKA [     Th-Thermal, Lt-Lighting, AQ-Air Quality and RH-Relative Humidity.

34.0%
Non-residential 66.0% In the context of comfort parameters, thermal comfort acquired more importance in both non-residential and residential buildings, whereas, other parameters are taken into consideration in few papers ( Figure 10). This indicates the significance of thermal comfort in overall indoor comfort sensation and optimization of thermal energy leads great amount of overall energy consumption reduction in comparison to other comfort variables energy consumption optimization. There is a major lack in consideration of indoor air quality and lighting control. However, regulations and standards urge maintenance of CO 2 and luminance level in order to keep occupants good health and productivity, hence more research on this topic is necessary. Only 5% of the papers have developed controller for all four comfort parameters control. This shows the difficulties in implementation of controller for overall indoor comfort management.
Towards sustainable development, installation of renewable energies are important. This factor has also been considered in the literature review. The literature review highlights 16% and 23% renewable energies integration into non-residential and residential buildings, respectively ( Figure 11). Most of RES integration is observed in smart grid and in big buildings context. The dynamic response in energy consumption by loads is an effective way of maintaining grid balance, grid durability, and cost optimization. Around 22% of non-residential and 25% of residential buildings have adopted DR. In Figure 12, it can be noticed the controller types used for DR application in both building types. Gray box modelling has higher implementation percentage because of the high flexibility for multi-objective optimization. Controllers used for RES integration are shown in Figure 13, where it should be noticed that black box models have higher percentage of implementation in residential buildings and gray box modelling in non-residential ones. This difference can be justified as follows: (1) Gray box models are characterized by high accuracy and higher computational cost that limit their usage only for large buildings; while (2) black box models are characterized by high accuracy and lower flexibility of MIMO that limit their application to multi-objective optimization purpose. In the literature review, it had been found that black box models includes controllers such as fuzzy logic, artificial neural networks, genetic algorithms, decision trees, particle swarm optimization, reinforced learning, etc., while gray box models includes lumped capacitance model, model predictive controller, hybrid systems, etc. Residential Non-residential Figure 10. Controller application on comfort parameters.

Conclusions
This paper has dealt with a state of the art review of recent developments on building energy and comfort management, and the related control. The carried out investigations includes explanation of conventional controllers and their up-gradation to the current challenging applications and new methods viz., black and gray box modelling. These models have been compared and critically reviewed on the basis of comfort conditions, RES integration, DR application, and building type. The proposed critical review will be useful for engineers and researchers in selection of suitable controller methods for BEMS model based on various conditions. In addition, the following observations, comments, and recommendations should be helpful.

•
All the comfort parameters (thermal, visual, air quality, and relative humidity) need to be controlled in the building to ensure occupants' health and productivity. However, thermal comfort control remains dominant as the other parameters have a minimal impact on energy consumption. In addition, these parameters inclusion may introduce complexity in the controller model and leads to poor performance. • White box models have been investigated as preliminary models for building energy performance analysis and were found to be used for low scale application. However, the white box application is restricted only for initial analysis and is not efficient to implementation due to its limitations. • Black box models have high accuracy, low computational cost, and higher flexibility for building non-linearities. These models have gained significant attention in recent years. Constant developments of new algorithms ensures the improved efficiency and suitable for multi-objective applications. Nevertheless, these applications have restricted implementation due to lack of physics-laws explanation and huge amount of data is required for model training.

•
Gray box models are found out to be more feasible for multi-objective optimization, predictive/adaptive, and cost-optimization applications, where design and computational time are high. This makes them not suitable for low scale applications.
Significant improvements can be noticed in intelligent controller for BEMS applications. The developments of new algorithms, and combination of various intelligent methods have ensured development of buildings towards sustainable environment. However, there is still lack of proper trade-off between energy and comfort parameters, thus further investigations in this area are still needed. The following are few future perspective points:

•
Further research required on air quality and lighting parameters.

•
Research efforts towards gray box models for residential buildings.
• Integration of RES into buildings still requires research efforts with feasible and uninterrupted energy supply. • Dynamic response (dynamic pricing) for energy consumption is yet to be implemented in large scale applications. • Development of new methods with IoT technologies will push towards more intelligent building models.

•
Research efforts towards adaptive building controller models.
Author Contributions: All the authors contributed equally for elementary related research, papers selection, literature survey, discussions, and state of the art review of the paper.
Funding: This research received no external funding.

Conflicts of Interest:
The authors declare no conflict of interest. The founding sponsors had no role in the design of the study; in the collection, analyses, or interpretation of data; in the writing of the manuscript, and in the decision to publish the results.

Abbreviations
The following abbreviations are used in this manuscript: