IoT ReDy Architecture for Smart Grid Management

Smart Grid introduces intelligent infrastructure to the existing power grid. Energy production is no longer confined just to large power plants, but is becoming geographically distributed on small renewable energy plants that can inject electricity directly into the grid. IoT proposes a good solution to connect the producers to the consumers and to propose a reactive balancing of power production and consumption. The ReDy architecture, which is intended for IoT applications, provides a base to implement a scalable, reliable, and dynamic IoT network ready to meet Smart Grid needs. The different producers and consumers represent nodes of a decentralized network managed with a dynamic membership management algorithm. Each node is a centralized sub-network composed of one gateway making decisions and several sensors and actuators.


Introduction
A smart grid is an electrical distribution network that promotes the communication of information between power producers and consumers in order to adjust the flow of electricity in real time and enable more efficient management of the electricity grid.Information and Communication Technologies (ICT) are used to optimize the production, distribution, consumption and storage of power in order to better coordinate all the links of the electricity grid, from the producer to the final consumer (Gungor et al., 2011).
Intelligent infrastructure is needed for the implementation of the smart grid (Reka and Dragicevic, 2018).In particular all the producers and consumers have to be equipped with communicating sensors, e.g.smart meters, actuators and intelligent devices that have to decide on production and consumption plans.These communicating devices are elements of an Internet of Things (IoT) network (Atzori et al., 2010).
This IoT network has to be scalable, reliable and dynamic.
-Scalable: To handle large implementation of IoT network on a country or a region of the world and also with more and more elements in the same area.The data produced by this network needs Big Data management techniques to be computed.No centralized computation can deal with the computation charge, only a decentralized and local computation can resolve this problem.
-Reliable: If an element of the network leaves the network without giving notice, whether if it is faulty or because of the loss of the physical link to the rest of the network, the network has to deal with the absence of this element (producer or consumer) and to establish a new balance.
-Dynamic: Elements can be added or removed from the network without stopping or reconfiguring other elements of the network.To add a new element, we can just connect it to one existing element of the network.
We propose to use our ReDy architecture (Hafdi and Kriouile, 2015;Hafdi et al., 2017) solution to guarantee those requirements.

Contributions:
In this paper, we propose to make use of advantages of the IoT paradigm in order to manage smart grids to meet the above requirements.This purpose is achieved by using the ReDy architecture intended for the design of IoT applications.We show how the use of the ReDy architecture ensures reliability and dynamic membership management of the Smart Grid.As a result, we show how the use of the ReDy architecture ensures a power optimization in the Smart Grid.
Outline: The rest of this paper is organized as follows.Section 2 discusses the specification of a ReDy architecture intended for IoT applications.Section 3 presents requirements and basics of the Smart Grid.Section 4 exhibits the resulting Smart Grid model using the ReDy architecture.Section 5 shows how can the IoT ReDy architecture help on optimizing the power in a Smart Grid.Section 6 discusses a proposition for physical network implementation of our solution.Section 7 surveys related work.Section 8 gives concluding remarks and directions of future work.

IoT ReDy Architecture
Figure 1.ReDy architecture example The ReDy Architecture (Hafdi and Kriouile, 2015;Hafdi et al., 2017) is proposed to organize highly Reliable and Dynamic IoT systems by ensuring a dynamic construction of the system and a high degree of reliability.The ReDy architecture is a reusable solution for a large spectrum of IoT applications.This solution integrates two important requirements that are common to the concerned systems.The first one is to design the system in a highly dynamic environment, i.e, components can continuously join and leave the system network.The second requirement is about fault tolerance.The designed system should have a high resistance to faults, which permit to preserve the overall behavior of the system even in the presence of faulty components.A large family of systems needs to guarantee the above requirements.Besides proposing a common architecture for those systems, the ReDy architecture gives general rules that should be respected and implemented during the design phase so as to construct reliable and dynamic IoT systems.
The ReDy architecture proposes a hybrid organization of IoT components, i.e, centralized and decentralized solutions are combined.The architecture is composed of different sub-systems.Each sub-system is organized with a centralized client server management.A subsystem consist of one governance unit and several detection and action units.The governance unit acts as the server.The detection and action units act as clients.In IoT applications, sensors are represented by detection units and actuators are represented by action units, while the governance unit represents the decision making device and the gateway to communicate with other subsystems.Each sub-system is considered as a node of the whole system.Nodes are organized in a decentralized mode.

