SlideShare a Scribd company logo
1 of 10
2022 IEEEConference on Technologies for Sustainability (SusTech)
Integration of Statistical Models of Residential
HVAC Loads with a Commercial Smart Thermostat
Jeewon Choi, Matthew Robinson, Andrea Mammoli
Department of Mechanical Engineering
University of New Mexico
Albuquerque, New Mexico 87131, USA chatchi923@unm.edu,
mr369@unm.edu, mammoli@unm.edu
Abstract—As part of an effort to develop accurate power flow
simulations in the area of Demand Response (DR) control, we
developed an agent-based model for power consumption by
residential end uses. Electrical power loads occurring in individual
houses are categorized and modeled statistically. We developed a
thermostat model to simulate the HVACpower draw, one ofthe most
important residential loadcategories. In the present work, we replace
the simulatedthermostat fromone of the house models participating
in the aggregatedloadcontrol, with a physical instance of commercial
smart thermostat. Specifically, we selected a ‘Nest Learning
Thermostat’ for integrationinthe loadsimulation. We usedthe Nest
Application Programming Interface (API) for the integration process.
We implemented a PID control system toregulate the temperature of
an environmental chamber where the Nest thermostat is installed.
The environmental chamber is intended to provide the Nest with
conditions similar to what it would experience in a real-life setting.
Learnings fromthe present workwill serve to increase the realismof
large-scale agent-basedsimulations.
Index Terms—Demand response, aggregated load control, smart
thermostat, learningthermostat, Nest API
I. INTRODUCTION
Aggregated residential power uses are considered as prime
resources for controllingloads atthe distribution feeder level.
We recently proposed a simulation framework to develop
scheduling and controls algorithms for aggregated residential
power loads [1].In our framework, residential energy services
are categorized into six groups, namely hot water, space
temperature control, refrigeration, clothes washing / drying,
cooking and lighting. These energy uses are then modeled
from statistical data. The six energy services are modeled for
each individual electric meter that exist within the simulation
framework. Whileaggregated loads areconsistentfromday to
day and relatively predictable,individual meter loads are not.
Here, the necessity of the bottom-up approach to the
characterization of power flow over the feeder arises.Among
the residential loads categories considered, we choose the
HVAC and the water heater as controllable resources. HVAC
provides a sizeable fast response due to its high power draw,
while water heater enables effective peak shifting due to its
high energy storagepotential.The overall objectiveof the load
simulation framework is to design control algorithms that
shape the total distribution feeder load to respond to some
external control signal, such as the power production of a
substation-sited PV array.The purposeof the work presented
here is to verify the realism of the simulation framework,
concerningthe control of HVAC loads.
With the advanceof Internet of Things (IoT) technology, the
availability of smart house appliances is rapidly increasing.
Smart thermostats for regulating space temperature are
becoming popular, enabling the simple utilization of HVAC
load as a controllable resource in aggregated load control. In
this paper, we focus on the integration of a physical smart
thermostat within the load simulation framework introduced
by Mammoli et al. [1] by replacing the model thermostat
switchingalgorithms with the actual responsefrom a physical
thermostat.
We selected the 3rd generation ‘Nest Learning Thermostat’
as the physical smart thermostat to be integrated, that will be
referred to as the Nest thermostat throughout the paper. The
Nest thermostat is attractive in that it possesses advanced
HVAC controlling algorithms that provide user comfort
combined with energy saving.Moreover, the Nest thermostat
is well suited for aggregated control, since it provides an API
that can be used for this purpose.In fact,Nest thermostats are
already providing Demand Rsponse (DR) rewards under
certain programs in collaboration with some energy providers
[2]. The capabilities of the Nest thermostat in this respect will
be considered and evaluated through a set of experiments in
the present work.
II. STATISTICAL LOAD SIMULATOR
We first summarize the statistical load simulation process
discussed in detail previously [1]. A schematic illustration of
the HVAC load simulation is shown in Fig. 1. The number of
load occurrence per day, the load start time and the load
duration for each house are characterized by associated
probability density functions (PDFs). At the beginning of each
day, a schedulefor each load is drawn from PDFs.For the case
of an HVAC event, the schedule generated indicates the
human occupancy of the residential space. For example, on a
particular day,a specific housecould be occupied from 12AM
to 8AM, unoccupied from 8AM to 6PM then occupied from
6PM to 12AM. A temperature setpoint and associated
978-1-5386-7791-9/18/$31.00©2022IEEE
2022 IEEEConference on Technologies for Sustainability (SusTech)
Fig. 1. Statistically drawn house occupancy schedule, setpoint/deadband,
current house model temperature is sent totheloadaggregator. Basedon its
control error, the loadaggregator decides whether to activate or deactivate
the HVAC loads. The simulated thermostat logic responds to thesignalfrom
the load aggregator, and its response is sent to the model. These steps are
repeated in a timeloop.
deadband are set to the value generally desired by user,
although in some cases thesecould be modified for DR control
purposes. In a normal operation situation, when the house is
occupied, a narrower deadband is set to provide comfortable
temperatures to residents.When unoccupied,the deadbandis
set to wider range. DR control can take various forms,such as
a change in the setpoint / deadband or by switchingthe HVAC
operation back and forth. In the previous work [1] the
deadband was simply set wider when unoccupied to reduce
the HVAC load,as a normal smart thermostat would do, while
the state of the HVAC compressor is switched depending on
whether higher or lower load is required by the distribution
system.
During operation, the occupancy, the setpoint / deadband
and the current spacetemperature for each house are sent to
an aggregator. The aggregator calculates the control error,
that is the difference between a desired signal determined by
conditions at the substation and the aggregated HVAC load,
the availablecontrol action,then makes a decision on whether
and how much to collectively activate or deactivate HVAC
loads. A detailed explanation on the aggregated load control
principle is given in the previous work [1]. A signal from the
aggregator is sent to the smart thermostat, which in turn,
based on internal logic, either switches its on / off status or
not. The housespacetemperature at the next time step, based
on the house thermal model in combination with the HVAC
operation, is then calculated.
For this study,we assumethat all houses areequipped with
an HVAC system based on an electrically powered heat pump
for spacetemperature regulation.This setup is widely used in
areas with moderate climate, and will become increasingly
prevalent with increasing electrification of energy services.
The thermal response of an air conditioned space can be
described by [1]:
(1)
,
(2)
Q˙ R = Π × Λ × COP × PAC. (3)
In this model, derived from the physical natureof the system,
Ms is theeffective heat capacity of the conditioned space, Ts(t)
is the temperature of the conditioned space, t is the time, Q˙ L
is the thermal energy exchange between the conditioned
space and its surrounding, Ta is the ambient temperature
outside of the building, Ks models the heat exchange between
the building and the external air, Q˙ R is the rate of energy
outflow or inflow from the space via the HVAC, COP is the
coefficient of performance of the HVAC system and PAC is the
electric power consumed by the compressor. It is assumed
that the heat pump utilizes a fixed-speed compressor,so that
PAC stays constant. Π indicates whether the HVAC mode is
cooling or heating, and Λ is a state function that indicates
whether the compressor is on or off. The HVAC mode is
determined by:
(4)
,
where the HVAC is in cooling mode when Π = 1 or in heating
mode when Π = −1. The switching logic for the simulated
thermostat when the HVAC
is in cooling mode is
described by:
(5)
,
where TL and TU are the lower and upper deadband limits for
the space temperature control. When the temperature is
within the deadband, the state function Λ at a particular time
step remains the same as its previous value,i.e.switchingonly
occurs when the temperature reaches the deadband limits.In
similar manner,when HVAC is in heatingmode:
(6)
.
The HVAC load for an individual houseata particular timestep
is then calculated by
LHVAC = Λ × PAC. (7)
2022 IEEEConference on Technologies for Sustainability (SusTech)
In what follows,we describehow the logic for the HVAC mode
decision and the HVAC state switching of one of the virtual
thermostat in the simulations can be replaced with a physical
instanceof a Nest thermostat.
III. EXPERIMENTAL SETUP
A. Chamber Temperature PID controller
The physical environment in which the Nest thermostat is
immersed mimics the real-time conditions of a house whose
temperature is modeled by (1)-(3). The Nest thermostat yields
Fig. 2. Illustrationof the environmentalchambersimulating a temperature of
the house model. The chamber temperature is controlled by the two fans,
providing thephysicalenvironment for theNest thermostat.
the actual response that we want to utilize within the
multiagent HVAC load simulation.The temperature within the
environmental chamber is controlled using two fan / coil
combinations. The cooling fan pushes air through a
chilledwater heat exchanger and into the chamber. The
heatingfan pushes air through electrically-operated heatcoils.
In the experimental setup shown in Fig. 2, the temperature of
the water running through the heat exchanger and the
temperature of the heatcoils remains steady, therefore the
speed of the fan determines the rate of temperature change
on the chamber. Two fans are connected to the General
PurposeInput Output (GPIO) pins of a Raspberry Pi computer,
that hosts a fan speed control code. Only one of two fans runs
atany one time. The fan speed is calculated based on theerror
between the desired temperature and the current chamber
temperature using a Proportional Integral Derivative (PID)
control method. A PID controller that simply solves (8) is
implemented:
, (8)
where u(t) is a control action, e(t) is the temperature error
and ∆t is a time constant.The PID gains Kp,Ki and Kd are tuned
experimentally so thatthe chamber temperature can precisely
track the house model temperature. The chamber
temperature is the average temperature from a set of T-type
thermocouples placed at strategic locations within the
chamber. An example of the PID controlled response of the
chamber temperature is shown in Fig. 3, in which the physical
chamber temperature tracks the model house temperature.
B. Nest settings
A 3rd generation Nest Learning Thermostat is selected as a
physical thermostat. An electrical circuit of the HVAC system
with a heat pump in an actual residential space,and thewiring
of the Nest thermostat to the HVAC, are shown in Fig. 4. The
24V AC power from the transformer runs through terminals
Fig. 3. With gains of Kp = 0.1, Ki = 0.004, Kd = 0.7, the PID control system
implements thehousemodeltemperatureinsidethe chamber reasonably.
R and C, to power the thermostat. Terminal W1, Y1 and G are
used for sending signals to the heating element relay, the
compressor relay and the fan relay of the heat pump system
respectively. In the present experiment, the Nest thermostat
terminals are not connected to an actual HVAC but the Nest
thermostat still generates HVAC control signals in responseto
its environment. These signals are obtainable through the
voltage measurement in relevant terminals or through the
utilization of the Nest API. The latter method is used in this
work, with details will be covered in the following section. By
detecting connections in its terminals, the Nest thermostat
knows what kind of HVAC system it is controlling. In order to
let the Nest thermostat know that it is associatingwith a heat
pump system, open-ended wires are connected to terminal
W1, Y1 and G as shown in Fig.4.
IV. INTEGRATION OF THE LOAD SIMULATOR AND THE NEST THERMOSTAT
Given this physical environment for the Nest thermostat, it
is now necessary to integrate the response of the Nest
thermostat to the overall simulation. The Nest API is the key
tool utilized in the integration process,and steps taken for this
purpose aredescribed in this section.
2022 IEEEConference on Technologies for Sustainability (SusTech)
A. Nest API
The Nest thermostat supports the API development through
the REpresentational State Transfer (REST) network HyperText
Transfer Protocol (HTTP), which allows a user to read or write
on the Nest thermostat without physically contacting it.
Through REST HTTP, a client(the thermostat itself, or a third-
party agent such as an aggregator) can make requests to
specific server URLs. The data can be manipulated on the
server itself,or transfered back to the client[5]. Nest provides
relevant URLs to API developers. While HTTP requests can be
made via various platforms, in the present work, HTTP
requests have been made in Python through the ‘requests’
library [5].A clientis created in the Nest Developers website
(a)
(b)
Fig. 4. The Nest thermostat wiringfor an actualHVACsystem witha heat pump
and a fan [3], [4]. Its responseis also reachablethroughtheNest API.
that is assigned with a unique client ID, a client secret and an
authorization URL. Before access to private data is available
from the Nest thermostat, an access token [6] must be
obtained. The Nest API uses the OAuth 2.0 protocol for the
authorization process. With the client ID, the client secret ID
and the authorization code, an access token is granted by
making requests. The authorization code is obtained from the
authorization URL with the user consent. Once the access
token has been obtained,itis possibleto makecalls to theNest
API, then access data such as setpoint or HVAC state for the
specific Nestthermostat. Data are pulled in a JavaScriptObject
Notation (JSON) object through the ‘GET’ method of the REST
API, and pushed in through ‘PUT’ method. The process of
authorization is shown in Fig.5.
B. Integration
Having established that data can be pushed in to or pulled
from the Nest thermostat using the Nest API, the integration
of the Nest thermostat to the load simulator can nowproceed.
The sequence of the integration implemented here is:
1) An initial temperature of the house model and the initial
thermostat status are sent to the environmental
chamber and to the Nest thermostat respectively. Then
the initialization is doneaccordingly.
2) The daily occupancy schedule is drawn from the
statistical information in theload simulator.
3) The setpoint / deadband are determined from the user
setting or the DR control insidethe load simulator.The
Fig. 5. Before making requests to thedata, an authorization must bemade.
An access tokenyieldedfrom the authorizationenables requests to theNest
API [6].
setpoint / deadband, the occupancy and the current
house temperature are then sent to the aggregator.
4) The aggregator receives the information provided in
step 3 from a number of simulated house models and
considers its control error, then decides whether to
activateor deactivate HVAC loads.
5) The Nest thermostat receives the final decision fromthe
aggregator, performs internal logic yieldingits response
(HVAC mode / HVAC state) with resulting inside the
chamber accordingly.
6) The Nest thermostat response (HVAC mode / HVAC
state) is sent to the housemodel.
7) Chamber tracks the temperature of the house model at
the next time step through the PID controller.8) Repeat
from step 3 to 7.
2022 IEEEConference on Technologies for Sustainability (SusTech)
A schematic illustration of the process is also shown in Fig. 6.
What is different from the previous work is that the
thermostat logic in the load simulation for one of the house
models is replaced with the physical Nestthermostat.
C. Nest Data
Data types involved in the integration are tabulated in Tab.
I. The HVAC mode and the HVAC state are the ones pulled out
from the Nest thermostat. There are 5 modes for the HVAC
operation. When the HVAC mode is set to ‘Heat’ or ‘Cool’, the
Nest thermostat utilizes a singlesetpoint to control the HVAC
system. It only operates in heating or cooling mode. At the
‘Heat-Cool’ or ‘Eco’ mode, the setpoints for heating and
coolingareset respectively. The HVAC system can either heat
or cool the space. Users may want to set the less comfort
oriented values atthe ‘Eco’ mode. Note that the Nest does
Fig. 6. In the load simulation, the simulated thermostat logic for on of the
house models is replaced with the physical Nest thermostat. The Nest
thermostat receives or sends data through the Nest API. The model
temperature is implemented in a physical chamber via a PID controller
providing theNestthermostatan environmentto yield an actual response.
not support the user set deadband, but supports only the
setpoint. Therefore the setpoint / deadband given from the
load simulator may need to be adjusted accordingly. The Nest
thermostat senses the human occupancy via near-field
activity, far-field activity and ambient light sensor. The Nest
thermostat sets away status of the structure where it is
installed to ‘Home’ when occupied or ‘Away’ otherwise. It can
be set manually as well. However in the present work, we do
not let the thermostat make decision on the occupancy, but
the occupancy will be pushed to the thermostat through the
API. When the away status has turned to ‘Away’ from ‘Home’,
the Nest thermostat automatically switches HVAC mode to the
‘Eco’ regardless of the previous HVAC mode. However, the
‘Eco’ mode is independent of the away status, meaning that
the user can set the HVAC mode to non-‘Eco’ mode when they
are away if it is desired. 3 HVAC states indicate whether the
HVAC system is cooling or heating the space or is off. The
ambient temperature is the space temperature the Nest
thermostat is measuring.
V. RESULTS
The Nest thermostat learns about the thermal response of
the structure/ HVAC combination fromits interaction with the
air conditioned space, and about the schedules from
intractions with its human users. It learns about the HVAC
system it is controllingsuch as how fast the space warms and
cools,and how efficient the system is [7]. The Nest thermostat
used here is trained in real time, by inputing the statistical
occupancy schedule and the setpoint, also by implementing
the house model response in the chamber over several days.
Therefore the Nest thermostat is expected to have learned the
HVAC characteristics of the house model, and these
characteristics are reflected in the Nest thermostat response
shown in this section.
Fig. 7. Behavior ofthe housemodeldriven by thesimulated thermostatlogic
in cooling mode. The HVAC is activated only when the model temperature
goes outsidethe deadband.
A. Simulated thermostat response
The response of the simulated thermostat logic inside the
load simulation is shown in Fig. 7. The simulated thermostat
puts the HVAC into the cooling mode following (4), then it
behaves exactly as demonstrated in (5). The HVAC is
deactivated when the space temperature is lower than the
lower deadband, activated when spacetemperature is higher
than the upper deadband and keeps the previous state within
the deadband.
B. Nest response in various modes
1) Cool Mode: Fig. 8 shows the response of the Nest
thermostat in Cool mode with a setpoint of 24◦ C. In Cool
2022 IEEEConference on Technologies for Sustainability (SusTech)
mode, we observe that the Nest thermostat activates cooling
when the spacetemperature is at the setpoint or above. Also,
the thermostat deactivates cooling a short time after the
temperature goes under the setpoint. Note, for example, that
at around 4000 seconds, the cooling is found to be still
activated whilethe spacetemperature is measured at 23.5 ◦ C,
slightly below the setpoint, but is deactivated shortly
afterward. WhiletheNest thermostat could uselogic based on
an internal deadband, this does not necessarily correspond to
the actual space temperature deadband implemented in our
load simulations. However, a deadband-like behavior is also
observed in the spacetemperature response. The connection
between the internal Nest deadband and the space
temperature deadband is discussed later.
2) Heat-Cool Mode: Figs.9-10 showthe Nest thermostat
response in Heat-Cool mode. Both cooling and heating are
supported in the Heat-Cool mode, with setpoint of 24◦ C and
21◦ C taken at each mode. The Nest thermostat controls the
HVAC the same as in the Cool mode, with the lower internally
set deadband involved. From Fig. 10 at around 9000 seconds,
it is found that the coolingis notactivated when the space
2022 IEEEConference on Technologies for Sustainability (SusTech)
TABLEI
DATA UTILIZED IN THE INTEGRATION
Device Thermostat
Returns/Range Access Note
hvac mode ‘heat’,‘cool’,‘heat-cool’,‘eco’,‘off’ read/write
hvac state ‘heating’,‘cooling’,‘off’ read-only
ambienttemperaturec number read-only
target temperaturec number/9-32 read/write hvac mode=‘heat’ or ‘cool’
target temperature low c hvac mode=‘heat-cool’
number/9-32 read/write
/target temperature high c min gap betweenlow/high=1.5
eco temperaturelowc number/4-21/24-32 read-only hvac mode=‘eco’
/eco temperaturehighc
Structure Returns/Range Access Note
away ‘home’,‘away’ read/write
*Reading or writing the data is availablethrough the Nest API.
Fig. 8. Nest thermostat responsein Cool mode. Cooling is activated when the
space temperature reaches thesetpoint. An internally setlower deadband of
the Nest thermostat is observed tobe 0.5◦ C.
temperature is 24◦ C.Thereforeitappears thatan internally set
upper deadband is used in the Heat-Cool mode. The activation
of the heating is observed in Fig. 9 when the temperature is
below the heating setpoint.
3) Eco Mode: The response of the Nest thermostat in Eco
mode is shown in Fig. 11. In similar manner to the HeatCool
mode, the thermostat uses two setpoints for cooling and
heating.The utilization of thesetpointin thecontrol algorithm,
appears to be almost the same as in the Heat-Cool mode.
However, we can observe that the HVAC is activated with less
strict rules in Eco mode. In the cooling case, the upper
deadband for the cooling setpoint is detected, however it is
found that the lower deadband is not enabled. As soon as the
space temperature reaches the cooling setpoint, the Nest
thermostat turns off the cooling. The same response is
presumed in the heating case. The cooling activation at each
mode found through experiments, is tabulated in Tab. II.
Fig. 9. The Nest thermostat response in Heat-Cool mode. Both cooling and
heating areavailablein this mode. Cooling turns on when thetemperatureis
above the cooling setpoint,heating turns on when thetemperatureis below
the heating setpoint. Thelowerdeadbandis also observed inthis mode.
2022 IEEEConference on Technologies for Sustainability (SusTech)
Fig. 10. The HVAC loadcanbe forcedly increased or decreasedby moving the
setpoint.
Fig. 11. Nest thermostatresponseinEco mode.Cooling is notalways activated
immediately when thespacetemperature is above thecooling setpoint.No
lower deadband set for the cooling setpointin theEco mode. As soon asthe
space temperature comes under the cooling setpoint, the Nest thermostat
turns off the cooling.
TABLEII
COOLING ACTIVATION OF THE NEST THERMOSTAT
Temperature
> Tset
+0.5◦ C
set
Tset
−0.5◦ C
4 4 ×
< Tset
−0.5◦ C
× × ×
* : cooling activated, 4 : cooling sometimes activated or
sometimes not, × : cooling deactivated.
C. Using the Nest thermostat for aggregated DR control
Even though the Nest thermostat does not use the
deadband in the sameway as in thesimulated thermostatlogic
shown in § V-B, we can still utilize it within an aggregated DR
control algorithm,in which the switchingto achievereduction
or increaseof the HVAC load can be activated by adjustingthe
setpoint rather than by actively switchingthe state. When the
Nest thermostat receives a DR signal to reduce the HVAC load,
the setpoint can be adjusted to a less comfort oriented value.
In Fig. 10, the Nest thermostat changing the cooling setpoint
from 24◦ C to 27◦ C, the heating setpoint from 21◦ C to 18◦ C
responding to the DR signal, is shown. We observe that the
state changes as soon as the temperature setpoint is changed,
around 1000 seconds and 6000 seconds, leading to reduction
or increaseof the HVAC load.
Fig. 12. A disagreement between the temperature measured by the Nest
thermostat andthermocouples in the chamberis observed, due to the heat
capacity the Nest thermostatpossesses.
D. Characteristic of the Nest thermostat Response
Before we can usethe Nest thermostat for implementing DR
schemes, it is necessary to fully understand its dynamic
response to temperature changes. Our experimental
apparatus allows such a measurement, since the response of
the thermocouples used in the environmental chamber is
essentially instantaneous, and accurate due to careful
calibration of the thermocouples. Fig. 12 shows temperatures
as indicated by the thermocouples and by the Nest thermostat
insidethe environmental chamber. A discrepancy isobserved.
For example, when the chamber temperature reaches the
upper deadband limit and starts decreasing, the Nest
thermostat continues to increase. Also, the Nest thermostat
2022 IEEEConference on Technologies for Sustainability (SusTech)
measures the temperature with 0.5◦ C resolution, while
thermocouples have better than 0.01◦ C of resolution.
Moreover, sincethe rate of data transfer through the Nest API
is limited, the Nest thermostat temperature and its response
are updated with one minute frequency. While all these
factors contribute to the discrepancy observed, the principal
mechanism responsible for the behavior observed is likely to
be the effective heat capacity embedded in the Nest
thermostat and its temperture measurement apparatus,
whose detailed implementation is not well-documented. We
hypothesize that there is a heat transfer process between the
air surrounding the Nest thermostat and its temperature
measurement system, which can be modeled as a convective
heat transfer to a thermal mass.This behavior can bemodeled
by :
dTn(t)
Mn = Kn[Ts(t) − Tn(t)], (9) dt
where Mn is theeffective heat capacity of the Nest thermostat,
Tn(t) is the modeled Nest Temperature and Kn is a constant
that models the convective heat exchange between the
conditioned space and the Nest thermostat temperature
sensors. Then the control logic that can be used in the
aggregated load simulation, mimicking the control logic
observed in the real
Fig. 13. An actual anda modeledversionoftheNestthermostatcontrol inthe
cooling mode. The Nestthermostat is modeled considering the heat transfer
between the house model (chamber) and the Nest thermostat, the
temperatureresolution and the APIratelimit.
Nest thermostat, can be modeled. The control logic in Cool
mode in particular,could bedescribed by :
,if Tn(t) < Tset −
0.5◦ C
if Tn(t) ≥ Tset (10)
keeps previous state, otherwise,
replacing (5). The response of the Nest thermostat modeled
from (9), considering its temperature resolution and the API
information exchange rate limitations,is shown in Fig. 13. The
suggested model of the Nest shows reasonably equivalent
response to the actual Nest thermostat response, therefore is
expected to bring extra realism to the aggregated load
simulation.
VI. CONCLUSION
The integration of an actual responseof a commercial smart
thermostat, to the aggregated residential load control
simulation framework, developed by Mammoli et al. [1], is
introduced in this paper. With the help of the Nest API, the
Nest thermostat can easily report its status and receive
external signals such as DR / Aggregated load control signals.
As a result, the Nest thermostat is successfully integrated to
the simulation framework, and is able to control the house
model temperature. The ultimate goal of the present work is
to fully understand the interaction between the physical
responseof the Nest thermostat and its environment. The goal
of the present work is achieved,resultingin more ways to add
realism to the simulation. For example, improved model
control logic to beused in the simulation of smartthermostats,
can be implemented based on the new understanding of the
inertial thermal behavior of the Nest thermostat. Such
implementations are expected to bring better realism to the
many-agent load simulations,enablingthe implementation of
control algorithms thatbetter reflect the real world.
ACKNOWLEDGMENT
This research was supported in part by the Mitsubishi
Research Institute, who is entrusted by New Energy and
Industrial Technology Development Organization, under
contractMIRI/EEU 46-001,in partby the U.S. National Science
Foundation,under award 1541148.
REFERENCES
[1] A. Mammoli, M. Robinson, V. Ayon, M. A. Hombrados-Herrera, and M.
Martinez-Ramon, “A simulation framework to develop control and
forecasting tools for aggregated residential energy resources.” preprint
submittedto Energy and Buildings, 2017.
[2] T. Larson, M. Chandra, K. Ward, D. Brannan,andS. Tobias, “Cutting peak
demand - two competing paths and their effectiveness,” in Proc. IEPEC
International Energy Program Evaluation Conference, (Baltimore, MD,
US), Aug. 2017.
[3] Nest, “Nest learning thermostat advanced installation andsetuphelp for
professionalinstallers.”Available: https://nest.com/support/pro/article/
Help-with-installation-and-set-up.
[4] Nest, “Howto installyournest thermostat.” Available: https://nest.com/
support/article/How-to-install-your-Nest-Learning-Thermostat#works/
?mode=guide.
[5] Real Python, “Api integration in python - part1.” Available: https://
realpython.com/api-integration-in-python.
2022 IEEEConference on Technologies for Sustainability (SusTech)
[6] Nest Developers, “Oauth 2.0 authentication and authorization.”
Available: https://developers.nest.com/documentation/cloud/how-to-
auth.
[7] Nest,“Learnaboutearly-onandhowtochangesettings.”Available:https:
//nest.com/support/article/What-is-Early-On.

