基于动态规划的子集和变量的经典与量子算法
Classical and Quantum Algorithms for Variants of Subset-Sum via Dynamic Programming
摘要:
子集求和是一个NP完全问题,其中必须判定$n$整数的多集合是否包含其元素和为目标值$m$的子集。最著名的经典和量子算法分别在时间上运行$\tilde{O}(2^{n/2})$和$\tilde{O}(2^{n/3})$,基于著名的中间相遇技术。在这里,我们介绍了一种新的经典的动态编程为基础的数据结构与应用程序的子集和和一些变种,其中包括(其中寻找两个具有相同和的不相交子集),2-Subset-Sum(Subset-Sum的一个宽松版本,其中输入集中的每个项目可以在求和中使用两次),以及Shifted-Sums,这两个变体的推广,其中寻找两个不相交的子集,其和相差某个指定值。给定任何模数$p$,我们的数据结构可以在时间上构造为$O(n^2p)$,之后可以在时间上查询$O(n^2)$,查询求和为任何模数$p$的值的子集列表。我们使用这种数据结构结合可变时间振幅放大和一个新的量子对发现算法,扩展的量子爪发现算法的多个解决方案的情况下,给出一个$O(2^{0.504n})$量子算法的移位和,最有名的$O(2^{0.773n})$经典的运行时间的改进。顺便说一句,我们获得了新的$\tilde{O}(2^{n/2})$和$\tilde{O}(2^{n/3})$经典和量子算法的子集和,而不是基于开创性的满足在中间的方法。我们还研究了鸽子洞模型和鸽子洞模型和鸽子洞,其中解决方案的存在性是由鸽子洞原理保证。对于前一个问题,我们给出了更快的经典和量子算法的运行时间$\tilde{O}(2^{n/2})$和$\tilde{O}(2^{2n/5})$,分别。对于更一般的模块化问题,我们给出了一个经典的算法,也运行在时间$\tilde{O}(2^{n/2})$。
英文摘要:
Subset-Sum is an NP-complete problem where one must decide if a multiset of $n$ integers contains a subset whose elements sum to a target value $m$. The best-known classical and quantum algorithms run in time $\tilde{O}(2^{n/2})$ and $\tilde{O}(2^{n/3})$, respectively, based on the well-known meet-in-the-middle technique. Here we introduce a novel classical dynamic-programming-based data structure with applications to Subset-Sum and a number of variants, including Equal-Sums (where one seeks two disjoint subsets with the same sum), 2-Subset-Sum (a relaxed version of Subset-Sum where each item in the input set can be used twice in the summation), and Shifted-Sums, a generalization of both of these variants, where one seeks two disjoint subsets whose sums differ by some specified value. Given any modulus $p$, our data structure can be constructed in time $O(n^2p)$, after which queries can be made in time $O(n^2)$ to the lists of subsets summing to any value modulo $p$. We use this data structure in combination with variable-time amplitude amplification and a new quantum pair finding algorithm, extending the quantum claw finding algorithm to the multiple solutions case, to give an $O(2^{0.504n})$ quantum algorithm for Shifted-Sums, an improvement on the best-known $O(2^{0.773n})$ classical running time. Incidentally, we obtain new $\tilde{O}(2^{n/2})$ and $\tilde{O}(2^{n/3})$ classical and quantum algorithms for Subset-Sum, not based on the seminal meet-in-the-middle method. We also study Pigeonhole Equal-Sums and Pigeonhole Modular Equal-Sums, where the existence of a solution is guaranteed by the pigeonhole principle. For the former problem, we give faster classical and quantum algorithms with running time $\tilde{O}(2^{n/2})$ and $\tilde{O}(2^{2n/5})$, respectively. For the more general modular problem, we give a classical algorithm that also runs in time $\tilde{O}(2^{n/2})$.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。