A Hybrid Particle Swarm Optimization with Butterﬂy Optimization Algorithm Based Maximum Power Point Tracking for Photovoltaic Array under Partial Shading Conditions

: The key objective of this paper is to develop a photovoltaic (PV) maximum power point tracking (MPPT) algorithm based on particle swarm optimization–butterﬂy optimization algorithm (PSO-BOA) that is adapted for partial shading conditions (PSCs). Generally, conventional MPPT techniques are often unable to accurately locate the global maximum power point (GMPP) generated by partial shading in PV systems. As a result, a signiﬁcant decrease in power output occurs. The traditional particle swarm optimization (PSO) algorithm traps the local maxima point easily, while the butterﬂy optimization algorithm (BOA) has slow convergence speed and large oscillations during its use in research. To address the limitations of the aforementioned PSO and BOA algorithms, the MPPT strategy of PV systems combining PSO-BOA is presented, which can ameliorate the efﬁciency and accuracy in PSCs. In this paper, the control parameter of sensory modality in the BOA can be acquired based on logistic mapping, and the self-adaptive adjustment of the inertial weight of the PSO algorithm is designed. According to the simulation ﬁndings, the suggested method is more suitable than PSO and BOA with respect to intricate shading-induced variations in irradiance and changes in external temperatures. The average tracking time is less than 0.5 s, and the tracking accuracy is not less than 99.94%. Especially under sudden variations in irradiance and temperature conditions, the tracking time of the PSO-BOA algorithm is only 49.70% of that of the PSO algorithm and 55.63% of that of the BOA. Therefore, the MPPT method presented has the ability to improve the oscillations and result in less convergence speed, which in turn accurately tracks the GMPP.


Introduction
In the past few years, the use of non-renewable energy sources has resulted in serious environmental pollution. Hence, finding renewable energy sources has become an imminent task. Among all the alternative energy resources, sun-powered energy as an abundant and clean source of power has been extensively applied in photovoltaic (PV) power generation [1]. Furthermore, the reduction in the manufacturing costs of PV modules and the improvement in equipment efficiency in PV systems have led to an increase in applications [2]. However, under normal conditions, the conversion of light-to-electricity efficiency of PV cells is barely around 11-28%, which restricts the development of PV systems [3]. To increase the output power, it should remain steady at the Maximum Power Point (MPP) for the PV systems. Hence, maximum power point tracking (MPPT) techniques are the crucial concerns of solar PV systems. the reference [34], a method was presented to solve power point fluctuations between GMPP and LMPPS, leveraging an opposition-based reinforcement learning methodology in conjunction with the BOA. Based on the above research, it can be found that there exist some deficiencies in the BOA, such as long convergence time, as well as large oscillations during optimization.
Motivated by the research mentioned above, this paper introduces an innovative PSO-BOA algorithm for solving the slow convergence issues in the BOA while incorporating the advantages and strong robustness of the PSO algorithm. Compared to the traditional PSO and BOA methods, the proposed PSO-BOA algorithm effectively combines the benefits of both approaches while overcoming their respective shortcomings, such as the low convergence accuracy of PSO and the slow convergence and large oscillation of the BOA. Under PSCs, the PSO-BOA algorithm demonstrates remarkable accuracy in tracking the GMPP, exhibiting superior tracking speed, efficiency, and reduced oscillation. With the goal of enhancing the optimization performance of the PSO-BOA algorithm, this article introduces two modifications: a control parameter of sensory modality based on logistic mapping and the self-adaptive adjustment of the inertial weight. The simulation results suggest that the proposed algorithm effectively addresses the shortcomings of existing MPPT algorithms and offers a promising alternative for practical application in various renewable energy systems.
The subsequent sections of this article are structured as follows: Section 2 provides an overview of the multi-peak output characteristics under PSCs. Section 3 introduces the PSO-BOA algorithm utilized to control the PV system. Section 4 presents an analysis of the simulation results from MPPT techniques based on PSO-BOA, BOA, and PSO, respectively. Finally, Section 5 provides a summary of the key findings discussed in this paper.

