Counting-machine runs as shared programs #
The choice program queries an occurrence index in Fin choices.length. Interpreting such
queries by the list of all indices preserves repeated occurrences, and a singleton instruction
has one outcome. An empty choice list interprets to no outcomes.
Main definitions #
Turing.MultiTapeCTM.occurrenceSpec: a finite occurrence-index query.Turing.MultiTapeCTM.chooseOccurrence: select an entry without identifying equal entries.Turing.MultiTapeCTM.runProgram: the existing sharedrunConfigFromwith this choice handler.
Main results #
Turing.MultiTapeCTM.interpret_chooseOccurrence: List interpretation recovers the exact list.Turing.MultiTapeCTM.chooseOccurrence_map: mapping preserves the occurrence query program.Turing.MultiTapeCTM.interpret_runProgram_succ: one actual transition unfolds by list bind.
These are programs in the existing PFunctor.FreeM calculus, not a second branch semantics or
an efficiency claim about an interpreter. The machine and program infrastructure credits its
authors in MultiTape.Machine and MultiTape.Machine.Program; the oracle interface and generic
interpretation credit Devon Tuma, Quang Dao and VCVio in Languages.Probabilistic.Basic.
Query the index of one of n transition occurrences; n = 0 permits no response.
Instances For
Select a list entry by its occurrence index, preserving equal entries at distinct positions.
Instances For
Mapping changes each response value without adding or identifying occurrence queries.
Enumerating responses recovers the original list, including its order and multiplicities.
The shared clocked machine program, with finite-index choice and no oracle channels.
Instances For
List interpretation executes each live occurrence once and then continues the same program.