Next Article in Journal
SHAP-Enhanced Artificial Intelligence Machine Learning Framework for Data-Driven Weak Link Identification in Regional Distribution Grid Power Supply Reliability
Previous Article in Journal
Potential Impacts of Climate Change on South China Sea Wind Energy Resources Under CMIP6 Future Climate Projections
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Optimal Sizing of an Off-Grid Hybrid Energy System with Metaheuristics and Meteorological Forecasting Based on Wavelet Transform and Long Short-Term Memory Networks

by
Yamilet González Cusa
1,
José Hidalgo Suárez
2,*,
Jorge Laureano Moya Rodríguez
1,
Tulio Hernández Ramírez
3,
Silvio A. B. Vieira de Melo
1,4 and
Ednildo Andrade Torres
1,4
1
Industrial Engineering Program, Polytechnic School, Federal University of Bahia (UFBA), Salvador 40210-630, Brazil
2
Electrical Engineering Program, SENAI CIMATEC University, Salvador 41650-010, Brazil
3
Electrical Engineering Program, Polytechnic School, Federal University of Bahia (UFBA), Salvador 40210-630, Brazil
4
Interdisciplinary Center for Energy and Environment (CIENAM), Ondina University Campus, Federal University of Bahia (UFBA), Salvador 40170-115, Brazil
*
Author to whom correspondence should be addressed.
Energies 2025, 18(20), 5371; https://doi.org/10.3390/en18205371
Submission received: 6 September 2025 / Revised: 1 October 2025 / Accepted: 10 October 2025 / Published: 12 October 2025

Abstract

This study proposes an integrated framework for the optimal sizing of off-grid hybrid energy systems, combining photovoltaic panels, wind turbines, battery storage, a diesel generator, and an inverter. The methodology uniquely integrates long-term meteorological forecasting through a hybrid approach based on the Discrete Wavelet Transform and Long Short-Term Memory networks, together with metaheuristic optimization techniques (Particle Swarm Optimization and Genetic Algorithm), to minimize the system’s total annual cost. A case study was conducted in Guanambi, Brazil, using ten years (2012–2021) of hourly data on wind speed, solar irradiance, and ambient temperature. Forecasting results show that the hybrid Discrete Wavelet Transform–Long Short-Term Memory model outperforms the conventional Long Short-Term Memory approach, reducing error metrics and improving predictive accuracy. In the optimization stage, Particle Swarm Optimization consistently achieved lower costs and more stable convergence compared to the Genetic Algorithm. The optimal configuration comprised 450 photovoltaic panels, 10 wind turbines, 66 lithium iron phosphate battery, and 1 diesel generator, yielding a total annual cost of $105,381.17, a cost of energy of $0.1243/kWh, and minimal diesel dependence ($8825.89 annually). The proposed framework demonstrates robustness, economic viability, and applicability for providing sustainable and reliable electricity in isolated regions with high renewable energy potential.

1. Introduction

Electricity supply is essential for community development, serving as a cornerstone of human well-being, social progress, and economic growth [1]. However, conventional fossil fuel-based power generation systems have proven to be unsustainable due to their reliance on finite resources that are progressively being depleted [2]. Global energy demand is expected to increase at an average annual rate of 3.4% through 2026 [3]. In this context, factors such as rising oil prices, technological advances and growing concerns about climate change have significantly driven the search for renewable energy sources (RES) as viable and sustainable alternatives to the current energy model [4]. By the end of 2024, RES accounted for 46% of the world’s total electricity generation capacity [5]. This expansion not only reflects significant progress in the global energy transition but also reinforces energy security and contributes to reducing the environmental impacts associated with conventional energy sources. Despite significant advances in renewable energy deployment, 675 million people still lack access to electricity, especially in remote regions where extending the grid is often economically impractical [6]. Renewable energy sources including wind, solar, and hydropower offer promising solutions to meet the electricity demand in these regions [7]. However, solar and wind energy are subject to limitations such as intermittent generation, weather-related uncertainty, and high initial investment costs [8]. A viable option for addressing these challenges is the incorporation of multiple RES into a hybrid energy system (HES), which leverages the complementarity of resources to ensure greater reliability in electricity supply [9]. In Brazil, several initiatives have demonstrated the capability of hybrid energy systems (HESs) in electrifying isolated communities. Projects that combine renewable sources such as photovoltaic solar energy, wind power, and diesel generators have been successfully integrated into remote regions of the Amazon, coastal islands, and rural areas with limited accessibility [10]. These configurations, often supported by public policies and energy access programs such as the Luz para Todos (Light for All) Program, facilitate the reduction in fossil fuel dependence, enhancing supply reliability, and promoting sustainable local development. However, the optimal sizing of HES components remains a challenge owing to the intrinsic variability of renewable resources, the variability of electricity demand, and the nonlinear behavior of various system elements [11]. Oversizing may lead to excessive investments and economic inefficiency, whereas undersizing can hinder meeting the load demand and compromise energy security [12]. Therefore, it is essential to adopt sizing strategies that combine the integration of multiple energy sources with accurate meteorological forecasting models, with the objective of reducing costs and ensuring operational reliability, and increasing environmental benefits compared to conventional or single-source systems [13].
The key contributions of this study are as follows:
  • The development of an innovative and integrated methodological framework that combines long-term meteorological forecasting using Discrete Wavelet Transform and Long Short-Term Memory (DWT-LSTM) with metaheuristic optimization using Genetic Algorithm (GA) and Particle Swarm Optimization (PSO) for the optimal sizing of off-grid HES. While previous studies have often addressed forecasting models or optimization algorithms independently, this research bridges these two areas into a unified and synergistic approach, validated under real-world conditions.
  • The use of long-term hourly real meteorological data covering a ten-year period (2012–2021), as opposed to the more common use of monthly averages or simplified synthetic datasets. This allows for a more accurate and robust simulation of the system’s long-term operational behavior.
  • The execution of a comprehensive case study in the remote Brazilian region of Guanambi, demonstrating the practical applicability of the proposed methodology for providing sustainable and decentralized energy solutions in regions facing energy vulnerability. The study not only advances scientific knowledge but also offers concrete contributions to decentralized energy planning.
The organization of this article is as follows: Section 2—Literature Review; Section 3—Methodology, which presents the procedures adopted in the development of the study; Section 4—Results and Discussion, presenting the outcomes obtained through the implementation of the algorithms in MATLAB; and Section 5—Conclusions, which presents the main findings and proposes directions for future research.

2. Literature Review

According to Bade et al. [14], the methods employed for sizing HESs can be classified into classical methods, software tools, and modern approaches based on Artificial Intelligence (AI). Classical methods such as graphical [15], probabilistic [16], interactive [17] and analytical techniques [18], despite their simplicity, they have limitations in multivariate problems and in complex search spaces [19]. Tools like HOMER, RETScreen, and TRNSYS are widely used and stand out for their detailed simulation capabilities, but they have restrictions regarding the flexibility for adjustments to their internal optimization algorithms [20,21]. Modern approaches have explored both AI-based algorithms [22] and hybrid models [23]. Among these approaches, metaheuristic optimization algorithms stand out because they are inspired by natural, behavioral, or physical processes. These algorithms are effective in finding approximate solutions to computationally complex problems [24]. These techniques demonstrate enhanced performance over classical methods and software tools, especially regarding computational efficiency and convergence speed, making them the preferred choice for optimizing the sizing and operation of HESs [25,26]. Among them, the GA and PSO are widely applied to address the nonlinear and complex challenges inherent to this type of system [27].
Articles like those of Khatri et al. [28], Lazaar et al. [29] and Namrata et al. [30] applied the GA to the sizing of HESs, demonstrating technically feasible solutions. On the other hand, PSO has proven to be more stable and has converged faster, as shown by [31] and [32] in applications involving solar, wind, battery systems, and diesel generators.
Despite the advances in optimization techniques, most studies still rely on historical meteorological data or monthly averages, without considering hourly forecasting models [33].
This approach can introduce significant errors, as pointed out by Sharma et al. [34] and De Jong et al. [35], who emphasize the importance of hourly variability in renewable energy generation. Abazari et al. [36] highlight that hourly meteorological forecasting techniques based on AI can substantially enhance component sizing and the operational reliability of HESs. However, the efficacy of these techniques is largely determined by the availability of consistent historical data, which remains a challenge in regions with limited or inadequate measurement infrastructure [37]. This issue becomes more critical when long-term datasets are unavailable, since such data are essential for training predictive models capable of identifying complex patterns over extended time horizons. As a result, many studies remain constrained to short-term forecasting, as noted by Singla et al. [38]. Moreover, Wang et al. [39] emphasize that noise and instability in meteorological data further undermine the accuracy of forecasts. In this context, data preprocessing becomes a critical step to improve model accuracy and reduce computational load [40], although few studies have focused specifically on this stage [41]. Wavelet Transform has proven to be effective in this process, enabling the decomposition of time series, noise filtering, and the identification of patterns across time-frequency scales [42,43]. Studies such as those by Alizamir et al. [44] and Singh et al. [45] demonstrate that combining the Wavelet Transform with deep learning models significantly improves forecasting accuracy.
Recent studies have successfully integrated weather forecasting with optimization algorithms. Zhang et al. [46] combined algorithms such as chaotic search, harmony search, and simulated annealing with Artificial Neural Networks (ANN) to incorporate weather forecasts, reducing the Loss of Power Supply Probability as well the life cycle cost. Maleki et al. [47] also used ANN to forecast meteorological variables in an HES designed for water supply, achieving better results with a hybrid approach. Other studies, such as those by Gurubel et al. [48] and Gupta et al. [49], reinforced the importance of accurate forecasting to minimize the total annual cost (CT), using neural networks and metaheuristic algorithms. In addition, recent advances have highlighted the application of risk-averse stochastic optimization in shipboard multi-energy microgrids, addressing operational uncertainties and enhancing system resilience [50]. Likewise, the N-1 evaluation of integrated electricity and gas systems considering cyber-physical interdependence emphasizes the importance of robustness and reliability in modern energy optimization frameworks [51].
Moreover, machine learning techniques such as Gaussian Process Regression, Extreme Gradient Boosting, Decision Trees, and Support Vector Regression were tested for hourly forecasting and were combined with algorithms like Tunicate Swarm Algorithm (TSA) and Aquila Optimization, with TSA standing out as the best performer [34]. Anand et al. [19] validated this approach with real-world data in India. However, ANN models have limitations when applied to long-term forecasting, which has led to the increasing adoption of deep learning techniques such as Recurrent Neural Networks (RNNs), particularly their LSTM and Gated Recurrent Units (GRU) variants, which are capable of capturing long-term temporal dependencies [52,53].
Examples include the work of Medina-Santana and Cárdenas-Barrón [54], who used LSTM models to forecast climate variables and optimize HESs, taking into account economic, social, and environmental criteria. Additionally, in another study [55], RNNs with LSTM and GRU cells were applied to perform weather forecasting and optimize an HES engineered to cover the energy requirements of a desalination system.
The review highlights that the accuracy of meteorological forecasts has a direct impact on optimization effectiveness. However, no previous study has integrated, within a single framework, data preprocessing using DWT, forecasting with LSTM, and optimization using PSO and the GA for off-grid systems. In this context, the present study proposes an innovative approach that combines long-term hourly forecasting through a DWT-LSTM model with optimization using PSO and the GA, validated through a case study in the city of Guanambi, Brazil.