Example
Fig. 1 illustrates an example of the global architecture of the ReDy distributed system.In this example, the global system is composed of three subsystems.Each subsystem contains one governance unit.The first subsystem is composed of three detection units and two action units.The second subsystem is composed of one detection unit and three action units.The third subsystem is composed of two detection units and two action units.This is a very simplified model used just for illustration purposes.The governance units are connected to each other, while the detection and action units of each subsystem are connected only to the governance unit of this subsystem.
In the ReDy architecture, the membership management of nodes is ensured using the shuffling algorithm (Jelasty et al., 2004;Jelasty et al., 2007;Voulgaris et al., 2005).This algorithm builds unstructured peer to peer networks which ensures a high degree of reliability and dynamic membership management.In fact, in the enhanced shuffling algorithm, each node maintains a list of c neighbors.The basic idea of this algorithm is that the nodes exchange their list of neighbors periodically (shuffle operations).The exchanged list is of the same length for all nodes.This length is called Shuffle Length (SL) and it is always smaller than c (the number of neighbors).An other important parameter used in this algorithm is the neighbors ages.For a given node of the network, having a list of neighbors, we give for each neighbor a number that we call Age.The age of all neighbors is increased by one when shuffling (executing a shuffle operation).Such a parameter allows to know the oldest neighbor in the list.
To join the network, a node has just to find one node in the overlay and to be tied to it.The joining node should construct its neighbors list and should be included in neighbors lists of other nodes.This is achieved by the periodic shuffling.
To leave the network, there is nothing to do: just leave.The system will adapt and ignore the node that has left when it is not responding.This feature provides a high failure resistance because a failed node can not inform the system when failing.

Smart Grid
In this section, we discuss the context of the introduction of Smart Grid to power management systems.This allows us to exhibit the different requirements of Smart Grid in order to design an adapted solution using the IoT ReDy architecture.

Towards Smart Grid
The traditional power grid has remained unchanged for almost a century.The technological advances that the world knows require an adaptation of the existing power grid in order to bypass a set of new challenges namely the increase in energy consumption per person and the increase in population.This requires more and more energy production while conventional resources are limited and are increasingly reaching their limit.In addition, conventional energy has a negative impact on the environment and contributes to the climate change that the planet knows.Reducing the emission of greenhouse gases requires a reduction in the production of conventional energies, especially fossil fuels.
This is why humanity is moving towards less polluting energies and sustainable resources called renewable, which are geographically distributed due to the nature of their resources (solar, wind, hydraulic, geothermal, biomass, etc.).The distribution of these sustainable resources requires a distribution of their production.In this new perspective, we start talking about distributed energy generation.Energy production is no longer confined just to large power plants, but is becoming geographically distributed on small renewable energy plants that can inject electricity directly into the grid.
In addition to that, the distributed production is beneficial as it allows to bring closer the production from the consumption points which was always very scattered.Electricity production that is geographically close to consumption points saves electrical energy losses at the transport level.
On the other hand, renewable energies depend on the availability of their natural resources, which are variable over time.These energies are then called intermittent because the production of renewable energies depends on the meteorological conditions.For example, solar photovoltaic energy will be present as long as the sun is present during the day and will be absent at night.Wind energy is present as long as the wind blows and stops as soon as it stops.
Taking into account this new configuration of the power grid and the new dynamics of these resources, a new complexity is then introduced in the management and stabilization of the power grid.This is why the concept of smart grid is introduced.These smart grids integrate a data network in parallel with the conventional electricity distribution network and offer tools for monitoring, analyzing and controlling the production and consumption of energy in the power grid.
Smart grids use modern communication technologies and automated control tools to ensure that at all times the amount of electricity injected into the grid is equal to the amount of electricity consumers draw.Unlike the traditional network where the interaction is one-way in order to deliver power to the point of consumption, the main idea in the smart grid is to make interactive any point connected to the grid by ensuring a dialogue in both ways.Thus, electricity and information are exchanged between the various elements of the grid to ensure a balance in the power grid.
We no longer speak of absolute producer and absolute consumer, but we speak of node of the network, such that at a given moment each node can be globally consumer or globally producer.Each node is composed of a point of access and connection to the network that has decision-making power, and at least one consumer or producer element or both.
A generic schema of a smart grid is presented in the figure 2. The latter includes mainly producer nodes such as conventional power plants, solar power plants, wind turbines, etc., mainly consumer nodes such as factories, charging points for electric vehicles, the tramway, in addition to fairly balanced nodes such as green buildings which are in general energy efficient because they include local renewable energy sources.These can play the role of producers at times and the role of consumers at other times.The nodes of the network are doubly connected to the network by the electricity distribution network but also by a data network.

