1 Introduction

The power system is becoming increasingly complex in recent years. In its classical version, large size power plants, power lines (transportation and distribution), substations and a very large number of customers (loads) compose the grid. In this kind of grid, the energy flow is unidirectional: from the power plants to the loads. The grid stability is ensured using the energy balancing mechanism based on primary, secondary and tertiary control. The primary control is based on the frequency and voltage droop characteristics implemented in the control systems of the generators but it is not able to return the frequency to the normal value, it can only stabilize it. The secondary control modifies the setting points of power plants in order to maintain the mean frequency on 1 min time range and can be automatic or manually imposed by the grid dispatcher. The tertiary control can act on the reserve deployment and deal with the long time stability (hour range).

The complexity of grids increases and their structure changes with the expansion of the renewable energies. Comparing with classical power plants, the photovoltaic parks and wind farms are smaller and dispersed on large areas. As a result the power production passes from a centralized way to a distributed one and the energy flow becomes bidirectional on several segments because the same power lines are used to take up energy from renewable generators and to supply customers. To highlight the bidirectional connections and the complexity of the future smart grid, some authors speak about an internet of energy [1].

The integration of this distributed production in the grid can be facilitated by the establishment of microgrids based on geographical location, microgrids composed by small power plants, loads and storage facilities that share the same connection point with the main grid.

In this case, the main grid will perceive the microgrid as an entity, without having to directly manage each of its components.

Because of its distributed character, traditional management/supervision systems, which are designed to manage large production units operating under a centralized way, can hardly control the microgrids. Thus, the management mechanism of microgrids must consider decentralized nature of the system.

Multi agent systems (MASs) appear to be a very useful tool to operate and control power systems. They have three main characteristics:

  • Agents have a very high level of autonomy: each agent is able to control/manage with autonomy its own states and tasks.

  • The agents negotiate between themselves in order to solve complicated coordination problems.

  • “Each agent has a certain behavior and tends to satisfy certain objectives by using its services” [2]. As a result MASs can provide optimal management strategies to the corresponding unit.

Having taken all these characteristics into account, several researchers have focused the application of MASs in microgrids. There are a variety of MASs applications on microgrids:

  • Management and control applications including market operation, islanding and synchronization, substation automation...

  • Safety applications including grid restoration, self healing of microgrid, grid monitoring and preventive diagnosis...

Interactive design is a concept which can be applied to different knowledge areas. As it can be understood from its name, the concept is linked to systems where different components which can be human, software or hardware type, interacts between them (communication, action, decision making...) in order to design or redesign something.

Concerning MASs, the interaction between real and virtual agents is permanent. In their application to microgrids management, as it can be seen in some examples given below, MASs must often redesign the microgrid configuration in real-time in order to adapt it to new situations. For instance when a microgrid has to be disconnected from the main grid, firstly some virtual agents have to detect why and when the disconnection has to be carried out. Then, these agents must transmit this information to other virtual agents which have to adapt the overall system to the new situation, redesigning virtual agents associated to the management of the microgrids. Finally, these last agents configure again the microgrids for instance disconnecting some real agents, as loads, from it.

Another example could be the optimization problem in microgrids, which is a real-time, iterative and interactive process, and where often different scenarios are simulated in order to optimally reconfigure the microgrid.

This paper presents different applications of MASs on microgrids and emphasizes applications about microgrid dependability. The paper is composed by three main parts. Section 2 provides firstly a definition of a microgrid and its structure. Secondly, it shows the different issues related to microgrids, especially in applications where MASs are relevant. Section 3 describes MASs concept, the agents’ properties and different types of agents. Section 4 analyzes the complexity of microgrids and the different reasons to use MASs technique in this context. It also reviews MASs’ applications for management and dependability in microgrids.

2 Microgrids and theirs specific issues

The microgrid is a small-scale grid designed to provide electricity to a small community (buildings, schools, industries). Its sources can be based on fossil fuels (diesel, gas turbine...) and renewable energies (photovoltaic, wind turbine...).

