The Bees Algorithm Tuned Sliding Mode Control for Load Frequency Control in Two-Area Power System

This paper proposes a design of Sliding Mode Control (SMC) for Load Frequency Control (LFC) in a two-area electrical power system. The mathematical model design of the SMC is derived based on the parameters of the investigated system. In order to achieve the optimal use of the proposed controller, an optimisation tool called the Bees Algorithm (BA) is suggested in this work to tune the parameters of the SMC. The dynamic performance of the power system with SMC employed for LFC is studied by applying a load disturbance of 0.2 pu in area one. To validate the supremacy of the proposed controller, the results are compared with those of recently published works based on Fuzzy Logic Control (FLC) tuned by Teaching–Learning-Based Optimisation (TLBO) algorithm and the traditional PID optimised by Lozi map-based Chaotic Optimisation Algorithm (LCOA). Furthermore, the robustness of SMC-based BA is examined against parametric uncertainties of the electrical power system by simultaneous changes in certain parameters of the testbed system with 40% of their nominal values. Simulation results prove the superiority and the robustness of the proposed SMC as an LFC system for the investigated power system.


Introduction
Modern power systems are highly nonlinear with increasing complexity in their structure. This is because of the obvious increase in the capacity with the wide dependence on different energy sources. Consequently, many issues are associated with this nonlinearity and complexity in which frequency deviation in power systems is one of the most serious problems in this field. The problem of frequency deviation is a persistent issue presents from the continuous change in the demand which accordingly requires changing the generated power in order to keep the frequency at rated value. In power systems, this process is termed Load Frequency Control (LFC) [1]. Based on the basic role of the LFC loop, the principal tasks of this service in power systems are providing the necessitated power from the generation plants operate in the system to meet the load demand variation and maintaining the interchanged power among interconnected control areas at pre-rated values. The objectives of the LFC loop which contribute to enhancing the power system stability are to assure zero steady state errors in frequency variations and the tie-line power fluctuations. This loop is also responsible for damping the overshoot and undershoot of the oscillation in frequency and exchanged power within a specified time; this depends on the capacity of the power system and the disturbance size [2]. Different control techniques based on different theories are suggested to overcome the issue of frequency regulation in power systems [3,4]. The conventional Proportional Integral Derivative (PID) is commonly employed for LFC in power systems as well as other control applications, with roughly 90% of control loops in industry are based on by TLBO presented in [14] and traditional PID-based LCOA [7]. The robustness of the SMC-BA is also verified against a wide range of parametric uncertainties of the testbed system where ten different scenarios of parametric uncertainties are investigated.
Concisely, the novelty of this work is in its proposal to apply the Bees Algorithm (BA) for tuning sliding mode control parameters implemented for load frequency control in power systems. The SMC design used in this study is simple, understandable, and applicable. Additionally, to the best of the authors' knowledge, no previous studies have compared the performance of SMC with Fuzzy Logic Control (FLC) for LFC. It is observed from the simulation results that the BA-optimised SMC has successfully performed as a robust LFC and affords the best dynamic performance in terms of peak undershoot with fast response as compared with the other controllers.
The rest of this research is structured as follows. Section 2 presents the investigated dual-area interconnected power system. Section 3 details the proposed SMC design. Section 4 presents the suggested optimisation tool and the used objective function. Section 5 shows the main simulation results based on the proposed SMC design; it also provides a comparison with other results based on previous studies. Section 6 investigates the robustness analyses of the proposed technique towards parametric uncertainties of the testbed system. Finally, Section 7 summarises the key outcomes and suggests future works for this research.

The Investigated Power System
The testbed model considered in this paper is shown in Figure 1. It is an extensively investigated system in literature to study the dynamic behaviour of different control concepts for LFC in power systems [7,14]. Table 1 provides the associated parameters of this power system. Table 1. The parameter of the testbed system [7,14]. The term of Area Control Error (ACE) in each area is the input of the controller equipped in that area. For this system, the ACEs are represented in Equations (1) and (2).

