arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2601.21202cs.DS
收藏

N重复元素问题的精确(n+2)比较复杂度

Exact (n + 1) Comparison Complexity for the N-Repeated Element Problem

Andrew Au

AI总结:

本文通过图论结构和对手论证,证明了在N重复元素问题中,确定性算法需要恰好n+2次比较才能找到重复n次的元素。

摘要:

本文确立了在等于比较模型下,使用O(1)额外空间,寻找一个在2n元素数组中重复n次的元素的精确比较复杂度。我们提出了一种简单的确定性算法,恰好需要n+2次比较,并证明这个界限是紧的:任何正确的算法在最坏情况下至少需要n+2次比较。下限通过使用图论结构的对手论证得出。等查询构建一个不等式图I;其补集P(潜在等式)必须包含两个不相交的n- clique或一个(n+1)- clique以保持模糊性。我们证明这些结构通过

英文摘要:

This paper establishes the exact comparison complexity of finding an element repeated $n$ times in a $2n$-element array containing $n+1$ distinct values, under the equality-comparison model with $O(1)$ extra space. We present a simple deterministic algorithm performing exactly $n+1$ comparisons and prove this bound \emph{tight}: any correct algorithm requires at least $n+1$ comparisons in the worst case. The lower bound follows from an adversary argument using graph-theoretic structure. Equality queries build an \emph{inequality graph} $I$; its complement $P$ (potential-equalities) must contain either two disjoint $n$-cliques or one $(n+1)$-clique to maintain ambiguity. We show these structures persist through $n$ comparisons via a ``pillar matching'' construction, but cannot survive the $(n+1)$st. The matching upper bound comes from a ``triangle'' construction that forces every component of $I$ to be a clique, so each hosts at most one copy of the repeated element and the single untested element must be the answer. This result provides a concrete, self-contained demonstration of exact lower-bound techniques, bridging toy problems with nontrivial combinatorial reasoning.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