Efficient day-ahead energy forecasting for microgrids using LSTM optimized by grey wolf algorithm
As distributed energy resources become increasingly integrated into power systems, accurate day-ahead load-forecasting is essential for effective microgrid (MG) management—enabling optimized energy generation, reduced reliance on the main grid. However, forecasting energy demand remains a significan...
| Published in: | e-Prime: Advances in Electrical Engineering, Electronics and Energy |
|---|---|
| Main Authors: | , , , , , |
| Format: | Article |
| Language: | English |
| Published: |
Elsevier
2025-09-01
|
| Subjects: | |
| Online Access: | http://www.sciencedirect.com/science/article/pii/S2772671125001615 |
| _version_ | 1849264371844251648 |
|---|---|
| author | Ahmed Khayat Mohammed Kissaoui Lhoussaine Bahatti Abdelhadi Raihani Khalid Errakkas Youness Atifi |
| author_facet | Ahmed Khayat Mohammed Kissaoui Lhoussaine Bahatti Abdelhadi Raihani Khalid Errakkas Youness Atifi |
| author_sort | Ahmed Khayat |
| collection | DOAJ |
| container_title | e-Prime: Advances in Electrical Engineering, Electronics and Energy |
| description | As distributed energy resources become increasingly integrated into power systems, accurate day-ahead load-forecasting is essential for effective microgrid (MG) management—enabling optimized energy generation, reduced reliance on the main grid. However, forecasting energy demand remains a significant challenge due to its inherent variability, nonlinear temporal patterns. Many existing models rely on external inputs such as temperature forecasts, which are often imprecise and introduce additional uncertainty. Moreover, energy consumption is influenced by delayed thermal responses in buildings, further complicating prediction accuracy. Traditional methods also struggle to capture sharp demand peaks with sufficient precision. To address these limitations, this study introduces a novel hybrid model based on Long Short-Term Memory (LSTM) networks optimized by the Grey Wolf Optimizer (GWO), referred to as LSTM-GWO. Unlike conventional approaches, the LSTM-GWO eliminates the need for exogenous variables by learning intrinsic seasonal patterns directly from historical consumption data. GWO is employed to automatically fine-tune key hyperparameters without manual intervention. The proposed model achieves a Mean Absolute Percentage Error (MAPE) of 8.69 %, with a peak prediction error of only 1.33 %, outperforming traditional baselines. Performance is further validated using Root Mean Square Error (RMSE) and the coefficient of determination (R²), confirming its ability to accurately capture complex temporal dependencies. In addition to its accuracy, the LSTM-GWO demonstrates high stability across multiple independent runs, ensuring consistent performance and reliability. By leveraging only historical load data, this approach reduces forecasting uncertainty, improves peak load anticipation, and provides a practical, efficient, and scalable solution for short-term load-forecasting in dynamic MG environment. |
| format | Article |
| id | doaj-art-e97d4dac61154422a0ec0b5b2713d7ea |
| institution | Directory of Open Access Journals |
| issn | 2772-6711 |
| language | English |
| publishDate | 2025-09-01 |
| publisher | Elsevier |
| record_format | Article |
| spelling | doaj-art-e97d4dac61154422a0ec0b5b2713d7ea2025-09-16T04:36:57ZengElseviere-Prime: Advances in Electrical Engineering, Electronics and Energy2772-67112025-09-011310105410.1016/j.prime.2025.101054Efficient day-ahead energy forecasting for microgrids using LSTM optimized by grey wolf algorithmAhmed Khayat0Mohammed Kissaoui1Lhoussaine Bahatti2Abdelhadi Raihani3Khalid Errakkas4Youness Atifi5Corresponding author.; Electrical Engineering and Intelligent Systems Laboratory (EEIS), ENSET Mohammedia, Hassan II University of Casablanca, MoroccoElectrical Engineering and Intelligent Systems Laboratory (EEIS), ENSET Mohammedia, Hassan II University of Casablanca, MoroccoElectrical Engineering and Intelligent Systems Laboratory (EEIS), ENSET Mohammedia, Hassan II University of Casablanca, MoroccoElectrical Engineering and Intelligent Systems Laboratory (EEIS), ENSET Mohammedia, Hassan II University of Casablanca, MoroccoElectrical Engineering and Intelligent Systems Laboratory (EEIS), ENSET Mohammedia, Hassan II University of Casablanca, MoroccoElectrical Engineering and Intelligent Systems Laboratory (EEIS), ENSET Mohammedia, Hassan II University of Casablanca, MoroccoAs distributed energy resources become increasingly integrated into power systems, accurate day-ahead load-forecasting is essential for effective microgrid (MG) management—enabling optimized energy generation, reduced reliance on the main grid. However, forecasting energy demand remains a significant challenge due to its inherent variability, nonlinear temporal patterns. Many existing models rely on external inputs such as temperature forecasts, which are often imprecise and introduce additional uncertainty. Moreover, energy consumption is influenced by delayed thermal responses in buildings, further complicating prediction accuracy. Traditional methods also struggle to capture sharp demand peaks with sufficient precision. To address these limitations, this study introduces a novel hybrid model based on Long Short-Term Memory (LSTM) networks optimized by the Grey Wolf Optimizer (GWO), referred to as LSTM-GWO. Unlike conventional approaches, the LSTM-GWO eliminates the need for exogenous variables by learning intrinsic seasonal patterns directly from historical consumption data. GWO is employed to automatically fine-tune key hyperparameters without manual intervention. The proposed model achieves a Mean Absolute Percentage Error (MAPE) of 8.69 %, with a peak prediction error of only 1.33 %, outperforming traditional baselines. Performance is further validated using Root Mean Square Error (RMSE) and the coefficient of determination (R²), confirming its ability to accurately capture complex temporal dependencies. In addition to its accuracy, the LSTM-GWO demonstrates high stability across multiple independent runs, ensuring consistent performance and reliability. By leveraging only historical load data, this approach reduces forecasting uncertainty, improves peak load anticipation, and provides a practical, efficient, and scalable solution for short-term load-forecasting in dynamic MG environment.http://www.sciencedirect.com/science/article/pii/S2772671125001615Load forecastingMachine learningMicrogridEnergy managementLong short-term memoryGrey wolf optimizer |
| spellingShingle | Ahmed Khayat Mohammed Kissaoui Lhoussaine Bahatti Abdelhadi Raihani Khalid Errakkas Youness Atifi Efficient day-ahead energy forecasting for microgrids using LSTM optimized by grey wolf algorithm Load forecasting Machine learning Microgrid Energy management Long short-term memory Grey wolf optimizer |
| title | Efficient day-ahead energy forecasting for microgrids using LSTM optimized by grey wolf algorithm |
| title_full | Efficient day-ahead energy forecasting for microgrids using LSTM optimized by grey wolf algorithm |
| title_fullStr | Efficient day-ahead energy forecasting for microgrids using LSTM optimized by grey wolf algorithm |
| title_full_unstemmed | Efficient day-ahead energy forecasting for microgrids using LSTM optimized by grey wolf algorithm |
| title_short | Efficient day-ahead energy forecasting for microgrids using LSTM optimized by grey wolf algorithm |
| title_sort | efficient day ahead energy forecasting for microgrids using lstm optimized by grey wolf algorithm |
| topic | Load forecasting Machine learning Microgrid Energy management Long short-term memory Grey wolf optimizer |
| url | http://www.sciencedirect.com/science/article/pii/S2772671125001615 |
| work_keys_str_mv | AT ahmedkhayat efficientdayaheadenergyforecastingformicrogridsusinglstmoptimizedbygreywolfalgorithm AT mohammedkissaoui efficientdayaheadenergyforecastingformicrogridsusinglstmoptimizedbygreywolfalgorithm AT lhoussainebahatti efficientdayaheadenergyforecastingformicrogridsusinglstmoptimizedbygreywolfalgorithm AT abdelhadiraihani efficientdayaheadenergyforecastingformicrogridsusinglstmoptimizedbygreywolfalgorithm AT khaliderrakkas efficientdayaheadenergyforecastingformicrogridsusinglstmoptimizedbygreywolfalgorithm AT younessatifi efficientdayaheadenergyforecastingformicrogridsusinglstmoptimizedbygreywolfalgorithm |