Parameters
where ∆F 1 and ∆F 2 are the frequency deviation in areas one and two, respectively, ∆P 12 and ∆P 21 are the power flow deviations, whilst B 1 and B 2 are frequency biases.  The term of Area Control Error (ACE) in each area is the input of the controller equipped in that area. For this system, the ACEs are represented in Equations (1) and (2) where ∆F 1 and ∆F 2 are the frequency deviation in areas one and two, respectively, ∆P 12 and ∆P 21 are the power flow deviations, whilst B and B are frequency biases.

The Proposed Sliding Mode Control Design
The SMC follows the concept of Variable Structure Control (VSC). This approach was initially introduced at the beginning of the 1950s. Subsequently, this controller has received considerable attention from researchers, with the aim of employing it on differen applications and benefiting from its numerous advantages.
The first step in designing an SMC is to identify the required behaviour of the testbed system, represented by the sliding surface of the controller. In the current research, the sliding surface of the suggested SMC design is as expressed in Equation (3):

The Proposed Sliding Mode Control Design
The SMC follows the concept of Variable Structure Control (VSC). This approach was initially introduced at the beginning of the 1950s. Subsequently, this controller has received considerable attention from researchers, with the aim of employing it on different applications and benefiting from its numerous advantages.
The first step in designing an SMC is to identify the required behaviour of the testbed system, represented by the sliding surface of the controller. In the current research, the sliding surface of the suggested SMC design is as expressed in Equation (3): where e(t) is the tracking error variable, K 1 , K 2 , K 3 and K 4 are the parameters that will be optimised via the Bees Algorithm. From a control perspective, it is essential to maintain the tracking signal e(t) and its derivatives equal to zero. Additionally, in order to keep S(t) at a specified value, it is required to maintain its derivative equal to zero as illustrated in (4). The control law of the proposed design illustrated in (5) is selected by taking into account the condition expressed in Equations (3) and (4).
where U C (t)= F (x(t), r(t), e(t)); in which x(t) is the control signal, r(t) is the reference signal, and e(t) is the error signal. The term U D (t) can be expressed as in Equation (6). (6) where the gains K D and δ are to be optimised by BA. Accordingly, the proposed SMC design comprises six parameters. The optimal values of these parameters are found by the BA via minimizing the integral time absolute error of the deviation in the frequency and exchanged power.
In the system shown in Figure 1, the transfer function of area one from the control signal U 1 to ∆F 1 with consideration of the droop characteristic R 1 can be demonstrated as in Equation (7).
By considering the values of the parameters tabulated in Table 1, Equation (7) can be re-written as follows: Equation (8) can also be written in differential form as expressed in (9) U C (t) = .
x(t) − 20.06 (11) As the variable e(t) is defined as the difference between the reference signal r(t) and the control signal x(t), this can be mathematically expressed as in (10).
The term U C (t) can be identified as follows: ..
Energies 2021, 14, 5701 6 of 28 The control law of the controller employed in area one is expressed as in (15). .. ..
Similarly, to derive the control law of the SMC equipped in area two, the same procedure is followed, this yields the equation expressed in (16). .. ..