More Related Content

Similar to sustech.2022.8671326.docx

Cfd simulation of telecommunications cabinet
Cfd simulation of telecommunications cabinetCfd simulation of telecommunications cabinet
Cfd simulation of telecommunications cabinetmahdi Mokrane
 
Artificial neural network based controller for home energy management conside...
Artificial neural network based controller for home energy management conside...Artificial neural network based controller for home energy management conside...
Artificial neural network based controller for home energy management conside...Basrah University for Oil and Gas
 
Best of breed control of platinum reactors
Best of breed control of platinum reactorsBest of breed control of platinum reactors
Best of breed control of platinum reactorsRotimi Agbebi
 
Impact of Electrification on Asset Life Degradation and Mitigation with DER
Impact of Electrification on Asset Life Degradation and Mitigation with DERImpact of Electrification on Asset Life Degradation and Mitigation with DER
Impact of Electrification on Asset Life Degradation and Mitigation with DERPower System Operation
 
Solar Thermal Engineeirng chap 5.pdf
Solar Thermal Engineeirng  chap 5.pdfSolar Thermal Engineeirng  chap 5.pdf
Solar Thermal Engineeirng chap 5.pdfsolomon261775
 
A home energy management algorithm in demand response events for household pe...
A home energy management algorithm in demand response events for household pe...A home energy management algorithm in demand response events for household pe...
A home energy management algorithm in demand response events for household pe...Basrah University for Oil and Gas
 
