#### Abstract

A fractional order PID (FOPID) controller, which is suitable for control system designing for being insensitive to the variation in system parameter, is proposed for hydroturbine governing system in the paper. The simultaneous optimization for several parameters of controller, that is, , , , , and , is done by a recently developed metaheuristic nature-inspired algorithm, namely, the firefly algorithm (FA), for the first time, where the selecting, moving, attractiveness behavior between fireflies and updating of brightness, and decision range are studied in detail to simulate the optimization process. Investigation clearly reveals the advantages of the FOPID controller over the integer controllers in terms of reduced oscillations and settling time. The present work also explores the superiority of FA based optimization technique in finding optimal parameters of the controller. Further, convergence characteristics of the FA are compared with optimum integer order PID (IOPID) controller to justify its efficiency. What is more, analysis confirms the robustness of FOPID controller under isolated load operation conditions.

#### 1. Introduction

Hydroturbine governing system (HTGS) [1], influenced by hydraulic, mechanical, and electrical factors, is a complex nonlinear system with time-varying and non-minimum-phase characteristic. Generally, performance of HTGS is directly related to the safety and stability of the power system. So it is necessary to obtain excellent performance through reasonable control methods. Conventional PID (or IOPID) has long been the most common used controller in HTGS for its simplicity and ease of implementation [2, 3] in execution. However, there is no guarantee that such controllers would provide the best dynamical response under some realistically constrained conditions [4]. Increasing interest in enhancing the performance of PID controller has led to considerable attention towards fractional order PID controller (FOPID) or controller [5]. FOPID controller, proposed by Podlubny, is characterized by five parameters, that is, the proportional gain , integration gain , derivative gain , integration order , and derivative order . Compared with conventional PID controller, the two extra parameters and enable more degrees of freedom for controller designing, but more complexity in implementation of the controller. FOPID controllers have been applied in many different fields [6–10], such as automatic voltage regulator, motion control of DC motor, irrigation canal control, wind energy system, and aerospace designing control system over the past decades. Further, different approaches have been tested and documented for parameters tuning of FOPID controller to achieve better solutions. For example, a kind of analytic method for FOPID controller designing is proposed in [11] by expanding the input/output of the reference model and control signal over a piecewise orthogonal function. By minimizing the integrated absolute error with a constraint based on maximum sensitivity, a number of tuning rules with the first order plus dead-time model of the process are devised in [12]. Five conditions about phase, gains, and constraints over sensitivity objectives are taken into consideration in [13] to optimize the parameters of FOPID controller. Performances of the works mentioned above confirm the superiority of FOPID controller over integer controllers. In addition, a number of artificial intelligence algorithms [14–17] have been applied in parameters optimization of FOPID. The particle swarms optimization (PSO) method is proposed by searching defined available space in [14, 17]. An improved electromagnetism mechanism algorithm with genetic algorithm (IEMGA) technique has been applied for FOPID controller designing by minimizing the objective errors in [15]. Moreover, a FOPID controller is designed with the root locus method based on an improved differential evolution algorithm in [16]. Therefore, studying for parameter optimization of FOPID controller with FA is an important and challenging issue.

Recently, a new metaheuristic nature-inspired algorithm, known as the firefly algorithm (FA) [18], has been successfully used in many different areas [19, 20]. The main idea behind FA is that social behavior characteristics, for example, the flashing light of a swarm of fireflies, could be formulated easily and associated with the objective function for a given optimization problem [18]. Performances of economic dispatch problems are analyzed and compared with those available in the literature to justify the effectiveness and implementation feature of FA in [20]. Though FA has many similarities with other swarm intelligence algorithms such as PSO, GA [21], and BFO [22], it is indeed much simpler in theory and implementation. By using various standard stochastic test functions, statistical performance of the firefly algorithm is measured against other well-known optimization algorithms [23, 24]. Subsequently, robustness of firefly algorithm is explored in finding optimal solution for the controllers in [25]. Proposed FA has been proven to be promising for optimization problem and encourages further researches for complex problems. But researches have been rarely reported so far. Motivated by the versatility and efficient performance of this technique in different areas, a FOPID controller with improved FA (MMFA-FOPID) of HTGS is proposed to investigate its effectiveness and implementation to the parameter optimization problem in the paper.

