Problem instances, output encoding, and output register for Word-RAM 2-SAT #
Defines Instance together with Instance.totalLits, Instance.encode, Instance.outAddrBase,
Instance.wordBound, and Instance.encode_length, as well as encodeAssignment, answerWords,
decodeAnswer, and Reg.outBase.
A CNF (Fin n) instance for the word-RAM 2-SAT solver.
- n : ℕ
Number of Boolean variables.
Total literal occurrences across all clauses of G.φ.
Word-list encoding [n, |φ|] ++ φ.flatMap (encodeClauseBy Fin.val).
Output header address G.encode.length + 1, immediately past the input in State.init.
Linear word-size envelope covering input length, literal codes, and scratch memory addresses.
Canonical word-list output of the 2-SAT solver on G.
@[reducible, inline]
Output-list header register (G.outAddrBase).