Modiﬁed Approach of NaFA based on its Step Size and its Performance in Bioreactor Processes

Objectives: The objective of this work is to ﬁne tune the variant of FA (Fireﬂy Algorithm), NaFA (Fireﬂy Algorithm with neighbourhood Attraction) by parameter tuning such as a , b , g . Furthermore, a new variant called Step Size Modiﬁed FA with neighbourhood attraction (SSMFA-N) has been proposed in which the step size is updated during the algorithm run so that a balance between local and global search is achieved. The considered objective functions are PO and ITAE. Methods: It is well known that parameters that are considered initially for any metaheuristic algorithms are purely trial and error basis and this leads to erroneous optimized results. While analysing the algorithms, NaFA (a variant of FA) has been considered for eﬃcient convergence and good performance. On analysing it is noticed that FA and its variants’ performances and convergence depend on Step Size( a ), brightness ( b ) and adsorption coeﬃcient( g ). In both the FA and NaFA the parameters to be tuned for eﬀective convergence are a , b and g . It is also understood that the parameter b had been done separately and the parameters a and g cannot be ﬁne-tuned simultaneously. Therefore, in NaFA the parameter tuning for a has been done for the processes FOPDT, stable and unstable SOPDT and the new variant SSMFA-N is thus proposed. Findings: The algorithm is made to run in MATLAB and Simulink environment for three diﬀerent processes such as FOPDT, Stable and Unstable Second order Process (bioreactor processes) with the objective functions of less PO and ITAE. The obtained results from all the three processes are compared with the conventional and optimization methods (PSO) and shown that SSMFA-N outperforms the conventional and optimization approaches in both the time domain and performance indices. Novelty: The novelty is the modiﬁcation of step size of NaFA, which ultimately leads to a new variant called SSMFA-N.


Introduction
In industrial automation around 97% of control loops are PID and among the PID tuning methods, the most preferable are manual model free tuning such as IMC, Adaptive (1) . But Control engineers prefer simple tuning methods based on tuning rules (2) and bump test. Some of the popular PID tuning procedures are Closed loop procedure called ZN, Open loop procedure called Process reaction curve, gain and phase margin method, tuning rule based on frequency domain values , direct synthesis method etc.
Though there are various tuning methods, industry always thrive for optimized solutions. History reveals us that when it comes for optimization, trial and error (heuristic and metaheuristic) plays an important role. The optimization approach starts form Genetic Algorithm (GA) in which the solution is obtained through mutation and crossover. The next one is simulated annealing, a trajectory based algorithm, single agent algorithm, which is based on annealing of metals and used in finding the solution to traveling salesman problem. Multiple agent-based algorithms like Particle swarm optimization (PSO), Ant colony optimization and Artificial Bee Colony (ABC) ] are proposed by various researchers in course of time. Number of optimization algorithms come into exist like Cuckoo search (CS) (3,4) , that has been demonstrated as better algorithm than other metaheuristic algorithms and Bat algorithm (5) for continuous optimization and harmony search (HS) for water distribution and transport problems. Though there are many optimization algorithms it is impossible to find the best one. So researchers have started to figure out the best suitable algorithm for the given problem. The problem considered in this paper is a FOPDT, stable bioreactor and unstable bioreactor processes. The algorithm considered for analysis is Firefly algorithm (FA) which is multiple agents based, inspired by the attraction among firefly (6) .
FA is more efficient than other algorithms because of its local search is superior to global search, lesser probability for premature convergence and adaptability to any search space through its parameter γ (7) . Among the optimization problems solved by FA, Industrial optimization tops the list (7) . Therefore, FA has been considered as a best solution provider for our industrial process. From (8)(9)(10)(11) it is evident that FA will aid in solving numerous problems viz banking, packaging, structural topology, industrial vibration etc., . The FA can be broadly classified into two categories, one is parameter control-altering the algorithm parameter during algorithm's run (12) and parameter tuning-fixing the algorithm's parameter well before the run (13) . Parameter Control method has been considered for the industrial process which is a stable and unstable bioreactor.
The sections of the paper are as follows. In Section 2 FA and its Variants have been discussed. In Section 3 proposed algorithm (SSMFA-N) has been discussed. In section 4 results have been shown and reviewed. In section 5 conclusions have been drawn from the results.

