A Novel Prairie Dog-Based Meta-Heuristic Optimization Algorithm for Improved Control, Better Transient Response, and Power Quality Enhancement of Hybrid Microgrids

The growing demand for electricity driven by population growth and industrialization is met by integrating hybrid renewable energy sources (HRESs) into the grid. HRES integration improves reliability, reduces losses, and addresses power quality issues for safe and effective microgrid (MG) operation, requiring efficient controllers. In this regard, this article proposes a prairie dog optimization (PDO) algorithm for the photovoltaic (PV)-, fuel cell (FC)-, and battery-based HRESs designed in MATLAB/Simulink architecture. The proposed PDO method optimally tunes the proportional integral (PI) controller gain parameters to achieve effective compensation of load demand and mitigation of PQ problems. The MG system has been applied to various intentional PQ issues such as swell, unbalanced load, oscillatory transient, and notch conditions to study the response of the proposed PDO controller. For evaluating the efficacy of the proposed PDO algorithm, the simulation results obtained are compared with those of earlier popular methodologies utilized in the current literature such as bee colony optimization (BCO), thermal exchange optimization, and PI techniques. A detailed analysis of the results found emphasizes the efficiency, robustness, and potential of the suggested PDO controller in significantly improving the overall system operation by minimizing the THD, improving the control of active and reactive power, enhancing the power factor, lowering the voltage deviation, and keeping the terminal voltage, DC-link voltage, grid voltage, and grid current almost constant in the event of PQ fault occurrence. As a result, the proposed PDO method paves the way for real-time employment in the MG system.


General Background
In recent decades, electric grid networks have been involved in a variety of challenges, such as the use of fossil fuels and thermal production, which generates energy with crucial emissions that are costly, polluting, and fuel-depleted [1]. Subsequently, researchers have proposed the deployment of renewable energy sources (RESs) in the last few years because of the merits such as being environment friendly and abundantly available, energy security, decreased line losses, low operating costs, and ability to mitigate emissions and global warming [2]. Furthermore, due to the rising population and increased industry, the power demand has recently risen significantly. Hybrid renewable energy sources (HRESs) are being incorporated into the grid to meet the rising electricity demand, improve dependability, lower losses, and reduce the use of fossil fuels, which contribute to pollution [3]. Numerous HRESs such as photovoltaic (PV) [4], fuel cell [5], wind energy [6], and biomass [7] are integrated along with local loads and storage units to form a small entity of an electrical grid network termed a microgrid (MG) system [8]. In this article, the PV-based RES has been used for its numerous advantages such as [4] (1) no fuel cost, (2) extensive power expansion, (3) ease of operation even on a building's rooftop, (4) low maintenance costs, (5) being plentily available, (6) being eco-friendly, (7) high reliability, and (8) being noiseless. To form an HRES, FC has been integrated with PV due to the following merits [5] (1) ease of use, (2) increased efficiency, (3) less hazardous pollutants, (4) increased modularity, (5) massive CHP, (6) increased stability, and (7) cost-effectiveness. But the major demerits associated with PV/FC systems are that PV supply is dependent on temperature and irradiance, FC response is sluggish, and at higher temperatures, the cost of the material rises, making it uneconomical to use. Therefore, this research article proposes the hybridization of battery-based energy storage units (due to high energy storage capability) [9] with PV/FC to competently meet the power demand as well as improve the performance, fuel economy, stability, and reliability of the MG system.

Motivation
The high penetration of HRESs into the MG network poses many challenges to stability and safe operation due to the intermittent nature of RESs, different types of sources (AC/DC) produced by RESs, several levels of generation of voltage by RESs, and the fact that they are environment-dependent [10]. The key to overcoming such difficulties is to employ power electronics interfaces (PEIs) that would maximize the power extracted from each HRES as well as convert the DC output to AC supply for necessary grid integration [11]. Nevertheless, the employment of PEIs in the MG system results in numerous power quality (PQ) issues, including the introduction of harmonics and system disruptions [11]. These disruptions must be addressed as they pose a threat to equipment on the load and source sides and may result in improper functioning and overheating. There are several types of PQ problems as reported in the literature such as harmonics, voltage sag, voltage swell, voltage interruption, oscillatory transient, flicker, notch, frequency deviation, etc. [12]. Of all of these problems, voltage interruption and voltage drop on the utility side cause the most problems, whereas harmonic distortion is on the customer side. To ensure the safe and consistent operation of the MG system, these PQ disturbances need to be substantially removed and efficiently dealt with. Due to their non-linear nature, these PEIs require robust control to increase power quality and efficaciously complete other control goals including voltage, frequency, and power flow management.

Literature Review
In this section, a comprehensive review of the available literature published by various researchers has been carried out regarding the different control strategies for optimal control of MG systems for enhanced power quality, efficient dynamic response, better energy management, and an overall increase in the efficiency of an MG system.
The use of classical controllers, such as proportional-integral (PI) controllers and proportional-integral-derivative (PID) controllers, is justified by their simplicity of installation, low cost, and quick computation times. However, the fact that PI and PID controllers are linear means they fail to respond robustly to these PQ disturbances. To obtain optimized control parameters of these linear controllers, many optimization methods have been applied. The authors of [13] have applied the Harris Hawks algorithm technique to optimize DVR controllers for improving the voltage quality of a low-voltage smart distribution system. The grasshopper optimization algorithm has been applied to D-FACTS for optimal tuning of PID control parameters to improve the power quality [14]. Masoud Dashtdar et al. have introduced a hybridization of the genetic algorithm and particle swarm optimization for enhancing the PQ of autonomous MG systems with voltage and frequency control [15]. The researchers in [16] have discussed the application of atom search optimization to bring about PQ enhancement in grid-connected PV/wind/battery with UPQC. Touqeer Ahmed Jumani et al. have applied the salp swarm optimization method to islanded MG for ensuring dynamic response and PQ improvement during faulted conditions [17]. A robust LFC-based African vulture optimization algorithm has been proposed by the authors for optimizing a hybrid MG's frequency response under variable renewable source conditions [18]. Some of the other popular techniques used for PQ enhancement in MG are Aquila optimizer [19], fuzzy logic controller [20], adaptive-network fuzzy inference [21], green leaf-hopper flame optimization [22], SVM-based random subspace [23], chaotic butterfly optimization [24], deep convolutional neural network [25], artificial neural network [26], wavelet-fuzzy [27], support vector machine [28], model predictive control [29], stochastic dynamic programming [30], quantum teaching learning-based optimization [31], multiagent system [32], crow search optimization technique [33], amended penguin optimization algorithm [34], and squirrel search algorithm [5]. Thorough study and analysis of popular contemporary algorithms available in the literature have been conducted. The merits and demerits have been summarized in Table 1 below for an easy understanding for readers and to evaluate the effectiveness of the new technique proposed in this research article. Table 1. Summary of existing popular contemporary algorithms highlighting merits and demerits.