Smart Grid Requirements
Based on the challenges presented above, smart grids must meet a set of requirements that we present in the following: -Dynamic membership management of the system components: in a smart grid, nodes are dynamic, ie, a node can connect to or disconnect from the network at any given time without giving notice.The critical aspect of the power grid must be able to ensure uninterrupted operation even if nodes are added to or removed from the grid.-In a smart grid, it is necessary to have sensors that are in contact with the environment to capture any significant event or information.In general, this information and events are related to the production or consumption of electricity.Based on the data collected by sensors, we must be able to make adequate decisions.These decisions are sent to entities in contact with the environment who are responsible for executing decisions.
-The intelligent network is spread over a given geographical area.It must therefore be possible to cover the geographical area concerned.

The Smart Grid Modeling Using the ReDy Architecture
In this part, we propose a modeling of the smart grid by the ReDy architecture.We propose to focus on the functional and distributed aspects of smart grids.The goal is to analyze the reliability and the dynamic membership management of smart grids.That is why we model a smart grid with a ReDy architecture where each node of the smart grid represents a subsystem of the ReDy architecture.
In a smart grid, each node has an energy management device that is responsible for controlling the operation of the electronic devices and deciding to turn them on or off according to criteria and rules specified during the implementation of the device.This device is in communication with both the internal elements of the node and with the external environment namely the other nodes of the smart grid.This central device of the node is modeled in the ReDy architecture by the subsystem governance unit.
Each node is made up of different elements producing and / or consuming electrical energy.On the other hand, it is equipped with a set of sensors for monitoring energy production or energy consumption.These sensors are modeled in the ReDy architecture by detection units.
A node can be equipped with actuators to start or stop the production of a producer or the consumption of a consumer.These actuators are modeled in the ReDy architecture by action units.
The governance unit, the detection and action units of a subsystem differ according to the nature of the concerned node.A node can be a smart home, a factory, a smart building, a power generation plant or other.
The power grid is a rather stable network and we are trying to keep that stability over time.We are also working to make the power grid more tolerant to adding and removing nodes as well as to failure of some equipment by providing service as long as a physical path allows it.The electrical grid is governed by the rules of physics, which stipulate, for example, that the electron produced is always consumed by the nearest consumer.
On the other hand, we are interested in our modeling to the data network, which must supervise and manage the distributed and dynamic aspect of the smart grid.The use of the ReDy architecture allows us to achieve this objective since it proposes a decentralized management model of the various nodes of the network (subsystems of our ReDy architecture).Each node keeps a list of neighbors and exchanges some of these neighbors each turn to automatically discover new neighbors and automatically eliminate neighbors that no longer interact (either because they are failing or because they have left the network).The node will always communicate the information relating to its production and consumption of electricity to its neighbors and will also communicate its possibilities of increasing and decreasing the production as well as the availability of flexible consumer (electric vehicle to recharge without emergency, electric balloon for heating water, battery, etc.) to operate in case a free or low cost production is available.

