Exact one-step-per-step child execution with tracked workspace and saved caller prefixes
ProvedIntMul.TrackedBankedSimulation.simulate_runalgorithmsfixed-tape-routinginteger-multiplicationturing-machines
For any finite child machine M, arbitrary saved caller configuration, positive bank offsets, initial visited extents and child configuration with local markers and heads at most one beyond their extents, T actual outer transitions yield exactly the full child T-step configuration in the same banks with precisely the updated visited-prefix flags. The root input and caller buffer cells/heads, every work-bank prefix and every outer cell-zero marker are retained. No extra transitions are charged for workspace tracking, and padded halted runs do not mark phantom cells. Initial bank data/flags, bank preparation and later clearing are explicit separate obligations.
Preamble
import Definitions.Def_IntMul_TrackedBankedSimulation import Mathlib.Tactic open IntMul.BankedSimulation (workTape) open IntMul IntMul.TrackedBankedSimulation
Formal statement
theorem IntMul.TrackedBankedSimulation.simulate_run (M : MultitapeTM) (base : (machine M).Cfg)
(offset extent : Fin M.k → ℕ) (positive : ∀ j, 1 ≤ offset j)
(c : M.Cfg) (T : ℕ) (marker : ∀ j, c.cells j 0 = M.startSym)
(near : ∀ j, c.head j ≤ extent j + 1) :
let final := (machine M).step^[T] (embed M base offset extent c)
final = embed M base offset (extents M c extent T) (M.step^[T] c) ∧
(∀ i : Fin (M.k + 2), i.val < 2 → final.cells i = base.cells i ∧ final.head i = base.head i) ∧
(∀ j : Fin M.k, ∀ p : ℕ, p < offset j →
final.cells (workTape M j) p = base.cells (workTape M j) p) ∧
(∀ j : Fin M.k, final.cells (workTape M j) 0 = base.cells (workTape M j) 0) := by sorrySource
Original finite visited-workspace instrumentation for the integer-multiplication campaign. Written by Codex.