Speeding up the 0-1 Knapsack Problem Using Shuffled Frog Leaping Algorithm
Subject Areas : C.3. Software Engineering
1 - Department of Computer Engineering, Technical and Vocational University (TVU), Tehran, Iran
Keywords: SFLA, Shuffled Frog Leaping Algorithm, CUDA, Knapsack problem, the 0-1 Knapsack Problem,
Abstract :
The knapsack problem is known as a NP-hard problem. The knapsack or rucksack problem consists of determining, given a set of items, each of which has a cost and a value, the number of items included in a collection such that the total cost is less than a given cost and the total value is as large as possible. There is a dynamic programming solution for this problem called the 0-1 knapsack. The 0-1 knapsack problem restricts the number of individual items to zero or one. The shuffled frog-leaping algorithm (SFLA) has long been considered a meta-heuristic algorithm that derives from how frog groups search for food. SFLA can improve computing performance by letting all frogs participate in memetic evolution and access an excellent ability for global search by adding the self-variation behavior to the frog. This study represents an efficient solution for the 0-1 knapsack problem using SFLA. Regarding the parallel nature of most meta-heuristic algorithms, they can be successfully used for speedup. Since it is time-consuming to test all the cases when the problems become larger, Compute Unified Device Architecture (CUDA) is used to implement the solution in parallel. The results of simulating the 0-1 knapsack problem using SFLA on the CUDA platform show that the execution time for a parallel solution decreases as the population of frogs increases. For the 0-1 Knapsack problem, it is 252 times faster than the sequential solution.