The Proposed Optimisation Technique and Objective Function
It is proved that in order to enhance the performance of a controller, it is essential to understand the behaviour of the controlled plant and design the controller based on the desired behaviour of that system. Notably, one of the most important steps that plays a crucial role in the control design procedure is to find the optimal values of its parameters. However, in many cases, it is difficult to estimate the optimum values of the controller's parameters that lead to the optimal performance. The trial-and-error technique is considerably used to overcome this matter; however, it is time-consuming and no accurate results are guaranteed. Therefore, optimisation algorithms are introduced to solve this problem to a great extent as well as other optimisation problems.
As it is explained above, in the proposed SMC design, twelve parameters will be tuned, namely: K 1 , K 2 , K 3 , K 4 , K D1 , and δ 1 for the LFC controller equipped in area one, K 5 , K 6 , K 7 , K 8 , K D2 , and δ 2 for the LFC controller employed in area two. These parameters are to be tuned by a metaheuristic algorithm inspired by the foraging behaviour of honeybees known as the Bees Algorithm (BA) [32]. Since its first introduction in 2005 by Professor Pham et al., this algorithm has been widely proposed by many researchers as a powerful optimisation tool to solve several problems in different fields. This is due to the wide spectrum of advantages such as simplicity and efficaciousness [33][34][35][36][37].
The algorithm requires a number of parameters to be set, specifically: number of scout bees (n), number of sites selected for exploitation out of the n visited sites (m), number of top-rated (elite) sites among the m selected sites (e), number of bees recruited for the best e sites (nep), number of bees recruited for the other (m-e) selected sites (nsp), initial size of each patch (ngh) "a patch is a region in search space that includes a visited site and its neighbourhood", and stopping criterion.
The simplest pseudo-code for this algorithm is shown in Figure 2. The mechanism of this algorithm begins with placing the n scout bees randomly in the search space. In step 2, the evaluation of the fitness of sites visited by the n scout bees is done. The m sites with the highest fitness in specified "chosen sites" in step 3 are selected for neighbourhood or local search. The algorithm in steps 4 and 5 conducts searches in the neighbourhood of the selected sites, with more bees assigned to the best e sites. Selection of the best sites could be conducted directly based on the fitness associated with them. Alternatively, using the fitness values, the probability of sites being selected is determined. Searches in the neighbourhood of the best e sites which represent the most promising solutions are made more prominent by recruiting more bees for them than for the other selected sites. Together with scouting, this differential recruitment is a key operation of the Bees Algorithm. For each patch, only the one bee that has found the site with the highest fitness (the "fittest" bee) is selected in step 5 to form part of the next bee population. In steps 6-8, the remaining bees in the population n are assigned randomly around the search space to scout for potential new solutions or to conduct the global search. These eight steps are repeated until a stopping criterion is met. The colony will have two parts to its new population at the end of each iteration: representatives from each selected patch and other scout bees assigned to conduct random searches [38].
Energies 2021, 14, x FOR PEER REVIEW 7 of neighbourhood of the best e sites which represent the most promising solutions are mad more prominent by recruiting more bees for them than for the other selected sites. T gether with scouting, this differential recruitment is a key operation of the Bees Algorithm For each patch, only the one bee that has found the site with the highest fitness (the "f test" bee) is selected in step 5 to form part of the next bee population. In steps 6-8, th remaining bees in the population n are assigned randomly around the search space scout for potential new solutions or to conduct the global search. These eight steps a repeated until a stopping criterion is met. The colony will have two parts to its new po ulation at the end of each iteration: representatives from each selected patch and oth scout bees assigned to conduct random searches [38]. In this work, the parameters of the BA are set as illustrated in Table 2. The numb of iterations was set as 100. Furthermore, in control theories, it is always preferred to obtain a fast response com bined with stability for the controlled plant. However, it is a challenging task to meet th requirements of both conditions simultaneously. Therefore, control engineering designe tend to compromise and find a balance between quick response and the required stabilit This compromise can be achieved by the appropriate selection of the controller and d signing it by minimising a properly specified objective function with the support of a optimisation method. In this research, the parameters of SMC proposed for LFC in th dual-area power system is optimised using the BA by minimising the Integral Time A solute Error (ITAE) objective function expressed in Equation (17). In this work, the parameters of the BA are set as illustrated in Table 2. The number of iterations was set as 100. Furthermore, in control theories, it is always preferred to obtain a fast response combined with stability for the controlled plant. However, it is a challenging task to meet the requirements of both conditions simultaneously. Therefore, control engineering designers tend to compromise and find a balance between quick response and the required stability. This compromise can be achieved by the appropriate selection of the controller and designing it by minimising a properly specified objective function with the support of an optimisation method. In this research, the parameters of SMC proposed for LFC in the dual-area power system is optimised using the BA by minimising the Integral Time Absolute Error (ITAE) objective function expressed in Equation (17).

Results and Discussion
In this paper, a step load disturbance of 0.2 pu is applied in area one to study the dynamic performance of the testbed system when the proposed SMC tuned by BA is equipped in the system for LFC. The BA is run for 100 iterations to obtain the optimal values of the SMC parameters and the restrains of the search space is set from [0 to 2]. The optimum gains of the SMC obtained by BA are shown in Table 3. Furthermore, in order to demonstrate the superiority of the SMC, the results obtained are compared with those from published articles based on TLBO tuned Fuzzy PID presented in [14] and LCOA tuned traditional PID presented in [7] employed for LFC in the same system. The optimum gains of these controllers are depicted in Table 4. Table 4. The optimum gains of the controllers proposed in [7,14].

