Download PDFOpen PDF in browserCycle Detection for Affine Integer Linear Loops9 pages•Published: October 24, 2026AbstractWe study the cycle-detection problem for affine single-path linear-constrained loops over the integers. A cycle is a finite execution that returns to its initial state. Cycle detection is a natural relaxation of termination: every cycle witnesses non-termination, while an infinite execution need not contain a cycle.We prove that cycle detection for affine integer loops belongs to Σ^P_2. The proof relies on the algebraic structure of periodic vectors of the update matrix. Using the cyclotomic factors of its characteristic polynomial, we obtain a polynomial representation of the periodic subspace and of exponentially distant states along a periodic orbit. We then apply a small-integer-solution theorem to show that, whenever a cyclic state exists, one exists with polynomial bit-length. Consequently, cycle existence can be expressed by existentially guessing such a state and universally quantifying over a polynomial-size binary encoding of a position in its orbit, with the resulting predicate decidable in polynomial time. In: Stephan Schulz, Konstantin Korovin and Michael Rawson (editors). Proceedings of 16th International Workshop on the Implementation on Logics. Proceedings of the 26th Conference on Logic for Programming, Artificial Intelligence, and Reasoning (short papers), vol 23, pages 1-9.
|

