Introducing Adaptive Artificial Bee Colony Algorithm ...

3 downloads 0 Views 276KB Size Report
[9] Sanjeev Arora, "Polynomial Time Approximation Schemes for. Euclidean Traveling Sa-lesman and Other Geometric Problems", Journal of the ACM, Vol.
Science and Information Conference 2013 October 7-9, 2013 | London, UK

Introducing Adaptive Artificial Bee Colony Algorithm and Using It in Solving Traveling Salesman Problem Amr Rekaby

A.A.Youssif, A.Sharaf Eldin

Faculty of computers and information Helwan University Cairo, Egypt [email protected]

Faculty of computers and information Helwan University Cairo, Egypt [email protected], [email protected]

Abstract—Artificial Bee colony algorithm is a modern swarm intelligence algorithm. This paper proposes a modified version of artificial bee colony algorithm called “Adaptive Artificial Bee Colony” (AABC). This paper compares between standard bee colony algorithm and the proposed adaptive bee colony algorithm through traveling salesman problem. Traveling salesman problem is one of the most common problems in the searching techniques evaluation, so the paper considers it as an experimental case for the algorithms' performance discrimination. The experiments were repeated across different benchmarks. The proposed adaptive artificial bee colony algorithm presents more efficiency than standard artificial bee colony algorithm. The final solution fitness value is enhanced by around 8% in adaptive artificial bee colony algorithm comparing to standard artificial bee colony algorithm’s solution. Keywords— Artificial bee colony algorithm; adaptive artificial bee colony algorithm; traveling salesman problem

I.

The motivation of this paper is how to add more artificial intelligence to the standard bee colony algorithm towards creating a new version of it, which performs better than the commonly known artificial bee colony algorithm. ABC algorithm is presented in section 2. AABC algorithm is discussed in section 3. In section 4, the traveling salesman problem (TSP) is described as the experiments case study in this paper. In Section 5, the experiments and results are provided. A conclusion is shown at the end of this paper in section 6. II.

ARTIFICIAL BEE COLONY (ABC) ALGORITHM

Artificial bee colony is an algorithm that simulates the swarm intelligence integration of bees’ colony in foraging activities. Real bees’ colonies contain three types of bees: 1) Worker bees (called also Employee bees). 2) Onlooker bees. 3) Scout bees.

INTRODUCTION

Any optimization problem's solutions can be fetched by two major techniques: exact combinatorial optimization techniques and approximate optimization techniques. Exact combination techniques are caring about finding the optimal solution ever in the search space by covering all the available solutions. On the other hand, approximate optimization techniques target fetching a solution that satisfies the needs and not far from the best solution. This technique does not address the optimal solution in the search space. Population-based optimization algorithms are part of the approximate techniques. These population-based algorithms contain Genetics, Swarm intelligence algorithms like Ant colony, Bee colony, cockroach, and others colonies [3]. Artificial bee colony (ABC) algorithm is a simulation of the real bee colony system and its foraging behaviors [2]. This paper study this behavior and provide an enhanced dynamic model of ABC algorithm called “Adaptive Artificial Bee Colony” (AABC) algorithm. We compile testing to compare between ABC and AABC algorithms according to against traveling salesman problem (TSP) to prove the proposed enhancements in AABC algorithm.

First of all this is a description for each kind of bees. The worker bees are assigned to real honey nectar sources. The workers go to these sources, get the nectar, and return to the hive. When they return to the hive, they do a waggle dance. This dance describes the evaluation of the food source and its direction. In artificial bee algorithm, the food source is a solution of the optimization problem, and evaluation of this source is the evaluation of the fitness function of this solution. For example in Traveling salesman problem, the food source is a valid route, and the worker bee dance represents the fitness value (route cost) of this path. Back to the bees foraging behaviors, after the workers bee dance in front of the hive, there are a set of bees (onlooker bees) watching this dance, choose one (or more) of the workers sources. This selection of a worker source depends on the evaluation of that source. After the onlookers choose a subset of the resources, the onlookers go to these sources and search in their neighbors to find a better food source. After that the onlookers return to the hive with their findings [5, 7]. In the same time, there is a small set of bees called scout bees, these bees work always in new food sources exploring.

1|P age www.conference.thesai.org

Science and Information Conference 2013 October 7-9, 2013 | London, UK

They do not depend on the worker or onlookers findings. Scout bees explore new areas to get new food source and return this information to the hive. By this step, a cycle in natural bee colony foraging is completed, at the beginning of the new cycle, the bee workers should select new generation of sources for the new cycle from all the available sources (old worker sources, onlookers findings and scout discovered sources). Regarding the artificial algorithm, all these natural behaviors are simulated. Onlookers bees select the sources depends on the source's (solution's) fitness. Some researches just sort the solutions and get the top fitness group, and others select using a roulette wheel probability, as the following: Pi= fit i / ∑fitn

