Diversity Operators-based Artificial Fish Swarm Algorithm to Solve Flexible Job Shop Scheduling Problem

: Artificial fish swarm algorithm (AFSA) is one of the critical swarm intelligent algorithms. In this paper, the authors decide to enhance AFSA via diversity operators (AFSA-DO). The diversity operators will be producing more diverse solutions for AFSA to obtain reasonable resolutions. AFSA-DO has been used to solve flexible job shop scheduling problems (FJSSP). However, the FJSSP is a significant problem in the domain of optimization and operation research. Several research papers dealt with methods of solving this issue, including forms of intelligence of the swarms. In this paper, a set of FJSSP target samples are tested employing the improved algorithm to confirm its effectiveness and evaluate its execution. Finally, this paper concludes that the enhanced algorithm via diversity operators has discrepancies about the initial AFSA, and it also provided both sound quality resolution and intersected rate.


Introduction:
Production managing has a great influence on the process of planning and scheduling of contemporary manufacturing systems, scheduling of production involves assigning the source over a period to perform a bunch of tasks, which can be considered one of the most demanding and grave topics in handling and scheming of manufacturing processes 1 . Many studies have been done to overcome several types of scheduling problems, one of the most difficult problems in this field is the job shop scheduling problem (JSSP) 2 , which is a highly popular problem in the fields of production management and optimization of combinatorial 3 . It is necessary to have a set of apparatuses to handle many jobs. Every job is made of a preset string of processes in order to perform each process, where one specified apparatus is assigned for one process to handle only one process at a time 4 .
In order to improve the classical problem of job scheduling, it has been circulated to an FJSSP, in FJSSP a fixed number. of apparatuses with processing time can operate a job operation not similar in JSSP where each process must be performed by a particular apparatus; this is why when JSSP is compared with FJSSP, it is concluded that the FJSSP is more awkward due to its uncertainty when choosing the right apparatus out of a specific set of apparatuses that would handle each process of a task 5 .Two sub-problems were decomposed from the problem of scheduling jobs in FJSP that are routing and scheduling. A routing subproblem means each operation is assigned to a particular machine (out of a set of capable machines) and a scheduling sub-problem means that each assigned operation is given a sequence number for all selected machines in order to achieve optimized objectives from the feasible schedule 6,7 . In this research the makespan is decreased i.e., the highest time to complete the tasks. FJSSP is intensely NP-hard 8 , and is a further complicated form of JSSP. Accordingly, the metaheuristic algorithms are the vital substitute to resolve this kind of problems which give an appropriate solution within a satisfactory time period 9,10 .
In 11 (2021), a new variable neighborhood descent hybrid genetic algorithm (VND-hGA) was proposed. To increase convergence performance and solution correctness, a barebones particle swarm optimization (BBPSO)-based mutation operator, a hybrid heuristic initialization method, and VND based on an improved multilevel neighborhood structure are introduced into the conventional GA framework. Furthermore, for maximizing the benefits of BBPSO, a real-numberbased chromosomal representation, coding, decoding, and crossover method is provided. VND-hGA outperformed current solutions in terms of solution accuracy and convergence. In 12 , the squirrel algorithm was used to solve the flexible shop scheduling problem, and the following are the primary innovations: To address working efficiency and system stability, a new dynamic multi-objective flexible shop scheduling model is proposed, with completion time, load balance (LB), and fault rescheduling deviation as objective functions, taking into account the changes in an actual workshop environment, including the random arrival of task sequences, the departure of completed tasks, sudden machine failure, and the repair of failed machines. Secondly an improved dynamic multi-objective squirrel search method based on decomposition is proposed in 12 in order to effectively solve the above stated mathematical model. It uses operation and machine coding for individual coding and optimizes the SSA's individual evolutionary strategy based on the FJSSP's features. In addition, new dynamic processing technology is proposed that includes the establishment and update of the external population as well as the initialization of the population at the time of rescheduling, allowing the system to respond quickly to changes by regenerating the initial population at the time of rescheduling. In 13 , presented a novel crossbred metaheuristic method based on Particle Swarm Optimization (PSO) and Tabu Search (TS) processes. It is created to address the issue of flexible job shop scheduling (FJSSP). For the algorithm's experimental inquiry, several benchmark examination cases from various lit origins are utilized. The divergence from optimality yielded a mean error of 1.09 percent. The test findings provide a solid foundation for further PSO-TS enhancement. In 14 , an improved AFSA algorithm was proposed for solving the flexible job shop scheduling problem (FJSSP). The enhancement is based on the Variable Neighborhood Descent (VND) method, which is applied to AFSA by various neighborhood structures in order to improve the original AFSA's performance. In addition, an improved algorithm termed (AFSA-VND) was tested for performance evaluation on certain FJSSP benchmark instances.
In terms of solution quality and convergence rate, the experimental results suggest that AFSA-VND outperforms the original AFSA. In 15 , camel herds algorithm (CHA) was introduced as a new swarm intelligent algorithm. The suggested method is based on camel behavior in the wild, taking into account that each herd has a leader, and that food and water are sought based on a humidity value using a nearby technique. To test the suggested technique, the flexible job shop scheduling problem (FJSSP) is used as a case study. The CHA is a good method for finding the best solution in problem space, according to the testing results. In 16 , the cuckoo search algorithm for addressing the flexible job shop scheduling problem (FJSP) has two improvements: the first is based on the best neighbors generation (CS-BNG), and the second is based on Iterative Levy Flight (CS-ILF). To improve searching in discrete state space, some adaptations to the main points of the CS algorithm have been made. The proposed algorithms have improved the quality and rate of convergence of solutions. For performance evaluation, the improved algorithms are evaluated on the HU dataset for FJSP benchmark instances. In comparison to the basic cuckoo search algorithm, the experimental findings show that the upgraded algorithms are more effective.
This paper tried to enhance the artificial fish swarm algorithm (AFSA) using a diversity operator to solve the (FJSP) complications. The rest of the paper is organized as follows: Section 2 reviews some associated research. Section 3 provides a broad description of AFSA. The improved AFSA is suggested in Section 4, and the results obtained experimentally, and their discussion are presented in Section 5. Eventually, the conclusions reached in this paper are presented in Section 6.

