XOR-SAT in polynomial time #
The input is an ordinary list of parity equations on natural-number variable labels, with
arbitrary repetitions and Boolean right-hand sides. Labels use the existing binary encNat,
equations use the existing pair encoding, and systems use the existing framed-list encoding.
No bound on the numerical value of a variable label is imposed.
The compiler lists the occurring labels without duplicates and computes each coefficient as the
parity of its occurrences. This gives a dense system of polynomial size, decided by the native
Gaussian-elimination algorithm in XORSAT.Dense. The semantics count repeated occurrences
modulo two. Both constant equations and the empty system are supported.
This implements the normalization and elimination argument after [Che06], Theorem 4.3, printed p. 16 (arXiv version 1). The separate affine normal-form theorem does not assert an efficient transformation of a variable truth table into equations: for fixed relation templates, the chosen equations are fixed independently of the input.
Main definitions #
Cslib.Complexity.XORSAT.encoding: lists of equations with binary variable labels.Cslib.Complexity.XORSAT.compile: compress labels and cancel repeated occurrences.Cslib.Complexity.XORSAT.solve: compile, then perform Gaussian elimination.Cslib.Complexity.XORSAT: the satisfiable systems.
Main results #
Cslib.Complexity.XORSAT.solve_eq_true_iff: correctness for ordinary parity systems.Cslib.Complexity.XORSAT.computableInPolyTime_solve: a native multi-tape polynomial-time certificate.Cslib.Complexity.XORSAT.mem_P: ordinary XOR-SAT is inP.
A conjunction of parity equations on arbitrarily large natural-number variable labels.
Instances For
A row is encoded by a framed list of binary labels and a Boolean right-hand side.
Instances For
The occurring variable labels, each retained once, in order of first occurrence.
Instances For
Compress occurring labels, keeping one Boolean coefficient for each label.
Instances For
Native dense Gaussian elimination after compression of binary variable labels.
Instances For
Ordinary satisfiability, with no restriction on the assignment away from occurring labels.
Instances For
There is one compressed coordinate per distinct occurring variable.
Compression allocates at most one column per variable occurrence in the input.
Every compiled row has exactly the declared width.
Compiled rows evaluate exactly as their sparse input equations, including repetitions.
The compiler preserves the satisfaction relation on every assignment.
Sparse satisfiability is equivalent to satisfiability of the compressed dense system.
The executable solver decides ordinary sparse systems with binary variable labels.
Label compression is itself a native polynomial-time computation. Binary labels are only compared, never expanded into a table indexed by their numerical value.
Ordinary XOR-SAT is decided in polynomial time by native multi-tape machines.
Ordinary XOR-SAT: the satisfiable systems of parity equations.