The Coin Change problem, also known as the Change-Making problem, is a well-studied combinatorial optimization problem, which involves minimizing the number of coins needed to make a specific change amount using a given set of coin denominations. A natural and intuitive approach to this problem is the greedy algorithm. While the greedy algorithm is not universally optimal for all sets of coin denominations, it yields optimal solutions under most real-world coin systems currently in use, making it an efficient heuristic with broad practical applicability. Researchers have been studying ways to determine whether a given coin system guarantees optimal solutions under the greedy approach, but surprisingly little attention has been given to understanding the general computational behavior of the greedy algorithm applied to the coin change problem. To address this gap, we introduce the Greedy Coin Change problem and formalize its decision version: given a target amount $W$ and a set of denominations $C$, determine whether a specific coin is included in the greedy solution. We prove that this problem is $\mathbf P$-complete under log-space reductions, which implies it is unlikely to be efficiently parallelizable or solvable in limited space.
翻译:硬币找零问题(又称找零问题)是一个被深入研究的组合优化问题,其目标是在给定硬币面额集合下,使用最少数量的硬币凑出特定金额。该问题的一种自然而直观的解决方法是贪心算法。虽然贪心算法并非对所有面额集合都能保证最优解,但在当前大多数实际使用的货币体系下,它确实能产生最优解,因此是一种具有广泛实用性的高效启发式算法。研究者们一直在探索如何判定给定硬币体系是否能在贪心策略下保证最优解,但令人惊讶的是,对于贪心算法在硬币找零问题中一般计算行为的理解却鲜有关注。为填补这一空白,本文提出贪心硬币找零问题,并形式化其判定版本:给定目标金额 $W$ 与面额集合 $C$,判断特定硬币是否出现在贪心解中。我们证明该问题在对数空间归约下是 $\mathbf P$ 完全的,这意味着它不太可能被高效并行化或在有限空间内求解。