The structure of a microgrid is not always the same. Anyway, each microgrid usually includes three types of components: distributed generation (DG), distributed storage systems and loads. An overview of a microgrid architecture is shown in Fig. 1. The DG is the producer of power. The distributed storage system stores power when production exceeds consumption and provide it when consumption exceeds production. The load is the consumer of power in the microgrid [3]. The electrical connection between the microgrid and the main grid is made through the point of common coupling (PCC).

Fig. 1
figure 1

Architecture of a microgrid

Conventional electrical grids often supply loads with alternating current (AC), but as renewable energies such as wind power and solar photovoltaic become more widespread in microgrids, direct current (DC) microgrids could be a more efficient and cheaper alternative. In fact, several devices used in microgrids deal with low voltage DC power: storage systems (batteries, supercapacities), fuel cells, PV panels, small-scale renewable sources (wind turbines, ...). In general, even if the electricity will ultimately be delivered to a DC load, generators require costly power converters / inverters because they supply power to AC mains electrical networks. In addition to the cost augmentation, the use of these inverters increases the power losses.

The significant increase of interest on the microgrids has drawn researchers’ attention on the various issues facing their operation. From a perspective of management, the primary goal of microgrids is to ensure the energy delivery to loads, while stabilizing the electrical infrastructure and reducing environmental emissions and operational cost [4]. Another main operation objective is to ensure a healthy and safe operation. Thus, it is important to concentrate researches also in the study of microgrid safety, in order to obtain a reliable system. In addition, considering the possibility of connection and disconnection between the microgrid and the main grid, it is also important to develop the issue of their islanding and synchronization.

2.1 Management optimization

In the management of microgrids, the main goal is to achieve a compromise between different constraints such as: the spot-market price of electricity, operational costs, weather conditions, fuel availability, greenhouse gas emissions, etc. [5].Therefore, the management optimization is an essential process in the operation of microgrids.

Two operational modes define the microgrid:

  • Grid connected mode: the microgrid exchanges power with the main grid (the upper level grid of the microgrid). The objective of the power exchange is to maintain power balance between supply and demand.

  • Islanded mode: there is no power exchange between the microgrid and the main grid, because they are electrically isolated [3].

Management in islanded mode In islanded mode, the main grid is unavailable. So according to [6] two main tasks must be executed: guarantee the power balance between production and consumption and the control/regulation of voltage amplitude and frequency of the system. As renewable DGs are not fully predictable, the controllable DGs, loads and distributed storage systems are charged of ensuring the power balance, managing the power difference between the renewable DGs and the local loads. In case of a supply excess, the management system has to store energy or to decrease the output power of the controllable DG to maintain the frequency and voltage of the microgrid. In case of a demand excess, available power cannot feed all local loads. So the management system has to take energy from the storage or to interrupt non-critical loads [4, 6].

Furthermore, the management in islanded mode can take into account several constraints as storage limitations, line losses, emissions of \(\hbox {CO}_{2}\), constraints of DG, as focused in reference [7], when fuel limits, generation limits, and rump up and ramp down limits are underlined.

Management in connected mode In connected mode, there is no interruption of the non-critical loads because the lack of delivered power to feed loads is no more a problem. Anyway, the management system usually tries to supply all the local loads (critical and non-critical loads) with local DGs. The supply of loads in connected mode is insured thanks to exchange of power with the main grid. In [8] authors proposed a simple MAS architecture which aims essentially to use local distributed resources in order to supply local loads. In this paper, the priority is given to the local production: the MAS considers the use of local DGs production, even if the cost of buying energy from the main grid is lower. In contrast, in [912], energy costs and market prices are the first priority of the microgrid operation.

Reference [12] proposes the concept of energy internet. The energy internet is defined in [12] as a vast network that efficiently supplies electricity to anyone anywhere. Such system becomes decentralized, reliable, and efficient thanks to the digital age. In this concept, electricity is considered as electrical data to dispatch in the microgrid. As written in [12] the limitation of energy internet is the lack of significant energy storage capacity inside the main grid.

