TDML
TDML (Two Dimensional Minimalistic Language) is an Turning tarpit by User:ChuckEsoteric08 inspired by 2L and 1L. It also is a languge where many commands can function differently in various implementations
Specification
TDML is a cell-based two-dimensional language with has four commands: +
, *
, ?
and NOP, which can be represented as any other character. The tape is binary and infinite in both sides
+
This is command changes the directiion of Instruction Pointer clockwise. For example (arrows represent direction):
>>+ ^ v ^ v +<<+
*
and NOP
This two commands operate on instruction wheel which looks like this (where >
represents current command, which is flip
by default, although it can be other command depending on implementation (and in some the order of commands is different, some even deleting in
and out
entirely, with this one being official one)
> flip right left in out
Each time a NOP is met instruction is changed to the next one on a wheel. When *
is met the instruction is executed. flip
would flip the cell under the cell pointer, right
would move cell pointer right, and left
would move it left, in
would store next byte input of input as a binary value, with first bit in the current cell, and the other 7 in the next 7 cells to the right (or to the left, depending on implementation). out
would output bit in the current cell followed by the next 7 cells to the right (or to the left, depending on implementation). I/O instruction can instead function on 8 cells to the right or to the left in some implementations
?
This command is a conditional instruction, which would skip the instruction in the same direction if the cell is 0
Variations
Note that this varuations can be combined together, called TDML-RMe, TDML-R-Mi, TDML-RMeMi and TDML-MeMi
TDML-R
R stands for "Restart", in which after executing *
the wheel restarts to the same position it started on
TDML-Me
Me stands for "Merged", in this one command ?
becomes skip
on instruction wheel, with this being official order:
> flip right left skip in out
TDML-Mi
Mi stands for "Minimised" in which flip
is merged with either right
or left
, with the instruction to which is merged to and whether it would flip the cell after or before moving the cell pointer depends on implementation, with none being official
Computational class
The language and all of it variations are Turing-complete, however it is very difficult to program in them.