The Smart Grid Features
In this part, we exhibit the main features that must be realized globally in the smart grid.These features are divided into two modes: local mode and distant mode.Local mode refers to the functionalities that must be fulfilled by a node in the network, since it represents communications between entities that belong to the same subsystem.
The distant mode concerns the exchanges between the different nodes of the grid.

Local Mode
In local mode we deal with the communications within the same node represented by the subsystem.The aim is to guarantee a centralized communication between the intelligent device represented by the governance unit and the different sensors and meters represented by the detection units and the actuators represented by the action units.
The objective is to have a real-time data about the state of production and / or consumption of electrical energy and to have a view on the production and consumption available capacities.This device is the decision-maker and gateway of all the elements of the node to the outside of the node.
This mode is specific to the type of the concerned node.Practically speaking, local mode features in a smart house are different from features in a factory or in a power generation plant.

Distant Mode
The required features in the distant mode concern the communications that take place between the nodes of the grid.
A mainly consumer node communicates the amount of used energy by the mean of the smart meter.It also communicates its flexible consumptions ready to be activated or the current one ready to be deactivated.
A mainly producer node communicates the amount of energy injected into the grid.It also communicates its unused production capacity and production plan in the coming period.A renewable energy plant can communicate its produc-tion forecasts for its intermittent renewable resources.For a renewable energy with a large storage capacity such as Concentrated Solar Power (CSP plants), the state of energy stocks is also to be communicated.
In the case of a lack of production or a need for consumption, data on the availability of additional resources or the possibility of deactivating non-urgent consumption makes it possible to better manage available resources and, above all, better manage the cost of electricity.In the same way, in the case of an excess of production, the most expensive producers, poluants or flexible ones can be warned to reduce their production.In this case we can also launch more flexible consumption.
It is a global intelligence of the grid that can be guaranteed in a distributed and decentralized way that replaces the stabilization of the grid at any cost by an optimal stabilization of the grid.
Example Figure 3 represents an example of a smart grid modeled using the ReDy architecture.In this example, we have three communicating nodes (subsystems).We start by discussing the local mode communication.The first node is a gas power plant which is a mainly producer node.This node has (i) a detection unit that measures and displays the power production status, (ii) an action unit that is responsible of the modification of the production instructions, and (iii) a governance unit connected to action and detection units and to other nodes of the represented smart grid.The second node is a factory which is a mainly consumer node.Similarly to the first node, it has a detection unit responsible of measuring the power consumption, an action unit responsible of controlling the flexible consumption, and a governance unit responsible of the overall behavior of the node.The third node is an ecological house which is a balanced node because it has a renewable production system.This node has two detection units responsible of measuring the power production and consumption, and an action unit responsible of controlling the flexible consumption devices, in addition to the governance unit controlling the overall functioning of the node.
In the distant mode communication, there exist a two-way dialogue allowing to exchange data that concerns power consumption or production information, between each node and the smart grid.In addition to that, there exist a possible two-way energy routing that allows to each node to put electricity onto the grid or to retrieve electricity from the grid.
Figure 3. Smart Grid modeled using the ReDy Architecture

Dynamic Membership Management in the Service of Smart Energy Management
The nodes of the smart grid are connected to the data network.The nodes are organized according to two layers: physical layer and logical layer.The physical layer transmitting nodes data is established by power grid distribution companies.The logical layer is built using the principles of membership management in the ReDy architecture, mainly the shuffling algorithm.In fact, each node in the smart grid maintains a list of neighbors.This list is dynamic and periodically exchanged between nodes which allows to have a knowledge about active nodes in the network.
The main use of exchanging data in a smart grid is the optimization of production and consumption of power in the grid.A node can be a pure non-flexible consumer, a flexible consumer, a renewable producer, a conventional producer or a mix of them.Depending on the type of the node, the node can have different benefits from exchanging production and consumption data.
A non-flexible consumer exchanges data to inform the other nodes about his current power needs.
A flexible consumer exchanges data to inform the other nodes about his current power needs but also to have a knowledge about the capabilities of the power grid in order to decide to activate or deactivate his flexible consumption.
A renewable producer exchanges data to inform other nodes on his production status but also the availability of renewable resources.It uses the collected data to decide his production plan.
A conventional producer exchanges data to inform other nodes on his production status and non-used production capacities.It uses the collected data to have a knowledge on the current needs but also the current renewable production availabilities in order to decide on its production plan.
We remind that there is no centralized control of the production and the consumption in this architecture.A nonactive node will be eliminated automatically from the neighbors list of the other nodes.To add a new node we have just to connect him to one node.
As a result, the reliability guaranteed by the ReDy Architecture enables to continue reactive balancing of power production and consumption even if some nodes go out of the network.The dynamic aspect of ReDy architecture enables to take in account any new producer or consumer automatically.