In the management of microgrids in connected mode, some papers as [1315] incorporate environmental data in the mathematical model used in the management optimization. In these papers, authors focus on the minimization of \(\hbox {CO}_{2 }\)emissions. The environmental factor is generally, in the scientific literature, the one which has the least priority in the optimization criteria. Among other reasons, this factor is used to encourage the use of renewable energy sources, which are non-polluting.

2.2 Islanding and synchronization

In addition to the functions mentioned above, islanding detection and synchronization with the main grid are also a challenge for the control of microgrids. In fact, the microgrid islanding process may result from a planned or an unplanned disconnection from the main grid. If faults could not be immediately isolated or solved, or if unusual events occur, the microgrid must be disconnected. Therefore, the microgrid operates in islanded mode. Then it is the role of the DG to supply the electricity demand that was previously supported by the main grid. As aforementioned, under this situation, two things must be maintained: the balance between supply and demand, and the voltage and frequency of the system within acceptable ranges. Maintaining the power equilibrium between supply and demand during the transition period from one state to another needs a carefully designed control strategy [3]. That’s why islanding detection algorithms must be established [16, 17]. As in [18], islanding detection strategies can be classified into passive and active methods. Passive methods recognize islanding by detection of the voltage abnormality at the PCC, including frequency, phase shift and harmonics, to identify the islanding [19]. Even these methods are simple and do not have an impact on the normal operation of the DG system, they are not always reliable.

To improve the islanding detection capability, active islanding detection methods are employed. A suitable active islanding detection method is used in [18]. This method is essentially based on two actions: monitoring the voltage at the PCC and changing the magnitude of the injected current. Under grid failure, islanding is detected when the change in voltage at the PCC is more than the allowable range. Active islanding detections methods are more efficient than passive ones. Moreover, the perturbations caused by active islanding detection methods must not introduce any distortion nor affect the zero crossing of the converter current.

2.3 Microgrid safety

The safe and reliable operation of the microgrid, including controlling its components so that variables remain within acceptable tolerances is very important. The reliability issue is dealt with two types of methods: preventive ones, based on the knowledge accumulated from experience and predictive ones which depend on real-time data acquisition and processing. Both must allow avoiding the occurring of potential problems.

Self-healing and restoration After service interruption, it is imperative to obtain post-fault target grid configuration for the reaching of optimal operational sequence [20]. Indeed, to improve the safety of microgrids, self-healing is the first key. As written in [4], in general, in view of a single or many fault events, the system must be able to detect them and recover its normal behavior: it is the self-healing. For power system, the definition of self healing includes three important steps: identify the problems rapidly, act to minimize any adverse impacts from fault events, and recover promptly the system to stable operating state, if possible [21, 22]. Certain researches treat the self-healing as a single bloc [20]. Though, it is divided into two periods: the emergency reaction step and the restorative step [4]. The first step starts by the detection of the fault reason.

The typical reaction of the system is the isolation of the problem. Emergency reactions which may be automatic or predetermined are considered here. The effect of these reactions is to place the system in a safer and less perilous condition. Once the system has carried out the transition beyond the initial emergency, the restorative stage can starts. Several reconfigurations may take place during restoration, to improve the overall system state involving: load shedding or recovering, switch manipulations, generation startup or shutdown, or other actions which change system set point [23].The restorative stage may be the longest and the most complicated in self-healing. It requires complex decisions. In fact, the problem of restoration is considered as a typical constrained nonlinear optimal problem [24] and many papers focused on only microgrid restorative stage [20, 24, 25]. Various approaches were proposed. They can be broken down into four categories: Mathematical Programming (MP) [29], Expert Systems (ESs) [28, 29], heuristic [26, 27], and soft computing [30].