An Adaptive Soft Calibration Technique for Thermocouples using Optimized ANN
An Adaptive Soft Calibration Technique for Thermocouples using Optimized ANNAn Adaptive Soft Calibration Technique for Thermocouples using Optimized ANN
An Adaptive Soft Calibration Technique for Thermocouples using Optimized ANNidescitation
 
Implementation of redundancy in the effective regulation of temperature in an...
Implementation of redundancy in the effective regulation of temperature in an...Implementation of redundancy in the effective regulation of temperature in an...
Implementation of redundancy in the effective regulation of temperature in an...IOSR Journals
 
Dynamic indoor thermal comfort model identification based on neural computing...
Dynamic indoor thermal comfort model identification based on neural computing...Dynamic indoor thermal comfort model identification based on neural computing...
Dynamic indoor thermal comfort model identification based on neural computing...Basrah University for Oil and Gas
 
Feasibility evaluation of two solar cooling systems applied to a cuban
Feasibility evaluation of two solar cooling systems applied to a cubanFeasibility evaluation of two solar cooling systems applied to a cuban
Feasibility evaluation of two solar cooling systems applied to a cubanyamile diaz torres
 
EARTH TUBE HEAT EXCHANGER
EARTH TUBE HEAT EXCHANGEREARTH TUBE HEAT EXCHANGER
EARTH TUBE HEAT EXCHANGERIRJET Journal
 
