Tape actions shared by Turing-machine combinators #
Idle and leftward directions respect the start marker. Read-back writes preserve off-start tape contents, providing the transition invariants used by combinators.
Direction for an idle tape: move right if reading ▷, else stay.
Satisfies δ_right_of_start for tapes not involved in the current phase.
Equations
Instances For
Direction for a tape we want to move left: move left unless reading ▷,
in which case move right to satisfy δ_right_of_start. During actual
execution the tape won't be at cell 0, so this always moves left.
Equations
Instances For
idleDir moves right when reading the start symbol ▷.
If the head reads ▷, then idleDir moves right — the shape of the
δ_right_of_start obligation for idle tapes.
If the head reads ▷, then moveLeftDir moves right — the shape of the
δ_right_of_start obligation for tapes being rewound.
Write back the same symbol read from a tape, preserving cell contents.
Maps ▷ to □ since Tape.write at position 0 is a no-op anyway.
Equations
Instances For
readBackWrite recovers the original symbol away from the left-end marker.
The "do nothing" transition output: all writes are □, all directions
are idleDir. Used for states that only change the control state.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The content-preserving driver action: write every currently read work and
output symbol back, and use idleDir on every tape. Every off-start tape is
preserved exactly; a head on ▷ takes the structurally mandatory move right.
Equations
- One or more equations did not get rendered due to their size.
Instances For
allReadBack satisfies the one-sided-tape direction invariant.