Control Strategy/Algorithm Merits Demerits
Proportional Integral • Implementation is straightforward.

•
The system exhibits a linear response.

•
No steady-state error is present.
• Fails to effectively handle nonlinear and imbalanced systems.

•
The range of stability is extremely limited. A meticulous literature survey on all available popular optimization techniques (OTs) has been carried out and presented in Table 1. A critical analysis of the literature has led to the conclusion that there has been a push for improved versions of current algorithms or entirely new ones as there is no solitary OT that can deliver optimum results for all optimization issues. Additionally, there is also the requirement to deliver robust methods that will continually accomplish improved results. The result is that an OT's resilience and efficacy are restricted to dealing with a certain set of challenges, rather than dealing with all possible problems. Numerous researchers have developed fresh, nature-inspired metaheuristic algorithms or enhanced tried-and-true ones, with varied degrees of success. In this regard, the authors of [35] have recently proposed a novel, nature-inspired method called prairie dog optimization (PDO) for solving unconstrained numerical optimization problems. This technique has not been explored much in the area of PQ enhancement in MG and has many advantages in comparison to other available techniques in the literature, which gave us the inspiration to apply it for the present study.
The following are the major merits of the PDO algorithm: 1. PDO is very capable of maintaining a well-balanced exploration and exploitation strategy.

2.
Compared to the other algorithms, PDO has good efficiency and better abilities.

3.
For real-world optimization issues with uncertain global optima, PDO is competent for predicting global optimum.

4.
In comparison to other popular optimization techniques that have been studied, PDO exhibits more stable convergence.

5.
Each clique performs optimization tasks within its domain or boundary, making effective use of the division of labour in the PDO. 6.
The digging strength (DS) and predator impact (PE) qualities, which specifically affect the PDO updating process, are included in the models of the forage and burrow-building activities (exploration), communication, and anti-predation (exploitation) activities.

Major Contributions
The major contributions, motivation, and implications of this research article are described in brief below: • Design, simulation, and optimal control of PV-, FC-, and battery-based HRESs for MG application with PQ enhancement in MATLAB/Simulink environment and application of suggested robust PDO algorithm to dynamically tune the PI gain parameters for ensuring improved PQ, system efficacy, and reliability. • Verification of the efficiency and validation of the proposed controller by subjecting the HRES-based MG system to severe intentional PQ disturbances such as voltage swell, unbalanced load, oscillatory transient, and notch conditions. Furthermore, the evaluation of system characteristics and dynamics by comparing the proposed PDO technique with the traditional TEO algorithm, BCO algorithm, and PI controller.

•
Comprehensive contrast study of different system characteristics at the grid side subjected to numerous PQ faults (swell, unbalanced load, oscillatory transient, and notch) such as active power, reactive power, apparent power, voltage deviation, power factor, frequency, THD, DC-link voltage, grid voltage, and grid current for the conventional and proposed techniques along with critical analysis of obtained numerical values for the suggested PDO technique and the conventional TEO, BCO, and PI methods by tabulating all control gain parameters (K p and K i ) and system parameters (terminal voltage (Volt), DC-link voltage (volt), voltage deviation (p.u.), active power (watt), reactive power (Var), apparent power (VA), THD (%), power factor, frequency (Hz), grid voltage (p.u.), and grid current).

Paper Organization
The complete research paper has been summarized as follows. Section 2 illustrates the detailed mathematical modelling of the HRES (PV/FC/battery)-based MG system. The proposed and traditional control approaches are discussed in detail in Section 3 with mathematical concepts and flowcharts. The MG system model designed in the Matlab/Simulink environment and the comparative results analysis for the conventional and proposed control methods are highlighted in Section 4. Finally, in Section 5, the conclusion is presented. Figure 1 is a diagrammatic illustration of the entire research work carried out highlighting the main concepts.

Microgrid Component Modelling
To justify the efficacy, reliability, and robust performance of the proposed PDO algorithm, a PV/FC/battery-based HRES for an MG network has been considered for this study and has been designed in Matlab/Simulink architecture. Furthermore, detailed modelling of all system components such as PV, FC, battery, and boost converter has been elaborated and the values considered for each power system unit have been provided in Appendix A.

Photovoltaic
A PV system converts solar energy into electrical energy using solar irradiance as a source of energy and is regarded as one of the most important renewable-based distributed energy resources because it is eco-friendly, has no noise pollution, requires minimal maintenance, and uses no fuel [36,37]. The basis of a PV system is the concept that solar cells convert light energy into electrical energy when it strikes them. The PV panel behaves as a current source, producing a photoelectric current that can be mathematically calculated from Equation (1) given below [4]:

Microgrid Component Modelling
To justify the efficacy, reliability, and robust performance of the proposed PDO algorithm, a PV/FC/battery-based HRES for an MG network has been considered for this study and has been designed in Matlab/Simulink architecture. Furthermore, detailed modelling of all system components such as PV, FC, battery, and boost converter has been elaborated and the values considered for each power system unit have been provided in Appendix A.

