Detection of comfortable temperature based on thermal events detection indoors

This work focussed on thermal comfort as the basis to control indoor conditions. Its objective is a method to determine thermal preferences of office occupants. The method is based on detection of thermal events. They occur when indoor conditions are under control of occupants. Thermal events are associated with the use of local heating/cooling sources which have user-adjustable settings. The detection is based on Fourier analysis of indoor temperature time series. The relevant data is collected by temperature sensor. We achieved thermal events recognition rate of 86 %. Conditions when indoor conditions were beyond control were detected with 95.6 % success rate. Using experimental data it was demonstrated that the method allows to reproduce key elements of temperature statistics associated with conditions when occupants are in control of thermal comfort.


Introduction
Thermal comfort is defined as "conditions of mind which expresses satisfaction with the thermal environment" [1].It is a key component of the indoor environment quality and the major criterion to evaluate the performance of building systems from the occupants perspective.Thermal discomfort is a serious problem.It can create dissatisfaction, reduces the performance as well as productivity of workers and affects their health.Hence, ensuring appropriate thermal conditions is an important goal in the operation of modern buildings.
The service sector is now one of the largest and fastest-growing branches of the economy.Its rapid expansion is visible in both employment levels and the dynamic development of the office buildings.Despite a great effort and high rate of energy use for the indoor environment conditioning, a significant portion of the users are unsatisfied with thermal conditions inside commercial buildings [2][3][4].
Thermal environment within the modern office is determined at two levels -centrally, for the whole building and locally, at room level, by the occupants.Centralized heating systems are typically designed for the peak load conditions and their performance is not sufficiently analyzed during mid-season.The design typically obeys standards that specify conditions in which majority of the occupants find their environment thermally acceptable.However, the assumption that all occupants have the same comfort preferences is unrealistic [1].At the local level, it is expected that occupants will moderate their own comfort by dressing and using air temperature regulators or thermal comfort regulators [5].
Air temperature regulators are often available in modern offices.Some of them also take humidity into account.Radiators, convectors or room thermostats allow to adjust the temperature [6,7].However, the temperature control seems to poorly fulfil the occupant expectations.Regulators allow to efficiently maintain the indoor temperature/humidity within the demanded range.But sometimes, it is impossible to create comfort conditions in this way.Hence, there are proposed methods using thermal comfort regulators, which operate in accordance with the individual preferences of occupants.
The differences in the assessment of thermal comfort cause that offices are mostly controlled automatically according to the commonly used thermal comfort indices, e.g. the predicted mean vote (PMV) [8,9,10,11].The PMV value is defined by four environmental variables (indoor air temperature, mean radiant temperature, relative air velocity, and humidity) and two person-dependent variables (activity level and the value of clothing worn).Approaches based on PMV exhibit are difficult in practical applications.For example, they intend to determine the comfort needs of average occupants rather than those of the specific users sharing a room.They require a large amount of environmental data whose retrieval is very costly.It is often difficult to obtain the precise values for the required person-dependent data.PMV often differs markedly and systematically from the actual mean vote.Recently, the development of automatic systems for the control and assessment of the thermal comfort is focused on the application of artificial intelligence (neural networks, fuzzy logic, genetic algorithms, reinforcement learning etc.) [5,12,13].
The solution of thermal comfort control problem is important and it has high application potential [14,15].However, several questions need to be addressed.(1) Is the control of thermal comfort indeed necessary?Occupants may have low expectations regarding thermal environment in the office and the cost of control system may not pay off.(2) What are the heating/cooling preferences of occupants?The most acceptable temperatures need to be specified.( 3) What is the level of acceptance of temperature variations?The maintenance of temperature in a narrow range requires significant energy inputs, while it was found that static environments do not necessarily result in appreciably higher levels of occupants' satisfaction.(4) Shall the control of thermal environments be based on constant conditions (steady-state) or adaptive comfort principles.Open character of these questions encouraged us to perform this study.The aim of the presented work is to create a method to determine thermal preferences of office occupants.

