Solving Quadratic Assignment Problem by Using Meta-Heuristic Search Method

While analytical solutions to Quadratic Assignment Problems (QAP) have indeed been since a long time, the expanding use of Evolutionary Algorithms (EAs) for similar issues gives a framework for dealing with QAP with an extraordinarily broad scope. The study's key contribution is that it normalizes all of the criteria into a single scale, regardless of their measurement systems or the requirements of minimum or maximum, relieving the researchers of exhaustively quantifying the quality criteria. A Tbu Search Algorithm for Qadratic Asignment Poblems (TSQAP) is proposed, which combines the limitations of tabu search with a discrete assignment problem. The effectiveness of the proposed technique has been compared to well-established alternatives, and its operating principle is illustrated with a numerical example. After repeating the solution of each issue (8) once and recording the algorithm results, it showed its agreement, once from a total (375) repetition of the experiment while the number of times the Artificial Bee Colony (ABC) arrived (2) as for the Firefly (FA) giving (117), also Genetic Algorithm (GA) and Particle Swarm Optimization (PSO) gives (120) and the Tabu Search algorithm (174). The proposed technique (TSQAP) is shown to yield a superior solution with low computing complexity. MATLAB was used to generate all of the findings (R2020b).


Introduction
The Quadratic Problem Formulation (QAP) is one of the Complex Optimization Problems (COP) that, in terms of difficulty, belongs to the difficulties of type (NP-hard).Modeling commercial transactions and the problem of quadratic allocation was also applied in a variety of applications, including scheduling and site development for hospitals and universities [1].Researchers have developed a suite of algorithms, including the Genetic Algorithm (GA), the Artificial Bee Colony (ABC), the Tabu Search Algorithm (TS), the Firefly (FA) Algorithm, and others, that have proven their effectiveness in finding good solutions to complex optimization problems in record time.Finding the best answer to a large-scale (n>20) quadratic assignment problem is challenging, and the absence of a polynomial-time technique to do so presents a challenge for researchers.Due to the breadth of the problem being solution space, utilizing estimated algorithms to find a polynomial solution algorithm for the quadratic assignment problem in a reasonable amount of time is doubtful until it is shown that (NP = P) [2].The overall goal of the research is to create a polynomial approximation algorithm that finds the optimal solution in polynomial time by, among other things, enhancing the efficiency of the tabu search algorithm (Tabu Search) to accelerate its progress towards a certain algorithm's current state of quality improvement.

Tabu Search
Tabu Search (TS) is one of the commonly utilized met heuristics for COP.Glover 1989 [3, 4, 5] and 6] proposed the core ideas of TS, which were built on earlier ideas in Glover 1990 [7].Glover and Laguna 1993 [8, 9 and 10] describe the technique and its concepts.TS makes explicit use of the search history to avoid local minima and to conduct an exploration plan.Figure (1) depicts the approach for the algorithm.As just a basic element, the simple TS algorithm employs a superior local search for improvement and employs a short attention span to eliminate local minima and cycles.The short-term memory is implemented as a list of tables that allows you to monitor the last alternatives you examined and prevents you from moving toward them.The current solution's neighborhood is so confined to solutions that do not belong on the list of violations [11 and 12].

Firefly Algorithm
Yang created the Firefly algorithm in 2008 by animating the typical movements of fireflies [13, 14, 15 and 16].It is classed as swarm intelligent, met heuristic, and nature-inspired.In reality, the population of fireflies exhibits unique luminary flashing activities that serve as a means of attracting partners, communicating, and warning predators [17].Yang developed this method based on the premise that all fireflies are unisexual, that all fireflies have appealing potential for each other, and that attractiveness is precisely proportional to the brightness level of individuals [18].As a result, the brighter fireflies encourage the less bright ones to travel toward them, and if there are no fireflies brighter than a specific firefly, it moves randomly.
The objective function of the firefly algorithm is connected with the flashing light features of the firefly population.Given that light intensity is inversely quadratic proportional to the square of the area, this concept allows us to develop a suitable function for the distance between any two fireflies.Individuals in the population are compelled to make systematic or random moves in order optimize the fitting function [17, 19, 20 and 21].This ensures that all fireflies gravitate toward more the appealing ones with brighter flashing until the population converges around the brightest one.The fireflies' algorithm is used in this operation and is controlled by three parameters: attraction, randomization, and absorption.The attractiveness parameter is defined using exponential functions and is based on the intensity of light between two fireflies.When this parameter is set to zero, the random walk associated with the randomization parameter, which is governed by the Gaussian distribution principle, generates a number from the [0,1] interval [17].However, absorption variables have an effect on the value of attractiveness parameters as they change from zero to infinity.In the scenario of converging to infinity, the movement of fireflies appears to be a chaotic system [17].The firefly optimization technique is illustrated briefly in Figure (2).[24, 25, 26, 27, 28, and 29].Karaboga [30, 31, 32, 33, and 34] presents the ABC algorithm based on this metaheuristic technique.Bees are grouped into three primary groups in this technique based on their tasks: employed, observer, and scout.Scout bees are in charge of locating food sources, while hired and observer bees are in charge of exploitation work at the source.To review the tasking of the bees, scout bees examine the region for food sources and mark them at random without regard for the richness of the food supply.The worker bees then fulfill their jobs, such as selecting some nectar-rich sources.Depending on the quantity of nectar, they modify their dancing style as well as their speed to attract spectator bees waiting in the hive.Onlooker bees immediately decide to go toward the sources.

