PYAsUKP: Yet Another solver for the Unbounded Knapsack Problem.
Join work of Poirriez,V (UVHC/LAMIH UMR CNRS 8530 France), Yanev,N (University of SOFIA, Bulgaria), Andonov,R (IRISA France)
PYAsUKP implements the EDUK2 algorithm distinguished by Kellerer et all. as the best known algorithm to solve the Unbounded Knapsack Problem in their 2005 book Knapsack Problems.
EDUK2 is described in: Vincent Poirriez, Nicola Yanev, Rumen Andonov: A Hybrid Algorithm for the Unbounded Knapsack Problem, Discrete Optimization, Volume 6, Issue 1, February 2009, Pages 110-124. Available online: DOI.
Here is the abstract of this publication:
this paper presents a new approach for exactly solving the Unbounded Knapsack Problem (UKP) and proposes a new bound that was proved to dominate the previous bounds on a special class of UKP instances. Integrating bounds within the framework of sparse dynamic programming led to the creation of an efficient and robust hybrid algorithm, called EDUK2. This algorithm takes advantage of the majority of the known properties of UKP, particularly the diverse dominance relations and the important periodicity property. Extensive computational results show that, in all but a very few cases, EDUK2 significantly outperforms both MTU2 and EDUK, the currently available UKP solvers, as well the well-known general purpose mathematical programming optimizer CPLEX of ILOG. These experimental results demonstrate that the class of hard UKP instances needs to be redefined, and the authors offer their insights into the creation of such instances.
pyasukp also implements a data set generator (see the option -form below).
Quite a lot of options are available, a short list is
- -nobb to use a pure dynamic programing algorithm (roughly speaking the EDUK algorithm published in 2000 in EDUK paper).
- -form [s|c|w|u|saw|rh|hd] to generate UKP instances
- s uses the strong-correlated formula pi=awi+b
- c wi = wmin+i pi=wi+step the stpe is defined by the option -step
- w weakly correlated formula: pi is chosen randomly in the intervall [awi−b..awi+b]
- u not correlated without any simply dominated items
- rh pi=i+wi
- hd pi=max(1 + pi−1; floor((wi× pi1)/wi−1)) forula (6) in EDUK paper
- saw to genarate a saw ukp (see the Listing 2 in DOI.)
- -wmin -wmax -pmin -pmax -cap to define respectively the minimum[maximum] weight and profit and the knapsack capacity
- -nosolve to only generate data together with -save to specify the named file
- -seed n to give the seed n to the random generator
Ce document a été traduit de LATEX par HEVEA