Assumptions
Thermal comfort is evaluated individually and subjectively, since it depends on occupants' age, gender, physiological and psychological factors.The group as a whole can express its collective opinion about thermal environment e.g. when individual occupants use a facility for thermal conditions adjustment.Since devices for temperature control are easily accessible (e.g. by pilot) each user of the room can use them to push indoor conditions towards what he recognizes as thermal comfort.The air temperature behaviour inside room in such circumstances reflects the group's opinion about thermal comfort.In other words, by examination of some period of active control there may be identified thermal conditions that are acceptable for the all group members.In our study, correction of indoor conditions 2 E3S Web of Conferences 22, 00172 (2017) DOI: 10.1051/e3sconf/20172200172 ASEE17 towards comfortable temperature is attained using local cooling unit.Each occupant can switch the unit on/off and change its settings upon wish.It was taken for granted, that occupants do not provide false feedback votes.
We assumed that time series of temperature should be a source of information about thermal and cooling preferences of occupants.Sensor technology was used to obtain the relevant data.In order to extract the needed information, we made use of the fact that temperature control caused periodic changes of this parameter.The operation of majority of AC units dedicated for local use is controlled by an electronic thermostat.The thermostat is an on/off switch that commands the compressor.When the desired temperature (userdefined set-point plus or minus a bit) is achieved the compressor is switched off.But, when the indoor temperature goes beyond the set point range, compressor is switched on again.This results in compressor running in on-off cycle.Due to this kind of control, when AC unit operates, room temperature oscillates around the set-point [16].
The key element of this work is a method of thermal event detection.Thermal event is defined by the period of time when the temperature in the room exhibits the characteristic periodic variations.Thermal events allow to determine the time when thermal conditions were under or beyond control of occupants.The number and length of these periods informs whether occupants have low or high expectations regarding the thermal environment in the office, whether control of thermal comfort is indeed necessary.Information about thermal preferences are included in the probability density function of temperature recorded during thermal events.It provides exhaustive statistical description of the temperature which is comfortable for the room users.This function informs also about most preferable temperature as well as the range of temperature variation which is accepted by the office users.

Pattern of thermal event
Thermal events were distinguished on the basis of their patterns.Fourier analysis was applied in order to determine the pattern of temperature variation during thermal events in the room.In general, Fourier analysis transforms a signal from time domain to the frequency domain (called a spectrum or transform).After Fourier analysis the signal is expressed as weighted sum of periodic components with different frequencies.When signal and its Fourier transform are replaced with discretized counterparts, it is called the discrete Fourier transform (DFT).The DFT is widely used in signal processing because of very fast algorithm for computing it which is called Fast Fourier Transform (FFT) [17,18].DFTs were computed for temperature time series divided into segments.We considered segments of various size, namely consisting of ns=32, 64, 128, 256 and 512 data points.For time series division, the sliding window technique was utilized.The window, with the size of segment, was moved along the time series with a step of one data point.
Two kinds of temperature data segments were distinguished.In the first group, there were segments associated with thermal events, when thermal conditions were under control of the room users.They were labelled "under control".The temperature data segment belonged to this group, when at least 50 % of segment plus 1 element fell on the time of thermal event.The second group consisted of segments associated with conditions other than thermal events, i.e. when temperature was beyond control of occupants.It was labelled "beyond control".The level of thermal acceptance was unknown in these circumstances.Similar, as temperature data segments, discrete Fourier transforms of these segments belong to two groups: "under control" and "beyond control".
It was proposed that the pattern of particular thermal conditions is the mean discrete Fourier transform of temperature data associated with these conditions.The pattern is obtained by averaging spectra computed for all segments of temperature time series recorded when the particular thermal conditions occurred.Using this principle, there were constructed the pattern of thermal events i.e. "under control" conditions and the pattern of "beyond control" thermal conditions.

Criterion for thermal event detection
The amplitude of discrete Fourier transform was identified as the feature with high discriminatory potential with respect to the patterns of thermal conditions indoors.In case of "under control" pattern the amplitude increase was expected in the part of DFT which corresponds to the frequency of the AC unit compressor switching.Important to note, this frequency was not fixed, but belonged to a certain range The magnitude and dynamics of room heat gains/losses may vary in time, causing change of the period of temperature variations.In "beyond control" pattern, the amplitude increase was not expected.
Let (f3, f4) be the frequency range where the amplitude of "under control" pattern is elevated.Other frequency range, selected as reference is (f1, f2).Let the amplitude of discrete Fourier transform of the test data set of temperature be A(f).The following criterion was proposed in order to evaluate the similarity of DFT of the test data with the pattern of "under control" and " beyond control" conditions.
If max(A(f1, f2)) < max(A(f3,f4)), then the test spectrum is belongs to group "under control" otherwise it belongs to group "beyond control".

