Project for the course of "Problem Solving: Optimization Methods and Algorithms" AA.2018/2019
The multiple-choice knapsack problem (MCKP) is a generalization of the ordinary knapsack problem, where the set of items is partitioned into classes. The binary choice of taking an item is replaced by the selection of exactly one item out of each class of items.
Solution implemented by using dinamic programming.
- g++ compile 8.2.0
-
Dependences:
g++ -std=c++11 Main.cpp ComputeSolution.h ComputeSolutionImp.cpp MultipleChoiceKnapsackProblem.cpp OneOrNoneForClass.cpp PrintMatrix.cpp UtilsVectors.h
-
Build:
g++ -o main Main.cpp ComputeSolution.h ComputeSolutionImp.cpp MultipleChoiceKnapsackProblem.cpp OneOrNoneForClass.cpp PrintMatrix.cpp UtilsVectors.h
It is possible to start the computation from the command line with the command:
./main
Nota: first it's necessary to build the project.
A brief presentation of the system can be found in doc folder