Report_EBACProject_BBP
Report_EBACProject_BBPReport_EBACProject_BBP
Report_EBACProject_BBPArun Sankar
 
Karimanal thrml co_design_itherm2010_final
Karimanal thrml co_design_itherm2010_finalKarimanal thrml co_design_itherm2010_final
Karimanal thrml co_design_itherm2010_finalKamal Karimanal
 
Intelligent home heating system
Intelligent home heating systemIntelligent home heating system
Intelligent home heating systemeSAT Journals
 

Similar to sustech.2022.8671326.docx (20)

Cfd simulation of telecommunications cabinet
Cfd simulation of telecommunications cabinetCfd simulation of telecommunications cabinet
Cfd simulation of telecommunications cabinet
 
Artificial neural network based controller for home energy management conside...
Artificial neural network based controller for home energy management conside...Artificial neural network based controller for home energy management conside...
Artificial neural network based controller for home energy management conside...
 
Best of breed control of platinum reactors
Best of breed control of platinum reactorsBest of breed control of platinum reactors
Best of breed control of platinum reactors
 
Impact of Electrification on Asset Life Degradation and Mitigation with DER
Impact of Electrification on Asset Life Degradation and Mitigation with DERImpact of Electrification on Asset Life Degradation and Mitigation with DER
Impact of Electrification on Asset Life Degradation and Mitigation with DER
 
