A 72-Hour Temperature Forecasting System for Benghazi Using LSTM and Random Forest Models

Authors

  • Esam. Miftah. Abdulnabi. Aboudoumat Computer Department, College of Science and Technology, Qumins, Libya Author
    • Ramadan Ahmed M. Elghalid Department of Computer Science, College of Computer Technology, Benghazi, Libya. Author
      • Ashraf Faraj Saed Albarki Computer Department, College of Arts and Sciences Qumins, University of Benghazi Author
        • Khalifa Mohammed Ballam Computer Department, College of Science and Technology, Qumins, Libya Author

          Keywords:

          Temperature Forecasting, LSTM, Random Forest, Time Series, Machine Learning, ERA5

          Abstract

          Accurate short-term temperature forecasting plays a critical role in urban climate management, energy optimization, and early warning systems. This study proposes a machine learning–based framework for 72-hour ahead maximum temperature prediction in Benghazi, Libya, using Random Forest (RF) and Long Short-Term Memory (LSTM) models. A five-year daily dataset (2021–2025), derived from ERA5 reanalysis and NOAA data, was used. A sliding window approach (30-day lookback) and chronological 80/20 train–test split ensured realistic forecasting conditions. Results show that LSTM outperforms RF with MAE = 1.25°C, RMSE = 1.82°C, and R² = 0.84. Statistical analysis confirms the significance of this improvement (p < 0.001). The proposed system demonstrates strong potential for short-term urban climate forecasting in Mediterranean environments.

          Downloads

          Published

          2026-05-09

          Issue

          Section

          Articles

          How to Cite

          Esam. Miftah. Abdulnabi. Aboudoumat, Ramadan Ahmed M. Elghalid, Ashraf Faraj Saed Albarki, & Khalifa Mohammed Ballam. (2026). A 72-Hour Temperature Forecasting System for Benghazi Using LSTM and Random Forest Models. Al-Imad Journal of Humanities and Applied Sciences (AJHAS), 2(1), 723-730. https://al-imadjournal.ly/index.php/ajhas/article/view/96