3. Methodology

The methodology for the optimal sizing of the off-grid HES consists of three main stages: data collection, meteorological forecasting, and optimization. Initially, hourly data on solar irradiance, wind speed, and ambient temperature (2012–2021) are collected for the study location. These meteorological variables are used in the forecasting stage, in which two LSTM-based models are compared: one incorporating DWT-based preprocessing and the other without it. The model that exhibits the best performance, evaluated through the Root Mean Square Error (RMSE), Mean Squared Error (MSE), and the coefficient of determination (R2), will be used to estimate the 8760 hourly values for the year. With the forecasted data, the optimization phase begins, involving the definition of the technical specifications and costs of system components, load profile, and an Energy Management Strategy (EMS). Based on these inputs, mathematical models of the HES components are developed, and PSO and the GA are applied to minimize the system’s CT, optimizing the number of photovoltaic panels, wind turbines, and batteries. The PSO algorithm and the GA are compared using metrics such as the minimum value of the objective function and the standard deviation, with the purpose of identifying the most efficient, stable, and cost-effective technique, which is further validated through the application of the Wilcoxon rank-sum statistical test. The optimal configuration, identified by the best-performing algorithm is then simulated for an entire year, assessing load coverage, the contribution of each source, and the fuel cost associated with the diesel generator, to verify the practical and economic feasibility of the proposed system in the study region. The entire process was implemented in MATLAB R2024a and executed on a computer powered by an 11th-generation Intel Core i5 processor with 8 GB of RAM. Figure 1 presents the complete methodological flow, while the following section details each stage.

3.1. Study Site Selection and Data Collection

The selected site for implementing the proposed methodology was the municipality of Guanambi, located in the state of Bahia, Brazil, at the coordinates −14.1521° S latitude and −42.7262° W longitude. This region was chosen particularly due to its high solar irradiance and wind speed potential. Additionally, the availability of reliable meteorological data and the energy challenges typical of remote areas make Guanambi a highly relevant location for assessing the feasibility of the proposed HES.
The hourly meteorological data used in the analysis, solar irradiance (kW/m2), wind speed (m/s at 50 m height), and ambient temperature (°C), were obtained from the official MERRA-2 NASA POWER database [56], widely recognized for its accuracy and reliability. The historical series spans the period from 2012 to 2021, offering a solid and representative foundation for the weather forecasting stage of the study.

3.1.1. DWT-LSTM Model for Weather Forecasting

This section presents the proposed DWT-LSTM forecasting method, which combines data preprocessing and predictive modeling techniques in two main stages:
  • Data preprocessing: The hourly time series of solar irradiance, wind speed, and ambient temperature from 2012 to 2021 was processed using DWT. This technique decomposes the signals into two components: low-frequency approximation and high-frequency detail. The purpose of this decomposition is to reduce noise and emphasize the underlying patterns that may be hidden in the original signal, thereby improving the quality of the forecast.
  • Forecasting using LSTM network: Only the approximation component, representing smoothed versions of the original series, were employed as input to the LSTM prediction model. These components effectively capture both short- and long-term dependencies in the data [57]. Each series consists of 87,672 hourly values, which were randomly partitioned into 80% for training, 10% for validation, and 10% for testing. This distribution ensures robust model training, allows for tuning of hyperparameters through validation, and provides an unbiased performance evaluation on unseen data [58]. These forecasts provide consistent and accurate hourly inputs for the optimization stage, ensuring that system sizing accounts for renewable variability based on realistic scenarios rather than historical averages or synthetic datasets, which often underestimate the stochastic nature of renewable resources. While the methodology does not fully eliminate uncertainty in renewable generation, it substantially mitigates its effects, improving both the economic viability and operational reliability of the hybrid system.

3.1.2. Data Decomposition Using Wavelet Transform

There are two principal types of Wavelet Transforms: the Continuous Wavelet Transform and the Discrete Wavelet Transform (DWT). The DWT was chosen for its computational efficiency and suitability for time series forecasting. It is mathematically defined by Equation (1) [59]:
D W T m , n = 2 m 2 t = 0 N 1 X t ψ t n 2 m 2 m
with m and n representing the scale and translation factors, respectively, N represent the length of the signal X ( t ) , ψ ( t ) indicates the mother wavelet, t is the discrete-time sampling index and the asterisk ( ) denotes the complex conjugate.
The optimal number of decomposition levels can be determined by comparing the approximation signal to the original signal [60].
Following Arseven and Çınar [61], a single-level decomposition was adopted, as it has been shown to provide sufficient predictive performance. The Daubechies wavelet of order 6 (db6) was selected due to its demonstrated effectiveness in detecting discontinuities in temporal signals. Moreover, its consistent performance in the analysis of complex dynamic signals, as reported by [62,63], further underscores its suitability for forecasting applications. Only the approximation signal (a1) was retained for use in the LSTM model, while the detail component (d1) was discarded [41,46,63]. Alternative wavelet families and decomposition levels were not considered, as they fall outside the scope of this study.

3.1.3. Forecasting Using LSTM

The core component of the LSTM network is the memory cell, which can retain temporal state information. The LSTM cell can add or remove information from the cell state through three control gates: the forget gate, the input gate, and the output gate. The forget gate determines which information should be discarded from the cell state, retaining only the relevant content. The input gate manages the flow of new information into the cell, updating its state, while the output gate controls the information flow from the cell state to the output [64].
Figure 2 illustrates the structure of the LSTM cell. The variable c t represents the internal cell state, f t , i t , and o t are the activation vectors for the forget gate, input gate, and output gate, respectively; x t is the input vector; h t 1 is the previous hidden state; c t 1 is the previous cell state; and c ~ t is the candidate cell state. The output of the LSTM cell is the hidden state h t . The mathematical formulation describing the LSTM structure is presented in Equations (2)–(7) [65]:
f t = σ   W f h t 1 , x t + b f
i t = σ   W i h t 1 , x t + b i
o t = σ   W o h t 1 , x t + b o
c ~ t = t a n h   W c h t 1 , x t ) + b c
c t = f t   c t 1 + i t   c ~ t
h t = o t t a n h c t
where σ x denotes the sigmoid activation function, t a n h x represents the hyperbolic tangent activation function, W refers to the weight matrices, b is the bias vector, and denotes the multiplication operation of corresponding elements of matrix.
The model was trained over 160 epochs using a single hidden layer composed of 200 units, facilitating the network’s ability to capture complex patterns in the time series data. The training process employed the Adam optimizer, designed to adaptively tune the learning rate for each parameter, improving convergence efficiency [44]. The initial learning rate was set at 0.005 and followed a piecewise schedule, being reduced by a factor of 0.2 every 125 epochs to support progressive model adaptation. Additionally, a gradient clipping threshold of 1 was employed to prevent gradient explosion and preserve training stability. Table 1 presents the hyperparameters used during the LSTM model training.

3.1.4. Statistical Metrics for Accuracy Assessment

To evaluate the performance of the proposed DWT-LSTM forecasting model in comparison with the standard LSTM model, the predicted data from both models were evaluated against the actual historical meteorological data from the year 2021. Performance metrics such as RMSE, MSE and R2, were calculated to quantify the forecasting accuracy, as defined by Equations (8)–(10). [66]:
R M S E = 1 M i = 1 M y i y ^ i 2
M S E = 1 M i = 1 M y i y ^ i 2
R 2 = 1 i = 1 M y i y ^ i 2 i = 1 M y i y m e a n 2
where y i , y ^ i , y m e a n and M represent the actual value, predicted value, mean of actual values, and the number of samples, respectively. Lower MSE and RMSE values indicate greater model efficiency, while R2 close to 1 reflects better fit quality.

3.2. Mathematical Model of Hes Components

As depicted in Figure 3, the HES consists of a combination of photovoltaic (PV) panels, wind turbine (WT), battery storage (Btt), a diesel generator (DG), and an inverter (Inv). The following subsections concisely present the mathematical models that describe the dynamics of each of these components, followed by the EMS responsible for coordinating the operation of the system components.

3.2.1. Mathematical Formulation of the Photovoltaic (PV) System

In this study, a simplified model was adopted to estimate the hourly power output of the photovoltaic panels, using only ambient temperature and solar irradiance as input variables, as shown in Equation (11) [7].
P P V ( t ) = P P V r × G ( t ) G S T C × 1 + K T T c ( t ) T C , S T C
with P P V ( t ) representing the PV output power in (kWh), P P V r is the rated PV power in kW, G ( t ) refers to the predicted solar irradiance in kW/m2, G S T C denotes the solar irradiance under standard test conditions (STC) in kW/m2, T c , S T C denotes the cell surface temperature under STC in °C and K T is the temperature coefficient associated with the maximum power output, with a value of −3.7 × 10−3 (°C−1) for both monocrystalline and polycrystalline silicon (Si) solar cells [7].
The cell temperature T c ( t ) is given by Equation (12) [67].
T c   ( t ) = T a ( t ) + N O C T 20 0.8 · G ( t )
where T a ( t ) is the predicted ambient temperature in °C and N O C T represents the nominal operating cell temperature of the panel in °C.
The total energy produced by a PV array is given by Equation (13) [68], where n P V is the number of PV panels.
E P V ( t ) = P P V ( t ) × n P V
This study considers photovoltaic modules from the manufacturer Sunova, model SS-550-72-MDH [69]. The technical specifications of the selected PV panel are presented in Table 2.

3.2.2. Mathematical Formulation of the Wind Turbine (WT)

Since wind speed data is typically measured at heights different from the turbine hub height, this study applies the Power Law to extrapolate wind speed to the turbine’s hub height of the turbine, as presented in Equation (14) [70].
V Z , t = V 0 , t h Z h 0 α
where V Z , t represents the wind speed at the turbine hub height ( h Z ) at time t (m/s), and V 0 , t is the wind speed at a reference height ( h 0 ) of 50 m at time t (m/s). The exponent α , known as the Hellmann coefficient, accounts for wind shear and depends on terrain characteristics and atmospheric stability. The most commonly used value is 1/7 (approximately 0.143), particularly in areas with low surface roughness and good wind exposure [71].
The hourly output power of each wind turbine P W T t , in kWh, is determined by Equation (15) [72].
P W T ( t ) =   0                                               V Z , t   V c u t i n   o r   V Z , t V c u t o f f ,   P W T r                                                                       V r a t     V Z , t V c u t o f f ,     P W T r V Z , t V c u t i n V r a t V c u t i n     V c u t i n V Z , t V r a t ,
where P W T r , represents the rated power of the wind turbine (kW), V r a t is the rated wind speed (m/s) at which the turbine reaches its maximum output, V c u t i n is the cut-in wind speed (m/s), from which energy generation begins, and V c u t o f f is the cut-off wind speed (m/s), above which the turbine is shut down for safety reasons.
The total energy generated by a set of wind turbines can be expressed by Equation (16) [68], where n W T is the number of WT.
E W T t = P W T t × n W T
The wind turbine selected for this study is the E20-HAWT model [73], and its technical specifications are presented in Table 3.

3.2.3. Mathematical Formulation of the Battery Storage (Btt)

The state of charge (SOC) of the battery is a critical parameter that directly influences system performance and indicates the available battery capacity. Within this framework, the SOC operates under two modes: charging and discharging. The battery enters charging mode when the energy generated by renewable sources exceeds the demand, while it enters discharging mode when the generated energy is insufficient to meet the load. The amount of energy charged and discharged at a given time t is determined by Equations (17) and (18), respectively [27]:
  • Charging mode, if; E r e n ( t ) > P L O A D ( t )
