The satisfiability coding lemma -- proofs #
Internal proofs for Complexitylib.Circuits.KCNF.Coding.
On a solution x of ψ, the decoder for the order σ recovers x from every input y that
agrees with x off the forced variables (decode_eq_of_agree). So the sets of such inputs are
disjoint for distinct solutions, and the sum of 2 ^ |forced σ x| over the solutions is at most
2 ^ N. Averaging over all orders and applying Jensen's inequality to t ↦ 2 ^ t gives the
bound with the average number of forced variables in the exponent.
For a clause set of width k, every isolated direction i of a solution x has a clause whose
only true literal under x is on i; then i is forced whenever σ places i after the other
variables of that clause, which happens for at least a 1/k fraction of the orders
(card_lastIn_mul_card).
In a satisfied clause whose other literals are false, the remaining literal is true.
One decoding step: on a partial assignment that agrees with the solution x before v, and
with an input bit that is x v unless v is forced, the decoder gives v its value in x.
The decoder invariant. After p positions, the decoder holds the solution's values at
the positions before p and the input's values elsewhere.
Decoding. On every input that agrees with a solution x off its forced variables, the
decoder outputs x.
The coding bound, averaged over all orders. With the average number of forced variables
in the exponent, the sum over the solutions is at most 2 ^ N (Jensen's inequality).
Isolated directions are forced often #
The orders that place j after every other element of V.
Equations
- Complexity.ClauseSet.Coding.lastIn V j = {σ : Equiv.Perm (Fin N) | ∀ u ∈ V, u ≠ j → σ u < σ j}
Instances For
An isolated direction of a solution has a critical clause: a clause whose only true literal
under x is a literal on that direction.
Isolated directions are forced on average. For a clause set of width at most k, the
number of isolated directions of a solution times N! is at most k times the total number of
forced variables over all orders.
The coding lemma for k-CNFs. For a clause set of width at most k ≥ 1, the sum over
its solutions of 2 ^ (ι(x)/k), ι(x) the number of isolated directions, is at most 2 ^ N.