Learning Individual Thermal Comfort using Robust Locally Weighted Regression with Adaptive Bandwidth Carlo Manna and Nic Wilson and Kenneth N. Brown1 Abstract. tical measure which assumes a large number of people experiencing Ensuring that the thermal comfort conditions in offices are in line the same conditions, and so may be inaccurate for small groups, or with the preferences of the occupants, is one of the main aims of for variable conditions and behaviours within the space, and (iii) it a heating/cooling control system, in order to save energy, increase requires an expensive iterative evaluation to compute the root of a productivity and reduce sick leave days. The industry standard ap- nonlinear relation. proach for modelling occupant comfort is Fanger’s Predicted Mean In this paper, we propose an alternative approach tailored to in- Vote (PMV). Although PMV is able to predict user thermal satis- dividual occupants, which relies on historical data on individual re- faction with reasonable accuracy, it is a generic model, and requires sponses to internal environment conditions. We apply Robust Locally the measurement of many variables (including air temperature, radi- Weighted Regression [23] with an Adaptive Bandwidth (LRAB), a ant temperature, humidity, the outdoor environment) some of which statistical pattern recognition methods, to learn, automatically, the are difficult to measure in practice (e.g. activity levels and clothing). comfort model of each user based on their history. As a preliminary As an alternative, we propose Robust Locally Weighted Regression study, we applied this method with only one input variable (internal with Adaptive Bandwidth (LRAB) to learn individual occupant pref- air temperature) and compared with PMV, using publicly available erences based on historical reports. As an initial investigation, we datasets [18]. Our experimental results show that LRAB outperforms attempt to do this based on just one input parameter, the internal air PMV in predicting individual comfort, and hence it is a promising temperature. Using publicly available datasets, we demonstrate that technique to be used as input to heating/cooling control systems in this technique can be significantly more accurate in predicting indi- office environment. vidual comfort than PMV, relies on easily obtainable input data, and The paper is organised as follows: in the next section, some back- is fast to compute. It is therefore a promising technique to be used as ground on PMV and on alternative techniques are reported. Then, in input to adpative HVAC control systems. the section 3, the proposed method is described and in the section 4, the experimental results using a public dataset [18] are shown. Fi- nally, in the section 5, conclusions and future directions are reported. 1 INTRODUCTION One of the primary purposes of heating, ventilating and air condition- ing (HVAC) systems is to maintain an internal environment which is 2 BACKGROUND comfortable for the occupants. Accurately predicting comfort levels The conventional PMV model has been an international standard for the occupants can enable one to avoid unnecessary heating or since the 1980s [3,4]. It has been validated by many studies, both in cooling, and thus improve the energy efficiency of the HVAC sys- climate chambers and in buildings [5,6,7]. The standard approach to tems. A number of thermal comfort indices (indicators of human comfort-based control involves regulating the internal environment comfort) have been studied for the design of HVAC systems [1,2], variables to ensure a PMV value of zero [8,9,10,11,12]. the most widely used of which is the Predicted Mean Vote (PMV) The PMV model parameters are based on field studies over large index, which was developed by Fanger [1]. This conventional PMV populations experiencing the same conditions. For small groups of model predicts the mean thermal sensation vote on a standard scale people within a single room or zone in a building, however, PMV for a large group of people in a given indoor climate. It is a function may not be an accurate measure. Kumar and Mahdavi in [17] anal- of two human variables and four environmental variables, i.e. cloth- ysed the discrepancy between predicted mean vote proposed in [1] ing insulation worn by the occupants, human activity, air tempera- and observed values based on a meta-analysis of the field studies ture, air relative humidity, air velocity and mean radiant temperature. database made available under ASHRAE RP-884 [18] and finally The values of the PMV index have a range from -3 to +3, which cor- proposing a framework to adjust the value of thermal comfort in- responds to the occupants thermal sensation from cold to hot, with dices (a modified PMV). The large field studies on thermal comfort the zero value of PMV meaning neutral. described in [27], have shown that PMV does not give correct pre- However, PMV has some drawbacks: (i) it requires many environ- dictions for all environments. de Dear and Brager [28] found PMV to mental data whose retrieval is costly due to the sensors needed, and be unbiased when used to predict the preferred operative temperature it requires precise personal dependent data (i.e., clothing and activity in the air conditioned buildings. PMV did, however, overestimate the level) which are often difficult to obtain in practice; (ii) it is a statis- subjective warmth sensations of people in warm naturally ventilated 1 Cork Constraint Computation Centre, Department of Computer Sci- buildings. Humphreys and Nicol in [29] showed that PMV was less ence, University College Cork, Ireland, e-mail: c.manna@4c.ucc.ie, closely correlated with the comfort votes than were the air temper- n.wilson@4c.ucc.ie, k.brown@cs.ucc.ie ature or the mean radiant temperature, and that the effects of errors Workshop on AI Problems and Approaches for Intelligent Environments (AI@IE 2012) 35 in the measurement of PMV were not negligible. Finally the work in proaches to predicting thermal comfort through the automatic learn- [30] also showed that the discrepancy between PMV and the mean ing of the comfort model of each user based on his/her historical comfort vote was related to the mean temperature of the location. records. We apply the Robust Locally Weighted Regression [23] In addition to the relative inaccuracy, the PMV model is a nonlin- technique with an Adaptive Bandwidth (LRAB), one of the fam- ear relation, and it requires iteratively computing the root of a nonlin- ily of statistical pattern recognition methods. Non-parametric regres- ear equation, which may take a long computation time. Therefore, a sion methods, or kernel-based methods, are well established meth- number of authors have proposed alternative methods of calculation ods in statistical pattern recognition [24]. These methods do not to the main one proposed in [1]. Fanger [1] and ISO [4] suggest us- need any specific prior relation among data. Hence, there are no pa- ing tables to determine the PMV values of various combinations be- rameter estimates in non-parametric regression. Instead, to forecast, tween the six thermal variables. Sherman [13] proposed a simplified these methods retain the data and search through them for past simi- model to calculate the PMV value without any iteration step, by lin- lar cases. This strength makes non-parametric regression a powerful earizing the radiation exchange term in Fanger’s model. This study method due to its flexible adaptation in a wide variety of situations. indicated that the simplified model could only determine precisely The Robust Locally Weighted Regression is one of a number of non- when the occupants are near the comfort zone. Federspiel and Asada parametric regressions. It fits data by local polynomial regression and [14] proposed a thermal sensation index, which was a modified form joins them together. This method was first introduced by Cleveland of Fanger’s model. They assumed that the radiative exchange and [23] and further developed for multivariate models [25]. the heat transfer coefficient are linear, and they also assumed that the clothing insulation and heat generation rate of human activity are constant. They then derived a thermal sensation index that is an 3 THE PROPOSED METHOD explicit function of the four environmental variables. However, as The proposed method is largely inspired by the work in [23]. In the the authors said, the simplification of Fanger’s PMV model results following, we will only describe the proposed LRAB method, while in significant error when the assumptions are not respected. On the for a more general description of the robust locally weighted regres- other hand, in [15] and [16] different approaches have been proposed sion, the readers should refer to the work in [23]. in order to compute PMV avoiding the difficult iterative calculation. Before giving precise details on the LRAB procedure, we attempt The former proposes a Genetic Algorithm—Back Propagation neu- to explain the basic idea of the method. Let (xi , yi ) denote a re- ral network to learn user comfort based both on historical data and sponse, yi , to a recorded value xi , for i = 1, . . . , n. In this paper real-time environmental measurements. The latter proposes a neural xi denotes an environmental variable (in our case air temperature) network applied to the iterative part of the PMV model that, after a and the response yi represents the satisfaction degree (integer-valued learning phase, based on historical data, avoids the evaluation of such on a 7-points scale from −3 to +3) that the user has given in re- iterative calculation in real-time. sponse to the condition xi , and then stored in a database. The aim is Finally, recent trends in the study of the thermal environment con- to assess the response yˆk (i.e. predict the degree of satisfaction) for ditions for human occupants are reported in the recently accepted a input value xk . The approach aims to estimate a local mean, fitting revisions to ASHRAE Standard 55, which includes a new adaptive the recorded data by means of a local linear regression centered at comfort standard (ACS) [19]. According to de Dear and Brager [20] xk . This involves, for a fixed entry point xk , solving a least squares this adaptive model could be an alternative (or a complementary) the- problem, where αk and βk are the values that minimize: ory of thermal perception. The fundamental assumption of this alter- native point of view states that factors beyond fundamental physics � n � �2 and physiology play an important role in building occupants expec- yi − αk − βk (xi − xk ) ω(xi − xk ; h) (1) tations and thermal preferences. PMV does take into account the heat i=1 balance model with environmental and personal factors, and is able to account for some degrees of behavioral adaptation such as changing Then αk is the response yˆk for the point xk . The kernel function one’s clothing or adjusting local air velocity. However, it ignores the ω(xi − xk ; h), is generally chosen to be a smooth positive function psychological dimension of adaptation, which may be particularly which peaks at 0 and decreases monotonically as |xi − xk | increases important in contexts where people’s interactions with the environ- in size. The smoothing parameter h controls the width of the kernel ment (i.e. personal thermal control), or diverse thermal experiences, function and hence the degree of smoothing applied to the data. This may alter their expectations, and thus, their thermal sensation and procedure computes the initial fitted values. Now, for each (xi , yi ), satisfaction. In particular, the level of comfort perceived by each in- a different weight, ψi is defined, based on the residual (yˆi − yi ) dividual also depends on their degree of adaptation to the context and (the larger the residual, the smaller the associated weight). Then, the to the environmental changes, and therefore the specificity of each function (1) is computed replacing ω(xi − xk ; h) with ψi ∗ ω(xi − individual should be taken into account to learn and predict comfort xk ; h). This is an iterative procedure. satisfaction. For this reason, some authors have proposed techniques based on learning the perception of comfort by individuals. For example, in 3.1 Kernel function and Adaptive bandwidth [21] the author proposes a system able to learn individual thermal In the following we introduce the concepts of kernel function (and preferences using a Nearest Neighbor Classifier, taking into account adaptive bandwidth) and residuals, then we describe the algorithm in only four variables (air temperature, humidity, clothing insulation details. There are many criteria to choose the kernel function based and human activity), acquired by means of wearable sensors. In [22], on the theoretical model of the function that has to be fitted. For a a Nearest Neighbor Classification-like method was implemented in locally weighted regression, a common choice is a tri-cubic function, order to learn individual user preferences based on historical data, which generally can be written as: ω(u) = (1 − |u|3 )3 , for |u| ≤ 1, using only one variable (air temperature). and ω = 0 otherwise [23]. Starting from these considerations, we In this study we consider such alternative and more practical ap- propose a similar kernel function: 36 Workshop on AI Problems and Approaches for Intelligent Environments (AI@IE 2012) � � |x − x | �3 �2 median of the |ρi |. As described in [23], we now choose robustness i k ω(xi − xk ; h) = 1− (2) weights by: h for |xi − xk | ≤ h; otherwise ω = 0. The outer exponent is 2 (in ψi = Γ(ρi /6m) (5) place of 3 as in the standard tri-cubic function), because of empirical considerations (preliminary experiments on smaller set of data were At each step of the proposed procedure, the equation (5) is used to carried out to select the shape of the kernel function). update the weight of the function (2) based on the residual ρi . In this Finally, we need to choose the bandwidth h. The choice here needs way the value of the kernel function (2) at each recorded points xi , to take into account the fact that the density of the recorded data is decreased (increased) where the residual value in xi (i.e. ψi ) is too may be variable. In particular, there may be areas in which the data high (too low), so as to improve the regression for the next step. are clustered closely together (which suggests that a narrow band- width would be appropriate), while, on other hand, other areas may 3.3 The algorithm be characterised by sparse data (in which case a choice of a large bandwidth is better). In view of this, it would be appropriate to have The proposed method can be described by the following sequence of a large smoothing parameter where the data are sparse, and a smaller operations: smoothing parameter where the data are denser (Figure 1). In this sit- uation an adaptive parameter has been introduced. Let the ratio ν/n LRAB (where ν < n), describes the proportion of the sample which con- tributes strictly positive weight to each local regression (for example 1: Initialize: set parameters ν if the ratio is 0.7, it means that 70% of the recorded data contributes 2: For each entry point xk : to the regression). Once we have chosen ν/n (that means we have 2.1: minimise (1) chosen ν, as n is fixed), we select the ν nearest neighbours from the 2.2: while iterations < max iterations do: new entry point xk . Then, the smoothing parameter h is denoted by 2.2.1: for each i compute (5) the distance of the most distant neighbour among the ν neighbours 2.2.2: minimise (1) replacing ω with ψi ∗ ω selected. It should be noted that the entire procedure requires the 2.3: end while choice of a single parameter setting. 3: end The algorithm is initialized by setting only one parameter (step 1). Then, for each new entry point xk (step 2), it first computes an initial fitting (step 2.1), then it strengthens the initial regression by the steps 2.2.1 to 2.2.2, performing the sub-procedure described in the previous section, iteratively. If we have K new entry points xk in total, the steps from 2.1 to 2.3 are repeated K times (one time for each new entry point). 4 EXPERIMENTS This section describes the experimental results obtained from a com- parison between the proposed method and the PMV. Although PMV Figure 1. In locally weighted regression, points are weighted by proximity is not based on a learning approach, in this paper, we compare our to the current xk in question using a kernel function. A linear regression is method with PMV since the latter is the international standard used then computed using the weighted points. Here, an adaptive bandwidth h to predict comfort in current building design and operation [32,33]. based on the density of the recorded data is proposed. In particular, LRAB has been compared with the PMV index on real data from ASHRAE RP-884 database [18]. This collection con- tains 52 studies with more than 20,000 user comfort votes from dif- ferent climate zones. However, some of these field studies contain 3.2 Computing the residuals and weights update only a few votes for each user. Thus they are not well suited for test- In this section we introduce the update mechanism for the weighted ing the proposed algorithm. This is because our approach seeks to function (2), based on the residuals (yˆi − yi ) for i = 1, . . . , n, as learn the user preferences based on their votes, and it requires suffi- mentioned at start of Section 2. Define the bisquare function: ciently many data records. For this reason, only the users with more than 5 votes have been used to compute the proposed LRAB. After Γ(ξ) = (1 − ξ 2 )2 (3) removing the studies and records as described above we were left with 5 climate zones, 226 users and 7551 records (Table 1). for |ξ| < 1; otherwise Γ = 0. As a starting point, we consider only one environmental variable Then, for a fixed new entry point xk , let: (i.e. inside air temperature) to evaluate the proposed LRAB. LRAB has been implemented in MatlabTM , using the trust-region method to ρi = (yˆi − yi ) (4) minimize the problem in (1), with a termination tolerance of 10−6 . be the residuals for i = 1, . . . , n, between the original points yi and The experiments have been performed through leave-one-out valida- the estimated points yˆi (i.e. by means of αk and βk ), and let m be the tion, for each user (i.e., using a single observation from the original Workshop on AI Problems and Approaches for Intelligent Environments (AI@IE 2012) 37 Climate zone users records 5 CONCLUSIONS AND FURTHER STEPS Hot arid 59 2594 In the present paper, we have applied robust locally weighted re- Mediterranean 51 1899 gression with an adaptive bandwidth to predict individual thermal Semi arid 21 2185 Tropical Savana 54 476 comfort. The approach has been characterized and compared with Continental 41 397 the standard PMV approach. The experiments were carried out using publicly available datasets: they have shown that our LRAB outper- forms the traditional PMV approach in predicting thermal comfort. Since LRAB can be computed quickly, and requires only a single Table 1. Number of users and records divided by climate zones, and used setting parameter that is easily obtained, then if individual comfort in the experiments responses are available, this method is feasible for use as a comfort measure in real time control. sample as the validation data, and the remaining observations as the The next step will be:(i) the comparison of our LRAB to other training data). (nonparametric) regression mechanisms (e.g., CART, neural net- As with the field study [22, 31], the algorithms are evaluated con- works, k-NN) and (ii) the extension of the method to accept multiple sidering the difference ∆V between the computed votes by both environment variables (for example humidity, external air tempera- LRAB (evaluated) and PMV (reported in the database) and the ac- ture etc.) in order to improve the above results. This mainly means tual vote (reported in the database) on a three-level accuracy scale the choice of a different kernel function to the one used here, in order [22, 31] as reported below: to avoid a bias problem on the boundaries of the predictor space, a kind of problem that may be arise especially in the multidimensional • Precise: ∆V < 0.2 case [26]. • Correct: 0.2 ≤ ∆V < 0.5 This work is part of the Strategic Research Cluster project ITOBO • Approximation: 0.5 ≤ ∆V < 0.7 (supported by the Science Foundation Ireland), for which we are ac- quiring occupant comfort reports and fine grained sensor data, and constructing validated physical models of the building and its HVAC systems. The intention is then to use the comfort reports and sensor data as input to our LRAB method, and then to use the output of LRAB as the input to intelligent control systems which optimise the internal comfort for the specific individual occupants. 6 ACKNOWLEDGEMENTS This work is supported by Intel Labs Europe and IRCSET through the Enterprise Partnership Scheme, and also in part by SFI Research Cluster ITOBO through grant No. 07.SRC.I1170. REFERENCES [1] Fanger, P. O. Thermal comfort: analysis and applications in environ- mental engineering. New York: McGraw-Hill; 1972. Figure 2. Average accuracy of predicting user comfort in 5 different [2] Gagge, A.P., Fobelets, A.P., Berglund, L.G. A standard predictive in- climate zones. dex of human response to the thermal environment. ASHRAE Trans 1986;92(2B):70931. [3] ASHRAE-55. Thermal environmental conditions for human oc- Figure 2 illustrates how accurately the LRAB predicts the actual cupancy. American Society of Heating, Refrigerating and Air- comfort vote of each user compared with PMV. In all 5 climate zones, conditioning Engineers Inc.; 1992. [4] International Standard ISO 7730, Moderate thermal environments- LRAB predicts the actual vote better than PMV especially in the ac- estimation of the PMV and PPD indices and specification of the condi- curacy level ∆V < 0.2 and has up to 200% of the number of occu- tions for thermal comfort, Geneva; 1987. pants for whom a precise value is predicted. However, having a close [5] Busch, J.F., A tale of two populations: Thermal comfort in air condi- look to the Figure 2, we notice that in the first three climate zones tioned and naturally ventilated offices in Thailand. Energy Buildings 1992;18:23549. (i.e. hot arid, mediterranean and semi-arid), LRAB achieves more [6] de Dear, R. J., Leow, K.G., Ameen, A., Thermal comfort in the hu- than 25% accuracy (∆V < 0.2), while in the last two climate zones mid tropics. Part I. Climate chamber experiments on temperature pref- (i.e. tropical savana and continental) it achieves only 16% and 18% erences in Singapore. ASHRAE Trans 1991;97(1):8749. of the same accuracy level respectively. We think that this discrep- [7] de Dear, R.J., Auliciems, A., Validation of the predicted mean vote ancy is because there is a lack of data for the last two climate zones model of thermal comfort in six Australian field studies. ASHRAE Trans 1985;91(2):45268 compared the first three. In fact, in the former we have 476 records [8] Funakoshi, S., Matsuo, D., PMV-based train air-conditioning control on 54 users (tropical savana) and 397 records on 41 users (continen- system. ASHRAE Trans 1995;101(1):42330. tal), as shown in Table 1. Hence, in these case studies we have 8.8 [9] MacArthur, J.W., Humidity and predicted-mean-vote-base (PMV- and 9.6 records per user on average, respectively. Conversely, in the based) comfort control. ASHRAE Trans . 1986;92(1B):517. [10] Scheatzle, D.G., Arch, D., The development of PMV-based con- first three climate zones, we have 44, 37 and 104 records per user on trol for a residence in a hot and arid climate. ASHRAE Trans average, respectively (table 1). As the proposed LRAB essentially 1991;97(2):100219. learns from the data, it requires a sufficient amount of data to give [11] Wai, L.T., Albert, T.P.S., Implementation of comfort-based air-handling the best results. unit control algorithms. ASHRAE Trans . 2000;106(1):2944. 38 Workshop on AI Problems and Approaches for Intelligent Environments (AI@IE 2012) [12] Yang, K.H., Su, C.H., An approach to building energy savings using the PMV index. Building Environment 1997;32(1):2530. [13] Sherman, M., A simplified model of thermal comfort. Energy Buildings 1985;8:3750. [14] Federspiel, C.C., Asada, H., User-adaptable comfort control for HVAC systems. Trans ASME 1994;116:47486. [15] Bingxin, M., Jiong, S., Yanchao, W.,Experimental design and the GA- BP prediction of human thermal comfort index, Seventh International Conference on Natural Computation,vol.2, pp. 771 - 775, 2011 [16] Atthajariyakul, S.,Leephakpreeda, T., Neural computing thermal com- fort index for HVAC systems, Energy Conversion and Management, Volume 46, Issues 1516, September 2005, Pages 2553-2565, 10 [17] Kumar, S.,Mahdavi, A., Integrating thermal comfort field data analysis in a case-based building simulation environment, Building and Envi- ronment, Volume 36, Issue 6, pp 711-720, 2001 [18] de Dear, R.J., A global database of thermal comfort experiments, ASHRAE Trans., 104(1):1141-1152, 1998. [19] ASHRAE. ASHRAE standard 55: thermal environmental conditions for human occupancy. American Society of Heating, Refrigerating and Air-conditioning Engineers; 2004. [20] de Dear, R.J., Brager, G.S., Thermal comfort in naturally ventilated buildings: revisions to ASHRAE Standard 55, Energy and Buildings, Volume 34, Issue 6, Pages 549-561, 2002 [21] Feldmeier, M.C., Personalized Building Comfort Control, PhD Thesis, Massachusetts Institute of Technology, Sept. 2009 [22] Schumann, A., Wilson, N., Burillo, M., Learning User Preferences to Maximise Occupant Comfort in Office Buildings, IEA/AIE (1) 2010: 681:690. [23] Cleveland, W.S., Robust Locally Regression and Smoothing Scatter- plots, J. of the American Statistical Association,Vol.74, No. 368, 829- 836, 1979. [24] Hastie , T., Tibshirani, R., Friedman, J., The elements of Statistical Learning, Springer, 2001 [25] Cleveland, W.S., 1988. Locally weighted regression: an approach by local fitting. Journal of the American Statistical Association, 88, 596- 610. [26] Hastie , T. and Loader, C., Local regression: automatic kernel carpentry, Statist. Science 8, 120-143, 1993. [27] Humphreys, M. A., Nicol, J. F., The validity of ISO-PMV for predicting comfort votes in every-day thermal environments, 2002, Energy and Buildings, 34(6), 667-684 [28] de Dear, R.J., Brager, G.S., Developing an adaptive model of thermal comfort and preference, Field studies of thermal comfort and adapta- tion, ASHRAE Technical Data Bulletin 14 (1) (1998) 27-49; ASHRAE Transactions 104 (1) (1998). [29] Humphreys, M.A., Nicol, J.F., Effects of measurement and formula- tion error on thermal comfort indices in the ASHRAE database of field studies, ASHRAE Transactions 106 (2) (2000) 493-502. [30] Humphreys, M.A., in: Proceedings of the World Renewable Energy Congress on the Recent Progress in the Adaptive Approach to Thermal Comfort, Brighton, UK, 2000, 438-443. [31] IS0/DIS 7730:2003, Ergonomics of the thermal environment Analyti- cal determination and interpretation of thermal comfort suing calcula- tion of the PMV and PPD indices and local thermal comfort, 2003. [32] ASHRAE-55. Thermal environmental conditions for human oc- cupancy. American Society of Heating, Refrig- erating and Air- conditioning Engineers Inc.; 1992. [33] International Standard ISO 7730, Moderate thermal environments- estimation of the PMV and PPD indices and specification of the condi- tions for thermal comfort, Geneva; 1987. Workshop on AI Problems and Approaches for Intelligent Environments (AI@IE 2012) 39