TLDR: Solving the Knapsack Problem with Evolutionary Algorithms
Date: 2022-03-07 Source: https://arpitbhayani.me/blogs/genetic-knapsack
Overview
Solve the Knapsack problem with a Genetic Algorithm! This guide offers a polynomial-time approximation for this famous optimization challenge. The Knapsack problem is one of the most famous problems in computer science.
Key Points
- The Knapsack problem is one of the most famous problems in computer science.
- Optimal solution: The solution to the Knapsack problem uses Recursion with memoization to find the optimal solution.
- Run-time Complexity: The above solution runs with a complexity of O(n.W) where n is the total number of items and W is the maximum weight the knapsack can carry.
- The Genetic Process: The basic idea behind the Genetic Algorithm is to start with some candidate Individuals (solutions chosen at random) called Population.
- An Individual in the Genetic Algorithm is a potential solution.