Mathematical Model of Photovoltaic Cells
A PV cell is a semi-conductor material that absorbs energy from sunlight and allows its electrons to jump to higher energy states. The liberated electrons subsequently undergo free movement along connected conductive wires, resulting in the generation of an electric current. This phenomenon of PV conversion is called the PV effect [35]. It harnesses the PV effect to directly transform solar energy into electrical energy. Figure 1 represents the single-diode model of a solar cell. systems with the aim of mitigating the negative impact of shading and improving the tracking speed. A modified version of the BOA was proposed in the reference [33], which used a single dynamic variable as the tuning parameter, resulting in reduced algorithm complexity. In the reference [34], a method was presented to solve power point fluctuations between GMPP and LMPPS, leveraging an opposition-based reinforcement learning methodology in conjunction with the BOA. Based on the above research, it can be found that there exist some deficiencies in the BOA, such as long convergence time, as well as large oscillations during optimization. Motivated by the research mentioned above, this paper introduces an innovative PSO-BOA algorithm for solving the slow convergence issues in the BOA while incorporating the advantages and strong robustness of the PSO algorithm. Compared to the traditional PSO and BOA methods, the proposed PSO-BOA algorithm effectively combines the benefits of both approaches while overcoming their respective shortcomings, such as the low convergence accuracy of PSO and the slow convergence and large oscillation of the BOA. Under PSCs, the PSO-BOA algorithm demonstrates remarkable accuracy in tracking the GMPP, exhibiting superior tracking speed, efficiency, and reduced oscillation. With the goal of enhancing the optimization performance of the PSO-BOA algorithm, this article introduces two modifications: a control parameter of sensory modality based on logistic mapping and the self-adaptive adjustment of the inertial weight. The simulation results suggest that the proposed algorithm effectively addresses the shortcomings of existing MPPT algorithms and offers a promising alternative for practical application in various renewable energy systems.
The subsequent sections of this article are structured as follows: Section 2 provides an overview of the multi-peak output characteristics under PSCs. Section 3 introduces the PSO-BOA algorithm utilized to control the PV system. Section 4 presents an analysis of the simulation results from MPPT techniques based on PSO-BOA, BOA, and PSO, respectively. Finally, Section 5 provides a summary of the key findings discussed in this paper.

