Algorithms and Complexity of Difference Logic
Konrad K. Dabrowski, Peter Jonsson, Sebastian Ordyniak, George Osipov
TL;DR
The paper conducts a thorough fine-grained complexity study of Difference Logic (DL) satisfiability, focusing on existential CNF sentences over rational variables and analyzing time complexity and parameterized complexity under arity and coefficient bounds. It establishes tight ETH-based upper and lower bounds for various restricted CSP languages ${\bf D}_{a,k}$, proves XP algorithms under incidence-treewidth for DL fragments, and demonstrates W[1]-hardness and pNP-hardness for key subproblems via reductions from Subset Sum, independent-set variants, and the multi-dimensional Subset Sum problem. A central technical contribution is the small-solution property for ${\sc CSP}({\bf D})$ enabling compact encodings, together with a novel divide-and-conquer strategy that yields a $2^{O(n\log\log n)}$ time algorithm for ${\sc CSP}({\bf D}_{2,k})$. The work also extends results to non-CNF formulas and to integer domains, enhancing the understanding of the DL-SAT landscape and guiding future inquiries into more general DL formalisms and structural parameterizations. Overall, the findings delineate when DL satisfiability remains tractable under strong complexity hypotheses and when natural restrictions still inherit hardness, informing practical SMT and AI applications that rely on DL reasoning.
Abstract
Difference Logic (DL) is a fragment of linear arithmetics where atoms are constraints x+k <= y for variables x,y (ranging over Q or Z) and integer k. We study the complexity of deciding the truth of existential DL sentences. This problem appears in many contexts: examples include verification, bioinformatics, telecommunications, and spatio-temporal reasoning in AI. We begin by considering sentences in CNF with rational-valued variables. We restrict the allowed clauses via two natural parameters: arity and coefficient bounds. The problem is NP-hard for most choices of these parameters. As a response to this, we refine our understanding by analyzing the time complexity and the parameterized complexity (with respect to well-studied parameters such as primal and incidence treewidth). We obtain a comprehensive picture of the complexity landscape in both cases. Finally, we generalize our results to integer domains and sentences that are not in CNF.
