We implement four algorithms for solving linear Diophantine equations in the naturals: a lexicographic enumeration algorithm, a completion procedure, a graph-based algorithm, and the Slopes algorithm. As already known, the lexicographic enumeration algorithm and the completion procedure are slower than the other two algorithms. We compare in more detail the graph-based algorithm and the Slopes algorithm. In contrast to previous comparisons, our work suggests that they are equally fast on small inputs, but the graph-based algorithm gets much faster as the input grows. We conclude that implementations of AC-unification algorithms should use the graph-based algorithm for maximum efficiency.
翻译:我们实施了四种算法来解决自然界中的线性二恶英方程式:一种地名录查算算法、一种完成程序、一种基于图表的算法和Slopes算法。 众所周知, 地名录查算法和完成程序比另外两种算法慢。 我们比较了基于图表的算法和斯洛佩斯算法。 与以往的比较相比,我们的工作表明,这些算法在小投入上同样快,但基于图表的算法随着输入的增加而加快得多。 我们的结论是,应用AC统一算法应该使用基于图表的算法来达到最高的效率。