B t t t = B t t t 1 × 1 σ + E r e n   t P L O A D ( t ) η i n v η c h
  • Discharging mode, if; E r e n ( t ) < P L O A D ( t )
B t t t = B t t t 1 × 1 σ P L O A D t η i n v E r e n   t 1 η d i s c h
where B t t t and B t t t 1 are the battery charge levels at times t and t 1 , respectively (kWh), σ represents the hourly self-discharge rate, P L O A D ( t ) is the hourly load demand (kWh), E r e n ( t ) refers to the energy generated from renewable sources ( E P V ( t ) + E W T ( t ) ) in kWh, η c h and η d i s c h denote the battery charging and discharging efficiencies, respectively, while η i n v represents the inverter efficiency.
Equation (19) defines the SOC limits [7].
B t t m i n   B t t t     B t t m a x
where B t t m i n and B t t m a x represent the minimum and maximum battery charge levels, respectively. The maximum charge level is defined based on the battery’s rated capacity ( S B t t ) while the minimum charge level is assumed to be 10% of the maximum state. The battery adopted in this study is a Lithium Iron Phosphate (LiFePO4) type [74], known for its safety, long lifespan, and thermal stability. This battery technology is widely used in residential energy systems and electric vehicles [75]. Technical specifications are provided in Table 4.

3.2.4. Mathematical Formulation of the Diesel Generator (DG)

For the DG, a generator with a maximum power output of 150 kW is considered capable of fully meeting the load demand. It operates as a backup source to cover energy deficits not met by solar, wind, or battery sources. The fuel consumption of the diesel generator F D G ( t ) in L/h can be calculated using Equation (20) [76].
F D G ( t ) = ( α D G P D G ( t ) + β D G P D G r )
where P D G ( t ) represents the actual power generated (kW), P D G r is the rated power of the generator (kW), and α D G and β D G are the coefficients of the diesel generator’s fuel consumption curve, with values of 0.246 L/kWh and 0.08145 L/kWh, respectively [27,76].

3.2.5. Mathematical Formulation of the Inverter (Inv)

The number of inverters required for the HES is determined using Equation (21) [77].
n I n v = P M H E S P I n v r
where P M H E S represents the maximum power generated by the components connected to the inverter, expressed in kW, and P I n v r corresponds to the rated capacity of the inverter (kW). The inverter parameters include a maximum efficiency of 90% and a rated power of 300 kW [78].

3.3. Energy Management Strategy (EMS)

The EMS adopted in this study, as shown in Figure 4, aims to efficiently coordinate the operation of the hybrid system components, prioritizing the use of renewable sources to meet the load demand while reducing dependence on the diesel generator. When renewable generation (solar and wind) is sufficient, the energy is consumed directly to satisfy the demand, and excess energy is stored in the batteries. If the batteries are fully charged, the excess energy is directed to a dump load. When renewable generation is inadequate to meet the load, the batteries supply the stored energy, and if a deficit still remains, the diesel generator is activated. This strategy ensures continuous power supply, maximizes the utilization of available resources, and contributes to reducing operational costs and emissions.

3.4. Assumptions, Limitations, and Uncertainties

3.4.1. Assumptions

Fixed costs: The values associated with the initial investment, system operation and maintenance, DG fuel price, as well as interest and inflation rates, are assumed to remain constant throughout the analysis period.
Constant load profile: A daily constant load profile is assumed across the entire simulation horizon, disregarding seasonal or behavioral variations in energy demand.

3.4.2. Limitations

Lack of sensitivity analysis: No sensitivity analysis was conducted to assess the impact of variations in system design and operational parameters.
Scalability constraints: The optimization framework was adapted to the specific characteristics of the selected case study location and may require methodological or parametric adjustments for application in other regions or in systems of substantially different scales.
Restricted comparison of forecasting models: The forecasting stage was compared only to the conventional LSTM model, an intentional choice to highlight the incremental contribution of integrating the Discrete Wavelet Transform (DWT) into LSTM.
Lack of dedicated seasonal analysis: Despite the use of ten years of hourly data, which implicitly capture seasonal and interannual variability, no specific analysis was carried out to evaluate system performance under different seasonal conditions.
Simplified load profile: The load profile was modeled as variable over 24 h but kept constant throughout the year, not adequately reflecting seasonal variations in demand.
Unmodeled component degradation: The natural degradation of equipment over time was not explicitly considered, which may compromise the accuracy of long-term performance and cost estimates, although replacement times for critical components such as batteries and the inverter were included in the economic analysis.
The last two assumptions were adopted to keep the model transparent and focused on the proposed forecasting and optimization methodology, avoiding additional complexity related to demand-side uncertainties and long-term degradation modeling.

3.4.3. Uncertainties

Exchange rate variability: Currency fluctuations pose a significant uncertainty, especially since many system components and materials may be tied to international markets.
Unforeseen events: The model does not account for unexpected events, such as critical equipment failures or changes in regulatory policies, which could compromise system operation or economic feasibility.
Forecasting and optimization models: The choice of forecasting and optimization models, along with the estimation of their parameters, may introduce uncertainties affecting the predictive performance and accuracy of the results.

3.5. Hes Optimization Problem

3.5.1. Objective Function and Decision Variables

In this study, the CT is defined as the objective function to be minimized, as indicated in Equation (22). To achieve this, three decision variables—the number of photovoltaic panels ( n P V ), wind turbines ( n W T ), and batteries ( n B t t )—must be optimized.
J = M i n i m i z e   C T ( n P V , n W T , n B t t )
The optimization is subject to predefined lower and upper bounds for each decision variable, aiming to ensure technical feasibility and computational efficiency, as described in Equation (23).
n x , m i n n x n x , m a x     x   ( P V ,   W T , B t t )
where n x represents the quantity of system component type x , and n x , m i n and n x , m a x are the minimum and maximum allowed values, respectively, as defined in Table 5.

3.5.2. Cost Functions

  • Total annual cost (CT)
The CT is the objective function of this study and comprises the sum of the following components: Annual capital ( C C A P ) , annual operation and maintenance cost ( C O & M ) , and annual fuel cost ( C F U E L ) consumed by the DG, as expressed in Equation (24) [79].
C T ( $ / y e a r ) = ( C C A P + C O & M + C F U E L )
  • Annual capital cost (CCAP)
The capital cost annualizes the initial investment, which includes the acquisition, transportation, and installation of system components, through the capital recovery factor (CRF), calculated using Equations (25) and (26) [36].
C R F ( i r , m ) = i r 1 + i r m 1 + i r m 1
i r = i f 1 + f
where i r is the real annual interest rate; m is the project lifetime, assumed as 20 years; i is the nominal interest rate (11.75%) [80]; f is the annual inflation rate (4.51%) [81]. The PV, WT, and DG systems are assumed to last for the entire project duration. However, batteries, with a 16-year lifespan, are replaced once over the study horizon. The present cost of batteries ( C B t t p ) is calculated using the present value factor for a single payment, as shown in Equation (27) [82].
C C B t t p = P B t t 1 + 1 1 + i r 16
where C B t t p represents the cost of the battery ($/kWh) and P B t t is the initial cost of the battery ($/kWh).
Similarly, the inverter, assumed to have a 10-year lifespan, is also replaced once as per Equation (28):
C I n v p = P I n v 1 + 1 1 + i r 10
where C I n v p represents the cost of the inverter ($/kW) and P I n v is the initial cost of the inverter ($/kW).
The total annual capital cost of the HES is then calculated using Equation (29):
C C A P $ / y e a r = C R F × ( C P V × P P V r × n P V + C W T × P W T r × n W T + C B t t p × S B t t   × n B t t + C I n v p × P I n v r   × n I n v + C D G × P D G r )
where C P V , C W T , and C D G are the unit costs ($/kW) of PV, WT, and DG, respectively; P P V r , P W T r , P D G r , P I n v r , a n d   S B t t are the rated power or capacity (kW or kWh) of PV, WT, DG, inverter, and battery, respectively.
  • Annual operation and maintenance cost (CO&M)
The C O & M of the HES is calculated using Equation (30):
C O & M $ / y e a r = C O & M   P V × P P V r × n P V + C O & M   W T × P W T r × n W T + C O & M   B t t × n B t t + C O & M   D G × t = 1 8760 P D G ( t )
where C O & M _ P V and C O & M _ W T are the O&M costs per kW/year for PV and WT; C O & M _ B t t is the O&M cost per battery unit per year; C O & M _ D G is the O&M cost per kWh for DG and P D G t is output power of DG at hour t. The inverter’s O&M cost is excluded as per Maleki and Pourfayaz [82] and Yimen et al. [68].
  • Annual fuel cost (CFUEL)
The C F U E L for the diesel generator is calculated using Equation (31) [7].
C F U E L ( $ / y e a r ) = C f t = 1 8760 F D G ( t )
where C f is the cost of diesel fuel per liter and F D G ( t ) is the fuel consumption at time t.
  • Cost of energy (COE)
The COE generated by the system is a key indicator for evaluating the project’s economic viability. It is calculated using Equation (32) [78].
C O E ( $ / k W h ) = C T E L
where E L is the yearly demand energy (kWh/year).
Table 6 provides the costs related to the components of the HES.

3.6. Optimization Methods

The optimal sizing of an HES is a complex problem that requires robust algorithms to ensure reliable results. In this context, metaheuristic algorithms such as PSO and GA stand out as some of the most widely used approaches for HES optimization [7]. This section presents the operation of these techniques.

3.6.1. Particle Swarm Optimization (PSO)

The PSO algorithm begins with a group of particles randomly positioned within the search space, seeking the optimal value by updating two best-known positions in each iteration. The first is the p b e s t , which represents the best value reached so far by each individual particle, and the second is the best value found by the entire population, known as the global best or g b e s t [23]. With these two values determined, each particle updates its velocity and position using Equations (33) and (34) [87].
v i k + 1 = ω v i k + c 1 r 1 p b e s t i ( k ) x i k + c 2 r 2 g b e s t ( k ) x i k       i = 1 n
x i k + 1 = x i k + v i k + 1       i = 1 n
where v i k + 1 is the velocity of particle i at iteration ( k + 1 ) , v i k is the velocity at iteration k , ω is the inertia weight, c 1 and c 2 are the cognitive and social acceleration coefficients, respectively, r 1 and r 2 are random numbers between 0 and 1, x i k is the position of particle i at iteration k , p b e s t i ( k ) is the best previous position of particle i at iteration k and g b e s t ( k ) is the best global position found by the swarm at iteration k .
The implementation of the PSO algorithm follows a sequence of systematic steps. Initially, the algorithm’s parameters are defined, such as swarm size, inertia weight, and cognitive and social acceleration coefficients. Next, the particles are randomly initialized with positions and velocities within the defined search space. Each particle has its fitness value evaluated using the objective function, which represents the CT of the hybrid system. Based on these values, each particle updates its personal best position ( p b e s t i ) and the swarm’s global best position ( g b e s t ). Using this information, the velocity and position vectors of each particle are recalculated according to the model equations. This process is repeated iteratively until the stopping criterion is met, which may be the maximum number of iterations or convergence of the solution. Finally, the algorithm returns the best solution found for the optimization problem.

3.6.2. Genetic Algorithm (GA)

