Correctness internals for fixed-time repetition #
This file proves the local simulation and fixed-rewind invariants used by the
public correctness theorems for NTM.repeatAtTime.
Project one active repetition bank back to a source-machine configuration. The source state is carried in the repetition control and is therefore supplied separately.
Equations
- tm.repeatProjectCfg j q C = { state := q, input := C.input, work := fun (i : Fin n) => C.work (Complexity.NTM.repeatWorkIdx j i), output := C.work (Complexity.NTM.repeatOutputIdx j) }
Instances For
Apply one source transition without a halting check. Repetition uses this
operation exactly in non-halted .run states.
Equations
- One or more equations did not get rendered due to their size.
Instances For
An active repetition bank simulates c. Before source halting its complete
projection agrees with c; after halting only the state and tape cells are
required to agree, because fixed-slot padding may bounce a head off cell zero.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Exact projection implies the simulation relation.
On a transition direction already satisfying the model's left-end rule, the repetition machine's defensive direction guard is inert.
Positioning an off-start tape writes its current symbol back and moves its head one cell left.
A parked initialized input returns to its initial head position under the positioning action.
A parked blank work tape returns to its initial head position under the positioning action.
Fixed-time rewind of one tape #
Iterate the one-tape rewind component in the cons-first order of NTM.trace.
Equations
Instances For
Under the unique-left-marker invariant, a tape reads ▷ exactly at cell zero.
T + 1 fixed rewind steps park any invariant tape whose head is at most
T at cell one, set its completion flag, and preserve all cells.
Configuration after the first setup transition: all tapes are parked at cell one and the control is ready to choose the first repetition.
Equations
- One or more equations did not get rendered due to their size.
Instances For
With at least one repetition and one simulated step, the second setup transition positions trial zero exactly at the source initial configuration.
With positive repetition count and simulation time, the second setup
transition gives trial zero the exact source initial configuration. This
stronger projection fact also covers tm.qstart = tm.qhalt.
The complete two-transition setup establishes the source initial configuration in trial zero.
The complete positive-time setup gives trial zero the exact source initial configuration.
One non-halted repetition .run transition commutes exactly with one raw
source transition through the active-bank projection.
One non-halted repetition .run transition projects to the source
machine's one-step trace, including the source's own halting semantics.
A .run slot after the source has halted advances the fixed counter while
preserving the source state and every projected tape cell. Thus the
halt-aware simulation relation survives padding slots.
A complete fixed-width simulation run #
Every proper prefix of a fixed-width simulation run remains in .run,
tracks the corresponding source prefix, and preserves all start invariants.
Exactly T simulation slots advance trial j from its initial .run
state to rewind counter zero. The active bank agrees with the source T-step
trace even when the source halts early, and all tape start invariants persist.