MIcroGrid Modelling
MIcroGrid Modelling
MIcroGrid Modelling
com
ScienceDirect
Available online at www.sciencedirect.com
Procedia Computer Science 00 (2017) 000–000
www.elsevier.com/locate/procedia
ScienceDirect
Procedia Computer Science 114 (2017) 392–400
Complex Adaptive Systems Conference with Theme: Engineering Cyber Physical Systems, CAS
October 30 – November 1, 2017, Chicago, Illinois, USA
Abstract
Complex computer systems and electric power grids share many properties of how they behave and how they are
structured. A microgrid is a smaller electric grid that contains several homes, energy storage units, and distributed
generators. The main idea behind microgrids is the ability to work even if the main grid is not supplying power. That
is, the energy storage unit and distributed generation will supply power in that case, and if there is excess in power
production from renewable energy sources, it will go to the energy storage unit. Therefore, the electric grid becomes
decentralized in terms of control and production. To deal with this change, one needs to interpret the electrical grid
as a system of systems (SoS) and build new models that capture the dynamic behavior of the microgrid. In this
paper, different models of electric components in a microgrid are presented. These models use complex system
modeling techniques such as agent-based methods and system dynamics, or a combination of different methods to
represent various electric elements. Examples show the simulation of the solar microgrid is presented to show the
emergent properties of the interconnected system. Results and waveforms are discussed.
Keywords: Microgrid; SoSs; Wind; Solar; Energy storage; neural networks; modeling; simulation; intelligence
1. Introduction
The current electric power grid suffers aging in both the developing and the developed world. The results of
aging grid and old infrastructures become more pronounced as the number of power outages increases. Old
equipment is prone to failures, and old engineering planning and operation methods are ineffective in tackling
current challenges. To better deal with current challenges, a paradigm shift is needed. Recently, concepts from
system engineering have been adapted to upgrade the electric power. That is, the electric grid can be treated as a
complex system. A complex system is a large collection of interacting elements that act together to perform an
overall nonlinear activity or task. A complex system is not centralized but distributed and self-organized. This paper
investigates various models of microgrid components and treats them as a complex system.
A system of systems is a relatively new concept in system engineering and is becoming a hot topic for researchers
in different fields. Despite the fact that this concept is in its early stages, this concept has achieved widespread use,
such as real-time systems and hardware-in-loop simulations [1]. It was restricted to two main domains: defense and
information technology. Nowadays, it has entered a wide variety of different domains. Although there are different
definitions of SoSs, the most general one That a SoSs are large-scale integrated systems that are diverse and
autonomous, but are working together to achieve a common goal [2]. The main reason for initiating this concept is to
improve either economy or performance. SoSs consist of employable heterogeneous subsystems. The subsystems
can work independently and each one has no power over the other. However, subsystems are connected to
communicate and transmit tasks and achieve an overall mission. Some characteristics distinguish SoSs from a
complex monolithic system, and they are listed in table 1.
Evolutionary development The overall system is not monolithic. Instead, it is flexible to adding new subsystems
Emergent behavior All subsystems work as collective unit to accomplish a big task
Geographic distribution The subsystems are sequentially distributed to facilitate the flow of information
Managerial independence The subsystems are in control for their own operation
3. Microgrid as SoSs
Figure 1 shows an example of a microgrid contains renewable energy sources. The renewable energy sources are
integrated to a dc bus through power electronic interfaces [3-6].One the most important goals of a microgrid is to be
able to work with various types of renewable sources and meet the load demand in case of outages. The subsystems
can communicate with each other to achieve the desired goal [7].
Dc Bus
Energy
Storage
DC/DC Unit
PV
interface
Subsystems 3
Subsystems 1
Main Grid
Wind AC/DC
Power interface
Subsystems 2
Load
Other
Interface
sources
Subsystems N
A complex system can be any system that contains a large number of elements that has distinguishing features
such as a large number of interacting agents, self-organizing collective behavior, decentralization, openness, and
nonlinearity between input and output. The central properties of complex systems are elements and their number,
interactions and their strength, time scale of operations, variability, environment and its demand, and activities and
their objectives. Attributes of complex systems are interdependent, independent, distributed, cooperative,
competitive, and adaptive. Many examples of large-scale systems are built from components, such as internet
networks, global satellite networks, enterprise information systems, and the electric power grid. There are many
similarities between electric grids and complex computer systems so that microgrids can be treated as SoSs
A storage system is a vital element in the microgrid. It operates in the case of an electricity blackout, and it mitigates
the variability of renewable energy sources. Therefore, it is usually placed between the renewable sources and the
load to help the generation match the load demand at any moment, and by doing that, the stability of the system is
assured. The size of battery storage is important, and detailed calculations should be made to meet the demand when
the power from the electric grid is not available. The required battery capacity is given by
where ζ, ηinv and ηbatt are the hourly self-discharge factor, efficiency of inverter, and efficiency of the battery,
respectively; EB(t) and EB(t-1) are the charge quantity of storage system at time t and t-1, correspondingly; and EGA
and EL are the renewable energy power and load demand, respectively. The charge quantity is constrained by
maximum and minimum charge quantities EBmax and EBmin [8], respectively.
Modeling electric load is a very challenging task. The behavior of electric load depends on energy consumption of
various devices that are turned on and off either automatically like air conditioning devices or manually like hair
dryer. Often, electric load is modeled using a constant electric impedance for the sake of simplicity. However, the
load can be modeled using machine learning algorithms or artificial neural networks if more accuracy is required.
There are usually some demand peaks at various times of the day. The peaks are sharp during weekdays, because of
air-conditioning and other high-power devices. Modeling load demand can be simplified as active and reactive
power. The values of apparent power components P and Q are usually pre-set for the sake of simplicity. In this
paper, the load was modeled and considered stochastic. Therefore, load profiles were generated using a feedforward
neural network, as explained in section 5.
IT Ib Rb Id Rd (Ib Id )Rr
(3)
where Ib is normal solar irradiance and Id is diffused solar irradiance. Parameters Rd and Rr are the tilt factors for the
diffused and reflected part of the solar irradiance. The sun position in the sky is the main factor that total solar
irradiance depends on [9]. There are many models for hourly output PV power, which is given by
IT , NOCT
Psj r pc APV ITj 1 Ta IT Tr (4)
( NOCT Ta , NOCT
where ηr is the reference efficiency of the module, ηpc is the efficiency of smoothing and conditioning power, γ is the
factor of density of a cell in module (also called packing factor), κ is the temperature coefficient of the array, APV is
the photovoltaic area, Ta is the instantaneous ambient temperature, Tr is the reference temperature, Tc is the monthly
temperature, and NOCT is the normal operating cell temperature, which Ta,NOCT is 20°C and irradiance is 800W/m2
for a wind speed of 1 m/s. The equivalent circuit of the solar panel is shown in Fig. 2. The solar irradiance can be
forecasted by statistical methods such as autoregressive moving average, or machine learning algorithms such as
support vector machine. In this paper, solar irradiance was modeled using feedforward neural network.
Id Rs
I0 Vd Rsh
Wind speed is a renewable source of energy. Using aerodynamic techniques, one can design a rotor that converts
wind speed into electric power. Although wind speed has some advantages like energy density and an excellent
return on investment, it has some disadvantages like required periodic maintenance, the difficulty of installation, and
intermittency. That is, it has a significantly variable output that is difficult to predict and might cause instability of
the grid operation. To model such a source, we need to model the electric behavior of the wind turbine generator, as
well as characterize of wind speed to capture the fluctuation.
3 r Vci V Vr (6)
PW Vr 3 Vci Vr Vci
Pr Vr V Vco
0 V Vco
Alzahrani, Ahmad / Procedia Computer Science 00 (2017) 000–000
396 Ahmad Alzahrani et al. / Procedia Computer Science 114 (2017) 392–400
where Vr is the rated speed at which the wind turbine generates maximum power, Vci is the cut-in speed at which the
wind turbine generates minimum power, Vco is cut-out speed, and Pr is the rated power. Fig. 3 shows the wind
turbine characterization.
The actual output power of wind turbine after considering the loss and the total swept area is given by
P Pw Aw
(7)
where η is the efficiency of the wind turbine and Aw is the total swept area [10].
Figure 4 shows the overall system modeled using time series neural networks. Each neural network was trained
with labeled data before plugging it into the system. All networks are feedforward networks trained using the back-
propagation algorithm. The solar power was trained using a feedforward neural network with 12 input neurons, 21
hidden neurons, and 1 output, which corresponds to the solar power. The input variables are the solar irradiance, the
corresponding time, the humidity, and the temperature. The previous values of solar irradiance were taken into
account. Choosing the best window size was based on trial and error. The best window size is three. The model was
trained using the Levenberg-Marquardt backpropagation algorithm to update the weight vector. The wind power
was trained using a similar neural network with 15 input neurons, 18 hidden neurons, and 1 output neuron, which is
the wind power. The input to this network is the wind speed and direction, and the corresponding time. Previous
values of wind speed and direction were taken into account to predict the next value of wind power. The wind power
model was trained using the Levenberg-Marquardt backpropagation algorithm, as in solar power modeling.
Modeling the load demand was the most difficult task because load demand contains human behavior of turning on
and off devices which is highly unpredictable, and feature extraction can be a tedious task. However, a feedforward
neural network with more neurons can represent the data. The inputs of the neural networks are power demand,
weather, and corresponding time. The network architecture has 15 input neuron, 25 hidden neurons, and one output
neuron, which is load demand. The best window size is also 3. The storage elements were modeled using a neural
network with 6 input neurons, 12 hidden neurons, and an output neuron, which is the state of charge of the storage
element. The best window size is 2. All of the previous models were trained using labeled data that were
preprocessed and cleaned. Then, this data was divided as follows: 70% of the dataset is for training, 30% for test,
Ahmad Alzahrani et al. / Procedia Computer Science 114 (2017) 392–400 397
Alzahrani, Ahmad / Procedia Computer Science 00 (2017) 000–000
and 15% was for validation. All of the hidden neurons are a hyper tangent activation function, which has a value
between -1 and 1. This is helpful because some variables have two directions such as the battery current, where the
negative current means the battery is charging and positive means the battery is discharging. The activation function
of the output layer is linear function. The training was stopped early to prevent overfitting, and to make the model
have a better generalization. Simulating the microgrid with neural network can make it treated as an SoS, where
each source is an independent and the system is capable of adding extra sources. All sources perform the big task
which is power balance between generation and load demand. Other tasks such as increasing the economic benefits
can also be achieved by controlling these renewable sources.
t, t-1, t-2, t-3
t-3 t-2,t-1, t,
x1(t-3) Time
Time x1(t-3)
Sliding Window
Sliding Window x1(t)
x1(t) Solar Power
Load profile
x2(t-3) Weather
Previous Solar x2(t-3) DC-DC Sliding Window
Irradiance Sliding Window converter
x2(t)
x2(t)
x3(t-3) Previous
Weather x3(t-3)
Sliding Window Power
variables Sliding Window x3(t)
x3(t)
t-3 t-2,t-1, t,
t, t-1, t-2, t-3
Main Grid
6. Control
Several different types of controllers can be found in literature, as shown in Fig. 5. These control techniques are
suitable for working in SoSs. Hierarchical control uses different layers to control the grid. Typically, it consists of
three layers: the primary layer, secondary layer, and tertiary layer. The primary layer is responsible for load sharing
where droop control is used. Also, it is in charge of stabilizing the voltage and frequency. The secondary is in charge
of checking the primary control errors. The tertiary layer monitors the flow from utility to the grid and vice versa
[7]. In this paper, a primary control was implemented to balance the power between generation and load demand.
Microgrid Control
Primary control
Secondary control Tertiary control
(local)
7. Case Study
This section illustrates a practical example of a microgrid. Missouri S&T solar village is a small-scale microgrid
which is consisted of four solar homes tied to the grid. These homes are also backed up by a storage system of two
960 V batteries and a fuel cell. The main aim of this project is to better utilize the energy locally rather than sending
it to the main grid. The overall microgrid is a possession of Missouri S&T and the energy supplier is Rolla
Municipal Utilities (RMU). Currently, Missouri S&T is responsible for the payment the electricity usage, and the
village is occupied by tenants. More information about the smart grid components is listed in Table 2 [11-12]. These
components include a natural gas fuel cell, solar generation, lithium ion battery, and automated smart switchgear
[13]. Figure 6 shows the picture of the microgrid, and Fig. 7 shows the simulation diagram. The solar village is
simulated using Simulink with the same parameters listed in Table 2. Different PV data sources were obtained from
[14-16]. The RMU was considered an ideal source with 13.8 kV and 60 Hz. The transmission line was simulated
using PI section line with non-ideal components. The rest of the system was considered a constant load with active
and reactive power equal to 1 MW and 1 kVAR, respectively. The solar village is connected to the transmission line
using a distribution transformer. The distribution transformer is connected to phase A of the transmission line, and it
is rated for 50 kVA power. The secondary side of the transformer is center tapped, which there are two phases at the
secondary side with the 120V magnitude and opposite polarity. The load profile is the output of a neural network
that was trained using data from [17]. The time resolution of the load profile is one minute.
Table 2: Parameters of the S&T microgrid
Load Rating
Battery storage 60kWh
Bidirectional Inverter 50kW
Fuel cell 5kW
Photovoltaic Panels 2.4kW
EV charging Shed
2009 Solar House 2002 Solar House
station
Phasors
A A a A a A
B B b B b B
C C c C c C
RMU Measurements Transmission Line Rest of the system1
(Other Loads in Rolla)
Single-phase
transformer
loads phase a
only
+ + >L1 L1>
2
1 +
>N N>
3 >L2 L2>
SMART meter
Residential
Transformer To take
N
L1
L2
power from
Missouri S&T smart
RMU
microgrid
7. Simulation Results
This section presents Missouri S&T microgrid simulation. Figure 8 shows the power consumption of each house,
solar power, and generation from RMU. The usual goal is to control the battery and maximize the performance of
the system. However, the battery in this simulation was eliminated so that the system is grid connected without
battery storage. The goal, then, is to reduce the consumption from power grid by using available power from the
solar panels as follows:
Putility Pload PPV (8)
The simulation setup in the previous section was run for 24 hours. The output waveforms after completion are
shown in Fig. 9. The voltage of phase A and phase B is 120 V, equal in magnitude and opposite in polarity. It also
shows the current passing through the distribution transformer, where IA, IB, and IN are the phase A current, phase B
current , and neutral current, respectively. The power consumption seen by the grid at each house is also shown in
Fig. 9., as well as the power loss in the transformer Ptransformer. From the waveforms, one can see that the system is
balanced, and each house utilizes the renewable energy effectively. The voltages are constant and steady, and the
currents are within transformer limits.
Utility Power Solar Power House load
House 1 House 2
15 15
10 10
Power [kW]
5 5
0 0
-5 -5
0 5 10 15 20 25 0 5 10 15 20 25
House 3 House 4
15 15
10 10
Power [kW]
5 5
0 0
-5 -5
0 5 10 15 20 25 0 5 10 15 20 25
Time [Hours] Time [Hours]
Fig. 8. Power at each house: Utility power (green), solar power (red), and house consumption (blue)
Volt
Volt
Volt
Ampere
Ampere
Ampere
IA IB IN 40 40
50 40
20 20 20
0 0 0 0
× 1e4 Power (W) × 1e4 Power (W) × 1e4 Power (W) Power (W)
1.0 Pconsumption Ptransformer
1.0 Pconsumption Ptransformer Pconsumption Ptransformer Pconsumption Ptransformer
0.5 1 5000
Watt
Watt
Watt
Watt
0.5
0.0 0.0 0 0
-0.5
0 2 4 6 × 1e4 0 2 4 6 × 1e4 0 2 4 6 × 1e4 0 2 4 6 × 1e4
Time [s] Time [s] Time [s] Time [s]
Fig. 9. Voltage and current balance at each house
400 Ahmad Alzahrani et al. / Procedia Computer Science 114 (2017) 392–400
Alzahrani, Ahmad / Procedia Computer Science 00 (2017) 000–000
Conclusion
This paper presented modeling and simulation of microgrid. This microgrid was treated as an SoSs and controlled to
be able to utilize different energy sources. A practical example from Missouri S&T was implemented and simulated.
The results were presented and to see that it utilized the renewable energy coming from the solar panels and
optimally distributed it between homes. The neural networks were used to model the output power of microgrid
components. Each component was treated as an autonomous system. These autonomous components were
collaborating to achieve the overall goal, which is supplying the electric load. Simulink model and results are
discussed for grid tied microgrid with no storage element. Future work includes simulating Missouri S&T with the
battery storage elements and implementing battery control algorithm.
References