This algorithm is a metaheuristic technique inspired by the theory of natural evolution, utilizing the principles of selection, crossover, and mutation to find optimal or near-optimal solutions for complex optimization problems [88]. In the GA, an initial population is randomly generated, and individuals evolve over generations to search for solutions that minimize the objective function. The evolution process is driven by genetic operators that simulate biological mechanisms: the selection of the fittest individuals, the exchange of genetic material (crossover), and the introduction of variability through mutation.
Implementation of the GA involves a sequence of steps designed to iteratively improve candidate solutions. Initially, the algorithm’s control parameters are configured, including population size, crossover rate, mutation rate, and the maximum number of generations. The process begins with the random generation of an initial population within the defined search space. Each individual is then evaluated using the objective function—in this case, the CT to be minimized. Based on fitness values, the best-performing individuals are selected to pass their genetic material to the next generation. The crossover operator is applied to these selected individuals to produce offspring, followed by a mutation step where small random changes are introduced to preserve genetic diversity and avoid premature convergence. The current population is then replaced by the new generation. After each cycle, the algorithm checks whether the stopping criterion has been met, which may be the maximum number of iterations or convergence of the solution. Finally, the algorithm returns the best solution found for the optimization problem.
Table 7 presents the parameters employed in the proposed optimization techniques. The selection of these parameters was based on an empirical tuning approach.

4. Results and Discussion

4.1. Meteorological Data

The average annual values recorded in Guanambi were 7.14 kWh/m2/day for solar irradiance, 5.91 m/s for wind speed, and 26.17 °C for temperature, highlighting the region’s potential for solar and wind energy generation. Figure 5 shows the variation in these parameters over the analyzed decade, emphasizing seasonal trends and fluctuations due to local climatic factors.
To provide a deeper analysis, Figure 6 presents the monthly averages of the variables studied over the ten-year period. It can be observed that solar irradiance, represented by blue circles, is highest from December to February, making these months the most favorable for solar energy generation.
Conversely, from May to July, solar irradiance is lower, indicating reduced solar efficiency during this darker period of the year. Wind speed, shown as black squares, suggests that July to September are the most suitable months for wind energy generation, corresponding to the windiest season, while the period from October to April shows less favorable conditions due to lower wind speeds, marking the calmer season. Temperature, represented by red triangles, gradually increases from May, peaks in September, and then decreases toward the end of the year. The complementarity between solar irradiance and wind speed strengthens the system’s viability, enabling efficient and uninterrupted use of renewable sources year-round. However, the seasonal variability underscores the importance of optimized system sizing and the potential integration of batteries or auxiliary generators to mitigate fluctuations during periods of lower energy generation, ensuring a stable and reliable energy supply.

4.2. Load Profile

Load demand variability is one of the main challenges in the optimal sizing of HESs, as it is influenced by climatic conditions, consumption patterns, and the introduction of new technologies. Due to the unavailability of real hourly data for the study area, a typical daily load profile was adopted [89], which was converted into a synthetic series of 8760 h, representing the consumption of 30 residential units. The simulated average annual load was 96.65 kW, with a peak demand of 150 kW. Figure 7 shows the estimated load curve for a typical day.

4.3. Results of Meteorological Variable Forecasting

4.3.1. Data Decomposition Using DWT

The original hourly time series data for solar irradiance, wind speed, and ambient temperature were processed using the DWT with the Daubechies wavelet (db6), applying a single level of decomposition. To illustrate this process, data from January 2012 were used, as shown in Figure 8, Figure 9 and Figure 10. Each original signal, denoted as “S”, was decomposed into two components: the approximation signal (“a1”), which preserves long-term variations and reduces noise, and the detail signal (“d1”), which captures peaks and stochastic fluctuations. As evidenced in Figure 8, Figure 9 and Figure 10, the main oscillations in solar irradiance, wind speed, and ambient temperature are reflected in the approximation component, which maintains a high similarity to the original signal. Therefore, the approximation signals were used as input for modeling and forecasting with the LSTM model.

4.3.2. Validation and Evaluation of the DWT-LSTM Model

Figure 11, Figure 12 and Figure 13 compare the actual and predicted values of solar irradiance, wind speed, and ambient temperature using the DWT-LSTM model for December 2021. The visual alignment between the predicted and actual data demonstrates the model’s high accuracy.
As summarized in Table 8, the DWT-LSTM outperformed the standard LSTM based on the RMSE and MSE metrics, confirming the effectiveness of wavelet-based preprocessing in enhancing forecasting performance. Figure 14 reinforces these findings by showing a strong correlation and high R2 values, above 0.98 for all variables. These improvements in forecasting accuracy directly contributed to the reliability and efficiency of the HES optimization stage.

4.4. Hes Optimization Results

After the meteorological variable forecasting stage, the optimal sizing of the off-grid hybrid energy system was carried out considering three distinct configurations: PV/WT/Btt/DG, PV/Btt/DG, and WT/Btt/DG. For this purpose, the metaheuristic algorithms PSO and the GA were applied, each executed 30 times with identical control parameters to ensure a fair comparison between the methods. The computation time required by each algorithm was not considered a selection criterion. The optimal solution was defined as the one that yielded the lowest value of the objective function, represented by the CT.
Figure 15 presents the convergence curves of the PSO algorithm and the GA for the three configurations analyzed. In all cases, PSO demonstrated superior performance, quickly reaching the minimum value of the objective function and maintaining stability throughout the iterations. Specifically, PSO converged to the optimal solution within the first few iterations (between the 2nd and 3rd), while GA showed greater variability and required more iterations to stabilize. Although the comparison between methods is based on the minimum CT, the results confirm the superior efficiency and consistency of PSO across all evaluated configurations.
A comparison of the results from the PSO algorithm and the GA for various HES configurations is presented in Table 9. It is important to note that all analyzed configurations considered the use of a 150 kW diesel generator (DG). The PV/WT/Btt/DG configuration achieved the lowest values for CT and COE when optimized with the PSO algorithm, reaching $105,381.17 per year and $0.1243 per kWh, respectively. The optimal sizing found by PSO includes 450 PV systems, 10 WTs, and 66 Btt units. In comparison, the GA resulted in a configuration with slightly fewer PV systems (448) and Btt units (65), while maintaining the same number of WTs (10).
For the WT/Btt/DG configuration, the PSO algorithm yielded slightly lower CT and COE values than those obtained by the GA, with $162,281.84 per year and $0.1915/kWh, respectively. Both algorithms converged to the same number of WTs (16), but differed in the number of batteries: 45 units for PSO and 47 for the GA.
In the PV/Btt/DG configuration, PSO also outperformed the GA, with slightly lower CT and COE values of $312,043.75 per year and $0.3682/kWh, respectively. Both algorithms converged to the same number of PV systems (450), differing only in the number of batteries: 50 units for PSO and 49 for the GA.
As shown in Table 9, the CT ranged from $105,381.17 per year to $312,112.17 per year. The lowest value was achieved with the PV/WT/Btt/DG configuration using the PSO algorithm, while the highest was recorded in the PV/Btt/DG configuration with the GA. Similarly, the COE ranged from $0.1243/kWh to $0.3683/kWh, with the minimum and maximum values also corresponding to these respective configurations. The PSO algorithm achieved the lowest CT values in all configurations analyzed: $105,381.17 per year, $162,281.84 per year, and $312,043.75 per year for the PV/WT/Btt/DG, WT/Btt/DG, and PV/Btt/DG configurations, respectively. Likewise, it presented the lowest COE values: $0.1243/kWh, $0.1915/kWh, and $0.3682/kWh.
Figure 16 compares the annual fuel costs of the three HES configurations. PSO achieved better results in reducing these costs for the PV/WT/Btt/DG and PV/Btt/DG configurations, with only minor differences compared to the GA. In the WT/Btt/DG configuration, the GA showed a slightly lower fuel cost, possibly due to the smaller number of batteries recommended by PSO, which led to greater reliance on the diesel generator. Notably, the PV/WT/Btt/DG configuration presented the lowest fuel cost in both algorithms, confirming its energy efficiency and suitability for the case study.
Figure 17 shows the annual energy contribution of each HES component across the three configurations. The PV/WT/Btt/DG setup delivered the highest total energy output due to its integration of four complementary sources. In this configuration, PV and WT are the primary renewable generators, while Btt and DG serve as backup. Both PSO and the GA produced similar results, with PSO yielding slightly higher total generation. The PV/Btt/DG configuration had the lowest energy output, limited by the absence of wind power, making the system more dependent on storage and diesel generation. Again, both algorithms produced comparable results, with minor differences in battery and generator contributions. The WT/Btt/DG configuration performed better than PV/Btt/DG but remained below the PV/WT/Btt/DG setup, reflecting the importance of hybrid diversification. Overall, PSO consistently delivered slightly better energy contributions across all configurations, confirming its effectiveness. Among the scenarios, PV/WT/Btt/DG optimized with PSO stood out as the most efficient solution, especially in regions with abundant renewable resources.

4.5. Statistical Analysis

Table 10 presents the statistical analysis of the performance of the PSO algorithm and the GA in optimizing the three HES configurations, considering 30 independent runs. The results show that PSO was consistently more efficient and reliable, achieving lower CT values with low dispersion, while the GA exhibited higher variability and greater average costs, especially in the PV/Btt/DG configuration. To assess the significance of the observed differences, the Wilcoxon rank-sum test was applied, following [90]. The results confirm statistically significant differences in favor of PSO for the PV/WT/Btt/DG and PV/Btt/DG configurations (p < 0.01), highlighting its superiority in terms of accuracy and stability. For the WT/Btt/DG configuration, although PSO demonstrated much lower variability (SD = 9.07 compared to 412.48 for GA), the p-value (0.6627) indicates that there is no statistically significant difference between the average costs obtained by the two algorithms.
Figure 18 and Figure 19 present the convergence curves of the 30 runs for each algorithm in the different configurations, while Figure 20 reinforces this evidence by demonstrating the superior convergence and stability of PSO. These results confirm that PSO is more robust, stable, and effective in solving the optimal sizing problem, with particular emphasis on the PV/WT/Btt/DG configuration.

4.6. Application of the Optimal Solution

