WI-FI ROUTER NETWORK-BASED OCCUPANCY ESTIMATION TO OPTIMIZE HVAC ENERGY CONSUMPTION

WI-FI ROUTER NETWORK-BASED OCCUPANCY ESTIMATION TO OPTIMIZE HVAC ENERGY CONSUMPTION 
Research By 
Krishna Chaitanya J Simma, Susan M Bogus and Andrea Mammoli

ABSTRACT 

More than half of the commercial building stock in the United States was built before 1980 prior to the increased focus on energy efficiency. In the current age of Smart and Green buildings, owners incorporating expensive sensor infrastructure to reduce building energy consumption and improve the building occupants’ satisfaction, efficiency, and comfort levels. The success of these automated building systems is influenced by the ability to estimate building occupancy. Recently, researchers shifted their focus towards exploring different occupancy estimation techniques with both dedicated sensors and existing infrastructure (e.g. CO2 sensors, Smart meters, temperature and humidity sensors, and wi-fi networks). However, there are concerns about the cost effectiveness, computational effort, accuracy and privacy protection for these techniques. This study explores the usage wi-fi router data to generate the of number of IP addresses connected to the router to estimate the occupancy within a building. To this end, occupancy patterns in a thirty-year-old university building are estimated using existing wi-fi infrastructure and compared and calibrated to ground data obtained manually and from dedicated occupancy estimating sensors to evaluate the accuracy. The estimated occupancy data patterns using existing wi-fi network represent a cost-effective method of occupancy estimation with less computational processing and reduced privacy concerns, that could assist owners in the decision-making process towards investing into smart and energy efficient technologies.

1. INTRODUCTION

With the rise of technology, Smart buildings and Green initiatives have grown in the past few years. In 2011, 
a report from the United States Energy Information Administration (EIA) reported an increase in the number 
of pilot studies related to smart grids. It stated that the smart meter installations in the United States would 
exceed 80 million by the year 2015 (SAIC 2011). This is close to the EIAs’ 2016 reported value of above 
70 million smart meter installations in the residential, commercial, industrial, and transportation sectors. 
Although the current number is slightly behind the predicted value, it is evident that building owners are 
investing in smart technologies to improve efficiency and comfort. With more than half of commercial 
building stock in the US being over 32 years old (CBECS 2012), the potential for building owner’s investment into smart technologies to optimize energy consumption and improve occupant comfort is great. 
Commercial buildings consume about 19% of total energy consumption in the US (Azar and Menassa 2014) 
in which about 50% of energy is consumed by HVAC (heating, ventilation, and air conditioning) equipment. 
Energy models and predictions were often mismatched with the actual building performances in terms of 
their energy consumption. Often the mismatch between modelled energy consumption and actual energy 
consumption in commercial buildings is attributed to the occupants and occupant behavior of the buildings 
(Azar and Menassa 2012b). In the past decade, studies have emphasized on the impact of occupants on 
building energy consumption (Yang and Wang 2013, Labeodan et al. 2015, Hong et al. 2016). As the 
influence of occupants on building energy consumption became evident, the importance of occupancy 
information has become the point of interest for researchers. 
Numerous occupancy detection and estimation techniques were introduced over the past few years. 
Studies have explored different techniques to detect, estimate and track occupants within the building. 
Some of the techniques include but are not limited to usage of sensor networks such as passive infrared 
sensors (PIR) (Dodier et al. 2006), RFID tags (Li et al. 2012), occupancy sensors and motion detectors 
(Duarte et al. 2013, Stoppel and Leite 2014, Mantha et al. 2015), vibration sensors (Pan et al. 2014), chair 
sensors (Labeodan et al. 2015), and Ultra-wideband (UWB) (Choi et al. 2018) among others. 
However, dedicated sensor infrastructure can be expensive for large scale deployment in commercial 
buildings. To address these issues, researchers have investigated occupancy detection, estimation and 
tracking for multiple purposes using existing infrastructure such as smart meters (Kleiminger et al. 2013), 
cameras (Liu et al. 2013), and wi-fi routers (Vattapparamban et al. 2016, Zou et al. 2017, Zou et al. 2018) 
among others. Each of these existing infrastructure systems have different levels of detection and 
estimation accuracies and privacy concerns. Z.Chen et al. (2018), performed a comparative review of 
different occupancy sensing techniques. The article presented a summary of different types of sensors 
used to detect and estimate occupancy along with their limitations. Overall, from literature is it evident 
occupancy data can be categorized into three levels depending on the extent of information obtained: 1) 
detection, 2) estimation, and 3) location tracking (Zou et al. 2017). 
This paper focuses only on occupancy estimation using existing infrastructure. Infrastructure such as smart 
meters are capable of detecting occupancy but have no capability of estimating the occupancy (D. Chen et 
al. 2013). Cameras have high accuracy, however they have high computational requirements and privacy 
concerns which would restrict their usage ( Liu et al. 2013Z). Wi-fi signals are capable of detecting and 
estimating occupancy with partial privacy concerns of the occupants (Zou et al. 2017, Zou et al. 2018). 
However, from the studies on occupancy estimation using wi-fi routers/Access Points (AP’s) and signals 
(Received Signal Strength, RSS), it is evident that the occupancy estimation requires either significant 
computational resources, additional software updates to the routers, or additional devices installed (Depatla 
et al. 2015, Vattapparamban et al. 2016, Zou et al. 2017). Table 1 summarizes some of the occupancy 
estimation techniques proposed in recent literature along with their computational requirements, added 
infrastructure, reported accuracy, and concerns.

