Fish School Search Algorithm for Constrained Optimization
In this work we investigate the effectiveness of the application of niching able swarm metaheuristic approaches in order to solve constrained optimization problems. Sub-swarms are used in order to allow the achievement of many feasible regions to be exploited in terms of fitness function. The niching approach employed was wFSS, a version of the Fish School Search algorithm devised specifically to deal with multi-modal search spaces. A base technique referred as wrFSS was conceived and three variations applying different constraint handling procedures were also proposed. Tests were performed in seven problems from CEC 2010 and a comparison with other approaches was carried out. Results show that the search strategy proposed is able to handle some heavily constrained problems and achieve results comparable to the state-of-the-art algorithms. However, we also observed that the local search operator present in wFSS and inherited by wrFSS makes the fitness convergence difficult when the feasible region presents some specific geometrical features.
According to Koziel and Michalewicz , the general nonlinear programming problem (NLP) consists in finding x such that:
where . Objective function is defined on the search space and the set defines the feasible region.
Search space is defined as a rectangle within and constraints define the feasible space :
Equality constraints are commonly relaxed and transformed in inequality constraints as : , where is a very small tolerance value.
Almost all real-world optimization problems are constrained . Hence, many metaheuristic search procedures were conceived for the general NLP. Recent approaches include: Genetic Algorithms [18, 9, 14], Diferential Evolution [19, 11, 30, 5, 29, 28], Cultural Algorithm , Particle Swarm Optimization [13, 6, 3, 17, 27, 12] and Artificial Bee Colony Optimization [16, 4, 1, 23].
Regarding the approaches applied in order to tackle constrained search, Mezura-Montes and Coello Coello  present a simplified taxonomy of the common procedures in literature:
Penalty functions - Includes a penalization term in the objective function due to constraint violation. This is a popular and easy to implement approach but has the drawback of requiring the penalty weights adjustment;
Decoders - Consists in mapping the feasible region on search spaces where an unconstrained problem will be solved. The high computational cost required is the main disadvantage in its use;
Special operators - Mainly in evolutionary algorithms, operators can be designed in a way to prevent the creation of infeasible individuals;
Separation of objective function and constraints - This approach, different from penalty functions, treat objective function and constraint violations in separately. Many procedures can be applied from this approach such as dividing the search process in phases or applying multi-objective techniques.
Fish School Search (FSS) algorithm, presented originally in 2008 in the work of Bastos-Filho and Lima-Neto et al. , is a population based continuous optimization technique inspired in the behavior of fish schools while looking for food. Each fish in the school represents a solution for a given optimization problem and the algorithm utilizes information of every fish to guide the search process to promising regions in the search space as well as avoiding early convergence in local optima.
Ever since the original version of FSS algorithm was developed, many modifications were performed in order to tackle different issues such as multi-objective optimization , multi-solution optimization  and binary search . Among those, a novel niching and multi-solution version known as wFSS was recently proposed .
To the best of the authors knowledge, the application of FSS in the solution of constrained optimization problems has never been reported before. Hence, in this work, a modification in niching weight based FSS (wFSS) was carried out. The separation of objective function and constraints was applied and the niching feature was used in order for the population to find different feasible regions within the search space to be exploited in terms of fitness value. Moreover, three different mechanisms were applied generating in total four approaches.
This paper is organized as follows: section 2 provides an overview of Fish School Search algorithm and its niching version, wFSS. Section 3 introduces the proposed modifications in order to employ wFSS in constrained optimization problems as well as the variations introduced based on the main procedure conceived. Section 4 presents the tests performed and results achieved.
2 Fish Schooling Inspired Search Procedures
2.1 Fish School Search Algorithm
FSS is a population based search algorithm inspired in the behavior of swimming fishes in a school that expands and contracts while looking for food. Each fish -dimensional location represents a possible solution for the optimization problem. The algorithm makes use of weights for all fishes which represent cumulative account on how successful has been the search for each fish in the school.
FSS is composed of feeding and movement operators, the latter being divided into three sub-components, which are:
Individual component of the movement: Every fish in the school performs a local search looking for promising regions in the search space. It is done as represented by (1):
where and represent the position of fish before and after the individual movement operator, respectively. rand(-1,1) is an uniformly distributed random numbers array with the same dimension as and values varying from up to . is a parameter that defines the maximum displacement for this movement. The new position is only accepted if the fitness of fish improves with the position change. If it is not the case, remains the same and .
Collective-instinctive component of the movement: An average of displacements performed within individual movements is calculated based (2):
Vector I represents the weighted average of the displacements of each fish. It means that fishes which experienced a higher improvement will attract other fishes into its current position.
After vector I computation, every fish will be encouraged to move according to (3):
Collective-volitive component of the movement: This operator is used in order to regulate exploration/exploitation abilities of the school during the search process. First of all, barycenter B is calculated based on the position and weight of each fish:
and then, if total weight given by the sum of weights of all fishes in the school has increased from last to current iteration, the fishes are attracted to the barycenter according to (5). If the total school weight has not improved, fishes are spread away from the barycenter according to (6):
where defines the maximum displacement performed with the use of this operator. is the euclidean distance between fish position and the school barycenter. rand(0,1) is an uniformly distributed random numbers array with the same dimension as B and values varying from up to .
Besides movement operators, it was also defined a feeding operator used in order to update the weights of every fish according to (7):
where is the weight parameter for fish , is the fitness variation between the last and new positions and represents the maximum absolute value of fitness variation among all fishes in the school.
is only allowed to vary from 1 up to , which is a user defined attribute. Weights of all fishes are initialized with the value .
The parameters and decay linearly along with the iterations.
2.2 Weight-based Fish School Search Algorithm
Introduced in the work of Lima-Neto and Lacerda , wFSS is a weight based niching version of FSS intended to provide multiple solutions for multi-modal optimization problems. The niching strategy is based on a new operator called Link Formator. This operator is responsible for defining leaders for fishes in order to form sub-schools and works according to the following: each fish chooses randomly another fish in the school. If is heavier than , then now has a link with and follows (i.e. b leads a). Otherwise, nothing happens. However, if already has a leader and the weights sum of followers is higher than weight, then stops following and starts following . In each iteration, if becomes heavier than its leader, the link will be broken.
In addition to Link Formator operator inclusion, some modifications were performed in the components of the movement operators in order to emphasize leaders influence on sub-swarms. Thus, the displacement vector I of the collective-instinctive component becomes:
where is 1 if fish has a leader and otherwise. and are the displacement and fitness variation of the leader of fish . Furthermore, the influence of vector I in fishes movements is increased along with iterations. This is represented by with . The collective-volitive component of the movement is also modified in a sense that the barycenter is now calculated for each fish with relation to its leader. If the fish does not have a leader, its barycenter will be its current position. This means:
Some modifications were proposed in wFSS in order to make the algorithm able to tackle constrained optimization problems. Basically, either fitness values and constraint violation are measured for every fish. In the beginning of each iteration, a decision has to be done in order to define whether fitness function or constraint violation will be used as objective function within current iteration.
The decision of which value to use as objective function was chosen to be done according to the feasible individuals proportion with relation to whole population. This means that, if the current feasible proportion of the population is higher than an user defined threshold , the search will be performed using fitness as objective function. If that is not the case, constraint violation will be then optimized.
The described procedure was applied to divide the search process in two different phases and to allow the algorithm to: phase 1 - find many feasible regions; phase 2 - optimize fitness within feasible regions. The niching feature of wFSS is useful in phase 1 once this feature will make the school able to find many different feasible regions. Moreover, every once the search changes from phase 1 to phase 2, an increase factor is applied in the steps of either Individual and Collective-volitive movement operators in order to augment the school mobility in the new phase.
The algorithm described will be referred as wrFSS and its pseudocode is:
The constraint violation measure applied in wrFSS was the same as in the work of Takahama and Sakai :
Best fish selection was done using Deb’s heuristic :
Any feasible solution is preferred to any infeasible solution;
Among two feasible solutions, the one having better fitness function will be preferred;
Among two infeasible solutions, the one having smaller constraint violation is preferred.
Furthermore, the feeding operator version applied was the same as in the work of Monteiro et al. . In this version, feeding becomes a normalization of both fitness and constraint violation values:
where will be constraint violation values within phase 1 and fitness on phase 2. and are the minimum and maximum values found in all the search process.
It is important to highlight that the normalization applied in Equation 11 makes and once this equation is applied for minimization of both fitness function and constraint violation.
3.1 wrFSS Variations
In this Section, some variations of the aforementioned algorithm will be presented applying state-of-the-art constrained optimization approaches within wrFSS. wrFSS variations are:
wrFSSe - Applies the -method  in Individual component of the movement;
wrFSSg - Includes a gradient based local search in either phases of the search process;
wrFSSp - Uses a penalized fitness function in phase 2.
wrFSS variations are intended to increase the algorithm performance when tackling challenging problems. Each of the variations specific mechanisms will be better described in next sections.
The -method [31, 29, 30, 5] defines a comparison procedure taking simultaneously into account constraint violation and fitness value. Let and be the fitness value and constraint violation evaluated at point . Thus, comparisons and , with , are defined as:
When , -comparison becomes a simple fitness comparison. Further, for , Deb’s heuristic is carried out.
In wrFSSe, was chosen to decay along with the iterations in the same way as in the work of Takahama and Sakai :
where is the current iteration and is a percentage of the maximum number of iterations. is given by , and is a user-defined parameter. depends on the initial school constraint violation :
Individual movement operator in wrFSSe applies the -comparison between the fishes’ current and candidate positions. If candidate position is with relation to the current position, the movement is allowed.
Gradient based individual movement operators were designed in order to guide the local search process in either phases of the search process intended to:
Phase 1 - The gradient based individual movement is performed in order to allow the fishes to quickly achieve feasible regions;
Phase 2 - The gradient based individual movement is intended not to allow the fishes to escape the feasible regions.
In order to do so, the following steps are employed:
Chose random directions and compute their director vectors ;
Calculate the directional derivatives given by ;
Return in phase 1 or in phase 2.
With this procedure, we intended to provide the individual movement operator with the directions containing high probabilities of improving constraint violation within phase 1 or improving fitness value maintaining fishes in feasible regions within phase 2 of the search process.
where is the problem dimensions number and is a pertubation constant.
The directional derivatives are computed by the inner product between the gradient and the director vectors.
The candidate position for the Individual movement operator is given by or for phases 1 and 2, respectively.
Gradient evaluation demands evaluations. Therefore, a user-defined probability is defined in order for each fish to check whether it will run the gradient based or the original Individual movement operator.
A simple modification was proposed in wrFSS originating wrFSSp. A penalty approach was applied specifically in phase 2 in order to avoid that feasible fishes move to infeasible positions which improve their fitnesses. Thus, the objective function of phase 2 is defined as in (22):
In order to evaluate wrFSS different versions performance, a set of constrained optimization problems defined for CEC 2010  was solved.
The chosen problems are presented in Table 1 as well as their features. The problems selected to be included in the test set present different feasible regions. The feasible region is the ratio between the feasible portion and the whole search space.
|Problem||Search Space||Number of Constraints||
Two levels of each parameter were chosen in order to evaluate which combination of them caused the best results for C01 and C03. Based on that, the best performers parameters sets on C01 were extended to C07 and C08. The parameters which generated best results to C03 were applied also in the tests with C04, C06 and C09 due to the similarities of the problems in terms of feasible region. Table 2 presents the chosen parameters values used in the tests performed.
Table 3 presents the results obtained in 30 runs of each wrFSS variation when solving each of the aforementioned CEC’s problem. In all the tests, the maximum number of iterations was set to and the tolerance values in all tests. All wrFSS variations include the Stagnation Avoidance Routine  within the Individual movement operator. was set to decay exponentially: , where is the current iteration.
From Table 3, it is noticeable that all the proposed algorithms were able to reach feasible solutions in all runs for problems C01, C08 and C09, which are those containing relatively large feasible regions. The same did not happen in the cases of C03, C04, C06 and C09, heavily constrained problems due to equality constraints presence. Specifically in C04, only wrFSSg was able to find feasible individuals. In the other hand, in C06 and C09 all the approaches were able to find feasible individuals in all runs. In C03, all the variations of wrFSS were able to find feasible individuals, but not in al runs.
The difficult of wrFSS variations in order to tackle some heavily constrained problems is related to the search mechanisms employed. The Individual movement operator is based on a local search performed with a random jump. Therefore, in situations in which the feasible regions are very small, random jumps may neither guarantee that a fish can reach this region in phase 1 nor guarantee that a fish that has already reached it will keep there.
In the specific case of C03, for instance, the feasible region is composed by the line . Thus, even when fishes are able to reach the line, becoming feasible and changing the search mode from phase 1 to phase 2, once they perform the Individual movement operator, the random jumps will not allow them to strictly move over the line. This drawback was tackled by the application of the method and the gradient based individual movement operators. However, these two methods still apply random jumps and then, depending on the topological features of the feasible regions, the algorithm could fail to exploit fitness in phase 2.
Figure 1 supports the aforementioned issues and displays the mean Best Fish’s Fitness and Feasibility (constraint violation measure) along with the iterations. It is possible to notice that, in C03, most approaches are not able to improve fitness once the feasibility improves up to the end of the search process. This means that a long phase 1 happens in all versions, trying to find and keep the feasible line. The fast improving fitness in wrFSSe happens because of the characteristic relaxation of the constraint violation present in method. Moreover, in C09, It is possible to notice that all versions of wrFSS are able to reach feasible regions, but the fitness does not improve when that happens. Which means that once fishes reach feasible regions and change the search mode to phase 2, in few iterations the feasibility state degenerates due to random jumps in infeasible directions and phase 1 takes place again avoiding fitness convergence.
The best mean fitness values reached among all the approaches as well as the best performing wrFSS variation are highlighted.
One can notice that DEg outperforms all the other approaches in all the problems selected, except for C08 where Co-CLPSO reaches better results. However, regarding specifically wrFSS variations, it can be seen that wrFSSe is the best wrFSS variation in 5 out of 7 tests. Further, in 6 out of 7 tests performed, some wrFSS variation outperforms at least one of the three approaches selected for comparison.
Several problems within Industry an Academia are constrained. Therefore, many approaches try to employ metaheuristic procedures in order to efficiently solve the aforementioned class of problems. Different search strategies were developed and applied in either Evolutionary Computation and Swarm Intelligence techniques.
The first contribution in this work regards the proposal of a new approach in order to tackle constrained optimization tasks: the separation of objective function and constraint violation by the division of the search process in two phases. Phase 1 is intended to make the swarm to find many different feasible regions and, after that, phase 2 takes place in order to exploit the feasible regions in terms of fitness values.
This strategy, mainly in phase 1, requires a niching able algorithm. Thus, we selected wFSS, the multi-modal version of the Fish School Search algorithm, to be employed as base algorithm. Hence, we conceived a variation of wFSS named wrFSS embedding the division strategy. Moreover, we proposed three variations of wrFSS applying different strategies in order to improve its performance.
In order to evaluate the techniques proposed, seven problems from CEC 2010 were solved. Results show that wrFSS as well as its variations are able to solve many hard constrained optimization problems. However, in some cases, specifically in problems containing feasible regions presenting geometric conditions in which the widths in some directions are much higher than in others, the algorithm’s local search procedure brings difficulties for wrFSS to keep solutions feasible once phase 1 finishes. Even so, in a comparison performed with three CEC 2010’s approaches within top 10 winners has shown that some wrFSS variation outperforms one of these techniques in almost all solved problems in this work. wrFSSe was the best variation of the proposed versions.
It is important to highlight that the approaches used for comparison apply costly search mechanisms that were not employed in wrFSS. Local optimization procedures and external archive were applied in these techniques.
Based on the aforementioned, the proposed strategy of dividing the search process in two different phases and apply a niching swarm optimization technique in order to find many feasible regions in phase 1 is an interesting approach to be explored. In future works, improvements in wrFSS could include a hybridization between wrFSSe and wrFSSg in order to improve the local search ability of wrFSSe, the best performing wrFSS variation. Moreover, the inclusion of other resources such as local optimization operators as well as external archive related operators could be employed in order to solve the issues highlighted in this work.
-  B. Akay and D. Karaboga. Artificial bee colony algorithm for large-scale problems and engineering design optimization. Journal of Intelligent Manufacturing, 23(4):1001–1014, 2012.
-  C. J. A. Bastos-Filho and A. C. S. Guimarães. Multi-Objective Fish School Search. International Journal of Swarm Intelligence Research, 6(1):23–40, 2015.
-  M. Bonyadi, X. Li, and Z. Michalewicz. A hybrid particle swarm with velocity mutation for constraint optimization problems. Proceeding of the fifteenth annual conference on Genetic and evolutionary computation conference - GECCO ’13, page 1, 2013.
-  I. Brajevic and M. Tuba. An upgraded artificial bee colony (ABC) algorithm for constrained optimization problems. Journal of Intelligent Manufacturing, 24(4):729–740, 2013.
-  J. Brest. Constrained real-parameter optimization with -self-adaptive differential evolution. Studies in Computational Intelligence, 198:73–93, 2009.
-  M. Campos and R. A. Krohling. Hierarchical bare bones particle swarm for solving constrained optimization problems. 2013 IEEE Congress on Evolutionary Computation, CEC 2013, pages 805–812, 2013.
-  P. Chootinan and A. Chen. Constraint handling in genetic algorithms using a gradient-based repair method. Computers & operations research, 33(8):2263–2281, 2006.
-  F. B. De Lima Neto and M. G. P. De Lacerda. Multimodal fish school search algorithms based on local information for school splitting. Proceedings - 1st BRICS Countries Congress on Computational Intelligence, BRICS-CCI 2013, pages 158–165, 2013.
-  K. Deb. An efficient constraint handling method for genetic algorithms. Computer Methods in Applied Mechanics and Engineering, 186(2-4):311–338, 2000.
-  C. J. a. B. Filho, F. B. D. L. Neto, A. J. C. C. Lins, A. I. S. Nascimento, and M. P. Lima. A novel search algorithm based on fish school behavior. Conference Proceedings - IEEE International Conference on Systems, Man and Cybernetics, pages 2646–2651, 2008.
-  N. Hamza, D. Essam, and R. Sarker. Constraint Consensus Mutation based Differential Evolution for Constrained Optimization. IEEE Transactions on Evolutionary Computation, (c):1–1, 2015.
-  X. Hu and R. Eberhart. Solving Constrained Nonlinear Optimization Problems with Particle Swarm Optimization. Optimization, 2(1):1677–1681, 2002.
-  A. R. Jordehi. A review on constraint handling strategies in particle swarm optimisation. Neural Computing and Applications, 26(6):1265–1275, 2015.
-  S. Koziel and Z. Michalewicz. Evolutionary algorithms, homomorphous mappings, and constrained parameter optimization. Evolutionary computation, 7(1):19–44, 1999.
-  R. Landa Becerra and C. A. C. Coello. Cultured differential evolution for constrained optimization. Computer Methods in Applied Mechanics and Engineering, 195(33-36):4303–4322, 2006.
-  X. Li and M. Yin. Self-adaptive constrained artificial bee colony for constrained numerical optimization. Neural Computing and Applications, 24(3-4):723–734, 2014.
-  J. J. Liang, S. Zhigang, and L. Zhihui. Coevolutionary comprehensive learning particle swarm optimizer. 2010 IEEE World Congress on Computational Intelligence, WCCI 2010 - 2010 IEEE Congress on Evolutionary Computation, CEC 2010, 450001(2):1–8, 2010.
-  C.-H. Lin. A rough penalty genetic algorithm for constrained optimization. Information Sciences, 241:119–137, 2013.
-  J. Liu, K. L. Teo, X. Wang, and C. Wu. An exact penalty function-based differential search algorithm for constrained global optimization. Soft Computing, 20(4):1305–1313, 2016.
-  S. S. Madeiro, F. B. De Lima-Neto, C. J. A. Bastos-Filho, and E. M. Do Nascimento Figueiredo. Density as the segregation mechanism in fish school search for multimodal optimization problems. Lecture Notes in Computer Science (including subseries Lecture Notes in Artificial Intelligence and Lecture Notes in Bioinformatics), 6729 LNCS(PART 2):563–572, 2011.
-  R. Mallipeddi and P. N. Suganthan. Ensemble of constraint handling techniques. IEEE Transactions on Evolutionary Computation, 14(4):561–579, 2010.
-  E. Mezura-Montes and C. A. Coello Coello. Constraint-handling in nature-inspired numerical optimization: Past, present and future. Swarm and Evolutionary Computation, 1(4):173–194, 2011.
-  E. Mezura-Montes and R. E. Velez-Koeppel. Elitist Artificial Bee Colony for constrained real-parameter optimization. 2010 IEEE World Congress on Computational Intelligence, WCCI 2010 - 2010 IEEE Congress on Evolutionary Computation, CEC 2010, 2010.
-  J. B. Monteiro, I. M. C. Albuquerque, F. B. L. Neto, and F. V. S. Ferreira. Comparison on novel fish school search approaches. 16th International Conference on Intelligent Systems Design and Applications, 2016.
-  J. B. Monteiro, I. M. C. Albuquerque, F. B. L. Neto, and F. V. S. Ferreira. Optimizing multi-plateau functions with FSS-SAR (Stagnation Avoidance Routine). IEEE Symposium Series on Computational Intelligence, 2016.
-  J. A. G. Sargo, S. M. Vieira, J. M. C. Sousa, and C. J. A. B. Filho. Binary Fish School Search applied to feature selection: Application to ICU readmissions. IEEE International Conference on Fuzzy Systems, pages 1366–1373, 2014.
-  T. Takahama and S. Sakai. Contrained Optimization by Constrained Swarm Optimizer with -level Control. In 4th IEEE International Workshop on Soft Computing as Transdisciplinary Science and Technology, pages 1019–1029, 2005.
-  T. Takahama and S. Sakai. Constrained Optimization by the Constrained Differential Evolution with Gradient-Based Mutation and Feasible Elites. IEEE Congress on Evolution Computation, pages 1–8, 2006.
-  T. Takahama and S. Sakai. Solving difficult constrained optimization problems by the constrained differential evolution with gradient-based mutation. Studies in Computational Intelligence, 198:51–72, 2009.
-  T. Takahama and S. Sakai. Constrained Optimization by the Constrained Differential Evolution with an archive and Gradient-Based Mutation. IEEE Congress on Evolution Computation, (1):1–8, 2010.
-  T. Takahama, S. Sakai, and N. Iwane. Constrained Optimization by the Constrained Hybrid Algorithm of Particle Swarm Optimization and Genetic Algorithm. Advances in Artificial Intelligence, 3809(1):389–400, 2005.