Figure 21 illustrates the percentage distribution of the CT among the components of the HES in the PV/WT/Btt/DG configuration, as optimized by the PSO algorithm. It is observed that the Btt accounts for the largest share of the cost, at 24.50%, reflecting both the initial investment and the replacement costs over time. The DG accounts for 23.90% of the CT, primarily due to ongoing fuel and maintenance expenses. WT contributed 23.30%, which is significant given their high installation and maintenance costs. PV panels represent 18.20%, showing a lower impact due to their durability and low operational and maintenance costs. Finally, the inverter accounts for 10.10% of the CT, being essential for energy conversion within the system. This cost distribution highlights the importance of carefully considering the economic contribution of each component to achieve efficient and financially viable system sizing.
Figure 22 presents the annual energy generation cycle of the HES components in the configuration optimized by the PSO algorithm, along with the load demand profile. Throughout the year, the total energy generation by the system was estimated at 1493.91 MWh.
To improve the understanding of the system components’ operation, a 200 h sample was extracted from Figure 22 and is shown in Figure 23. In this interval, the combined operation of the four components (PV, WT, Btt, and DG) is illustrated to meet the energy demand ( P L o a d curve). The photovoltaic power output (red line) varies according to solar irradiance, peaking during the day and dropping to near zero at night. Similarly, wind power generation (green line) fluctuates with wind speed and may occasionally exceed the demand. When the sum of solar and wind power exceeds the load, the surplus is allocated to battery charging (yellow curve, representing charging). In periods where renewable sources do not fully meet the load, the batteries discharge (pink curve) to supply part of the energy. If a deficit still exists, the diesel generator (black dashed line) activates to bridge the gap, ensuring uninterrupted power supply. This graph highlights the synergy between renewable sources (PV and WT), battery storage, and DG. The load is consistently met throughout the period while minimizing DG usage during high renewable availability, which contributes to reducing fuel costs.
Figure 24 shows the percentage contribution of each HES component in the configuration optimized by PSO. Wind energy was the main source, accounting for 51.51% of the annual generation, followed by solar energy with 38.43%. The battery system contributed 9.09%, while the diesel generator accounted for only 0.97%. Despite the dominance of wind power, the results highlight the essential role of PV and storage in ensuring uninterrupted power delivery and effectively compensating for the variability of renewable sources throughout the year.
Figure 25 shows the variation in the SOC of the batteries, expressed as a percentage, throughout the year. The SOC fluctuates between 10% and 100%, indicating that the control system effectively prevents the batteries from being fully discharged, thus preserving their lifespan. Over the year, the batteries operate dynamically, frequently charging up to nearly 100% during periods of high renewable generation (PV and/or WT) and discharging down to approximately 10% when energy demand exceeds renewable generation. This operating range reflects the efficient and continuous utilization of the storage system, keeping the batteries within safe limits and playing a crucial role in ensuring energy supply stability.
Figure 26 illustrates the annual operation of the DG in the optimized HES, with the upper graph showing power output (kW) and the lower graph indicating fuel consumption (L/h). The DG operates intermittently, being activated only when renewable sources (PV and WT) and the battery system are unable to meet the load demand. Power output peaks can reach up to 150 kW, while diesel consumption follows a similar trend, reaching approximately 50 L per hour during periods of highest demand. For most of the year, the generator remains off, highlighting its role as a backup resource. These results demonstrate the efficiency of the optimized configuration, which prioritizes renewable energy and storage use, significantly reducing dependence on the DG as well as operational and environmental costs.

5. Conclusions

This study proposed an integrated and innovative methodology for the optimal sizing of off-grid HESs, combining long-term meteorological forecasting using a DWT-LSTM model with metaheuristic optimization algorithms (PSO and GA). The application of this methodology to the region of Guanambi, in Bahia, Brazil, demonstrated its effectiveness both in forecasting and in system optimization, highlighting the importance of using advanced forecasting models to enhance HES performance.
The DWT-LSTM forecasting model outperformed the conventional LSTM network, presenting lower RMSE and MSE values, along with R2 coefficients exceeding 0.98, which confirms the advantages of wavelet-based preprocessing in improving predictive accuracy. These improvements directly impacted the quality of the optimization, enabling more reliable energy planning.
Among the three configurations analyzed, the PV/WT/Btt/DG system optimized with PSO achieved the best results in terms of total annual cost (CT = $105,381.17) and cost of energy ($0.1243/kWh). This configuration also delivered the highest total annual generation (1493.91 MWh), with minimal reliance on the diesel generator, leading to reduced fuel consumption and, consequently, lower greenhouse gas emissions and environmental impact. The optimal configuration consisted of 450 PV panels, 10 WT, 66 Btt, and 1 DG. The PSO algorithm showed superior performance over the GA in terms of convergence, accuracy, and repeatability, reinforcing its suitability for HES sizing problems. However, it is important to note that this study assumed a constant daily load profile and did not account for equipment degradation over time, which may limit its real-world applicability.
From a practical standpoint, the proposed methodology is promising for the development of cost-effective and low-emission energy systems in remote or vulnerable areas. To enhance its robustness and applicability, future work should include the following:
  • Conduct sensitivity analyses to evaluate the impact of uncertainties in input data.
  • Include component degradation and aging over the system’s lifetime.
  • Adapt the methodology to different geographic contexts and consumption scales.
  • Explore multi-objective optimization, balancing economic, environmental, and reliability criteria.
  • Validate the results through pilot projects or experimental environments.
  • Expand the analysis to include comparisons with other advanced forecasting models, such as GRU, CNN-LSTM, and hybrid approaches, providing more robust evidence of performance.
  • Evaluate system performance under different seasonal conditions to enhance the robustness of the methodology.
  • Incorporate state-of-the-art metaheuristics developed in the last 3–5 years.

Author Contributions

Conceptualization, Y.G.C. and J.H.S.; Methodology, Y.G.C., J.H.S., J.L.M.R. and E.A.T.; Software, Y.G.C., J.H.S. and T.H.R.; Validation, Y.G.C., J.H.S., J.L.M.R., T.H.R. and S.A.B.V.d.M.; Formal analysis, Y.G.C. and J.H.S.; Investigation, Y.G.C., J.H.S. and T.H.R.; Data curation, Y.G.C., J.H.S., J.L.M.R. and T.H.R.; Writing—original draft, Y.G.C. and J.H.S.; Writing—review & editing, Y.G.C., J.H.S., S.A.B.V.d.M. and E.A.T.; Visualization, Y.G.C. and E.A.T.; Supervision, J.L.M.R., S.A.B.V.d.M. and E.A.T.; Project administration, Y.G.C., J.L.M.R., S.A.B.V.d.M. and E.A.T. All authors have read and agreed to the published version of the manuscript.

Funding

This work was funded by the Bahia Research Foundation (FAPESB—Brazil) under Grant (Process No. 00047098999).

Data Availability Statement

The data presented in this study are openly available in NASA at https://power.larc.nasa.gov/, reference number [56].

Conflicts of Interest

The authors declare no conflict of interest.

Abbreviations

AIArtificial intelligence
ANNArtificial Neural Network
BttBattery bank
COECost of energy
CTTotal annual cost
DGDiesel generator
DWTDiscrete Wavelet Transform
EMSEnergy Management Strategy
GAGenetic Algorithm
GRUsGated Recurrent Units
HESHybrid energy system
HESsHybrid energy systems
LSTMLong Short-Term Memory
MSEMean Squared error
PSOParticle Swarm Optimization
PVPhotovoltaic panel
RESRenewable energy source
RMSERoot Mean Square Error
RNNsRecurrent Neural Networks
SDStandard deviation
SOCState of charge
STCStandard test condition
TSATunicate Swarm Algorithm
WTWind turbine

