Documentation

CslibFrontier.Computability.Machines.Turing.MultiTape.Halting.SMN

The s-m-n theorem in polynomial time #

The description Turing.MultiTapeTM.Universal.hardwire d p, which behaves on every input x as d behaves on p ++ x (Turing.MultiTapeTM.Universal.Desc.computes_hardwire), is computed from d and p in polynomial time (Turing.MultiTapeTM.Universal.computableInPolyTime_hardwire): this is the s-m-n theorem for native descriptions, the counterpart of Sipser, Lemma 6.1. The transitions of hardwire d p are lists built from those of d and from the symbols of p by the list operations of the polynomial-time calculus, which fun_prop assembles from the fields of keys, actions and descriptions, using the shared bit coding rules in CslibFrontier.Computability.Machines.Turing.MultiTape.Universal.PolyTime. The exact framed unary length of the generated description and a concrete quadratic upper bound are proved separately in CslibFrontier.Computability.Machines.Turing.MultiTape.Halting.SMNBounds. The transformation is offline; its runtime is not part of executing the generated description.

Main definitions #

Main results #

References #

Fields of keys, actions and descriptions #

@[reducible, inline]

Transition tables, the table field of eDesc: the concatenation of the framed entries, each entry the framed eKey of its key followed by the eAct of its action.

theorem Turing.MultiTapeTM.Universal.Hardwire.redirectEntry_hardwire (e : Key × Act) :
Redirect.redirectEntry (fun (q : ℕ) => 2 * q + 1) none [] 0 id e = fun (s : Option ℕ) => ({ state := 2 * e.1.state + 1, input := none, work := s :: e.1.work }, { inputTape := SignType.zero, workTapes := (none, Redirect.vmove s e.2.inputTape) :: e.2.workTapes, output := e.2.output, state := Option.map (fun (q : ℕ) => 2 * q + 1) e.2.state })

The transitions of hardwire d p #

The s-m-n theorem: the description with an input prefix built in, Turing.MultiTapeTM.Universal.hardwire d p, is computed from d and p in polynomial time.