From the summary presented in Table 1, it is evident that the techniques implemented to detect and 
estimate occupancy require additional resources such as routers capable of handling specific task (e.g. 
Meraki routers), upgrading firmware, and wi-fi sniffers (e.g. wi-fi pineapple) among others, identifies 
occupants through unique identifiers (e.g. MAC addresses), or limited to occupancy detection only. The 
added infrastructure, and firmware upgrades may increase the cost of gathering occupant data for 
commercial buildings. Similarly, identifying and tracking individuals may raise privacy concerns when 
implemented in university buildings or other public buildings. In this context, this paper asks a question: 
Can Wi-fi Routers serve as a cost-effective, reliable and accurate source of occupancy estimates that 
reduces computational requirements and privacy concerns?

2. METHODOLOGY

To address the question asked, this study proposes the methodology presented in Figure 1 and consisting 
of three steps: 1) Establish ground truth, 2) Data acquisition, and 3) Data processing, and accuracy.


The methodology is used to estimate occupancy of a large lecture hall inside a thirty-year old Mechanical 
Engineering Building at University of New Mexico that is equipped with a campus wide wi-fi network. To 
estimate the occupancy, it is assumed that when students spend time within the university building they 
connect to the university wi-fi network for their needs. The router infrastructure covers the entire building 
which facilitates the detection and estimation of occupants within the areas of wi-fi coverage. The lecture 
hall in question was preinstalled with three wi-fi routers spread across the entire room.

2.1. Step1: Establish Ground Truth
 
To establish ground truth, the lecture hall in the Mechanical Engineering building shown in Figure 2(a) was 
selected as it is one of the classrooms regularly used during the semester. The lecture hall is capable of 
seating over one hundred students at a time. It has two entrances one on the north end and one on the 
south end. On average five different classes take place on a regular week day. To obtain an actual count 
during a normal class, a people-counting sensor (EBTRON: CENCUS-C100) shown in Figure 2(b) was 
installed that uses the thermal signature of occupants to estimate the occupant count as they walk through 
the door. Each entrance was installed with a single C100 as shown in Figure 2(c). When an individual 
enters through the door, the C100 sensor is activated and it is directionally sensitive. It consists of two 
infrared sensors that detects the thermal signature of the occupant and increases the count when an 
individual enters and decreases when the individual exits based on the order of activation (e.g. if 1 to 2 is 
entry, 2 to 1 is exit).
The installed sensors were calibrated and tested for over 3 months during regular semester weekdays. The 
sensor logs the occupancy count every time an occupant walks through the door to attend a class and 
sends the data to the server located at the Physical Plant Department on the university campus. The 
occupancy count data is made available for download from the server as a Comma Separated Value (CSV) 
file. The raw data consists of the occupant count for the entire day with timestamps. This data is then 
validated against manual counts to estimate the accuracy and establish the sensor count as the ground 
truth.

2.2. Step2: Data Acquisition from Routers
 
The lecture hall is equipped with three wi-fi routers to facilitate wi-fi coverage for the entire hall. Students 
often connect to the wi-fi network during classes and this data is logged and sent to the network servers 
held at the Information Technology (IT) department for the university campus. This data consists of the 
number of clients (i.e. number of Media Access Control (MAC) addresses) connected to the network at a 
given time throughout the day. Such data can be obtained for any building equipped with a wireless network 
managed by a central network server. For this investigation, the IT department was asked to share the data 
with number of clients connected through the wi-fi routers inside the lecture hall throughout the day. The 
number of connections at a given time should approximately match the total occupancy of the lecture hall. 
The IT department was asked to filter any information that could identify an occupant to eliminate privacy 
concerns.

2.3. Step3: Data Processing and Accuracy
 
The client list is shared on daily basis as a CSV file containing the data from the previous day. This data 
requires minimal processing to estimate occupancy of the room as the count of total number of clients at a 
given time is considered as the total occupancy. This client count data is then compared with the ground 
truth (data obtained by the sensors (C100) installed for the lecture hall) to find the correlation between the 
two estimates and measure the accuracy.

