Abstract
Microgrids are integrated systems that gather and operate energy production units to satisfy consumers' demands. This paper details different mathematical methods to design the Energy Management System (EMS) of domestic microgrids. We consider different stocks coupled together—a battery, a domestic hot water tank—and decentralized energy production with solar panels. The main challenge of the EMS is to ensure, at least cost, that supply matches demand for all time, while considering the inherent uncertainties of such systems. We benchmark two optimization algorithms to manage the EMS and compare them with a heuristic. The Model Predictive Control (MPC) is a well-known algorithm which models the future uncertainties with a deterministic forecast. By contrast, Stochastic Dual Dynamic Programming (SDDP) models the future uncertainties as probability distributions to compute optimal policies. A comprehensive numerical study shows that i) optimization algorithms achieve significant gains compared to the heuristic, and ii) SDDP outperforms MPC by a few percent, with a reasonable computational overhead.
Introduction
Managing a domestic microgrid is a complex balancing act involving variable production from solar panels, multiple storage mediums (chemical batteries and thermal hot water tanks), and unpredictable consumer demands. The core challenge is uncertainty: weather forecasts are imperfect, and human behavior is inherently erratic. An effective Energy Management System (EMS) must make real-time decisions—such as whether to charge a battery or heat water—without perfect knowledge of future solar availability or appliance usage. This paper evaluates which mathematical frameworks best handle these stochastic variables to minimize electricity costs without sacrificing occupant comfort.
System Architecture and Modeling
The domestic microgrid under study integrates several components into a unified energy network. As shown in Figure 1, the system includes a connection to the external electrical network, solar panels for local production, a chemical battery, and thermal storage in the form of a hot water tank.
To accurately capture the house's thermal behavior, the researchers employed an R6C2 electrical analogy (6 resistances, 2 capacitors). This model treats heat flow similarly to electrical current and temperature like voltage, accounting for the building's thermal inertia, which effectively acts as a "passive" battery.
Control Methodologies
The study benchmarks three distinct approaches to managing the microgrid's 4-dimensional state model (battery charge, water tank energy, and two building temperatures):
- Heuristic (Baseline): A rule-based logic that triggers actions based on immediate conditions, such as charging the battery whenever solar production exceeds demand.
- Model Predictive Control (MPC): The current industry standard. MPC uses a deterministic "best guess" forecast to plan a future trajectory. It executes the first step of this plan and then re-calculates the entire trajectory at the next time step to account for new data.
- Stochastic Dual Dynamic Programming (SDDP): A probabilistic approach that avoids relying on a single forecast. Instead, SDDP uses probability distributions to compute "value functions" offline. These functions quantify the future value of energy stored in the battery or tank, allowing for optimal "recourse" decisions when real-world conditions deviate from the mean.
Experimental Results and Discussion
The algorithms were tested using 2015 meteorological data from Meteo France and demand scenarios generated by the StRoBe stochastic simulator. Evaluation followed an "out-of-sample" protocol, where models were trained on 1,000 scenarios and assessed on a separate set of 1,000 scenarios.
Storage Utilization and Efficiency
A key finding was that SDDP utilized the full capacity of the battery and hot water tank more effectively than MPC. While MPC tended toward conservative management, SDDP's probabilistic value functions allowed it to recognize the benefit of storing excess solar energy earlier in the day.
As illustrated in Figure 6, SDDP consistently achieves higher and more uniform state-of-charge levels by the evening compared to the more scattered and lower peaks produced by MPC. This leads to significant cost reductions; both optimization methods outperformed the heuristic by up to 35% in winter, but SDDP specifically outperformed MPC in 93% of summer scenarios.
Computational and Operational Insights
While SDDP requires a significant offline calculation phase (approximately 50 seconds), its online decision-making is exceptionally fast (1.5ms), making it ideal for real-time hardware implementation. Furthermore, both optimization algorithms naturally converged to a single daily charge/discharge cycle, which promotes battery longevity even without explicit aging constraints in the cost function.
Conclusion
This research demonstrates that accounting for the full range of probabilistic uncertainty through SDDP provides a measurable advantage over deterministic MPC in domestic microgrid management. While the performance gap is narrowest during moderate seasons, SDDP excels during summer and winter peaks where forecast errors in MPC are most costly. Future work will focus on hybrid models that combine MPC’s handling of time correlations with SDDP’s risk management, as well as scaling these techniques to neighborhood-level microgrids.
Summary updated