Dependability: predictive diagnosis The study of predictive diagnosis is the second main issue concerning microgrids safety. Predictive diagnosis allows improving significantly the safety of physical systems in general and that of microgrids in particular. One definition for predictive diagnosis, as referenced in [31], is the following one: “predictive diagnosis is the task of foreseeing the occurrence of possible faults within the system itself before they actually occur and in a given time interval”. The knowledge of all conditions that affect the system operation, when applied from outside, is required to achieve predictive diagnosis functions. These conditions can be:

  • input variables: the predictive diagnosis system processes these variables in order to perform its functions and therefore achieve the objectives that it is designed for.

  • system settings: all system attributes, whose values can be set by the user or the operator, are considered as system settings (for example, the position of a switch).

  • environmental conditions: are the conditions related to the environment which influence the system operation (example: irradiation for PV panels).

In this context, a suitable predictive diagnosis is more effective by using state observation/estimation techniques which improves the reliability and the efficiency of electrical systems [32, 33]. To apply these techniques, it is necessary to identify the different states of the power system which establish the situation of all its components.

There are many other methods of predictive diagnosis for microgrids. They are often based on repetitions and application of various scenarios in simulations in order to predict the error before its occurrence [34].

Although this issue is extremely important, the most important issue about microgrid dependability in the scientific literature is the restoration.

3 Multi agent systems (MASs)

As explained before, the decentralized nature of microgrids promotes their control in a distributed way. On the other hand, some artificial intelligence techniques are more effective than classic techniques for the management of complex systems.

The study of MASs started around 1980 as part of the development of distributed artificial intelligence (DAI). Currently, many techniques in computer science and artificial intelligence focus on agents. In fact, agents are used in an increasingly wide variety of applications [35, 36]. MASs approach benefits several important computer applications such as process control, planning, communication networks configuration or concurrent systems [24].

MASs are systems composed of several agents which cooperate. In general, agents act to support the users and have different goals and motivations [37, 38].

3.1 Agent

An agent is defined as an autonomous entity that can be viewed as perceiving and acting upon its environment. The agent must be able to communicate with other agents. To interact successfully, agents must have the ability to cooperate, coordinate and negotiate with each other, almost as people do.

The main point of the agents is that they are autonomous; this property will be defined below.

3.2 Properties of agents

In the literature, several properties of agents have been proposed, among them we can mention:

Autonomy An agent is able to take initiatives (capacity for self-definition), to exercise control over its actions and its statements (self-control capacity), perceive changes in its environment and decide when it will act.

Reactivity An agent perceives environment where it is located and can respond to changes that occur there (acting in response to external events).

Goal-oriented is the ability of an agent to decide how to meet the assigned objective and setup an agenda. We also talk about flexibility in the sense that the actions of an agent are not entirely predetermined and defined. Indeed, it is able to choose what it will consider and in which order, depending on the external environment. Agents can receive requests from external sources, but each agent can decide to follow up or not such requests.

Pro-activity is the ability of the agent to be permanently active, without waiting to be invoked by external events. The software agent is physically a process or a particular thread within a home agent system.

Communication Software agent is able to be engaged in complex interactions with applications, services, users, resources, systems or with other agents.

Cooperation Software agent is able to establish and maintain relationships with other agents and users in order to accomplish its tasks.

Anthropomorphism Some human characteristics can be useful. For example, natural language understanding allows users to specify tasks to be performed without having to learn a particular language for the rules specification or to be familiar with a particular interface with an agent.

Mobility A mobile agent is able to move physically from one machine to another and go across different system architectures and platforms during its execution.

Learning and Adaptability The agent can be able to learn and change its behavior according to the experiment. Learning agent may also be called adaptive agent.

Self-triggering An agent can decide exactly when to trigger the appropriate action according to the external environment [37, 38].

3.3 Classification of agents

Several classifications of agents exist in the literature. According to [39], three types of agents have been distinguished in the MASs: cognitive agents, reactive agents, and hybrid agents.

Cognitive agents are agents which have a capacity of memory, reasoning and communication. They behave in a more “reflected” way, resulting from a choice among a set of possible actions. This choice is the result of reasoning.

Reactive agents are agents which have a low communication capacity. They have little or no model about themselves, about other agents or about the environment. Their behavior type is stimulus-response.