Genetic Algorithm
Using a model of biological processes, GAs are a type of optimization technique.As GA draws parallels to biological systems, it employs concepts like "chromosome," "selection," "crossover," and "mutation" [35, 36, 37, and 38].The candidate solution to the optimization problem can be thought of as an array of n bits (loci) in length, with the size of the solution dictating the number of bits used.Chromosomes are a sequence of 0 and 1s in binary code, where n is the number of bits in the code.Conversely, selection, crossover, and mutation operators use probabilistic models that replicate the functions in biological processes to control the candidate solutions and speed up the convergence rate of the optimization process [39, 40, 41 42, and 43].

Formulation of the Problem
Assume we get a quadratic assignment problem having three matrices (F, D, C) of size (nxn), where F represents the diffusion matrix between amenities, D represents the distance matrix across sites, and C represents the cost matrix, i.e. the cost of allocating facilities to sites.They also have the vector, which holds all of the possible combinations of the elements 1, . . ., n, therefore the mathematical model for the quadratic assignment problem is as follows [2, 44, 45, 46, and 47].
Where ( , ) is the flow between facility () and facility (), ( (),() ) represents the distance between the site (()) and site (()), and ( ,() ) represents the fixed cost of allocating the facility() to the site (().As a result of the quadratic assignment problem resulting in the modification of a portion of the problem's facilities, the cost-related portion of the problem is typically disregarded.Change it, and assuming the cost matrix does have a value of zero, the model becomes the following: The goal is to find the permutation vector () of the mathematical model (1,2) which reduces the objective function to the least possible.

Quadratic Assignment Problem
A quadratic problem in specialized knowledge arises when trying to assign n facilities to n regions in such a way that the total cost of allocation is minimized, with transmission cost being calculated by incrementing the flow among each pair of resources by the distance between their assigned locations.Facilities or methods can be used at any place to guarantee the lowest possible energy-momentum for the least possible outlay of money [1, 48, 49, and 50].

The Proposed Algorithm (TSQAP)
We will begin by discussing the several QAP capabilities available.It then proceeds to demonstrate the algorithm's theoretical underpinnings.We then describe the method for allocating available resources.Environmental selection mechanisms and reproductive strategies are discussed last.It has been suggested that the banned search algorithm (TS) could benefit from the following additions: 1-The (block list possession) algorithm's memory set is of the same size, which means that the memory entered to block an attribute is equal to the other memory.2-The block memory has variable dimensions, which means it can be increased or lowered within the algorithm depending on the solution's direction.3-Memory can be lowered to obtain quick solutions while condensing the solution and achieving good places.4-The incorporation of storage for past events our ability to recall a large number of fabricated solutions relies on this memory.This reminder is based on four different concepts, the incident, the problem, the solution, and some attribute and it enables us to gain from all past solutions and some atributes in producing a new solution.Measures of how often, how well, and how significantly something affects you.The quality memory is based on the achievement of the objective function, the brightness memory is based on the number of times this very same solution or attribute is replicated, and the event memory is based on the recording of each way to solve or characteristic from the last incarnation in which the solution occurred.The density of the solution and the duration of the created solution's effects on the improvement are both recorded.There are undoubtedly many benefits to using this algorithm, and it does get pretty close to the optimal solution on a regularly basis.On the other hand, it does take a little longer than other algorithms, and the fact that it discards some solutions and doesn't use them again lessens the value of diversification, even after the addition of long-term memory.Last but not least, the programmer might tailor the algorithm's design to the problem's data.Removing elements that are irrelevant to the topic at hand [3].

Multi-Memory Tabu Search Algorithm Procedures
The algorithm procedures as follows: a-Generate a specific solution.b-Calculate the value of the objective function of the current solution Z(S).c-Make S → X and Z(S) → Z(X).d-Tabu list (1, 2, … .) → ∅. e-The process is repeated.f-Generate a new solution ′ by moving a given neighborhood N(S) from the current solution that does not exist in 1, 2, … . .g-Recording the best solution found in 1, 2, … . and delete the old solution.h-Calculate the value of the objective function for the new substitution (′).i-If Z(S) < Z(X') make X' → S the conditional.j-Repeat the process until the stopping condition is met and print the best solution that was found.k-End.

The steps to make the forbidden search algorithm used to solve the quadratic assignment problem as follows:
a-Entering the issue of the issue in the form of descriptions in size () where () represents the size of the issue the flow matrix (F) and the distance matrix (D) include a memory matrix that records the frequency for each solution that has been transferred ( = ∅) and made it the size of the issue.b-Solving a preliminary solution (S) is complete solution to the issue with the calculation of the goal function for the first solution according to the equation (2).c-Make the solution ( =  * ) and it is necessary to make ( * = ()).d-Repetition meter set ( = 1).e-The creation of a preliminary workaround in the style of neighborhood research) N (s) (and here the functionality of order switching will be used by optional points that are not registered in the prohibition remembrance and their sites are replaced and a new solution is replaced and then the search process in the prohibition memory and the following form shows a mutation of a change.Ranks [9]: g-The stopping of the stops is continuing with steps (e, f) until the condition of stopping is achieved with the end of the number of total repetitions.

Simulation Experiment and Meanwhile Analysis
The problem of quadratic assignment has become a measure of the efficiency of algorithms due to the difficulty of finding an optimal solution in a suitable time, so any method that is developed to solve the problem must be applied to standard problems taken from the library of the quadratic assignment problem (QAPLIB) [9].Standard problems taken from the library with the solution repeated several times once and calculating the results based on the algorithm's efficiency law, which is [9]: Such that: : the solution found.: the best solution to the problem.In this paragraph, 8 standard problems were solved, taken from the virtual library of the quadratic assignment problem using the Tabu Sarch algorithm (TS), after repeating the solution of each problem (25) times and recording the results by calculating the mean gap of approach (GAP) and standard deviation, Min and Max that was found by comparing the results with Artificial Bee Colony (ABC), Firefly (FA), Genetic Algorithm (GA) and Particle Swarm Optimization (PSO) the Tabu Search algorithm outperformed other algorithms for most of the results, as the results of reaching the optimal solution for each algorithm were as follows in a Table (2): Now we can see some graphics of random selection of the existing problems.

Conclusions
In this paper, several conclusions were reached, which can be summarized as follows: 1-The use of the first stage of the algorithm and the directed search feature helps to greatly improve the memory of the Tabu Search (TS).2-These results in a quick convergence of the optimal solution to the problem, where the percentage of reaching the optimal solution in the first stage of the algorithm was approximately (75%).3-The extent of the algorithm's ability to reach the optimal solution, especially in solving Complex Optimization Problems (COP), depends mainly on the algorithm's ability to diversify the search for the solution, as well as diversify solutions and the speed of reaching the optimal solution depends on the criteria of rejection and acceptance of the new solution because these criteria help determine The search space is in the issue, so whenever this space is reduced, the speed of the algorithm in reaching is faster and also the same higher diversification.4-The percentage of access of the Tabu Search (TS) Algorithm to the optimal solution was (75.2%), and the Bee Colony algorithm was (31.2%), while the Firefly and Genetic algorithms were the worst if the percentage of reaching the optimal solution was (0.5%).

Figure ( 2 ):
Figure (2): Flowchart of firefly algorithm technique.[22and 23] 4. Artificial Bee Colony Algorithm Dorigo et al. developed the ACO technique to inspire honey bee intelligence in their search for food[24, 25, 26, 27, 28, and 29].Karaboga[30, 31, 32, 33, and 34]  presents the ABC algorithm based on this metaheuristic technique.Bees are grouped into three primary groups in this technique based on their tasks: employed, observer, and scout.Scout bees are in charge of locating food sources, while hired and observer bees are in charge of exploitation work at the source.To review the tasking of the bees, scout bees examine the region for food sources and mark them at random without regard for the richness of the food supply.The worker bees then fulfill their jobs, such as selecting some nectar-rich sources.Depending on the quantity of nectar, they modify their dancing style as well as their speed to attract spectator bees waiting in the hive.Onlooker bees immediately decide to go toward the sources.

Figure ( 2 ):
Figure (2): Shows the results of the approach gap

Table ( 2
(8)Shows the details of the system used to implement the algorithm After repeating the solution of each issue(8)once and recording the algorithm results, it showed its agreement, once from a total (375) repetition of the experiment while the number of times the local research algorithm arrived (2) as for the algorithm of the giving birth simulation (117) and the Tabu Search algorithm (174), we can see the details in a Table(3) below:

Table ( 4
) Shows the Results of the Comparison Between Algorithms