References

  1. da Silva, E.T.; Martins, M.A.F.; Rodríguez, J.L.M.; Ferreir, A.S. Evaluation of the influence of distributed generation on the well-being of the rural community using PLS-SEM. J. Clean. Prod. 2024, 442, 141023. [Google Scholar] [CrossRef]
  2. Agajie, T.F.; Ali, A.; Fopah-Lele, A.; Amoussou, I.; Khan, B.; Velasco, C.L.R.; Tanyi, E. A comprehensive review on techno-economic analysis and optimal sizing of hybrid renewable energy sources with energy storage systems. Energies 2023, 16, 642. [Google Scholar] [CrossRef]
  3. IEA. Electricity 2024. Analysis and Forecast to 2026. 2024. Available online: https://iea.blob.core.windows.net/assets/6b2fd954-2017-408e-bf08-952fdd62118a/Electricity2024-Analysisandforecastto2026.pdf (accessed on 5 September 2025).
  4. Verma, R.; Bhatia, R.; Raghuwanshi, S.S. Computational Strategies for Enhancing Hybrid Renewable Energy Systems: A Comprehensive Review. In Proceedings of the 2024 IEEE 2nd International Conference on Innovations in High Speed Communication and Signal Processing (IHCSP), Bhopal, India, 6–8 December 2024; pp. 1–5. [Google Scholar]
  5. IRENA. Renewable Capacity Statistics 2025. In International Renewable Energy Agency. 2025. Available online: https://www.irena.org/-/media/Files/IRENA/Agency/Publication/2025/Mar/IRENA_DAT_RE_Capacity_Statistics_2025.pdf (accessed on 5 September 2025).
  6. IEA; UNSD; World Bank; WHO. WHO. Tracking SDG 7: The Energy Progress Report. World Bank, Washington DC. © World Bank. License: Creative Commons Attribution—NonCommercial 3.0 IGO (CC BY-NC 3.0 IGO). 2023. Available online: https://unstats.un.org/unsd/energystats/pubs/documents/sdg_7.pdf (accessed on 5 September 2025).
  7. Belboul, Z.; Toual, B.; Bensalem, A.; Ghenai, C.; Khan, B.; Kamel, S. Techno-economic optimization for isolated hybrid PV/wind/battery/diesel generator microgrid using improved salp swarm algorithm. Sci. Rep. 2024, 14, 2920. [Google Scholar] [CrossRef]
  8. Bawan, E.K.; Wijaya, F.D.; Alid, H.R.; Vasquez, J.C. Comprehensive Analysis and Optimal Design of Hybrid Renewable Energy System for Rural Electrification in West Papua, Indonesia. IEEE Access 2025, 13, 66250–66275. [Google Scholar] [CrossRef]
  9. Gusain, C.; Nangia, U.; Tripathi, M.M. Optimal Configuration of Off-Grid Hybrid Renewable Energy System: A Multi-Criteria Analysis. In Proceedings of the IEEE Third International Conference on Power Electronics, Intelligent Control and Energy Systems (ICPEICES), Delhi, India, 26–28 April 2024; pp. 1002–1006. [Google Scholar]
  10. de Oliveira Barbosa, C.F.; Pinho, J.T.; Galhardo, M.A.B.; da Silva Pereira, E.J. Sistemas Híbridos de Energia: Aplicações e Estudos No Brasil. In Proceedings of the Anais Congresso Brasileiro de Energia Solar-CBENS, Belo Horizonte, Brazil, 4–7 April 2016; pp. 1–8. [Google Scholar]
  11. Mazzeo, D.; Baglivo, C.; Matera, N.; Congedo, P.M.; Oliveti, G. A novel energy-economic-environmental multi-criteria decision-making in the optimization of a hybrid renewable system. Sustain. Cities Soc. 2020, 52, 101780. [Google Scholar] [CrossRef]
  12. Bensalmi, W.; Zeroual, A.; Belhani, A. Improved sizing approach for hybrid energy system based on machine learning paradigm. Comput. Electr. Eng. 2025, 123, 110217. [Google Scholar] [CrossRef]
  13. He, Y.; Guo, S.; Dong, P.; Zhang, Y.; Huang, J.; Zhou, J. A state-of-the-art review and bibliometric analysis on the sizing optimization of off-grid hybrid renewable energy systems. Renew. Sustain. Energy Rev. 2023, 183, 113476. [Google Scholar] [CrossRef]
  14. Bade, S.O.; Meenakshisundaram, A.; Tomomewo, O.S. Current Status, Sizing Methodologies, Optimization Techniques, and Energy Management and Control Strategies for Co-Located Utility-Scale Wind–Solar-Based Hybrid Power Plants: A Review. Eng 2024, 5, 677–719. [Google Scholar] [CrossRef]
  15. Gan, L.K.; Shek, J.K.H.; Mueller, M.A. Hybrid wind–photovoltaic–diesel–battery system sizing tool development using empirical approach, life-cycle cost and performance analysis: A case study in Scotland. Energy Convers. Manag. 2015, 106, 479–494. [Google Scholar] [CrossRef]
  16. Li, W.; Li, J.; Hu, Z.; Li, S.; Chan, P.W. A novel probabilistic approach to optimize stand-alone hybrid wind-photovoltaic renewable energy system. Energies 2020, 13, 4945. [Google Scholar] [CrossRef]
  17. Giallanza, A.; Porretto, M.; Puma, G.L.; Marannano, G. A sizing approach for stand-alone hybrid photovoltaic-wind-battery systems: A Sicilian case study. J. Clean. Prod. 2018, 199, 817–830. [Google Scholar] [CrossRef]
  18. Karve, G.M.; Kurundkar, K.M.; Vaidya, G.A. Implementation of analytical method and improved particle swarm optimization method for optimal sizing of a standalone PV/wind and battery energy storage hybrid system. In Proceedings of the 2019 IEEE 5th International Conference for Convergence in Technology (I2CT), Bombay, India, 29–31 March 2019; pp. 1–5. [Google Scholar]
  19. Anand, P.; Sharma, B.; Rizwan, M. Size Optimization of Grid-Tied Hybrid Energy System by Employing Forecasted Meteorological Data. MAPAN 2024, 39, 739–750. [Google Scholar] [CrossRef]
  20. Khan, A.A.; Minai, A.F.; Godi, R.K.; Sharma, V.S.; Malik, H.; Afthanorhan, A. Optimal Sizing, Techno-Economic Feasibility and Reliability Analysis of Hybrid Renewable Energy System: A Systematic Review of Energy Storage Systems’ Integration. IEEE Access 2025, 13, 59198–59226. [Google Scholar] [CrossRef]
  21. Rashwan, A.; Faragalla, A.; Abo-Zahhad, E.M.; El-Dein, A.Z.; Liu, Y.; Chen, Y.; Abdelhameed, E.H. Techno-economic Optimization of Isolated Hybrid Microgrids for Remote Areas Electrification: Aswan city as a Case Study. Smart Grids Sustain. Energy 2024, 9, 18. [Google Scholar] [CrossRef]
  22. Javed, M.S.; Song, A.; Ma, T. Techno-economic assessment of a stand-alone hybrid solar-wind-battery system for a remote island using genetic algorithm. Energy 2019, 176, 704–717. [Google Scholar] [CrossRef]
  23. Bade, S.O.; Tomomewo, O.S.; Meenakshisundaram, A.; Dey, M.; Alamooti, M.; Halwany, N. Multi-Criteria Optimization of a Hybrid Renewable Energy System Using Particle Swarm Optimization for Optimal Sizing and Performance Evaluation. Clean Technol. 2025, 7, 23. [Google Scholar] [CrossRef]
  24. Akter, A.; Zafir, E.I.; Dana, N.H.; Joysoyal, R.; Sarker, S.K.; Li, L.; Muyeen, S.M.; Das, S.K.; Kamwa, I. A review on microgrid optimization with meta-heuristic techniques: Scopes, trends and recommendation. Energy Strategy Rev. 2024, 51, 101298. [Google Scholar] [CrossRef]
  25. Abdullah, H.M.; Park, S.; Seong, K.; Lee, S. Hybrid renewable energy system design: A machine learning approach for optimal sizing with net-metering costs. Sustainability 2023, 15, 8538. [Google Scholar] [CrossRef]
  26. Mohamed, M.A.; Hassanin, M.; Hassan, A. Optimization of Standalone Hybrid Renewable Energy Systems Using Different Metaheuristic Techniques Considering Demand Side Management. J. Adv. Eng. Trends 2025, 44, 159–186. [Google Scholar] [CrossRef]
  27. Ahmed, M.M.; Das, B.K.; Das, P.; Hossain, M.S.; Kibria, M.G. Energy management and sizing of a stand-alone hybrid renewable energy system for community electricity, fresh water, and cooking gas demands of a remote island. Energy Convers. Manag. 2024, 299, 117865. [Google Scholar] [CrossRef]
  28. Khatri, K.C.A.; Shah, K.B.; Logeshwaran, J.; Shrestha, A. Genetic algorithm based techno-economic optimization of an isolated hybrid energy system. ICTACT J. Microelectron. 2023, 1, 1447–1450. [Google Scholar] [CrossRef]
  29. Lazaar, N.; Fakhri, E.; Barakat, M.; Sabor, J.; Gualous, H. A genetic algorithm based optimal sizing strategy for PV/battery/hydrogen hybrid system. In Artificial Intelligence and Industrial Applications: Artificial Intelligence Techniques for Cyber-Physical, Digital Twin Systems and Engineering Applications, Proceedings of the Artificial Intelligence & Industrial Applications (A2IA2020), Meknes, Morocco, 19–20 March 2020; Springer: Berlin/Heidelberg, Germany, 2021; pp. 247–259. [Google Scholar]
  30. Namrata, K.; Kumar, N.; Sekhar, C.; Gupta, R.P.; Salkuti, S.R. Modeling and Sizing of the Hybrid Renewable System Opting Genetic Algorithm. In Power Quality in Microgrids: Issues, Challenges and Mitigation Techniques; Springer: Berlin/Heidelberg, Germany, 2023; pp. 535–563. [Google Scholar]
  31. Firdouse, F.; Surender Reddy, M. A hybrid energy storage system using GA and PSO for an islanded microgrid applications. Energy Storage 2023, 5, e460. [Google Scholar] [CrossRef]
  32. Al-Shammari, Z.W.J.; Azizan, M.M.; Rahman, A.S.F.; Hasikin, K. Optimal sizing of standalone for hybrid renewable energy system by using PSO optimization technique. Int. J. Power Electron. Drive Syst. 2023, 14, 426. [Google Scholar] [CrossRef]
  33. Bansal, A.K. Sizing and forecasting techniques in photovoltaic-wind based hybrid renewable energy system: A review. J. Clean. Prod. 2022, 369, 133376. [Google Scholar] [CrossRef]
  34. Sharma, B.; Rizwan, M.; Anand, P. Optimal design of renewable energy based hybrid system considering weather forecasting using machine learning techniques. Electr. Eng. 2023, 105, 4229–4249. [Google Scholar] [CrossRef]
  35. De Jong, P.; Barreto, T.B.; Tanajura, C.A.S.; Kouloukoui, D.; Oliveira-Esquerre, K.P.; Kiperstok, A.; Torres, E.A. Estimating the impact of climate change on wind and solar energy in Brazil using a South American regional climate model. Renew. Energy 2019, 141, 390–401. [Google Scholar] [CrossRef]
  36. Abazari, A.; Soleymani, M.M.; Kamwa, I.; Babaei, M.; Ghafouri, M.; Muyeen, S.M.; Foley, A.M. A reliable and cost-effective planning framework of rural area hybrid system considering intelligent weather forecasting. Energy Rep. 2021, 7, 5647–5666. [Google Scholar] [CrossRef]
  37. Almaraashi, M. Using particle swarm optimization of fuzzy logic systems as a hybrid soft computing method to enhance solar energy prediction. Neural Comput. Appl. 2023, 35, 21903–21914. [Google Scholar] [CrossRef]
  38. Singla, P.; Duhan, M.; Saroha, S. A comprehensive review and analysis of solar forecasting techniques. Front. Energy 2021, 16, 187–223. [Google Scholar] [CrossRef]
  39. Wang, J.; Yang, W.; Du, P.; Niu, T. A novel hybrid forecasting system of wind speed based on a newly developed multi-objective sine cosine algorithm. Energy Convers. Manag. 2018, 163, 134–150. [Google Scholar] [CrossRef]
  40. Wang, H.; Lei, Z.; Zhang, X.; Zhou, B.; Peng, J. A review of deep learning for renewable energy forecasting. Energy Convers. Manag. 2019, 198, 111799. [Google Scholar] [CrossRef]
  41. Baghel, R.S.; Gosh, A.K.; Patidar, Y.; Gangakhedkar, T.; Panchal, A. SIF-DWTRL: Solar irradiation forecasting using discrete wavelet transform and regression learning. Energy Syst. 2023, 16, 395–411. [Google Scholar] [CrossRef]
  42. Rodríguez, F.; Azcárate, I.; Vadillo, J.; Galarza, A. Forecasting intra-hour solar photovoltaic energy by assembling wavelet based time-frequency analysis with deep learning neural networks. Int. J. Electr. Power Energy Syst. 2022, 137, 107777. [Google Scholar] [CrossRef]
  43. Singla, P.; Duhan, M.; Saroha, S. An ensemble method to forecast 24-h ahead solar irradiance using wavelet decomposition and BiLSTM deep learning network. Earth Sci. Inform. 2022, 15, 291–306. [Google Scholar] [CrossRef]
  44. Alizamir, M.; Shiri, J.; Fard, A.F.; Kim, S.; Gorgij, A.D.; Heddam, S.; Singh, V.P. Improving the accuracy of daily solar radiation prediction by climatic data using an efficient hybrid deep learning model: Long short-term memory (LSTM) network coupled with wavelet transform. Eng. Appl. Artif. Intell. 2023, 123, 106199. [Google Scholar] [CrossRef]
  45. Singh, S.K.; Jha, S.K.; Gupta, R. A fusion approach of discrete wavelet decomposition and deep learning techniques for the enhancement of wind speed prediction accuracy. Theor. Appl. Climatol. 2025, 156, 223. [Google Scholar] [CrossRef]
  46. Zhang, W.; Maleki, A.; Rosen, M.A.; Liu, J. Sizing a stand-alone solar-wind-hydrogen energy system using weather forecasting and a hybrid search optimization algorithm. Energy Convers. Manag. 2019, 180, 609–621. [Google Scholar] [CrossRef]
  47. Maleki, A.; Khajeh, M.G.; Rosen, M.A. Weather forecasting for optimization of a hybrid solar-wind–powered reverse osmosis water desalination system using a novel optimizer approach. Energy 2016, 114, 1120–1134. [Google Scholar] [CrossRef]
  48. Gurubel, K.J.; Osuna-Enciso, V.; Cardenas, J.J.; Coronado-Mendoza, A.; Perez-Cisneros, M.A.; Sanchez, E.N. Neural forecasting and optimal sizing for hybrid renewable energy systems with grid-connected storage system. J. Renew. Sustain. Energy 2016, 8, 045303. [Google Scholar] [CrossRef]
  49. Gupta, R.A.; Kumar, R.; Bansal, A.K. BBO-based small autonomous hybrid power system optimization incorporating wind speed and solar radiation forecasting. Renew. Sustain. Energy Rev. 2015, 41, 1366–1375. [Google Scholar] [CrossRef]
  50. Fei, Z.; Zou, Y.; Hua, W.; Banda, O.V.; Guerrero, J.M.; Li, Z. Weather Routing Based Multi-Energy Ship Microgrid Operation Under Diverse Uncertainties: A Risk-Averse Stochastic Approach. IEEE Trans. Smart Grid, 2025; early access. [Google Scholar] [CrossRef]
  51. Zhang, S.; Zhang, X.; Zhang, R.; Gu, W.; Cao, G. N-1 evaluation of integrated electricity and gas system considering cyber-physical interdependence. IEEE Trans. Smart Grid 2025, 16, 3728–3742. [Google Scholar] [CrossRef]
  52. Mohamad Radzi, P.N.L.; Akhter, M.N.; Mekhilef, S.; Mohamed Shah, N. Review on the application of photovoltaic forecasting using machine learning for very short-to long-term forecasting. Sustainability 2023, 15, 2942. [Google Scholar] [CrossRef]
  53. Assaf, A.M.; Haron, H.; Abdull Hamed, H.N.; Ghaleb, F.A.; Qasem, S.N.; Albarrak, A.M. A review on neural network based models for short term solar irradiance forecasting. Appl. Sci. 2023, 13, 8332. [Google Scholar] [CrossRef]
  54. Medina-Santana, A.A.; Cárdenas-Barrón, L.E. Optimal Design of Hybrid Renewable Energy Systems Considering Weather Forecasting Using Recurrent Neural Networks. Energies 2022, 15, 9045. [Google Scholar] [CrossRef]
  55. Li, Q.; Loy-Benitez, J.; Nam, K.; Hwangbo, S.; Rashidi, J.; Yoo, C. Sustainable and reliable design of reverse osmosis desalination with hybrid renewable energy systems through supply chain forecasting using recurrent neural networks. Energy 2019, 178, 277–292. [Google Scholar] [CrossRef]
  56. NASA. Available online: https://power.larc.nasa.gov/ (accessed on 2 January 2022).
  57. Brahma, B.; Wadhvani, R.; Shukla, S. Attention mechanism for developing wind speed and solar irradiance forecasting models. Wind Eng. 2020, 45, 1422–1432. [Google Scholar] [CrossRef]
  58. Masmoudi, W.; Djebli, A.; Moussaoui, F. Evaluating LSTM and NARX neural networks for wind speed forecasting and energy optimization in Tetouan, Northern Morocco. Energy Explor. Exploit. 2025, 43, 953–970. [Google Scholar] [CrossRef]
  59. Shah, A.A.; Aftab, A.A.; Han, X.; Baloch, M.H.; Honnurvali, M.S.; Chauhdary, S.T. Prediction Error-Based Power Forecasting of Wind Energy System Using Hybrid WT–ROPSO–NARMAX Model. Energies 2023, 16, 3295. [Google Scholar] [CrossRef]
  60. Tascikaraoglu, A.; Sanandaji, B.M.; Poolla, K.; Varaiya, P. Exploiting sparsity of interconnections in spatio-temporal wind speed forecasting using Wavelet Transform. Appl. Energy 2016, 165, 735–747. [Google Scholar] [CrossRef]
  61. Arseven, B.; Çınar, S.M. A novel hybrid solar radiation forecasting algorithm based on discrete wavelet transform and multivariate machine learning models integrated with clearness index clusters. J. Atmos. Sol.-Terr. Phys. 2025, 267, 106417. [Google Scholar] [CrossRef]
  62. De Giorgi, M.G.; Ficarella, A.; Tarantino, M. Assessment of the benefits of numerical weather predictions in wind power forecasting based on statistical methods. Energy 2011, 36, 3968–3978. [Google Scholar] [CrossRef]
  63. Zhang, Y.; Kong, L. Photovoltaic power prediction based on hybrid modeling of neural network and stochastic differential equation. ISA Trans. 2022, 128, 181–206. [Google Scholar] [CrossRef]
  64. Sankarananth, S.; Karthiga, M.; Suganya, E.; Sountharrajan, S.; Bavirisetti, D.P. AI-enabled metaheuristic optimization for predictive management of renewable energy production in smart grids. Energy Rep. 2023, 10, 1299–1312. [Google Scholar] [CrossRef]
  65. Molu, R.J.J.; Tripathi, B.; Mbasso, W.F.; Naoussi, S.R.D.; Bajaj, M.; Wira, P.; Blazek, V.; Prokop, L.; Misak, S. Advancing short-term solar irradiance forecasting accuracy through a hybrid deep learning approach with Bayesian optimization. Results Eng. 2024, 23, 102461. [Google Scholar] [CrossRef]
  66. Gayathry, V.; Kaliyaperumal, D.; Salkuti, S.R. Seasonal solar irradiance forecasting using artificial intelligence techniques with uncertainty analysis. Sci. Rep. 2024, 14, 17945. [Google Scholar] [CrossRef]
  67. Yamany, A.; Mohamed, M.A.; Mohammed, Y. Optimal Sizing and Economic Evaluation of Hybrid Photovoltaic/Wind/Battery/Diesel Generation Systems for Autonomous Utilization. J. Adv. Eng. Trends 2024, 43, 47–65. [Google Scholar] [CrossRef]
  68. Yimen, N.; Tchotang, T.; Kanmogne, A.; Abdelkhalikh Idriss, I.; Musa, B.; Aliyu, A.; Okonkwo, E.C.; Abba, S.I.; Tata, D.; Meva’a, L. Optimal sizing and techno-economic analysis of hybrid renewable energy systems—A case study of a photovoltaic/wind/battery/diesel system in Fanisau, Northern Nigeria. Processes 2020, 8, 1381. [Google Scholar] [CrossRef]
  69. Sunova. Painel Solar Fotovoltaico 550W–Sunova SS-550-72-MDH. 2024. Available online: https://www.neosolar.com.br/loja/painel-solar-fotovoltaico-550w-sunova-ss-550-72-mdh.html (accessed on 5 September 2025).
  70. Guven, A.F.; Abdelaziz, A.Y.; Samy, M.M.; Barakat, S. Optimizing energy Dynamics: A comprehensive analysis of hybrid energy storage systems integrating battery banks and supercapacitors. Energy Convers. Manag. 2024, 312, 118560. [Google Scholar] [CrossRef]
  71. Elnaggar, M.; El-Khozondar, H.J.; Salah, W.A.; Nassar, Y.F.; Bashir, M.J.K. Assessing the techno-enviro-economic viability of wind farms to address electricity shortages and Foster sustainability in Palestine. Results Eng. 2024, 24, 103111. [Google Scholar] [CrossRef]
  72. Bacha, B.; Ghodbane, H.; Dahmani, H.; Betka, A.; Toumi, A.; Chouder, A. Optimal sizing of a hybrid microgrid system using solar, wind, diesel, and battery energy storage to alleviate energy poverty in a rural area of Biskra, Algeria. J. Energy Storage 2024, 84, 110651. [Google Scholar] [CrossRef]
  73. Ryse_Energy. E20-HAWT. Available online: https://en.wind-turbine-models.com/turbines/2591-ryse-energy-e-20-hawt (accessed on 5 September 2025).
  74. Deye_ESS. Technical Data Sheet Battery BOS-G. Available online: https://deyeess.com/ (accessed on 5 September 2025).
  75. Hokmabad, H.N.; Husev, O.; Kurnitski, J.; Belikov, J. Optimizing size and economic feasibility assessment of photovoltaic and energy storage setup in residential applications. Sustain. Energy Grids Netw. 2024, 38, 101385. [Google Scholar] [CrossRef]
  76. Adebayo, I.; Sun, Y.; Awal, U. Economic optimization of hybrid renewable energy resources for rural electrification. Int. J. Power Electron. Drive Syst. 2024, 15, 1147–1157. [Google Scholar] [CrossRef]
  77. Abed, F.T.; Abed, N.K.; Alrubeei, I.R.N.; Alrikabi, A.R.H. Using genetic algorithm for optimal sizing of stand-alone hybrid energy system. Herit. Sustain. Dev. 2024, 6, 287–300. [Google Scholar] [CrossRef]
  78. Muleta, N.; Badar, A.Q.H. Designing of an optimal standalone hybrid renewable energy micro-grid model through different algorithms. J. Eng. Res. 2023, 11, 100011. [Google Scholar] [CrossRef]
  79. Maleki, A.; Askarzadeh, A. Optimal sizing of a PV/wind/diesel system with battery storage for electrification to an off-grid remote region: A case study of Rafsanjan, Iran. Sustain. Energy Technol. Assess. 2014, 7, 147–153. [Google Scholar] [CrossRef]
  80. SELIC. Sistema Especial de Liquidação e de Custódia. Banco Central do Brasil. Available online: https://www.bcb.gov.br/controleinflacao/taxaselic (accessed on 5 September 2025).
  81. IBGE. IPCA—Índice Nacional de Preços ao Consumidor Amplo; Instituto Brasileiro de Geografia e Estatística: Rio de Janeiro, Brazil, 2023. [Google Scholar]
  82. Maleki, A.; Pourfayaz, F. Sizing of stand-alone photovoltaic/wind/diesel system with battery and fuel cell storage devices by harmony search algorithm. J. Energy Storage 2015, 2, 30–42. [Google Scholar] [CrossRef]
  83. IRENA. Renewable Power Generation Costs in 2022, 978-92-9260-544-5. 2023. Available online: https://www.irena.org/Publications/2023/Aug/Renewable-Power-Generation-Costs-in-2022 (accessed on 5 September 2025).
  84. NEOPWR. Loja Online Neopwr Brasil. Available online: https://neopwr.one/brasil.lojaonline?gad_source=1&gclid=Cj0KCQjw782_BhDjARIsABTv_JACDvymC8XCHUCmOu3VpHLswJ1Ot3uk-ubWpjfRMlY4VzRiQ7QYxu0aAp9UEALw_wcB (accessed on 8 March 2025).
  85. Diab, A.A.Z.; Sultan, H.M.; Mohamed, I.S.; Kuznetsov, O.N.; Do, T.D. Application of different optimization algorithms for optimal sizing of PV/wind/diesel/battery storage stand-alone hybrid microgrid. IEEE Access 2019, 7, 119223–119245. [Google Scholar] [CrossRef]
  86. Rathore, A.; Kumar, A.; Patidar, N.P. Techno-socio-economic and sensitivity analysis of standalone micro-grid located in Central India. Int. J. Ambient Energy 2023, 44, 1490–1511. [Google Scholar] [CrossRef]
  87. Mokhtara, C.; Negrou, B.; Bouferrouk, A.; Yao, Y.; Settou, N.; Ramadan, M. Integrated supply–demand energy management for optimal design of off-grid hybrid renewable energy systems for residential electrification in arid climates. Energy Convers. Manag. 2020, 221, 113192. [Google Scholar] [CrossRef]
  88. Ajewole, T.O.; Oladepo, O.; Hassan, K.A.; Olawuyi, A.A.; Onarinde, O. Comparative study of the performances of three metaheuristic algorithms in sizing hybrid-source power system. Turk. J. Electr. Power Energy Syst. 2022, 2, 134–146. [Google Scholar] [CrossRef]
  89. EPE EDPE. Metodologia: Projeção de Curva de Carga Horária-Nota Técnica NT/EPE/DEA-005/2020; Rio de Janeiro. 2020. Available online: https://www.epe.gov.br/pt/publicacoes-dados-abertos/publicacoes/nota-tecnica-metodologia-projecao-de-curva-de-carga-horaria (accessed on 5 September 2025).
  90. Güven, A.F.; Yörükeren, N.; Mengi, O.Ö. Multi-objective optimization and sustainable design: A performance comparison of metaheuristic algorithms used for on-grid and off-grid hybrid energy systems. Neural Comput. Appl. 2024, 36, 7559–7594. [Google Scholar] [CrossRef]
