The clause-family emitters #
One emitting machine per tableauCNFFlat family handled here — the accept,
state/cell/head one-hot, and frame families — each with a Hoare specification
appending exactly that family's CNF.encode image. (The start and active
families are emitted in EmitterStart and EmitterActive.)
The emitter's tape layout is fixed once (Emit.nT = 20 work tapes, named
indices below), so register-distinctness side conditions are all decide.
Number of work tapes of the reduction emitter.
Equations
Instances For
Register holding radix A = steps + 1.
Equations
Instances For
Register holding radix B = max Qc 3.
Equations
Instances For
Register holding radix C = P + 2.
Equations
Instances For
Register holding radix D = 4.
Equations
Instances For
Numeral scratch register.
Equations
Instances For
Second numeral scratch register.
Equations
Instances For
Register holding the input length |x|.
Equations
Instances For
Register holding steps = p.eval |x|.
Equations
Instances For
Register holding P = steps + |x| + 1.
Equations
Instances For
Register holding the row counter t.
Equations
Instances For
Register holding the row-loop fuel.
Equations
Instances For
Register holding the successor row t + 1.
Equations
Instances For
Register holding the position counter (pos / pi).
Equations
Instances For
Register holding the position-loop fuel (P + 1).
Equations
Instances For
Register holding the second position counter (pos' / pw).
Equations
Instances For
Register holding the second position fuel (P + 1).
Equations
Instances For
Register holding the third position counter (po).
Equations
Instances For
Register holding the third position fuel (P + 1).
Equations
Instances For
Spare register.
Equations
Instances For
Second spare register.
Equations
Instances For
Pointwise Forall₂ between two maps of the same list.
Forall₂ is preserved by appending componentwise-related lists.
Descriptor mirror of atMostOne.
Equations
Instances For
Descriptor mirror of exactlyOne.
Equations
- Complexity.SAT.exactlyOneD mkPos mkNeg qs = List.map mkPos qs :: Complexity.SAT.atMostOneD mkNeg qs
Instances For
atMostOneD mk qs denotes atMostOne (qs.map f) clause-by-clause,
provided each descriptor mk q denotes the negative literal on f q.
exactlyOneD mkPos mkNeg qs denotes exactlyOne (qs.map f)
clause-by-clause, given the positive/negative literal denotations.
Clause sizes in atMostOneD are 2.
atMostOneD over m indices has at most m² clauses.
The accept-family emitter.
Equations
- One or more equations did not get rendered due to their size.
Instances For
emitAcceptTM Hoare specification: appends the encoded accept
clauses.
The state one-hot emitter: loop the leaf over all rows.
Equations
- One or more equations did not get rendered due to their size.
Instances For
emitOneHotStatesTM Hoare specification: appends the encoded
state one-hot family, leaving the row counter at steps + 1.
Position sweep at one tape index: loop the leaf over positions, then return the position counter to zero.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The oneHotCells row body: position sweeps at the three tape indices.
Equations
Instances For
The cell one-hot emitter: loop the row body over all rows.
Equations
Instances For
Budget of one position sweep.
Equations
Instances For
posChunkTM Hoare specification (at row i, tape index tp).
Budget of the oneHotCells row body.
Equations
Instances For
cellsBodyTM Hoare specification (at row i).
emitOneHotCellsTM Hoare specification: appends the encoded cell
one-hot family, leaving the row counter at steps + 1.
atMostOne over a mapped range as rectangle loops with shrinking inner
ranges — the shape the head emitter's nested loops produce.
One head literal: row from tReg, tape index hardwired, position from
posSrc.
Equations
- Complexity.SAT.headLitD sign tp posSrc = { sign := sign, tag := 3, sa := Sum.inl Complexity.SAT.Emit.tReg, sb := Sum.inr tp, sc := Sum.inl posSrc, sd := Sum.inr 0 }
Instances For
The at-least-one head clause: loop the positive literal over all positions, close the clause, return the position counter.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Budget of the at-least-one head clause.
Equations
- Complexity.SAT.headAtLeastBudget M = Complexity.SAT.loopBudget M (Complexity.TM.emitVarBudget M + 1 + (2 * Complexity.TM.opBudget M + 1)) + 1 + (2 + 1 + Complexity.TM.opBudget M)
Instances For
The head-literal denotation lemma, shared by both head clause shapes.
headAtLeastTM Hoare specification (at row i, tape index tp).
The pairwise at-most-one clauses: outer loop over the first position; per outer step, mirror the counter past it, sweep the (offset, shrinking) inner loop, and shrink the fuel.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The pairwise at-most-one head sweep: loop headPairBodyTM over the
outer position, then return the position counter to zero.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Budget of one outer step of the pairwise sweep.
Equations
Instances For
The per-outer-position word of the pairwise sweep.
Equations
- One or more equations did not get rendered due to their size.
Instances For
headPairBodyTM Hoare specification (at row i, outer position
q): emits the pair clauses (q, q') for all q' > q, mirrors the
counters home, and shrinks the fuel.
Budget of the pairwise at-most-one sweep.
Equations
Instances For
headAtMostTM Hoare specification (at row i, tape index tp):
appends the encoded pairwise at-most-one clauses, consuming the shrink
fuel (auxReg: P in, 0 out).
One (row, tape) head leaf: initialize the shrink fuel, then the
exactly-one block.
Equations
Instances For
Budget of one head leaf.
Equations
Instances For
headLeafTM Hoare specification (at row i, tape index tp).
The oneHotHeads row body: head leaves at the three tape indices.
Equations
Instances For
The head one-hot emitter: loop the row body over all rows.
Equations
Instances For
Budget of the oneHotHeads row body.
Equations
Instances For
headsBodyTM Hoare specification (at row i).
emitOneHotHeadsTM Hoare specification: appends the encoded head
one-hot family, leaving the row counter at steps + 1.
Forall₂ is preserved by flatMap with pointwise-related images.
The frame leaf at one (row, tape, position): both clauses for all four
symbols.
Equations
Instances For
Frame position sweep at one tape index.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The frame row body: bump the successor-row register, then sweep the three tapes.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The frame-family emitter: loop the row body over rows 0..steps-1.
Equations
Instances For
The frame leaf formula at one (row, tape, position).
Equations
- One or more equations did not get rendered due to their size.
Instances For
Budget of one frame position sweep.
Equations
Instances For
Budget of the frame row body.
Equations
Instances For
framePosChunkTM Hoare specification (at row i, tape tp; the
successor-row register holds i + 1).
frameRowTM Hoare specification (at row i < steps; the
successor-row register enters at i and leaves at i + 1).
emitFrameTM Hoare specification: appends the encoded frame family,
leaving row counter and successor-row register at steps.