0% found this document useful (0 votes)
14 views20 pages

Management of An Island and Grid Connected Microgrid Using Hybr 2020 Applied

Download as pdf or txt
Download as pdf or txt
Download as pdf or txt
You are on page 1/ 20

Applied Energy 278 (2020) 115581

Contents lists available at ScienceDirect

Applied Energy
journal homepage: www.elsevier.com/locate/apenergy

Management of an island and grid-connected microgrid using hybrid


economic model predictive control with weather data
Danilo P. e Silva a ,1 , José L. Félix Salles b ,∗, Jussara F. Fardin b , Maxsuel M. Rocha Pereira c
a
Federal Institute of Education, Science and Technology of Espírito Santo, Serra, E.S., Brazil
b
Electrical Eng. Department, Federal University of Espírito Santo, Vitória, E.S., Brazil
c
Industrial Technology Department, Federal University of Espírito Santo, Vitória, E.S., Brazil

GRAPHICAL ABSTRACT

ARTICLE INFO ABSTRACT

Keywords: Microgrid management is a multi-objective problem that involves purchasing and selling energy, time-variant
Microgrid renewable generation, and maintenance costs. The microgrid can operate autonomously on an island or
Renewable energy resources through mode connected with the main grid. This paper proposes an original optimization model for the
Optimization
management of an isolated microgrid that allows the automatic grid connection to provide ancillary services to
Hybrid economic model predictive control
the main grid, such as selling the excess renewable generation and purchasing electricity to charge the battery
Energy management system
Weather data
bank. The proposed optimization is formulated via hybrid economic model predictive control using weather
forecasts performed by a mesoscale meteorological model. It includes new constraints to meet a specific
connection/disconnection regulation, such as the minimum connection/disconnection time and the maximum
connection frequency. This paper also proposes a new hybrid model of a battery bank that includes the grid
connection/ disconnection. Furthermore, the hybrid models of renewable energy sources convert weather data
to the wind and photovoltaic power by using the mixed logical dynamical framework. The proposed algorithm
is sensitive to the forecasting error, which causes variations of 1% in the met demand, 27.3% in the battery
bank costs, and 13.3% in the financial profits. Compared to multi-period mixed integer linear programming and
rule-based strategy, we show that the proposed controller manages the microgrid more safely (i.e., it provides
state of charge below its critical value during a period less than 25% of that offered by other strategies). In
locations with high energy generation, only the proposed optimization furnishes energy sale profit.

∗ Corresponding author.
E-mail address: [email protected] (J.L.F. Salles).
1
Ph.D. student in electrical engineering at Federal University of Espírito Santo.

https://doi.org/10.1016/j.apenergy.2020.115581
Received 9 January 2020; Received in revised form 4 July 2020; Accepted 20 July 2020
Available online 5 August 2020
0306-2619/© 2020 Elsevier Ltd. All rights reserved.
D.P. e Silva et al. Applied Energy 278 (2020) 115581

1. Introduction grid connection/disconnection of MG was not taken into account. In


locations where the consumer unit has a high probability of main grid
Technologies based on renewable energy sources (RES) such as interruptions due to poor quality of service [33], it is convenient and
wind turbines, photovoltaic panels (PV), and fuel cells have become viable that an MG stay in isolated mode. Moreover, it must have the
essential for meeting the growing demand for sustainable energy and autonomy of eventually connecting to the grid and offering ancillary
the world’s economic development. Renewable energies accounted for services such as voltage regulation, reduction of peak demand, and
the highest share in primary energy production in the European Union harmonic filtering. During the grid connection, the MG can sell the
in 2018 (28.4%) [1]. From the total renewable energy produced, 57% excess renewable energy generation to the main grid to avoid energy
corresponded to photovoltaic and wind power generation. In 2019, waste in the dump load [34] when the battery is charged.
the United States produced 4.18 trillion kilowatt hours of electricity, The weather data forecasting is important information for micro-
and the RES generation corresponded to 19% of the total energy grid management because it determines the power generated from
produced [2]. The RES generation in China increased 6% in 2019 when RES [29] and the thermal and electrical loads that can be fed by
compared to 2018 [3]. In Brazil, 9.9% of electricity generation-installed the microgrid [35–37]. The association of feedback control strategies
capacity (162.8 GW) in 2018 corresponds to the wind and photovoltaic and forecasting techniques in the decision variables of the economic
generation [4]. This growth in renewable energy use around the world dispatch problem are reasons for the success of MPC in microgrid man-
has increased the uncertainties concerning the electric power systems agement. However, some studies that used MPC [13] ignored weather
due to the intermittent renewable power generation. In this scenario, data, and the solutions obtained reflect ideal representations of the
a microgrid (MG) is a promising approach [5,6] because of its ability MG operating conditions. They did not address possible contingencies
to operate with bidirectional power flow as well as independently or derived from the operation under real scenarios of meteorological
connected to the main grid. A typical MG is composed of electric events. Some articles that used MPC commented on the need to perform
charges, an energy storage system (ESS), RES, and fossil fuel power forecasts, but left in the background the information about the weather
generation. forecasting techniques and the impact of the forecasting errors on
The complete formulation of the optimal operation problem of MG the results obtained [15,35,37]. Instead of using meteorological data,
requires mathematical models related to the energy storage system, other works preferred to deal only with historical power data to obtain
power exchange with the main grid, data forecasting, and demand- renewable energy generation [30,32,38–41].
side management policies [7]. Several mathematical models developed It is challenging to forecast renewable power using only historical
for MG have been presented in the literature for real-time operation, power data because of the shading effect on the photovoltaic panels.
demand-side management [8], and optimization. The authors in [9] for- However, we can achieve better power forecasting results by perform-
mulate a stochastic correlation model between generation and demand ing irradiance forecasts through techniques that detect sunny days,
of different MGs, and the work [10] proposed a support decision- cloudy days, and rainy days [42]. Another challenging issue is the effect
making framework for investments in distributed generation of three of the wind power saturation when the wind speed frequently leaves
different MGs. The authors in [10] use the mixed integer programming the range between the cut-in and cut-off speed values (minimum and
(MILP) formulation to determine the minimal cost capacity and opera- maximum), inflicting a strong nonlinearity on the wind power time se-
tion of the distributed energy resources in a microgrid. The work [11] ries. Therefore, power forecasting models require nonlinear forecasting
proposed a real-time simulator for MG monitoring, and the paper [12] techniques, such as those based on the support vector machine [43].
considered smart electrical loads in the MG mathematical formulation. Thus, nonlinear models have their own characteristics that depend on
Finally, the authors [13–15] used the mixed logic dynamic (MLD) [16] a specific renewable energy generator already installed in an MG.
framework for MG modeling. Conversely, the use of weather data to forecast renewable energy
The economic dispatch problem for MG aims to perform fast op- generation and electrical and thermal demands can detect weather
erational decisions along a planning horizon of a few minutes to 1 h disturbances such as sudden changes in temperature, irradiance, and
ahead to minimize energy and operational and maintenance (O&M) humidity, which can affect microgrid management. Moreover, it is
costs and maximize energy sales to the main grid [5]. The decisions possible to use mesoscale meteorological models, such as the weather
taken in this optimization problem are the amount of power that each research and forecasting (WRF) model [44], for the generation of
RES should provide to meet the loads, the amount of energy that dynamic and thermodynamic data from the atmosphere. The advantage
should be purchased or sold to the main grid, and when the MG should of this forecasting method is that it does not depend on the implemen-
disconnect from the main grid. Several optimization techniques have tation of the physical installation of surface meteorological stations.
been proposed in order to solve the economic dispatch problem for In this case, the WRF model allows us to carry out feasibility studies
MG in the last 5 years, including the following: genetic algorithm [17, of the technique applied in any location, based on the geographic
18], evolutionary algorithms [19], exchange market algorithm [20], coordinates of the current place, or the future installation of an MG.
differential evolution algorithm [21] and particle swarm optimiza- However, the simple application and indiscriminate use of numerical
tion algorithms [22,23], mixed-integer programming [24–26], rolling models can produce results far from the reality if the calibration of the
horizon, [27–29], and model-based predictive control (MPC) [30]. WRF model and the representation of the physical processes operating
Other works on the economic dispatch problem analyzed MGs oper- in the region are not correct. To avoid these deficiencies, the WRF
ating on grid-connected and grid-disconnected modes. However, they model must be adjusted correctly. For this, current research exists on
did not consider the autonomy of the management system to decide the gathering of knowledge and critical analysis of the simulations
when to switch between these two operational modes. The paper [31] obtained by this forecasting model. However, the use of meteorological
used the multi-objective genetic algorithm for the optimal manage- data using mesoscale models is subject to significant errors compared
ment of a battery system with photovoltaic panels under programmed to the power forecast using models based on historical power data.
grid-disconnection when predictable blackouts occur in the main grid. Considering the literature studied, we observed few articles that
However, it would be ideal if an MG had the autonomy to detect apply MPC in MG management and perform forecasts of weather data
the main grid failures before the blackout occurrence and carried out to obtain renewable energy generation. The article [14] manages an
the disconnections automatically. In [32], the authors presented the MG connected to the main grid through the hybrid MPC (HMPC)
affine arithmetic MPC-based approach of combined heat and power controller. These authors used neural networks in conjunction with
microgrid that considers both connected and isolated operation modes. autoregressive integrated moving average models to perform forecasts
The MG operational performance is analyzed separately in these two on irradiance, temperature, wind speed, humidity, and wind direction.
scenarios (disconnected or connected modes). However, the automatic Although this article presents the MLD model of the energy storage

2
D.P. e Silva et al. Applied Energy 278 (2020) 115581

system in detail, it does not describe the solar and wind energy models 3. The photovoltaic hybrid model uses the MLD structure with
for converting weather data into power. Moreover, the HMPC cannot weather data such as irradiance and temperature.
perform the connection /disconnection of MG with the main grid. 4. The photovoltaic and wind power forecasts obtained from the
In [29], the authors considered the uncertainty in the wind speed global WRF forecasting model of meteorological data.
forecast using the max–min method [42] and formulated the MILP 5. The detailed modeling of the wind turbine obtained through the
optimization problem combined with the rolling horizon and stochastic discrete hybrid automata approach.
programming. However, these authors modeled only wind generation
using weather data and considered an MG always connected to the The proposed management algorithm assumes that the MG has
main grid. The paper [35] presented the temperature control of a room decision-making autonomy to perform connections to the main grid,
through HMPC using data of irradiance and external temperature in the offering and receiving services from the utility, such as battery bank
MG installation locality. These authors used stochastic programming charging. Besides, it belongs to the secondary control level of hierarchi-
cal control structure presented in [53]. This control level is responsible
to model the irradiance forecast to obtain solar power. However, they
for the reliability, safety, and economic operation of MGs in both
presented only the solar power model using irradiance data and did
connected and isolated modes through the energy management system
not formulate the HMPC to manage the connection and disconnection
(EMS). The EMS is a centralized control structure that optimizes an
of an MG with the main grid. In [45], the authors used the stochastic
MG’s economic dispatch according to ESS information, RES forecast,
MILP optimization and the rolling horizon algorithm to manage an
electric power loads, and electricity prices [54].
isolated MG. They performed wind speed and irradiance forecasts from
The remainder of this article is organized as follows: Section 2
the WRF system combined with statistical methods, using the persistent
presents the hybrid modeling of PV, wind turbine, and battery bank by
techniques and clear-sky index for irradiance [46]. Besides, they also
considering weather data. Section 3 formulates the cost function and
determined the solar and wind power forecasting models of solar and
constraints of the optimization problem to include the connection and
wind power but did not manage the connection/disconnection of an
disconnection operations of an MG with the main grid. We also present
MG with the main grid. in Section 3 the HEMPC algorithm. Section 4 shows the study of cases
This paper aims to fill the gap in the literature concerning the from computational simulations using real weather data from different
MG management using MPC with weather data forecasted by the WRF meteorological characteristics. It analyzes the computational perfor-
model, considering the grid connection and disconnection. We propose mance and forecasting error sensibility of the algorithm. Moreover,
the MG economical dispatch algorithm through the hybrid economic it compares the proposed algorithm with the rule-based strategy and
model predictive control (HEMPC) approach that uses weather data. the MILP multi-period optimization. Finally, we conclude this paper in
The optimization model allows an MG to operate in the island mode Section 5.
and eventually in the grid-connected mode to offer energy sale ser-
vices to the main grid when there is a surplus of renewable energy. 2. Microgrid modeling
The proposed optimization algorithm includes constraints on meeting
a specific MG connection and disconnection regulation, such as the In this section, we present each MG equipment model through DHA.
minimum connection/disconnection time and the maximum connection DHA is composed of four components: switch affine system (SAS), event
frequency. This paper also proposes a new hybrid model of a battery generator (EG), finite state machine (FSM), and mode selector (MS).
bank that takes into account the connection and disconnection of The EG extracts and generates logical signals from the SAS. These
an MG with the main grid. In grid-connection mode, the main grid external logics enable the transition of FSM states. A MS processes
charges the battery bank, viewing it as a load. Finally, the hybrid ESS all logic signals in order to choose new continuous SAS dynamics.
model proposed here has improvements in the switching logic and the The parameters of proposed DHA models depend on the weather data
continuous dynamics compared to the model proposed in [47]. measured at each time 𝑘𝑇s , where 𝑇s is the sample time. For notation
Another original contribution is the PV panel hybrid modeling based simplification, we omitted 𝑇s in all equations presented here. The
on the equivalent circuit equation [48]. Some PV panel models found proposed MG model makes the following assumptions:
in the literature calculate the power through theoretical equations
1. The existence of the following MG equipment: solar panels, wind
based on the PV panel area [49], irradiance, temperature, wind speed,
turbine, ESS having a battery bank, electric charges, and weather
latitude, and longitude [50]. However, these works do not consider
data acquisition through a local meteorological station.
PV power saturation. The advantage of hybrid models over theoretical
2. The secondary level of the hierarchical control structure is not
power-supply equations is that they can convert some types of nonlin-
affected by the transient behaviors of the primary level dynam-
earities into logical propositions, which may include constraints and
ics.
continuous and binary variables. The paper in [51] proposed a wind
3. The connection and disconnection duration times of an MG to
turbine MLD model, and it used the HMPC strategy to improve the wind
the main grid are a few seconds, and they do not interfere in the
turbine performance. However, these authors did not present the wind
second control system level, which is updated in minutes.
turbine modeling in detail, as we have presented here. Other hybrid
4. The connection and disconnection operations of an MG to the
models proposed in this paper, such as electrical loads and purchasing
main grid do not affect its stability.
and selling electrical energy, were based on previous works [13,15,41].
5. All MG disconnections from the main grid are intentional (i.e.,
However, these articles lacked details about the discrete hybrid au-
there are not disconnections due to failures).
tomata (DHA) approach [52]. DHA is a dynamic system that describes
6. The pitch and frequency control of the wind generator track its
the temporal evolution of the set of logic (or discrete) and real (or
maximum power.
continuous) variables.
7. The charging and discharging efficiencies of the battery bank are
The main original contributions of this article can be summarized
assumed constant.
as follows:

1. The objective function considers the connected and isolated 2.1. Photovoltaic generation
modes of the MG operation with the main grid to provide
The equivalent circuit of the photovoltaic array [48] is represented
ancillary services, to purchase or sell energy, and to avoid energy
by
waste in the dump load.
𝑞𝐴 𝑉 (𝑘)
2. The minimum time interval for MG to stay grid connected and 𝐼sc
𝐼(𝑘) = 𝐼sc ⋅ 𝜆(𝑘) − 𝑞𝐴
⋅ [𝑒 n𝑘B 𝑇 (𝑘) ⋅ 𝑒 𝑉oc − 1] (1)
the maximum number of grid connections over a time interval. n𝑘B 𝑇 (𝑘)
𝑒

3
D.P. e Silva et al. Applied Energy 278 (2020) 115581

This equation depends on the irradiance variation 𝜆(𝑘), the ambient


temperature 𝑇 (𝑘), the open-circuit voltage 𝑉oc , the short circuit current
𝐼sc , the ideality factor 𝐴, Boltzmann constant 𝑘B , the elementary charge
of the electron 𝑞, and the number of cells of the photovoltaic module
n. We used the maximum power point tracking algorithm (MPPT) to
calculate the maximum power (𝑃MPPT (𝑘)) at each instant 𝑘 = 0, 1, 2, …
according to the following steps:

1. Read the measured irradiance and temperature (𝜆(𝑘), 𝑇 (𝑘)) at the