Figure 1. Structure of the proposed methodology.
Figure 1. Structure of the proposed methodology.
Energies 18 05371 g001
Figure 2. The basic LSTM cell.
Figure 2. The basic LSTM cell.
Energies 18 05371 g002
Figure 3. The proposed HES model.
Figure 3. The proposed HES model.
Energies 18 05371 g003
Figure 4. HES Energy management strategy.
Figure 4. HES Energy management strategy.
Energies 18 05371 g004
Figure 5. Hourly time series of solar irradiance, wind speed, and ambient temperature in Guanambi (2012–2021).
Figure 5. Hourly time series of solar irradiance, wind speed, and ambient temperature in Guanambi (2012–2021).
Energies 18 05371 g005
Figure 6. Monthly average of solar irradiance, wind speed, and temperature over ten years.
Figure 6. Monthly average of solar irradiance, wind speed, and temperature over ten years.
Energies 18 05371 g006
Figure 7. Daily load curve for the study area.
Figure 7. Daily load curve for the study area.
Energies 18 05371 g007
Figure 8. Wind speed decomposition using DWT.
Figure 8. Wind speed decomposition using DWT.
Energies 18 05371 g008
Figure 9. Temperature decomposition using DWT.
Figure 9. Temperature decomposition using DWT.
Energies 18 05371 g009
Figure 10. Solar irradiance decomposition using DWT.
Figure 10. Solar irradiance decomposition using DWT.
Energies 18 05371 g010
Figure 11. Irradiance forecast result using DWT-LSTM.
Figure 11. Irradiance forecast result using DWT-LSTM.
Energies 18 05371 g011
Figure 12. Wind speed forecast result using DWT-LSTM.
Figure 12. Wind speed forecast result using DWT-LSTM.
Energies 18 05371 g012
Figure 13. Temperature forecast result using DWT-LSTM.
Figure 13. Temperature forecast result using DWT-LSTM.
Energies 18 05371 g013
Figure 14. Coefficient of determination of the DWT-LSTM model for (a) solar irradiance, (b) wind speed, and (c) ambient temperature.
Figure 14. Coefficient of determination of the DWT-LSTM model for (a) solar irradiance, (b) wind speed, and (c) ambient temperature.
Energies 18 05371 g014
Figure 15. Convergence of CT using the PSO algorithm and the GA for the three configuration scenarios, (a) PV/WT/Btt/DG, (b) PV/Btt/DG, (c) WT/Btt/DG.
Figure 15. Convergence of CT using the PSO algorithm and the GA for the three configuration scenarios, (a) PV/WT/Btt/DG, (b) PV/Btt/DG, (c) WT/Btt/DG.
Energies 18 05371 g015
Figure 16. Annual fuel consumption cost comparison for the three HES configurations.
Figure 16. Annual fuel consumption cost comparison for the three HES configurations.
Energies 18 05371 g016
Figure 17. Annual energy generation contribution from different HES configurations: (a) PV/WT/Btt/DG, (b) PV/Btt/DG, (c) WT/Btt/DG.
Figure 17. Annual energy generation contribution from different HES configurations: (a) PV/WT/Btt/DG, (b) PV/Btt/DG, (c) WT/Btt/DG.
Energies 18 05371 g017
Figure 18. Convergence of the 30 PSO executions: (a) PV/WT/Btt/DG; (b) PV/Btt/DG; (c) WT/Btt/DG.
Figure 18. Convergence of the 30 PSO executions: (a) PV/WT/Btt/DG; (b) PV/Btt/DG; (c) WT/Btt/DG.
Energies 18 05371 g018
Figure 19. Convergence of the 30 GA executions: (a) PV/WT/Btt/DG; (b) PV/Btt/DG; (c) WT/Btt/DG.
Figure 19. Convergence of the 30 GA executions: (a) PV/WT/Btt/DG; (b) PV/Btt/DG; (c) WT/Btt/DG.
Energies 18 05371 g019
Figure 20. Boxplot of CT obtained by PSO and GA over 30 independent runs for each system configuration: (a) PV/WT/Btt/DG, (b) PV/Btt/DG, (c) WT/Btt/DG.
Figure 20. Boxplot of CT obtained by PSO and GA over 30 independent runs for each system configuration: (a) PV/WT/Btt/DG, (b) PV/Btt/DG, (c) WT/Btt/DG.
Energies 18 05371 g020
Figure 21. Percentage contribution of each component (PV/WT/Btt/DG) to the CT based on PSO.
Figure 21. Percentage contribution of each component (PV/WT/Btt/DG) to the CT based on PSO.
Energies 18 05371 g021
Figure 22. Operation curve of the HES components (PV/WT/Btt/DG) over one year.
Figure 22. Operation curve of the HES components (PV/WT/Btt/DG) over one year.
Energies 18 05371 g022
Figure 23. Operation curve of HES components (PV/WT/Btt/DG) over 200 h.
Figure 23. Operation curve of HES components (PV/WT/Btt/DG) over 200 h.
Energies 18 05371 g023
Figure 24. Percentage contribution of each component (PV/WT/Btt/DG) in energy generation based on PSO.
Figure 24. Percentage contribution of each component (PV/WT/Btt/DG) in energy generation based on PSO.
Energies 18 05371 g024
Figure 25. Hourly SOC profile of the battery bank throughout the year using PSO.
Figure 25. Hourly SOC profile of the battery bank throughout the year using PSO.
Energies 18 05371 g025
Figure 26. Power generated by DG and fuel consumption throughout the year using PSO.
Figure 26. Power generated by DG and fuel consumption throughout the year using PSO.
Energies 18 05371 g026
Table 1. LSTM model hyperparameters.
Table 1. LSTM model hyperparameters.
HyperparameterValue
Maximum number of epochs160
Number of hidden layers1
OptimizerAdam
Learning rate0.005
Hidden units200
Gradient clipping threshold1
Table 2. PV panel technical specifications.
Table 2. PV panel technical specifications.
ParametersValue
TechnologyMonocrystalline (Si)
P P V r 0.55 kW
T c , S T C 25 °C
N O C T 46 °C
G S T C 1 kW/m2
Lifespan20 years
Table 3. Technical specifications of the wind turbine.
Table 3. Technical specifications of the wind turbine.
ParametersValue
Technology3-blade horizontal shaft
P W T r 20 kW
V c u t i n 2 m/s
V r a t 9 m/s
V c u t o f f 30 m/s
h Z 27 m
Lifespan20 years
Table 4. Battery technical specifications.
Table 4. Battery technical specifications.
ParametersValue
ModelBOS-G15
S B t t 15.36 kWh
η c h 90%
η d i s c h 100%
σ 0.02%
Lifespan16 years
Table 5. Minimum and maximum quantities of equipment.
Table 5. Minimum and maximum quantities of equipment.
HES Components n x , m i n n x , m a x
n P V 0450
n W T 016
n B t t 0300
Table 6. Economic parameters of HES components.
Table 6. Economic parameters of HES components.
ComponentParameterValue (Unit)Source
PV Panel C P V 747 ($/kW)IRENA [83]
C O & M _ P V 7.4 ($/kW/year)
WT C W T 1052 ($/kW)IRENA [83]
C O & M _ W T 24 ($/kW/year)
Btt P B t t 202 ($/kWh)NEOPWR [84]
C O & M _ B t t 10 ($/unit/year)
DG C D G 850 ($/kW)Diab, et al. [85]
C O & M _ D G 0.30 ($/kWh)Rathore, et al. [86]
C f 1.18 ($/L)Abazari et al. [36]
Inv P I n v 250 ($/kW)Muleta and Badar [78]
Table 7. Parameters for PSO and GA.
Table 7. Parameters for PSO and GA.
AlgorithmParameterValue
PSOPopulation50
Iterations30
Inertia factor ( ω ) 0.4–1.2
p b e s t weight factor ( c 1 ) 1.5
g b e s t weight factor ( c 2 ) 2.0
GAPopulation50
Interations30
Crossover rate ( P C ) 0.8
Mutation rate ( P m ) 0.005
Elite count0.1
Table 8. Forecast error results.
Table 8. Forecast error results.
Irradiance
(kW/m2)
Wind Speed
(m/s)
Temperature
(°C)
RMSE MSE RMSE MSE RMSE MSE
DWT-LSTM0.01110.000120.20780.04320.27150.0737
LSTM0.01130.000130.30090.09050.33970.1154
Table 9. Optimization results for different HES configurations using PSO and GA.
Table 9. Optimization results for different HES configurations using PSO and GA.
PV/WT/Btt/DGWT/Btt/DGPV/Btt/DG
PSOGAPSOGAPSOGA
n P V 450448--450450
n W T 10101616--
n B t t 666545475049
C T   ( $ / y e a r ) 105,381.17105,504.51162,281.84162,387.98312,043.75312,112.17
C O E   ( $ / k W h ) 0.12430.12450.19150.19160.36820.3683
PV (kWh/year)574,116.17571,564.54--574,116.17574,116.17
WT (kWh/year)769,556.27769,556.271,231,290.041,231,290.04--
Btt (kWh/year)135,723.39134,993.1767,290.0668,403.93194,830.13194,174.99
DG (kWh/year)14,512.0715,114.00103,868.64103,038.50325,363.61326,021.14
C F U E L ( $ / y e a r ) 8825.899245.7051,602.9751,174.57153,050.23153,313.18
Table 10. Statistical performance assessment of the proposed optimization algorithms based on 30 executions.
Table 10. Statistical performance assessment of the proposed optimization algorithms based on 30 executions.
IndicatorPV/WT/Btt/DGWT/Btt/DGPV/Btt/DG
PSOGAPSOGAPSOGA
Minimum105,381.17105,504.51162,281.84162,281.84312,043.75312,112.17
Maximum108,220.13110,313.80162,331.52164,542.28312,112.17320,554.80
Mean105,479.52106,028.59162,283.49162,358.52312,048.31312,847.13
Standard Deviation (SD)518.021127.119.07412.4817.362135.99
p-value4.402995   ×   10−106.627348   ×   10−12.737666   ×   10−10
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

