Leveraging PSO algorithms to achieve optimal stand-alone microgrid performance with a focus on battery lifetime

ABSTRACT


INTRODUCTION
Microgrids are systems that utilize renewable energy sources such as photovoltaic (PV) panels [1], wind turbines [2], and diesel generators (DG) [3], along with batteries for energy storage. The batteries in microgrids serve as backup power sources when renewable energy sources are unable to meet the energy demand [4], [5]. Ensuring the efficiency [6]- [14], stability [15], safety [16], and reliability [17] of the energy storage system is vital in microgrids.
Optimizing battery performance can be challenging due to the limited lifespan and high cost of these systems [18]- [20]. An energy management system can be used to control energy optimization in microgrids [21]- [23]. This research involves the use of a modified IEEE 30 bus as a model for optimization, taking into consideration various factors such as battery lifespan cost, maintenance cost, and fuel cost in order to determine optimal operating parameters. The aim of this study is to analyze the comparison of battery lifespan through the implementation of an energy management system in microgrids by considering various factors such as battery lifespan cost, maintenance cost, and fuel cost.
In the past, there have been difficulties in optimizing battery performance in microgrid systems. Conventional battery management methods, such as maximizing the state of charge (SOC) or controlling charging and discharging patterns, fail to consider the limited lifespan of batteries and often result in  The power output of a PV system can be calculated using the output power rate under standard test conditions, data from the system's datasheet, and information on temperature and irradiance, shown in (1).
The power output of a PV system can be calculated using the maximum module output power standard test conditions (PSTC), The actual irradiance received by the system is indicated by the variable "GC", the solar irradiance at a reference temperature of 1000 W/m 2 is indicated by the variable "GSTC", a temperature coefficient (k) for the module, the cell temperature in degrees Celsius, and a temperature standard test conditions (TSTC) of 25 degrees Celsius [24]- [26]. The output of a wind turbine can be modeled using an equation or set of equations that take into account various factors such as the wind speed, size and orientation of the turbine blades, and efficiency of the turbine itself. By inputting these variables, it is possible to predict the amount of electricity that a wind turbine will be able to generate under certain conditions, shown in (2).
The output of the wind turbine, represented by in watts, can be calculated using the wind speed variables , , , and , which represent the cut-in speed, cut-out speed, rating speed, and actual wind speed, respectively [27]- [29]. The output power of the DG can be modeled linearly based on its actual output power, as shown in (3). To predict the performance of a generator, we can use a cost function that is derived from a test heat run and values of a, b, and c from the generator's datasheet. By inputting these variables, we can estimate how much the generator will cost to operate under different conditions.
The lifetime of a battery or group of batteries (also known as a battery bank) can be extended through the use of a saving strategy called the SOC. This is typically achieved by following a specific equation or set of guidelines as shown in (4)-(6).
The SOC at a specific time, represented by ( + ) , can be determined by considering the value of the SOC at the previous time and the battery power during the time period . The minimum, average, and maximum values of the SOC, represented by SOC min, SOC mean, and SOC max, respectively, are used as indicators for the discharge of the battery and as limitations on the battery's charge [30], [31]. The power output of the batteries, represented by , should be balanced with the load in order to maintain a stable microgrid system [32], [33]. The demand for load must also be balanced in accordance with the rules of the microgrid system, following in (7).

RESULTS AND DISCUSSION
The particle swarm optimization (PSO) algorithm is a computational method that is used to find the best solution for a problem with multiple objectives. In this algorithm, each "particle" represents an individual element, and these particles can interact with each other to find the optimal solution. The PSO algorithm can be used to optimize the fitness value of a problem, which represents the best solution or position. This method can be applied to economic dispatch problems, as shown in (8).
In the PSO algorithm, the power output of generator i for particle j is represented by . To solve the optimization problem, random values for generator output must be considered within the constraints of the problem. The relative importance of different factors may vary, so it is appropriate to assign random weights to each aspect of the problem. The velocity of the particles, which determines their movement within the optimization process, is then calculated using the formula in (9). The power output from a random process is used to begin a power flow calculation. After the power flow calculation is completed, the power generation at the designated reference bus (also known as the slack bus) is checked to ensure that it falls within certain constraints. If the generation is outside of these constraints, it is adjusted by adding or subtracting generation until it falls within limits. The weighted sum method is used to evaluate the overall performance of the system, taking into account various objective functions such as speed calculation, generating cost, battery life loss cost, and the fitness value from a multiobjective problem. These objective functions are each given a weight in the weighted sum equation, where is the specific objective function, and is the weight assigned to it, the equation shown in (10).
The results obtained from this process are used to determine the best combination of generating power and the global best fitness value. The speed and position of the particles are updated based on the best particle. During each update of the speed and particles, the load flow is run, and the slack bus is checked to ensure that it remains within the constraints. The fitness value, best particle, and global best are updated and the update step is repeated until the maximum iteration value is reached. In this simulation, the initial parameters used include a particle count of 30, a weight of 0.4, a maximum iteration value of 100, and values of c1 and c2 equal to 2.
In this study, the optimal operation of a standalone microgrid is evaluated through three case studies. In the first case, the optimal operation occurs when the battery is fully charged (SOC=1). In the second case, the optimal operation occurs when the battery is fully discharged (SOC=0). In all three cases, the battery serves as both a storage device and a backup power source when the renewable energy generator is unable to meet the load demand. In the first two cases, the generator acts as a backup energy source. Figure 2 shows the load and renewable energy in the system, Figure 3 shows the optimization of the islanded microgrid using renewable energy, a battery, and a diesel engine when the battery is fully charged, and Figure 4 shows the microgrid system when the battery is empty, and the diesel engine is used to charge the battery in order to maximize its performance and lifespan.   Table 2 compares the simulation results obtained from the multi-objective function in the two different case studies. The results show a significant difference between the two cases, with a higher cost of a generation when attempting to minimize battery losses when the battery is empty. This is because the diesel engine is used more frequently in this scenario. The comparison shows that it is more cost-effective to optimize the generation cost, as the difference in generation cost is significant, and the battery can still be kept fully charged.

CONCLUSION
In this research, the PSO algorithm was used to optimize the operation of an islanded microgrid system that employs renewable energy sources, batteries, and diesel generators. The optimization aimed to find the optimal solution for the multi-objective problem that considers both battery life loss cost and generation cost. The simulation results showed that prioritizing the objective of minimizing generation cost resulted in a 0.58% decrease in battery lifetime and a generation cost of Rp 5,271,523 ($338.64 in USD). On the other hand, optimizing for battery lifetime resulted in a 0.42% decrease in battery lifetime and a generation cost of Rp 13,064,979 ($839.30 in USD).
One potential area for future work after conducting research on an integrated energy system consisting of PV, batteries, and DG using the PSO method in an off-grid setup is to carry out further optimization studies. This can involve comparing the results obtained from the PSO method with other optimization methods, such as the genetic algorithm (GA) or ant colony optimization (ACO). This can provide a deeper understanding of the potential of different optimization methods in optimizing the performance of the integrated energy system, leading to improved system efficiency and reliability. The results of these studies can also be used to guide future implementations of integrated energy systems.