This is an old revision of the document!
Deciding Boolean Algebra with Presburger Arithmetic
Motivation
Definition of BAPA
See Figure 3 on page 5 of the paper and compare to its special cases: BA and PA.
\[ \begin{array}{rcl}
F & ::= & A \mid F_1 \land F_2 \mid F_1 \lor F_2 \mid \lnot F \mid \exists x.F \mid \forall x.F \mid \exists k.F \mid \forall k.F \\ A & ::= & B_1 = B_2 \mid B_1 \subseteq B_2 \mid T_1 = T_2 \mid T_1 < T_2 \mid (K{|}T) \\ B & ::= & x \mid \mathbf{0} \mid \mathbf{1} \mid B_1 \cup B_2 \mid B_1 \cap B_2 \mid B^{c} \\ T & ::= & k \mid K \mid maxc \mid T_1 + T_2 \mid K \cdot T \mid \ \q{|} B \q{|} \\ K & ::= & \ldots {-2} \mid -1 \mid 0 \mid 1 \mid 2 \ldots \end{array}
\]
Semantics: we consider the theory of models where integers are interpreted as integers and sets are interpreted as subsets of some finite set. For each finite set we have one interpretation. (If we prove a valid formula, it will hold for arbitrarily large finite universes.) are empty and universal set. We interpret constant as .
Example
Eliminate the quantifier from the following formula: \[ \exists X. A \subseteq X \land X \cup B = B \land |X \cap A| = 2 |A| + 1 \]
Simplifying Atomic Formulas
For sets :
becomes
becomes
Result: all set variables and operators occur within formula where is expression built from set variables, .
Transform into union of disjoint Venn regions. Let be all set variables. Venn regions are connected regions in the Venn diagram, and are analogous to conjunctive normal form: \[
\bigcup_{i=1}^m x_i^{\alpha_i}
\] where is either or (complement of ).
Now observe that each set expression is a disjoint union of certain Venn regions. It is union of precisely those regions that belong to disjunctive normal form of the corresponding propositional formula.
Then use \[
|b| = |s_{i_1}| + \ldots + |s_{i_k}|
\] We therefore assume that the only occurence of sets and set operators is within where is a Venn region.
Separating BA and PA Part
Transform formula to prenex form \[
Q_p v_p. \dots Q_1 v_1. G_1(|s_1|,\ldots,|s_n|)
\] where is quantifier-free.
For each expression in introduce a fresh variable that denotes the value . We obtain \[
Q_p v_p. \dots Q_1 v_1. \exists^+ l_1.\ldots \exists l_q. \left(\bigwedge_{i=1}^q |s_i|=l_i \right)\ \land\ G_1(l_1,\ldots,l_q)
\] Note that is a quantifier-free PA formula.
Here denotes .
We will eliminate integer and set quantifiers from the entire subformula \[ \exists^+ l_1.\ldots \exists l_q. \left(\bigwedge_{i=1}^q |s_i|=l_i \right)\ \land\ G_1(l_1,\ldots,l_q) \] Indeed, we can always transform this formula to a quantifier-free formula by substituting back into .
In which parts of this formula do we find variables that we wish to eliminate
Eliminating Quantifiers
Eliminating Integer Existential
Eliminating Set Existential
Lemma: Let be two finite disjoint sets and non-negative integers. Then the following two conditions are equivalent:
- there exists a finite set such that: , , , and ;
- and .
Eliminating Universals
Express them using negation and existentials.