Photovoltaic
A PV system converts solar energy into electrical energy using solar irradiance as a source of energy and is regarded as one of the most important renewable-based distributed energy resources because it is eco-friendly, has no noise pollution, requires minimal maintenance, and uses no fuel [36,37]. The basis of a PV system is the concept that solar cells convert light energy into electrical energy when it strikes them. The PV panel behaves as a current source, producing a photoelectric current that can be mathematically calculated from Equation (1) given below [4]:

Fuel Cell
A fuel cell (FC) is an electrochemical system that oxidizes fuel to generate electricity [5]. Researchers have reported several types of FCs in the literature. Of these, the proton exchange membrane fuel cell (PEMFC) is considered to be the most economical because of the following merits: (1) ease of use, (2) increased efficiency, (3) less hazardous pollutants, (4) increased modularity, (5) massive CHP, (6) increased stability, (7) cost-effectiveness, (8) flexibility in input fuel, (9) fast startup, (10) lightweight, (11) compact design, and (12) solidity of electrolyte [38]. An FC's output voltage and its general equations can be represented as [5]:

Battery
Batteries are widely regarded as potent energy storage technology that can be employed in a wide range of electrical implementations. Due to their enormous energy storage capacity, they perform better than other available energy storage devices. Batteries are made up of components that convert electrical energy into chemical energy and vice versa [39]. Batteries provide a steady voltage and a significant lift. They can change the frequency through the absorption or injection of power into the load during frequency changes. Numerous types of battery-based energy storage units have been reported, like lead-acid, lithium-ion (Li-ion), nickel cadmium (Ni-Cd), nickel-metal hydride (Ni-MH), etc. However, Li-ion has normally been employed for application in MG systems due to many advantages such as (1) less self-discharging ability; (2) more charging and discharging cycles; (3) better efficiency; (4) higher energy density; and (5) being more economical [40].
Kirchhoff's voltage law (KVL) is applied to a simplified battery model made up of a voltage source, resistances, and capacitors, and the output voltage of a Li-ion battery can be found as given in Equation (7) below [9]:

Boost Converter
A boost converter is a DC-DC converter that enhances the output voltage concerning its supply voltage and functions through a pulse width modulation (PWM) technique for controlling the switching states of the switches [5]. It has a low to medium efficiency range. The output voltage is mathematically calculated as in Equation (8) [5]:

Buck/Boost Converter
The HRES employs a buck/boost converter with the objective of transmitting power in two directions. It has the characteristics of being lightweight and having compact volume and high reliability. Its ability to function as a buck converter and a boost converter in reverse directions depends on the functioning of two switches that are regulated by a PWM signal [41]. Both switches function simultaneously and alternately.

Proportional Integral (PI) Controller
The PI controller is a conventional, linear, closed-loop, and easy-to-implement control method. It comprises the proportional and integral controller with gain parameters K p and K i , respectively. K p enhances the rise time and K i reduces the steady-state error to ensure the overall control action. The primary drawback of the PI controller is that because of its linearity, it is unable to respond effectively to any non-linearities in the electrical grid network; as a result, additional techniques must be used to dynamically change the gain parameters. Mathematically, the PI controller can be presented as in Equation (9) [42]:

Bee Colony Optimization (BCO)
In the past, academics have been attentively examining the swarm behaviour of social insects to develop various intelligent optimization strategies. A unique kind of insect, honeybees can locate sustenance, i.e., nectar, even in erratic and dynamic environments, which makes them an enchanting insect [43]. Their effective foraging activity is mostly responsible for making this possible. Worker bees are the types of bees that are in charge of collecting and searching for nectar. They preserve the food they have collected for the bee community's use in the future. The scout bee, a different type of bee, roams the region around its hive. Scout bees return to their hives after exploring new areas to notify the remaining bees of the location, nature, and abundance of available food sources. If these bees are successful in finding nectar, they perform a ritual dance known as the "waggle dance" inside the hive to entice and encourage their colony mates to follow them. A bee leaves its hive when it decides to follow the scout bee to gather nectar. It decides for one of the cases after returning [44]:

1.
With a waggle dance before leaving the nectar spot, it can begin enlisting the help of its hive friends.

2.
Without using any additional bees from the beehive, it can continue foraging at the discovered nectar supply.

3.
It can become a loose follower and fully turn its back on the food source.
BCO mostly uses a hive of bees known as "artificial bees" that are looking for the best solution. Every artificial bee, unlike worker bees, is capable of coming up with a fresh idea. The forward and backward passes of each BCO iteration step are regarded as alternating phases.
(i) Forward Pass: Every artificial bee involved in this operation participates in the foraging process individually [45]. As a result, no information is shared during this stage. Specific motions are used to either generate a new component of the solution or modify an existing one as part of the exploration of new areas. As a function of the parameter FP, the number of moves carried out during a single forward pass is taken into account. It typically controls how quickly bees communicate information. In other words, it chooses how many passes forwards and backwards should be made throughout each cycle.
(ii) Backward Pass: All artificial bees share information about newly discovered places in the event of a backward pass. Keeping the best and worst options in mind, the information shared determines the quality of the partial solutions obtained.
Each bee decides whether or not it will remain dependable toward the nectar source depending on the quality of the solution. When artificial bees lose their loyalty, they become disloyal and are forced to join one of the recruiters' suggested solutions [45]. The better ideas found by recruiters have a higher likelihood of being chosen for further investigation. A bee chooses whether to stick with the earlier discovered result after completing its forward pass. This decision is based simply on how good the result is compared to other results. Equation (10), given below, can be used to determine the likelihood that the nth bee will adhere to a previously discovered result [43]: where s n signifies the value of a partial or full solution normalized by the nth bee, s mn signifies the highest value of the overall partial/complete solution, and i reflects the number of forward passes i = 1, 2, . . . , FP). By letting the uncommitted bees weigh the value of the solutions offered, a recruiter is chosen for all of the uncommitted bees. The mathematical formulation of the possibility that the nth partial/complete answer is chosen by any uncommitted bee is as follows [43]: Here, the normalized value of the objective function for the ath promoted solution is indicated by s a . R stands for the number of bees that are recruiters in this equation.
It can be used to solve a variety of challenging combinatorial optimization issues. In comparison to other techniques, it is more versatile and exhibits faster convergence with fewer configuration factors [43]. Nevertheless, the main demerits associated with BCO are as follows: (1) the study of the actions or characteristics of a single agent will not help to gather information about the whole swarm. Hence, choosing swarm-defeating behaviour will be difficult. (2) Since the action path is probabilistic, a single agent's response is unpredictable and noisy, and (3) designing a swarm-based system is challenging since there is no analytical method.