Physical Network
In this part, we discuss a possible physical implementation of our IoT ReDy architecture in the context of Smart Grid.We propose to connect distant nodes using a LAN-Network and to use a ZigBee wireless network within the same node (subsystem).
The LAN-Network is based on Internet Protocol (IP) addressing to identify the different nodes.The neighbors list can be implemented by an IP address list.
For the ZigBee (Lee et al., 2007), the governance unit of the node represents the ZigBee coordinator.

Related Work
In the literature, a wired Network (LAN) is proposed to connect the nodes of the smart grid in particular to connect producers and consumers based on Internet Protocol (IP) principles while a wireless network is used within each node (Reka and Dragicevic, 2018;Gungor et al., 2011).This approach discusses the physical layer of the network and it is complementary to our proposed architecture which details the logical layer and architecture of the network.Different technologies can be used in this IoT implementation.For example, ZigBee, wireless Mesh, Cellular Network Communication, Powerline Communication, and Digital Subscriber Lines (Gungor et al., 2011;Whitmore et al., 2015;Miorandi et al., 2012).Each one presents issues and opportunities related to smart grids (Gungor et al., 2011).
There exist studies that present different solutions to prevent failures on the IoT network applied on Smart Grid.(Ciavarella et al., 2016) proposes a framework for contingency management by preventing subsequent failures.The authors propose an algorithmic solution that is implemented using the IoT paradigm.This approach confirms the need of a reliable IoT implementation for the smart grid case.
Data management on Smart Grids is an important issue related to the implementation of IoT solutions for Smart Grids.In our ReDy architecture we assume that each node is equipped with a governance unit and that this unit is able to compute data to decide to activate or deactivate actuators on his corresponding sub-network.Besides, it is proposed (Meloni et al., 2018) to use a Cloud-IoT-based architectural solution for smart grid that combines cloud capabilities and edge-computing advantages and uses virtualization technologies to manage and use the generated data.Test cases where the architectural solution is applied are given.In opposition to the latter vision, our approach looks for a fully distributed computation where nodes try to stabilize the grid with a "best effort" approach depending on collected data and node capabilities of production or flexible-consumption.This Cloud-IoT approach tries to have more global computations based solutions.This approach can be a good way to have additional computation and storage capacities if our approach reaches its computational limits.
In the same concern of data management, security and privacy of communicated data present a challenge for Smart Grid implementation.New protocols are proposed to preserve the privacy of communicated data within smart meters (Tonyali et al., 2018).Such protocols ensure the security and reliability of the smart grid.This approach has to be taken into account before any commercial implementation of our proposed ReDy architecture.

Conclusion
In this paper, we propose a solution to implement IoT support in the Smart Grid context.To this end, we use the ReDy architecture ensuring scalability, reliability, and dynamic membership management aspects.The ReDy architecture is based on a hybrid architecture: centralized and decentralized solutions are combined.This allows to Smart Grid nodes to optimize dynamically the power production and consumption.We propose a physical network implementation for the proposed solution.
As perspectives, an implementation of a prototype of this solution is planned.This prototype will allow to test the solution and to propose an optimum configuration of the shuffling algorithm in the case of Smart Grid.

Figure 2 .
Figure 2. Smart Grid Example The action and detection units are represented by ZigBee End Devices.If needed, intermediate elements called Routers will be charged of connecting the coordinator to some End Devices especially if the distance between the coordinator and End Device exceeds the range of ZigBee communication (30 to 50m).