Controller
Controller Gains of Area The frequency variation in area one, frequency variation in area two, and tie-line power variation following the sudden 0.2 pu disturbance applied in area one are shown in Figures 3-5, respectively. From Figures 3-5, it is found that the SMC tuned by BA employed for LFC in the dual-area power system offers a better dynamic response compared with those provided in [7,14]. The undershoot (U sh ), overshoot (O sh ), and settling time (T s ) of the frequency in both areas and tie-line power along with the values of the objective function are illustrated in Table 5. From Table 5, it is observed that the settling time and undershoot of ∆F 1 , ∆F 2 , and ∆P tie is less when the proposed SMC tuned by BA is used as an LFC controller to study the dynamic behaviour of the two-area power model as compared with the other techniques studied in [7,14]. It is also evident that the value of the objective function (ITAE) is extremely less for BA-optimised SMC in comparison with the other controllers. However, a negligible increase in the overshoot is noticed.       Based on the characteristics provided in Table 5, the percentage of improvement in U sh , T s , and ITAE for the SMC proposed in this research and Fuzzy PID controllers [14] in comparison with the LCOA-based PID controller [7] is shown in Figure 6. From Figure 6, it is observed that with BA-optimised SMC, undershoot and settling time in the frequency deviation of area one (∆F 1 ) are improved by 82.60% and 80.3055%, respectively. While in (∆F 2 ), the undershoot and settling time in frequency deviation are improved by 97.59% and 88.606%, respectively, and in (∆P tie ) they are improved by 97.76% and 91.01%, respectively. Based on the results shown in Figures 3-6 and Table 5, it is confirmed that the proposed SMC design offers the fastest response with the minimum undershoot, which in turn guarantees the best stability. Based on the characteristics provided in Table 5, the percentage of improvement in U sh , T s , and ITAE for the SMC proposed in this research and Fuzzy PID controllers [14] in comparison with the LCOA-based PID controller [7] is shown in Figure 6. From Figure 6, it is observed that with BA-optimised SMC, undershoot and settling time in the frequency deviation of area one (∆F 1 ) are improved by 82.60% and 80.3055%, respectively. While in (∆F 2 ), the undershoot and settling time in frequency deviation are improved by 97.59% and 88.606%, respectively, and in (∆P tie ) they are improved by 97.76% and 91.01%, respectively. Based on the results shown in Figures 3-6 and Table 5, it is confirmed that the proposed SMC design offers the fastest response with the minimum undershoot, which in turn guarantees the best stability.

Robustness Investigation of SMC
An analysis of the parametric uncertainties in the two-area power system and it pact on the system stability is performed in this section by considering different scen The testbed system has many parameters that may alter during the operating time, nations in any parameter by increasing or decreasing will influence the overall sy stability. For instance, increasing the value of the governor time constant Tg leads increase in the frequency fluctuation. While decreasing the damping ratio (D) cou crease the frequency deviation which may result in a risk of system instability.
To verify the robustness of the proposed SMC optimised by BA employed in the area power model as an LFC system, several scenarios pertaining to the parametri certainties of the investigated system are considered as depicted in Table 6. Initially, parameter of the testbed system has been varied individually. Subsequently, severa rameters are simultaneously varied by (+ or −) 40% from their nominal values. A step perturbation of 0.2 pu is applied in area one to observe the impact of the system para ric uncertainties on the performance of the SMC-LFC controller. Similar robustness i tigation is carried out for the Fuzzy PID controller optimised by TLBO and the cla PID controller-based LCOA.
In cases 1 to 6 in Table 6, only one parameter is varied at a time. However, in to make this investigation more realistic, more than one parameter is simultaneously ied from their nominal values. In case 7, the parameters Tg and D in areas one and are varied by +40% and −40%, respectively. In case 8, the parameters Tt and B in both are varied by +40% and −40%, respectively. Furthermore, in case 9, Tg, Tt, and B are v by +40%, −40% and −40%, respectively. Finally, in case 10, four parameters of the two