Materials and Methods: Artificial Fish Swarm Algorithm
Lei introduced AFSA in 2002 as a swarm algorithm that relies on metaheuristics. The general idea of AFSA is to replicate the swarming of fish in the environment; one of the techniques which are used to solve various problems for ideal solutions is to adapt the intelligence of a fish swarm with artificial intelligence 17,18 . Naturally in a marine habitat, a single fish or a group of fish will find areas that are rich in more nutrition. In the behavior of fish-eating, the behavior of the swarm has a significant effect in facilitating and simplifying the search for food. Because some aspects of nutrition are first discovered by some individuals, who are usually the first to use this nutrition, this simplifying effect arises. When the eating fish appear, other individuals get attracted, and within a short period, the entire swarm quickly huddles in that area of food and starts excessive eating 18 . In a line of this performance, the Artificial Fish (AF) [19][20][21][22][23] replica expresses a set of fish performances such as the following, teeming, and predatory performance for probing in the problem space. The AF model is made up of two parts: variables and functions. The variables section contains the following items: denotes the current position of AF, which is represented as an array = [ 1, 2 … ], step denotes the maximum length of the movement step, and the functions component covers three AF behaviors: preying behavior, swarming behavior, and following behavior [24][25][26][27] . Visual refers to the visual distance of AF, try number is the maximum number of searching tours within the visible distance, and a crowd factor (δ) (0 < < 1). The basic steps of the AFSA algorithm are depicted in algorithm 1.

