Finite Boolean relation programs #
This formalizes the six positive equation forms on bit-vector addresses from Section 4.1
of Balasubramanian and Majumdar. The ground facts form a
finite space. The least closed set is obtained by iterating the consequence operator from the
empty set for at most r * 2 ^ H steps. This module gives a semantics and a finite decision
procedure. The construction here does not include the paper's pushdown simulation.
Main definitions #
Equation: the six positive forms of a relation equation.Program: one equation per predicate.Fact: a predicate applied to a bit-vector address.Fact.equivFin: the numbering of ground facts by predicate and address.consequence: the monotone consequence operator on sets of facts.next: one executable round of the program.evaluate: the decision procedure for derivability.
Main results #
derives_fixed: the derivable facts are a fixed point.derives_iff_all_closed: derivability is membership in every closed set.lfp_consequence: the derivable facts form the least fixed point.derives_iff_stage_card: at most one iteration per ground fact suffices.evaluate_eq_true_iff: the executable iteration decides derivability.
References #
- A. R. Balasubramanian, R. Majumdar, Pushdown Reachability Requires N² Time on Multitape Turing Machines, arXiv:2611.27814v2, Section 4.1.
The six positive equation forms in Balasubramanian and Majumdar's relation programs. Assignment modifies the queried address, not the program.
- top {r H : ℕ} : Equation r H
- bot {r H : ℕ} : Equation r H
- test {r H : ℕ} (position : Fin H) (value : Bool) : Equation r H
- disj {r H : ℕ} (left right : Fin r) : Equation r H
- conj {r H : ℕ} (left right : Fin r) : Equation r H
- write {r H : ℕ} (source : Fin r) (position : Fin H) (value : Bool) : Equation r H
@[reducible, inline]
One positive equation for each predicate.
@[instance_reducible]
@[instance_reducible]
Enumerate all ground facts in predicate and address order.
The least fixed point of the consequence operator is the set of derivable facts.