Firefly Algorithm (FA)
Yang, in the year 2008, developed firefly algorithm that entirely depends on the behaviour of fireflies and their flashing patterns (6) . FA is a population-based metaheuristic and a search algorithm. Each and every firefly in the population is a solution in the respective search space. The firefly tends to move towards the brighter firefly and the brightness is measured by the fitness functions in the search space. Let X i and X j be the firefly in the given search space. Here i=1, 2--N; j=1, 2--N. The attractiveness between the two is given by the following equation (6) .
Where β 0 is the brightness of the firefly at distance r =0; γ is the light absorption coefficient.
In the above equation (2) x it is the t th dimension of X i and x jt is the t th dimension of X j . The brightness of X i and X j (j=1,2--N and j̸ =i) are compared and if the brightness of Xj is greater than Xi then X i is updated as (13) x it (n + 1) = x it (n) where ∝ is the step size or step factor and its range is 0 to 1. Furthermore ∈ i is the random variable in the range -0.5 to 0.5. https://www.indjst.org/ Steps in FA 1. Initialization of the population as general random solution through the equation (4) x it = down + rand (0, 1) (up − down) (4) Here rand is the random number that lies between 0 and 1. Up and down is the upper and lower bounds of the dimension 't' respectively. 2. Each solution in FA is obtained after comparing each X i ( where i=1,2--N) with all the other X j (where j=1,2, --N and j ̸ = i ) in the considered initial population. The solutions are based on the objective functions which are the fitness functions here. Henceforth, the attraction (displacement) is based on the objective functions and if the fitness values (solutions) of X j is better than X i then the solution of X i gets updated by equation (3). 3. The entire process gets repeated until the stopping criteria is reached.

Variants of FA
In (14) redefined the attractiveness (β ) and the step size (α) of firefly in Memetic FA (MFA). In MFA the step size was adapted as per equation (6) and the firefly has been updated by eq. (5).
Where s is the length of the variable; In (15) has designed an enhanced FA for steel frames in which he had replaced the distance between the fireflies with normalized distances, thereby defining a set of new equations for attractiveness, step size or randomness (α) and absorption coefficient (γ).
Here the attractiveness, step size or randomness (α) and absorption coefficient (γ) are given by equations (7), (9) and (10) respectively. The maximum and minimum values are considered as one and zero for all the below equations (7) to (10).
and r normalized = r i j r max (8) Similarly, for the randomness or step size (α) In (16) a wise strategy was proposed in which the randomness or step size had been updated with the local best (p best ) and global best firefly (g best ). In (17) the randomness or step size had been updated with the increasing generations. In (18) analysed and stated that the performance of FA mainly depends on the parameters such as brightness (β 0 ) and randomness (∝) .In (18) proposed the values of ∝, β and γ can be modified through updation during the course of optimization. In (19) proposed the values of ∝, β and γ can be predefined well before the optimization. In (19) applied FA for structural problems such as pressure vessel design, helical compression beam design, concrete beam design, cantilever beam design etc., in (20) applied FA in solving queuing system problems in communications, transportation networks, computer systems and manufacturing. In (21) did a comparative study between FA and bees algorithm, by finding the optimal solutions for continuous mathematical functions. Both in FA and a hybrid approach called FA-PSO, the convergence is modified by updating the brightness alone (22) . As per the results it was concluded that FA had outperformed bees optimization. In (7) Fister et al had done a comprehensive review of FA and in that it was stated that FA was one of the most crucial technology for solving engineering problems. In addition to that it was observed that industrial optimization had topped the list of engineering areas in which FA had been used as a tool. It was also observed that Image Processing had occupied second in the list. https://www.indjst.org/

Proposed Algorithm
In FA, each and every firefly gets attracted towards the brightest one and ultimately optimal solutions are obtained. However, this sort of attraction is complex and time-consuming. In (23) proposed a FA based new algorithm called FA with neighbourhood attraction (NaFA). In NAFA the brightness is updated by comparing X i with X j . In the comparison, instead of comparing with all the fireflies the brightness is compared with only the neighbourhood fireflies. Here j is taken as i-k…k…..i+k and k << N. Also in NaFA, The parameter, step size has been updated using eq. (6) and each firefly is updated using eq. (5). Use of NaFA greatly reduces the computational time and oscillations in the optimization strategy. In the proposed algorithm the brightness is compared and updated as per NaFA and the step size (α) is updated by the following equation Where the range of ∝ ∈ (0, 1); γ ∈ (0, 1) ; Here γ = 0.4; As the step size is modified for NaFA the proposed algorithm is hereby referred as Step Size modified Firefly Algorithm with neighbourhood attraction (SSMFA-N) The algorithm steps are as follows: • The initial population is considered and the solutions for each firefly is calculated for the specified objective function.
• The parameter, step size has been updated using eq (6) and each firefly is updated using eq (5).
• The brightness of Xi is compared with Xj where i=1, 2…. N; j= i-k,….. i…..i+k and most importantly i̸ =j. if j<1 or j > N then j will be (j+N)%N. The solution of Xi is compared with Xj and if Xj > Xi then Xi will be updated by eq. (5). • Repeat the brightness updation till the stopping criteria is satisfied.
Initialize the population of Firefly 2.
Evaluate the brightness or solution by using objective functions.

3.
For iterations 1 to max.no of iterations 4.
update the solution using eq (12)