Thermal Exchange Optimization (TEO)
According to the law of cooling by Newton, a body loses heat at a rate that is proportional to the temperature differential between it and its surroundings. According to Newton's own words, the following describes the law of cooling: "For the iron's heated air to always be blown away due to the wind and chilly air to alternately succeed it, and to obtain a heat level equivalent to the iron's heat, the iron wasn't set up in a quiet environment, nonetheless, in a wind that blew evenly onto it". Several textbooks provide the contemporary lumped parameter technique for transient cooling. The physical characteristics are taken to be constant, and the heat transfer coefficient is taken to be h. The solid's shape section is unimportant (except that h's calculation will be impacted). When the object is suddenly relocated to a different environment, it is swiftly chilled to a consistent temperature by the fluid in the area. The object begins at a high temperature at time t = 0. V is the solid's volume, while A is its surface area.
The rate at which heat is lost through the surface can be mathematically denoted as [46].
where A = heat flow area; T 0 = high temperature; T b = constant temperature; h = temperature coefficient; Q = heat loss from the surface. Heat loss over time dt is the same as the difference in heat as the temperature stored drops dT h(T a − T b )A dt [46]. (13) where V = volume; ρ = density; and c = specific heat.
The integration results in [47] The integration is only effectively valid when hA V ρc does not change, i.e., not influenced by T, so it can be written as [47] Equation (12) can be represented as [47] Finally, Equation (12) may be rewritten as follows [47]: The opposite strategy from the TEO method has been adopted, where a few agents are designated as cooling items and the rest are meant to represent the environment [48]. TEO has many advantages such as [49] (1) minimum initial cost and operating cost; (2) low heat transfer area; (3) fewer pressure drops; and (4) capability of reducing the thermal resistance and obtaining a relatively high surface temperature. However, a few drawbacks associated with the TEO algorithm are that (1) the optimization problem is complicated and (2) the algorithm only allows for a certain number of iterations.

Basic Concepts
The PDO algorithm mimics the activities of four prairie dogs (PDs) to achieve optimization. The optimization problem domain is explored using the PDs' feeding and burrow-building behaviours. The PDs' tunnels are built upon a bountiful food source. As the current food source runs out, they search the entire colony or problem space for other food sources or solutions [35]. They create new tunnels around each new food source they uncover. The distinctive responses of the PDs have been employed for two different alarm or communication sounds. The sounds or signals used by PDs can indicate anything from the presence of predators to the availability of food. The PDs exceptional communication skills enable them to fulfil their nutritional requirements and defend themselves against predators. When the PDO is implemented, these two separate behaviours induce the PDs to gather in a certain spot or a promising area, after which exploitation is carried out to discover better or nearly ideal solutions. The herbivorous burrowing rodents known as PDs are found in the Great Plains, the southwest desert grasslands of the United States, the regions surrounding the plains and plateaus of Canada, and Mexico [50]. The PD is related to the Sciuridae family of squirrels, which also includes ground squirrels and chipmunks.

Inspiration of PDO
The five species of PDs are black-tailed, Gunnison's, white-tailed, Utah, and Mexican. The black-tailed type is the one that is most frequently observed at Badlands National Park [35,51]. A PD weighs 1-3 pounds and can grow to a maximum length of 14-17 inches. PDs have acquired some morphological adaptations, such as short, muscular arms and very large toenails, to thrive in their environment. These characteristics allow them to run up to 35 mph over short distances and build tunnels to escape predators and reach the safety of their burrows [52]. PD habitats are exposed to natural threats like drought, prairie fires, floods, hailstorms, and blizzards.

Habitat and Burrowing
The habitats are located between 2000 and 10,000 feet above sea level and have summer highs of 38 • C (100 • F) and winter lows of −37 • C (−35 • F). The PDs' burrow homes give them vital defence against environmental hazards and aid in regulating their body temperatures [35,53]. A colony has 10 to 100 burrow openings per acre. Figure 2 shows the perimeter of the burrows. The ecosystem depends on the burrows. Changing the region's soil composition lessens soil compaction and minimizes erosion by channelling rainwater into the water table.
Sensors 2023, 23, x FOR PEER REVIEW 12 of 42 Habitat and Burrowing The habitats are located between 2000 and 10,000 feet above sea level and have summer highs of 38 °C (100 °F) and winter lows of −37 °C (−35 °F). The ' burrow homes give them vital defence against environmental hazards and aid in regulating their body temperatures [35,53]. A colony has 10 to 100 burrow openings per acre. Figure 2 shows the perimeter of the burrows. The ecosystem depends on the burrows. Changing the region's soil composition lessens soil compaction and minimizes erosion by channelling rainwater into the water table. The burrows are between 5 and 10 m long and 2 and 3 m deep, and the tunnel entrances (up to six) are typically 10 to 30 cm in diameter. The entrances to ' burrows are typically just flat holes in the earth, but on rare occasions, will build mounds of dirt to enclose them. The rim craters are 1 m high and the dome craters range in complexity and size from 20 to 30 cm [50]. Both craters protect the tunnel from flooding and aeration while also acting as observation posts for watching out for predators. In addition, the burrows have a variety of units for various uses, such as nursery chambers for their younglings, listening stations, chambers for night and winter, storerooms, and rear entrances for numerous escape routes, as depicted in Figure 2 [54].

