$(1-ε)$-Approximation of Knapsack in Nearly Quadratic Time (2308.07004v3)
Abstract: Knapsack is one of the most fundamental problems in theoretical computer science. In the $(1 - \epsilon)$-approximation setting, although there is a fine-grained lower bound of $(n + 1 / \epsilon) ^ {2 - o(1)}$ based on the $(\min, +)$-convolution hypothesis ([K{\"u}nnemann, Paturi and Stefan Schneider, ICALP 2017] and [Cygan, Mucha, Wegrzycki and Wlodarczyk, 2017]), the best algorithm is randomized and runs in $\tilde O\left(n + (\frac{1}{\epsilon}){11/5}/2{\Omega(\sqrt{\log(1/\epsilon)})}\right)$ time [Deng, Jin and Mao, SODA 2023], and it remains an important open problem whether an algorithm with a running time that matches the lower bound (up to a sub-polynomial factor) exists. We answer the question positively by showing a deterministic $(1 - \epsilon)$-approximation scheme for knapsack that runs in $\tilde O(n + (1 / \epsilon) ^ {2})$ time. We first extend a known lemma in a recursive way to reduce the problem to $n \epsilon$-additive approximation for $n$ items with profits in $[1, 2)$. Then we give a simple efficient geometry-based algorithm for the reduced problem.
- SETH-based lower bounds for subset sum and bicriteria path. In Proceedings of the 30th ACM-SIAM Symposium on Discrete Algorithms (SODA), pages 41–57, 2019. doi:10.1137/1.9781611975482.3.
- Geometric applications of a matrix-searching algorithm. Algorithmica, 2(1):195–208, November 1987. doi:10.1007/BF01840359.
- Necklaces, convolutions, and x+y. Algorithmica, 69(2):294–314, June 2014. doi:10.1007/s00453-012-9734-3.
- Fast Convolutions for Near-Convex Sequences. In Satoru Iwata and Naonori Kakimura, editors, 34th International Symposium on Algorithms and Computation (ISAAC 2023), volume 283 of Leibniz International Proceedings in Informatics (LIPIcs), pages 16:1–16:16, Dagstuhl, Germany, 2023. Schloss Dagstuhl – Leibniz-Zentrum für Informatik. URL: https://drops-dev.dagstuhl.de/entities/document/10.4230/LIPIcs.ISAAC.2023.16, doi:10.4230/LIPIcs.ISAAC.2023.16.
- A fine-grained perspective on approximating subset sum and partition. In Proceedings of the 2021 ACM-SIAM Symposium on Discrete Algorithms, SODA 2021, Virtual Conference, January 10 - 13, 2021, pages 1797–1815. SIAM, 2021. doi:10.1137/1.9781611976465.108.
- On near-linear-time algorithms for dense subset sum. In Dániel Marx, editor, Proceedings of the 2021 ACM-SIAM Symposium on Discrete Algorithms, SODA 2021, Virtual Conference, January 10 - 13, 2021, pages 1777–1796. SIAM, 2021. doi:10.1137/1.9781611976465.107.
- Timothy M. Chan. Approximation Schemes for 0-1 Knapsack. In Proceedings of the 1st Symposium on Simplicity in Algorithms (SOSA), pages 5:1–5:12, 2018. doi:10.4230/OASIcs.SOSA.2018.5.
- On problems equivalent to (min,+)-convolution. ACM Trans. Algorithms, 15(1):14:1–14:25, January 2019. doi:10.1145/3293465.
- Deterministic apsp, orthogonal vectors, and more: Quickly derandomizing razborov-smolensky. In Proceedings of the 27th Annual ACM-SIAM Symposium on Discrete Algorithms (SODA), pages 1246–1255, 2016. doi:10.1137/1.9781611974331.ch87.
- Computational Geometry: Algorithms and Applications. Springer-Verlag, second edition, 2000. URL: http://www.cs.uu.nl/geobook/.
- Approximating knapsack and partition via dense subset sums. In Proceedings of the 2023 Annual ACM-SIAM Symposium on Discrete Algorithms (SODA), pages 2961–2979, 2023. URL: https://epubs.siam.org/doi/abs/10.1137/1.9781611977554.ch113, arXiv:https://epubs.siam.org/doi/pdf/10.1137/1.9781611977554.ch113, doi:10.1137/1.9781611977554.ch113.
- Computational complexity of approximation algorithms for combinatorial problems. In Jirí Becvár, editor, Mathematical Foundations of Computer Science 1979, Proceedings, 8th Symposium, Olomouc, Czechoslovakia, September 3-7, 1979, volume 74 of Lecture Notes in Computer Science, pages 292–300. Springer, 1979. doi:10.1007/3-540-09526-8_26.
- Fast approximation algorithms for the knapsack and sum of subset problems. Journal of the ACM (JACM), 22(4):463–468, October 1975. doi:10.1145/321906.321909.
- Ce Jin. An improved FPTAS for 0-1 knapsack. In Christel Baier, Ioannis Chatzigiannakis, Paola Flocchini, and Stefano Leonardi, editors, 46th International Colloquium on Automata, Languages, and Programming, ICALP 2019, July 9-12, 2019, Patras, Greece, volume 132 of LIPIcs, pages 76:1–76:14. Schloss Dagstuhl - Leibniz-Zentrum für Informatik, 2019. doi:10.4230/LIPIcs.ICALP.2019.76.
- A faster fptas for the unbounded knapsack problem. European Journal of Combinatorics, 68:148 – 174, 2018. doi:10.1016/j.ejc.2017.07.016.
- Richard M Karp. Reducibility among combinatorial problems. In Complexity of computer computations, pages 85–103. Springer, 1972.
- An efficient fully polynomial approximation scheme for the subset-sum problem. J. Comput. Syst. Sci., 66(2):349–370, 2003. doi:10.1016/S0022-0000(03)00006-0.
- Improved dynamic programming in connection with an fptas for the knapsack problem. Journal of Combinatorial Optimization, 8(1):5–11, March 2004. doi:10.1023/B:JOCO.0000021934.29833.6b.
- An efficient approximation scheme for the subset-sum problem. volume 1350, pages 394–403, 12 1997. doi:10.1007/3-540-63890-3_42.
- On the fine-grained complexity of one-dimensional dynamic programming. In Proceedings of the 44th International Colloquium on Automata, Languages, and Programming (ICALP), pages 21:1–21:15, 2017. doi:10.4230/LIPIcs.ICALP.2017.21.
- Eugene L. Lawler. Fast approximation algorithms for knapsack problems. Mathematics of Operations Research, 4(4):339–356, 1979. doi:10.1287/moor.4.4.339.
- Subquadratic approximation scheme for partition. In Proceedings of the 30th Annual ACM-SIAM Symposium on Discrete Algorithms (SODA), pages 70–88, 2019. doi:10.1137/1.9781611975482.5.
- Donguk Rhee. Faster fully polynomial approximation schemes for knapsack problems. Master’s thesis, Massachusetts Institute of Technology, 2015. URL: http://hdl.handle.net/1721.1/98564.
- Ryan Williams. Faster all-pairs shortest paths via circuit complexity. In Proceedings of the 46th Annual ACM Symposium on Theory of Computing (STOC), pages 664–673, 2014. doi:10.1145/2591796.2591811.