Concerning hybrid agents, they use both types of behavior: cognitive and reactive. Hybrid agents can be classified according to their degree of autonomy, cooperation and adaptation [40]. These characteristics are generally considered major in DAI [41]. Thus, four hybrid agent types can be distinguished:

Intelligent agent Combine the three characteristics (autonomy, cooperation, adaptation) to their highest level. They are able to plan their actions, to negotiate with other agents and to acquire or modify their knowledge. They generally have learning ability.

Collaborating agent are cognitive not learners agents. They have a large degree of cooperation and autonomy, but they are not adaptive. They are mainly used in areas that require decentralization such as network maintenance [42].

Information agent These agents which are used increasingly are dedicated to information retrieval, mainly on the Internet. Information agents must have considerable autonomy to be able to act alone. Also they must be able to adapt their behavior according to the needs of the user or the amount or relevance of the information.

Interface agent are also called assistants agents. They are mainly used for assisting the user in the case of interfaces with many complex features. These agents generally have a limited capacity for cooperation.

4 MASs in microgrids

The power system is sometimes considered as “one of the largest and most complex objects made by man” [43]. Microgrids are also complex systems, even if they are smaller than conventional electrical grids. They are more heterogeneous and adaptive. According to Cilliers [44], from the system and control point of view, the main characteristics of microgrids are the following:

  • The number of elements that have an impact on the microgrid behavior is large: many types of generators, loads and other types of entities and components which have their own objectives and specific modes of interactions. That’s why the behavior of the grid cannot be modeled through the classic descriptions as differential algebraic equations systems only.

  • The interaction between elements is necessary. Two types of interactions are required to maintain the equilibrium between supply and demand: direct interaction (by communication) and indirect interaction (by consuming or converting energy). However, to operate in a comprehensive manner, the system doesn’t require all elements. For example, the microgrid must be able to continue to operate when a load is disconnected, even if this disconnection makes unstable the grid temporarily.

  • Interactions are non-linear, i.e., big results can have small causes. Moreover, interactions having short range can influence the grid gravely. The consequence may extend much further. For example, a single failure as power failure in a line caused by falling trees can be the source of a blackout [45].

  • The feedback associated to interactions can be positive or negative. The single proportional- or proportional-integral are the types of feedback loops included in most of systems’ control, for example to maintain the voltage and the frequency.

  • They interact with the environment, thus they are open systems. The grid can have different changes on its structure and size. The effects of these changes influence other infrastructure such as: transport and water infrastructure. In this context, boundaries between the system and its environment are difficult to draw.

  • Several equilibrium states which are not “natural” must be maintained in the system: the balance between supply and demand is an example of these states. That’s why, to keep the system running, the system needs advanced control systems. Turn off the control systems can cause an immediate instability.

  • Power grids have a history. That is they evolve over time. This evolution does not include only the accumulation of various components, but also the improvement of their architecture, for example the adding of in anticipation of future needs. So, the past of microgrids is, at least partially, responsible for their current state.

  • The microgrid elements have a local view of the grid, and they can access limited information about other elements and the overall system behavior. Only grid operators have an aggregate view of the system macroscopic behavior.

4.1 MASs in microgrids management

Several algorithms based on artificial intelligence, such as MASs [46], are implemented in decentralized systems. Amongst these control strategies, MASs try to simplify the operation of complex systems, by dividing a large system into subsystems. These subsystems are smaller, easier to manage and coordinate with each other to achieve a common goal in a distributed way [47, 48].

The literature is rich with examples of MASs applications in the management and control of microgrids. Indeed, agents are designed to achieve several operations’ goals as supervising energy production and consumption, monitoring power quality in the system, controlling the status of other agents, detecting power flow issues, outages or voltage irregularities, carrying out tasks related to security, brokering the completion of computational tasks among resources, etc. [49].

