Bachelors Program in Electrical Engineering
Smart Grid Technology
•
Bachelor
Microgrids and Distributed Grid Control
Introduction
A microgrid is a group of interconnected loads and distributed energy resources (DERs) within clearly defined electrical boundaries. It can operate while connected to the utility grid or, when necessary, disconnect and operate autonomously as an island. Microgrids are important because they combine distributed generation, energy storage, controllable loads, power electronics, communications, and automation into an actively managed electrical system.
Traditional distribution networks were designed mainly for one-way power flow from large generators to customers. High penetrations of photovoltaic (PV) systems, wind turbines, batteries, electric vehicles, and flexible loads create bidirectional power flows and rapidly changing operating conditions. Microgrids provide a practical framework for coordinating these resources while improving resilience, efficiency, renewable-energy utilization, and power quality.
A successful microgrid design must address both normal and abnormal operation. In grid-connected operation, the utility normally establishes voltage and frequency, while the microgrid exchanges real and reactive power with the distribution network. In islanded operation, local resources must maintain voltage and frequency, balance generation and demand, and respond to faults without relying on the utility.
Learning Objectives
After completing this chapter, the reader should be able to:
Define microgrids and distinguish grid-connected from islanded operation.
Explain hierarchical control using primary, secondary, and tertiary layers.
Select suitable control approaches for inverter-based DERs and storage.
Formulate basic energy-management and power-balance relationships.
Explain synchronization, protection, intentional islanding, and reconnection.
Describe peer-to-peer coordination, virtual power plants, and DER management systems.
Evaluate a microgrid design through a practical engineering case.
Identify cybersecurity, regulatory, safety, and operational limitations.
1. Microgrid Architecture and Operating Modes
A microgrid generally contains five functional elements:
DERs: photovoltaic arrays, wind turbines, microturbines, fuel cells, and other generators.
Energy storage systems (ESSs): batteries, flywheels, supercapacitors, or other storage technologies.
Loads: critical, priority, and noncritical loads, including flexible demand.
Power-conversion interfaces: inverters, rectifiers, DC–DC converters, and transformers.
Control and communication systems: local controllers, supervisory controllers, meters, protection relays, and communication networks.
The point of common coupling (PCC) is the electrical connection between the microgrid and the utility. A static transfer switch or circuit breaker at the PCC permits disconnection and reconnection. The microgrid controller monitors voltage, frequency, power flows, equipment status, forecasts, and market signals.
Microgrid architecture showing utility connection, point of common coupling, distributed resources, storage, loads, and controller
Figure: Microgrid architecture showing utility connection, point of common coupling, distributed resources, storage, loads, and controller
Figure: Functional architecture of a microgrid.
Grid-Connected Operation
In grid-connected mode, the utility grid usually provides the voltage and frequency reference. DERs may operate under active-power, reactive-power, power-factor, or voltage-support commands. The microgrid can import power when local generation is insufficient or export power when generation exceeds local demand.
Advantages include economic dispatch, reduced peak demand, renewable-energy utilization, and ancillary services. However, export limits, reverse power flow, voltage rise, harmonics, and utility protection requirements must be considered.
Islanded Operation
An island forms when the microgrid is electrically separated from the utility but continues supplying some or all local loads. Islanding may be intentional, such as during a planned outage, or unintentional, caused by a utility fault. In an island, the microgrid must establish its own voltage and frequency reference. Energy balance becomes immediate:
Here, PG is local generation power, Pdis and Pch are battery discharge and charge powers, Pgrid is utility import power (zero during islanding), PL is load power, and Ploss represents electrical losses. All terms are in watts or kilowatts, and the equation applies over the same time interval and sign convention.
If generation is lower than demand, frequency tends to fall unless storage, generation, or load shedding responds. If generation exceeds demand, frequency tends to rise or storage must absorb the surplus.
2. Inverter-Based Resources and Microgrid Control
Synchronous generators naturally provide rotating inertia and electromechanical frequency response. Inverters do not inherently possess this behavior, although control software can emulate it. Two broad inverter approaches are common.
Grid-Following Control
A grid-following inverter uses a phase-locked loop (PLL) to estimate the grid angle and injects commanded current. It works well when a strong voltage reference is present, but it is less suitable for a weak grid or an island without a voltage-forming device.
Grid-Forming Control
A grid-forming inverter establishes a voltage waveform and can regulate frequency and voltage in an island. It may use droop control, virtual synchronous-machine control, or direct voltage-source control. Grid-forming resources are particularly important when a microgrid contains mostly inverter-based generation.
Droop Control
A common decentralized strategy is frequency–power and voltage–reactive-power droop. In simplified form:
f = f0 - mP(P-P0)
V = V0 - nQ(Q-Q0)
Here, f and V are controlled frequency and voltage, f0 and V0 are nominal values, P and Q are measured active and reactive power, P0 and Q0 are reference values, and mP and nQ are positive droop coefficients. Units must be selected consistently; for example, mP may be expressed in hertz per kilowatt and nQ in volts per kilovolt-ampere-reactive.
Droop permits multiple sources to share load without high-bandwidth communication. Its disadvantages include steady-state voltage and frequency deviations and imperfect reactive-power sharing caused by feeder impedance differences.
3. Hierarchical Distributed Control
Microgrid control is commonly organized into three layers.
Primary Control
Primary control operates locally and rapidly, typically within milliseconds to seconds. It stabilizes voltage and frequency and provides current limiting, inner current loops, voltage loops, and droop characteristics. It must remain functional even if communication is lost.
Secondary Control
Secondary control restores frequency and voltage toward nominal values and improves sharing accuracy. It may use centralized communication or distributed consensus. For a frequency-restoration command, a controller may adjust the common frequency reference after primary droop has responded. Secondary control is slower than primary control, commonly operating over seconds to minutes.
Tertiary Control
Tertiary control performs optimization, economic dispatch, scheduling, and coordination with the utility or electricity market. It considers fuel cost, battery degradation, renewable forecasts, emissions, import limits, and reserve requirements. Its time scale ranges from minutes to hours.
The layers must be coordinated: tertiary commands should not destabilize primary control, and secondary restoration should not eliminate the intentional power-sharing behavior required for safe operation.
4. Energy Management and Dispatch
The energy-management system (EMS) decides how available resources should meet demand over time. A basic objective is to minimize operating cost while satisfying technical constraints:
The variables include grid-import cost Cgrid,t, local-generation cost CG,t, startup cost Cstart,t, binary commitment state ut, battery degradation cost Cdeg, and battery throughput Ethrough,t. The time index is t, and T is the scheduling horizon. This simplified objective is applicable only when the cost coefficients and operational constraints have been defined consistently.
Important constraints include power balance, generator limits, ramp rates, battery state of charge, reserve, and network limits. A simplified battery state equation is:
Here, SOC is fractional state of charge, ηch and ηdis are charging and discharging efficiencies, Erated is rated energy capacity, Δt is the interval duration, and powers are nonnegative. The formula assumes constant efficiencies during the interval and excludes self-discharge. The result must satisfy SOCmin≤SOCt≤SOCmax.
Worked Example: Battery Dispatch
A battery has rated energy capacity of 100 kWh, initial state of charge 40%, charging power of 20 kW for one hour, and charging efficiency of 90%. Ignoring self-discharge:
ΔSOC = (0.90×20×1)/100 = 0.18.
Therefore, the final state of charge is 40% + 18% = 58%. The stored energy increases by 18 kWh, although 20 kWh is drawn electrically because 2 kWh is lost in charging. The calculation is valid provided the battery’s power and state-of-charge limits are not violated.
Forecast error means that an EMS should preserve reserves rather than schedule every resource to its theoretical limit. Model-predictive control is useful because it repeatedly forecasts, optimizes, implements the first control action, and then updates the solution using new measurements.
5. Synchronization, Islanding, and Reconnection
Before reconnection, the islanded microgrid and utility must have sufficiently compatible voltage magnitude, frequency, phase angle, and phase sequence. A synchronization relay or controller verifies these conditions for a specified time. Closing the PCC breaker with a large phase-angle difference can produce high transient currents and torque disturbances.
A practical sequence is:
Detect that utility conditions are acceptable.
Establish a stable microgrid voltage and frequency.
Measure utility and microgrid phase relationships.
Adjust the grid-forming reference or power exchange.
Confirm phase sequence, voltage, and frequency windows.
Close the PCC breaker under approved protection logic.
Transfer smoothly to grid-connected control.
The exact limits are determined by applicable utility standards, protection studies, equipment ratings, and local regulations; they should not be assumed universally.
6. Protection and Safety
Microgrid protection is more difficult than conventional radial protection because fault current magnitude and direction can change with operating mode. Inverter current limiting may produce fault currents only slightly above rated current, while synchronous generators may produce much larger initial currents.
Protection design should address:
overcurrent, short-circuit, and ground faults;
directional protection for bidirectional power flow;
under/overvoltage and under/overfrequency;
anti-islanding requirements;
arc-flash and touch-voltage hazards;
protection coordination in both grid-connected and islanded modes;
communications failure and breaker failure;
safe maintenance isolation and lockout/tagout.
Adaptive protection can change relay settings when the microgrid changes mode, but it introduces dependence on communications, configuration management, and cybersecurity. Protection should fail safely and should not rely on an unverified communication message.
7. Distributed and Peer-to-Peer Coordination
A centralized controller provides a global view and can optimize the complete system, but it creates a single point of failure and may require extensive communications. Distributed control assigns decisions to local agents that exchange limited information with neighboring agents.
Peer-to-peer coordination can support:
local power sharing;
energy trading among prosumers;
voltage support;
restoration after communication loss;
coordination of geographically distributed storage.
Consensus algorithms allow agents to converge on a shared estimate or decision. For example, each agent may update an estimate using neighboring differences:
xi(k+1)=xi(k)+ε\sumj∈Niaij[xj(k)-xi(k)]
Here, xi is the estimate of agent i, Ni is its neighbor set, aij is a nonnegative communication weight, ε is a suitably chosen step size, and k is the iteration number. Convergence requires appropriate network connectivity and step-size conditions; the equation alone does not guarantee convergence.
Peer-to-peer energy markets may use distributed ledgers or smart contracts, but blockchain is not automatically necessary. Transaction speed, privacy, interoperability, governance, and cyber risk must be evaluated before deployment.
8. Virtual Power Plants and DER Management Systems
A virtual power plant (VPP) coordinates geographically dispersed DERs as though they were one dispatchable resource. A VPP may aggregate batteries, rooftop PV, flexible loads, electric vehicles, and small generators to provide energy, capacity, frequency regulation, or reserve.
A DER management system (DERMS) is a utility- or aggregator-level platform that monitors and coordinates DERs connected to a distribution network. An EMS usually focuses on a facility or microgrid; a DERMS coordinates many sites and must account for feeder voltage, congestion, hosting capacity, and utility operating constraints.
The aggregation process includes forecasting, customer enrollment, telemetry, dispatch, verification, settlement, and performance monitoring. Aggregators must avoid promising the same capacity to multiple services. They must also account for customer comfort, battery warranties, rebound effects, and the uncertain availability of renewable resources.
9. Illustrative Case Study: Hospital Resilience Microgrid
Background
Consider an illustrative 1 MW hospital microgrid with a 600 kW peak critical load, 400 kW of rooftop PV, a 500 kWh battery, and a 750 kW natural-gas generator. The hospital remains connected to the utility during normal operation but must maintain critical services during outages.
Problem
The hospital experiences utility interruptions and wishes to reduce peak demand while preserving medical loads. PV output varies rapidly under passing clouds, and the battery cannot sustain all loads for an extended outage.
Analysis
The design separates loads into critical medical systems, priority building systems, and interruptible services. During grid-connected operation, the EMS schedules the battery to reduce costly peaks and keeps a reserve for forecast error and emergency operation. PV supplies local demand first, subject to voltage and export limits.
When an outage is detected, the PCC opens. A grid-forming battery inverter establishes the island voltage, while the generator starts and assumes sustained generation. PV inverters transition to grid-following operation and reduce output when generation exceeds load. If the battery state of charge approaches its minimum limit, noncritical loads are shed in stages.
For example, if critical demand is 600 kW and PV supplies 250 kW, the generator can provide 350 kW while the battery handles short transients. If the generator is unavailable, the 500 kWh battery alone cannot supply 600 kW for one hour at full rated energy because operating reserves and conversion losses must be retained. This demonstrates why energy capacity and power capacity are distinct design requirements.
Approach and Outcome
The proposed control system uses local inverter controls for fast voltage and frequency regulation, secondary control for restoration, and an EMS for dispatch and load shedding. Dual communications paths are provided, but essential protection remains locally operable. Synchronism-check protection controls reconnection.
The expected outcome is improved ride-through, reduced peak demand, and longer preservation of critical services. The design does not eliminate risk: fuel availability, battery fire safety, cyberattack, common-mode communication failure, and prolonged low-solar conditions remain important concerns.
Learning Points
Resilience requires load prioritization, not merely more generation.
Grid-forming capability is valuable in inverter-dominated islands.
Storage power rating determines instantaneous support; storage energy rating determines duration.
Protection and operating procedures must cover every switching state.
Economic dispatch must not compromise emergency reserve.
10. Design Methodology and Best Practices
A systematic microgrid design process includes:
Define electrical boundaries, objectives, critical loads, and operating modes.
Collect load profiles, fault data, DER characteristics, tariffs, and reliability requirements.
Size generation, storage, converters, conductors, transformers, and switchgear.
Perform load-flow, short-circuit, harmonic, transient, and protection studies.
Select grid-forming and grid-following resources appropriately.
Develop primary, secondary, and tertiary control functions.
Test islanding, reconnection, black start, communication loss, and extreme weather scenarios.
Validate cybersecurity, safety procedures, interoperability, and regulatory compliance.
Commission progressively using hardware-in-the-loop or staged field tests where practical.
Monitor performance and revise models as equipment and operating conditions change.
Interoperability is essential. Devices should use documented data models, time synchronization, secure authentication, role-based access, event logging, and controlled firmware updates. Operators should maintain accurate one-line diagrams, settings records, asset inventories, and recovery procedures.
11. Challenges, Governance, and Contemporary Developments
Microgrids face technical, financial, organizational, and regulatory barriers. Utilities must determine how islanding affects protection, tariffs, hosting capacity, and restoration responsibility. Customers and aggregators must establish ownership of operational data and clarify who may dispatch customer equipment.
Cybersecurity is a safety issue as well as an information-technology issue. A malicious command to open a breaker, disable protection, or alter battery limits can create physical consequences. Defense-in-depth includes network segmentation, least privilege, secure authentication, anomaly detection, backups, incident response, and regular testing.
Artificial intelligence can improve load and renewable forecasting, anomaly detection, and predictive maintenance. However, AI outputs should be bounded by physical constraints and verified before automatic control. Poorly trained models may fail during rare weather, topology changes, or cyberattacks. Human oversight and deterministic protection remain necessary.
Contemporary developments include grid-forming inverters, second-life batteries, vehicle-to-grid operation, DC microgrids, renewable hydrogen systems, and coordinated community microgrids. These technologies increase flexibility but also create new requirements for standards, market rules, safety assessment, and lifecycle management.
Chapter Summary
Microgrids are bounded electrical systems containing DERs, storage, loads, power converters, protection, communications, and supervisory control. Their central capability is the controlled transition between grid-connected and islanded operation. Grid-connected microgrids can reduce costs, support voltage, and exchange power with the utility; islanded microgrids must independently balance generation and demand and establish voltage and frequency.
Hierarchical control separates fast local primary control, voltage and frequency restoration through secondary control, and economic or market coordination through tertiary control. Grid-forming inverters are important for establishing island voltage, while grid-following inverters depend on an existing reference. EMS optimization must include power balance, storage limits, forecast uncertainty, network constraints, and emergency reserves.
Synchronization, adaptive protection, safe switching, cybersecurity, and regulatory compliance are as important as generation capacity. Distributed coordination, VPPs, and DERMS platforms extend microgrid principles to networks of prosumers and utility-connected resources. Effective designs combine technical analysis with load prioritization, operational procedures, interoperability, safety, and continual performance assessment.
Key Terms
Microgrid: A bounded group of loads and DERs capable of coordinated operation and possible islanding.
Distributed energy resource (DER): A small-scale generation, storage, or controllable resource connected near loads.
Point of common coupling (PCC): The electrical interface between a microgrid and the utility.
Islanded operation: Operation of a microgrid while electrically separated from the utility.
Grid-forming inverter: An inverter that establishes a controlled voltage waveform and frequency reference.
Grid-following inverter: An inverter that synchronizes to and injects current into an existing grid waveform.
Droop control: Local control that varies frequency or voltage in response to power changes.
Primary control: Fast local control that stabilizes voltage, frequency, and current.
Secondary control: Control that restores voltage and frequency toward nominal values.
Tertiary control: Supervisory optimization and economic coordination.
Energy-management system (EMS): A system that schedules and dispatches resources within a facility or microgrid.
DER management system (DERMS): A platform for coordinating many distribution-connected DERs.
Virtual power plant (VPP): An aggregation of DERs operated as a coordinated resource.
State of charge (SOC): The available stored energy expressed relative to rated capacity.
Intentional islanding: Deliberate separation from the utility while maintaining local service.
Synchronization: Matching voltage magnitude, frequency, phase angle, and phase sequence before connection.
Adaptive protection: Protection whose settings or logic change with operating conditions.
Peer-to-peer coordination: Distributed control or exchange among participating agents without one central decision-maker.
Critical load: A load whose interruption creates unacceptable safety, health, or mission consequences.
Review Questions
Short Answer Questions
What is the purpose of the point of common coupling?
Why is grid-forming capability important during islanded operation?
Distinguish primary, secondary, and tertiary microgrid control.
What factors must be matched before reconnection to the utility?
Why is microgrid protection more complex than protection of a traditional radial feeder?
Long Answer Questions
Explain the architecture and operating modes of a microgrid, including the roles of DERs, storage, loads, converters, and the controller.
Discuss droop control, including its benefits, limitations, and relationship to hierarchical control.
Formulate and explain an EMS strategy for a microgrid containing PV, a battery, flexible loads, and a utility connection.
Compare centralized, distributed, and peer-to-peer control approaches in terms of reliability, communication, scalability, and optimization.
Explain how a VPP and a DERMS differ and how they can support distribution-system operation.
Analytical / Application Questions
A microgrid has 300 kW of local generation and 420 kW of load. If battery charging and losses are initially zero, determine the battery discharge power needed to maintain power balance during islanding. State the assumptions.
Design an operating sequence for a campus microgrid that detects a utility outage, islands safely, supplies critical loads, sheds noncritical loads, and reconnects after utility restoration.
Critically evaluate whether a hospital should use its battery primarily for tariff reduction or reserve it for resilience. Develop a decision framework that includes costs, outage probability, critical-load duration, battery degradation, and uncertainty.
Multiple Choice Questions with Answers
Question 1
Which device or location defines the electrical boundary between a microgrid and the utility?
A. Point of common coupling
B. Battery management unit
C. Wind-turbine gearbox
D. Load-shedding panel
Correct Answer: A. Point of common coupling
Question 2
Which control layer normally provides the fastest local stabilization of voltage and frequency?
A. Tertiary control
B. Primary control
C. Market settlement control
D. Long-term planning control
Correct Answer: B. Primary control
Question 3
A grid-forming inverter is particularly important because it can:
A. Measure customer tariffs only
B. Establish a voltage and frequency reference
C. Eliminate all harmonic currents
D. Operate without any protection
Correct Answer: B. Establish a voltage and frequency reference
Question 4
A battery has 100 kWh capacity, begins at 40% SOC, and receives 20 kW for one hour at 90% charging efficiency. What is its approximate final SOC?
A. 42%
B. 50%
C. 58%
D. 76%
Correct Answer: C. 58%
Question 5
Which condition is normally checked before closing a microgrid breaker to reconnect to the utility?
A. Matching phase sequence and acceptable phase relationship
B. Maximum battery temperature only
C. Zero load in the microgrid
D. Disconnection of all renewable generation
Correct Answer: A. Matching phase sequence and acceptable phase relationship
Question 6
Why can protection coordination change when a microgrid islands?
A. The loads become purely resistive
B. Fault-current magnitude and direction can change
C. Frequency becomes exactly zero
D. Transformers stop affecting voltage
Correct Answer: B. Fault-current magnitude and direction can change
Question 7
What is the main function of a virtual power plant?
A. To replace every distribution transformer
B. To aggregate dispersed DERs as a coordinated resource
C. To prevent all customer energy storage
D. To provide only physical fuel storage
Correct Answer: B. To aggregate dispersed DERs as a coordinated resource
Question 8
In the battery state equation, charging efficiency less than 100% means that:
A. Stored energy increases by more than input energy
B. Some input energy is lost during charging
C. Battery power is independent of energy capacity
D. SOC must decrease while charging
Correct Answer: B. Some input energy is lost during charging
Question 9
Which feature is characteristic of peer-to-peer coordination?
A. Every decision must be made by one central server
B. Agents exchange information with other agents to coordinate decisions
C. No measurements are required
D. Protection is unnecessary
Correct Answer: B. Agents exchange information with other agents to coordinate decisions
Question 10
Why should AI-based microgrid control remain subject to physical constraints and human oversight?
A. AI cannot process measurements
B. Rare conditions and model errors can produce unsafe commands
C. AI always reduces reliability
D. Physical constraints apply only to generators
Correct Answer: B. Rare conditions and model errors can produce unsafe commands