Documentation

CslibFrontier.Computability.PCP.Approximation.AssignmentConsistency

Consistency of finite partial Boolean assignments #

A partial assignment is represented as a list of variable indices and their Boolean values. Cslib.Complexity.SAT.consistentLits checks whether two such lists agree wherever they both assign a value. Testing a list against itself detects conflicting repetitions. The check is polynomial-time with binary indices.

Two partial assignments, given as lists of literals (x, b) read as x := b, are consistent when they give no variable two different values.

theorem Cslib.Complexity.SAT.consistentLits_eq_true_iff {ρ ρ' : List (ℕ × Bool)} :
consistentLits ρ ρ' = true ↔ ∀ l ∈ ρ, ∀ l' ∈ ρ', l.1 = l'.1 → l.2 = l'.2

The checker succeeds exactly when shared variables have the same value.