Results & Discussions
The proposed algorithm is run with 50 fireflies. The examples which are considered here are made to run in MATLAB 2013A and Simulink window with the sampling time as 0.01. The proposed algorithm (SSMFA-N) has been compared with a conventional approach and an optimization approach. The objective functions considered here are PO and ITAE. It is obvious that for the continuous process the emphasis must be on steady state. Among the performance indices ITAE provides more weightage to the end of the process and PO provides more weightage to the error in the start of the process. In all the examples considered the SSMFA-N is compared in terms of time domain specifications and performance indices. The processes considered here are first tuned with the conventional approaches like ZN (24) , Huang-Chen (25) ABB (26) and with an optimization approach (PSO). While running SSMFA-N the minimum value and maximum value of the brightness are 0.4 and 1.0 respectively. The minimum and maximum value of the step size is 0.2 and 1.0 respectively. The adsorption coefficient is 1.0. https://www.indjst.org/

Example 1:
The example that is taken into account is a First order Plus Dead time (FOPDT) process. It has been compared with the conventional ZN method discussed in (24) and with the optimization method. In (24) discussed the conventional method called ZN method and furthermore he had shown the PID parameters as k p =0.91, k i =0.3309 and k d =0.6188. For the optimization approach, PSO has been considered among the metaheuristic algorithms for analysis. From Table 1 it is well understood that SSMFA-N outperforms both the conventional (ZN) and optimization (PSO) approaches in terms of all time domain specifications such as t r , t p , PO and t s and performance indices like ISE, IAE and ITAE. The comparisons among the three approaches for the performance indices and the time domain specifications are illustrated in Figures 1 and 2 respectively. The robustness of SSMFA-N exceeds the other two approaches. This is shown by increasing and decreasing the gain of the process by 10% and the same is shown in Table 1. The proposed SSMFA-N performs well in both set point tracking and load disturbances which is shown in Figure 3. On observing it has been noted down that one of the objective functions PO has been reduced from 1.26 to 1.07 and ITAE has been lowered to 8.1167 from 19.55. The same has been illustrated in Table 1.

Example 2
The second process that is taken into account is a stable bioreactor process. It has been compared with the conventional method proposed by ABB which was discussed by (26) for less ITAE. The approach had been discussed in (26) and it was followed for less ITAE in Industries. The PID parameters for the stable bioreactor process have been found by using the method (ABB) shown in (26) . For the optimization approach, PSO has been considered for analysis. The robustness has been checked by increasing and decreasing the process gain by 10 percentage. From Table 2 it is well-established that the robustness of PID defined by SSMFA-N is better than the other two. Also, from Table 2 it is well-defined that the performance indices and time domain specifications of the process tuned by SSMFA-N is far better than other two approaches and this is well-established in Figures 4 and 5 too. The Set point tracking and the load disturbances rejection of SSMFA-N exceeds the other approaches (ABB and PSO) and it is well depicted in Figure 6. In the process of bioreactor the considered objective function PO has been maintained at 1.0 and the performance index ITAE has been reduced to 0.10 from 3.64 appreciably and the same is illustrated in Table 2. https://www.indjst.org/ ABB-10% reduction in gain of the process k p = −0.1220

Example 3
The example that is taken into account is unstable Bioreactor. SSMFA-N is compared with the conventional method proposed by (25) and optimization approach PSO. In (25) proposed the tuning procedure for unstable systems and revealed the PID parameters for the process as k p =-0.4498, τ i = 33.41 and τ d = 0.6950.In both the approaches the robustness has been checked by increasing and decreasing the gain by 10%. In all the cases the time domain specifications and performance indices of SSMFA-N are very less compared to the other two methods. The same has been depicted in Table 3 , Figures 7 and 8. The servo and regulatory response of SSMFA-N outperforms the other two which is shown in Figure 9. In this unstable process the indices that are considered for evaluation such as PO and ITAE has been truncated to 1.15 and 0.41 from 1.5 and 334 respectively. The results are also shown in Table 3 which is given below.

Conclusions
From the examples considered and the tables 1 to 3 and figures 1 to 9 obtained it is well understood that the proposed SSMFA-N outperforms the conventional approaches and the optimization approach (PSO) in both the time domain specifications and performance indices. Both the servo and regulatory responses of SSMFA-N exceeds the performance of other two methods. The robustness has also been checked and the SSMFA-N is more robust than the other two approaches. Though the objective function is PO and ITAE, all the obtained time domain specifications and performance indices are less for SSMFA-N on comparing with the conventional method and the optimization method. In SSMFA-N, when comparing with the optimization approach (PSO), the examined objective functions such as PO and ITAE has been truncated to 7% and 41.56% from 26% and 65.23 % respectively for FOPDT process. With respect to the optimization approach, in the stable bioreactor process, there is no PO and ITAE has been reduced to 2.7 % from 16.2%. Finally, with reference to PSO, in the unstable process, the PO and ITAE has been diminished to 15% and 0.1% form 40% and 3.74 % respectively. The step size is modified with the other FA models also. Thus, with the parameter tuning of step size the balance between the local and global search has been achieved here within 5 iterations. The updating parameters must be dynamic in nature and this requires mathematical analysis of computational algorithms. Similarly, the balance between exploration and exploitation can also be attained by varying the adsorption coefficient and combining it with the brightness tuning. The results can also be refined by adapting hybrid approaches.