Recognition of thermal event
We propose to apply thermal event detection approach for determining comfort temperature in a room.Although the thermal event detection is based on data collected over a period of time, it may be applied for determining the kind of thermal conditions with the temporal resolution of temperature data collection.The procedure of determining thermal conditions in a particular time point consists of the following steps: 1. Picking a segment of temperature time series, such that the time point in question is one of middle data points in this segment.2. Computing Discrete Fourier transform of temperature data segment.3. Assigning the obtained DFT to one of two categories "comfort" or "unspecified", based on the amplitude criterion introduced in Sec.2.2. 4. Labelling the time moment in question with the label assigned to the spectrum in pt. 3.

Performance assessment
The performance of the method is assessed by comparing true and recognized category of thermal conditions in time point.For each data point, there are two possibilities, namely "under control" and "beyond control".We used two kinds of error as performance measures.They are defined for the period of time which consists of n time moments.In this period, temperature was under control during n1 time moments and beyond control during n2 time moments.The number of correctly recognized data points in the first group was nUC and in the second group it was nBC.The error eUC refers to the fact of not recognizing 'under control' conditions, while they existed and the error eBC refers to the fact of not recognizing "beyond control" conditions while they existed E3S Web of Conferences 22, 00172 (2017) DOI: 10.1051/e3sconf/20172200172 Two errors were applied due to imbalanced size of two categories "under control" and "beyond control", the second one being considerably greater.
The method of thermal events detection was optimized.The optimisation consisted in search for the best combination of parameters {ns, f1, f2, f3, f4}.The minimization of eUC and eBC jointly was chosen as the criterion of finding the best combination of parameters.
All scripts were written in Python.