Robustness Investigation of SMC
An analysis of the parametric uncertainties in the two-area power system and its impact on the system stability is performed in this section by considering different scenarios. The testbed system has many parameters that may alter during the operating time, alternations in any parameter by increasing or decreasing will influence the overall system stability. For instance, increasing the value of the governor time constant Tg leads to an increase in the frequency fluctuation. While decreasing the damping ratio (D) could increase the frequency deviation which may result in a risk of system instability.
To verify the robustness of the proposed SMC optimised by BA employed in the two-area power model as an LFC system, several scenarios pertaining to the parametric uncertainties of the investigated system are considered as depicted in Table 6. Initially, each parameter of the testbed system has been varied individually. Subsequently, several parameters are simultaneously varied by (+ or −) 40% from their nominal values. A step load perturbation of 0.2 pu is applied in area one to observe the impact of the system parametric uncertainties on the performance of the SMC-LFC controller. Similar robustness investigation is carried out for the Fuzzy PID controller optimised by TLBO and the classical PID controller-based LCOA.
In cases 1 to 6 in Table 6, only one parameter is varied at a time. However, in order to make this investigation more realistic, more than one parameter is simultaneously varied from their nominal values. In case 7, the parameters Tg and D in areas one and two are varied by +40% and −40%, respectively. In case 8, the parameters Tt and B in both areas are varied by +40% and −40%, respectively. Furthermore, in case 9, Tg, Tt, and B are varied by +40%, −40% and −40%, respectively. Finally, in case 10, four parameters of the two-area power system are varied from their nominal values, namely, B, H, R and D. These different scenarios could represent the most common conditions of parametric uncertainties that the testbed system may experience in real-time operation.
The frequency variation in area one, frequency variation in area two and tie-line power variation following the implementation of the disturbance in area one under different scenarios of system parametric variations are shown in Figures 7-16. In Figures 7-16, subfigures (A) illustrate the frequency deviation in area one, subfigures (B) illustrate the frequency deviation in area two and subfigures (C) illustrate the tie line power deviation. Moreover, the dynamic response of the system represented by undershoot (U sh in Hz), overshoot (O sh in Hz) and settling time (T s in s) in ∆F 1 , and ∆F 2 are presented in Table 7. Additionally, Table 7 provides the undershoot (U sh in pu), overshoot (O sh in pu), and settling time (T s in s) in ∆P tie .           Values that represent the best performance are indicated in bold. Figure 7 shows the dynamic performance of the system based on SMC, Fuzzy PID, and the classical PID under parametric uncertainty case 1, where only the system inertia time constants in both areas are varied by 40% from their nominal values. It is observed that the proposed SMC provided the best performance in terms of undershoot and settling time in the frequency deviation in areas one and two as well as in the tie-line power deviation. Figure 8 indicates the response under parametric uncertainty case 2. In this case, the turbine time constants in both areas are altered by 40%. It is noticed that the increase in the turbine time constant worsened the dynamic response, it caused a further drop in the frequency in both areas. The dynamic response of the system with different controllers under parametric uncertainty case 3 is illustrated in Figure 9. In this case, the nominal values of the frequency bias constants in both areas are varied by −40%. As a result of this variation and based on the results obtained from the SMC tuned by BA, the drop in the frequency in areas one and two have increased from −0.0746 Hz and −0.0016 Hz to −0.0918 Hz and −0.0035 Hz, respectively. In case 4 of robustness analysis towards parametric uncertainty of the testbed system, the value of the coefficient D in both areas are varied by −40%. An extremely slight change in the dynamic performance of the system is observed as shown in Figure 10. However, based on the results obtained for case 5, where the governor time constants in both areas are increased by 40% from their nominal values, a slight increase in the drop in the frequency in both areas is observed as illustrated in Figure 11 and Table 7. In case 6 from the robustness investigation, no obvious change in the dynamic response is observed as shown in Figure 12.
In case 7, the values of Tg and D in both areas are varied by 40% and −40%, respectively. Although two parameters in areas one and two are varied, the proposed SMC-based BA still offering good performance and outperforms the other two controllers as demonstrated in Figure 13. The worst undershoot in the frequency in both areas as well as in the tie-line power deviation is recorded based on the results obtained from case 8 as shown in Figure 14, where the drop of the frequency in area one has increased from −0.0746 Hz to −0.1087 Hz, from −0.1885 Hz to −0.4015 Hz, and from −0.4288 Hz to −0.5931 Hz based on SMC, Fuzzy PID, and classical PID, respectively. Additionally, the drop of the frequency in area two has increased from −0.0016 Hz to −0.0047 Hz, from −0.0190 Hz to −0.0805 Hz, and from −0.0664 Hz to −0.1435 Hz based on SMC, Fuzzy PID, and classical PID, respectively. Whilst the undershoot in the tie-line power has increased from −0.0003 pu to 0.00067 pu, from −0.0042 pu to −0.0114 pu, and from −0.0134 pu to −0.0210 pu based on SMC, Fuzzy PID, and classical PID, respectively. The dynamic response of the system under parametric uncertainty case 9 is demonstrated in Figure 15. In this case of robustness analysis, three different parameters are simultaneously varied. Namely, Tt and B in areas one and two are varied by −40% while the governor time constants Tg are altered by 40%. The notable observed change in the dynamic performance of the system is the slight increase in the drop in the frequency in both areas. Finally, in case 10, four different parameters are varied, the dynamic response of the testbed system under parametric uncertainty case 10 based on SMC, Fuzzy PID and the traditional PID is given in Figure 16.
From Figures 7-16 and Table 7, in spite of the wide range of parametric uncertainties of the testbed system in the ten investigated scenarios, the implementation of the proposed SMC design tuned by BA has provided a robust performance which has maintained the system stability within acceptable limits. Furthermore, this controller has outperformed the Fuzzy PID and the traditional PID in terms of the peak undershoot and settling time regardless of the negligible increase in the overshot noted in certain cases.
Moreover, to further assess the performance of the SMC controller, a random load disturbance is applied in area one under the parametric uncertainties of the system case 10 as shown in Figure 17A. The frequency deviation in area one is shown in Figure 17B, the frequency deviation in area two is shown in Figure 17C,D shows the tie line power deviation.
From Figure 17, it is understandable that the proposed SMC-BA controller continues to offer the best dynamic response for frequency variation in area one, frequency variation in area two and tie-line power deviation even with the presence of load disturbance changes every twenty seconds. Additionally, this controller has guaranteed the fastest response with the best-damped oscillation in comparison with Fuzzy PID controller-based TLBO and PID controller tuned by LCOA.