In recent years, complex practical engineering systems have emerged as a topic of significant interest in the nonlinear control systems. For example, Wang et al. [26] propose a novel two-layer structure to solve the set points compensation problem for industrial processes under network-based environment; works in [27] demonstrate the effectiveness of the proposed feedback robust control for a class of nonlinear spatially distributed systems expressed by T-S fuzzy models with parameter uncertainties; paper [28] proposes an input-output approach to the delay-dependent stability analysis and controller synthesis for a class of continuous-time Markovian jump linear systems (MJLSs) with a time-varying delay which is a common phenomenon in practical engineering systems. The above works are based on integer order control system, and it will be very meaningful and challenging to extend the concept of fractional order calculus to systems of [26–28] to investigate the nonlinear motion, dynamic characteristic, stability, and control performance.

The rest of the paper is outlined as follows: Section 2 briefly introduces the theory of fractional calculus and implementation of it in FOPID controller. In Section 3, conception and behaviors of the improved firefly algorithm are presented in detail. The MMFA-FOPID controller and HTGS model are constructed in Section 4, and the integral of time-weighted absolute error (ITAE [29]) for optimal controller design is employed in this section. Section 5 illustrates the simulation results along with discussions and remark words. Conclusions are summarized in Section 6.

#### 2. Fractional Calculus and the Fractional Order PID (FOPID)

##### 2.1. Theory of Fractional Calculus

The entire available real number order fundamental operator [30], which is a generalization of differential and integral operators, can be defined as follows:where , , and are the lower limits, upper limits, and the order of the operator, respectively. Definitions [31] for fractional derivatives that generalize the following definition corresponding to integer order can be obtained:

A definition for fractional integral is given bywhere , , is the Euler gamma function [32], and .

FOPID controller can be described as follows:where and are not limited to integer number but fractional number. The conventional controllers are the particular cases of the FOPID controller. When and vary continuously, the corresponding points will move in a row on the - plane. Different types of integer order and fractional order controllers are shown in Figure 1. Notice that the integer order controllers are some isolated points on the - plane. FOPID controller has a more flexible regulation performance and control structure than IOPID controller because of the introduction of and , which makes it possible to obtain better dynamical performance. In some control problems, performance of best FOPID controller will be much better than that of best IOPID controller [33].

It should be noted that the integral part of FOPID controller is , indicating that slope of characteristic curve in phase-frequency diagram is 20* λ* dB/dec instead of 20 dB/dec. This means that the shape of Bode diagram can be changed arbitrarily to increase the robustness of the closed loop system by optimizing .

##### 2.2. Implementation of Fractional Order Controllers

Differential equation of FOPID controller is converted to time-domain equations by the time-domain numerical solution method in the paper based on a method that integer order transfer functions, where infinite numbers of zeroes and poles are included, are adopted to approximate and implement the fractional order transfer functions more perfectly. The specific steps are as follows.

Error of the system can be written as , and control signal of FOPID is described as (5) according to (2)–(4):

Output of FOPID controller can be obtained from the incremental PID control algorithm:where , , and .

, , , , and are the intermediate variables that can be obtained from (2) and (3):

Output of FOPID controller can be directly obtained by (6) when calculation step is small enough. In addition, expressions of , , , , and show that nature of fractional differential and integral terms is greatly influenced by error information of each time in the past, namely, the memory function. Points closer in time will have a greater impact on the output signal. Otherwise, the impact will be smaller. This kind of memory function can guarantee the impact of error history information on present and future, which helps to improve the system performance [34].

#### 3. Firefly Algorithm Based Optimization Technique

Firefly algorithm, proposed by Krishnanad firstly in 2005 and developed by Yang [35], is a new kind of optimization algorithm based on the following three idealized behaviors [4] of the flashing characteristics of fireflies in the summer sky: (1) all the fireflies are unisex; one firefly could be attracted to other fireflies regardless of their sex; (2) brightness or light intensity of a firefly is directly affected or determined by landscape of the objective function; for the maximization problem, brightness can simply be proportional to the objective function and other forms of brightness can be defined in a similar way to the fitness function GA or BFO; (3) attractiveness between different fireflies is proportional to their brightness and will decrease as the distance between them increases; for any two fireflies, the less bright one will move towards a brighter one. Fireflies will move randomly if no firefly is brighter than a particular one. Based on these three rules, basic steps of the firefly algorithm can be summarized as shown in Section 3.4.

##### 3.1. Local-Decision Range

Supposing that a swarm of fireflies is distributed within an -dimensional defined available space of objective function, each firefly has its own luciferin and range of vision, called local-decision range. Size of the initial local-decision range is determined according to defined domain of objective function, and local-decision range of each generation is updated by the following formula:

is the sensing range; is the neighborhood threshold that aims to limit the firefly number of neighbors; is constants for controlling the neighbor range; is the number of fireflies, those with relatively high light intensity within the local-decision range that can be described aswhere is the current position of firefly for the generations, is the light intensity, number of neighbors is limited to local-decision range , and .