In [5, 11, 46, 50] authors had as issue power management and control of microgrids. They used MASs applications focusing on collaboration, coordination and interaction between agents to distribute energy from resources to different loads performing market operation. Figure 2 shows the application of MASs in microgrids in general. It is important to note that physically, the agents are located nearby each microgrid element. It means that the messages exchange between the agents must be supported by a communication network.

Fig. 2
figure 2

Application of MASs in microgrid operation

In [5], authors proposed a microgrid MAS with three agent types: generator agent, consumer agent and observer agent, as shown in Fig. 3. One agent of appropriate type is associated to each element of the microgrid according to its role, except for storage systems which are associated to two agents’ type: generator agent and consumer agent. In addition, authors add an observer agent to obtain information about spot price and status for the MASs when the microgrid is interconnected with the main grid. The power management in the context of [5] primarily describes asset dispatch for static stability. Static stability, as a category, “describes the effects of gradual small changes to system parameters and focuses on the response of system assets reestablish a tolerable state of operation after such changes” [5]. At each instant, agents must control their local situation, choose the best solution taking into account agent’s goals and, if necessary, communicate their planned action to the MASs, participate in the prioritization of the MASs and adjust their actions according to the collective group decision.

Fig. 3
figure 3

MAS structure used in [5]

In [3, 6] microgrid management and control in islanded mode is studied. In [3] authors think about how to maintain the power balance between supply and demand. In the case of lack of supply, MASs perform the isolation of non critical loads in order to meet the power equilibrium. In [6] authors present scalable MASs for optimal operation of islanded microgrid. Each independent element in the microgrid is represented by an intelligent agent in the MAS.

To accomplish microgrid objectives, five types of agents have been used in the distributed MAS:

Distributed generator agent (DGAg) Controls and negotiates the power level of corresponding micro source and its status. DGAg has a data set which can be divided into:

  • Fixed data: minimum power levels, maximum power levels, unit name, coefficients of fuel cost...

  • Variable data: the status of the unit, current power production...

Load agent (LAg) Controls and negotiates the power level of corresponding load and its status. LAg is able to carry out demand side management.

Energy storage system agent (ESSAg) is the responsible of managing the storage elements in the microgrid. Its role is to provide the best schedule to storage systems such as electrolyzers/fuel cells and battery banks. ESSAg supervises requests from the microgrid manager agent and controls the state of charge (SOC) of its attached storage system.

Microgrid manager agent (MGMAg) The main functions of control and management of the microgrid are affected to the MGMAg. Indeed, it’s the agent responsible of supervising and scheduling distributed energy sources, executing demand side management techniques and storing some information such as units’ operational statuses and power settings.

Schedule coordinator agent (SCAg) In order to ensure a balance between demand and supply, it is necessary to achieve a day-ahead generation scheduling. In this case MGMAg has to activate SCAg which negotiates with DGAg and LAg in order to define the production schedule for the period.

Database agent (DAg) As its name suggests, this agent store data about available agents and their capacities.

Power world simulator agent (PWSAg) It has the task to verify the correct operation of the system compared with the simulation results [6].

On the other hand, in [14] a hierarchical hybrid control for microgrid is considered. Authors feel that “a smart control scheme for a microgrid requires not only the continuous controllers to regulate dynamic behaviors of units, but also the discrete control strategies to coordinate switching behaviors of multi-mode operations”. Thus, there is a real-time interaction and cooperation between continuous and discrete control systems. Three agents’ levels are proposed and the architectures of different hierarchical agents and their interaction are designed as follows:

  • The lower level control agent: it is a hybrid agent that is composed by two layers, one reactive and another one cognitive. The reactive layer is named as “perception and action” layer. It is responsible of responding quickly when it detects an emergency situation in the environment. Thus, the reactive layer of renewable energy resource agent is able to perceive the sudden change of resources conditions in order to determine when it must react switching the operational mode. In addition, the cognitive layer that is named as “belief, desire and intention” layer has high degree of intelligence. It is able to control or plan the behavior of agents in order to achieve some goals.

  • The middle level coordinates control agents: is designed as a cognitive agent. Its role is to coordinate the switches of operational modes in order to maintain safe voltages. The voltage safety evaluation is determined according to knowledge data and state data in order to plan coordinated control strategies. As a result, the agent can determine the reconfiguration plans of operational mode.

  • The upper level energy management agent: is also designed as a cognitive agent. It uses optimization process based on state data and knowledge data in order to plan the energy management strategies. So, it’s responsible to maintain the balance between demand and supply of power in the microgrid [14].