iSAIRAS PAPER_AM060.PDF
iSAIRAS PAPER_AM060.PDFiSAIRAS PAPER_AM060.PDF
iSAIRAS PAPER_AM060.PDF
 
Solar Thermal Engineeirng chap 5.pdf
Solar Thermal Engineeirng  chap 5.pdfSolar Thermal Engineeirng  chap 5.pdf
Solar Thermal Engineeirng chap 5.pdf
 
IPAC 2016_final
IPAC 2016_finalIPAC 2016_final
IPAC 2016_final
 
Energy, economic and environmental analysis of fuzzy logic controllers used i...
Energy, economic and environmental analysis of fuzzy logic controllers used i...Energy, economic and environmental analysis of fuzzy logic controllers used i...
Energy, economic and environmental analysis of fuzzy logic controllers used i...
 
A home energy management algorithm in demand response events for household pe...
A home energy management algorithm in demand response events for household pe...A home energy management algorithm in demand response events for household pe...
A home energy management algorithm in demand response events for household pe...
 
An Adaptive Soft Calibration Technique for Thermocouples using Optimized ANN
An Adaptive Soft Calibration Technique for Thermocouples using Optimized ANNAn Adaptive Soft Calibration Technique for Thermocouples using Optimized ANN
An Adaptive Soft Calibration Technique for Thermocouples using Optimized ANN
 
Gt3311841189
Gt3311841189Gt3311841189
Gt3311841189
 
ar condicionado
ar condicionadoar condicionado
ar condicionado
 
Implementation of redundancy in the effective regulation of temperature in an...
Implementation of redundancy in the effective regulation of temperature in an...Implementation of redundancy in the effective regulation of temperature in an...
Implementation of redundancy in the effective regulation of temperature in an...
 
Dynamic indoor thermal comfort model identification based on neural computing...
Dynamic indoor thermal comfort model identification based on neural computing...Dynamic indoor thermal comfort model identification based on neural computing...
Dynamic indoor thermal comfort model identification based on neural computing...
 
Feasibility evaluation of two solar cooling systems applied to a cuban
Feasibility evaluation of two solar cooling systems applied to a cubanFeasibility evaluation of two solar cooling systems applied to a cuban
Feasibility evaluation of two solar cooling systems applied to a cuban
 
EARTH TUBE HEAT EXCHANGER
EARTH TUBE HEAT EXCHANGEREARTH TUBE HEAT EXCHANGER
EARTH TUBE HEAT EXCHANGER
 
Report_EBACProject_BBP
Report_EBACProject_BBPReport_EBACProject_BBP
Report_EBACProject_BBP
 
Karimanal thrml co_design_itherm2010_final
Karimanal thrml co_design_itherm2010_finalKarimanal thrml co_design_itherm2010_final
Karimanal thrml co_design_itherm2010_final
 
Intelligent home heating system
Intelligent home heating systemIntelligent home heating system
Intelligent home heating system
 
Intelligent home heating system
Intelligent home heating systemIntelligent home heating system
Intelligent home heating system
 

Recently uploaded

Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdfFraming an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdfUjwalaBharambe
 
Painted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of IndiaPainted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of IndiaVirag Sontakke
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Celine George
 
Capitol Tech U Doctoral Presentation - April 2024.pptx
Capitol Tech U Doctoral Presentation - April 2024.pptxCapitol Tech U Doctoral Presentation - April 2024.pptx
Capitol Tech U Doctoral Presentation - April 2024.pptxCapitolTechU
 
Solving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxSolving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxOH TEIK BIN
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17Celine George
 
Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxthorishapillay1
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)eniolaolutunde
 