3. RESULTS AND DISCUSSION
 
The installed sensors were connected to the university’s Delta Control systems network (Facilities 
management system) to allow viewing the data logging in real time as shown in Figure 3. The sensors were 
calibrated and tested during regular semester classes and special seminar talks where the total attendance 
was obtained via manual count. A data point is logged every time a student walks through the door. The count increases as students walk in through the door and decreases as students walk out. No specific 
instructions were given to the students on how to enter or exit the room. The student’s behavior was 
unaltered throughout the period of calibration and testing. The logged data provides fine grained occupancy 
information in real time as students walk in and walk out of the lecture hall. The data is then compared to 
the manual count over multiple days and the sensor achieved 97.7% accuracy in estimating the occupancy 
count. Therefore, the sensor count is used going forward as representative of the ground truth.
The wi-fi routers in the lecture hall allow students to connect to the campus network through one of the 
routers and the information of the individual is logged on the university IT department’s network servers. 
The servers log the total number of clients connected to the campus wi-fi every five minutes throughout the 
day. The total number of unique clients connected to the three routers that serve the lecture hall were 
isolated from the rest of the database with a timestamp. This information was shared via CSV file from Jan 
22, 2019 to Feb 21, 2019. All the information such as MAC or IP address of the users that can identify an 
individual was filtered out by the IT department to protect the identity of the occupants. 
The total count versus time from the two data sets are plotted alongside each other using simple MATLAB 
script as shown in Figure 4 from (a) to (d) representing the data from Jan 22, 2019 to Jan 25, 2019 
respectively

The timesteps at which the data logged by the C100 sensor is different from that of the wi-fi routers. To 
form a correlation between the two data sources, the occupancy values need to be obtained for the same 
timesteps from each source. Using the “griddedInterpolant” function in MATLAB, occupant count and client 
count were interpolated for the same timesteps. The extracted values provided the occupant count (x1) 
from the C100 sensor and client count (x2) from the wi-fi router. As time (y) is common for both x1 and x2, 
these values are plotted against each other to estimate the correlation. The correlation plot with linear 
regression line is shown in Figure 5 and Figure 6 for days Jan 22, 2019 to Jan 25, 2019.

Similarly, three weeks (only weekdays) data was analyzed to observe the correlations between the client 
count from the routers and the occupant count from the C100 sensor. The R2
 values ranged from 0.887 to 
0.963 and the intercept of linear regression lines ranged from 0.23 to 1.27. This highlights that the wi-fi 
router client count agrees with sensor occupancy count. Therefore, it is apparent that meaningful occupancy 
data can be extracted from the wi-fi routers implying that the routers can serve as an accurate source of 
occupancy count. Since information that can identify an individual is filtered out by the IT department before 
the data was pulled out of the servers, the router count has little privacy concerns. Apart from a little cleaning 
of the raw data, no processing or computation was required to obtain the occupancy count from the routers. 
This allows the reallocation of computational resources elsewhere while using the router occupancy data 
for optimizing HVAC’s energy usage. 
No infrastructure or firmware upgrades were made to the routers to extract the occupancy count from the 
routers. The student behavior was not altered in anyway during the testing and calibrating of the C100 
sensor or during the wi-fi router data acquisition period making this a non-intrusive occupancy estimation 
technique. The EBTRON C100 sensors costed $450 each and most classrooms in the Mechanical 
Engineering building have two entrances. Installation of these sensors for every classroom to estimate 
occupancy is not economically viable. Gathering reliable and accurate occupancy estimates from the w-fi 
routers can be cost-effective compared to methods that need additional infrastructure, firmware updates, 
and special operating systems.

4. CONCLUSION, LIMITATIONS, AND FUTURE DIRECTION 

The R2 values of 0.887 to 0.963 and linear regression intercept values of 0.23 to 1.27 demonstrate that 
accurate occupancy counts can be obtained from wi-fi routers with low privacy concerns and minimal 
computational efforts. As no infrastructure or firmware upgrades were made to the original existing 
infrastructure, this method has no additional cost impacts. These results address the question raised in the 
introduction of this paper that wi-fi routers can server as a cost-effective, reliable and accurate source of 
occupancy data. However, there are few limitations to this study that need to be addressed in future. The 
client count from the router may not necessarily represent the total occupants in the lecture hall. There 
might be instances where students carry more than one wi-fi capable device which may result in over 
counting of occupants. The wi-fi data needs to be analyzed over many weeks to conclude that routers can 
provide accurate occupancy counts. These limitations will be addressed in the future steps of this research.

Comments

Popular posts from this blog

What is Electrical Drive? Types of electrical drives?

How to get pure sinusoidal AC output from DC input using PWM inverter

Basic Electrical Theory