Social Organization
The incredibly amiable have underground colonies or communities. They construct their colonies underground to perfectly accommodate their natural surroundings. A colony with an area of 25,000 square miles has been reported. It is known that live in large colonies (1-1000 acres) [50]. Regardless of the size of the colony, the subunits' complications and capabilities are the same. Each family unit resides in a ward, which can The burrows are between 5 and 10 m long and 2 and 3 m deep, and the tunnel entrances (up to six) are typically 10 to 30 cm in diameter. The entrances to PDs' burrows are typically just flat holes in the earth, but on rare occasions, PDs will build mounds of dirt to enclose them. The rim craters are 1 m high and the dome craters range in complexity and size from 20 to 30 cm [50]. Both craters protect the tunnel from flooding and aeration while also acting as observation posts for watching out for predators. In addition, the burrows have a variety of units for various uses, such as nursery chambers for their younglings, listening stations, chambers for night and winter, storerooms, and rear entrances for numerous escape routes, as depicted in Figure 2 [54].

Social Organization
The incredibly amiable PDs have underground colonies or communities. They construct their colonies underground to perfectly accommodate their natural surroundings. A PD colony with an area of 25,000 square miles has been reported. It is known that PDs live in large colonies (1-1000 acres) [50]. Regardless of the size of the colony, the subunits' complications and capabilities are the same. Each family unit resides in a ward, which can hold around 10 to 30 family coteries, inside the colony or town. To keep the groupings stable, the female offspring usually remain in their natal coterie throughout their entire lives. The male children, however, typically leave their coterie once they reach sexual maturity in pursuit of a new family. PDs are fiercely territorial, and their lines of demarcation correspond to natural barriers like trees and rocks. A challenger from another family is repelled by the dominant male in a coterie to protect his territory [51].
PDs spend most of their days feeding, watching out for predators, digging new burrows, or maintaining those that already exist. Various components begin the optimization process of scavenging from one food source to another. Although they do consume some insects, PDs are primarily herbivorous. They travel from one place to another during the year, typically consuming grasses, very small seeds, and certain insects as they look for problems [53]. They lift their heads or stand on their hind legs while foraging to watch out for predators. The coterie looks for areas without existing burrows but that are well-suited for creating new burrows. A defined role that improves the town, ward, or coterie must be served by the location of the new burrows. In this way, exploring is enhanced much more.

Communication and Anti-Predation
One distinguishing attribute of PDs' nature is communication, and the PDs' unique response to different sounds makes it possible to use the recommended method. The majority of scientists concur that PDs possess a critical animal language that is yet to be discovered [35]. Although to us, the PDs' "bark" might merely seem to be a simple squeak or yippee, to a PD, it has far deeper meanings [35]. The sounds or signals used by PDs can indicate anything from the presence of predators to the availability of food. The PDs' ability to communicate has a substantial impact on their ability to ward off predators. They can distinguish between various predators and their distinctive hunting styles [55]. This behavioural adaptation is thought to result from the necessity for a varied reaction or set of survival abilities in response to the various predator hunting tactics. For example, if the signal identifies a hawk as the predator, only PDs in the hawk's flight path hide, while others keep watching from their burrows [56]. In the case of coyotes, they only watch from their tunnel entrances, but when they see human predators, they collectively retreat into their burrows. Exploitation is accomplished using an exact reply to a particular sound. The coteries respond appropriately to the various distinct sounds, which are compared to calls to prospective places. The core of the suggested PDO is this ongoing cycle of behaviours [35].

Mathematical Model Formulation and Algorithm of PDO Assumptions and Implementation
To facilitate the creation of the models for the proposed PDO, the following presumptions were made [35], and the corresponding specification of parameters is provided in Appendix A:

1.
Each prairie dog is a member of one of the m coteries that make up the colony, each of which has n prairie dogs.

2.
The m groups of prairie dogs are further divided into identical subgroups.

3.
Every coterie resides in a colony ward, or the problem search space equivalent.

4.
Each ward has a minimum of ten burrow entrances, which increases to a hundred as nest building activities take place.

5.
An antipredation call and a call for a new food supply (a new burrow being built) are two separate noises that are used. 6.
Only individuals from the same coterie engage in foraging, burrow construction (exploration), communication, and anti-predation (exploitation) behaviours. 7.
The exploration and exploitation actions are repeated m (number of coteries) times since other coteries in the colony are working on the same things at the same time.
Initialization PDO uses an arbitrary initialization for the position of the PDs, just like other populationbased methods. The populations of PDs serve as the search agents, and each PD is represented in d-dimensional space by a vector.
A coterie's PDs are each a part of one of the n coteries. A vector may locate each PD inside a certain coterie because the PD exists and functions as a group or coterie. The matrix given below represents the position of each coterie (CT) in a colony [35]: where CT i,j stands for the ith coterie's jth dimension. The equation below represents the position of each prairie dog in a coterie [35].
where PD i,j stands for the ith prairie dog in a coterie's jth dimension. According to the equations given below, a uniform distribution is used to distribute each CT and PD site [35].
where ub j = UB j m , lb j = LB j m , U (0, 1) is a uniformly distributed random number between 0 and 1. UB j and LB j are the upper and lower bounds of the jth dimension of the optimization problem respectively.

Fitness Function Evaluation
The defined fitness function receives the solution vector and computes the fitness function value for each PD's location. The array shown below contains the values that are obtained [35].
The fitness function values for each PD represent the quality of the food available at a specific source, the ability to create new burrows, and the capability of responding effectively to anti-predation alerts. The achieved minimal fitness value is regarded as the best solution to the given minimization problem so far. The fitness function values are stored in an array that is sorted. For making burrows that aid in their ability to escape predators, the next three are taken into account along with the best value.

