Direct ToPartrec.Code → TM Recognition #
This file proves the direct bridge from a semideciding ToPartrec.Code to
is_TM. It composes the user code with listEncodeCode, so the Partrec chain
runs on a variable-length List ℕ input representing the encoded word. The
tape-level part realizes the finite per-symbol conversion from the input
alphabet to the shifted chain fragments used by shiftedEncoding.
Key results #
shifted_converter_exists: realizes the finite per-symbol conversion.directEmbedTM0_eval_dom: alphabet lifting preserves the embedded TM0's halting domain.code_implies_isTM_direct: aToPartrec.Coderecognizing a language givesis_TMfor that language.
Blank-preserving embedding #
Equations
- directBlankInv (some (Sum.inr γ)) = γ
- directBlankInv a = default
Instances For
Direct shifted tape construction #
Instances For
Equations
Instances For
Equations
Instances For
Equations
- shiftedPayload = List.foldr (fun (t : T) (acc : List ChainΓ) => shiftedSymbolBlock t ++ acc) []
Instances For
Equations
Instances For
Equations
- shiftedFoldAccStep t acc = shiftedSymbolBlock t ++ acc
Instances For
Equations
Instances For
Remaining direct-converter obligation #
The reduced converter obligation for the direct bridge.
It maps identity-encoded input w to the embedded Partrec-chain tape for
shiftedEncoding w. Since T is finite, this is implemented by the finite
per-symbol substitution fold above rather than binary arithmetic on the tape.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Local alphabet embedding #
Embed a ChainΓ TM0 into Option (T ⊕ ChainΓ), preserving blanks.
Instances For
The direct embedding preserves halting behavior.
Once the reduced converter exists, any ToPartrec.Code-semidecidable
language is is_TM.
This is the sound replacement target for the current arithmetic converter:
the Code-level list encoding is already handled by composedCode, and the
tape-level converter only needs to write shiftedEncoding w.