MARGINALIZATION (Different learners in Marginalized Group
MARGINALIZATION (Different learners in Marginalized GroupMARGINALIZATION (Different learners in Marginalized Group
MARGINALIZATION (Different learners in Marginalized GroupJonathanParaisoCruz
 
Full Stack Web Development Course for Beginners
Full Stack Web Development Course  for BeginnersFull Stack Web Development Course  for Beginners
Full Stack Web Development Course for BeginnersSabitha Banu
 
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxHistory Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxsocialsciencegdgrohi
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxiammrhaywood
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdfssuser54595a
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationnomboosow
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxGaneshChakor2
 
Roles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in PharmacovigilanceRoles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in PharmacovigilanceSamikshaHamane
 
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...Marc Dusseiller Dusjagr
 

Recently uploaded (20)

Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdfFraming an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
 
Painted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of IndiaPainted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of India
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17
 
Capitol Tech U Doctoral Presentation - April 2024.pptx
Capitol Tech U Doctoral Presentation - April 2024.pptxCapitol Tech U Doctoral Presentation - April 2024.pptx
Capitol Tech U Doctoral Presentation - April 2024.pptx
 
Solving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxSolving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptx
 
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdfTataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17
 
Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptx
 
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)
 
MARGINALIZATION (Different learners in Marginalized Group
MARGINALIZATION (Different learners in Marginalized GroupMARGINALIZATION (Different learners in Marginalized Group
MARGINALIZATION (Different learners in Marginalized Group
 
Full Stack Web Development Course for Beginners
Full Stack Web Development Course  for BeginnersFull Stack Web Development Course  for Beginners
Full Stack Web Development Course for Beginners
 
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxHistory Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communication
 
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptx
 
Roles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in PharmacovigilanceRoles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in Pharmacovigilance
 
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
 

sustech.2022.8671326.docx

  • 1. 2022 IEEEConference on Technologies for Sustainability (SusTech) Integration of Statistical Models of Residential HVAC Loads with a Commercial Smart Thermostat Jeewon Choi, Matthew Robinson, Andrea Mammoli Department of Mechanical Engineering University of New Mexico Albuquerque, New Mexico 87131, USA chatchi923@unm.edu, mr369@unm.edu, mammoli@unm.edu Abstract—As part of an effort to develop accurate power flow simulations in the area of Demand Response (DR) control, we developed an agent-based model for power consumption by residential end uses. Electrical power loads occurring in individual houses are categorized and modeled statistically. We developed a thermostat model to simulate the HVACpower draw, one ofthe most important residential loadcategories. In the present work, we replace the simulatedthermostat fromone of the house models participating in the aggregatedloadcontrol, with a physical instance of commercial smart thermostat. Specifically, we selected a ‘Nest Learning Thermostat’ for integrationinthe loadsimulation. We usedthe Nest Application Programming Interface (API) for the integration process. We implemented a PID control system toregulate the temperature of an environmental chamber where the Nest thermostat is installed. The environmental chamber is intended to provide the Nest with conditions similar to what it would experience in a real-life setting. Learnings fromthe present workwill serve to increase the realismof large-scale agent-basedsimulations. Index Terms—Demand response, aggregated load control, smart thermostat, learningthermostat, Nest API I. INTRODUCTION Aggregated residential power uses are considered as prime resources for controllingloads atthe distribution feeder level. We recently proposed a simulation framework to develop scheduling and controls algorithms for aggregated residential power loads [1].In our framework, residential energy services are categorized into six groups, namely hot water, space temperature control, refrigeration, clothes washing / drying, cooking and lighting. These energy uses are then modeled from statistical data. The six energy services are modeled for each individual electric meter that exist within the simulation framework. Whileaggregated loads areconsistentfromday to day and relatively predictable,individual meter loads are not. Here, the necessity of the bottom-up approach to the characterization of power flow over the feeder arises.Among the residential loads categories considered, we choose the HVAC and the water heater as controllable resources. HVAC provides a sizeable fast response due to its high power draw, while water heater enables effective peak shifting due to its high energy storagepotential.The overall objectiveof the load simulation framework is to design control algorithms that shape the total distribution feeder load to respond to some external control signal, such as the power production of a substation-sited PV array.The purposeof the work presented here is to verify the realism of the simulation framework, concerningthe control of HVAC loads. With the advanceof Internet of Things (IoT) technology, the availability of smart house appliances is rapidly increasing. Smart thermostats for regulating space temperature are becoming popular, enabling the simple utilization of HVAC load as a controllable resource in aggregated load control. In this paper, we focus on the integration of a physical smart thermostat within the load simulation framework introduced by Mammoli et al. [1] by replacing the model thermostat switchingalgorithms with the actual responsefrom a physical thermostat. We selected the 3rd generation ‘Nest Learning Thermostat’ as the physical smart thermostat to be integrated, that will be referred to as the Nest thermostat throughout the paper. The Nest thermostat is attractive in that it possesses advanced HVAC controlling algorithms that provide user comfort combined with energy saving.Moreover, the Nest thermostat is well suited for aggregated control, since it provides an API that can be used for this purpose.In fact,Nest thermostats are already providing Demand Rsponse (DR) rewards under certain programs in collaboration with some energy providers [2]. The capabilities of the Nest thermostat in this respect will be considered and evaluated through a set of experiments in the present work. II. STATISTICAL LOAD SIMULATOR We first summarize the statistical load simulation process discussed in detail previously [1]. A schematic illustration of the HVAC load simulation is shown in Fig. 1. The number of load occurrence per day, the load start time and the load duration for each house are characterized by associated probability density functions (PDFs). At the beginning of each day, a schedulefor each load is drawn from PDFs.For the case of an HVAC event, the schedule generated indicates the human occupancy of the residential space. For example, on a particular day,a specific housecould be occupied from 12AM to 8AM, unoccupied from 8AM to 6PM then occupied from 6PM to 12AM. A temperature setpoint and associated 978-1-5386-7791-9/18/$31.00©2022IEEE
  • 2. 2022 IEEEConference on Technologies for Sustainability (SusTech) Fig. 1. Statistically drawn house occupancy schedule, setpoint/deadband, current house model temperature is sent totheloadaggregator. Basedon its control error, the loadaggregator decides whether to activate or deactivate the HVAC loads. The simulated thermostat logic responds to thesignalfrom the load aggregator, and its response is sent to the model. These steps are repeated in a timeloop. deadband are set to the value generally desired by user, although in some cases thesecould be modified for DR control purposes. In a normal operation situation, when the house is occupied, a narrower deadband is set to provide comfortable temperatures to residents.When unoccupied,the deadbandis set to wider range. DR control can take various forms,such as a change in the setpoint / deadband or by switchingthe HVAC operation back and forth. In the previous work [1] the deadband was simply set wider when unoccupied to reduce the HVAC load,as a normal smart thermostat would do, while the state of the HVAC compressor is switched depending on whether higher or lower load is required by the distribution system. During operation, the occupancy, the setpoint / deadband and the current spacetemperature for each house are sent to an aggregator. The aggregator calculates the control error, that is the difference between a desired signal determined by conditions at the substation and the aggregated HVAC load, the availablecontrol action,then makes a decision on whether and how much to collectively activate or deactivate HVAC loads. A detailed explanation on the aggregated load control principle is given in the previous work [1]. A signal from the aggregator is sent to the smart thermostat, which in turn, based on internal logic, either switches its on / off status or not. The housespacetemperature at the next time step, based on the house thermal model in combination with the HVAC operation, is then calculated. For this study,we assumethat all houses areequipped with an HVAC system based on an electrically powered heat pump for spacetemperature regulation.This setup is widely used in areas with moderate climate, and will become increasingly prevalent with increasing electrification of energy services. The thermal response of an air conditioned space can be described by [1]: (1) , (2) Q˙ R = Π × Λ × COP × PAC. (3) In this model, derived from the physical natureof the system, Ms is theeffective heat capacity of the conditioned space, Ts(t) is the temperature of the conditioned space, t is the time, Q˙ L is the thermal energy exchange between the conditioned space and its surrounding, Ta is the ambient temperature outside of the building, Ks models the heat exchange between the building and the external air, Q˙ R is the rate of energy outflow or inflow from the space via the HVAC, COP is the coefficient of performance of the HVAC system and PAC is the electric power consumed by the compressor. It is assumed that the heat pump utilizes a fixed-speed compressor,so that PAC stays constant. Π indicates whether the HVAC mode is cooling or heating, and Λ is a state function that indicates whether the compressor is on or off. The HVAC mode is determined by: (4) , where the HVAC is in cooling mode when Π = 1 or in heating mode when Π = −1. The switching logic for the simulated thermostat when the HVAC is in cooling mode is described by: (5) , where TL and TU are the lower and upper deadband limits for the space temperature control. When the temperature is within the deadband, the state function Λ at a particular time step remains the same as its previous value,i.e.switchingonly occurs when the temperature reaches the deadband limits.In similar manner,when HVAC is in heatingmode: (6) . The HVAC load for an individual houseata particular timestep is then calculated by LHVAC = Λ × PAC. (7)
  • 3. 2022 IEEEConference on Technologies for Sustainability (SusTech) In what follows,we describehow the logic for the HVAC mode decision and the HVAC state switching of one of the virtual thermostat in the simulations can be replaced with a physical instanceof a Nest thermostat. III. EXPERIMENTAL SETUP A. Chamber Temperature PID controller The physical environment in which the Nest thermostat is immersed mimics the real-time conditions of a house whose temperature is modeled by (1)-(3). The Nest thermostat yields Fig. 2. Illustrationof the environmentalchambersimulating a temperature of the house model. The chamber temperature is controlled by the two fans, providing thephysicalenvironment for theNest thermostat. the actual response that we want to utilize within the multiagent HVAC load simulation.The temperature within the environmental chamber is controlled using two fan / coil combinations. The cooling fan pushes air through a chilledwater heat exchanger and into the chamber. The heatingfan pushes air through electrically-operated heatcoils. In the experimental setup shown in Fig. 2, the temperature of the water running through the heat exchanger and the temperature of the heatcoils remains steady, therefore the speed of the fan determines the rate of temperature change on the chamber. Two fans are connected to the General PurposeInput Output (GPIO) pins of a Raspberry Pi computer, that hosts a fan speed control code. Only one of two fans runs atany one time. The fan speed is calculated based on theerror between the desired temperature and the current chamber temperature using a Proportional Integral Derivative (PID) control method. A PID controller that simply solves (8) is implemented: , (8) where u(t) is a control action, e(t) is the temperature error and ∆t is a time constant.The PID gains Kp,Ki and Kd are tuned experimentally so thatthe chamber temperature can precisely track the house model temperature. The chamber temperature is the average temperature from a set of T-type thermocouples placed at strategic locations within the chamber. An example of the PID controlled response of the chamber temperature is shown in Fig. 3, in which the physical chamber temperature tracks the model house temperature. B. Nest settings A 3rd generation Nest Learning Thermostat is selected as a physical thermostat. An electrical circuit of the HVAC system with a heat pump in an actual residential space,and thewiring of the Nest thermostat to the HVAC, are shown in Fig. 4. The 24V AC power from the transformer runs through terminals Fig. 3. With gains of Kp = 0.1, Ki = 0.004, Kd = 0.7, the PID control system implements thehousemodeltemperatureinsidethe chamber reasonably. R and C, to power the thermostat. Terminal W1, Y1 and G are used for sending signals to the heating element relay, the compressor relay and the fan relay of the heat pump system respectively. In the present experiment, the Nest thermostat terminals are not connected to an actual HVAC but the Nest thermostat still generates HVAC control signals in responseto its environment. These signals are obtainable through the voltage measurement in relevant terminals or through the utilization of the Nest API. The latter method is used in this work, with details will be covered in the following section. By detecting connections in its terminals, the Nest thermostat knows what kind of HVAC system it is controlling. In order to let the Nest thermostat know that it is associatingwith a heat pump system, open-ended wires are connected to terminal W1, Y1 and G as shown in Fig.4. IV. INTEGRATION OF THE LOAD SIMULATOR AND THE NEST THERMOSTAT Given this physical environment for the Nest thermostat, it is now necessary to integrate the response of the Nest thermostat to the overall simulation. The Nest API is the key tool utilized in the integration process,and steps taken for this purpose aredescribed in this section.
  • 4. 2022 IEEEConference on Technologies for Sustainability (SusTech) A. Nest API The Nest thermostat supports the API development through the REpresentational State Transfer (REST) network HyperText Transfer Protocol (HTTP), which allows a user to read or write on the Nest thermostat without physically contacting it. Through REST HTTP, a client(the thermostat itself, or a third- party agent such as an aggregator) can make requests to specific server URLs. The data can be manipulated on the server itself,or transfered back to the client[5]. Nest provides relevant URLs to API developers. While HTTP requests can be made via various platforms, in the present work, HTTP requests have been made in Python through the ‘requests’ library [5].A clientis created in the Nest Developers website (a) (b) Fig. 4. The Nest thermostat wiringfor an actualHVACsystem witha heat pump and a fan [3], [4]. Its responseis also reachablethroughtheNest API. that is assigned with a unique client ID, a client secret and an authorization URL. Before access to private data is available from the Nest thermostat, an access token [6] must be obtained. The Nest API uses the OAuth 2.0 protocol for the authorization process. With the client ID, the client secret ID and the authorization code, an access token is granted by making requests. The authorization code is obtained from the authorization URL with the user consent. Once the access token has been obtained,itis possibleto makecalls to theNest API, then access data such as setpoint or HVAC state for the specific Nestthermostat. Data are pulled in a JavaScriptObject Notation (JSON) object through the ‘GET’ method of the REST API, and pushed in through ‘PUT’ method. The process of authorization is shown in Fig.5. B. Integration Having established that data can be pushed in to or pulled from the Nest thermostat using the Nest API, the integration of the Nest thermostat to the load simulator can nowproceed. The sequence of the integration implemented here is: 1) An initial temperature of the house model and the initial thermostat status are sent to the environmental chamber and to the Nest thermostat respectively. Then the initialization is doneaccordingly. 2) The daily occupancy schedule is drawn from the statistical information in theload simulator. 3) The setpoint / deadband are determined from the user setting or the DR control insidethe load simulator.The Fig. 5. Before making requests to thedata, an authorization must bemade. An access tokenyieldedfrom the authorizationenables requests to theNest API [6]. setpoint / deadband, the occupancy and the current house temperature are then sent to the aggregator. 4) The aggregator receives the information provided in step 3 from a number of simulated house models and considers its control error, then decides whether to activateor deactivate HVAC loads. 5) The Nest thermostat receives the final decision fromthe aggregator, performs internal logic yieldingits response (HVAC mode / HVAC state) with resulting inside the chamber accordingly. 6) The Nest thermostat response (HVAC mode / HVAC state) is sent to the housemodel. 7) Chamber tracks the temperature of the house model at the next time step through the PID controller.8) Repeat from step 3 to 7.
  • 5. 2022 IEEEConference on Technologies for Sustainability (SusTech) A schematic illustration of the process is also shown in Fig. 6. What is different from the previous work is that the thermostat logic in the load simulation for one of the house models is replaced with the physical Nestthermostat. C. Nest Data Data types involved in the integration are tabulated in Tab. I. The HVAC mode and the HVAC state are the ones pulled out from the Nest thermostat. There are 5 modes for the HVAC operation. When the HVAC mode is set to ‘Heat’ or ‘Cool’, the Nest thermostat utilizes a singlesetpoint to control the HVAC system. It only operates in heating or cooling mode. At the ‘Heat-Cool’ or ‘Eco’ mode, the setpoints for heating and coolingareset respectively. The HVAC system can either heat or cool the space. Users may want to set the less comfort oriented values atthe ‘Eco’ mode. Note that the Nest does Fig. 6. In the load simulation, the simulated thermostat logic for on of the house models is replaced with the physical Nest thermostat. The Nest thermostat receives or sends data through the Nest API. The model temperature is implemented in a physical chamber via a PID controller providing theNestthermostatan environmentto yield an actual response. not support the user set deadband, but supports only the setpoint. Therefore the setpoint / deadband given from the load simulator may need to be adjusted accordingly. The Nest thermostat senses the human occupancy via near-field activity, far-field activity and ambient light sensor. The Nest thermostat sets away status of the structure where it is installed to ‘Home’ when occupied or ‘Away’ otherwise. It can be set manually as well. However in the present work, we do not let the thermostat make decision on the occupancy, but the occupancy will be pushed to the thermostat through the API. When the away status has turned to ‘Away’ from ‘Home’, the Nest thermostat automatically switches HVAC mode to the ‘Eco’ regardless of the previous HVAC mode. However, the ‘Eco’ mode is independent of the away status, meaning that the user can set the HVAC mode to non-‘Eco’ mode when they are away if it is desired. 3 HVAC states indicate whether the HVAC system is cooling or heating the space or is off. The ambient temperature is the space temperature the Nest thermostat is measuring. V. RESULTS The Nest thermostat learns about the thermal response of the structure/ HVAC combination fromits interaction with the air conditioned space, and about the schedules from intractions with its human users. It learns about the HVAC system it is controllingsuch as how fast the space warms and cools,and how efficient the system is [7]. The Nest thermostat used here is trained in real time, by inputing the statistical occupancy schedule and the setpoint, also by implementing the house model response in the chamber over several days. Therefore the Nest thermostat is expected to have learned the HVAC characteristics of the house model, and these characteristics are reflected in the Nest thermostat response shown in this section. Fig. 7. Behavior ofthe housemodeldriven by thesimulated thermostatlogic in cooling mode. The HVAC is activated only when the model temperature goes outsidethe deadband. A. Simulated thermostat response The response of the simulated thermostat logic inside the load simulation is shown in Fig. 7. The simulated thermostat puts the HVAC into the cooling mode following (4), then it behaves exactly as demonstrated in (5). The HVAC is deactivated when the space temperature is lower than the lower deadband, activated when spacetemperature is higher than the upper deadband and keeps the previous state within the deadband. B. Nest response in various modes 1) Cool Mode: Fig. 8 shows the response of the Nest thermostat in Cool mode with a setpoint of 24◦ C. In Cool
  • 6. 2022 IEEEConference on Technologies for Sustainability (SusTech) mode, we observe that the Nest thermostat activates cooling when the spacetemperature is at the setpoint or above. Also, the thermostat deactivates cooling a short time after the temperature goes under the setpoint. Note, for example, that at around 4000 seconds, the cooling is found to be still activated whilethe spacetemperature is measured at 23.5 ◦ C, slightly below the setpoint, but is deactivated shortly afterward. WhiletheNest thermostat could uselogic based on an internal deadband, this does not necessarily correspond to the actual space temperature deadband implemented in our load simulations. However, a deadband-like behavior is also observed in the spacetemperature response. The connection between the internal Nest deadband and the space temperature deadband is discussed later. 2) Heat-Cool Mode: Figs.9-10 showthe Nest thermostat response in Heat-Cool mode. Both cooling and heating are supported in the Heat-Cool mode, with setpoint of 24◦ C and 21◦ C taken at each mode. The Nest thermostat controls the HVAC the same as in the Cool mode, with the lower internally set deadband involved. From Fig. 10 at around 9000 seconds, it is found that the coolingis notactivated when the space
  • 7. 2022 IEEEConference on Technologies for Sustainability (SusTech) TABLEI DATA UTILIZED IN THE INTEGRATION Device Thermostat Returns/Range Access Note hvac mode ‘heat’,‘cool’,‘heat-cool’,‘eco’,‘off’ read/write hvac state ‘heating’,‘cooling’,‘off’ read-only ambienttemperaturec number read-only target temperaturec number/9-32 read/write hvac mode=‘heat’ or ‘cool’ target temperature low c hvac mode=‘heat-cool’ number/9-32 read/write /target temperature high c min gap betweenlow/high=1.5 eco temperaturelowc number/4-21/24-32 read-only hvac mode=‘eco’ /eco temperaturehighc Structure Returns/Range Access Note away ‘home’,‘away’ read/write *Reading or writing the data is availablethrough the Nest API. Fig. 8. Nest thermostat responsein Cool mode. Cooling is activated when the space temperature reaches thesetpoint. An internally setlower deadband of the Nest thermostat is observed tobe 0.5◦ C. temperature is 24◦ C.Thereforeitappears thatan internally set upper deadband is used in the Heat-Cool mode. The activation of the heating is observed in Fig. 9 when the temperature is below the heating setpoint. 3) Eco Mode: The response of the Nest thermostat in Eco mode is shown in Fig. 11. In similar manner to the HeatCool mode, the thermostat uses two setpoints for cooling and heating.The utilization of thesetpointin thecontrol algorithm, appears to be almost the same as in the Heat-Cool mode. However, we can observe that the HVAC is activated with less strict rules in Eco mode. In the cooling case, the upper deadband for the cooling setpoint is detected, however it is found that the lower deadband is not enabled. As soon as the space temperature reaches the cooling setpoint, the Nest thermostat turns off the cooling. The same response is presumed in the heating case. The cooling activation at each mode found through experiments, is tabulated in Tab. II. Fig. 9. The Nest thermostat response in Heat-Cool mode. Both cooling and heating areavailablein this mode. Cooling turns on when thetemperatureis above the cooling setpoint,heating turns on when thetemperatureis below the heating setpoint. Thelowerdeadbandis also observed inthis mode.
  • 8. 2022 IEEEConference on Technologies for Sustainability (SusTech) Fig. 10. The HVAC loadcanbe forcedly increased or decreasedby moving the setpoint. Fig. 11. Nest thermostatresponseinEco mode.Cooling is notalways activated immediately when thespacetemperature is above thecooling setpoint.No lower deadband set for the cooling setpointin theEco mode. As soon asthe space temperature comes under the cooling setpoint, the Nest thermostat turns off the cooling. TABLEII COOLING ACTIVATION OF THE NEST THERMOSTAT Temperature > Tset +0.5◦ C set Tset −0.5◦ C 4 4 × < Tset −0.5◦ C × × × * : cooling activated, 4 : cooling sometimes activated or sometimes not, × : cooling deactivated. C. Using the Nest thermostat for aggregated DR control Even though the Nest thermostat does not use the deadband in the sameway as in thesimulated thermostatlogic shown in § V-B, we can still utilize it within an aggregated DR control algorithm,in which the switchingto achievereduction or increaseof the HVAC load can be activated by adjustingthe setpoint rather than by actively switchingthe state. When the Nest thermostat receives a DR signal to reduce the HVAC load, the setpoint can be adjusted to a less comfort oriented value. In Fig. 10, the Nest thermostat changing the cooling setpoint from 24◦ C to 27◦ C, the heating setpoint from 21◦ C to 18◦ C responding to the DR signal, is shown. We observe that the state changes as soon as the temperature setpoint is changed, around 1000 seconds and 6000 seconds, leading to reduction or increaseof the HVAC load. Fig. 12. A disagreement between the temperature measured by the Nest thermostat andthermocouples in the chamberis observed, due to the heat capacity the Nest thermostatpossesses. D. Characteristic of the Nest thermostat Response Before we can usethe Nest thermostat for implementing DR schemes, it is necessary to fully understand its dynamic response to temperature changes. Our experimental apparatus allows such a measurement, since the response of the thermocouples used in the environmental chamber is essentially instantaneous, and accurate due to careful calibration of the thermocouples. Fig. 12 shows temperatures as indicated by the thermocouples and by the Nest thermostat insidethe environmental chamber. A discrepancy isobserved. For example, when the chamber temperature reaches the upper deadband limit and starts decreasing, the Nest thermostat continues to increase. Also, the Nest thermostat
  • 9. 2022 IEEEConference on Technologies for Sustainability (SusTech) measures the temperature with 0.5◦ C resolution, while thermocouples have better than 0.01◦ C of resolution. Moreover, sincethe rate of data transfer through the Nest API is limited, the Nest thermostat temperature and its response are updated with one minute frequency. While all these factors contribute to the discrepancy observed, the principal mechanism responsible for the behavior observed is likely to be the effective heat capacity embedded in the Nest thermostat and its temperture measurement apparatus, whose detailed implementation is not well-documented. We hypothesize that there is a heat transfer process between the air surrounding the Nest thermostat and its temperature measurement system, which can be modeled as a convective heat transfer to a thermal mass.This behavior can bemodeled by : dTn(t) Mn = Kn[Ts(t) − Tn(t)], (9) dt where Mn is theeffective heat capacity of the Nest thermostat, Tn(t) is the modeled Nest Temperature and Kn is a constant that models the convective heat exchange between the conditioned space and the Nest thermostat temperature sensors. Then the control logic that can be used in the aggregated load simulation, mimicking the control logic observed in the real Fig. 13. An actual anda modeledversionoftheNestthermostatcontrol inthe cooling mode. The Nestthermostat is modeled considering the heat transfer between the house model (chamber) and the Nest thermostat, the temperatureresolution and the APIratelimit. Nest thermostat, can be modeled. The control logic in Cool mode in particular,could bedescribed by : ,if Tn(t) < Tset − 0.5◦ C if Tn(t) ≥ Tset (10) keeps previous state, otherwise, replacing (5). The response of the Nest thermostat modeled from (9), considering its temperature resolution and the API information exchange rate limitations,is shown in Fig. 13. The suggested model of the Nest shows reasonably equivalent response to the actual Nest thermostat response, therefore is expected to bring extra realism to the aggregated load simulation. VI. CONCLUSION The integration of an actual responseof a commercial smart thermostat, to the aggregated residential load control simulation framework, developed by Mammoli et al. [1], is introduced in this paper. With the help of the Nest API, the Nest thermostat can easily report its status and receive external signals such as DR / Aggregated load control signals. As a result, the Nest thermostat is successfully integrated to the simulation framework, and is able to control the house model temperature. The ultimate goal of the present work is to fully understand the interaction between the physical responseof the Nest thermostat and its environment. The goal of the present work is achieved,resultingin more ways to add realism to the simulation. For example, improved model control logic to beused in the simulation of smartthermostats, can be implemented based on the new understanding of the inertial thermal behavior of the Nest thermostat. Such implementations are expected to bring better realism to the many-agent load simulations,enablingthe implementation of control algorithms thatbetter reflect the real world. ACKNOWLEDGMENT This research was supported in part by the Mitsubishi Research Institute, who is entrusted by New Energy and Industrial Technology Development Organization, under contractMIRI/EEU 46-001,in partby the U.S. National Science Foundation,under award 1541148. REFERENCES [1] A. Mammoli, M. Robinson, V. Ayon, M. A. Hombrados-Herrera, and M. Martinez-Ramon, “A simulation framework to develop control and forecasting tools for aggregated residential energy resources.” preprint submittedto Energy and Buildings, 2017. [2] T. Larson, M. Chandra, K. Ward, D. Brannan,andS. Tobias, “Cutting peak demand - two competing paths and their effectiveness,” in Proc. IEPEC International Energy Program Evaluation Conference, (Baltimore, MD, US), Aug. 2017. [3] Nest, “Nest learning thermostat advanced installation andsetuphelp for professionalinstallers.”Available: https://nest.com/support/pro/article/ Help-with-installation-and-set-up. [4] Nest, “Howto installyournest thermostat.” Available: https://nest.com/ support/article/How-to-install-your-Nest-Learning-Thermostat#works/ ?mode=guide. [5] Real Python, “Api integration in python - part1.” Available: https:// realpython.com/api-integration-in-python.
  • 10. 2022 IEEEConference on Technologies for Sustainability (SusTech) [6] Nest Developers, “Oauth 2.0 authentication and authorization.” Available: https://developers.nest.com/documentation/cloud/how-to- auth. [7] Nest,“Learnaboutearly-onandhowtochangesettings.”Available:https: //nest.com/support/article/What-is-Early-On.