OAI/Computability/MaxCut/Machines/MachineOverlayRows.lean

GitHub source file

35 declarations, 0 contain sorry, 0 declared as axioms

The fixed-degree vertex loop has one finite label block per port, plus one terminal boundary. The stored row values do not occur in its program.

  1. abbrev OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.State line 15
  2. inductive OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.Label line 17
  3. def OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.bodyIndex line 24

    Source documentation

    The row body's nine tapes retain their numbering; tape 9 is the stream.

    def bodyIndex (i : Fin 9) : Fin 10 := i.castSucc
  4. theorem OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.bodyIndex_injective line 26
  5. def OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.trueBits line 30
  6. def OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.instruction line 32
  7. def OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.rowBits line 47
  8. def OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.rowSteps line 50
  9. def OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.resultTapes line 54
  10. theorem OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.joinTrace_inline_MachineOverlayRows line 59
  11. theorem OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.rowTrace line 65

    Source documentation

    Load the actual next expander index, execute the arithmetic and complete 4096-bit row emitter, then clear the three isolated temporary fields.

    theorem rowTrace (d e : Nat) (positive : 0 < e) (tape : Fin 10 → K)
        (distinct : Function.Injective tape) (labels : Label e → Λ) (exit : Option Λ)
        (program : Λ → TM2.Stmt (fun _ : K => Bool) Λ (State A e))
        (atLabels : ∀ l, program (labels l) = instruction d e positive tape labels exit l)
        (base : K → List Bool) (v j : Nat) (suffix : List Bool)
        (tailWord : base (tape 0) = encodeWord v)
        (inputWord : base (tape 9) = encodeWord j ++ suffix)
        (empty : ∀ i : Fin 10, i ≠ 0 → i ≠ 7 → i ≠ 9 → base (tape i) = [])
        (ambient : A) :
        (advance (TM2.step program))^[rowSteps d e v j (base (tape 7))]
          (some ⟨some (labels .loadStart), MachinePortReindex.clean e positive ambient, base⟩) =
          some ⟨exit, MachinePortReindex.clean e positive ambient,
    …

    Mentions: OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.Label, OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.State, OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.instruction, OAI.MaxCutGames.Foundations.Complexity.encodeWord, OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.rowSteps, OAI.MaxCutGames.Foundations.Complexity.MachinePortReindex.clean

  12. theorem OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.rowBits_eq_expanderRow line 207
  13. def OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.machine line 220
  14. abbrev OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.VertexLabel line 234
  15. def OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.vertexInstruction line 236
  16. def OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.streamFrame line 246
  17. def OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.streamOutput line 251
  18. def OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.vertexSteps line 254
  19. def OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.valueBound line 259
  20. def OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.rowSizeBound line 260
  21. def OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.rowCostBound line 261
  22. theorem OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.value_le line 264
  23. theorem OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.rowBits_length line 272
  24. theorem OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.rowBits_length_le line 278
  25. theorem OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.rowSteps_le line 285
  26. theorem OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.vertexSteps_le_capacity_inline_MachineOverlayRows line 295
  27. theorem OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.vertexSteps_le line 322

    Source documentation

    Explicit polynomial budget for the finite port loop, including repeated output append costs and all real loader and cleanup transitions.

    theorem vertexSteps_le (d e v B : Nat) (words : List Nat)
        (bounded : ∀ j ∈ words, j ≤ B) (output : List Bool) :
        vertexSteps d e v words output ≤
          words.length * (rowCostBound d e v B +
            2 * (output.length + words.length * rowSizeBound d e v B) + 1) + 1 :=
    …

    Mentions: OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.vertexSteps, OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.rowCostBound, OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.rowSizeBound

  28. theorem OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.streamFrame_afterRow_inline_MachineOverlayRows line 329
  29. theorem OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.vertexSuffixTrace line 347

    Source documentation

    A suffix of the actual fixed-degree port loop. Each row execution is derived from rowTrace; no row-execution premise is accepted.

    theorem vertexSuffixTrace (d e : Nat) (positive : 0 < e) (tape : Fin 10 → K)
        (distinct : Function.Injective tape) (labels : VertexLabel e → Λ) (exit : Option Λ)
        (program : Λ → TM2.Stmt (fun _ : K => Bool) Λ (State A e))
        (atLabels : ∀ l, program (labels l) = vertexInstruction d e positive tape labels exit l)
        (base : K → List Bool) (v : Nat) (values : Fin e → Nat)
        (tailWord : base (tape 0) = encodeWord v)
        (empty : ∀ i : Fin 10, i ≠ 0 → i ≠ 7 → i ≠ 9 → base (tape i) = [])
        (ambient : A) (remaining : Nat) (i : Fin (e + 1)) (count : i.val + remaining = e)
        (output : List Bool) :
        (advance (TM2.step program))^[vertexSteps d e v ((List.ofFn values).drop i.val) output]
          (some ⟨some (labels (i, none)), MachinePortReindex.clean e positive ambient,
            streamFrame tape base ((List.ofFn values).drop i.val) output⟩) =
    …

    Mentions: OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.VertexLabel, OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.State, OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.vertexInstruction, OAI.MaxCutGames.Foundations.Complexity.encodeWord, OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.vertexSteps, OAI.MaxCutGames.Foundations.Complexity.MachinePortReindex.clean, OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.streamFrame

  30. theorem OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.vertexTrace line 421
  31. def OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.vertexInTime line 437
  32. theorem OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.encodeWords_flatMap_inline_MachineOverlayRows line 459
  33. theorem OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.streamOutput_expanderRows line 465
  34. theorem OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.expanderValues_bounded line 477
  35. def OAI.MaxCutGames.Foundations.Complexity.MachineOverlayRows.vertexMachine line 482