n=1 →SN (1)

fitness mean value. So the count of worker bees in generation (X) might be greater than or less than the count of the worker bees in generation (X-1) up on the finding solutions fitness values. This adaption is under a constraint of minimum and maximum worker counts. Therefore, two new parameters are needed for AABC algorithm: • Minimum worker bees count. • Maximum worker bees count. The main concept in this dynamic worker bee’s count is described in the following points: •

If a lot of available solutions fitness’s are better than the last generation mean value, so this generation has a lot of valuable (dramatically enhanced solutions) and the algorithm should keep as much as possible of these solutions (doesn’t exceed maximum worker count) and concentrate in the next cycle on worker local search actions. This count of worker bees may be greater than original worker bees count, this delta of bees is removed from "onlookers" bees force. This action considers that: while the generation becomes much enhanced, so this is the time to keep good solutions and check in their minor neighbors solutions. This change could be understood by just converting part of onlooker bees to be worker bees for one (the next) cycle. After the next cycle work, all numbers are a matter of change, workers could be increased again, or decreased according to the generations and the history of mean values (the last generation is the only considered history one).



On the other hand, if the generation over all does not have such dramatic enhancements, the worker bees could be decreased (just keeping the solution better than the last generation mean value) taking into consideration the minimum worker bees count parameter. This delta of bees (delta between the original worker count and the particular generation worker count) should join the scout bees list. They target exploring new areas in the search space to overcome this straggled generations sources (local minimum trap). These delta bees are joining the scouts set for one cycle, in the next cycle the objective/role of these bees will be dynamically decided according to the generation fitness values and the history of the fitness mean.

Where fiti is the fitness value of the solution number i and SN is the count of the food sources (which is equal to the number of worker bees). In this paper's experiments, the paper uses the probability selection for the onlooker’s bees as a selection method. Some researches go to that: the worker bees also do some search activity in the neighborhood area but within a very small scale, then onlooker bees do the search with a wider scope than worker bees. Figure 1 shows ABC algorithm steps. Fig. 1. ABC algorithm description.

The exit condition in figure 1 is “requirements are met”, this condition might be an acceptable solution fitness value, and also it might be a count of cycles. Maximum cycle number (MCN) is the used exit criteria in this research [6]. By definition, there are four mandatory parameters for ABC algorithm: worker bees count, onlooker bees count, scout bees count, maximum cycle number (MCN). These parameters are mandatory for ABC to be able to do its logic. III.

ADAPTIVE ARTIFICIAL BEE COLONY (AABC) ALGORITHM

Adaptive Artificial Bee Colony is the proposed algorithm in this research based on standard bee colony algorithm that has been described in the last section. The adaptive bee colony uses the same three types of bees apparently like ABC. The role of each type is still the same. The enhancements over ABC are in the flexibility of the bees’ role exchange. The selection of each cycle (generation) worker bees is the main modified phase in AABC. In normal ABC algorithm, the selection of new worker generation is selecting (W) bees from the available solutions, where W is the worker bees count parameter. In AABC, the new worker bee’s generation sources should have better fitness value than the last generation’s

In figure 2, the relation between workers, onlookers, and scouts bee’s counts is described. The original counts of bees are adapted based on the increase and decrease of the worker bees count. As described above, these increases or decreases of worker bees’ count depend on the available solutions' fitness against last generation fitness mean calculated value. As presented in figure 2, the blue shape shows the original bees count parameter (100 worker, 50 onlooker, and 10 scouts). In case of rich generation (red shape), the worker bees are increased to be 135 bees, these extra bees come from onlooker bees (to be 15 instead of 50), the scout bees here is

2|P age www.conference.thesai.org

Science and Information Conference 2013 October 7-9, 7 2013 | London, UK