##### 3.2. Selection and Movement

Selection probability of a firefly moving path is defined by

The movement of firefly attracted to another more attractive (brighter) firefly is determined bywhere is the calculation step.

##### 3.3. Attractiveness

Light intensity of firefly is written as follows:where are the constants for function values and is the fitness function. FA is more effective in optimization with a fast convergence by using the real random numbers based on global communication among swarming particles (i.e., the fireflies). But there are some flaws to be improved such as search accuracy which existed in optimization. To solve this problem, an improved FA (MMFA) method is proposed in the paper that the updating of light intensity for each firefly is dynamically evaluated and controlled within the scope of to avoid plunging local optimum. Limits of the minimum and maximum values of luciferin are dynamically updated by

When a firefly finds a neighborhood with larger light intensity and their distance is limited within the sensing range , firefly will select the neighbor firefly with a certain probability according to (10) and move towards it firstly and then update its current location by (11) and calculate the value of objective function correspondingly. Finally, light intensity will be updated by (12). This kind of attractiveness, movement, and selection process only depend on local information of fireflies, and firefly population will divide into disjoint subgroups with a slide of a spontaneous behavior; ultimately, optimal value of objective function would be obtained.

##### 3.4. Implementation Steps of Improved FA

The improved FA algorithm is outlined as follows.

*Step 1 (start). *
Initialize , , , , , , , , , , and other parameters.

*Step 2 (attractiveness). *Update the light intensity of each firefly with (12).

*Step 3 (limitation). *Evaluate the updated light intensities and control them within dynamically: if , then ; if , then .

*Step 4 (selection). *Move the fireflies in -dimensions space and elect qualified fireflies according to (9).

*Step 5 (movement). *Firefly () selects a neighbor with a certain probability according to (10) and updates its current location independently by (11).

*Step 6 (range). *Update by (8).

*Step 7 (replace). *Update and by (13).

*Step 8 (test and loop). *Evaluate new solution; if the end condition is satisfied (e.g., reaching a constant number of generations Maxgen in this paper), exit the loop and postprocess results; otherwise, go to Step 2.

#### 4. MMFA-FOPID Controller Design and HTGS Model

##### 4.1. HTGS Model with MMFA-FOPID Controller

Structure of MMFA-FOPID controller for HTGS is obtained as Figure 2.

The HTGS is a complicated system which consisted of five essential parts, that is, the conduit system, governor, hydraulic servosystem, hydroturbine, and power generator. Model for each individual part has been well developed [1]. Schematic diagram of the HTGS with MMFA-FOPID controller is presented in Figure 2. Main task of HTGS is to track the frequency and adjust the power output to grid; thus an excellent dynamic performance of HTGS system is essential to ensure the safety and stability operation of power grid. Model of each part of HTGS is obtained as follows.

*(1) Conduit System Model.* It is difficult to describe movement laws of fluid in penstock where the flow rate is nonlinear to the pressure. However, when neglecting the water column elasticity effect, transfer function of the rigid water hammer could be expressed as

*(2) Governor Model.* Structure of MMFA-FOPID controller for HTGS is shown as Figure 2. Solutions of , , , , and are updated constantly in accordance with the fitness function to optimize the output response of the system.

*(3) Hydraulic Servosystem Model.* The servomotor, which acts as the actuator of hydraulic turbine, is used to amplify the control signals and provide power to operate the guide vane. It consists of the major relay connecter and auxiliary relay connecter. Generally, parameter of auxiliary relay connecter is far less than major relay connecter. So the model can be simplified as a first-order system as follows:

*(4) Hydroturbine Model.* For a small variation around steady-state working conditions, the following equation is often employed to describe the nonlinear characteristic of Francis-turbine model:

*(5) Generator Model.* The well-known Park first-order model is the most common used model in the simulation that can be written as follows:

Based on the discussions above, the HTGS model that coupled each individual part of the nonlinear turbine control system can be obtained. Parameters for a hydropower plant have been measured and used in the later simulation experiments. The effectiveness of FOPID controller for HTGS system will be verified throughout experimental results.

##### 4.2. Objective Functions

The ITAE measure, which will be implemented in this paper, has been used to design the MMFA-FOPID controller. ITAE is given by the following equation:where is the upper limit for the integration. Generally, an excellent dynamic performance with fast, smooth, and small overshoot characteristics of the system will be gotten when using ITAE criteria, where the limitation of errors in latter part of transition process is considered more than the initial error. Suppose that [24] is the steady-state speed deviation of HTGS in transition process that can be expressed as follows with load step disturbance:

And is obtained as follows with frequency step disturbance:

in (19) and (20) is the permanent speed droop; when , the system would adjust without droop characteristic; then , and the speed deviation of hydroelectric generating set becomes

#### 5. Results and Analysis

The proposed MMFA method is applied to optimize parameters of FOPID controller in this section. Simulation experiments with respect to the HTGS are conducted with the load and unloads conditions, respectively. Step disturbance of frequency is adopted to excite the system under unloads condition and load step disturbance is employed to excite the system under load condition. Parameters of HTGS are measured as follows: , , , and . In the MMFA based optimization, parameters of MMFA technique are tuned for optimal performance and their tuned values are as follows: population size of MMFA is considered to be 100, the maximum iteration Maxgen for MMFA is taken as 50, and dimension* m *of definition space is set to be 2 (i.e., , Maxgen = 50, and ). Essential factors and are taken as 0.4 and 0.6 and initial concentration of light intensity is taken as 5 (i.e., , , and ). Local-decision range and sensing range are assigned to 2.048; the neighborhood threshold is taken as 5, is 0.08, and calculation step (i.e., , , , and ). For the optimization problem, the searching ranges of the controller parameters are chosen as and those of the fractional orders and are chosen as .

##### 5.1. Frequency Disturbance under Unloads Condition

In this part of the experiments, FOPID controller and IOPID controller are employed to act on the HTGS system for a better dynamic performance with a 4% step frequency disturbance under unloads condition at 1 s. Speed deviation of unit set, ITAE index, and system Bode diagram are shown in Figures 3, 4, and 5, respectively, in which the red dotted line, blue dotted line, and black dotted line are the response curves of FA-FOPID, MMFA-FOPID, and IOPID optimized by orthogonal experiment method. It can be seen from Figures 3 and 4 that dynamic performance of HTGS with a step frequency disturbance has been improved significantly in terms of almost overall obtained indicators comparing with the FA-PID and IOPID, that is, reduced oscillations and settling time, zero overshoot, more stable transition process, and reduced ITAE index. Furthermore, antitransfer effect caused by the has reduced greatly.

Characteristic curves are located under 0 dB in amplitude-frequency diagram, as Figure 5 shows. The system has a positive gain margin and a positive phase margin in phase-frequency diagram. Therefore, the systems, those with three kinds of controllers shown above, are in stable area with no steady-state error. However, compared with IOPID, system with fractional order controllers has a greater phase margin in the intermediate frequency and low frequency region, leading to the better stability; but it should be noted that, in this range segment, gain margin of integer order controller is larger than that of FOPID. Amplitude-frequency characteristics curve is nearly a straight line parallel to the horizontal axis in the low frequency region; the system will have a finite steady-state error with a step disturbance or a given signal if .

In addition, optimization processes of FA-FOPID and MMFA-FOPID are compared in the paper. Fitness convergence curves are shown in Figure 6, where the solid line corresponds to MMFA-FOPID fitness convergence curve and the dotted line represents FA-FOPID fitness convergence curve. Results show that parameters of FOPID can be optimized effectively with a 4% frequency disturbance. Fitness values of two algorithms turn to stabilize with substantially the same convergence rate after 10 iterations. But MMFA-FOPID algorithm has a smaller fitness value, leading to a better optimization performance.

##### 5.2. Load Disturbance under Isolated Load Conditions

A 10% load disturbance under isolated load conditions occurs at the end of 1 s; speed deviation of unit set, ITAE index, and system Bode diagram are shown in Figures 7, 8, and 9, respectively. It can be seen from Figures 7 and 8 that speed deviation of HTGS with 10% load disturbance has been improved evidently and also that the maximum value of speed has reduced significantly, fluctuation process of speed is more smooth, oscillations and settling time are reduced, and the transition process is more stable compared with the FA-PID and IOPID.

ITAE index with 10% load disturbance by MMFA-FOPID is much smaller than the other two methods; rising process is faster and more stable. System with three kinds of controllers will be stable with no steady-state error. Characteristic curves in amplitude-frequency diagram and phase-frequency diagram indicate that gain margin and phase margin of FOPID are larger than those of IOPID in the intermediate frequency and low frequency region, resulting in stronger suppression to interference; system with FOPID controller in this area has better dynamic characteristics and fast decay process, which is conducive to improving the quality and stability of the control system.

Fitness convergence curves of FA-FOPID and MMFA-FOPID with 10% load disturbance are shown in Figure 10. MMFA-FOPID shows a better indicator than FA-FOPID in terms of convergence rate and descent process of fitness and optimizes performance.