4.2 MASs and simulation of microgrids management

In [34], authors consider that simulation is a powerful technique for power system studies. A computer simulation of the system with Hardware-In-the-Loop (HIL) is provided. The HIL type simulation has several advantages comparing with other testing methods:

  • It provides the possibility to investigate repeatedly and thoroughly the different states of the power system in a true-to-nature condition before the actual system is built and operated.

  • It decreases the costs and the risks of dangerous situations thanks to the examination of various extreme conditions. So it increases the likelihood to identify hidden defects in the system before their impact manifests themselves in the actual operation.

The studied microgrid in [34] is a DC one. The MAS is operated as intelligent controller of the DC microgrid where the DG, the distributed storage systems, and the smart loads are presented by intelligent agents.

There are three agents in this MAS: one for the DG (DGAg), one for the distributed storage system (ESSAg) and one for the smart loads (LAg). DGAg et ESSAg are responsible to determine the output power reference using information related to each energy source (as the SOC of the battery, the rated power, the current output power...) and taking into account costs, power reserve and so on. A central coordinator cooperates with other agents to achieve the microgrid management goals. Thus, the central coordinator gathers real time data such as request for power system ancillary service, electricity price and benefits paid for the power request participation. When the central coordinator receives a request for power participation or power quality improvement, it decides if the microgrid participates in this request or not. In the case of participation, it communicates with other agents to respond to the request optimally.

Simulation, in general, and HIL simulation in particular is an effective approach to forecast microgrid operation and it allows the improvement of not only the management but also the dependability of microgrids.

4.3 Application of MAS in microgrids dependability

Application of MASs in microgrids management has increasingly demonstrated its advantages, mainly when MASs focuses microgrid dependability. It is primordial to focus microgrid safety in order to master the power system. In addition, MASs have the property of autonomy, cooperation, learning and adaptability, which accentuate the efficiency of their use in reconfiguration and diagnosis of microgrids.

Several studies have focused on the application of MASs self healing microgrid systems, because it’s a process directly related to increase the dependability in the system. Colson et al. [4] proposes a MAS architecture which study the self healing of microgrid in an emergency situation. The power system modeled in [4] is a set of microgrids interconnected and operating in cooperation. The goals of the used MAS are to minimize the reactive power flow, to keep frequency and voltage stable and to consider economic factors and synchronization concerns. Each microgrid is represented by an agent. This agent manages local generation based on the following priority hierarchy which includes both self-interest and cooperation:

  1. 1.

    Local microgrid critical load requirements.

  2. 2.

    Neighboring microgrid emergency critical load requirements.

  3. 3.

    Local microgrid non-critical load requirements.

  4. 4.

    Neighboring microgrid non-critical load requirements.

In this MAS, as written, an emergency situation is “either a failure of a microgrid resulting in its loss from the system or a faulted transmission line that results in the loss of that power flow path from the system”.

At an emergency situation (Fig. 4), upon the detection of an internal microgrid fault or a neighboring microgrid failure, the microgrid agent sends an emergency message. At the reception of that broadcast, each microgrid migrates to the autonomous state in order to reduce the power transmission on the compromised power system. Upon the placement of microgrids in a safe condition, the restoration stage starts.

Fig. 4
figure 4

Agents algorithm under emergency situation

At this point, the agent of the microgrid in fault broadcast an emergency message indicating the inability to satisfy the supply of critical loads with local production. So, each microgrid agent with available generation capacity (in excess compared to its critical load requirements) sends the quantity of excess capacity and the current list of available safe connections to the microgrid in trouble. The agent of the microgrid in fault identifies which microgrid will supply it. As written in [4] “The restorative stage is very similar to normal operation except that some microgrid nodes and connections are unavailable to the system”. Finally, when the emergency situation has disappeared, the last step of self healing begins.