Exploration
In this part, the PDO exploratory method is explained, as shown in Figure 3a. The optimization problem domain is explored using the PDs' feeding and burrow building behaviours. The PDs' tunnels are built upon a bountiful food source. As the current food source runs out, they search the entire colony or problem space for other food sources or solutions [35]. They create new tunnels around each new food source they uncover. The burrows are necessary for both environmental and predator defence. All PDs live in towns or colonies, and each colony is organized into family groups or coteries with specific colonial borders. Only the presence of a predator stops the several coteries from feeding and excavating burrows together within their boundaries. towns or colonies, and each colony is organized into family groups or coteries with specific colonial borders. Only the presence of a predator stops the several coteries from feeding and excavating burrows together within their boundaries. Based on four criteria, PDO might choose between exploration and exploitation. The maximum number of iterations is divided into four parts: the first two are for exploration and the last two are for exploitation.
The two techniques for exploration are dependent on [35] < and ≤ < whilst the two strategies for exploitation are dependent on

≤ ≤ 3 and 3 ≤ ≤
In the exploration phase, the coterie's initial tactic is to have members scour the ward for fresh food sources. The Levy flight motion best depicts the motion of the s as they search for food. Because of the distinctive large hops, this movement prevents an exhaustive search of a given place yet effectively searches a variety of areas (exploration). They produce characteristic noises to alert other individuals of the discovery of food sources. Following the quality of the food source, the best is accessed, chosen for foraging, and new burrows are constructed. In the algorithm's exploration phase, foraging position updating is provided by the equations given below [35].
where , evaluates the effects of the most effective solution currently acquired worldwide and , signifies the best solution currently available globally. signifies the location of a random solution, , denotes the randomized cumulative effect of all prairie dogs in the colony, and designates the experiment's specialized food source alarm set at 0.1 kHz. Based on four criteria, PDO might choose between exploration and exploitation. The maximum number of iterations is divided into four parts: the first two are for exploration and the last two are for exploitation.
The two techniques for exploration are dependent on [35] iter < In the exploration phase, the coterie's initial tactic is to have members scour the ward for fresh food sources. The Levy flight motion best depicts the motion of the PDs as they search for food. Because of the distinctive large hops, this movement prevents an exhaustive search of a given place yet effectively searches a variety of areas (exploration). They produce characteristic noises to alert other individuals of the discovery of food sources. Following the quality of the food source, the best is accessed, chosen for foraging, and new burrows are constructed. In the algorithm's exploration phase, foraging position updating is provided by the equations given below [35].
where eCBest i,j evaluates the effects of the most effective solution currently acquired worldwide and GBest i,j signifies the best solution currently available globally. rPD signifies the location of a random solution, CPD i,j denotes the randomized cumulative effect of all prairie dogs in the colony, and ρ designates the experiment's specialized food source alarm set at 0.1 kHz.
The calibre of the food source determines the coterie's digging strength, indicated by DS, which has a random value. It is commonly known that the Levy distribution, Levy (n), encourages better and more efficient problem search space exploration [35].
where ∆ stands for a modest number that signifies disparities that occur among the PDs and r introduces the stochastic property to confirm exploration and takes the value of −1 or 1 based on the present iteration. The maximum number of iterations is called Max iter , while iter is the current iteration. The r adds the stochastic property to ensure exploration and takes the value of −1 or 1 depending on the current iteration.

Exploitation
This section comprehensively explains PDO's exploitative practices. The entire phase is depicted using a schematic block diagram in Figure 3b. The proposed PDO takes advantage of the differential reactions of PDs to two separate alarms or communication noises. The sounds or signals used by PDs can indicate anything from the presence of predators to the availability of food [35]. The PDs' exceptional communication skills enable them to fulfil their nutritional requirements and defend themselves against predators. Additionally, they can communicate details about the calibre of various food sources as well as information about predators and their hunting techniques. Each of them responds differently to these diverse noises; for instance, if the communication signals a reliable source of high-quality food, they assemble there to satiate their hunger (feed). Additionally, if the communication identifies a hawk as the predator, only PDs along the bird's route go into hiding while the others remain watching from their burrows.
These two different behaviours cause the PDs to gather in one place or, in the case of PDO implementation, a promising location where additional search (exploitation) is carried out to find better or nearly ideal solutions. PDO's exploitation procedures are designed to extensively scour the prospective regions found during the exploration phase.
The equation given below models the two tactics used for this phase. As was previously mentioned, PDO alternates between these two tactics under the conditions respectively [35].
where eCBest i,j analyses the impact of the most recently obtain finest solution and GBest i,j is the most successful global solution to date. iter is the current iteration and Max iter is how many iterations can be carried out. ε is a small value that denotes the level of food quality available, CPD i,j is the combined impact of every PD in the colony, rand is a random number between 0 and 1, and PE is the predator effect [35].
In this section, the algorithm of the PDO technique (Algorithm 1) is presented with the help of pseudo-codes and a block diagram, as represented in Figure 4 [35].

