Encodings of clauses and CNF formulas #
A machine reads a formula in conjunctive normal form through an encoding enc : V ↪ List Bool
of its variables. A literal (v, b) is the framed enc v followed by its polarity bit b
(encPair enc encBool); a clause is the concatenation of its framed literals
(Cslib.Logic.PL.encClause), and a formula the concatenation of its framed clauses
(Cslib.Logic.PL.encCNFOver). Both are reducible abbreviations, so fun_prop and the
combinators' lemmas see through the names. omega does not, since it compares atoms
syntactically: state the bounds it combines with the same spelling.
Cslib.Complexity.encCNF, the encoding of the instances of SAT, is definitionally
encCNFOver encNat: variables numbered by natural numbers written in binary.
Main definitions #
Cslib.Logic.PL.encClause: clauses over an encoding of the variables.Cslib.Logic.PL.encCNFOver: formulas over an encoding of the variables.