Online Unbounded Knapsack

被引:0
|
作者
Boeckenhauer, Hans-Joachim [1 ]
Gehnen, Matthias [2 ]
Hromkovic, Juraj [1 ]
Klasing, Ralf [3 ]
Komm, Dennis [1 ]
Lotze, Henri [2 ]
Mock, Daniel [2 ]
Rossmanith, Peter [2 ]
Stocker, Moritz [1 ]
机构
[1] Swiss Fed Inst Technol, Dept Comp Sci, Zurich, Switzerland
[2] Rhein Westfal TH Aachen, Dept Comp Sci, Aachen, Germany
[3] Univ Bordeaux, CNRS, LaBRI, Talence, France
关键词
Online knapsack; Unbounded knapsack; Online algorithm; Advice complexity; ADVICE COMPLEXITY; ALGORITHMS; FPTAS; TREE;
D O I
10.1007/s00224-025-10215-0
中图分类号
TP301 [理论、方法];
学科分类号
081202 ;
摘要
We analyze the competitive ratio and the advice complexity of the online unbounded knapsack problem. An instance is given as a sequence of n items with a size and a value each, and an algorithm has to decide whether or not and how often to pack each item into a knapsack of bounded capacity. The items are given online and the total size of the packed items must not exceed the knapsack's capacity, while the objective is to maximize the total value of the packed items. While each item can only be packed once in the classical knapsack problem (also called the 0-1 knapsack problem), the unbounded version allows for items to be packed multiple times. We show that the simple unbounded knapsack problem, where the size of each item is equal to its value, allows for a competitive ratio of 2. We also analyze randomized algorithms and show that, in contrast to the 0-1 knapsack problem, one uniformly random bit cannot improve an algorithm's performance. More randomness lowers the competitive ratio to less than 1.736, but it can never be below 1.693. In the advice complexity setting, we measure how many bits of information (so-called advice bits) the algorithm has to know to achieve some desired solution quality. For the simple unbounded knapsack problem, one advice bit lowers the competitive ratio to 3/2. While this cannot be improved with fewer than loglog22nn advice bits for instances of length n, a competitive ratio of 1 + epsilon can be achieved with O(epsilon(-1 )<middle dot> log(n epsilon(-1))) advice bits for any epsilon > 0. We further show that no amount of advice bounded by a function f(n) allows an algorithm to be optimal. We also study the online general unbounded knapsack problem and show that it does not allow for any bounded competitive ratio for both deterministic and randomized algorithms, as well as for algorithms using fewer than log(2)n advice bits. We also provide a surprisingly simple algorithm that uses O(epsilon(-1 )<middle dot> log(n epsilon(-1))) advice bits to achieve a competitive ratio of 1 + epsilon for any epsilon > 0.
引用
收藏
页数:25
相关论文
共 50 条
  • [21] The Online Knapsack Problem with Departures
    Sun B.
    Yang L.
    Hajiesmaili M.
    Wierman A.
    Lui J.C.S.
    Towsley D.
    Tsang D.H.K.
    Performance Evaluation Review, 2023, 51 (01): : 59 - 60
  • [22] Online knapsack with resource augmentation
    Iwama, Kazuo
    Zhang, Guochuan
    INFORMATION PROCESSING LETTERS, 2010, 110 (22) : 1016 - 1020
  • [23] Removable Online Knapsack and Advice
    Bockenhauer, Hans-Joachim
    Frei, Fabian
    Rossmanith, Peter
    41ST INTERNATIONAL SYMPOSIUM ON THEORETICAL ASPECTS OF COMPUTER SCIENCE, STACS 2024, 2024, 289
  • [24] Online minimization knapsack problem
    Han, Xin
    Makino, Kazuhisa
    THEORETICAL COMPUTER SCIENCE, 2016, 609 : 185 - 196
  • [25] The Online Knapsack Problem with Departures
    Sun, Bo
    Yang, Lin
    Hajiesmaili, Mohammad
    Wierman, Adam
    Lui, John C. S.
    Towsley, Don
    Tsang, Danny H. K.
    PROCEEDINGS OF THE ACM ON MEASUREMENT AND ANALYSIS OF COMPUTING SYSTEMS, 2022, 6 (03)
  • [26] Online Minimization Knapsack Problem
    Han, Xin
    Makino, Kazuhisa
    APPROXIMATION AND ONLINE ALGORITHMS, 2010, 5893 : 182 - 193
  • [27] Online Knapsack with Removal and Recourse
    Boeckenhauer, Hans-Joachim
    Klasing, Ralf
    Moemke, Tobias
    Rossmanith, Peter
    Stocker, Moritz
    Wehner, David
    COMBINATORIAL ALGORITHMS, IWOCA 2023, 2023, 13889 : 123 - 135
  • [28] Removable online knapsack problems
    Iwama, K
    Taketomi, S
    AUTOMATA, LANGUAGES AND PROGRAMMING, 2002, 2380 : 293 - 305
  • [29] Solving Unbounded Knapsack Problem Based on Quantum Genetic Algorithms
    Chen, Rung-Ching
    Huang, Yun-Hou
    Lin, Ming-Hsien
    INTELLIGENT INFORMATION AND DATABASE SYSTEMS, PT I, PROCEEDINGS, 2010, 5990 : 339 - 349
  • [30] UKP5: A New Algorithm for the Unbounded Knapsack Problem
    Becker, Henrique
    Buriol, Luciana S.
    EXPERIMENTAL ALGORITHMS, SEA 2016, 2016, 9685 : 50 - 62