Experimental part
Measurement study was carried out.It consisted in indoor air monitoring in an airconditioned room and recording human interactions with the air conditioning unit.
The observation comprised a selected room of IT engineers in Wroclaw Centre for Networking and Supercomputing.The room is occupied by 10 people, whose working hours are 9:00-17:00.The layout of the room and its dimensions are shown in Fig. 1.The room is fitted with the AC unit, which is the ceiling cassette ACK30A+A4LC30C, the cooling only model.The unit is equipped with rotary compressor controlled by the electronic thermostat.Two modes of operation are available: COOL, DRY & FAN.Temperature set point may be changed and the fun speed can be regulated by the user.The cassette is mounted in the ceiling, in central part of the room, as shown in Fig. 1.In course of the study, there were made notes about the switch on/off moments of the AC unit.Its working parameters have not been recorded.We assumed that various temperature set points, modes of operation and fun speeds have been tried to achieve thermal comfort.
Temperature was the indoor air parameter considered in this study.It was measures by air quality monitoring instrument, HD 37B17D, equipped with NTC 10 k temperature sensor.The instrument offers measurement accuracy of ±0.2C or ±0.15% of the measure, and measurement resolution ±0.2C.The sensor device was mounted on the table in the central part of the room, as shown in Fig. 1.Measurements were performed continuously.The data were recorded with temporal resolution of 30 s.The results of the measurement study were the basis for developing the method of comfort temperature detection based on thermal events.
The measurement study was carried out in the summer season of 2016, namely from the 1st June to 30th September.In this period AC unit was frequently used due to hot temperature outdoors and considerable heat gains resulting from solar radiation.For that reason, our attention was focused on the cooling process.It should be noticed, that methodology proposed in this work may be also applied in case of heating.In Fig. 2 there is shown the daily record of temperature in the room.The period of time when occupants were in control of thermal conditions via AC unit is characterised by the variation of temperature around the set-point.The pattern of thermal events when thermal environment was under control is shown in Fig. 3, left and the pattern when thermal environment was beyond control is shown in Fig. 3, right.Individual plots refer to spectra computed for temperature data segments of various lengths.The amplitudes of individual spectra were scaled with reference to the maximum amplitude.As shown in Fig. 3 the patterns of "under control" and "beyond control" conditions are different.In certain frequency range, approximately f(0.0015, 0.005) the amplitude is elevated in case of DFT representing "under control" conditions, as compared with the DFT representing "beyond control" ones.This observation indicates that the cycle of AC unit compressor operation varied in quite wide range, from 3 to 17 min.This observation also confirms that the amplitude criterion, presented in sec.2.2 has a considerable discriminatory potential.Its optimization in the studied case involved search in the following ranges of values: ns{32, 64, 128, 256, 512}; f1{0:0.0001:0.0009};f2=f3 and f2{0.001:0.0001:0.0024};f4=0.005.The exhaustive search of parameters' space was done.
The error analysis showed that the detection of thermal events was most successful when using temperature data segments composed of ns=32 elements.The best values of f1 and f2, were f1=0 and f2<0.001,0.002>.For any (f1,f2) combination in this range of values, the eUC and eBC errors were constant.The error values were eUC = 14% and eBC = 4.4%.Based on our study, there were identified 47 thermal events.Except for 2 cases, there was recorded one thermal event per day.The event lasted from 33 min to 10h 8 min, with the average length of 6 h.The overall duration of conditions when thermal comfort was under control was 286 h.This constituted about 42.5 % of the work-time hours in the study time.Based on thermal events detection the respective numbers were 265 h and 39.4 %.The method underestimated by 3 %, which is negligible.From this result we may infer that in the considered room, control of thermal comfort is highly needed.Occupants have high expectations towards the quality of thermal environment.
In Fig. 4 we show, the empirical probability density function for temperature, when thermal environment is under control.They are based on raw data and results of recognition by the thermal events detection method presented in this work.As shown by the green plot, the essential feature of probability density function in "under control" conditions is the bimodal character.One observes two maxima, one at temperature 24.7 C and the other at 25.7 C.This fact may be interpreted as resulting from the existence of two kinds of dominating thermal preferences amongst people who occupy the room.Namely, part of the group is satisfied when air temperature is maintained around 24.7 C and the other prefers 1 degree warmer conditions.As shown in Fig. 4, the red plot displays the same bimodal character.Namely, the estimation of comfort temperature based on thermal events detection allows to retrieve this key information about comfortable temperature in an indoor space.
Clearly the studied office is the case where the temperature is maintained in quite a narrow range of 24C to 26C, when under control.The spread is 2 degrees.The occupants are not too willing to accept high range of temperatures.Partially it may be due to low speared of individual expectations towards thermal comfort.As compared to optimum temperature detection performance we were not so much successful regarding, the retrieval of the range of temperature which is accepted by the office users.The event detection method qualified too many high temperature occurrences as being examples of "under control" conditions.Although in the lower temperature end the match was much better, there is still room for the detection performance improvement.

Conclusions
The work presents a method which allows to determine comfortable temperature in offices, which are fitted with local heating/cooling units controlled by an electronic thermostat.The method consists in detection of temperature events, associated with their use.The detection is based on temperature monitoring and Fourier analysis of the recorded data.The method was developed and optimised using measurement data collected in the summer season 2016 in an air conditioned office occupied by IT engineers.
We achieved thermal events recognition rate of 86 %.Conditions other than thermal events were recognized with the efficiency of 95.6 %.
It was demonstrated that the method allows to correctly retrieve the key characteristics of the probability density function for temperature in comfort conditions.In this study we detected that room occupants favour two comfort temperatures, which indicates inhomogeneous thermal preferences in this group.We also found that, they prefer temperatures within small range of about 2 °C.
The method is computationally efficient.It may be directly applied to detect comfort temperature in any space where thermal environment may be controlled by occupants.
Further work is planned, aimed at improving the performance of thermal events detection.Alternative recognition approaches and additional parameters of indoor air will be taken into consideration.

Fig. 1 .
Fig. 1.The schema of the room where the study was performed.Green dot indicates the measurement point and dotted line shows the location of AC unit.

Fig. 2 .
Fig. 2. Time series of indoor air temperature.Thermal event is displayed between dotted lines.

Fig. 3 .
Fig. 3. Patterns of "under control" and "beyond control" conditions.The mean DFT spectra of temperature data refer to time series segments composed of 32, 64, 128, 256 and 512 elements.

E3SFig. 4 .
Fig.4.Empirical probability density function for temperature in "under control" conditions, true (green) and recognized with thermal events detection method (red).