Finally, the microgrid agents reestablish all broken connection with the microgrids previously in fault and include them into normal operations.

Restoration is the most important step. It improves the dependability and the safety of the system. Papers [20, 24, 25] cover the subject in greater depth. In [24], a MAS architecture is proposed for restoration. It is divided into three layers:

  • The bottom layer: is the fundamental layer. It is composed by DGAg, LAg and switch agent (SWAg), which are independent agents.

  • The middle layer: is the layer of coordination and management and is based on the MGMAg. The MGMAg coordinates the local controllers which are responsible of the optimization operation.

  • The top layer: is composed by a central control agent (CCAg), which is in charge of the market operation and technical operation in a medium and low voltage area. The MAS structure is shown in Fig. 5 and the used algorithm is shown in Fig. 6.

    Fig. 5
    figure 5

    MAS architecture for restoration purposes

    Fig. 6
    figure 6

    Restoration algorithm

The decisions made for restoration are based on messages exchange between agents. A fault situation can be marked for example by a detection of power insufficiency on behalf of LAg. Thus, the LAg sends an emergency message to its adjacent SWAg which spreads information to others SWAg and asks the restoration to the DGAg, MGMAg and CCAg. A restore order (ACCEPT/DECLINE) is sent to SWAg, which has to send (CLOSE/OPEN) signal to the switch for operation. Considering the branch maximum transmission capacity and the new switches situation, DGAg uses the measured current to compute the new available transfer capacity. It sends a restoration order if it meets the demand. Otherwise, it sends a request for support to the MGMAg. There two cases can arise: islanded mode and connected mode. In [24], authors focused only islanded mode, where MGMAg has to isolate non-critical loads. Furthermore, in connected mode MGMAg negotiates with its adjacent MGMAg and CCAg to perform a market operation [11].

While in [24] the restoration was considered as a single block of sending and receiving messages between agents, in [20, 25] it was divided into two steps: the first step is to identify an optimal configuration as a restoration target. The second step is defined as the restoration procedure. There, maintaining a certain level of security, a sequence of switching is made up in order to bring the faulted system into the target system obtained from the first step.

In [20] a MAS architecture is proposed for smart grid which does not have DG. The MAS is based on three types of agents:

  • Load agent: controls the load affected to it. It cooperates with the bus agent (BAg) as it is the responsible of the connection and the disconnection of the load in an emergency situation.

  • Facilitator agent (FAg): it is the responsible of the grids management and decisions making in the emergency situations.

  • Bus agent: it manages the coordination between FAg and LAg in order to determine an optimal structure of grid connection after a fault occurs.

5 Conclusion

The integration of the distributed generators, based essentially on renewable energies, in power systems push towards a distributed management and operation of electrical grids: the microgrids. This relevant change has prompted researches to opt for new techniques of control and management of microgrids, as distributed artificial intelligence techniques.

In this way, MASs, which proved their effectiveness in several fields, are increasingly used in microgrid operation. Indeed, MASs are specifically dedicated to distributed control of complex systems. That is why agents are designed with a strong capacity of autonomy. In addition, they have the ability to communicate, coordinate, and negotiate between themselves. Thus, MASs are effective in both management and restoration of microgrids.

In this paper, some aspects on how MASs can be designed were addressed, especially from the point of view of two functions: management and dependability.

Concerning the microgrid management, some examples of MAS architectures for energy optimization, market operation, and improvement of environmental concerns whatever the operational mode of microgrid have been exposed.

Regarding the dependability, the robustness of MAS in fault detection and islanding, reconfiguration, restoration and predictive diagnosis of microgrids has been exposed.

The MAS technique, as presented in this paper, is very promising and can be an excellent candidate for microgrid operation in the future works, especially in predictive diagnosis, which is an issue, which has to be significantly studied and developed by researches.