Extending a machine with additional work tapes #
extendTapes tm e, for an embedding e : Fin k ↪ Fin k', runs tm inside a machine with more
work tapes. The tapes selected by e are used by tm: target tape e j plays the role of source
tape j. The remaining tapes are left unchanged.
The configuration map embed e cfg extraTapes extraPos places cfg on the selected tapes and
initialises the remaining tapes from extraTapes and extraPos.
The main lemmas show that one step and an entire run of the larger machine mirror the corresponding
step and run of tm.
Main definitions #
Turing.MultiTapeTM.partialInv: the partial inverse of the tape embedding.Turing.MultiTapeTM.extendTapes: the machine with reindexed work tapes.Turing.MultiTapeTM.embed: the corresponding configuration map.Turing.MultiTapeTM.tapeEmb: the embedding placing the only tape of a one-tape machine on tapei, andTuring.MultiTapeTM.noTapes: the embedding of a machine without work tapes.
Main results #
Turing.MultiTapeTM.step_embedandTuring.MultiTapeTM.runFrom_embed: the one-step and run-level mirroring lemmas.Turing.MultiTapeTM.workTapePos_embed_of_not_range: the extra tapes never move.Turing.MultiTapeTM.spaceUsed_embed_le: the resulting space bound.Turing.MultiTapeTM.oneTapeCfg: the one-tape view of a configuration.Turing.MultiTapeTM.runFrom_tapeEmb,Turing.MultiTapeTM.spaceUsed_tapeEmb_le: the run and the space of a one-tape machine placed on work tapei.Turing.MultiTapeTM.TransformsTapes.tapeEmb: a one-tape specification, read on tapei.Turing.MultiTapeTM.runFrom_noTapes,Turing.MultiTapeTM.spaceUsed_noTapes_le: the run and the space of a machine without work tapes, placed in a machine withkof them.
The computable analogue of Function.partialInv for an embedding e: partialInv e l = some j
when e j = l (such j is unique by injectivity), and none when l lies outside the range of
e.
Equations
- Turing.MultiTapeTM.partialInv e l = if h : l ∈ Set.range ⇑e then some (e.invOfMemRange ⟨l, h⟩) else none
Instances For
partialInv e is a partial inverse of e.
tm run on the tapes selected by the embedding e, leaving other tapes untouched: work tape
e j plays the role of tm's tape j, and any tape outside range e is never written and never
moves.
Equations
- One or more equations did not get rendered due to their size.
Instances For
A configuration of tm, embedded: tape j goes to tape e j, the tapes outside range e
carry the given extraTapes contents and extraPos head positions.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Reindexing is a step-semiconjugation: the reindexed machine acts on the embedded tapes exactly
as tm does, and never touches the extra tapes.
The reindexed run mirrors the original, with the extra tapes held fixed throughout.
The head of a tape outside range e never leaves its starting position.
Space bound for a reindexed run. The embedded tapes contribute the space used by tm, while
each of the remaining k' - k tapes never moves and contributes at most one cell.
Placing a one-tape machine on a single work tape #
A one-tape configuration placed on tape i leaves every other tape as it was.
The one-tape view of a configuration of a machine with k work tapes: the tape and head of
tape i, with everything else as it is.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Running a one-tape machine on work tape i. The run is the run on the one-tape view of the
configuration, placed back on tape i; every other tape and head keeps its starting value. Combine
with embed_tapeEmb to read off the resulting configuration.
Space bound for a one-tape machine placed on tape i: the space of the one-tape run, plus
one cell for each tape the machine does not use.
A one-tape specification on tape i. A one-tape machine placed on tape i transforms the
word on that tape as it did on its own tape and leaves every other word alone; each remaining tape
costs one cell.
No tape is in the range of noTapes.
The view of a configuration as a configuration of a machine without work tapes.
Equations
- One or more equations did not get rendered due to their size.
Instances For
A configuration without work tapes, placed in a machine with k of them, only contributes its
state, its input head and its output.
Running a machine without work tapes inside a machine with k of them. Only the state, the
input head and the output change; every work tape and work head keeps its starting value.
Space bound for a machine without work tapes: one cell for each tape it does not use.