# Presburger arithmetic

Presburger arithmetic is the first-order theory of the natural numbers with addition, named in honor of Mojżesz Presburger, who introduced it in 1929. The signature of Presburger arithmetic contains only the addition operation and equality, omitting the multiplication operation entirely. The axioms include a schema of induction.

Presburger arithmetic is much weaker than Peano arithmetic, which includes both addition and multiplication operations. Unlike Peano arithmetic, Presburger arithmetic is a decidable theory. This means it is possible to algorithmically determine, for any sentence in the language of Presburger arithmetic, whether that sentence is provable from the axioms of Presburger arithmetic. The asymptotic running-time computational complexity of this decision problem is doubly exponential, however, as shown by Fischer & Rabin (1974).

## Overview

The language of Presburger arithmetic contains constants 0 and 1 and a binary function +, interpreted as addition. In this language, the axioms of Presburger arithmetic are the universal closures of the following:

1. ¬(0 = x + 1)
2. x + 1 = y + 1 → x = y
3. x + 0 = x
4. x + (y + 1) = (x + y) + 1
5. Let P(x) be a first-order formula in the language of Presburger arithmetic with a free variable x (and possibly other free variables). Then the following formula is an axiom:
(P(0) ∧ ∀x(P(x) → P(x + 1))) → ∀y P(y).

(5) is an axiom schema of induction, representing infinitely many axioms. Since the axioms in the schema in (5) cannot be replaced by any finite number of axioms, Presburger arithmetic is not finitely axiomatizable in first-order logic.

Presburger arithmetic cannot formalize concepts such as divisibility or prime number. Generally, any number concept leading to multiplication cannot be defined in Presburger arithmetic, since that leads to incompleteness and undecidability. However, it can formulate individual instances of divisibility; for example, it proves "for all x, there exists y : (y + y = x) ∨ (y + y + 1 = x)". This states that every number is either even or odd.

## Properties

Mojżesz Presburger proved Presburger arithmetic to be:

• consistent: There is no statement in Presburger arithmetic which can be deduced from the axioms such that its negation can also be deduced.
• complete: For each statement in the language of Presburger arithmetic, either it is possible to deduce it from the axioms or it is possible to deduce its negation.
• decidable: There exists an algorithm which decides whether any given statement in Presburger arithmetic is a theorem or a nontheorem.

The decidability of Presburger arithmetic can be shown using quantifier elimination, supplemented by reasoning about arithmetical congruence (Enderton 2001, p. 188).

Peano arithmetic, which is Presburger arithmetic augmented with multiplication, is not decidable, as a consequence of the negative answer to the Entscheidungsproblem. By Gödel's incompleteness theorem, Peano arithmetic is incomplete and its consistency is not internally provable (but see Gentzen's consistency proof).

The decision problem for Presburger arithmetic is an interesting example in computational complexity theory and computation. Let n be the length of a statement in Presburger arithmetic. Then Fischer and Rabin (1974) proved that any decision algorithm for Presburger arithmetic has a worst-case runtime of at least ${\displaystyle 2^{2^{cn}}}$, for some constant c>0. Hence, the decision problem for Presburger arithmetic is an example of a decision problem that has been proved to require more than exponential run time. Fischer and Rabin also proved that for any reasonable axiomatization (defined precisely in their paper), there exist theorems of length n which have doubly exponential length proofs. Intuitively, this means there are computational limits on what can be proven by computer programs. Fischer and Rabin's work also implies that Presburger arithmetic can be used to define formulas which correctly calculate any algorithm as long as the inputs are less than relatively large bounds. The bounds can be increased, but only by using new formulas. On the other hand, a triply exponential upper bound on a decision procedure for Presburger Arithmetic was proved by Oppen (1978). A more tight complexity bound was shown using alternating complexity classes by Berman (1980).

## Applications

Because Presburger arithmetic is decidable, automatic theorem provers for Presburger arithmetic exist. For example, the Coq proof assistant system features the tactic omega for Presburger arithmetic and the Isabelle proof assistant contains a verified quantifier elimination procedure by Nipkow (2010). The double exponential complexity of the theory makes it infeasible to use the theorem provers on complicated formulas, but this behavior occurs only in the presence of nested quantifiers: Oppen and Nelson (1980) describe an automatic theorem prover which uses the simplex algorithm on an extended Presburger arithmetic without nested quantifiers to prove some of the instances of quantifier-free Presburger arithmetic formulas. More recent Satisfiability Modulo Theories solvers use complete integer programming techniques to handle quantifier-free fragment of Presburger arithmetic theory (King, Barrett, Tinelli 2014).

Presburger arithmetic can be extended to include multiplication by constants, since multiplication is repeated addition. Most array subscript calculations then fall within the region of decidable problems. This approach is the basis of at least five proof-of-correctness systems for computer programs, beginning with the Stanford Pascal Verifier in the late 1970s and continuing through to Microsoft's Spec# system of 2005.

## Presburger-definable integer relation

Some properties are now given about integer relations definable in Presburger Arithmetic. For the sake of simplicity, all relations considered in this sections are over natural integers.

A relation is Presburger-definable if and only if it is a semilinear set.[1]

A unary integer relation ${\displaystyle R}$, that is, a set of natural integers, is Presburger-definable if and only if it is ultimately periodic. That is, if there exists a threshold ${\displaystyle t\in \mathbb {N} }$ and a positive period ${\displaystyle p\in \mathbb {N} ^{>0}}$ such that, for all integer ${\displaystyle n}$ such that ${\displaystyle |n|\geq t}$, ${\displaystyle n\in R}$ if and only if ${\displaystyle n+p\in R}$.

