NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Integer Programming with GCD Constraints

Rémy Défossez, Christoph Haase, Alessio Mansutti, Guillermo A. Pérez

TL;DR

This paper proves that Integer Programming (IP) remains in the complexity class NP even when you add constraints involving the Greatest Common Divisor (GCD) of linear terms. The authors establish a "small witness property," showing that if a solution exists for these non-linear systems, it must have a bit length that is only polynomially larger than the input size.

What Problem Does This Paper Address?

Classical Integer Programming—finding an integer solution to a system of linear inequalities ($A\mathbf{x} \le \mathbf{b}$)—is a cornerstone of operations research and computer science. While it is NP-complete, it is well-behaved: if a solution exists, it isn't "too big" to represent.

However, once you introduce non-linearities, things get dangerous. General quadratic Diophantine equations are undecidable (Hilbert's 10th Problem). GCD constraints, such as $\gcd(f(\mathbf{x}), g(\mathbf{x})) = d$, are essentially "Diophantine problems in disguise." Previous research into the existential theory of integers with addition and divisibility suggested that solutions to such systems could require an exponential number of bits, potentially pushing the problem into higher complexity classes like NEXP.

The authors set out to determine if IP with GCD constraints (IP-GCD) is actually simpler than the general theory suggests. Specifically, they ask: Is IP-GCD decidable in NP, and do optimal solutions have polynomial bit lengths?

Methods

The authors bridge the gap between linear IP and non-linear divisibility logic using several sophisticated mathematical tools:

  1. The "r-increasing" Fragment: They identify a specific structural fragment of divisibility logic called "r-increasing" formulas. They prove that while general divisibility formulas can have massive solutions, $r$-increasing ones have solutions with polynomial bit length. Crucially, they show that any IP-GCD instance can be transformed into a "3-increasing" formula.
  2. Local-to-Global Principle: They build on a principle established by Lipshitz (1978), which states that a formula is satisfiable over the integers if and only if it is satisfiable modulo every prime $p$.
  3. Refining "Difficult Primes": The bottleneck in previous proofs was a set of "difficult primes" that was too large. The authors use an in-depth analysis of "S-polynomials" and "divisibility modules" to prove that one only needs to consider a polynomial number of primes, each with polynomial bit length.
  4. A New Chinese Remainder Theorem (CRT): To combine local (modular) solutions into a global integer solution, the authors developed a novel version of the CRT. Unlike the standard version, this one handles both congruences ($x \equiv a \pmod m$) and non-congruences ($x \not\equiv a \pmod p$). They proved that the size of the resulting solution does not depend on the magnitude of the primes used in the non-congruences, only on their quantity.

Datasets

Not discussed in the paper. As a theoretical work in computational complexity, the paper relies on mathematical proofs rather than empirical benchmarks or training datasets.

Key Insights and Ideas

  • GCD as a Gateway: The paper demonstrates that GCD constraints are a "safe" form of non-linearity. They are expressive enough to be NP-hard even for a single variable (unlike classical IP), but restricted enough to avoid the undecidability of general quadratic equations.
  • The Power of Structure: The "r-increasing" property is the "aha moment." It provides a syntactic way to guarantee that divisibility constraints don't "chain" together in a way that forces the variables to grow double-exponentially (like the powers of 2).
  • Sieve Theory Application: By applying Brun’s pure sieve (a tool from analytic number theory), the authors were able to bound solution sizes for systems of non-congruences. This is a clever cross-pollination of number theory and complexity theory.

Key Results

  • NP-Completeness: The feasibility problem for IP-GCD is formally proven to be NP-complete.
  • Small Witness Property: If an IP-GCD instance is feasible, it has a solution (and an optimal solution, if one exists) of polynomial bit length.
  • Complexity Bounds: The authors provide explicit (though large) polynomial bounds for the bit length of solutions based on the number of variables and the magnitude of the coefficients.
  • Algorithmic Reduction: They provide a polynomial-time algorithm to reduce an IP-GCD system into an equivalent disjunction of 3-increasing systems of divisibility constraints.

Limitations and Future Work

  • The Gap in the General Theory: While this paper settles the complexity for the IP-GCD fragment, the exact complexity of the full existential theory of integers with addition and divisibility remains an open problem (currently known to be between NP and NEXP).
  • Word Equations: The authors suggest that their "r-increasing" framework could be applied to word equations with length constraints, potentially leading to new PSPACE or NP decidability results in that field.
  • Practical Solvers: This is a theoretical "membership in NP" proof. Translating these insights into a practical, high-performance solver that can handle GCD constraints alongside traditional linear constraints remains a challenge for the optimization community.

Summary updated

BibTeX
@inproceedings{defossez2024integer,
  author = {Rémy Défossez and Christoph Haase and Alessio Mansutti and Guillermo A. Pérez},
  title = {{Integer Programming with GCD Constraints}},
  booktitle = {SODA},
  year = {2024},
  doi = {10.1137/1.9781611977912.128},
}
Figure