Solving combinatorial optimization problems of the kind that can be codified by quadratic unconstrained binary optimization (QUBO) is a promising application of quantum computation. Some problems of this class suitable for practical applications such as the traveling salesman problem (TSP), the bin packing problem (BPP), or the knapsack problem (KP) have inequality constraints that require a particular cost function encoding. The common approach is the use of slack variables to represent the inequality constraints in the cost function. However, the use of slack variables considerably increases the number of qubits and operations required to solve these problems using quantum devices. In this work, we present an alternative method that does not require extra slack variables and consists of using an unbalanced penalization function to represent the inequality constraints in the QUBO. This function is characterized by larger penalization when the inequality constraint is not achieved than when it is. We evaluate our approach on the TSP, BPP, and KP, successfully encoding the optimal solution of the original optimization problem near the ground state cost Hamiltonian. Additionally, we employ D-Wave Advantage and D-Wave hybrid solvers to solve the BPP, surpassing the performance of the slack variables approach by achieving solutions for up to 29 items, whereas the slack variables approach only handles up to 11 items. This new approach can be used to solve combinatorial problems with inequality constraints with a reduced number of resources compared to the slack variables approach using quantum annealing or variational quantum algorithms.
翻译:求解可通过二次无约束二进制优化(QUBO)形式编码的组合优化问题,是量子计算的一项前景广阔的应用。在旅行商问题(TSP)、装箱问题(BPP)或背包问题(KP)等实际应用中,此类问题往往包含需要特殊代价函数编码的不等式约束。常规方法是引入松弛变量以在代价函数中表示不等式约束,但这会大幅增加利用量子设备求解时所需的量子比特数和操作数。本研究提出一种无需额外松弛变量的替代方法,即采用非平衡罚函数在QUBO中表示不等式约束。该函数的特点在于:当不等式约束未满足时施加更大惩罚,而约束满足时惩罚较小。我们将该方法应用于TSP、BPP和KP问题,成功将原始优化问题的最优解编码至基态代价哈密顿量附近。此外,我们利用D-Wave Advantage及D-Wave混合求解器求解BPP,其性能超越松弛变量法——新方法可处理多达29个物品的装箱问题,而松弛变量法仅能支持11个物品。相较于松弛变量法,该新方法在采用量子退火或变分量子算法时,能以更少的资源消耗求解含不等式约束的组合优化问题。