the same (10 bees). On the other hand in poor generation (green shape), the worker bees are decreased to be 65, this delta count of bees become scout,, the scout here is 45 bees instead of 10, the onlooker bees count in this case is resettled to be the default again (50 bees). All these values based on that, the maximum worker bees parameter is 135, and the minimum is 65. The change in the worker bees can be within this range range, it does nott have to be just these three values (default, maximum and minimum), but it might have any value within this range (the bees' role exchange works the same as methodology described above). Fig. 2. AABC adaptive bees count impact description description.

IV.

TRAVELING SALESMAN PROBLEM

Traveling sales man problem (TSP) is a commonly known NP-hard hard combinatorial optimization problem. Given a set of cities, it targets finding the shortest test path that covers all the cities and ended with the same started city. The inputs for TSP problem are a set of cities and the distance (cost) between these cities. The minimum route’s cost (that that covers all the cities) cities is the objective function of the TSP, SP, taking into consideration that the final city in the route should be the first one in the route. As described in figure 4, given a graph G= (V, E) where V is a set of cities V= {V1, V2…} and E is a set of edges representing the distance cost between cities E= {(r, s): r, s ∈ V} [7, 9]. Fig. 4. Symmetric TSP graph of cities.

AABC algorithm is described in an activity flow diagram in figure 3. Fig. 3. AABC algorithm description description.

A lot of evolutionary and swarm algorithms are used in solving TSP problem, sample of these algorithms are Genetic algorithm, Ant colony algorithm, Tabu search and bee colony algorithm [1, 8]. The paper uses TSP as a case study problem in experimental work to evaluate AABC versus ABC algorithm. V.

EXPERIMENTS AND RESULTS

In this section, the implementation, experiments and results details are discussed.. To evaluate AABC and judge the impacts of its dynamic behavior versus ABC algorithm, two simulators are implemented,, one uses ABC algorithm, algorithm and another one uses AABC algorithm (same ABC implementation plus the dynamic role exchange feature).. Both simulators use the same ABC parameters (worker bees’ ees’ count, onlooker bees’ count, scout bees’ count, cycle count). AABC simulator uses extra two parameters (maximum worker bees' count, and minimum worker bees' count). Both simulators are implemented using Java 5. Experiments were run on the following machine specifications: • Windows XP professional, SP 3. • Intel core 2 Duo CPU. • 4 G Ram total size. • 2.8 GHz processor speed. A. Experiments Benchmark Data A commonly known repository for TSP benchmark data is located online at [4]. It has nationals nals test data that list the cities

3|P age www.conference.thesai.org

Science and Information Conference 2013 October 7-9, 2013 | London, UK

per country and their (X, Y) dimensions. Traveling sales man path of these countries could be calculated by Euclidean calculations between cities coordinates. The experiments were repeated for each and every benchmark data for ten times and the average of the results are presented in the next sections. The experiments were run on the following countries data: • Western Sahara (29 cities). • Djibouti (38 cities). • Qatar (194 Cities). • Uruguay (734 Cities)

According to the comparison graphs, AABC presents more enhanced solutions. The progress of AABC curve is higher than ABC curve. After a number of cycles, the solution becomes slightly saturated in both algorithms as appear in figure 7. Many worker bees change role to scout bees due to the dynamic performance of the bees in AABC. Enhancements after this saturation phase are probably happened in AABC curve more than in ABC curve. This probability is a result of the big number of scout bees in AABC algorithm (according to saturation phase) which explore the search space randomly and could discover dark areas for the bees. Meanwhile, the same bees force (total number of the generation) in ABC and AABC algorithm is used.

The experiments results are listed in table 1 below.

• Onlookers count = 100. • Scouts count = 20. • Cycle count = 200.

100000 80000 60000 40000 20000 0

ABC AABC 1 26 51 76 101 126 151 176

• Workers count = 300.

Best Solution Fitness Value

Fig. 7. Qatar TSP experiments results

B. Experiments parameters and results The experiments executions use the following values for the running parameters:

• Minimum worker count for AABC= 250.

Bees Cycles

• Maximum worker count for AABC= 350.

20000 10000

ABC

0

1000000 ABC

500000

AABC

0

AABC

Bees Cycles

Bees Cycles As shown in table 1, the experiments’ results values and analysis percentages are presented. Table 1 lists ABC, AABC best solutions fetched. The table presents the enhancements percentage that AABC provides over ABC algorithm.

Fig. 6. Djibouti TSP experiments results

100000 80000 60000 40000 20000 0

TABLE I.

ABC AABC 1 26 51 76 101 126 151 176

Best Solution Fitness Value

1500000

1 26 51 76 101 126 151 176

Best Solution Fitness Value

30000

2000000

1 26 51 76 101 126 151 176

Fig. 5. Western Sahara TSP experiments results.

Fig. 8. Uruguay TSP experiments results

Best Solution Fitness Value

The results of the experiments are presented in figures 5, 6, 7, and 8. X axis represents the cycle number. Y axis represents the best solution fitness value (until this cycle).

Bees Cycles

ABC VS. AABC EXPERIMENTS RESULTS.

Benchm ark Test data

Number of cities

ABC Fitness value

AABC Fitness value

Percentage of enhancements

Western Sahara

29

31487

28670

%8.94654937

Djibouti

38

8934

7899

%11.584956

Qatar

194

36402

33288

%8.554475029

4|P age www.conference.thesai.org

Science and Information Conference 2013 October 7-9, 2013 | London, UK Benchm ark Test data

Number of cities

ABC Fitness value

AABC Fitness value

Percentage of enhancements

Uruguay

734

1052943

1019918

%3.136447082

C. Experiments Results Extension In this section, we show extra experiments. TSP solution is based on tour generating. There are many tour constructing ways. In our research, we use the random tour generation mechanism. In this section, we explain the results of random tour generation benchmark (Concorde software) [11]. Same random mechanism is used in our simulators as an initial solutions generation (generation 1). Table 2 presents how AABC algorithm enhances this random solution value by its iteration dynamic logic (after 200 cycles). There are other tour-generating algorithms for heuristic TSP solution finding. "Nearest Neighbor" is one of these known algorithms. While ABC and AABC simulators use random technique to create the initial generation's solutions, the random solution of Concorde software is mentioned in table 2. The random solution is captured from Concorde for ten times per each test case, and the mean value is determined in table 2. If our developed simulators used "Greedy" or "nearest neighbor" algorithm to create the initial population, we would reach better final solution of the test cases, and we would introduce these algorithms results in Concorde software in these comparisons, but this is not the current provided work. TABLE II.

Test Case

ABC VS. AABC EXPERIMENTS RESULTS.

Concorde Mean Random solution value

AABC algorithm best solution fitness value

AABC Enhancement percentage over Concorde random generated solution

Western Sahara

132765

28670

%78

Djibouti

27888

7899

%72

Qatar

91553

33288

%64

Uruguay

1630002

1019918

%37

VI.

CONCLUSION

Adaptive artificial bee colony algorithm is a new proposed swarm algorithm based on ABC algorithm. AABC algorithm workflow is similar to ABC algorithm but with different bees assignment techniques and dynamic bees’ role distribution logic. It acts more dynamically than ABC due to the dynamic bees’ allocation to the resources; this allocation depends on the generation fitness values. Worker bees count in AABC might be increased or decreased within the algorithm execution time with keeping the overall generation bees count fixed. AABC algorithm is compared in this paper against ABC algorithm in traveling salesman problem. Experiments were executed to judge the proposed algorithm enhancements using multiple benchmarks data. According to these experiments, AABC algorithm presents more dynamically, adaptable, and efficient performance than ABC algorithm. 8% is the average efficiency enhancement in AABC algorithm’s final fetched solution in all tested benchmarks cases. REFERENCES [1]

[2] [3]

[4] [5]

[6]

[7]

[8]

[9]

Alexander Barvinok, Arie Tamir, Sa´ Ndor P. Fekete, Gerhard J. Woeginger, David S. Johnson, Russ Woodroofe. "The Geometric Maximum Traveling Salesman Problem". Journal of the ACM, Vol. 50, No. 5, pp. 641–664, September 2003. D. Karaboga , B. Basturk , “On the performance of artificial bee colony (ABC) algorithm,” Applied Soft Computing 8, 2008,pp,687-697 Dervis Karaboga, Bahriye Akay. "A Comparative Study of Artificial Bee Colony Algo-rithm". Applied Mathematics and Computation Journal, Elelsevier, pp. 108–132, 2009. National Traveling Salesman Problems. http://www.tsp.gatech.edu/world/countries.html [Mar 10, 2013]. Karl O. Jones, André Bouffet."Comparison of Bees Algorithm, Ant Colony Optimisation and Particle Swarm Optimisation for Pid Controller Tuning". International Conference on Computer Systems and Technologies - CompSysTech’08, 2008. Ling Wang, Gang Zhou, Ye Xu, Shengyao Wang, Min Liu. "An effective artificial bee colony algorithm for the flexible job-shop scheduling problem", Int J Adv Manuf Technol, September 2011. Li-Pei Wong, Malcolm Yoke Hean Low, Chin Soon Chong. "A Bee Colony Optimization Algorithm for Traveling Salesman Problem", Second Asia International Conference on Modelling & Simulation, IEEE, 2008, pp. 818-823. M. Fatih Tasgetiren, P. N. Suganthan, Quan-Ke Pan, "A Discrete Particle Swarm Optimi-zation Algorithm for the Generalized Traveling Salesman Problem", GECCO’07, ACM, 2007. Sanjeev Arora, "Polynomial Time Approximation Schemes for Euclidean Traveling Sa-lesman and Other Geometric Problems", Journal of the ACM, Vol. 45, No. 5, pp. 753–782, September 1998.

5|P age www.conference.thesai.org