The existing single-machine tidy normalization construction #
Machine declarations are moved from their original module without changing programs or resource formulas. Higher computability-calculus theorems remain in the original facade.
Clearing a work tape and its shadow #
Work tape i of C and its shadow k + i are ready to be cleared: the heads of both are on
cell c - a, the shadow marks cells V that together with c - a form the interval [-a, b],
and the work tape is blank outside it.
The head of the work tape is on cell
c - a.The head of the shadow is on cell
c - a.The marked cells and the cell under the heads form the interval
[-a, b].The shadow marks the cells
V.- blank (y : ℤ) : y ∉ Finset.Icc (-↑a) ↑b → C.workTapes (Fin.castAdd k i) y = none
The work tape is blank outside
[-a, b].
Instances For
Clearing tapes l preserves PairReady on any tape i ∉ l.
Clearing one work tape and its shadow inside a machine with k + k work tapes.
The control states of clearList for a list of length n.
Instances For
Clear the work tapes in l along their shadows, one after the other.
Instances For
Clearing a list of work tapes with their shadows, each ready to be cleared: a run path of
clearList m₀ m₁ l to the configuration with these tapes cleared.
The tidy normal form #
The tidy normal form of tm: run tm with shadowed work tapes, clear every work tape along
its shadow, and rewind the input head. The symbols m₀ and m₁ mark the shadows.
Instances For
The run of the tidy normal form. If tm first halts at step u, having used S cells,
then tidy m₀ m₁ tm has a run path to the halted configuration with blank work tapes, every head on
its start cell and the output of tm, taking at most 2 u + 3 S + 2 k + 4 steps and visiting at
most 2 S + 2 k (3 S + 2 k + 3) cells.
The tidy normal form. What tm computes within t steps and s cells,
tidy m₀ m₁ tm computes tidily within 2 t + 3 s + 2 k + 4 steps and 2 s + 2 k (3 s + 2 k + 3)
cells, for any two distinct marks m₀ and m₁.