Implementation of PDO Algorithm for Optimal Tuning of the PI Gain Parameters
In this study, the PDO method has been applied to accomplish the optimal operation of HRES comprising PV, FC, and batteries. The gain values of the optimum PI parameters are determined with the aid of the PDO technique. The three objective functions given in Equations (31)- (33) have been minimized using the integral time absolute error (ITAE) standard. Figure 5a-c illustrates the mechanism of the generation of the duty cycle for the inverters of the PV, FC, and battery, respectively, using the suggested MWWO approach.  (24) Execute the response to food alarm activities as in Equation (28) Execute the antipredation activities as in Equation (

Execute the new burrow building as in Equation
Return the best solution (GBest) End

Implementation of PDO Algorithm for Optimal Tuning of the PI Gain Parameters
In this study, the PDO method has been applied to accomplish the optimal operation of HRES comprising PV, FC, and batteries. The gain values of the optimum PI parameters are determined with the aid of the PDO technique. The three objective functions given in Equations (31)- (33) have been minimized using the integral time absolute error (ITAE) standard. Figure 5a-c illustrates the mechanism of the generation of the duty cycle for the inverters of the PV, FC, and battery, respectively, using the suggested MWWO approach. The objective functions for the PV (OF 1 ), FC (OF 2 ), and battery (OF 3 ) are given below: where Er 2 (t) = ∆ SOC bat = SOC bat_re f − SOC bat_load (36)

Simulink Model and Description
In this research article, an HRES system comprising PV-, FC-, and battery-based distributed generations forming an MG system has been taken into consideration. PEIs such as DC-DC boost converters (for PV/FC), DC-DC buck/boost converters (for battery), and DCAC converters have been implemented. All the system components forming the MG system have been designed using MATLAB/Simulink architecture, and the values of each component are given in the appendix. The simulations have been carried out and various system responses have been observed for the traditional as well as proposed controller methods. In this research article, a simplified modelling approach has been adopted to address the specific challenges of improving control, achieving better transient response, and enhancing the power quality of a hybrid MG. Figure 6 below illustrates the diagrammatic representation of the system considered for study in this research paper. DCAC converters have been implemented. All the system components forming the MG system have been designed using MATLAB/Simulink architecture, and the values of each component are given in the appendix. The simulations have been carried out and various system responses have been observed for the traditional as well as proposed controller methods. In this research article, a simplified modelling approach has been adopted to address the specific challenges of improving control, achieving better transient response, and enhancing the power quality of a hybrid MG. Figure 6 below illustrates the diagrammatic representation of the system considered for study in this research paper.

Simulation Results and Discussion
The performance of the HRES-based MG has been studied and the results have been critically analysed by categorizing all the simulation results obtained into (1) HRES performance at the supply side and (2) system performance under fault scenarios at the grid side.

Simulation Results and Discussion
The performance of the HRES-based MG has been studied and the results have been critically analysed by categorizing all the simulation results obtained into (1) HRES performance at the supply side and (2) system performance under fault scenarios at the grid side.

HRES Performance on Supply Side
In this section, the performance and characteristics of the HRESs consisting of PV, FC, and battery (supply end) are presented, considering the proposed PDO controller as well as the conventional TEO, BCO, and PI methods. Figures 7-9 depict the simulation results of the voltage, current, and power of the PV system, highlighting the comparison between the suggested and the traditional methods. The results indicate that the PV system response for the proposed PDO technique is better than the conventional TEO, BCO, and PI techniques in terms of improved stability, fewer harmonics, and enhanced system response. Figures 10 and 11 indicate the power vs. voltage and current vs. voltage curves of the PV system for the suggested PDO controller. The FC system characteristics such as FC voltage, FC current, FC power, and FC fuel consumption are illustrated in Figures 12-15, respectively. It can be inferred from the figures that the PDO-optimized PI outperforms the classical TEO, BCO, and PI methods in terms of reduced oscillations, better system reliability, and less fuel consumption. Battery voltage, current, and state of charge (SOC) responses are shown in Figures 16-18, respectively. It can be concluded from the simulation results that the PDO algorithm robustly tunes the gain parameters of the PI controller, ensuring enhanced system overall dynamics, better efficacy, and reduced harmonics as compared to the TEO, BCO, and PI controllers. 15, respectively. It can be inferred from the figures that the PDO-optimized PI outperforms the classical TEO, BCO, and PI methods in terms of reduced oscillations, better system reliability, and less fuel consumption. Battery voltage, current, and state of charge (SOC) responses are shown in Figures 16-18, respectively. It can be concluded from the simulation results that the PDO algorithm robustly tunes the gain parameters of the PI controller, ensuring enhanced system overall dynamics, better efficacy, and reduced harmonics as compared to the TEO, BCO, and PI controllers.   15, respectively. It can be inferred from the figures that the PDO-optimized PI outperforms the classical TEO, BCO, and PI methods in terms of reduced oscillations, better system reliability, and less fuel consumption. Battery voltage, current, and state of charge (SOC) responses are shown in Figures 16-18, respectively. It can be concluded from the simulation results that the PDO algorithm robustly tunes the gain parameters of the PI controller, ensuring enhanced system overall dynamics, better efficacy, and reduced harmonics as compared to the TEO, BCO, and PI controllers.

HRES Performance under Fault Scenarios at Grid Side
In this section, the system performance and characteristics of the HRES-based MG unit have been comprehensively studied in the grid-tied mode of operation. To validate the effectiveness, robustness, and efficacy of the proposed PDO algorithm compared to the conventional TEO, BCO, and PI methods, the MG system has been tested on four types of severe intentional PQ issues: (1) swell, (2) unbalanced, (3) oscillatory, and (4) notch conditions. A thorough description of the method of formation of these four PQ disturbances is also presented. Furthermore, simulation results for all four scenarios have been determined, and different system dynamics such as DC-link voltage, terminal voltage, voltage deviation, frequency, power factor, THD, grid active power, grid reactive power,

HRES Performance under Fault Scenarios at Grid Side
In this section, the system performance and characteristics of the HRES-based MG unit have been comprehensively studied in the grid-tied mode of operation. To validate the effectiveness, robustness, and efficacy of the proposed PDO algorithm compared to the conventional TEO, BCO, and PI methods, the MG system has been tested on four types of severe intentional PQ issues: (1) swell, (2) unbalanced, (3) oscillatory, and (4) notch conditions. A thorough description of the method of formation of these four PQ disturbances is also presented. Furthermore, simulation results for all four scenarios have been determined, and different system dynamics such as DC-link voltage, terminal voltage, voltage deviation, frequency, power factor, THD, grid active power, grid reactive power, grid apparent power, grid voltage and grid current are presented with regard to the suggested and classical control methods. Comprehensive study and investigation of the simulation results indicate that the PI controller tuned through the proposed PDO method surpasses the conventional TEO, BCO, and PI techniques in remarkably boosting the overall system efficacy and reliability, enhancing the PQ by reducing the harmonics, maintaining robust control of the active, reactive, and apparent power, improving the power factor, minimizing the voltage deviation, and keeping the terminal voltage, DC-link voltage, grid voltage, and grid current constant even with the occurrence of severe PQ disturbances.

Scenario A: Swell Condition
The swell phenomenon has been introduced through the removal of a heavy inductive load (2000 KVAR) for a time duration of 2 s to 3 s, and the model has been run for a time of 5 s. Different system characteristics such as DC-link voltage, terminal voltage, voltage deviation, frequency, power factor, THD, grid active power, grid reactive power, grid apparent power, grid voltage, and grid current are plotted in Figure 19a-k, respectively.

Scenario B: Unbalanced Condition
The unbalanced voltage condition has been brought on by creating an unbalance in the voltage amplitude in one of the phases (phase-a) for a time of 0.3 s to 0.6 s, and the model has been run for 1 s. Various system responses such as DC-link voltage, terminal voltage, voltage deviation, frequency, power factor, THD, grid active power, grid reactive power, grid apparent power, grid voltage, and grid current are illustrated in Figure 20ak, respectively.

Scenario B: Unbalanced Condition
The unbalanced voltage condition has been brought on by creating an unbalance in the voltage amplitude in one of the phases (phase-a) for a time of 0.3 s to 0.6 s, and the model has been run for 1 s. Various system responses such as DC-link voltage, terminal voltage, voltage deviation, frequency, power factor, THD, grid active power, grid reactive power, grid apparent power, grid voltage, and grid current are illustrated in Figure 20a-k, respectively.   The notch phenomenon has been introduced with the help of a six-pulse three-phase rectifier for a duration of 0.03 s to 0.06 s while running the model for 0.1 s. Various system responses such as DC-link voltage, terminal voltage, voltage deviation, frequency, power factor, THD, grid active power, grid reactive power, grid apparent power, grid voltage, and grid current are illustrated in Figure 22a-k, respectively.

Scenario D: Notch Condition
The notch phenomenon has been introduced with the help of a six-pulse three-phase rectifier for a duration of 0.03 s to 0.06 s while running the model for 0.1 s. Various system responses such as DC-link voltage, terminal voltage, voltage deviation, frequency, power factor, THD, grid active power, grid reactive power, grid apparent power, grid voltage, and grid current are illustrated in Figure 22a-k, respectively.

Scenario D: Notch Condition
The notch phenomenon has been introduced with the help of a six-pulse three-phase rectifier for a duration of 0.03 s to 0.06 s while running the model for 0.1 s. Various system responses such as DC-link voltage, terminal voltage, voltage deviation, frequency, power factor, THD, grid active power, grid reactive power, grid apparent power, grid voltage, and grid current are illustrated in Figure 22a-k, respectively.

Conclusive Remarks
A growing field of research in grid-tied MG systems is PQ mitigation in HRESs comprising various renewable-based DGs (PV and FC) and energy storage systems (battery). The usage of PEIs, non-linear loads, unbalanced loads, and high-frequency switching properties on the load side in HRES power systems plays a significant role in affecting the quality of the power delivered and may result in the malfunctioning of the entire power system generation unit. To efficiently address the above issues, a robust and intelligent control scheme based on the prairie dog optimization algorithm has been implemented in this research article. The proposed PDO method facilitates optimal gain scheduling of the PI controllers, which are utilized to drive the inverter for governing the PCC voltage between the MG and the DGs, which, in turn, effectively mitigates the PQ issues.
The MG system has been designed in the MATLAB/Simulink environment, and various intentional fault cases such as swell, unbalanced load, oscillatory transient, and notch have been studied to prove the efficacy of the proposed controller in maintaining the dynamic voltage stabilization, mitigating the harmonics distortion, and reducing the consumed reactive power. Various system characteristics such as terminal voltage, DC-link voltage, voltage deviation, active power, reactive power, apparent power, THD, power factor, frequency, grid voltage, and grid current have been plotted. The system responses of the proposed PDO method have been compared with two other conventional OTs: the BCO and TEO techniques. A thorough examination of the findings supports the effectiveness, reliability, and ability of the proposed PDO controller in terms of reducing THD, improving active and reactive power control, boosting power factor, reducing voltage deviation, and keeping terminal voltage, DC-link voltage, grid voltage, and grid current almost constant in the incident of PQ faults, thus paving the way for its real-time deployment in an MG system.

Comparative Numerical Value Analysis Justifying Efficacy of Proposed Method
In this section, a critical analysis of the characteristics obtained from the simulation has been carried out, and the numerical values obtained after a thorough study are presented in a tabulated manner to support the claim of the robustness of the proposed PDO method over other traditional methods. The four types of PQ issues, (1) swell, (2) unbalanced load, (3) oscillatory transient, and (4) notch, have been introduced for justification of the robustness of the proposed PDO controller. The numerical value response for various system dynamics such as (a) DC-link voltage, (b) terminal voltage, (c) voltage deviation, (d) frequency, (e) power factor, (f) THD, (g) grid active power, (h) grid reactive power, (i) grid apparent power, (j) grid voltage, and (k) grid current is presented in tabular form for the swell, unbalanced, oscillatory transient, and notch conditions in Tables 2-5, respectively. A comprehensive study of the numerical values obtained justifies the robustness of the suggested PDO controller in terms of optimally tuned the PI gain parameters, minimum voltage deviation, enhanced reactive power, reduced THD, improved power factor, and almost constant frequency, even when subjected to severe PQ issues.

Future Directions
The following are some probable upcoming research initiatives that could be investigated:

1.
Only single-objective continuous optimization issues have been solved by the proposed PDO, and scientists may consider creating the binary version of the technique.

2.
PDO's multi-objective form may also be established.

3.
Researchers may also explore the idea of enhancing and hybridizing PDO with other available techniques. 4.
PDO can be expanded to address additional discrete or continuous real-world issues, which is a potential effort for researchers to embark on.

5.
Several distributed generating technologies, such as wind, biomass, microturbines, etc., can be integrated with PV and FC to expand the capacity of supplying power. 6.
Other energy storage units such as supercapacitors, flywheels, compressed air, etc. can be utilized and their response can be studied. Data Availability Statement: Authors may provide data upon request.

Conflicts of Interest:
The authors declare no conflict of interest.