Our research deals with the optimization version of the set partition problem, where the objective is to minimize the absolute difference between the sums of the two disjoint partitions. Although this problem is known to be NP-hard and requires exponential time to solve, we propose a less demanding version of this problem where the goal is to find a locally optimal solution. In our approach, we consider the local optimality in respect to any movement of at most two elements. To accomplish this, we developed an algorithm that can generate a locally optimal solution in at most $O(N^2)$ time and $O(N)$ space. Our algorithm can handle arbitrary input precisions and does not require positive or integer inputs. Hence, it can be applied in various problem scenarios with ease.
翻译:本研究关注集合划分问题的优化版本,其目标是最小化两个不相交子集之和的绝对差值。尽管该问题已知为NP难问题且需要指数时间求解,我们提出了一个低求解难度的版本,旨在寻找局部最优解。在该方法中,局部最优性基于至多两个元素的任意移动进行考量。为此,我们开发了一种算法,能够在至多$O(N^2)$时间和$O(N)$空间内生成局部最优解。该算法可处理任意精度的输入,且不要求输入为正数或整数,因此可便捷地应用于多种问题场景。