Papers
Topics
Authors
Recent
Gemini 2.5 Flash
Gemini 2.5 Flash
194 tokens/sec
GPT-4o
7 tokens/sec
Gemini 2.5 Pro Pro
45 tokens/sec
o3 Pro
4 tokens/sec
GPT-4.1 Pro
38 tokens/sec
DeepSeek R1 via Azure Pro
28 tokens/sec
2000 character limit reached

A Faster FPTAS for #Knapsack (1802.05791v1)

Published 15 Feb 2018 in cs.DS

Abstract: Given a set $W = {w_1,\ldots, w_n}$ of non-negative integer weights and an integer $C$, the #Knapsack problem asks to count the number of distinct subsets of $W$ whose total weight is at most $C$. In the more general integer version of the problem, the subsets are multisets. That is, we are also given a set $ {u_1,\ldots, u_n}$ and we are allowed to take up to $u_i$ items of weight $w_i$. We present a deterministic FPTAS for #Knapsack running in $O(n{2.5}\varepsilon{-1.5}\log(n \varepsilon{-1})\log (n \varepsilon))$ time. The previous best deterministic algorithm [FOCS 2011] runs in $O(n3 \varepsilon{-1} \log(n\varepsilon{-1}))$ time (see also [ESA 2014] for a logarithmic factor improvement). The previous best randomized algorithm [STOC 2003] runs in $O(n{2.5} \sqrt{\log (n\varepsilon{-1}) } + \varepsilon{-2} n2 )$ time. Therefore, in the natural setting of constant $\varepsilon$, we close the gap between the $\tilde O(n{2.5})$ randomized algorithm and the $\tilde O(n3)$ deterministic algorithm. For the integer version with $U = \max_i {u_i}$, we present a deterministic FPTAS running in $O(n{2.5}\varepsilon{-1.5}\log(n\varepsilon{-1} \log U)\log (n \varepsilon) \log2 U)$ time. The previous best deterministic algorithm [APPROX 2016] runs in $O(n3\varepsilon{-1}\log(n \varepsilon{-1} \log U) \log2 U)$ time.

Citations (5)

Summary

We haven't generated a summary for this paper yet.