Parity systems and bounded-width derivations #
A parity system P : ParitySystem ฯ is a finite list of equations โ_{i โ S} xแตข = b over
๐ฝโ, each given by its set S of variables and its right-hand side b. An assignment
a : ฯ โ Bool satisfies P (ParitySystem.Holds) when parityOn S a = b for every equation.
Variables are sets rather than lists, unlike Cslib.Logic.PL.AffineEquation: the algebraic
encodings over ยฑ1 variables (Cslib.Logic.PL.ParitySystem.toPolys) are multilinear in the
variables of an equation.
Summing two equations gives the equation of the symmetric difference of their sets and the
exclusive or of their right-hand sides. Width-w derivations (ParitySystem.Derives P w)
start from 0 = 0 and the equations of P with at most w variables, and close under this rule
as long as the result has at most w variables. This is width-w resolution on XOR formulas,
Schoenebeck, Definition 10, except that the equations of P used must also have
width at most w; restricting the axioms derives fewer equations, so the hypothesis "width-w
derivations do not reach 0 = 1" is weaker here than in the source. Every derived equation holds
under every satisfying assignment (ParitySystem.Holds.parityOn_eq_of_derives), so a system from
which 0 = 1 is derivable is unsatisfiable. Tseitin parity systems are in
CslibFrontier.Logics.Propositional.ParitySystem.Tseitin.
Main definitions #
Cslib.Logic.PL.ParityEquation: a parity equation, with fieldsvarsandrhs.Cslib.Logic.PL.ParitySystem: systems of parity equations.Cslib.Logic.PL.ParitySystem.Holds: satisfaction by an assignment.Cslib.Logic.PL.ParitySystem.Derives: width-wderivations.
Main results #
Cslib.Logic.PL.ParitySystem.Holds.parityOn_eq_of_derives: soundness of derivations.Cslib.Logic.PL.ParitySystem.not_holds_of_derives_empty_true: a system from which0 = 1is derivable is unsatisfiable.
References #
A parity system: a list of parity equations.
The assignment a satisfies every equation of P: the parity of a on the variables of an
equation is its right-hand side.
Width-w derivations from a parity system P: Derives P w S b says that the equation
โ_{i โ S} xแตข = b is obtained from 0 = 0 and the equations of P with at most w variables by
summing two derived equations, every derived equation having at most w variables. Deriving
0 = 1 is Derives P w โ
true.
- empty {ฯ : Type u_1} [DecidableEq ฯ] {P : ParitySystem ฯ} {w : โ} : P.Derives w โ
false
The trivial equation
0 = 0. - mem {ฯ : Type u_1} [DecidableEq ฯ] {P : ParitySystem ฯ} {w : โ} {S : Finset ฯ} {b : Bool} : { vars := S, rhs := b } โ P โ S.card โค w โ P.Derives w S b
An equation of
Pwith at mostwvariables. - symmDiff {ฯ : Type u_1} [DecidableEq ฯ] {P : ParitySystem ฯ} {w : โ} {S T : Finset ฯ} {b c : Bool} : P.Derives w S b โ P.Derives w T c โ (_root_.symmDiff S T).card โค w โ P.Derives w (_root_.symmDiff S T) (b ^^ c)
The sum of two derived equations, if it has at most
wvariables.
A derived equation has at most w variables.
Width-w derivations are width-w' derivations for w โค w'.
Soundness of derivations: every derived equation holds under every assignment satisfying the system.
A system from which 0 = 1 is derivable is unsatisfiable.