Mathematical Model of Photovoltaic Cells
A PV cell is a semi-conductor material that absorbs energy from sunlight and allows its electrons to jump to higher energy states. The liberated electrons subsequently undergo free movement along connected conductive wires, resulting in the generation of an electric current. This phenomenon of PV conversion is called the PV effect [35]. It harnesses the PV effect to directly transform solar energy into electrical energy. Figure 1 represents the single-diode model of a solar cell. Applying Kirchhoff's current law [36], the output current is represented as follows: Applying Kirchhoff's current law [36], the output current is represented as follows: where I represents the current through series resistor R s , I sh is the current through shunt resistor R sh , I ph is the photo-generated current, V D s is the voltage across D s , and I D s is the current through the diode D s . The output voltage of the solar cell is represented by V. The following Shockley equation [37] can be used to express the electric current: where η is the ideality factor of the diode; K is the Boltzmann constant, K = 1.38 × 10 −23 J/K; T is the ambient temperature; q is the electronic charge constant, q = 1.6 × 10 −19 C; R s is the equivalent series resistance; V is the output voltage of the PV array; and I is the output current of the PV array. By substituting Equation (2) into Equation (1), the I-V characteristic model is derived and represented as follows: A PV module commonly consists of numerous solar cells arranged in a series or in parallel to effectuate increased power, voltage, and current output levels. This unique design also allows PV modules to adapt to various system requirements and environmental conditions. The series configuration enables the module to generate higher voltages, making it suitable for applications that demand higher voltage levels. In contrast, the parallel arrangement ensures that sufficient current is provided, which is ideal for situations where higher current output is essential. The output characteristic is influenced by both its internal parameters and external factors, such as temperature and light intensity [38]. The equivalent circuit is depicted in Figure 2.
where is the ideality factor of the diode; K is the Boltzmann constant, K = 1.38 × 10 J/K; T is the ambient temperature; q is the electronic charge constant, q = 1.6 × 10 −19 C; R is the equivalent series resistance; V is the output voltage of the PV array; and I is th output current of the PV array. By substituting Equation (2) into Equation (1), the I-V characteristic model is derive and represented as follows: A PV module commonly consists of numerous solar cells arranged in a series or parallel to effectuate increased power, voltage, and current output levels. This unique d sign also allows PV modules to adapt to various system requirements and environment conditions. The series configuration enables the module to generate higher voltages, ma ing it suitable for applications that demand higher voltage levels. In contrast, the parall arrangement ensures that sufficient current is provided, which is ideal for situation where higher current output is essential. The output characteristic is influenced by bo its internal parameters and external factors, such as temperature and light intensity [38 The equivalent circuit is depicted in Figure 2.  The current-voltage characteristics of a PV module model [39] are represented by Equation (4): where n p is the number of lateral PV panels, n s is the number of vertical PV panels, I sc is the saturation current of the diode. The value of I ph is dependent on the intensity of the light source and temperature.
where I ph_STC is the short-circuit current under standard temperature and irradiance intensity; K i is the temperature coefficient of current change, K i = 0.003; T re f is the standard temperature, T re f = 25 • C; and G is the current irradiance intensity, while G STC is the standard irradiance intensity, G STC = 1000 W/m 2 . As stated in Equation (4), the I-V characteristic of PV modules undergoes significant alterations by external factors, such as solar irradiance and ambient temperature. The I-V and P-V curves presented in Figure 3a illustrate how different temperatures, while maintaining the same irradiance level, can influence the performance of the system. With increasing temperature, the I-V curve shifts toward a lower voltage, whereas a decrease in temperature causes the I-V curve to shift toward a higher voltage. Additionally, as indicated by the P-V curve, the power exhibits a negative correlation with the increase in temperature. Figure 3b shows the I-V curve and P-V curve at constant temperatures with varying irradiance. It is evident that a rise in solar irradiance leads to a corresponding increase in current and power. Observing Figure 3a,b, it is apparent that the MPP varies with changes in irradiance and module temperature. Hence, it is imperative to consider the impact of temperature and irradiance on PV solar systems. As stated in Equation (4), the I-V characteristic of PV modules undergoes significant alterations by external factors, such as solar irradiance and ambient temperature. The I-V and P-V curves presented in Figure 3a illustrate how different temperatures, while maintaining the same irradiance level, can influence the performance of the system. With increasing temperature, the I-V curve shifts toward a lower voltage, whereas a decrease in temperature causes the I-V curve to shift toward a higher voltage. Additionally, as indicated by the P-V curve, the power exhibits a negative correlation with the increase in temperature. Figure 3b shows the I-V curve and P-V curve at constant temperatures with varying irradiance. It is evident that a rise in solar irradiance leads to a corresponding increase in current and power. Observing Figure 3a,b, it is apparent that the MPP varies with changes in irradiance and module temperature. Hence, it is imperative to consider the impact of temperature and irradiance on PV solar systems.

Output Characteristics of Photovoltaic Array under Partial Shading Conditions
Under PSCs, when the incident irradiance on the PV panels decreases, the shaded areas experience heating, leading to the hot spot effect, which can potentially cause damage to the entire panel. To address these issues, bypass diodes are usually connected in

Output Characteristics of Photovoltaic Array under Partial Shading Conditions
Under PSCs, when the incident irradiance on the PV panels decreases, the shaded areas experience heating, leading to the hot spot effect, which can potentially cause damage to the entire panel. To address these issues, bypass diodes are usually connected in parallel with PV cells to prevent temperature rise caused by the hot spot effect. Furthermore, the multi-peak characteristics arising from partial shading are associated with the PV cells connected in series within the array. This paper presents a simulation analysis of the output characteristics of a PV array considering five PV cells under PSCs. The PV array structure is illustrated in Figure 4. parallel with PV cells to prevent temperature rise caused by the hot spot effect. Furthermore, the multi-peak characteristics arising from partial shading are associated with the PV cells connected in series within the array. This paper presents a simulation analysis of the output characteristics of a PV array considering five PV cells under PSCs. The PV array structure is illustrated in Figure 4. Each PV module configures the parameters in the simulation model described in Table 1. The simulation tests are carried out under standard irradiance conditions of 1000 W/m 2 and a standard ambient temperature of 25 °C. These tests are conducted under three different conditions, as detailed in Table 2: example 1 remains unshaded, while examples 2 and 3 are subjected to PSCs. Figure 5 illustrates a simulated diagram of the photovoltaic components tracking the MPP theory, while Figure 6 presents the P-V characteristic curve. The pseudo-code for obtaining the theoretical MPP is outlined in Algorithm 1, where the theoretical MPP and the corresponding P-V curve are derived using the same method as described in this paper. Algorithm 1. Pseudo-code of getting theory MPP 1. Setting the irradiance and temperature received by five solar panels. Each PV module configures the parameters in the simulation model described in Table 1. The simulation tests are carried out under standard irradiance conditions of 1000 W/m 2 and a standard ambient temperature of 25 • C. These tests are conducted under three different conditions, as detailed in Table 2: example 1 remains unshaded, while examples 2 and 3 are subjected to PSCs. Figure 5 illustrates a simulated diagram of the photovoltaic components tracking the MPP theory, while Figure 6 presents the P-V characteristic curve. The pseudo-code for obtaining the theoretical MPP is outlined in Algorithm 1, where the theoretical MPP and the corresponding P-V curve are derived using the same method as described in this paper. Algorithm 1. Pseudo-code of getting theory MPP 1. Setting the irradiance and temperature received by five solar panels. 2. Initialize the parameter of P max = 0, I max = 0, V max = 0. 3. Input power current voltage of five solar panels 4. If P max < power 5. P max = power   It can be observed that under non-standard irradiance intensity, the PV array demonstrates the occurrence of multiple peaks in its power output characteristic curve. The number of peaks and the power vary with the degree of shadowing. Therefore, accurately tracking the GMPP is crucial under PSCs.   It can be observed that under non-standard irradiance intensity, the PV array demonstrates the occurrence of multiple peaks in its power output characteristic curve. The number of peaks and the power vary with the degree of shadowing. Therefore, accurately tracking the GMPP is crucial under PSCs.

The Particle Swarm Optimization (PSO)
PSO [23] is a swarm intelligence optimization algorithm that mimics the search for food by a moving flock of birds in a multidimensional search space. PSO is widely adopted in solving optimization problems of nonlinear systems, owing to its advantages of rapid convergence and straightforward implementation. The velocity and position update formulas in the PSO algorithm are, respectively, expressed in Equations (6) and (7):

The Particle Swarm Optimization (PSO)
PSO [23] is a swarm intelligence optimization algorithm that mimics the search for food by a moving flock of birds in a multidimensional search space. PSO is widely adopted in solving optimization problems of nonlinear systems, owing to its advantages of rapid convergence and straightforward implementation. The velocity and position update formulas in the PSO algorithm are, respectively, expressed in Equations (6) and (7): where v t i and v t+1 i are the velocities of the i-th particle at the (t) and (t + 1) iterations; p best and g best represent the local and global optimal positions of particles. Generally, c 1 and c 2 are the acceleration factors. In the reference [23], the stochastic factors (rand 1 and rand 2 ) were multiplied by a factor of 2 to achieve a mean value of 1. This adjustment was made to ensure that the particles would "overfly" the target about half of the time. Therefore, the c 1 and c 2 are equal to 2 in this paper; rand 1 and rand 2 are the random numbers that range from 0 to 1; ω represents the inertia weight.

The Butterfly Optimization Algorithm (BOA)
The BOA [29] mimics the habits of butterflies searching for food and seeking mates in their natural habitat. Setting the BOA apart from other optimization algorithms is that each butterfly in the algorithm is equipped with its own unique odor, leading to the generation of distinct odor intensities between individuals. By releasing a higher level of odor intensity, a butterfly can attract and be perceived by neighboring butterflies. The intensity of an individual's odor is perceived by other butterflies, which is denoted by Equation (8): where f (x) represents the perceived magnitude of fragrance; c is the sensory modality; I corresponds to the stimulus intensity; and a is the power exponent that relates to the degree of fragrance absorption and is limited to [0, 1]. In theory, the sensory modality coefficient c can be assigned a value within the range [0, ∞]. However, in the iterative process, the specific value of c is determined by the particular optimization problem. During the optimal search phase of the algorithm, the sensory modality c is expressed using the following formulation: (9) where T max represents the upper bound of the number of iterations; generally, the initial value of parameter c t is 0.01 [40].
Butterflies are capable of finding food and mating partners through both global and local search strategies in nature. The BOA utilizes a switching probability, denoted as "p", that governs the shift from a wide-ranging global exploration to a concentrated local exploration. Based on a comparison of the switching probability 'p' with a random number, the BOA decides whether to execute a local search or a global search. The position updating formula is demonstrated by Equation (10), as follows: where g * is the current best-performing one in all the solutions that have been generated in the current stage; x t a and x t b represent the spatial positions of the a-th and b-th butterflies in the t-th iteration, and when a = b, the butterfly performs a local random search; r is a number that is generated randomly, 0 < r < 1; and f i is the fragrance produced by the i-th butterfly.

The Particle Swarm Optimization-Butterfly Optimization Algorithm
In the process of searching, it is simple for the PSO algorithm to fall into the local optimal solution. The main drawback of the BOA is its extended convergence time and significant oscillations during the process. To address the limitations of the PSO and BOA algorithms, the PSO-BOA algorithm incorporates the BOA search mechanism into the PSO algorithm. Specifically, the algorithm selects the search method based on comparing the generated random number with the predetermined switching probability 'p'. To enhance the algorithm's ability to identify the global optimal value, the PSO-BOA algorithm integrates two strategies. On the one hand, the strategy randomizes the spatial position of individual particles during the local search process, which explores a diverse search space and optimizes the quality of individual particles. On the other hand, the strategy utilizes both local and global optimal particles to update the position and speed of particles in the global search process, enabling the algorithm to exploit the current best solutions and refine the search trajectory toward the global optimal value. Simultaneously, the PSO-BOA algorithm adjusts the sensory modality c and the inertia weight ω in the iteration process, which accelerates the convergence rate and improves the local search performance.

Global Search
The updating criterion of the position for the global search stage in the PSO-BOA algorithm can be represented by Equation (11) as follows: where v t i is the velocity of the i-th particle at the t-th iteration; p best and g best represent the local and global optimal positions of particles; and f max represents the current optimal scent intensity value. Generally, c 1 = c 2 = 2; rand 1 and rand 2 generate a random number that falls between 0 and 1. ω represents the inertia weight.

Local Search
The updating of the position formula for the local search stage used in the PSO-BOA algorithm can be represented by Equation (12) as follows: where x t a and x t b are the spatial positions of the a-th and b-th butterflies in the t-th iteration; the parameter ω represents inertia weight; r generates a random number that falls between 0 and 1.

Parameter Control Strategy
Chaos theory has numerous applications in intelligent optimization algorithms. Logistic mapping [41] is one of the classic chaotic mapping methods in chaos theory, and its representation is shown in Equation (13): where µ is the chaotic parameter, and the value falls in [0, 4], l can be defined as the iteration count of the chaotic map. The Lyapunov index [42] is a measure for distinguishing chaotic characteristics. A larger value of the Lyapunov exponent indicates a higher degree of chaos and stronger chaotic characteristics. The Lyapunov exponent is calculated by Equation (14): where λ is the Lyapunov exponent; n h is the number of iterations of the map function; and f (·) is the first derivative of the chaotic map function. Produce a logistic diagram and a Lyapunov exponent curve of the logistic map where parameter µ is within the interval (0, 4], as illustrated in Figure 7. As illustrated in Figure 7, the bifurcation of the logistic map occurs at µ= 3.55, and with an increase in the parameter value, the range of the map gradually expands to (0, 1). When µ = 4, the logistic map exhibits chaotic behavior, leading to a sequence within the range (0, 1). The maximum Lyapunov exponent of the logistic map is calculated to be 0.6839. Consequently, the parameter µ is set to 4.
According to the logistic mapping expression, the sensory modality c in the PSO-BOA algorithm can be represented by Equation (12) as follows: The coefficient of inertia weight directly affects the particle flight speed of the PSO algorithm. A dynamic tuning strategy is utilized to alter the local and global search capabilities of the algorithm, as depicted in Equation (16): where ω 1 represents the initial inertia weight; ω 2 represents the inertia weight at the maximum number of iterations; t represents the current number of iterations; and T m represents the maximum number of iterations. In this paper, the initial value of the inertia weight is set to 0.9, and the inertia weight value of the last iteration is set to 0.2. As the iteration progresses, the inertia weight decreases from 0.9 to 0.2. A larger inertia weight in the initial stage of the iteration can maintain the strong global search ability of the algorithm, while a smaller inertia weight in the later stage of the iteration is conducive to accurate local search and facilitates algorithm convergence.

Particle Swarm Optimization-Butterfly Optimization Algorithm for Maximum Power Point Tracking of Photovoltaic Arrays System
The input variables are the current I and voltage V of PV arrays, and the duty cycle D is the particle of individuality. Simultaneously, the duty cycle D is the output variable, which is controlled by regulating the MOSFET switching behavior to achieve the desired on and off states. The flowchart of the PSO-BOA algorithm proposed in this paper is presented in Figure 8. The pseudo-code of the PSO-BOA algorithm in this paper is presented in Algorithm 2 [43].

Particle Swarm Optimization-Butterfly Optimization Algorithm for Maximum Power Point Tracking of Photovoltaic Arrays System
The input variables are the current I and voltage V of PV arrays, and the duty cycle D is the particle of individuality. Simultaneously, the duty cycle D is the output variable, which is controlled by regulating the MOSFET switching behavior to achieve the desired on and off states. The flowchart of the PSO-BOA algorithm proposed in this paper is presented in Figure 8. The pseudo-code of the PSO-BOA algorithm in this paper is presented in Algorithm 2 [43].   Update the fragrance f according to Equation (8)  Set a random number "rand" in [0, 1] 12.
If rand < p then 13.
Move to the best position according to Equation (12) 14.
Move to adjust positions according to Equation (11)  16.
End if 17. End for 18.
Update the velocity v according to Equation (6) 19.
Calculate the new fitness f value of each particles 20.
If f new < f max 21.
Update the position of best f according to Equation (7) 22.
Update the value of sensory modality c according to Equation (15)  When the termination condition is reached, the value of maximum power for the PV array is output; otherwise, the search continues. Additionally, during dynamic local shading, the output of the P-V characteristics also changes. To determine whether the algorithm needs to be restarted by detecting the degree of power change, this article defines the restart condition as shown in Equation (17).
where P k m is the effective output power value after local shading changes; P m is the maximum power output value before local shading changes.

Simulation Results
A comparative analysis is performed for the PSO-BOA, PSO, and BOA algorithms proposed in this study in order to assess their effectiveness for MPPT under four different irradiance conditions, namely, standard irradiance conditions, local shading conditions, abrupt alterations for irradiance conditions, and sudden variations for irradiance and temperature conditions. When analyzing scenarios with uniform irradiance, we compared the PSO-BOA algorithm with the P&O, PSO, and BOA algorithms. In this case, the P&O algorithm is configured with a perturbation step size of 0.005. The population size is set to 10, and maximum iteration count is set to 15 for all three algorithms. The basic parameters of these algorithms are presented in Table 3. This study utilizes a boost circuit for the PV array, which was controlled by MPPT, as depicted in Figure 9. In this study, the system uses a PV array comprising five PV panels in series. The parameters of the boost circuit are designed as follows: Cpv = 500 µF, L = 0.85 mH, C = 200 µF, R = 30 Ω, and the MOSFET frequency is set at 0.1 MHz. Table 3. Parameters of three algorithms.

Algorithm
Related Parameters   Figure 9. Structure of the MPPT system.

Optimization Results under Uniform Irradiance
Under a standard light intensity of 1000 W/m 2 and a standard ambient temperature of 25 °C, it is observed that the output power demonstrated a single peak characteristic. The P-V characteristic of the output is depicted in Figure 10. Specifically, the GMPP of the PV arrays is observed to be 8517 W.

Optimization Results under Uniform Irradiance
Under a standard light intensity of 1000 W/m 2 and a standard ambient temperature of 25 • C, it is observed that the output power demonstrated a single peak characteristic. The P-V characteristic of the output is depicted in Figure 10. Specifically, the GMPP of the PV arrays is observed to be 8517 W.   Figure 9. Structure of the MPPT system.

Optimization Results under Uniform Irradiance
Under a standard light intensity of 1000 W/m 2 and a standard ambient temperature of 25 °C, it is observed that the output power demonstrated a single peak characteristic. The P-V characteristic of the output is depicted in Figure 10. Specifically, the GMPP of the PV arrays is observed to be 8517 W. The GMPP is searched using the aforementioned four algorithms in this article. Figure 11 presents the simulation results for these four algorithms, with a simulation time of 2 s.  Figure 11 demonstrates that all four algorithms (PSO-BOA, PSO, P&O, and BOA) are capable of tracking GMPP under uniform irradiance. In this situation, the P&O algorithm can track the MPP relatively quickly, but it suffers from significant oscillations and fails to converge to the MPP. Therefore, this paper does not provide further comparisons for the other complex conditions. When reaching the stable state, the power tracked by the other three algorithms is 8517 W, which is the theoretical maximum power. However, the convergence rate of the three algorithms varies. The PSO algorithm converges rapidly but tends to exhibit fluctuations around the maximum power point for an extended period of time, whereas the BOA has the slowest convergence rate. The PSO-BOA algorithm requires the least amount of time and significantly improves the convergence speed.  Figure 11 demonstrates that all four algorithms (PSO-BOA, PSO, P&O, and BOA) are capable of tracking GMPP under uniform irradiance. In this situation, the P&O algorithm can track the MPP relatively quickly, but it suffers from significant oscillations and fails to converge to the MPP. Therefore, this paper does not provide further comparisons for the other complex conditions. When reaching the stable state, the power tracked by the other three algorithms is 8517 W, which is the theoretical maximum power. However, the convergence rate of the three algorithms varies. The PSO algorithm converges rapidly but tends to exhibit fluctuations around the maximum power point for an extended period of time, whereas the BOA has the slowest convergence rate. The PSO-BOA algorithm requires the least amount of time and significantly improves the convergence speed.

Optimization Results during Static Shading
In the setting of standard ambient temperature conditions at 25 • C, each of the five PV panels is subjected to varying light intensities: 800 W/m 2 , 800 W/m 2 , 600 W/m 2 , 600 W/m 2 , and 400 W/m 2 . In this situation, the output power of the PV array exhibits multi-peak characteristics, with the GMPP measuring at 4374 W, as depicted in Figure 12.

Optimization Results during Static Shading
In the setting of standard ambient temperature conditions at 25 °C, each of the five PV panels is subjected to varying light intensities: 800 W/m 2 , 800 W/m 2 , 600 W/m 2 , 600 W/m 2 , and 400 W/m 2 . In this situation, the output power of the PV array exhibits multipeak characteristics, with the GMPP measuring at 4374 W, as depicted in Figure 12. The GMPP at this time is determined using the three algorithms mentioned earlier.
The simulation curves of these algorithms with a simulation time of 2 s are depicted in Figure 13. The GMPP at this time is determined using the three algorithms mentioned earlier. The simulation curves of these algorithms with a simulation time of 2 s are depicted in Figure 13.

Optimization Results during Static Shading
In the setting of standard ambient temperature conditions at 25 °C, each of the five PV panels is subjected to varying light intensities: 800 W/m 2 , 800 W/m 2 , 600 W/m 2 , 600 W/m 2 , and 400 W/m 2 . In this situation, the output power of the PV array exhibits multipeak characteristics, with the GMPP measuring at 4374 W, as depicted in Figure 12. The GMPP at this time is determined using the three algorithms mentioned earlier.
The simulation curves of these algorithms with a simulation time of 2 s are depicted in Figure 13.  Figure 13 shows that both the PSO-BOA and BOA algorithms have the capability to track the theoretical GMPP accurately. However, the PSO algorithm tracks a slightly lower GMPP of 4373 W, with a deviation value of 1 W, and exhibits small oscillations even reaching the steady state (after 0.4 s). In contrast, the BOA has slower convergence and larger power oscillations. Under static shading conditions, the PSO-BOA algorithm displays sig-  Figure 13 shows that both the PSO-BOA and BOA algorithms have the capability to track the theoretical GMPP accurately. However, the PSO algorithm tracks a slightly lower GMPP of 4373 W, with a deviation value of 1 W, and exhibits small oscillations even reaching the steady state (after 0.4 s). In contrast, the BOA has slower convergence and larger power oscillations. Under static shading conditions, the PSO-BOA algorithm displays significant improvement in convergence speed and reduction in power oscillation.

Optimization Results under Abrupt Alterations for Irradiance Conditions
To test the response of a PV array to rapid changes in light intensity, this paper conducts a series of tests involving exposing the array to different light intensities at specific time intervals. Specifically, the array is devised to varying light intensities of 1000 W/m 2 , 1000 W/m 2 , 800 W/m 2 , 800 W/m 2 , and 400 W/m 2 from 0 to 0.8 s, and is then designed by 800 W/m 2 , 800 W/m 2 , 600 W/m 2 , 400 W/m 2 , and 400 W/m 2 from 0.8 to 2 s. These simulations are carried out under the environmental temperature of 25 • C, and the resulting P-V characteristics are depicted in Figure 14. During the two stages, the corresponding GMPP values of the array are 4606 W and 3337 W. Further evaluation of the system's performance is conducted by comparing the dynamic shading simulations for three algorithms with a simulation time of 2 s. The comparison is depicted in Figure 15. Figure 13 shows that both the PSO-BOA and BOA algorithms have th track the theoretical GMPP accurately. However, the PSO algorithm tracks a GMPP of 4373 W, with a deviation value of 1 W, and exhibits small oscillatio ing the steady state (after 0.4 s). In contrast, the BOA has slower convergen power oscillations. Under static shading conditions, the PSO-BOA algorithm nificant improvement in convergence speed and reduction in power oscilla

Optimization Results under Abrupt Alterations for Irradiance Conditions
To test the response of a PV array to rapid changes in light intensity, t ducts a series of tests involving exposing the array to different light intensi time intervals. Specifically, the array is devised to varying light intensities 1000 W/m 2 , 800 W/m 2 , 800 W/m 2 , and 400 W/m 2 from 0 to 0.8 s, and is the 800 W/m 2 , 800 W/m 2 , 600 W/m 2 , 400 W/m 2 , and 400 W/m 2 from 0.8 to 2 s. The are carried out under the environmental temperature of 25 °C, and the resul acteristics are depicted in Figure 14. During the two stages, the correspondi ues of the array are 4606 W and 3337 W. Further evaluation of the system' is conducted by comparing the dynamic shading simulations for three algo simulation time of 2 s. The comparison is depicted in Figure 15.  Figure 15 shows that the PSO-BOA algorithm accurately tracks the theoretical GMPP under varying irradiance conditions. The BOA also displays good performance in this regard, albeit with a slight tracking error. However, the PSO algorithm exhibits a significant deviation from the theoretical GMPP and is susceptible to local optima, thus resulting in low convergence accuracy. Furthermore, in terms of convergence time, the BOA requires around 0.7 s to converge, with more oscillations during varying irradiance conditions. In contrast, the PSO algorithm has relatively faster convergence, requiring about 0.4 s. Meanwhile, the PSO-BOA algorithm exhibits the fastest convergence time of about 0.3 s, accompanied by less oscillation, thereby demonstrating its superior tracking performance under dynamic local shading conditions. Overall, compared to both the PSO and BOA algorithms, the PSO-BOA algorithm offers improved tracking accuracy and less oscillation.  Figure 15 shows that the PSO-BOA algorithm accurately tracks the theoretical GMPP under varying irradiance conditions. The BOA also displays good performance in this regard, albeit with a slight tracking error. However, the PSO algorithm exhibits a significant deviation from the theoretical GMPP and is susceptible to local optima, thus resulting in low convergence accuracy. Furthermore, in terms of convergence time, the BOA requires around 0.7 s to converge, with more oscillations during varying irradiance conditions. In contrast, the PSO algorithm has relatively faster convergence, requiring about 0.4 s. Meanwhile, the PSO-BOA algorithm exhibits the fastest convergence time of about 0.3 s, accompanied by less oscillation, thereby demonstrating its superior tracking performance under dynamic local shading conditions. Overall, compared to both the PSO and BOA algorithms, the PSO-BOA algorithm offers improved tracking accuracy and less oscillation.

Optimization Results under Sudden Variations for Irradiance and Temperature Conditions
To evaluate the output power characteristics under harsh environmental conditions considering the influence of temperature on MPP, this paper sets the irradiance intensity of the array as 800 W/m 2 , 800 W/m 2 , 600 W/m 2 , 400 W/m 2 , and 400 W/m 2 at 0-0.8 s, while the ambient temperature is maintained at 25 °C. Later, from 0.8 to 2 s, the array experience suddenly changes light intensity to 800 W/m 2 , 600 W/m 2 , 400 W/m 2 , 200 W/m 2 , and 200 W/m 2 , while the environmental temperature is increased to 30 °C. The resulting P-V characteristics outputs are depicted in Figure 16, where the GMPP for the two stages is 3798 W and 2237 W. Figure 17 shows the dynamic shading simulations for three algorithms under harsh environmental conditions.

Optimization Results under Sudden Variations for Irradiance and Temperature Conditions
To evaluate the output power characteristics under harsh environmental conditions considering the influence of temperature on MPP, this paper sets the irradiance intensity of the array as 800 W/m 2 , 800 W/m 2 , 600 W/m 2 , 400 W/m 2 , and 400 W/m 2 at 0-0.8 s, while the ambient temperature is maintained at 25 • C. Later, from 0.8 to 2 s, the array experience suddenly changes light intensity to 800 W/m 2 , 600 W/m 2 , 400 W/m 2 , 200 W/m 2 , and 200 W/m 2 , while the environmental temperature is increased to 30 • C. The resulting P-V characteristics outputs are depicted in Figure 16, where the GMPP for the two stages is 3798 W and 2237 W. Figure 17 shows the dynamic shading simulations for three algorithms under harsh environmental conditions.  According to the findings illustrated in Figure 17, the PSO-BOA algorithm successfully tracks the theoretical GMPP with high precision. In contrast, the PSO algorithm is prone to falling into local optima after abrupt changes in irradiance and temperature, leading to significant deviations from the theoretical GMPP. Although the BOA can track the theoretical GMPP, the error is still greater than that of the PSO-BOA algorithm. As for convergence speed, the PSO-BOA algorithm shows the fastest convergence speed and the According to the findings illustrated in Figure 17, the PSO-BOA algorithm successfully tracks the theoretical GMPP with high precision. In contrast, the PSO algorithm is prone to falling into local optima after abrupt changes in irradiance and temperature, leading to significant deviations from the theoretical GMPP. Although the BOA can track the theoretical GMPP, the error is still greater than that of the PSO-BOA algorithm. As for convergence speed, the PSO-BOA algorithm shows the fastest convergence speed and the least oscillation. Conversely, the PSO algorithm converges extremely slowly after a sudden change in conditions, oscillating around GMPP. The BOA converges slowly with a large power oscillation amplitude. Notably, in harsh environmental conditions, the PSO-BOA algorithm outperforms different algorithms in the context of both convergence speed and power oscillations.

Statistics of Results and Analysis
To provide a clearer insight into the performance indicators of each algorithm, statistical tables are created summarizing the results obtained using the above-mentioned three algorithms. The performance of each algorithm is assessed originating from various evaluation metrics, including convergence time, optimization value, projected annual loss cost, and tracking efficiency, as shown in Table 4. As illustrated in Table 4, the PSO-BOA algorithm outperforms both the BOA and PSO in all four simulations, achieving faster and smoother convergence to GMPP. It is worth noting that the PSO-BOA algorithm shows a faster convergence speed. The convergence time of PSO-BOA is 54.43% relative to PSO and 57.33% relative to the BOA under uniform irradiance, and is reduced to 37.5% relative to PSO and 51.22% relative to the BOA under local shading conditions. Based on the local electricity prices and assuming an average daily sunlight duration of 12 h, this study calculates the annual cost of losses. In scenarios with abrupt lighting condition changes, the PSO algorithm results in the highest annual loss cost, whereas the PSO-BOA algorithm proves effective in mitigating these losses and reducing costs. Meanwhile, the PSO algorithm achieves faster convergence in cases of sudden changes in irradiance and temperature, but is more prone to falling into local optima, resulting in the worst convergence accuracy. The convergence rate of the BOA is sluggish, with many oscillations occurring over the course of convergence. In contrast, the PSO-BOA algorithm is able to maintain stable and higher optimization accuracy than both the BOA and PSO across all four simulations. These results suggest that the PSO-BOA algorithm effectively addresses the issues of large search oscillation in the BOA and low optimization accuracy in PSO while also improving convergence speed.

Conclusions
In response to the issues of low tracking accuracy and susceptibility to local optima in classical PSO algorithms, as well as the problems of slow convergence speed and large oscillation in the BOA, this study introduces a novel PSO-BOA algorithm based on the PSO and BOA. The paper simulated four different scenarios, and the simulation results demonstrate that the PSO-BOA algorithm outperforms the PSO and BOA in terms of convergence accuracy, with a tracking accuracy of no less than 99.94%. In contrast, the PSO algorithm is prone to becoming trapped in local optima, resulting in a convergence accuracy of only 96.96% when both irradiation and temperature undergo abrupt changes. The PSO-BOA algorithm also surpasses both the PSO and BOA algorithms in handling oscillations. In terms of convergence time, the PSO-BOA algorithm shows a significant improvement. Particularly, in scenarios of abrupt changes in irradiation and simultaneous changes in temperature and irradiation, the convergence time of PSO-BOA is less than 0.5 s, while the BOA takes approximately double the time compared to the PSO-BOA. Moreover, the convergence time of the PSO algorithm is relatively longer, and it tends to converge quickly but may be trapped in local optima. Therefore, the proposed algorithm exhibits faster convergence speed, higher tracking accuracy, and smaller oscillations compared to both the PSO and BOA algorithms, which can effectively enhance power supply reliability and safety.