Documentation

Complexitylib.Models.TuringMachine.Subroutines.ResetBinaryMany

Resetting several binary work tapes #

This module exposes a framed compositional contract for resetting a fixed list of distinct canonical binary work tapes.

theorem Complexity.TM.resetBinaryWorkManyTime_le {n : } (targets : List (Fin n)) (bits : Fin nList Bool) (headBound : Fin n) (maxHead maxWidth : ) (hhead : itargets, headBound i maxHead) (hwidth : itargets, (bits i).length maxWidth) :
resetBinaryWorkManyTime bits headBound targets targets.length * (maxHead + 2 * maxWidth + 9) + 1

A reset list has a uniform linear bound when every target head and represented bit string is bounded uniformly.

theorem Complexity.TM.resetBinaryWorkManyResult_eq_blank_of_mem {n : } (work₀ : Fin nTape) (targets : List (Fin n)) (idx : Fin n) (hidx : idx targets) :

Every targeted work tape is the standard parked blank after the reset sequence.

theorem Complexity.TM.resetBinaryWorkManyResult_eq_of_not_mem {n : } (work₀ : Fin nTape) (targets : List (Fin n)) (idx : Fin n) (hidx : idxtargets) :
resetBinaryWorkManyResult work₀ targets idx = work₀ idx

Work tapes outside the target list are preserved literally.

theorem Complexity.TM.resetBinaryWorkManyResult_parked {n : } (work₀ : Fin nTape) (targets : List (Fin n)) (hwork : ∀ (i : Fin n), Parked (work₀ i)) (i : Fin n) :
Parked (resetBinaryWorkManyResult work₀ targets i)

Resetting a list of work tapes preserves parkedness of the whole work family.

theorem Complexity.TM.resetBinaryWorkManyTime_congr_headBound {n : } (targets : List (Fin n)) (bits : Fin nList Bool) (left right : Fin n) (heq : itargets, left i = right i) :
resetBinaryWorkManyTime bits left targets = resetBinaryWorkManyTime bits right targets

The reset-sequence time depends on head bounds only at named targets.

theorem Complexity.TM.resetBinaryWorkManyTM_hoareTime_frame {n : } (targets : List (Fin n)) (bits : Fin nList Bool) (headBound : Fin n) (inp₀ : Tape) (work₀ : Fin nTape) (out₀ : Tape) (hnodup : targets.Nodup) (htarget : itargets, (work₀ i).HasBinaryContent (bits i)) (htargetStart : itargets, (work₀ i).cells 0 = Γ.start) (htargetHead : itargets, (work₀ i).head headBound i) (hinput : Parked inp₀) (hwork : ∀ (i : Fin n), Parked (work₀ i)) (houtput : Parked out₀) :
(resetBinaryWorkManyTM targets).HoareTime (fun (inp : Tape) (work : Fin nTape) (out : Tape) => inp = inp₀ work = work₀ out = out₀) (fun (inp : Tape) (work : Fin nTape) (out : Tape) => inp = inp₀ work = resetBinaryWorkManyResult work₀ targets out = out₀) (resetBinaryWorkManyTime bits headBound targets)

Sequentially reset a distinct list of canonical binary work tapes while preserving the complete external frame.

Resetting several binary work tapes preserves one-way output safety.

theorem Complexity.TM.resetBinaryWorkManyTM_prefix_withinAuxSpace {n : } (targets : List (Fin n)) (bits : Fin nList Bool) (headBound : Fin n) (inputLength initialSpace time : ) (start current : Cfg n (resetBinaryWorkManyTM targets).Q) (hinitial : start.WithinAuxSpace inputLength initialSpace) (hreach : (resetBinaryWorkManyTM targets).reachesIn time start current) (htime : time resetBinaryWorkManyTime bits headBound targets) :
current.WithinAuxSpace inputLength (initialSpace + resetBinaryWorkManyTime bits headBound targets)

Coarse all-prefix auxiliary-space envelope for a reset sequence.