Conclusions
In this paper, a novel and simple design of Sliding Mode Control (SMC) is proposed and implemented for Load Frequency Control (LFC) in a dual-area interconnected power system. In order to enhance the performance of the proposed controller, the Bees Algorithm (BA) is proposed in this work as an optimisation tool to find the optimum values of the SMC parameters by minimising integral time absolute error of the frequency variations in both areas and the tie-line power deviation. A step load perturbation of 0.2 pu is applied in area one to study the dynamic behaviour of the testbed system with the proposed decentralised SMC equipped in areas one and two. The superiority of the SMC performance was validated by comparing the results obtained with those of previously published works based on Fuzzy PID and classical PID. Simulation results demonstrated that the SMC tuned by BA performs better than the other reported methods; the peak undershoot and settling time of the frequency deviation in area one has been improved by 82.60% and 80.3055%, respectively, while the same characteristics of the frequency deviation in area two are improved by 97.59% and 88.606%, respectively, as compared with results based on the classical PID tuned by LCOA. Furthermore, the robustness examination of the proposed controller tuned by BA towards a wide range of parametric uncertainties of the investigated system was also performed by considering ten different scenarios. Based on the results obtained from this research, it is revealed that the performance of the proposed SMC design used as LFC in the two-area power system is robust and superior; it provides satisfactory performance in different aspects such as undershoot and settling time regardless of the slight and negligible increase in the overshoot noticed in particular cases. This work can be further extended in future work by implementing the proposed SMC design for LFC in systems that comprise renewable energy resources and considering some nonlinear aspects such as Generation Rate Constraint (GRC) and Governor Deadband (GDB).