current instant 𝑘.
2. Vary the PV voltage at instant 𝑘 (𝑉 (𝑘)) from 0 to 𝑉oc and
calculate from Eq. (1) the power curve versus voltage through
the relation 𝑃pv (𝑘) = 𝑉 (𝑘)𝐼(𝑘).
3. Interpolate the power curve versus PV voltage through a polyno-
mial of order 𝑛, shown in (2), that relates the power generated
in the panel (𝑃pv (𝑘)) with the applied PV voltage.
4. Calculate from Eq. (2) the maximum power at instant 𝑘
(𝑃MPPT (𝑘)).
Fig. 1. The pitch-controlled wind turbine curve.
𝑃pv (𝑘) = 𝑑n (𝑘)𝑉 𝑛 (𝑘) + 𝑑n-1 (𝑘)𝑉 𝑛−1 (𝑘) + ⋯ + 𝑑1 (𝑘)𝑉 (𝑘) + 𝑑0 (𝑘)
(2)
provided by [51], which linearized the maximum power point tracking
where 𝑑0 , 𝑑1 , … , 𝑑n are parameters that depend on irradiance region in four operational points.
and temperature.
The proposed wind generation DHA model has the finite state
The photovoltaic panel DHA model is represented by the logical machine (FSM) defined by (7). This FSM evolves through discrete
sentences (3), (4), and (5). The selector mode, given by (3), selects events between operational states: idle (𝑥wb1 ), MPPT (𝑥wb2 ), nominal
SAS dynamics defined by (4) according to the event generator binary (𝑥wb3 ), and cut-off (𝑥wb4 ). The event generator shown in (8) and the
variable 𝛿pv1 (𝑘) given by (5). If the calculated power (𝑃pv (𝑘)) is greater
binary variable 𝑜𝑝 indicate that the wind generator is operating below
than the PV nominal power (𝛿pv1 (𝑘) = 1) for a given irradiance and
temperature, then the power saturates at value 𝑃pvsat . The switching its rated power, and 𝑝𝑛 indicates that the generator is operating at its
affine system represented by (4) changes the maximum generation rated power. Each state generated by FSM can be accessed by all other
power between the dynamics described in (2) and the saturation of the states, depending on the transition event.
nominal power, according to the mode selector.
{ The selection rules between the dynamics in (10) are defined by the
1 if ¬𝛿pv1 (𝑘) mode selector in (9). For example, if the wind turbine is in an idle state
𝑀𝑆 ∶ 𝑚pv (𝑘) = (3)
2 if 𝛿pv1 (𝑘) (𝑥wb1 ), then 𝑚w (𝑘) = 1 and consequently 𝑥w (𝑘 + 1) = 0 in SAS. If only
{
𝒙pv (𝑘 + 1) = 𝑃pv (𝑘) if 𝑚pv (𝑘) = 1 event 𝛿w1 is disabled (𝑣(𝑘) ≥ 𝑣cutin ), the turbine FSM changes from the
𝑆𝐴𝑆 ∶ (4) idle state (𝑥wb1 ) to the MPPT state (𝑥wb2 ) and the MS makes 𝑚w (𝑘) = 2
𝒙pv (𝑘 + 1) = 𝑃pvsat if 𝑚pv (𝑘) = 2
{ and selects 𝑥w (𝑘 + 1) = 𝑃w (𝑘) on SAS.
𝐸𝐺 ∶ [𝛿pv1 (𝑘) = 1] ↔ [𝑃pv (𝑘) ≥ 𝑃pvsat ] (5)

⎪𝑥wb1 if (𝑥wb1 ∧ 𝛿w1 ) ∨ (𝑥wb2 ∧ 𝛿w1 )
2.2. Wind generation ⎪
⎪ ∨(𝑥wb3 ∧ 𝛿w1 ) ∨ ( 𝑥wb4 ∧ 𝛿w1 )
⎪𝑥wb2 if (𝑥wb1 ∧ 𝑜𝑝) ∨ (𝑥wb2 ∧ 𝑜𝑝)
The energy conversion system of a wind turbine is characterized ⎪
by a power curve provided by the manufacturer that relates the wind ⎪ ∨(𝑥wb3 ∧ 𝑜𝑝) ∨ ( 𝑥wb4 ∧ 𝑜𝑝)
𝐹 𝑆𝑀 ∶ 𝑥wb =⎨ (7)
power (𝑃w (𝑘)) and the wind speed (𝑣(𝑘)) on the turbine. On a pitch- ⎪𝑥wb3 if (𝑥wb1 ∧ 𝑝𝑛) ∨ (𝑥wb2 ∧ 𝑝𝑛)
controlled wind turbine, the ratio between wind power 𝑃w (𝑘) and its ⎪ ∨ (𝑥wb3 ∧ 𝑝𝑛) ∨ ( 𝑥wb4 ∧ 𝑝𝑛)
nominal power 𝑃wn has four logic states defined by four operational ⎪
⎪𝑥wb4 if (𝑥wb1 ∧ 𝛿w3 ) ∨ (𝑥wb2 ∧ 𝛿w3 )
regions (see Fig. 1): ⎪
⎪ ∨ (𝑥wb3 ∧ 𝛿w3 ) ∨ ( 𝑥wb4 ∧ 𝛿w3 )

• No generation (idle state) for speeds lower than 𝑣cutin .
• Maximum power point tracking (MPPT) state for speeds ranging
from 𝑣cutin to nominal speed 𝑣n . ⎧[𝛿 = 1] ↔ [𝑣 ≤ 𝑣
⎪ w1 cutin ]
• Nominal state where the wind turbine reaches its rated power for
⎪[𝛿w2 = 1] ↔ [𝑣 ≥ 𝑣n ]
speeds greater than 𝑣n . ⎪
• Cut-off state when the wind speed exceeds 𝑣cutoff and the turbine 𝐸𝐺 ∶ ⎨[𝛿w3 = 1] ↔ [𝑣 ≥ 𝑣cutoff ] (8)

stops, or it operates at shallow speed with generate power equal ⎪[𝑜𝑝 = ¬𝛿w1 ∧ ¬𝛿w2 ] ↔ [𝑣 > 𝑣cutin ∧ 𝑣 < 𝑣n ]
to 𝑃cutoff . ⎪[𝑝𝑛 = 𝛿
⎩ w2 ∧ ¬𝛿w3 ] ↔ [𝑣 ≥ 𝑣n ∧ 𝑣 < 𝑣cutoff ]

Through the points extracted in the MPPT region of Fig. 1, we


determined the wind power from a polynomial interpolation given by
⎧1 if 𝑥wb1 (𝑘)

𝑃w (𝑘) = 𝑎n 𝑣𝑛 (𝑘) + 𝑎n-1 𝑣𝑛−1 (𝑘) + ⋯ + 𝑎1 𝑣(𝑘) + 𝑎0 (6) ⎪2 if 𝑥wb2 (𝑘)
𝑀𝑆 ∶ 𝑚w (𝑘) = ⎨ (9)
where 𝑎0 … 𝑎n are polynomial constants. The wind power provided by ⎪3 if 𝑥wb3 (𝑘)
the polynomial (6) is closer to the manufacturer’s data than the one ⎪4 if 𝑥wb4 (𝑘)

4
D.P. e Silva et al. Applied Energy 278 (2020) 115581

⎧𝑥 (𝑘 + 1) = 0 if 𝑚w (𝑘) = 1 ⎧1 if 𝑔l1 (𝑐1 , 𝑐2 , … , 𝑐n ) = 0 ⋯ 01


⎪ w ⎪
⎪𝑥 (𝑘 + 1) = 𝑃w (𝑘) if 𝑚w (𝑘) = 2 ⎪2 if 𝑔l2 (𝑐1 , 𝑐2 , … , 𝑐n ) = 0 ⋯ 10
𝑆𝐴𝑆 ∶ ⎨ w (10) ⎪
⎪𝑥w (𝑘 + 1) = 𝑃wn if 𝑚w (𝑘) = 3 𝑀𝑆 ∶ 𝑚l (𝑘) = ⎨3 if 𝑔l3 (𝑐1 , 𝑐2 , … , 𝑐n ) = 0 ⋯ 11 (18)
⎪𝑥 (𝑘 + 1) = 𝑃 if 𝑚w (𝑘) = 4 ⎪
⎩ w cutoff ⎪⋮
⎪𝜚 if 𝑔l𝜚 (𝑐1 , 𝑐2 , … , 𝑐n ) = 1 ⋯ 11

2.3. ESS - Battery bank


The DHA model of battery bank represents different dynamics ac- ⎪0 if 𝑚l (𝑘) = 1
cording to the MG operational modes: isolated or connected to the ⎪𝐷 if 𝑚l (𝑘) = 2
𝑆𝐴𝑆 ∶ 𝐷c (𝑘) = ⎨ 2 (19)
main grid. In the logical equations presented in (11), when the state ⎪⋮
of charge (SOC) 𝑆(𝑘) reaches its maximum value, the battery bank will ⎪𝐷𝜚 if 𝑚l (𝑘) = 𝜚

be charged and 𝛿s1 (𝑘) = 1. Otherwise, the batteries have not reached
their maximum SOC. The event 𝛿s2 (𝑘) = 1 occurs when the MG is where 𝜚 = 2𝑛c e 𝑔l (.) is a function that represents a binary number
connected to the main grid, and the battery bank is not charged. The with 𝑛c bits such that 𝑔l (𝑐1 , 𝑐2 , … , 𝑐nc ) = 𝑐nc ⋯ 𝑐2 𝑐1 . The total controlled
mode selector defined by (12) chooses the SAS dynamics represented demand is the sum of all turned on loads, which is represented by
𝑛c
by (13) according to the variable 𝑢g (𝑘) defined in (14). ∑
{ 𝐷c (𝑘) = 𝑐h (𝑘)𝐷h (𝑘) (20)
[𝛿s1 (𝑘) = 1] ↔ [𝑆(𝑘) ≥ 𝑆max ] ℎ=1
𝐸𝐺 ∶ (11)
[𝛿s2 (𝑘) = 1] ↔ [𝑢g (𝑘) ∨ ¬𝛿s1 (𝑘)] For example, if we have two controllable loads with demands 𝐷1 and
𝐷2 , the SAS in (19)
{ will have four dynamics
} and the possible values of
{ loads are 𝐷c = 0, 𝐷1 , 𝐷2 , 𝐷1 + 𝐷2 . Usually, an MG also has critical
1 if ¬𝑢g (𝑘)
𝑀𝑆 ∶ 𝑚s (𝑘) = (12) loads (i.e., loads that are non-controllable and always remain turned
2 if 𝑢g (𝑘) on). The total demand of the electric load, including the critical loads,
are defined by
⎧ 𝜂𝑇s
⎪𝑆(𝑘 + 1) = 𝑆(𝑘) − 𝐶max
⋅ 𝑖1 (𝑘) − 𝑥𝑠b if 𝑚s (𝑘) = 1 𝑛c
∑ 𝑛𝑙

𝑆𝐴𝑆 ∶ ⎨ (13) 𝐷L (𝑘) = 𝑐h (𝑘)𝐷h (𝑘) + 𝐷i (𝑘) (21)
𝜂𝑇s
⎪𝑆(𝑘 + 1) = 𝑆(𝑘) + ⋅ 𝑖2 (𝑘) − 𝑥𝑠b if 𝑚s (𝑘) = 2 ℎ=1 𝑖=1
⎩ 𝐶max
where 𝑛𝑙 is the number of critical loads and 𝐷i is the 𝑖th critical load.
{
1 if MG is grid-connected
𝑢g (𝑘) = (14) 2.5. Electricity price
0 if MG is isolated
In the logical equation system (13), 𝑥𝑠b represents the self-discharge An MG can purchase or sell electrical power at prices 𝑐p (𝑘) and
current of battery bank, 𝑖1 (𝑘) refers to the charge/discharge current 𝑐s (𝑘) respectively, when it is connected to the grid. The DHA model
when the MG is isolated, 𝑖2 (𝑘) is the charge current of the battery bank of electricity price used in this paper was proposed in [13]. The
when the MG is grid-connected. 𝑖1 (𝑘) is determined from Eq. (15a) expressions (22), (23), and (24) describe this model:
(i.e., it is equal the load current 𝑖L (𝑘) minus the PV 𝑖pv (𝑘) and wind {
𝐸𝐺 ∶ [𝛿g (𝑘) = 1] ↔ [𝑃g (𝑘) ≥ 0] (22)
generator 𝑖w (𝑘) currents). The battery bank is charged when 𝑖1 (𝑘) is
negative; otherwise, the battery bank is discharged. 𝑖2 (𝑘) is the charger
current supplied to the battery bank when the MG is connected. If {
1 if ¬𝛿g (𝑘)
𝛿s2 (𝑘) = 1 in (11), then the battery bank is charged. In this case, the 𝑀𝑆 ∶ 𝑚p (𝑘) = (23)
2 if 𝛿g (𝑘)
charger stops supplying power to the battery bank (i.e., 𝑖2 (𝑘) = 0).
{
𝑐s (𝑘)𝑃g (𝑘) if 𝑚p (𝑘) = 1
𝑆𝐴𝑆 ∶ 𝐶g (𝑘) = (24)
𝑖1 (𝑘) = 𝑖L (𝑘) − 𝑖pv (𝑘) − 𝑖w (𝑘) if ¬𝑢g (𝑘) (15a) 𝑐p (𝑘)𝑃g (𝑘) if 𝑚p (𝑘) = 2
𝑖2 (𝑘) = 𝑖ch (𝑘)𝛿s2 (𝑘) if 𝑢g (𝑘) (15b) where 𝐶g (𝑘) is the cost of energy and 𝑃g (𝑘) is the instantaneous power
balance of the connected MG, defined in (25).
Therefore, when the MG is connected to the grid, the battery bank
charger is a load for the main grid, which the demand is given by 2.6. Power balance
𝐷ch (𝑘) = 𝛿s2 (𝑘) ⋅ 𝐷c2 (𝑘) (16)
The power balance defined in (25) represents the difference be-
where 𝐷c2 (𝑘) = 𝑖ch (𝑘) × 𝑉b and 𝑉b is the battery bank voltage. tween consumption and generation of energy, (i.e., it is the sum of all
load demands of the MG, including the battery bank charger, minus the
2.4. Electrical loads sum of PV and wind power generations).
𝑃g (𝑘) = 𝐷L (𝑘) + 𝐷ch (𝑘) − 𝑃w (𝑘) − 𝑃pv (𝑘)
We consider that there is a total of 𝑛c controllable electrical loads
𝑛𝑙 𝑛c
through contactors. Each contactor is represented by a binary variable ∑ ∑ (25)
= 𝐷i (𝑘) + 𝑐h (𝑘)𝐷h + 𝛿s2 (𝑘)𝐷c2 (𝑘) − 𝑃w (𝑘) − 𝑃pv (𝑘)
𝑐h , ℎ = 1, … , 𝑛c . Each load 𝐿h has a power demand 𝐷h . The control- 𝑖=1 ℎ=1
lable loads DHA can be represented by the expressions in (17), (18),
The second equality in the above expression separates the control-
and (19):
lable loads from the critical loads. The power balance depends on the
⎧[𝑐 (𝑘) = 1] ↔ [𝐿 = 𝐷 ] operational policy of the MG, as explained as follow:
1 1
⎪ 1
⎪[𝑐2 (𝑘) = 1] ↔ [𝐿2 = 𝐷2 ] • If the power balance 𝑃g (𝑘) has a negative sign, then generation is
𝐸𝐺 ∶ ⎨ (17)
⎪ ⋮ larger than consumption; otherwise, consumption is larger than
⎪[𝑐 (𝑘) = 1] ↔ [𝐿 = 𝐷 ] generation.
⎩ nc nc nc

5
D.P. e Silva et al. Applied Energy 278 (2020) 115581

• If the MG is isolated, 𝑃g (𝑘) is the charge or discharge power of The MG cannot be disconnected from the grid while the binary state
the battery bank. ℎ𝑜𝑙𝑑𝑜𝑛(𝑘) is enabled (i.e., while 𝜉hon (𝑘) is counting); thus, we have
• If the MG is connected to the grid, 𝑃g (𝑘) is the power exchanged
𝑢g (𝑘) = 1 if ℎ𝑜𝑙𝑑𝑜𝑛(𝑘) = 1 (34)
with the main grid.
and analogously, the Boolean relation in (35) describes that an MG
2.7. Connection and disconnection conditions cannot be connected to the grid while 𝜉hoff (𝑘) is enabled.

𝑢g (𝑘) = 0 if ℎ𝑜𝑙𝑑𝑜𝑓𝑓 (𝑘) = 1 (35)


We assumed that the power utility allows the connection and dis-
connection of the MG to the main grid during the minimum time We also assumed that the power utility has a maximum number
intervals 𝜏c and 𝜏𝑖 , respectively. The following expressions determine (𝑛𝑐max ) of MG connections with the main grid during any time interval
these time intervals: [𝑖𝑇c , (𝑖 + 1)𝑇c ], 𝑖 = 0, 1, 2, where 𝑇c is a time period specified by the
power distribution company. These intervals have the sampling period
𝜏c = min(𝑇up , 𝑁)𝑇s (26) 𝑇s , so the maximum number of samples in each of these intervals is
𝑛𝑠max = 𝑇c ∕𝑇s . The time interval from 𝑖𝑇c to 𝑘𝑇s ∈ [𝑖𝑇c , (𝑖 + 1)𝑇c ] is
𝜏i = min(𝑇down , 𝑁)𝑇s (27)
indicated by the real variable 𝜉s (𝑘) ∈ [0, 𝑇c ]. Let 𝛿𝜉 (𝑘) be the binary
where 𝑇up and 𝑇down are the minimum numbers of samples required for variable, which always resets 𝜉s (𝑘) according to the following logical
the MG to remain grid connected and isolated, respectively; 𝑇s is the and dynamical system:
{
sample time; and 𝑁 is the forecasting horizon. 𝜉s (𝑘 + 1) = 𝜉s (𝑘) + 𝑇s if 𝑚c (𝑘) = 1
Let us denote by 𝜉hon (𝑘) and 𝜉hoff (𝑘) the variables that count the 𝑆𝐴𝑆 ∶ (36)
𝜉s (𝑘 + 1) = 0 if 𝑚c (𝑘) = 2
number of samples remaining that are necessary to enable the con- {
nection or disconnection of an MG from the current sample. The last 1 if ¬𝛿𝜉
𝑀𝑆 ∶ 𝑚c (𝑘) = (37)
connection and disconnection of an MG occurs at samples 𝑘c and 𝑘i , 2 if 𝛿𝜉
respectively. These counters satisfy the following equations:
Let us denote by 𝜉c (𝑘) the number of MG connections to the main
𝜏
𝜉hon (𝑘 + 1) = 𝜉hon (𝑘) − 1, for 𝑘 ≥ 𝑘c and 𝜉hon (𝑘c ) = c (28) grid from instant 𝑡 = 𝑖𝑇c to instant 𝑡 = 𝑘𝑇s ∈ [𝑖𝑇c , (𝑖 + 1)𝑇c ]. The
𝑇s transition from the isolated mode to the connected mode at time 𝑡 = 𝑘𝑇s
𝜏i is detected by the binary variable 𝛿c (𝑘) and the maximum number of
𝜉hoff (𝑘 + 1) = 𝜉hoff (𝑘) − 1, for 𝑘 ≥ 𝑘i and 𝜉hon (𝑘i ) = (29)
𝑇s connections within each time interval [𝑖𝑇c , (𝑖 + 1)𝑇c ] is indicated by
To guarantee positive values for these counters, we defined the binary the binary variable 𝛿cmax (𝑘). From these definitions we determined the
variables 𝛿hon (𝑘) and 𝛿hoff (𝑘) by the following expressions: logical and dynamical system:
{
[𝛿hon (𝑘) = 1] ↔ [𝜉hon (𝑘) ≥ 0] ⎧[𝛿c (𝑘) = 1] ↔ [𝑢g (𝑘) ∧ ¬𝑢g (𝑘 − 1)]
𝐸𝐺 ∶ (30) ⎪
[𝛿hoff (𝑘) = 1] ↔ [𝜉hoff (𝑘) ≥ 0] 𝐸𝐺 ∶ ⎨[𝛿cmax (𝑘) = 1] ↔ [𝜉c (𝑘) > 𝑛𝑐max ] (38)

⎩[𝛿𝜉 (𝑘) = 1] ↔ [𝜉s (𝑘) > 𝑇c ]
Let us define the binary states ℎ𝑜𝑙𝑑𝑜𝑛(𝑘) and ℎ𝑜𝑙𝑑𝑜𝑓𝑓 (𝑘) that indicate
which counter 𝜉hon (𝑘) and 𝜉hoff (𝑘) are enabled, respectively. These
⎧𝜉c (𝑘 + 1) = 𝜉c (𝑘) + 1 if 𝑚count (𝑘) = 1
states satisfy the FSM (31), which detects the MG connection and dis- ⎪
connection times and checks whether 𝛿hon (𝑘) and 𝛿hoff (𝑘) are enabled. 𝑆𝐴𝑆 ∶ ⎨𝜉c (𝑘 + 1) = 𝜉c (𝑘) if 𝑚count (𝑘) = 2 (39)

⎩𝜉c (𝑘 + 1) = 0 if 𝑚count (𝑘) = 3
𝐹 𝑆𝑀 ∶
{
ℎ𝑜𝑙𝑑𝑜𝑛(𝑘 + 1) = ((𝑢g (𝑘) ∧ ¬𝑢g (𝑘 − 1)) ∨ ℎ𝑜𝑙𝑑𝑜𝑛(𝑘)) ∧ 𝛿hon (𝑘) ⎧1 if 𝛿c (𝑘) ∧ ¬𝛿𝜉 (𝑘)
ℎ𝑜𝑙𝑑𝑜𝑓𝑓 (𝑘 + 1) = ((¬𝑢g (𝑘) ∧ 𝑢g (𝑘 − 1)) ∨ ℎ𝑜𝑙𝑑𝑜𝑓𝑓 (𝑘)) ∧ 𝛿hoff (𝑘) ⎪
𝑀𝑆 ∶ 𝑚count (𝑘) = ⎨2 if ¬𝛿c (𝑘) ∧ ¬𝛿𝜉 (𝑘) (40)
(31) ⎪
⎩3 if 𝛿𝜉 (𝑘)
When the binary states ℎ𝑜𝑙𝑑𝑜𝑛(𝑘) and ℎ𝑜𝑙𝑑𝑜𝑓𝑓 (𝑘) are disabled, the We guarantee that an MG cannot be connected to the grid if 𝜉c (𝑘)
counters 𝜉hon (𝑘) and 𝜉hoff (𝑘) are reset through the MS in (32) and the exceeds the maximum number of connections (𝑛𝑐max )). Therefore,
SAS in (33).
𝑢g (𝑘) = 0 if 𝛿cmax (𝑘) = 1 (41)
⎧1 if ℎ𝑜𝑙𝑑𝑜𝑛(𝑘)
⎪ When the timer 𝜉s (𝑘) reaches its maximum time period (𝑇c ), the vari-
⎪2 if ¬ℎ𝑜𝑙𝑑𝑜𝑛(𝑘)
𝑀𝑆 ∶ 𝑚clk (𝑘) = ⎨ (32) ables 𝜉c (𝑘) and 𝜉s (𝑘) will be reset, and the binary variable 𝛿c (𝑘) will
⎪3 if ℎ𝑜𝑙𝑑𝑜𝑓𝑓 (𝑘) be disabled, allowing the MG to perform 𝑛𝑐max grid connections at
⎪4 if ¬ℎ𝑜𝑙𝑑𝑜𝑓𝑓 (𝑘) maximum in the next time period.

⎧𝜉 (𝑘 + 1) = 𝜉 (𝑘) − 1 3. Optimization problem


if 𝑚clk (𝑘) = 1
⎪ hon hon
⎪𝜉hon (𝑘 + 1) = 𝑚𝑖𝑛(𝑇up , 𝑁) if 𝑚clk (𝑘) = 2 In this paper, the proposed dispatch economic problem of an MG
𝑆𝐴𝑆 ∶ ⎨ (33)
⎪𝜉hoff (𝑘 + 1) = 𝜉hoff (𝑘) − 1 if 𝑚clk (𝑘) = 3 is formulated as a short-term, multi-objective optimization problem
⎪𝜉 (𝑘 + 1) = 𝑚𝑖𝑛(𝑇 if 𝑚clk (𝑘) = 4 (i.e., it has a forecasting horizon of up to 6 h [42]). The proposed for-
⎩ hoff down , 𝑁)
mulation takes into account not only the battery bank storage levels to
For example, if the MG is connected to the main grid (𝑢g (𝑘) = 1), be managed by the MG but also the possibility to perform connections
the ℎ𝑜𝑙𝑑𝑜𝑛(𝑘) state is enabled and the variable 𝑚clk (𝑘) = 1 selects the to the main grid for selling and purchasing energy. At every instant 𝑘,
SAS dynamic that decrements 𝜉hon (𝑘). When 𝜉hon (𝑘) is less than zero, the energy management system must make high-level decisions such as
the ℎ𝑜𝑙𝑑𝑜𝑛(𝑘) state becomes inactive and the counter changes its SAS whether to charge or discharge the battery bank, the amount of energy
dynamics according to the mode selector 𝑚clk (𝑘) = 2. In this situation, that can be sold or purchased from the main grid, and the loads that can
the MG has reached its minimum connection time and can remain be shifted or disconnected. The mathematical formulation proposed in
connected or not. this paper includes the following constraints:

6
D.P. e Silva et al. Applied Energy 278 (2020) 115581

• Equipment and technologies capacities 3.1.1. Battery bank


• Power flow balance constraints (generation, storage, and de- The operational and maintenance (O&M) costs of the battery bank
mand) (𝐽bat ) presented in (44) are related to the charging and discharging
• Maximum amount of grid connections during a determined time frequency of the battery bank. When the MG is in island mode, its
interval charging and discharging frequency depends on the power balance in
• Minimum time intervals that an MG must remain in the grid- (25). When the battery bank is not charged and the MG is connected to
connected mode and island mode the grid, the charger of the battery bank is considered a demand load
(𝐷c2 (𝑘)).
The proposed formulation is detailed in the next sections. 𝐽bat (𝑘) = 𝑂𝑀b [¬𝑢g (𝑘)[(−2(𝛿dex (𝑘)𝑃g (𝑘)) + 𝑃g (𝑘))
(44)
− 𝛿s2 (𝑘)𝐷c2 (𝑘)] + 𝛿s2 (𝑘)𝐷c2 (𝑘)]
3.1. Objective function formulation In the expression (44), 𝑂𝑀b is a cost rate (US$/kWh) and the binary
variables satisfy the logical equations (11) and (45).
The objective function, shown in (42), represents the operational
[𝛿dex (𝑘) = 1] ↔ [𝑃g (𝑘) < 0] (45)
and economic costs of an MG over a planning horizon with 𝑁 samples.
The term 𝐽bat (𝑘) is the operational and maintenance costs of the battery The expressions 𝛿𝑠2 (𝑘)𝐷c2 (𝑘) and 𝛿dex (𝑘)𝑃g (𝑘) are replaced by the fol-
bank, 𝐽p (𝑘) represents the purchase and sale costs of electricity, and lowing auxiliary variables:
𝐽dis (𝑘) is the discomfort cost for turning off the unexpected loads: 𝛿crt (𝑘) 𝑧ch (𝑘) = 𝛿s2 (𝑘)𝐷c2 (𝑘)
is a binary variable that is enabled when the battery bank SOC is lower (46)
𝑧dex (𝑘) = 𝛿dex (𝑘)𝑃g (𝑘)
than its critical level (𝑆crt ), and 𝛿dump (𝑘) is a binary variable that is
enabled when an MG is operating in the island mode, the battery bank The variable 𝑧ch (𝑘) denotes that the battery bank should be charged
is fully charged (𝑆(𝑘) = 1), and power generated due to the renewable when the MG is connected to the main grid and the SOC is no at the
energy sources is higher than actual demand. maximum level (𝛿s2 (𝑘) = 𝑢g (𝑘) ∨ ¬𝛿s1 (𝑘)). The 𝑧dex (𝑘) variable enables
the power balance when the RES generation is greater than the load

𝑁−1
demand. Replacing the auxiliary variables presented in (46) by the
𝐽N (𝑘) = [𝑞bat 𝐽bat (𝑘 + 𝑖) + 𝐽p (𝑘 + 𝑖) + 𝐽dis (𝑘 + 𝑖) respective terms of expression (44), we obtain
𝑖=0

+ 𝑞crt 𝛿crt (𝑘 + 𝑖) + 𝑞dump 𝛿dump (𝑘 + 𝑖)] (42) 𝐽bat (𝑘) = 𝑂𝑀b [¬𝑢g (𝑘)[(−2𝑧dex (𝑘) + 𝑃g (𝑘)) − 𝑧ch (𝑘)] + 𝑧ch (𝑘)] (47)

Because there are still nonlinear terms in (47), it is necessary to define


To increase the life cycle of the battery bank, 𝐽bat (𝑘) is penalized
another auxiliary variable as follows:
by the weight 𝑞bat and the critical SOC is penalized by the weight 𝑞crt .
When the MG is in the island mode and the battery bank SOC is at 𝑧𝑏𝑎𝑡 (𝑘) = ¬𝑢g (𝑘)[(−2𝑧dex (𝑘) + 𝑃g (𝑘)) − 𝑧ch (𝑘)] (48)
the maximum level, the excess of RES power generation dissipates in
Finally, replacing 𝑧bat (𝑘) in (47), we have the following linear battery
a dump load, wasting energy. The waste of excess renewable power
cost:
generation is penalized by the weight 𝑞dump . The main decisions of the
proposed objective function are as follows: 𝐽bat (𝑘) = 𝑂𝑀b [𝑧bat (𝑘) + 𝑧ch (𝑘)] (49)

Table 1 shows the O&M battery costs for different MG operation


• Minimize the charging and discharging frequency of the battery
modes and power balances, by considering the assumption that the
bank
battery bank is not full (𝛿s1 (𝑘) = 0).
• Minimize the discomfort caused by unexpected load disconnec-
When an MG is isolated, the O&M costs of the battery bank depend
tion
on the power balance in (25). When the MG is connected to the grid, the
• Maximize the electricity selling while charging the battery bank O&M costs depend on the charger demand. All weights of the proposed
once the MG is connected to the main grid formulation are equal to or greater than zero. If the power balance is
• Minimize the waste of the excess RES power generation in the negative (𝑃g (𝑘) < 0), the expression 𝐽bat (𝑘) = −𝑂𝑀b 𝑃g (𝑘) will always
dump load be positive.
• Prevent the battery bank from reaching critical SOC to extend its
life cycle and ensure the safe operation of the MG 3.1.2. Electricity price
In the grid-connected mode (𝑢g (𝑘) = 1), the MG can sell and
The decision variables of the objective function are the binary purchase electricity from/to the main grid. The MG can sell elec-
variables (𝑐h (𝑘), ℎ = 1, … , 𝑛c ) that turn on/off the controllable loads tricity at a selling price 𝑐s (𝑘) when the power balance in (25) is
and the operation mode of the MG (𝑢g (𝑘)). negative. Otherwise, the MG can purchase electricity at a purchasing
The objective function in (42) is nonlinear because there are multi- price 𝑐p (𝑘). The Eq. (50) gives the objective function term representing
plications between binary variables and real value functions. By defin- the purchase and sale of energy:
ing some auxiliary variables such as 𝑧(𝑘) = 𝛿(𝑘)𝑓 (𝑘), where 𝛿(𝑘) is a 𝐽p (𝑘) = 𝑢g (𝑘)[(𝑐s (𝑘) − 𝑐p (𝑘))𝛿dex (𝑘)𝑃g (𝑘)] + 𝑐p (𝑘)𝑢g (𝑘)𝑃g (𝑘) (50)
binary variable, we can transform (42) into a linear objective function
with the following linear mixed-integer constraints [16]: To transform the nonlinear terms of expression (50) in linear terms, we
defined the following auxiliary variables:
𝑧 ≤ 𝑀𝛿 (43)
𝑧p1 (𝑘) = (𝑐s (𝑘) − 𝑐p (𝑘))𝛿dex (𝑘)𝑃g (𝑘)
− 𝑧 ≤ −𝑚𝛿
𝑧p2 (𝑘) = 𝑢g (𝑘)𝑧p1 (𝑘) (51)
𝑧 ≤ 𝑓 (𝑥) − 𝑚(1 − 𝛿)
𝑧bal (𝑘) = 𝑐p (𝑘)𝑢g (𝑘)𝑃g (𝑘)
− 𝑧 ≤ −𝑓 (𝑥) + 𝑀(1 − 𝛿)
Replacing these auxiliary variables by their respective terms in (50),
where 𝑓 is a real function and 𝑀 and 𝑚 are their upper and lower limits we obtained the following linear function:
respectively. Posteriorly, this transformation is presented according to
each objective function term. 𝐽p (𝑘) = 𝑧p2 (𝑘) + 𝑧bal (𝑘) (52)

7
D.P. e Silva et al. Applied Energy 278 (2020) 115581

Table 1
O&M battery cost for different MG operation modes and power balances.
Microgrid operation mode Power balance 𝐽bat
Island (𝑢g = 0) Positive (𝛿dex = 0) 𝑂𝑀b [𝑃g − 𝛿s2 𝐷c2 + 𝛿s2 𝐷c2 ] = 𝑂𝑀b 𝑃g
Island (𝑢g = 0) Negative (𝛿dex = 1) 𝑂𝑀b [−2𝑃g + 𝑃g − 𝛿s2 𝐷c2 + 𝛿s2 𝐷c2 ] = −𝑂𝑀b 𝑃g
Connected (𝑢g = 1) Positive (𝛿dex = 0) 𝑂𝑀b 𝐷c2
Connected (𝑢g = 1) Negative (𝛿dex = 1) 𝑂𝑀b 𝐷c2

3.1.3. Controllable loads Table 2


Microgrid equipment specifications.
In this paper, we considered the demand response program [55],
where the customers can specify the curtailment of the controllable Microgrid equipment

loads for better power management. This procedure may occur in PV Panels Six PV panels of 250 Wp each, total power: 1500 Wp, open
circuit voltage: 37.8 V, short circuit current: 8.71A, Axitec,
critical operation situations; for example, when the MG is isolated and
model: AC-250P/156-60S [56]
there is low RES power generation. The controllable loads, however, PV inverter Power: 2.0 kW, output voltage: 220 V, Fronius, model:
follow the forecasted demand when there is enough power generation. Fronius Galvo 1.1-5 [57]
The demand response program usually leads to the user’s discomfort, Wind turbine 2.46 m blade diameter wind generator, nominal power: 1000
which is represented by a penalty associated with the load curtail- W, output voltage: 220 V, cut-in wind speed: 2 m/s, nominal
wind speed: 11 m/s, cut-off wind speed: 16 m/s, Enersud,
ment/shedding. The amount of electrical load not met by the MG due model: GERAR246 [58]
to the load curtailment is given by Wind inverter Power: 1,5 kW, output voltage: 220 V, Ginlong, model:
𝑛c CO.LTD GCI-1.5kW [59]

𝐽dis (𝑘) = 𝑞h (1 − 𝑐h (𝑘))𝐷h (53) Energy storage Eight lead–acid batteries, 12 Vdc, 55 AH, Moura, model:
system 12MF55 [60]
ℎ=1
Resistive loads Six resistors with 500 W each, 127 V, Denktherm, model:
where 𝐷h has been defined in (20) and 𝑛c is the total number of con- BR6-500/127
trollable electrical loads. The weight 𝑞h penalize the objective function
(42) if there is load shutdown.

3.2. Hybrid economic model predictive control optimal solution vector 𝐮 contains the controls 𝑢(𝑘), … , 𝑢(𝑘 + 𝑁 − 1);
however, with the receding horizon principle, we applied only 𝑢(𝑘) and
abandoned the remaining control actions. In the next sample 𝑘 + 1,
The DHA models of MG presented in Section 2 can be converted
we updated the initial conditions 𝑥0 = 𝑥(𝑘 + 1) and calculated a new
to mixed-integer linear inequalities by using the auxiliary variable de-
sequence of control actions 𝑢(𝑘 + 1), … , 𝑢(𝑘 + 𝑁). This procedure is
scribed in the previous subsection and converting each logical condition
repeated in real time until the planning horizon 𝑁p is reached.
[𝑓 (𝑥) ≤ 0] ↔ [𝛿 = 1] to the following inequalities:
𝑃𝑁 = 𝑚𝑖𝑛𝐽N (𝑘)(𝐱, 𝐮, 𝜹, 𝒛) (58)
𝑓 (𝑥) ≤ 𝑀 − 𝑀𝛿 (54) 𝑢

𝑓 (𝑥) ≥ 𝜀 + (𝑚 − 𝜀)𝛿 (55) Fig. 2 outlines the proposed economic dispatch procedure. First of
all, the HEMPC receives the electricity prices (𝑐s (𝑘) and 𝑐p (𝑘)), wind
where 𝜀 is an arbitrarily small positive scalar. speed (𝑣(𝑘)), irradiance (𝜆(𝑘)), temperature (𝑇 (𝑘)), and load demand
Other constraints of MG equipment are related to the upper and forecasts (𝐷(𝑘)). The wind power generation is calculated from the
lower limits of the SOC, the power balance in (25), and the current wind turbine MLD model presented in the Eqs. (7)–(10) and the PV
balance, see the first three constraints of (56), respectively. The fourth power generation is determined from the PV MLD model in (3), (4),
time-varying constraint presented in (56) depends on the demand and (5). The HEMPC also receives the objective function penalties
forecasting curve 𝐷c𝑓 (𝑘). We observed in the last constraint that the and the initial condition 𝑥0 . Next, the receding horizon strategy is
generated power is limited by the power forecasting sum of the wind applied at each sample time 𝑇s with the new measured/estimated states
(𝑃w𝑓 (𝑘)) and PV (𝑃pv
𝑓
(𝑘)) generations. 𝒙(𝑘 + 1|𝑘 + 1) = 𝒙k+1 . By doing so, a feedback policy is designed.

𝑆min ≤ 𝑆(𝑘) ≤ 𝑆max 4. Numeric results


𝑃g𝑚𝑖𝑛 ≤ 𝑃g (𝑘) ≤ 𝑃g𝑚𝑎𝑥
The proposed predictive control algorithm was applied to an MG
𝑖𝑚𝑖𝑛 𝑚𝑎𝑥
g ≤ 𝑖g (𝑘) ≤ 𝑖g (56)
composed of photovoltaic panels, wind turbine, converters (PV and
0 ≤ 𝐷c (𝑘) ≤ 𝐷c𝑓 (𝑘) wind converters), charge control panel, controllable loads, battery bank
0 ≤ 𝑃w (𝑘) + 𝑃pv (𝑘) ≤ 𝑃w𝑓 (𝑘) + 𝑃pv
𝑓
(𝑘) for energy storage, and a common connections panel (see Fig. 3) Ta-
ble 2 presents the characteristics of the equipment used in all numeric
All constraints containing the real and binary variables can be trans- results.
formed into a mixed logical dynamical (MLD) system [16], represented The proposed algorithm was implemented using MATLAB with
by CPLEX and HYSDEL toolboxes. The computer used has Intel Core i7-
𝒙(𝑘 + 1) = 𝑨𝒙(𝑘) + 𝑩 1 𝒖(𝑘) + 𝑩 2 𝜹(𝑘) + 𝑩 3 𝒛(𝑘) 7700 3.6 Ghz processor, 16 Gb RAM, Linux Ubuntu 18.10 64 bits. We
have analyzed the HEMPC performance for two simulation scenarios:
𝒚(𝑘) = 𝑪𝒙(𝑘) + 𝑫 1 𝒖(𝑘) + 𝑫 2 𝜹(𝑘) + 𝑫 3 𝒛(𝑘) (57)
𝑬 2 𝜹(𝑘) + 𝑬 3 𝒛(𝑘) ≤ 𝑬 1 𝒖(𝑘) + 𝑬 4 𝒙(𝑘) + 𝑬 5 1. Scenario 1: Prioritizes battery bank conservation through the 𝑞bat
penalty in (42)
where 𝒙 = [𝑥r 𝑥b ∈ ]𝑇 × 𝑅𝑣c {0, 1}𝑣l
are continuous and binary states,
2. Scenario 2: Prioritizes energy sales by decreasing the 𝑞bat value
𝒖 = [𝑢r 𝑢b ]𝑇 ∈ 𝑅𝑚𝑐 × {0, 1}𝑚l are continuous and binary inputs, 𝒚 = by 10 times compared to Scenario 1
[𝑦r 𝑦b ]𝑇 ∈ 𝑅𝑝c × {0, 1}𝑝l are the outputs, 𝜹 ∈ {0, 1}𝑟l and 𝒛 ∈ 𝑅𝑟c
represent binary and continuous auxiliary variables, respectively. Moreover, the proposed scenarios should minimize the purchased en-
The proposed HEMPC approach solves the optimal control problem ergy, the waste of renewable energy and the shutdown of loads, allow-
introduced in (58), subject to the MLD constraints in (57) at instant 𝑘, ing the MG to continue offering services to the main grid and meeting
given an initial condition 𝑥0 = 𝑥(𝑘) and a forecasting horizon 𝑁. The the user demand.

8
D.P. e Silva et al. Applied Energy 278 (2020) 115581

Fig. 2. Hybrid EMPC block diagram.

Fig. 3. Single-line diagram of the microgrid and its connection to the main grid.

9
D.P. e Silva et al. Applied Energy 278 (2020) 115581

Table 3 Table 4
Common parameters for all scenarios. Numerical values of objective function weights for each Scenario.
Parameters Value Unit Parameters Scenario 1 Scenario 2
𝑖ch 3.5 A 𝑞bat 1 0.1
𝑁 1 h 𝑞2 0.01 0.01
𝑁p 168 h 𝑞3 20 0.01
𝜂 0.95 pu 𝑞4 0.01 0.01
𝑂𝑀b 0.08 US$/kWh 𝑞5 0.01 0.01
𝑃g𝑚𝑖𝑛 −2.5 kW 𝑞crt 100 100
𝑃g𝑚𝑎𝑥 2.5 kW 𝑞dump 50 50
𝑆min 0.0 pu
𝑆max 1.0 pu
𝑆crt 0.5 pu Table 5
𝑇s 10 min Parameter values of the MG grid-connection constraints for each weather station.
Parameters Santa vitoria Natal Unit
𝑛𝑐max 3 5 –
𝑇down 4 5 Samples
The performance analysis of the proposed control algorithm is 𝑇up 5 6 Samples
carried out through simulations using real weather data and forecasts. 𝑇c 144 144 Samples
The weather data of irradiance, temperature, and wind speed were
extracted from the National Institute of Meteorology [61]. We used the
weather research and forecasting (WRF) model [44] for estimations of
Scenario 1, load 3 has the highest priority to remain connected, and in
the direction and speed of wind, air temperature, and global radiation.
Scenario 2, the loads have the same priority. The value of 𝑞crt is high
The model consists of four telescoping nests, with horizontal resolutions
to prevent the SOC level of the battery bank from exceeding its critical
of 27 km on the outermost domain (d01), 9 km on the first nest (d02),
value; whereas, 𝑞dump is high to reduce the waste of excess renewable
3 km on the second nest (d03), and 1 km on the innermost nest (d04).
generation.
The numerical grid was configured with 31 vertical levels that follow
Table 5 shows the parameter values related to the MG grid-connec-
the terrain, with the first six levels at approximately 25 m, 58 m, 74
tion constraints 𝑛𝑐max , 𝑇down , 𝑇up , 𝑇c for each weather station situated
m, 89 m, 110 m, and 141 m above the ground. The WRF model starts
in different geographical locations. The transients for MG converters
automatically every day at 2:00 a.m. (local time), using the boundary
must respect the minimum time of 300 s [63]. Therefore, the minimal
conditions data of the Global Forecast System [62]. The model runs
time intervals 𝜏c and 𝜏i in (26) and (27) respectively must be greater
twice, generating meteorological forecasts within a horizon of 24 h
than such value specified in the standard.
and with a resolution of 10 min (i.e., 10, 20, 30 … 1440 min), for Natal
Fig. 4 presents the daily curves of the energy purchase and sale
[20.19𝑜 S and 40.2𝑜 W], and Santa Vitoria do Palmar [33.742297𝑜 S and
prices. Note that the energy sale price is most attractive between
53.37221𝑜 W]. The locations may be briefly described as follows:
midday and 3:00 p.m.. The purchase price of energy increases at peak
hours between 5:00 p.m. and 10:00 p.m..
(1) Natal-RN. Located in the northeast of Brazil, it has a hot and
The power demand of the MG has a characteristic similar to that
humid climate with average temperatures around 28 𝑜 C and
of a typical residence, where there are turn on or turn off controllable
average wind speed of 3.4 m∕s. In Natal, the summer is hot and
loads and a critical load of (𝐷1 = 0.25 kW) that remains always turned
partly cloudy; the winter is short and warm and with an almost
on. Demand for controllable loads is presented in (59). Such loads can
cloudless sky. During the whole year, precipitation and medium
be turned off at any time by the controller, thus generating a met
to strong wind occur. The average irradiance is 248 W/m2 .
demand.
(2) Santa Vitoria do Palmar-RS, Brazil. Located in the extreme south
of Brazil, on the border with Uruguay. It has a mild climate with [𝑐2 (𝑘) = 1] ↔ [𝐷2 = 0.15 kW]
average temperatures around 18𝑜 C. It has an average wind speed [𝑐3 (𝑘) = 1] ↔ [𝐷3 = 0.20 kW]
of over 6.5 m∕s, which is considered a good average for installing (59)
[𝑐4 (𝑘) = 1] ↔ [𝐷4 = 0.20 kW]
wind turbines. In Santa Vitoria do Palmar, the summer is warm
and muggy; the winter is mild. During the whole year there is [𝑐5 (𝑘) = 1] ↔ [𝐷5 = 0.30 kW]
precipitation and strong wind with partly cloudy skies. We evaluated the proposed algorithm performance by defining the
user comfort index (CI) through the following equation:
Table 3 shows the common parameters used for all simulation
𝐷L𝑚
scenarios. The current value 𝑖ch (𝑘) of the battery bank is within a range 𝐶𝐼 = 100 % (60)
defined in [60] to obtain the highest charging and discharging effi- 𝐷L𝑟
ciency. We chose the forecasting horizon (𝑁) to guarantee the lowest where 𝐷L𝑚 is the average met demand and 𝐷L𝑟 is the average real
computational cost without compromising the stability of the HEMPC. demand during the planning horizon.
We tested all the MG’s operations with a planning horizon (𝑁p ) of The met demand differs from the real demand when the MG man-
one week. According to [42], this period is adequate to evaluate the agement algorithm removes loads to minimize operating costs. The
performance of the management algorithm because the weather data forecasted demand (𝐷L𝑓 (𝑘)) can be scheduled in advance and unpre-
used in the simulation have different characteristics. The charge and dictable loads can be shedding to the forecasted demand before ap-
discharge efficiencies of the battery bank are equal to 0.95, see [31]. plying the optimization algorithm, providing the real demand. We
The O&M cost of the battery bank was estimated from its total cost also assumed that the real demand shifts over time in relation to the
specified in Table 2, divided by the lifetime. The critical SOC is based forecasted demand and the forecasting error is around 10% (see Fig. 5).
on the manufacturer’s recommendations to keep the discharge variation Fig. 6(a) shows the time series of real and forecasted temperatures
as smooth as possible in order to increase the battery life. over a week at the Santa Vitoria-RS weather station. The average
We chose the objective function penalties presented in Table 4 temperature is equal to 19.34 𝑜 C, and the minimum and maximum
according to the priority established for each simulation scenario. temperatures are equal to 12 𝑜 C and 26 𝑜 C, respectively. Fig. 6(b) shows
Scenario 2 prioritizes the sale of energy, and it has the lowest 𝑞bat the time series of the temperature forecasting error, in which the mean
parameter in relation to the other scenarios. The penalties 𝑞2 ⋯ 𝑞5 absolute error (MAE) and mean relative error (MAPE) are equal to
refer to the controlled loads by contactors 𝑐2 ⋯ 𝑐5 shown in (53). In 1.51 𝑜 C and 7.81% respectively.

10
D.P. e Silva et al. Applied Energy 278 (2020) 115581

Fig. 4. Energy prices over 24 h.

Fig. 5. Real and forecasted demand curves over 24 h.

Fig. 6. (a) Temperature curves; (b) Temperature forecasting error over one week.

Fig. 7(a) shows the time series of real and predicted irradiance irradiance forecasting error, with MAE and MAPE equal to 60.0 W/m2
collected during one week at the Santa Vitoria-RS station. In this case, and 22.83%, respectively.
irradiance has its peak range between 7:00 a.m. and 6:00 p.m., with Fig. 8(a) shows the wind speed profile observed at Santa Vitoria
an average around 264.0 W/m2 . Fig. 7(b) shows the curve of the station for a week. The average wind speed is 6.71 m∕s and there are

11
D.P. e Silva et al. Applied Energy 278 (2020) 115581

Fig. 7. (a) Irradiance curves; (b) Irradiance forecasting error over one week.

gusts greater than 15 m∕s. Fig. 8(b) shows the wind speed forecasting Fig. 10 shows the real and met demands associated with the simu-
error curve, with MAE of 1.78 m∕s and MAPE of 26.60%. lation presented in Fig. 9. Note that the met-demand curve follows the
The weather data forecasts obtained from the WRF model were real-demand curve, indicating that the HEMPC experiences a low level
converted to photovoltaic and wind power forecasts through the math- of load shedding.
ematical models presented in Sections 2.1 and 2.2, respectively. Be- Fig. 11 shows the simulation result for Scenario 2 in Santa Vitoria
cause of the difference in heights between the weather station and the do Palmar. In this scenario, the MG remains connected to the grid
wind turbine, we recalculated the real wind in the turbine from an for a longer time than in Scenario 1. Thus, the battery SOC shown in
extrapolation technique (see Appendix A). Fig. 11(a) remains at its maximum value for about 63 h. Consequently,
Table 6 shows low correlation coefficient between the forecasting the MG sells more energy than it does in Scenario 1, but it also buys
errors of renewable power and weather data obtained from the Santa more energy when the power balance, shown in Fig. 11(b), becomes
Vitoria-RS and Natal-RN stations. positive. In addition, the power balance presents a smoother oscillation
than in Scenario 1, between the 4th and 6th days (72 h and 144 h), thus
Thus, we observed from the statistics presented in Tables 7 and 8,
producing little renewable energy.
that the forecast errors of the photovoltaic and wind power are worse
Fig. 12 shows the profiles of the real and met demands. The met
than the forecast errors of the weather data.
demand has a behavior similar to that in Scenario 1, where the HEMPC
Next, we discuss the results obtained for each scenario, considering
algorithm almost does not shutdown loads.
that the weather data forecasts are determined from the WRF model.
Fig. 9(a) shows the evolution of the battery SOC and the MG connection 4.1. Sensitivity analysis of the HEMPC algorithm in relation to the forecast-
mode for Scenario 1 in Santa Vitoria do Palmar during a week of ing errors
operation. Fig. 9(b) shows that Eq. (25) is satisfied because the power
balance is negative when there is an excess of energy production. In the This analysis is carried out with respect to the comfort index (CI),
case of low energy generation, the balance tends to be positive or close cost of the battery bank, profit from energy sale, cost of purchased
to the origin of the graph. In the first 72 h there is a large amount of energy, and the cost of waste of renewable energy. These last four terms
renewable power, as shown in Fig. 9(b), that keeps the battery SOC at are defined as follows:
its maximum level during most of this period. When the SOC reaches 𝑁
∑p
its maximum value, there is no charging and discharging of the battery 𝐶bat = 𝐽bat (𝑘) (61)
bank in such a way that there is a lower O&M cost. 𝑘=1
In addition, the MG sells energy during most of the first 72 h 𝑁
∑p

because the energy balance, as shown in Fig. 9(b), is negative. Between 𝐽s = 𝑐s (𝑘)𝑃g (𝑘), when 𝑢g (𝑘) = 1 and 𝛿g (𝑘) = 0 (62)
the 4th and 6th days (or 72 h and 144 h), there is a low amount 𝑘=1
𝑁p
of renewable energy generation, which makes the MG connect to the ∑
main grid to buy energy and prevent the battery bank from reaching 𝐽pur = 𝑐p (𝑘)𝑃g (𝑘), when 𝑢g (𝑘) = 1 and 𝛿g (𝑘) = 1 (63)
𝑘=1
its critical SOC. From the end of the 6th day onwards, we observed
𝑁p
an adequate renewable generation. In addition, the SOC level increases ∑
𝐽dump = 𝑐s (𝑘)𝑃g (𝑘), when 𝛿dump (𝑘) = 1 (64)
because the MG connects to the grid to sell the excess renewable en- 𝑘=1
ergy, avoiding having to dissipate it in the dump load. We observed that
In addition, we defined financial profit through the following expres-
the proposed optimization algorithm does not violate the maximum
sion:
number of connections or the minimum time that the MG must remain
connected to the main grid. 𝑝𝑟𝑜𝑓𝑖𝑡 = 𝐽s − 𝐽pur − 𝐽dump (65)

12
D.P. e Silva et al. Applied Energy 278 (2020) 115581

Table 6
Correlation coefficients between power and weather data.
PV power errors and PV power errors and Wind power errors and
temperature errors irradiance errors wind speed errors
Santa Vitoria 0.03 0.71 0.64
Natal 0.14 0.53 0.65

Fig. 8. (a) Wind speed curves; (b) Wind forecasting error over one week.

Fig. 9. Scenario 1: (a) State of charge and connection mode of MG; (b) Power balance and RES power over one week.

Fig. 10. Scenario 1: Real and met demands over one week.

13
D.P. e Silva et al. Applied Energy 278 (2020) 115581

Fig. 11. Scenario 2: (a) State of charge and connection mode of MG; (b) Power balance and RES powers over one week.

Fig. 12. Scenario 2: Real and met demands over one week.

Table 7 The HEMPC algorithm with the forecast strategy F3 is deterministic


Statistic values of renewable power and weather forecasting errors at Santa Vitoria-RS. and it is considered as a benchmark. Table 9 shows that the MG needs
Santa Vitoria-RS Mean MAE MAPE (%) to buy energy in all scenarios, considering all forecasting strategies
Photovoltaic 388.4 W 93.9 W 24.17 evaluated by the HEMPC. Because there is not enough wind generation
Power
Wind 482.0 W 248.6 W 51.58 in Natal, we observed that more energy is purchased in order not to
Temperature 19.31 ◦ C 1.51 ◦ C 7.81 violate the critical SOC and impair the lifespan of the battery bank. In
Weather data Irradiance 264.0 W/m2 60.0 W/m2 22.83 addition, considering all HEMPC scenarios and forecasting strategies,
Wind speed 6.71 m/s 1.78 m/s 26.60 both in Natal and Santa Vitoria, a high level of comfort is observed (less
than 1% of demand is not met), and there is no waste of energy due to
excess of renewable generation. Regarding the Natal weather station,
Table 8
we observed, for each scenario (1 and 2), that the terms 𝐶bat , 𝐽𝑠 and
Statistic values of renewable power and weather forecasting errors at Natal-RN.
𝐽pur do not vary considerably when we modify the forecasting strategy.
Natal-RN Mean MAE MAPE (%)
Therefore, the HEMPC algorithm is not highly sensitive to forecasting
Photovoltaic 399.4 W 96.8 W 24.22 errors, which can eventually happen due to low generation of wind
Power
Wind 96.7 W 67.3 W 69.58
energy in Natal.
Temperature 28.31 ◦ C 1.08 ◦ C 3.82 However, because appropriate solar energy production was com-
Weather data Irradiance 272.0 W/m2 62.0 W/m2 22.61 bined with excellent wind energy production from the Santa Vitoria
Wind speed 3.32 m/s 0.95 m/s 28.54 do Palmar station, we observed (see Table 9) that when applied to this
location, the proposed optimization algorithm has financial profit, and
the battery bank operation average cost is 39.6% lower than it is in
Natal-RN. Unlike Natal, where the MG connects to the main grid to
avoid overtaking the critical SOC, the grid connection in Santa Vitoria
To assess the impact of the weather and load scheduling forecasting
enables the excess of generated energy to be sold because the batteries
errors on the proposed HEMPC algorithm, we defined the following remain charged for a long period, as shown in Fig. 11. In Santa Vitoria,
forecasting strategies: the indexes analyzed in Table 9 have greater variations when the three
HEMPC forecasting strategies are compared. In addition, the perfect
F1: Forecast of weather data using WRF with forecast error of the load forecast (F3) achieves 19.5% more profit, on average, than the F2
schedule, applying a 2-hour shift (related to the real load) to the forecasting strategy, which cost the battery bank 27.4% more.
expected load Therefore, we have concluded that the proposed algorithm is more
sensitive to forecasting errors when there is a considerable amount of
F2: Forecast of weather data using WRF with perfect forecast (without renewable energy production, where such errors substantially affect the
error) of the load scheduling cost of the battery bank as well as the financial profit (27.3% for the
former and 13.3% for the latter), whereas there is a minor degree of
F3: Perfect forecast in weather data and perfect load scheduling variation in terms of comfort index (less than 1%).

14
D.P. e Silva et al. Applied Energy 278 (2020) 115581

Table 9
Sensitivity analysis with respect to the forecasting errors for Scenarios 1 and 2 over one week.
Location Scenarios Forecast 𝐶bat (US$) 𝐽s (US$) 𝐽pur (US$) 𝐽dump (US$) profit (US$) CI (%)
F1 6.91 0.20 6.38 0.00 −6.18 100.00
1 F2 6.89 0.20 6.44 0.00 −6.24 100.00
Natal F3 6.76 0.19 6.59 0.00 −6.40 100.00
Brazil
F1 7.19 0.41 5.20 0.00 −4.79 99.56
2 F2 7.18 0.41 5.20 0.00 −4.79 99.56
F3 6.99 0.44 6.13 0.00 −5.69 99.93
F1 5.44 4.48 1.50 0.00 2.98 99.37
1 F2 5.24 4.73 1.65 0.00 3.08 99.56
Santa Vitoria F3 6.08 4.36 1.01 0.00 3.35 99.56
Brazil
F1 4.10 6.65 2.44 0.00 4.21 99.56
2 F2 3.77 6.84 3.09 0.00 3.75 99.56
F3 5.39 6.00 1.20 0.00 4.80 99.56

Table 10
Comparison of battery cost, financial profit and comfort index among the HEMPC, MILPm and RBS strategies.
Location Scenarios Strategy 𝐶𝑏𝑎𝑡 (US$) 𝐽𝑠 (US$) 𝐽𝑝𝑢𝑟 (US$) 𝐽𝑑𝑢𝑚𝑝 (US$) profit (US$) CI (%)
RBS 6.82 0.25 4.70 0.00 −4.45 92.52
1 MILPm 8.50 0.01 5.63 0.00 −5.62 100.00
Natal HEMPC 7.37 0.17 5.63 0.00 −5.46 99.57
Brazil
RBS 5.80 0.18 3.61 0.01 −3.44 80.26
2 MILPm 7.29 0.40 7.51 0.68 −7.79 100.00
HEMPC 7.71 0.34 4.35 0.00 −4.01 99.61
RBS 6.53 1.58 0.33 1.92 −0.67 94.69
1 MILPm 7.35 0.42 2.42 2.26 −4.26 99.92
Santa Vitoria HEMPC 6.46 4.70 0.62 0.01 4.07 99.91
Brazil
RBS 6.08 1.85 0.18 2.14 −0.47 89.15
2 MILPm 4.93 1.25 4.97 3.48 −7.20 100.00
HEMPC 4.96 6.74 2.01 0.00 4.73 99.93

4.2. Comparison of the proposed algorithm with others MG management Table 11


Comparison of MG operational safety indexes among the HEMPC, MILPm and RBS
strategies.
strategies.
Location Scenarios Strategy SOC𝑚𝑖𝑛 𝑇𝑐𝑟𝑡 (min) 𝑃 𝑇𝑐𝑟𝑡 (%)
In this section the performance of the HEMPC strategy has been
compared with the following MG management techniques: RBS 0.38 710 7.04
1 MILPm 0.32 4380 43.45
Natal HEMPC 0.49 110 1.09
Rule-based strategy (RBS): It mimics the logical decision of an MG Brazil
operator. The description of this algorithm can be found in RBS 0.49 210 2.08
2 MILPm 0.43 210 2.08
Appendix B
HEMPC 0.49 70 0.69

MILP multi-period (MILPm): It consists in the solution of successive RBS 0.49 20 0.20
1 MILPm 0.30 530 5.26
MILP problems (42) with a 6-hour forecasting horizon until
Santa Vitoria HEMPC 0.49 20 0.20
reaching the planning horizon of 168 h. The proposed strategy Brazil
solves the MILP problem at a sampling rate of 10 min, and RBS 0.54 0 0.00
the data update occurs every 6 h. A longer forecasting horizon 2 MILPm 0.46 100 0.99
HEMPC 0.53 0 0.00
would lead to the overflow of computational memory

The HEMPC and MILP multi-period are receding horizon strategies;


however, the HEMPC updates the meteorological data for each sam- Note that the energy balance is predominantly positive in Natal and
pling period and applies the first solution obtained from the MILP prob- predominantly negative in Santa Vitoria (i.e., there is more energy
lem in the management of the MG (closed-loop strategy). In MILPm, the being sold in Santa Vitoria and more energy being purchased in Natal).
data update occurs at multiple times of the forecasting horizon after the We confirmed this from Table 10, which shows that all strategies had
resolution of each MILP problem, and we use all calculated solutions an economic loss in Natal, and only the HEMPC makes a profit in Santa
in the MG management open loop or myopic strategy [64]). Vitoria. This is because the MILPm and RBS strategies in Santa Vitoria
Figs. 13(a) and 14(a) show the SOC levels of Natal and Santa wasted the excess renewable energy, instead of selling it, causing losses.
Vitoria, respectively, for Scenario 1. Note that, because of the low Also, Table 10 shows that the demand comfort index (CI) of RBS was
generation in Natal, the SOC oscillates around the critical level (𝑆crt = below 94.69%, whereas MILPm and the HEMPC had a CI higher than
0.5) for the MILPm and RBS strategies and above the critical level 99% in all scenarios (MILPm had an average CI index 0.3% higher than
for the HEMPC. Because of the high generation in Santa Vitoria, the the HEMPC and 13% greater than RBS). Although RBS has a lower
HEMPC and RBS operate above the critical SOC, and MILPm violates CI index, its battery cost in Natal was the smallest (i.e., RBS prefers
the critical SOC only at the beginning of the simulation. Figs. 13(b) and to discard load to conserve the battery when low power generation
14(b) show the energy balances in Natal and Santa Vitoria, respectively. occurs). However, in Santa Vitoria, the average battery cost of the

15
D.P. e Silva et al. Applied Energy 278 (2020) 115581

Fig. 13. Comparison of the MG management strategies for Natal: (a) SOC levels and (b) Power balances and RES powers.

Fig. 14. Comparison of the MG management strategies for Santa Vitoria: (a) SOC levels and (b) Power balances and RES powers.

Table 12
Computational cost between iterations for different prediction horizons.
N (h) Number of decision variables Number of constraints Average times (s) Worst case times (s) Memory (MB)
1 42 552 3.4 3.6 507
3 126 1656 3.5 3.7 521
6 252 3312 11.1 11.4 565

HEMPC was lower than that of the other strategies (for RBS, the simulation time. Through this table, we noticed that the SOC level
average battery cost was 10.3% higher than the HEMPC and for MILPm furnished by MILPm reached values lower than the critical SOC over a
it was 7.5% higher). Therefore, MG management from the HEMPC long time, mainly in low power generation. Thus, the MILPm strategy
in scenarios with higher power generation is the most economically has a higher operational risk because the battery operation at low levels
efficient. over a long period decreases the reliability of the MG operation. In
Table 11 compares the MG security indexes defined by the minimum contrast, we observed that for the HEMPC, the minimum SOC level was
SOC (𝑆min ) obtained from the battery bank during the simulation close to 0.5, and the average 𝑇crt is 90 min in Natal and 10 min in
period, the time period ( 𝑇crt ) during which the SOC was below the Santa Vitoria (𝑃 𝑇crt equal to 1.4% and 0.1%, respectively). Therefore,
critical SOC, and the percentage rate (𝑃 𝑇crt ) between 𝑇crt and the total the HEMPC is safer in any scenario because the SOC levels furnished

16
D.P. e Silva et al. Applied Energy 278 (2020) 115581

by MILPm and RBS stay below the critical SOC during a period 19.7 remained stable over the planning horizon with forecasting horizons
times and 4.3 times greater than the HEMPC, respectively. between 1 and 6 h. Moreover, the results showed that real-time op-
timization is feasible with sampling periods of up to 10 min. Future
4.3. Computational complexity
work suggests implementing the proposed framework in a real plant
The HEMPC solution, made through the MILP model, requires a considering the control loops of the converters, battery bank charger,
computational time proportional to the forecasting horizon. As shown and a formal controller stability analysis.
in Table 12, the computational time to solve the optimization problem
for horizons less than or equal to 6 h is considerably lower than the
sampling rate (10 min or 600 s). We do not recommend forecasting Nomenclature
horizons larger than 6 h because the computational time to solve the Abbreviations
MILP problem increases considerably and there may be a memory DHA Discrete Hybrid Automata
overflow due to the large number of decision variables and constraints. EG Event Generator
Therefore, there will not be much time left for the algorithm to perform EMS Energy Management System
predictions during the 10 min sampling period. Moreover, the solutions ESS Energy Storage System
obtained by the HEMPC with forecasting horizons from one to 6 h FSM Finite State Machine
converged to near values in all tested meteorological scenarios and for HEMPC Hybrid Economic Model Predictive Control
different forecasting strategies without presenting infeasibilities. HMPC Hybrid Model Predictive Control
MILP Mixed Integer linear Programing
5. Conclusion MG Microgrid
MLD Mixed Logic Dynamic
This paper presented a new optimization model for microgrid man- MPC Model Predictive Control
agement from the hybrid economic model predictive control strategy MPPT Maximum Power Point Tracking
using weather forecasts by the global model. The proposed optimiza- MS Mode Selector
tion algorithm has autonomy in decision-making to perform connec- O&M Operation and Maintenance
tion/disconnection with the main grid to provide ancillary services, PV Photovoltaic
such as the sale of excess power generation. This service helps the RBS Rule Based Strategy
main grid in the power supply for its demand when the selling price of RES Renewable Energy Resources
energy is advantageous and the microgrid has excess power generation. SAS Switch Affine System
Moreover, the model considers a maximum limit of grid-connection SOC State of Charge
occurrence, and after the microgrid connects to the main grid, it must WRF Weather Research and Forecasting
remain connected for a minimum time interval. These constraints give Parameters
flexibility to adapt the microgrid control algorithm to various grid-
𝜂 Storage charging and discharging efficiencies
connection policies established by the power utility. The proposed
𝐴 Ideality factor
optimization algorithm can be applied in any location and does not
𝑎n Wind turbine polynomial coefficients
depend on the physical installations of surface meteorological stations.
𝐶max Storage capacity [Ah]
It can be used for feasibility studies in any location based on the
𝑑𝑛 Photovoltaic panel polynomial coefficients
geographic coordinates of the future installation of a microgrid and its
𝐼sc Short-circuit current [A]
equipment specifications.
𝑘 Time instant [s]
The performance of the proposed control algorithm was analyzed
𝑘𝐵 Boltzmann constant [ m2 kgs−2 K−1 ]
through simulations using real weather data with different meteoro-
𝑛c Number of controllable loads
logical characteristics. The real demand is shifted over time, leading to
𝑛𝑙 Number of critical loads
a demand forecasting error of 10%. Using the weather data forecasts,
𝑛𝑐max Maximum number of grid-connections
the new hybrid wind and solar power generation models presented high
𝑁 Prediction Horizon [h]
forecasting errors that caused variations in the optimization results of
𝑁p Scheduling Horizon [h]
1% in the met demand, 27.3% in the battery bank costs, and 13.3%
𝑂𝑀b O&M costs of battery bank [R$/ kWh ]
in the financial profits. A comparison among different management
𝑃wn Nominal wind power [kW]
strategies showed that multi-period mixed integer linear programming
𝑃pvsat Nominal photovoltaic power [kW]
and the proposed algorithm had a demand comfort index of over
𝑃cutoff Cut off wind power [kW]
99% in all scenarios, whereas the ruled-based strategy was less than
𝑃g𝑚𝑎𝑥 Maximum power balance [kW]
94.7%. Moreover, multi-period mixed integer linear programming and
𝑃g𝑚𝑖𝑛 Minimum power balance [kW]
the ruled-based strategy had state of charge of the battery bank below
the critical state of charge during a period 19.7 and 4.3 times higher 𝑞h Penalty for the load curtailment
than that furnished by the proposed algorithm, respectively. Thus, in 𝑞bat Penalty for the battery bank cost
terms of the microgrid operational safety, the hybrid economic model 𝑞crt Penalty for the Critical SOC
predictive control is more efficient in all scenarios. In the low energy- 𝑞dump Penalty for the energy waste in the load dump
generation scenario, all management policies showed losses with the 𝑇c Time related to the maximum number of grid
sale of energy. In the situation with high energy generation, only the connections
proposed strategy showed a profit. Besides, the ruled-based and multi- 𝑇s Sample time [s]
period mixed integer linear programming strategies had an average 𝑇up Minimum number of samples for the MG to
battery cost of 10.3% and 7.5% higher than the hybrid economic remain grid connected
model predictive control did, respectively. Therefore, in locations with 𝑇down Minimum number of samples for the MG to
high energy generation, the proposed algorithm is more economically remain isolated
advantageous. 𝑆crt Critical state of charge [pu]
Although solutions to optimization problems using hybrid models 𝑆max Maximum state of charge [pu]
require a high computational cost, the results of the proposed algorithm

17
D.P. e Silva et al. Applied Energy 278 (2020) 115581

𝑆max Minimum state of charge [pu] 𝑇up (𝑘) Integer variable related to the minimum number
𝑉b Battery bank voltage [Volts] of samples required for the MG remains isolated
𝑉oc Open circuit photovoltaic voltage [Volts] 𝑚c (𝑘) Integer variable related to the mode selector of
𝑣n Nominal wind speed [m/s] the timer 𝜉s (𝑘)
𝑣cutin Cut-in wind speed [m/s] 𝑚clk (𝑘) Integer variable related to the mode selector of
𝑣cutoff Cut-off wind speed [m/s] 𝜉hon (𝑘) and 𝜉off (𝑘)
𝑥𝑠b Storage auto discharge [pu] 𝑚count (𝑘) Integer variable related to the mode selector of
Real Variables the counter 𝜉c (𝑘)
𝑐p (𝑘) Energy purchase price [US$/kWh] 𝑚l (𝑘) Integer variable related to the load mode selector
𝑐s (𝑘) Energy sell price [US$/kWh] 𝑚p (𝑘) Integer variable related to the mode selector of
𝐶g (𝑘) Energy purchase or sell cost [US$] the energy price
𝐶bat Total O&M battery bank cost during the 𝑚pv (𝑘) Integer variable related to the mode selector of
scheduling horizon [US$] the photovoltaic generation
𝐷c2 (𝑘) Battery charger demand [kW] 𝑚w (𝑘) Integer variable related to the mode selector of
𝐷ch (𝑘) Battery charger auxiliary variable [kW] the wind generation
𝐷h (𝑘) Demand of controllable loads [kW] 𝑚s (𝑘) Integer variable related to the mode selector of
𝐷i (𝑘) Demand of critical loads[kW] the battery charge
𝐷c (𝑘) Total controllable load demand [kW] 𝑐h (𝑘) Binary variable that is enabled when the load h is
𝐷c𝑓 (𝑘) Total scheduled load demand [kW] turned on
𝐷L (𝑘) Total load demand [kW] ℎ𝑜𝑙𝑑𝑜𝑓𝑓 (𝑘) Binary variable that is enabled when MG is in
𝐼(𝑘) Photovoltaic panel current [A] isolated mode
𝑖L (𝑘) Total load current [A] ℎ𝑜𝑙𝑑𝑜𝑛(𝑘) Binary variable that is enabled when MG is grid
𝑖pv (𝑘) Photovoltaic generator current [A] connected
𝑖w (𝑘) Wind turbine generator current [A] 𝛿c (𝑘) Binary variable that is enabled when there is an
𝑖ch (𝑘) ESS charger current [A] MG grid disconnection.
𝐽N (𝑘) Objective function 𝛿cmax (𝑘) Binary variable that is enabled when the number
𝐽dis (𝑘) Discomfort costs of grid connections is maximum
𝐽dump Total waste cost in the dump load during the 𝛿𝜉 (𝑘) Binary variable that is enabled when 𝜉s (𝑘) is
scheduling horizon [US$] reseted
𝐽bat (𝑘) O&M battery bank costs [US$] 𝛿g (𝑘) Binary variable that is enabled when the power
𝐽p (𝑘) Electricity costs [US$] balance is positive
𝐽pur Total cost of purchase electricity the scheduling 𝛿dex (𝑘) Complement of 𝛿g (𝑘)
horizon [US$] 𝛿hon (𝑘) Binary variable that is enabled when the counter
𝐽s (𝑘) Total revenue from electricity sale during the 𝜉hon (𝑘) is negative
scheduling horizon [US$] 𝛿hoff (𝑘) Binary variable that is enabled when the counter
𝜆(𝑘) Irradiance [W/𝑚2 ] 𝜉off (𝑘) is positive
𝜉s (𝑘) Elapse time for the MG stay connected to the 𝛿pv1 (𝑘) Binary variable that is enabled when the
main grid [min] photovoltaic power is saturated
𝑃g (𝑘) Power balance [kW] 𝛿s1 (𝑘) Binary variable that is enabled when the battery
𝑃pv (𝑘) Photovoltaic power [kW] bank is charged
𝑓
𝑃pv (𝑘) Forecast of the photovoltaic power [kW] 𝛿s2 (𝑘) Binary variable that is enabled when the battery
𝑃w (𝑘) Wind power [kW] bank is not charged and the MG is connected to
the grid
𝑃w𝑓 (𝑘) Forecast of the wind power [kW]
𝛿wi (𝑘) Binary variables that enables the wind turbine
𝑝𝑟𝑜𝑓 𝑖𝑡 Electricity profit [US$]
state i
𝑃 𝑇crt The percentage rate between 𝑇𝑐𝑟𝑡 and the total
𝑜𝑝(𝑘) Binary variable that is enabled when the wind
simulation time [%]
turbine is operating below its rated power
𝑆(𝑘) State of the battery charge [pu]
𝑝𝑛(𝑘) Binary variable that is enabled when the wind
𝑇 (𝑘) Temperature [𝑜 C]
turbine is operating at its rated power
𝑇𝑐𝑟𝑡 Total time period that the SOC remains below the
𝑢g (𝑘) Binary variable that is enabled when the MG
critical SOC [min]
connects to the grid
𝑉 (𝑘) Photovoltaic panel voltage [V]
𝑣w (𝑘) Wind speed [m/s] Linguistic Variables of the Wind Turbine
𝑥w (𝑘) State variable related to the wind power [kW] 𝑥wb (𝑘) Idle,MPPT,Nominal,Cut-off
𝑥pv (𝑘) State variable related to the photovoltaic power 𝑥wb1 (𝑘) Idle state
[kW] 𝑥wb2 (𝑘) MPPT state
Integer and Binary Variables 𝑥wb3 (𝑘) Nominal state
𝑥wb4 (𝑘) Cut-off state
𝜉c (𝑘) Integer variable related to the MG-connections
counter
𝜉hon (𝑘) Integer variable related to the total samples left to
enable the MG connection Declaration of competing interest
𝜉hoff (𝑘) Integer variable related to the total samples left to
enable the MG disconnection
𝑇up (𝑘) Integer variable related to the minimum number The authors declare that they have no known competing finan-
of samples required for the MG remains grid cial interests or personal relationships that could have appeared to
connected influence the work reported in this paper.

18
D.P. e Silva et al. Applied Energy 278 (2020) 115581

Acknowledgments [4] Statistical annual of electricity. Energetic Research Company. URL


www.epe.gov.br/pt/publicacoes-dados-abertos/publicacoes/anuario-estatistico-
de-energia-eletrica. [Accessed 10 May 2020].
The authors thank the financial support received from the State of
[5] Liang H, Zhuang W. Stochastic modeling and optimization in a microgrid: A
Espirito Santo Research Foundation (FAPES), project number 67666027, survey. Energies 2014;7,:2027–50. http://dx.doi.org/10.3390/en7042027.
and the authorization of the Federal Institute of Education, Science, and [6] Nosratabadi SM, Hooshmand RA, Gholipour E. A comprehensive review on
Technology of Espirito Santo (IFES) to carry out this research under the microgrid and virtual power plant concepts employed for distributed en-
ergy resources scheduling in power systems. Renew Sustain Energy Rev
process number 23158.001738/2018-33.
2017;67,:341–63. http://dx.doi.org/10.1016/j.rser.2016.09.025.
[7] Hossain MA, Pota HR, Hossain MJ, Blaabjerg F. Evolution of microgrids with
Appendix A. Adjustment of the wind speed in the turbine converter-interfaced generations: Challenges and opportunities. Int J Electr Power
Energy Syst 2019;109,:160–86. http://dx.doi.org/10.1016/j.ijepes.2019.01.038.
[8] Gonzalez de Durana J, Barambones O. Technology-free microgrid modeling
The height of the wind turbine is different from the height of with application to demand side management. Appl Energy 2018;219,:165–78.
the weather data station. The real wind speed in the wind turbine is http://dx.doi.org/10.1016/j.apenergy.2018.03.024.
recalculated using a logarithmic profile given by [9] Zhang X, Chen B, Cheng Y, Sun S, Wang S. A multi-microgrids system
model considering stochastic correlations among microgrids. Energy Procedia
𝑣 𝑙𝑛(𝐻∕𝑧0 ) 2018;145,:3–8. http://dx.doi.org/10.1016/j.egypro.2018.04.002.
= (A.1)
𝑣0 𝑙𝑛(𝐻0 ∕𝑧0 ) [10] Hanna R, Ghonima M, Kleissl J, Tynan G, Victor DG. Evaluating business
models for microgrids: Interactions of technology and policy. Energy Policy
where 𝑧0 is the roughness length in meters, 𝐻𝑜 is the reference height 2017;103,:47–61. http://dx.doi.org/10.1016/j.enpol.2017.01.010.
in meters corresponding to the speed 𝑣𝑜 in the weather station, and 𝐻 is [11] Magro MC, Giannettoni M, Pinceti P, Vanti M. Real time simulator for microgrids.
the height in meters corresponding to the speed 𝑣 in the wind turbine, Electr Power Syst Res 2018;160,:381–96. http://dx.doi.org/10.1016/j.epsr.2018.
respectively. For the case study, 𝐻 = 15 m, 𝐻0 = 10 m and 𝑧0 = 1 m. 03.018.
[12] Zhu L, Hill DJ. Modeling and stability of microgrids with smart loads.
The height values were obtained at the installation site of the weather IFAC-PapersOnLine 2017;50,:10021–6. http://dx.doi.org/10.1016/j.ifacol.2017.
stations and wind turbine, and the roughness length was taken from a 08.2037.
roughness table [65] classified for urban areas. [13] Parisio A, Rikos E, Glielmo L. A model predictive control approach to microgrid
operation optimization. IEEE Trans Control Syst Technol 2014;22,:1813–27.
http://dx.doi.org/10.1109/TCST.2013.2295737.
Appendix B. Rule-based strategy [14] Garcia-Torres F, Bordons C. Optimal economical schedule of hydrogen-based
microgrids with hybrid storage using model predictive control. IEEE Trans Ind
The rule-based strategy algorithm consists of the following steps: Electron 2015;62:5195–207. http://dx.doi.org/10.1109/TIE.2015.2412524.
[15] Olama A, Mendes PR, Camacho EF. Lyapunov-Based hybrid model predic-
tive control for energy management of microgrids. IET Gener Transm Distrib
1. Monitor the variation rate of the battery charge (SOC) at all 𝑛c
2018;12,:5770–80. http://dx.doi.org/10.1049/iet-gtd.2018.5852.
operation ranges, where 𝑛c is the number of controllable loads. [16] Bemporad A, Morari M. Control of systems integrating logic, dynamics,
These ranges define intervals where the SOC variation rates and constraints. Automatica 1999;35,:407–27. http://dx.doi.org/10.1016/S0005-
are negative to prevent the battery bank from having a deep 1098(98)00178-2.
[17] Elsied M, Oukaour A, Youssef T, Gualous H, Mohammed O. An advanced
discharge.
real time energy management system for microgrids. Energy 2016;114,:742–52.
2. If the SOC’s charge rate is in the range 𝑘, 𝑘 = 1, 2, … , 𝑛c − 1 and http://dx.doi.org/10.1016/j.energy.2016.08.048.
if there are turn on loads, then turn off 1 to k loads gradually, [18] Kumar RH, Ushakumari S. A novel control strategy for autonomous operation of
starting from the lower priority and go to step 3. If the SOC isolated microgrid with prioritized loads. J Inst Eng India: Ser B 2018;99,:323–30.
variation rate exceeds its lowest value, then turn off all loads http://dx.doi.org/10.1007/s40031-018-0335-7.
[19] Wasilewski J. Optimisation of multicarrier microgrid layout using selected
and go to step 3. Otherwise, do not turn off the loads and go to metaheuristics. Int J Electr Power Energy Syst 2018;99,:246–60. http://dx.doi.
step 3. org/10.1016/j.ijepes.2018.01.022.
3. Monitor the SOC state of the batteries and the power balance [20] Gazijahani FS, Salehi J. Integrated DR and reconfiguration scheduling for optimal
(difference between the current demand and the generated RES operation of microgrids using Hong’s point estimate method. Int J Electr Power
Energy Syst 2018;99,:481–92. http://dx.doi.org/10.1016/j.ijepes.2018.01.044.
power). [21] Sharma A, Panigrahi BK. Phase fault protection scheme for reliable operation of
4. Check whether the maximum-allowed number of MG grid con- microgrids. IEEE Trans Ind Appl 2018;54,:2646–55. http://dx.doi.org/10.1109/
nections in a time interval is achieved. In this case, the MG must TIA.2017.2787691.
remain isolated and return to step 1. Otherwise, go to step 5. [22] Herath PU, Fusco V, Caceres MN, Venayagamoorthy GK, Squartini S, Piazza F,
et al. Day-ahead power forecasting in a large-scale photovoltaic plant based
5. If the MG is already connected to the grid, then keep it connected on weather classification using LSTM. IEEE Trans Ind Appl 2019;55,:732–40.
for at least 𝑇up time periods and then return to step 1. Otherwise, http://dx.doi.org/10.1109/TIA.2018.2871390.
go to the next step. [23] Hossain MA, Pota HR, Squartini S, Abdou AF. Modified PSO algorithm for
6. Verify the following connection conditions: (a) The state of the real-time energy management in grid-connected microgrids. Renew Energy
2019;136,:746–57. http://dx.doi.org/10.1016/j.renene.2019.01.005.
battery bank charge is not at its critical value or (b) The RES [24] Tenfen D, Finardi EC. A mixed integer linear programming model for the energy
power generated is higher than the load demand plus the battery management problem of microgrids. Electr Power Syst Res 2015;122,:19–28.
bank charge. If one of the conditions is true, then perform the http://dx.doi.org/10.1016/j.epsr.2014.12.019.
MG grid connection or keep the MG connected to the grid and [25] Liu G, Starke M, Xiao B, Zhang X, Tomsovic K. Microgrid optimal schedul-
ing with chance-constrained islanding capability. Electr Power Syst Res
return to step 1. Otherwise, perform a grid disconnection or keep 2017;145,:197–206. http://dx.doi.org/10.1016/j.epsr.2017.01.014.
it disconnected for a minimum number of samples 𝑇down and [26] Li Z, Xu Y. Optimal coordinated energy dispatch of a multi-energy microgrid
return to step 1. in grid-connected and islanded modes. Appl Energy 2018;158,:6601–6. http:
//dx.doi.org/10.1016/j.apenergy.2017.08.197.
[27] Silvente J, Kopanos GM, Pistikopoulos EN, Espuña A. A rolling horizon opti-
References mization framework for the simultaneous energy supply and demand planning
in microgrids. Appl Energy 2015;155,:485–501. http://dx.doi.org/10.1016/j.
[1] Production of primary energy. EUROSTAT. URL www.ec.europa.eu/eurostat/ apenergy.2015.05.090.
statistics-explained/index.php/Energy. [Accessed 18 May 2020]. [28] Marquant JF, Evins R, Carmeliet J. Reducing computation time with a rolling
[2] Electricity in the United States. EIA. URL www.eia.gov/outlooks/aeo/pdf/ horizon approach applied to a MILP formulation of multiple urban energy hub
AEO2020. [Accessed 18 May 2020]. system. Procedia Comput Sci 2015;51,:11. http://dx.doi.org/10.1016/j.procs.
[3] End of the year wrap-up: five figures show China’s renewable energy growth 2015.05.486.
in 2019. URL www.renewableenergyworld.com/2019/12/01/end-of-the-year- [29] Javier Silvente VD, Papageorgiou LG. A rolling horizon approach for opti-
wrap-up-five-figures-show-chinas-renewable-energy-growth-in-2019. [Accessed mal management of microgrids under stochastic uncertainty. Chem Eng Res
18 May 2020]. 2018;131,:293–317. http://dx.doi.org/10.1016/j.cherd.2017.09.013.

19
D.P. e Silva et al. Applied Energy 278 (2020) 115581

[30] Gu W, Wang Z, Wu Z, Luo Z, Tang Y, Wang J. An online optimal dispatch [46] Palma-Behnke R, Benavides C, Lanas F, Severino B, Reyes L, Llanos J, et al.
schedule for CCHP microgrids based on model predictive control. IEEE Trans A microgrid energy management system based on the rolling horizon strategy.
Smart Grid 2017;8,:2332–42. http://dx.doi.org/10.1109/TSG.2016.2523504. IEEE Trans Smart Grid 2013;4,:996–1006. http://dx.doi.org/10.1109/TSG.2012.
[31] Alramlawi M, Gabash A, Li P. Optimal operation strategy of a hybrid PV- 2231440.
battery system under grid scheduled blackouts. In: IEEE international conference [47] Silva DP, Queiroz MD, Fardin JF, Sales JLF, Orlando MTD. Hybrid modeling of
on environment and electrical engineering and IEEE industrial and commercial energy storage system and electrical loads in a pilot-microgrid. In: 13th IEEE
power systems europe (EEEIC / I CPS Europe). Milan, Italy; 2017, p. 1–5. International Conference on Industry Applications. São Paulo, Brazil; 2018, p.
http://dx.doi.org/10.1109/EEEIC.2017.7977543. 433–8. http://dx.doi.org/10.1109/INDUSCON.2018.8627180.
[32] Romero-Quete D, Garcia JR. An affine arithmetic-model predictive control [48] Kang BO, Park JH. Kalman filter MPPT method for a solar inverter. In: IEEE
approach for optimal economic dispatch of combined heat and power microgrids. power and energy conference at Illinois. Urbana, IL, USA; 2011, p. 1–5. http:
Appl Energy 2019;242,:1436–47. http://dx.doi.org/10.1016/j.apenergy.2019.03. //dx.doi.org/10.1109/EEEIC.2017.7977543.
159. [49] Yan X, Abbes D, Francois B. Uncertainty analysis for day ahead power reserve
[33] Resende M, Cardoso V. Mapping service quality in electricity distribution: An quantification in an urban microgrid including PV generators. Renew Energy
exploratory study of Brazil. Util Policy 2019;56,:41–52. http://dx.doi.org/10. 2017;106,:288–97. http://dx.doi.org/10.1016/j.renene.2017.01.022.
1016/j.jup.2018.08.009. [50] Marinelli M, Sossan F, Costanzo GT, Bindner HW. Testing of a predictive control
[34] Ismail MS, Moghavvemi M, Mahlia TM, Muttaqi KM, Moghavvemi S. Effective strategy for balancing renewable sources in a microgrid. IEEE Trans Sustain
utilization of excess energy in standalone hybrid renewable energy systems for Energy 2014;5,:1426–33. http://dx.doi.org/10.1109/TSTE.2013.2294194.
improving comfort ability and reducing cost of energy: A review and analysis. [51] Shi YT, Qiao SJ, Hou YJ, Li ZJ, Sun DH. Hybrid model predictive control
Renew Sustain Energy Rev 2015;42,:726–34. http://dx.doi.org/10.1016/j.rser. and fault detection of wind energy conversion system based on mixed logical
2014.10.051. dynamic. In: 26th chinese control and decision conference. Changsha, China;
[35] Khakimova A, Shamshimova A, Sharipova D, Kusatayeva A, Ten V, Bemporad A, 2014, p. 782–8. http://dx.doi.org/10.1109/CCDC.2014.6852271.
et al. Hybrid model predictive control for optimal energy management of [52] Bemporad A, Torrisi F, Morari M. Discrete-time hybrid modeling and verification
a smart house. In: IEEE 15th international conference on environment and of the batch evaporator process benchmark. Eur J Control 2001;0,:1–18. http:
electrical engineering. Rome, Italy; 2015, p. 513–8. http://dx.doi.org/10.1109/ //dx.doi.org/10.3166/ejc.7.382-399.
EEEIC.2017.7977543. [53] Olivares DE, Mehrizi-Sani A, Etemadi AH, Cañizares CA, Iravani R, Kazerani M,
[36] Parisio A, Wiezorek C, Kyntaja T, Elo J, Johansson KH. An MPC-based energy et al. Trends in microgrid control. IEEE Trans Smart Grid 2014;5,:1905–19.
management system for multiple residential microgrids. In: IEEE international http://dx.doi.org/10.1109/TSG.2013.2295514.
conference on automation science and engineering. Gothenburg, Sweden; 2015, [54] El-Hendawi M, Gabbar H, El-Saady G, Ibrahim E-N. Control and EMS of a
p. 7–14. http://dx.doi.org/10.1109/CoASE.2015.7294033. grid-connected microgrid with economical analysis. Energies 2018;11,:20. http:
[37] Bruni G, Cordiner S, Mulone V, Sinisi V, Spagnolo F. Energy management //dx.doi.org/10.3390/en11010129.
in a domestic microgrid by means of model predictive controllers. Energy [55] Mazidi M, Zakariazadeh A, Jadid S, Siano P. Integrated scheduling of renewable
2016;108,:119–31. http://dx.doi.org/10.1016/j.energy.2015.08.004. generation and demand response programs in a microgrid. Energy Convers
[38] Clarke WC, Manzie C, Brear MJ. An economic MPC approach to microgrid Manage 2014;86,:1118–27. http://dx.doi.org/10.1016/j.enconman.2014.06.078.
control. In: Australian control conference. Newcastle, NSW, Australia; 2017, p. [56] Crystalline photovoltaic modules installation and operation manual. 2017, URL
276–81. http://dx.doi.org/10.1109/AUCC.2016.7868202. www.axitecsolar.com/data/document_files/Manual_PT.pdf. [Accessed 21 May
[39] Pereira M, Muñoz de la Peña D, Limon D. Robust economic model predictive 2020].
control of a community micro-grid. Renew Energy 2017;100,:3–17. http://dx. [57] Fronius galvo 208-240 operating instructions. 2016, URL www.fronius.com/~/
doi.org/10.1016/j.renene.2016.04.086. downloads/Solar%20Energy/Operating%20Instructions/42%2C0410%2C1934.
[40] Zheng Y, Li S, Tan R. Distributed model predictive control for on-connected pdf. [Accessed 21 May 2020].
microgrid power management. IEEE Trans Control Syst Technol 2017;26,:1–12. [58] GERAR 246 instructions manual. 2016, URL http://www.enersud.com.br/
http://dx.doi.org/10.1109/TCST.2017.2692739. produtos/turbina-eolica-gerar-246/. [Accessed 21 June 2020].
[41] Parisio A, Rikos E, Glielmo L. Stochastic model predictive control for eco- [59] Wind grid tie inverter GCI-2G-W single phase inverter, installation and operation
nomic/environmental operation management of microgrids: An experimental manual. 2018, URL http://ginlong.com/Download/down/id/527.html. [Accessed
case study. J Process Control 2016;43,:24–37. http://dx.doi.org/10.1016/j. 06 November 2018].
jprocont.2016.04.008. [60] Stationary battery technical manual clean nano. 2016, URL www.moura-
[42] Agüera-Pérez A, Palomares-Salas JC, González de la Rosa JJ, Florencias- portal.s3.amazonaws.com/uploads/2017/07/MANUAL_CLEAN_NANO_V13_06_
Oliveros O. Weather forecasts for microgrid energy management: Review, DEZ_16.pdf. [Accessed 21 May 2020].
discussion and recommendations. Appl Energy 2018;228,:265–78. http://dx.doi. [61] National Institute of Meteorology. INMET. www.inmet.gov.br/portal/index.php?
org/10.1016/j.apenergy.2018.06.087. r=estacoes/estacoesAutomaticas. [Accessed 10 May 2020].
[43] Eseye AT, Zhang J, Zheng D. Short-term photovoltaic solar power forecasting [62] Caplan P, Derber J, Gemmill W, Hong SY, Pan HL, Parrish D. Changes to the
using a hybrid wavelet-PSO-SVM model based on SCADA and meteorological in- 1995 NCEP operational medium-range forecast model analysis-forecast system.
formation. Renew Energy 2018;118,:357–67. http://dx.doi.org/10.1016/j.renene. Weather Forecast 1997;12,:581–94. http://dx.doi.org/10.1175/1520-0434(1997)
2017.11.011. 012<0581:CTTNOM>2.0.CO;2.
[44] Skamarock W, Klemp J, Dudhia J, Gil D, Liu Z, Berner J, et al. A description of [63] IEEE application guide for IEEE Std 1547(TM), IEEE standard for interconnecting
the advanced research WRF model version 4. National Center for Atmospheric distributed resources with electric power systems, IEEE Std 1547-2018. 2018, p.
Research; 2019. 1–217.
[45] D. E. Olivares CAC, Kazerani M. Stochastic-predictive energy management system [64] de Oliveira Junior VB, Pena JG, Salles JL. An improved plant-wide multiperiod
for isolated microgrids. IEEE Trans Smart Grid 2015;6,:2681–93. http://dx.doi. optimization model of a byproduct gas supply system in the iron and steel-
org/10.1109/TSG.2015.2469631. making process. Appl Energy 2016;164,:462–74. http://dx.doi.org/10.1016/j.
apenergy.2015.11.043.
[65] Masters GM. Renewable and efficient electric power systems. 2nd ed. John Wiley
and Sons; 2013.

20

You might also like