According to the analysis of obtained results in Sections 5.1 and 5.2, the various distinctive feature and advantage of approaches proposed is that it can simulate an independent and parallel run strategy, where each firefly works almost independently and a swarm of fireflies will generate solutions; as a result, FA can find the global optima as well as all the local optima simultaneously in a very effective manner. In addition, MM FA-FOPID has been proven to be far superior and outperforms the other algorithms in terms of efficiency, flexibility, and success rate, which makes it promising for dealing with optimization problem and encourages further researches for complex problems. What is more, the proposed MM FA-FOPID has an excellent capability of handling parameter uncertainty. It also possesses the properties of excellent disturbance rejection, robustness to high frequency noise, and elimination of steady-state errors. It also gives better stability in case of nonlinear systems. All these properties make the MMFA-FOPID a very adaptable and desirable control strategy.

##### 5.3. Robustness Analysis against System Parameter Variations

In the previous experiments, the FOPID controllers designed for the nominal operating conditions have been discussed. Some other simulations which test the effect of tuned controller working for suddenly changed operating conditions, that is, the robustness ability to change in system parameters, are conducted. To illustrate the effect of the variation in system parameter on obtained solution, a common encounter situation should be discussed, for example, load disturbance during the isolated load running condition. The load self-regulation factor and water starting time constant are often varied due to the load changes which occur frequently in the system; thus robustness analysis simulation is carried out under the load condition in the present study in this part, shown in Figures 11 and 12, respectively. It is seen that the FOPID controller is capable of tolerating the decrease or increase of and for the representative solutions 1, 2, and 3 presented in Table 1, which confirms the sufficient robustness of FOPID controller to parameter variation of the system during the load condition.

It is observed from the obtained results that the MMFA-FOPID controller is indeed superior compared to other controllers. Further studies are carried out considering figures of speed response, ITAE, and so forth as performance index and the corresponding numerical values are reported in Figures 3 to 10. The proposed MMFA-FOPID controller provides better results than the others with all four performance indices. It is also to be appreciated that firefly algorithm has optimized efficiently five numbers of parameter simultaneously in a system. The robustness and convergence efficiency of an FA based optimization technique can be clearly concluded from these comparisons in Table 1 and Figures 11 and 12. Therefore, it can be concluded from the analysis that the addition of improved FA to fractional order PID controller has resulted in much better controller performance.

#### 6. Conclusion

Proposed FOPID controller is applied in HTGS with the consideration of optimization objectives. A new metaheuristic nature-inspired algorithm has been improved and applied for simultaneous optimization of several parameters of the controllers for the first time. Performances of PID and FA-FOPID controllers are studied and compared with proposed MMFA-FOPID controller. Critical examination reveals that MMFA-FOPID controller provides more effective and promising results and better designs than the others. Analysis confirms the stability and robustness of the proposed controller against system parameter variations. The paper has also shown that FOPID, which has two more extra tuning knobs than the classical PID controller, gives more flexibility for the control system designing and has better opportunity to adjust system dynamic characteristics, which means that the proposed controller design technique may serve as an efficient alternative for the design of future controllers. The future work is to analyse the nonlinear motion laws as parameters optimization by the method proposed in this paper for HTGS that takes time-delay issue into consideration.

#### Nomenclature

*HTGS*

: | Turbine torque relative deviation, p.u. |

: | Load torque relative deviation, p.u. |

: | Flow rate relative deviation, p.u. |

: | Water head relative deviation, p.u. |

: | Major relay connecter response time |

: | Generator mechanical time |

: | Water starting time constant |

: | Permanent speed droop |

: | Generator load self-regulation factor |

: | First-order partial derivative value of torque with respect to turbine speed |

: | First-order partial derivative value of torque with respect to wicket gate |

: | First-order partial derivative value of torque with respect to water head |

: | First-order partial derivative value of flow rate with respect to turbine speed |

: | First-order partial derivative value of flow rate with respect to wicket gate |

: | First-order partial derivative value of flow rate with respect to water head. |

*FOPID*

: | Proportional gain of FOPID controller |

: | Integral gain of FOPID controller |

: | Differential gain of FOPID controller |

: | Integration order of FOPID controller |

: | Differentiation order of FOPID controller. |

*The Improved Firefly Algorithm*

: | Population size of firefly |

: | Dimension of defined available space. |

*Maxgen Maximum Generation for Firefly Algorithm*

: | Essential factor |

: | Coefficients for function values |

: | Initial concentration of light intensity |

: | Local-decision range |

: | Sensing range |

: | Threshold of neighborhood |

: | Changing rate of neighborhood. |

#### Conflict of Interests

The authors declare that there is no conflict of interests regarding the publication of this paper.