A. Preying behavior
It is a vital life living conduct of fish for nutrition inclination; fish typically use their vision to sense the condensation of food in water and determine the direction of movement that they can select accordingly. To describe the above behavior: Suppose that is the current state of AF, is the AF status random in a visual distance, ( ) refers to food condensation (AF value is the objective function). The following state of ( ) is calculated as Where, random ( ) function is a built-in function to generate random numbers between 0 and 1. If the result of equation 1 is better than the existing value ( ), so moving forward direction as in equation 2. ( Where, step is the length of step. Then, randomly selecting an alternative status and testing if it has a priority in the value of the objective function to meet the progress requirements. If it is not able to obtain an improved result that meets the progress requirements after a number of trial times, a random step will be taken B. Swarming behavior The transition of fish in nature takes place in the form of aggregates to avert risks and maintain the sustainability of the colony. The following diagram depicts the swarming behavior: Assume that the current state of AF is and that c is the center place, where the number of its neighbors in the visual field is , where (ǁ − ǁ < ), n is the overall number of fish, and F( ) is better than ( ), and ( / < ), refers to extra food in the neighbors center (a higher value of fitness function in the center and not too congested), so it moves a step If not, the preying behavior is performed.

C. Following behavior
During the moving of fish swarm stage, whether a single fish or a group of fish found the food, their neighbors will move towards and get nutrition hastily. This behavior can be described as: is the current state of , and is the neighborhood, where (ǁ − ǁ < ), means it has better value for fitness function ( ). If ( ) is better than ( ) × ( / < ) this implies that there is a greater food condensation on the neighbor's place and that the surrounding is not very congested, so it proceeds a step toward the neighbor . If not, preying behavior is executed.

AFSA Based on Diversity Operators: Representation of Solutions
Operation sequence and machine assignment are two sub-problems of FJSSP. The solution must be described in matrices such as 1 and 2 ; where 1 denotes the operation sequence while 2 denotes the machine assignment. An example for the FJSSP with three jobs and three machines is shown in Fig. 1. The operation sequence can be represented by the permutation approach. Gen et al. produced an approach for operation sequence solution vector representation using feasible permutation 14 . The same symbol is used to name all operations of a job, that symbol is the job number. Depending on the order in which the job shows in the ( 1 ). The operation of a job number is selected i.e., number of operations that this job content is equal to the job number shown in ( 1 ). This representation always has forms of convenient operation sequence because there is no break for the priority constraints.

A Modified AFSA Based on Diversity Operators
In an attempt to enhance the basic AFSA performance, an AFSA based on diversity operators (AFSA-DO) is proposed in this paper. AFSA is a good algorithm in the optimization problem, but sometimes there are several solutions that need more diversification to increase the performance and decrease the execution time. The diversity operators are a collection of operators aims to produce updated neighbor solutions for several purposes such as: • Various solutions for the purpose of exploring the largest number of them. • Reducing the effect of the local minima problem. • Exploitation is a diversification to increase the solutions space, subsequently, increases the good solution(s). • Reducing the randomization of AFSA to exploit the nearest. The proposed AFSA-DO main steps are shown meanwhile in the below algorithm. The maximum number of solution locations that switch their position in the solution vectors is depicted in the visual idea of the AFSA-DO. Hamming distance is used to compute the distance between ( , ) solutions where the corresponding positions have dissimilar values. In the discrete space, the AF movement step forward will take the same solution that is estimated as the next better solution for each AF. The basic steps of the Improved AFSA via Diversity Operators are illustrated in algorithm 2. In AFSA-DO, diversity operators are suggested to implement on the best AF that has been detected till now in each generation (repetition). A diversity operators' strategy is offered to take a better AF solution as input to further condense around the best resolution area in the state space. in a better solution and faster convergence. The algorithm below illustrates the essential steps used by diversity operators to improve AFSA. ( ( best) < ( optimum)) best = optimum; ( ); .

Experimental Results
In order to measure the performance and power of the proposed algorithm (AFSA-DO), several experiments have been executed using the FJSSP dataset and comparing the performance between the AFSA-VND and the original AFSA 25 . With the original AFSA, the artificial fish are moved from one location to another in the continuous state space. The AFSA and AFSA-DO algorithms are subjected to some adaptation to be appropriate for diversification in the discrete state space of the problem using many diversification operators. In this work, the MATLAB platform is employed to execute AFSA and AFSA-DO with computer specifications: Intel Core i7, 2.7 GHz, 4 GB RAM, 500 GB hard drive and Windows 7 have used these algorithms 25 , which are made up of three separate instance sets: "edata," "rdata," and "vdata," with the customizable machines set being increased by a probability distribution in each case. Size ( ) jobs and ( ) machines are assigned for each instance, where ( × ) will equal to sequence vector and assignment vector. The same FJSSP instances with the same parameter value are used in these three algorithms (AFSA, AFSA-DO, and AFSA-VND) 14 and the parameters are initialized as follows:  Table 1 shows the results of the test runs, with the best-known Lower Bound of dataset (each occurrence) represented by (LB) 26 , the mean of makespan for each occurrence represented by Average makespan (AMK) which is obtained from the test runs for the three algorithms mentioned above, and the relative error percentage represented by (REP) for the three algorithms under study, which computed as:  The above outcomes indicate that for all instances applied in the experiment, the makespan obtained by AFSA-DO is superior to that of the original algorithm of AFS and modified AFSA based on VND, and it has been approximated above the lower bound. Moreover, AREP is greater than (AREP) of AFSA-DO for both AFS and AFSA based on VND as original algorithms.
Furthermore, when comparing the number of iterations for finding makespan using AFSA-DO versus AFSA, it is found that the number of iterations of the instance applied into the test is 82% higher than the number of iterations of the instance of AFSA-DO, and in some cases, the makespan is generated by AFSA-DO with significantly fewer iterations than AFSA. Table. 2, shows a comparison between the results obtained through the suggested algorithm (AFSA-DO) with those attained by the algorithms suggested in 14,16 . By applying equation 5 on the dataset 21 to calculate the REP of the makespan for the proposed algorithm and some others 21 . To illustrate that, Table. 2, clarifies that REP of the modification of AFSA based on Diversity Operators is not worse than REP; of most instances for the algorithms executed in (AFSA-VND, CS-BNG and CS-ILF) 14,16 ; in addition, the results showed that AREP in the proposed algorithm (AFSA-DO) is lower than the other algorithms that are compared. Figs. 2, 3, illustrate the comparison between the got effects.    edata_la1  edata_la2  edata_la3  edata_la4  edata_la5  edata_la6  edata_la7  edata_la8  rdata_mt06  rdata_mt10  rdata_la1  rdata_la2  rdata_la3  rdata_la4  rdata_la5  rdata_la6  rdata_la7  rdata_la8  vdata_mt10  vdata_la1  vdata_la2  vdata_la3  vdata_la4  vdata_la5  vdata_la6  vdata_la7  vdata_la8 REP Results

Conclusion and Future Work
This paper presents a modification on the AFSA based on diversity operators. Moreover, the diversity operators (mutation, insertion, translocation, inversion, and swapping) provide more diversification, enforcement, and utilization than the basic AFSA. Also, using different operators can increase diversification for current solutions and utilization of the local optimum, which maximize the convergence ratio. The AFSA local search ability has been improved through this proposed algorithm. The laboratory effects made it clear that the improvement made to the proposed AFSA-DO led to more excellent quality solutions for all the instances that underwent the test. Moreover, in most instances, this improvement accelerated the convergence ratio in most cases compared to the original AFSA and AFSA-VND. This affords AFSA-DO the prevalence over the original AFSA and AFSA-VND. In the future, this work will be designed utilizing other algorithms and techniques, and a comparison of effects will be made.