By the Cobham–Semenov theorem, a relation is Presburger-definable if and only if it is definable in Büchi arithmetic of base ${\displaystyle k}$ for all ${\displaystyle k\geq 2}$.[2][3] A relation definable in Büchi aritmetic of base ${\displaystyle k}$ and ${\displaystyle k'}$ for ${\displaystyle k}$ and ${\displaystyle k'}$ being multiplicatively independent integers is Presburger definable.

An integer relation ${\displaystyle R}$ is Presburger-definable if and only if all sets of integers which are definable in first order logic with addition and ${\displaystyle R}$ (that is, Presburger Arithmetic plus a predicate for ${\displaystyle R}$) are Presburger-definable.[4] Equivalently, for each relation ${\displaystyle R}$ which is not Presburger-definable, there exists a first-order formula with addition and ${\displaystyle R}$ which defines a set of integer which is not definable using only addition.

### Muchnik's characterization

Presburger-definable relations admit another characterization: by Muchnik's theorem.[5] It is more complicated to state, but led to the proof of the two former characterizations. Before Muchnik's theorem can be stated, some additional definitions must be introduced.

Let ${\displaystyle R\subseteq \mathbb {N} ^{d}}$ be a set, the section ${\displaystyle x_{i}=j}$ of ${\displaystyle R}$, for ${\displaystyle i and ${\displaystyle j\in \mathbb {N} }$ is defined as

${\displaystyle \left\{(x_{0},\ldots ,x_{i-1},x_{i+1},\ldots ,x_{d-1})\in \mathbb {N} ^{d-1}\mid (x_{0},\ldots ,x_{i-1},j,x_{i+1},\ldots ,x_{d-1})\in R\right\}.}$

Given two sets ${\displaystyle R,S\subseteq \mathbb {N} ^{d}}$ and a ${\displaystyle d}$-tuple of integers ${\displaystyle (p_{0},\ldots ,p_{d-1})\in \mathbb {N} ^{d}}$, the set ${\displaystyle R}$ is called ${\displaystyle (p_{0},\dots ,p_{d-1})}$-periodic in ${\displaystyle S}$ if, for all ${\displaystyle (x_{0},\ldots ,x_{d-1})\in S}$ such that ${\displaystyle (x_{0}+p_{0},\dots ,x_{d-1}+p_{d-1})\in S,}$ then ${\displaystyle (x_{0},\ldots ,x_{d-1})\in R}$ if and only if ${\displaystyle (x_{0}+p_{0},\dots ,x_{d-1}+p_{d-1})\in R}$. For ${\displaystyle s\in \mathbb {N} }$, the set ${\displaystyle R}$ is said to be ${\displaystyle s}$-periodic in ${\displaystyle S}$ if it is ${\displaystyle (p_{0},\ldots ,p_{d-1})}$-periodic for some ${\displaystyle (p_{0},\dots ,p_{d-1})\in \mathbb {Z} ^{d}}$ such that

${\displaystyle \sum _{i=0}^{d-1}|p_{i}|

Finally, for ${\displaystyle k,x_{0},\dots ,x_{d-1}\in \mathbb {N} }$ let

${\displaystyle C(k,(x_{0},\ldots ,x_{d-1}))=\left\{(x_{0}+c_{0},\dots ,x_{d-1}+c_{d-1})\mid 0\leqslant c_{i}

denote the cube of size ${\displaystyle k}$ whose lesser corner is ${\displaystyle (x_{0},\dots ,x_{d-1})}$.

Muchnik's Theorem. ${\displaystyle R\subseteq \mathbb {N} ^{d}}$ is Presburger-definable if and only if:
• if ${\displaystyle d>1}$ then all sections of ${\displaystyle R}$ are Presburger-definable and
• there exists ${\displaystyle s\in \mathbb {N} }$ such that, for every ${\displaystyle k\in \mathbb {N} }$, there exists ${\displaystyle t\in \mathbb {N} }$ such that for all ${\displaystyle (x_{0},\dots ,x_{d-1})\in \mathbb {N} ^{d}}$ with
${\displaystyle \sum _{i=0}^{d-1}x_{i}>t,}$
${\displaystyle R}$ is ${\displaystyle s}$-periodic in ${\displaystyle C(k,(x_{0},\dots ,x_{d-1}))}$.

Intuitively, the integer ${\displaystyle s}$ represents the length of a shift, the integer ${\displaystyle k}$ is the size of the cubes and ${\displaystyle t}$ is the threshold before the periodicity. This result remains true when the condition

${\displaystyle \sum _{i=0}^{d-1}x_{i}>t}$

is replaced either by ${\displaystyle \min(x_{0},\ldots ,x_{d-1})>t}$ or by ${\displaystyle \max(x_{0},\ldots ,x_{d-1})>t}$.

This characterization led to the so-called "definable criterion for definability in Presburger arithmetic", that is: there exists a first-order formula with addition and a ${\displaystyle d}$-ary predicate ${\displaystyle R}$ which holds if and only if ${\displaystyle R}$ is interpreted by a Presburger-definable relation. Muchnik's theorem also allows one to prove that it is decidable whether an automatic sequence accepts a Presburger-definable set.