González Cusa, Y.; Hidalgo Suárez, J.; Moya Rodríguez, J.L.; Hernández Ramírez, T.; Vieira de Melo, S.A.B.; Andrade Torres, E. Optimal Sizing of an Off-Grid Hybrid Energy System with Metaheuristics and Meteorological Forecasting Based on Wavelet Transform and Long Short-Term Memory Networks. Energies 2025, 18, 5371. https://doi.org/10.3390/en18205371

AMA Style

González Cusa Y, Hidalgo Suárez J, Moya Rodríguez JL, Hernández Ramírez T, Vieira de Melo SAB, Andrade Torres E. Optimal Sizing of an Off-Grid Hybrid Energy System with Metaheuristics and Meteorological Forecasting Based on Wavelet Transform and Long Short-Term Memory Networks. Energies. 2025; 18(20):5371. https://doi.org/10.3390/en18205371

Chicago/Turabian Style

González Cusa, Yamilet, José Hidalgo Suárez, Jorge Laureano Moya Rodríguez, Tulio Hernández Ramírez, Silvio A. B. Vieira de Melo, and Ednildo Andrade Torres. 2025. "Optimal Sizing of an Off-Grid Hybrid Energy System with Metaheuristics and Meteorological Forecasting Based on Wavelet Transform and Long Short-Term Memory Networks" Energies 18, no. 20: 5371. https://doi.org/10.3390/en18205371

APA Style

González Cusa, Y., Hidalgo Suárez, J., Moya Rodríguez, J. L., Hernández Ramírez, T., Vieira de Melo, S. A. B., & Andrade Torres, E. (2025). Optimal Sizing of an Off-Grid Hybrid Energy System with Metaheuristics and Meteorological Forecasting Based on Wavelet Transform and Long Short-Term Memory Networks. Energies, 18(20), 5371. https://doi.org/10.3390/en18205371

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop