OAI/Computability/MaxCut/Machines/MachineFieldTemplate.lean
35 declarations, 0 contain sorry, 0 declared as axioms
- inductive
OAI.MaxCutGames.Reduction.MachineFieldTemplate.Tokenline 14 - def
OAI.MaxCutGames.Reduction.MachineFieldTemplate.tokenOutputline 19 - def
OAI.MaxCutGames.Reduction.MachineFieldTemplate.templateOutputline 23 - def
OAI.MaxCutGames.Reduction.MachineFieldTemplate.tokenStepsline 26 - def
OAI.MaxCutGames.Reduction.MachineFieldTemplate.workStepsline 30 - def
OAI.MaxCutGames.Reduction.MachineFieldTemplate.templateStepsline 33 - def
OAI.MaxCutGames.Reduction.MachineFieldTemplate.copiedLengthline 36 - inductive
OAI.MaxCutGames.Reduction.MachineFieldTemplate.Labelline 39 - abbrev
OAI.MaxCutGames.Reduction.MachineFieldTemplate.Stateline 47 - abbrev
OAI.MaxCutGames.Reduction.MachineFieldTemplate.Alphabetline 48 - def
OAI.MaxCutGames.Reduction.MachineFieldTemplate.resetline 50 - theorem
OAI.MaxCutGames.Reduction.MachineFieldTemplate.reset_resetline 52 - def
OAI.MaxCutGames.Reduction.MachineFieldTemplate.startAtline 54 - def
OAI.MaxCutGames.Reduction.MachineFieldTemplate.jumpline 57 - def
OAI.MaxCutGames.Reduction.MachineFieldTemplate.identityEmitline 62 - def
OAI.MaxCutGames.Reduction.MachineFieldTemplate.instructionline 66Source documentation
Local finite labels are placed in an arbitrary caller label space, with an explicit continuation. Every instruction is determined by the fixed template.
def instruction (tokens : List (Token q)) (field : Fin q → K) (scratch output : K) (place : Label tokens.length → Λ) (exit : Option Λ) : Label tokens.length → TM2.Stmt (Alphabet (K := K)) Λ (State σ) …Mentions: OAI.MaxCutGames.Reduction.MachineFieldTemplate.Token, OAI.MaxCutGames.Reduction.MachineFieldTemplate.Label, OAI.MaxCutGames.Reduction.MachineFieldTemplate.Alphabet, OAI.MaxCutGames.Reduction.MachineFieldTemplate.State
- def
OAI.MaxCutGames.Reduction.MachineFieldTemplate.programline 86Source documentation
A standalone local program, also usable with a local continuation.
def program (tokens : List (Token q)) (field : Fin q → K) (scratch output : K) (exit : Option (Label tokens.length)) : Label tokens.length → TM2.Stmt (Alphabet (K := K)) (Label tokens.length) (State σ) := …Mentions: OAI.MaxCutGames.Reduction.MachineFieldTemplate.Token, OAI.MaxCutGames.Reduction.MachineFieldTemplate.Label, OAI.MaxCutGames.Reduction.MachineFieldTemplate.Alphabet, OAI.MaxCutGames.Reduction.MachineFieldTemplate.State
- def
OAI.MaxCutGames.Reduction.MachineFieldTemplate.outputTapesline 93 - theorem
OAI.MaxCutGames.Reduction.MachineFieldTemplate.outputTapes_selfline 96 - theorem
OAI.MaxCutGames.Reduction.MachineFieldTemplate.outputTapes_outputline 99 - theorem
OAI.MaxCutGames.Reduction.MachineFieldTemplate.outputTapes_otherline 102 - theorem
OAI.MaxCutGames.Reduction.MachineFieldTemplate.outputTapes_appendline 106 - theorem
OAI.MaxCutGames.Reduction.MachineFieldTemplate.fieldValues_outputTapesline 111 - theorem
OAI.MaxCutGames.Reduction.MachineFieldTemplate.identity_outputline 117 - theorem
OAI.MaxCutGames.Reduction.MachineFieldTemplate.chain_inline_MachineFieldTemplateline 123 - theorem
OAI.MaxCutGames.Reduction.MachineFieldTemplate.doneStepline 139 - theorem
OAI.MaxCutGames.Reduction.MachineFieldTemplate.literalStepline 146 - theorem
OAI.MaxCutGames.Reduction.MachineFieldTemplate.copySetupStepline 157 - theorem
OAI.MaxCutGames.Reduction.MachineFieldTemplate.copyTraceline 167 - theorem
OAI.MaxCutGames.Reduction.MachineFieldTemplate.tokenTraceline 190 - theorem
OAI.MaxCutGames.Reduction.MachineFieldTemplate.suffixTrace_inline_MachineFieldTemplateline 207 - theorem
OAI.MaxCutGames.Reduction.MachineFieldTemplate.phaseTraceline 253Source documentation
The complete phase is derived from concrete instruction traces. The code placement premise identifies instructions; it assumes no whole-phase run.
theorem phaseTrace (base : K → List Bool) (scratchEmpty : base scratch = []) (state : State σ) : (MachineComposition.advance (TM2.step P))^[templateSteps tokens (fun j => base (field j))] (some ⟨some (place (startAt tokens.length 0)), state, base⟩) = some ⟨exit, reset state, outputTapes base output (templateOutput tokens (fun j => base (field j)))⟩ := by …Mentions: OAI.MaxCutGames.Reduction.MachineFieldTemplate.State, OAI.MaxCutGames.Reduction.MachineFieldTemplate.templateSteps, OAI.MaxCutGames.Reduction.MachineFieldTemplate.startAt, OAI.MaxCutGames.Reduction.MachineFieldTemplate.reset, OAI.MaxCutGames.Reduction.MachineFieldTemplate.outputTapes, OAI.MaxCutGames.Reduction.MachineFieldTemplate.templateOutput
- theorem
OAI.MaxCutGames.Reduction.MachineFieldTemplate.programTraceline 267Source documentation
Direct execution of the emitted local finite program; its instructions are discharged by construction rather than supplied by the caller.
theorem programTrace (tokens : List (Token q)) (field : Fin q → K) (scratch output : K) (fieldScratch : ∀ j, field j ≠ scratch) (fieldOutput : ∀ j, field j ≠ output) (scratchOutput : scratch ≠ output) (exit : Option (Label tokens.length)) (base : K → List Bool) (scratchEmpty : base scratch = []) (state : State σ) : (MachineComposition.advance (TM2.step (program tokens field scratch output exit)))^[ templateSteps tokens (fun j => base (field j))] (some ⟨some (startAt tokens.length 0), state, base⟩) = some ⟨exit, reset state, outputTapes base output (templateOutput tokens (fun j => base (field j)))⟩ := …Mentions: OAI.MaxCutGames.Reduction.MachineFieldTemplate.Token, OAI.MaxCutGames.Reduction.MachineFieldTemplate.Label, OAI.MaxCutGames.Reduction.MachineFieldTemplate.State, OAI.MaxCutGames.Reduction.MachineFieldTemplate.program, OAI.MaxCutGames.Reduction.MachineFieldTemplate.templateSteps, OAI.MaxCutGames.Reduction.MachineFieldTemplate.startAt, OAI.MaxCutGames.Reduction.MachineFieldTemplate.reset, OAI.MaxCutGames.Reduction.MachineFieldTemplate.outputTapes, OAI.MaxCutGames.Reduction.MachineFieldTemplate.templateOutput
- theorem
OAI.MaxCutGames.Reduction.MachineFieldTemplate.templateSteps_leline 279 - def
OAI.MaxCutGames.Reduction.MachineFieldTemplate.phaseInTimeline 292