A MULTI-AGENT HOME AUTOMATION SYSTEM FOR POWER
MANAGEMENT
Shadi Abras
§
, St
´
ephane Ploix
§§
, Sylvie Pesty
§
and Mireille Jacomino
§§
§
Laboratoire Leibniz-Institut IMAG
CNRS, UMR5552, 46, Avenue F
´
elix Viallet
38031 Grenoble, France.
§§
Laboratoire d’Automatique de Grenoble
CNRS, UMR5528, BP 46
38402 Saint Martin d’H
`
eres, France.
Keywords:
Home Automation System, Multi-Agent Systems, Automatic Control, Negotiation and Cooperation, Power
Management.
Abstract:
This paper presents the principles of a Home Automation system dedicated to power management that adapts
power consumption to available power ressources according to user comfort and cost criteria. The system
relies on a multi-agent paradigm. Each agent is embedded into a power resource or an equipment, which
may be an environment (thermal-air, thermal-water, ventilation, luminous) or a service (washing, cooking),
and cooperates and coordinates its action with others in order to find acceptable near-optimal solution. The
control algorithm is decomposed into two complementary mechanisms: an emergency mechanism, which
protects from constraint violations, and an anticipation mechanism, which computes the best future set-points
according to predicted consumptions and productions and to user criteria. The paper details a negotiation
protocol used by the both mechanisms and presents some preliminary simulation results.
1 INTRODUCTION
For the next decades, the two major problems con-
cerning energy are the greenhouse effect and the de-
pletion of petrol resources especially the energy pro-
vided by oil and gas. Therefore, by conscience or by
necessity, the resort to renewable resources of energy
such as wind or solar radiations, arrives in the build-
ings knowing that the building represents 47% of the
energy consumption and it is responsible for 25% of
the greenhouse effect (Fontaine, 2003). Moreover,
undoubtedly, the user will be confronted by variable
tariffs of energy according to the hour and the days
and to the energy producers. It is in this varied and
dynamic context of production and consumption of
energy that a building, equipped with a Home Au-
tomation system to control the energy, takes its im-
portance. The role of a Home Automation system
dedicated to power management is to adapt the power
consumption to the available power resources taking
into account user comfort criteria: it permits to limit
the use of supplementary resources which require ad-
ditional investment and to avoid the expensive need of
storage. A Home Automation system has to reach a
compromise between the priorities of the user in term
of comfort and in term of cost while satisfying tech-
nological constraints of equipment and user’s comfort
constraints.
This problem can be formulated as a scheduling prob-
lem. In (Ha et al., 2005), a solution based on a
Resource Constrained Project Scheduling Problem
(RCPSP), to improve the management of thermal-air
equipments, is presented. Its aim is to satisfy resource
constraints by coordinating the control of thermal-
air equipment. Nevertheless, this approach requires
precise predictive models and RCPSP techniques are
hardly adaptable to the context of multi energy re-
sources and multi equipments. In (Ha et al., 2006), an
anticipation mechanism using Bellman-Ford’s algo-
rithm (Cherkassky et al., 1994) is presented for solv-
ing the problem of managing predicted events in a
Home Automation system. The principal advantage
of Bellman-Ford’s approach is that the optimal solu-
tion is guaranteed (if exist) but the major disadvantage
3
Abras S., Ploix S., Pesty S. and Jacomino M. (2006).
A MULTI-AGENT HOME AUTOMATION SYSTEM FOR POWER MANAGEMENT.
In Proceedings of the Third International Conference on Informatics in Control, Automation and Robotics, pages 3-8
DOI: 10.5220/0001207200030008
Copyright
c
SciTePress
is the high order of complexity.
An alternative approach is to use Multi-Agent tech-
niques. Algorithms based on Multi-Agent Systems
are nowadays used in several areas such as Computer
science or Automatic Control. The first MAS ap-
proach for energy distribution have been presented in
(Jennings, 1994) and (H
¨
agg and Ygge, 1995). (Kok
et al., 2005) put forward a market-based control con-
cept for the supply and demand matching (SDM) in
electricity networks. It aims to propose a Multi-Agent
system for the electronic market. Its purpose is to
control tasks in future electricity network which is ex-
pected to develop into a network of networks in which
a vast number of system parts communicate and coor-
dinate with each other.
The developments of solutions based on Multi-Agent
Systems, well suited to solve spatially distributed and
opened problems, permit to imagine an intelligent
Multi-Agent Home Automation system. This paper
presents a Multi-Agent Home Automation System
(MAHAS). It focuses on the definition of a negoti-
ation protocol between agents embedded into equip-
ments as well as in energy resources. The paper is
organized as follows: section 2 describes, in a general
view point, the Multi-Agent Home Automation Sys-
tem. Section 3 presents the two main mechanisms of
this system: the emergency and anticipation mecha-
nisms. Section 4 presents, in detail, the principle of
the negotiation protocol for emergency and anticipa-
tion mechanisms. Then, the paper presents some pre-
liminary results and highlights the future work which
will be done.
2 MULTI-AGENT HOME
AUTOMATION SYSTEM
The three main features of the Multi-Agent Home Au-
tomation System (MAHAS) (Figure 1), which con-
sists of agents embedded into energy resources and
into the different equipments, are the following:
Distributed: the energy resources and equipments
are distributed spatially and their control systems
are independent.
Flexible: the energy resources are few but also
some equipments can accumulate energy (thermal-
air, thermal-water) or satisfy with delay to demands
of services (washing service, cooking service).
Opened: the number of connected resources and
equipments may vary with time (equipments or re-
sources can be connected or disconnected) without
having to completely redefine the control mecha-
nism.
In Multi-Agent Systems, the notion of control in-
volves operations such as coordination and negotia-
Solarradiations
Cooking
Washing Refrigerator
Heating
Hot water
Wind
Figure 1: Energy network and communication between em-
bedded agents housing.
tion among agents, elimination of agents that are no
longer present and adding new agents when needed.
2.1 Agent Architecture
The main functionalities of an agent in MAHAS are
shown in figure 2.
Prediction of
power needs
Co-Construction
of a plan
Characterization of
user behavior
Application or
revision of a plan
Prediction of
power resources
Prediction of
user behavior
Equipment
Actions
Applied set points
Plan
Predict set points
power
resources
Power
needs
Current state
User Constraints
& criteria
Weather
forecast
Information
from energy
producers
Agents
Agent
Local control
Anticipation
mechanism
Emergency
mechanism
Figure 2: Structure of an agent in MAHAS.
Depending on weather forecast, energy resource in-
formation and user habits:
Resource agent calculates the available power re-
sources: to determine what is and what will be the
available power. For the moment, the energy re-
sources are represented by a virtual energy resource
which manages operations between the different re-
sources.
Equipment agent calculates the prediction of power
consumption: to determine what are the future
power needs taking into account the usual behav-
iour of users.
ICINCO 2006 - INTELLIGENT CONTROL SYSTEMS AND OPTIMIZATION
4
From these predictions and taking into account
the user constraints and criteria, a plan is jointly
constructed by the different agents which negotiate
their future power consumption (section 4). The
construction of a plan by cooperating and negotiation
between agents is called the anticipation mechanism
(subsection 3.2). This plan includes predicted values
of the variables that characterize the environments
(for example: the room temperatures) or the end dates
of services (an oven for instance). Then, this plan is
applied but it can be modified in case of unforeseen
perturbations (for example: consumption peak). If
the perturbation is so important, the agents rene-
gotiate in order to recalculate plans. The real time
adjustment of a plan in order to match constraints is
achieved by cooperation between agents: it is called
the emergency mechanism (subsection 3.2).
A third mechanism may exist: the local control mech-
anism i.e. the controllers endowed into equipments
by the manufacturers. It’s time response is very
fast. This mechanism receives set points from the
agents. Besides, some information on its current state
(power needs) are sent back to the agents so that they
can be taken into account in the future plans. This
mechanism is not mentioned in this paper because
other mechanisms are slower and local controls are
assumed to be transparent.
One of the objectives of the MAHAS is to fulfil user
comfort. A notion bound directly to the comfort is
the satisfaction function (Simonin, 2001). Satisfac-
tion functions have been defined for energy resources
as well as for equipments. The equipment satisfac-
tion function will be expressed by a function defined
on the domain of the characteristic variable corre-
sponding to the interval [0, 100%] where zero means
”inadmissible” and 100% is ”perfect”. For example:
thermal air environment satisfaction function, which
is defined on room temperature values corresponding
to an interval selected by user, can be represented by
figure 3. The resource satisfaction function is also ex-
Figure 3: Thermal air environment satisfaction function.
pressed by a function where the characteristic variable
corresponds to produced power. When the produced
power exceeds the resource capacity, the satisfaction
function falls to 0%. The nominal power of the re-
sources corresponds to 100%.
3 AGENT MECHANISMS
3.1 Emergency Mechanism
The emergency mechanism is a real time adjustment
mechanism which is triggered out when the level of
satisfaction of an agent falls below the weak values
(10% for example). This mechanism, which relies
on the negotiation protocol (section 4), permits to
react quickly to avoid violations of energy constraints
and to guarantee a good level of user satisfaction. It
is considered as transparent for anticipation mech-
anism because emergency adjustments have very
small impact on the period considered by anticipation.
Therefore, the emergency mechanism adjusts, in
real time, set points coming from the predicted plan,
equipment’s current state (equipment satisfaction
value) and constraints and user criteria. The predicted
set points can be directly transmitted to the local
control mechanism or modified in case of emergency.
When the emergency mechanism is triggered, each
agent has multiple roles:
It evaluates, at predefined intervals, its current sat-
isfaction. Therefore, it uses an infinite internal
loop. This interval of time is called checking pe-
riod.
It can request help from other agents, by sending
messages, when its satisfaction falls below a level
of emergency.
It analyzes the other agent demand and makes some
propositions.
When it receives some answers to its demands, it
chooses and accepts the interesting propositions (to
have a maximum value of satisfaction).
It can allow, according to received messages, to
activate or inactivate its associated equipment.
If an equipment agent satisfaction decreases, it sends
messages requesting help from resource agents to ini-
tiate a negotiation. Other agent answers are collected
during a fixed delay and are sorted out according to
their satisfaction values. Then a solution which max-
imizes the satisfactions of equipments and resources
is chosen.
3.2 Anticipation Mechanism
The emergency mechanism is sufficient to avoid
constraint violations but a MAHAS can be improved
in order to avoid emergency situations. This im-
provement is obtained thanks to the anticipation
mechanism. The objective of this mechanism is
A MULTI-AGENT HOME AUTOMATION SYSTEM FOR POWER MANAGEMENT
5
to compute the predicted set points depending on
predictions of consumptions and on predictions of
energy resources. The anticipation mechanism relies
on the fact that there is on the one hand, some electric
equipments which are capable of accumulating
energy and on the other hand, some services that
have a variable date as for their execution: some
services can both be delayed or advanced. From these
preliminary observations, it is possible to imagine
that if the equipment consumption can be anticipated,
there is a way to organize it better.
The anticipation mechanism relies on learning
algorithms which are not explained in this paper.
As for the emergency mechanism, the anticipation
mechanism relies also on a negotiation protocol
(section 4). It works on a time window (anticipation
period) larger than the checking period and works
with average values of energy, because it is difficult to
make precise predictions, in order to keep emergency
mechanism transparent for it.
During anticipation mechanism, each agent has mul-
tiple roles:
When requested, it predicts future needs or re-
sources over a given number of anticipation period.
This period is a multiple of the checking period.
It analyzes the other agent demands and makes
some propositions.
When it receives some answers to its demands, it
chooses and accepts the best propositions (to have
a maximum value of satisfaction for all).
It calculates, according to received messages, its
predicted set points.
The message exchanges between agents during emer-
gency and anticipation negotiations are defined by a
protocol which is presented in the next section.
4 NEGOTIATION PROTOCOL
The negotiation protocol has been defined on the ba-
sis of the contract negotiation model (Mathieu and
Verrons, 2004), CNP protocol ((Smith, 1980), (Yang
et al., 1998)) and algorithms of distributed constraint
satisfaction problems (Makoto and Hirayama, 2000).
This protocol can be used for agent mechanisms ac-
cording to the checking period for emergency mech-
anism and anticipation period for anticipation mecha-
nism.
The negotiation protocol is characterized by suc-
cessive messages exchanged between resource and
equipment agents. Agents exchange messages for two
objectives:
To avoid to overpass the maximum available en-
ergy.
To keep the satisfactions over a certain value: ac-
ceptable characteristic variable for environments
which accumulate energy and acceptable shifts for
services.
The agreements issued from negotiations are based on
satisfactions of equipments (representing user com-
fort criteria) and on satisfactions of resources (repre-
senting the ideal power production).
4.1 Phases of Negotiation Protocol
The negotiation protocol (Figure 4) may be decom-
posed into three phases:
Energy demand phase: During this phase, the re-
source agents request equipment agents for propo-
sitions that lead to satisfactions greater or equal to
an attempting satisfaction value and wait for equip-
ment agent answers.
Proposition phase: A conversation between re-
source agents and equipment agents takes place
during which new propositions are exchanged.
Then, resource agents analyse these propositions
and can either accept them or request for equipment
agents to send all the solutions for a new attempting
satisfaction.
Final decision phase: The resource agents take the
decision, so equipment agent demands can either
be accepted or refused.
Figure 4: Negotiation protocol.
ICINCO 2006 - INTELLIGENT CONTROL SYSTEMS AND OPTIMIZATION
6
The global success of negotiation is reached when all
the equipments have reached quite similar satisfac-
tions. When an event is under negotiation and no so-
lution is possible, a negotiation with the user starts to
modify user constraints.
4.2 Primitives of Negotiation
Protocol
The primitives of negotiation protocol are decom-
posed into two groups.
Energy resource agent primitives:
Request: The resource agents initiate a negotiation
by asking equipment agents to send them their
power needs in order to reach a satisfaction greater
or equal than an attempting satisfaction provided
by resource agent. It collects the answers, it
verifies if there is a global solution. Next request
indicates to the equipment agents that there is no
solution for the attempting satisfaction because
the energy asked by equipments exceeds the
maximum available energy provided by resources,
so resource agents request equipment agents to
send them other propositions about their needs for
a smaller attempting satisfaction. A request may
be defined as:
request(mechanism-name, period,
satisfaction)
where mechanism-name has two values ”emer-
gency” or ”anticipation”. period value may be
equal to the checking period or to the anticipation
period. satisfaction is the attempting satisfaction
value provided by resource agent.
Accept: This message indicates to equipment
agents that one of the proposed solutions has been
accepted by a resource agent. This message may
be defined as:
accept(proposition)
where proposition is one of the solutions proposed
by the equipment agents.
Renegotiate: This message indicates that there is
no solution that satisfies the constraints defined by
the user. A negotiation with the user starts. This
message may be defined as:
renegotiate(constraints)
where constraints is the set of constraints that can-
not be satisfied.
Equipment agent primitive:
Help: This message initiates a negotiation. It is
sent when an emergency situation is detected or
foreseen for the next checking period. It may be
defined as:
help().
Propose: This message replies to a request from
resource agents. It contains a set of propositions
of possible sequences of energy consumption
covering one period for an emergency mechanism
or several periods for an anticipation mechanism.
This list may be empty if there are not any possible
propositions.
This message may be defined as:
propose(set-of-powers,
satisfactions)
where set-of-powers are the propositions of equip-
ment agent during the checking or anticipation
period. satisfactions are the predicted satisfaction
values corresponding to each proposition.
4.3 Preliminary Results
In this subsection, an illustrative example is presented
for Home Automation system which consists only of
thermal air environments which are the largest part
of consumption of electricity in buildings in winter.
This system consists of three electrical heaters of
1kW each and a 2100W energy resource knowing
that the initial temperatures in rooms are fixed to
18
o
C and the desired value of temperature is 20
o
C
(satisfaction function takes its values between 0% for
18
o
C and 100% for 20
o
C). The temperature values
Figure 5: Simulated temperature in room 1.
for other rooms are quite similar to room 1 (Figure
5). The control system, in this example, is capable of
maintaining temperature values for each environment
above 18
o
C: because of the lack of power, the tem-
peratures remain close to the minimum acceptable
value. An example of exchanged messages between
the energy resource agent and the equipment agents
is presented below:
Heater2: help(heater2)
Resource: request
("emergency",15s,90%)
Heater2: propose (900W,90%)
Heater1: propose (900W,90%)
Heater3: propose (900W,90%)
Resource: request
("emergency",15s,80%)
A MULTI-AGENT HOME AUTOMATION SYSTEM FOR POWER MANAGEMENT
7
Heater3: propose (800W,80%)
Heater1: propose (700W,70%)
Heater2: propose (750W,75%)
Resource: request
("emergency",15s,70%)
Heater1: propose (650W,65%)
Heater3: propose (700W,70%)
Heater2: propose (600W,60%)
Resource: accept(650W, 600W, 700W)
Heater1: help(heater1)
Resource: request
("emergency",15s,90%)
Heater2: propose (900W,99%)
Heater1: propose (900W,90%)
Resource: accept(900W, 900W, 0W)
Heater2 agent has requested help from the resource
agent to start the negotiation. Then a conversation
between the agents takes place during which the re-
source agent requests the equipment agents to send
their propositions for an attempting satisfaction value,
and during which the equipment agents send their
propositions, which may be empty, to the resource
agent.
In the absence of MAHAS but with an unbalancing
system, always the same heater is penalized when all
heaters simultaneously consume energy according to
the user’s predefined priorities. Contrary to MAHAS,
the maximum user satisfaction cannot be guaranteed.
5 CONCLUSION AND
PERSPECTIVES
This paper has presented a Multi-Agent Home Au-
tomation system allowing the agents to cooperate and
coordinate their actions in order to find the accepted
near-optimal solution for power management. Nego-
tiation protocol has been detailed. The experimen-
tal results have showed the performance of the ne-
gotiation algorithm. This paper have provided evi-
dence that cooperation and negotiation capabilities of
Multi-Agent systems can be advantageously used in
automatic control systems for spatially distributed and
opened systems.
The implementation of a simulator for the emergency
and anticipation mechanisms is not finished yet. This
simulator will be tested on a reduced-scale model of
an apartment composed of two thermal environments
and several services (washing machine,...). Each en-
vironment contains a reduced-scale electric heater, a
temperature sensor and a micro-controller card with
an embedded Java Virtual Machine.
REFERENCES
Cherkassky, B. V., Goldberg, A. V., and Radzik, T. (1994).
Shortest paths algorithms: theory and experimental
evaluation. In SODA ’94: Proceedings of the fifth an-
nual ACM-SIAM symposium on Discrete algorithms,
pages 516–525, Philadelphia, PA, USA. Society for
Industrial and Applied Mathematics.
Fontaine, N. (2003). Livre blanc sur les
´
energies. d
´
ebat national sur les
´
energies,
http://www.industrie.gouv.fr/energie/politiqu/ploe.htm.
Ha, D. L., Ploix, S., Zamai, E., and Jacomino, M. (2005).
Control of energy consumption in home automation
by ressource constraint scheduling. In The 15th Inter-
national Conference on Control System and Comput-
erScience, Bucharest, Romania.
Ha, D. L., Ploix, S., Zamai, E., and Jacomino, M. (2006).
A home automation system to improve household en-
ergy control. In The 12th IFAC Symposium on Infor-
mation Control Problems in Manufacturing.
H
¨
agg, S. and Ygge, F. (1995). Agent-oriented programming
in power distribution automation. PhD thesis, Univer-
sity of Karlskrona/Ronneby, Ronneby, Sweden.
Jennings, N. R. (1994). The ARCHON system and its appli-
cations. In Second International Working Conference
on Cooperating Knowledge Based Systems (CKBS-
94), pages 13–29, Keele, UK.
Kok, J. K., Warmer, C. J., and Kamphuis, I. G. (2005).
Powermatcher: multiagent control in the electricity in-
frastructure. In AAMAS ’05: Proceedings of the fourth
international joint conference on Autonomous agents
and multiagent systems, pages 75–82, New York, NY,
USA. ACM Press.
Makoto, Y. and Hirayama, K. (2000). Algorithms for
distributed constraint satisfaction: A review. Au-
tonomous Agents and Multi-Agent Systems, 3(2):185–
207.
Mathieu, P. and Verrons, M. H. (2004). Three differ-
ent kinds of negotiation applications achieved with
GeNCA. In Proceedings of the International Confer-
ence on Advances in Intelligent Systems - Theory and
Applications (AISTA) In cooperation with the IEEE
Computer Society, Centre de Recherche Public Henri
Tudor, Luxembourg-Kirchberg, Luxembourg.
Simonin, O. (2001). Le mod
`
ele satisfaction-altruisme :
coop
´
eration et r
´
esolution de conflits entre agent situ
´
es
r
´
eactifs, application
`
a la robotique. PhD thesis, Uni-
versit
´
e Montpellier II.
Smith, R. G. (1980). The contract net protocol: High-
level communication and control in a distributed prob-
lem solver. IEEE Transaction on Computers, C-
29(12):1104–1113.
Yang, J., Havaldar, R., Honavar, V., Miller, L., and Wong,
J. (1998). Coordination of distributed knowledge net-
works using contract net protocol. IEEE Information
Technology Conference, Syracuse, NY.
ICINCO 2006 - INTELLIGENT CONTROL SYSTEMS AND OPTIMIZATION
8