资 源 简 介
This is a multi-tape Turing Machine project written in Haskell. You are welcome to contribute.
Usage
You can create a more robust executable or modify TM.hs to suit your needs.
I provided a simple main script that requires four arguments:
Path to file which contains the tapes;
Path to file which contains the transitions;
Number of the initial state;
true or false.
A tape is a string. Separate them with a newline. The blank symbol is #.
The transitions are more complicated, so I wrote an example:
((0,["0","#"]), (1,[("0", R),("b",R)])) ((1,["0","#"]), (1,[("0", R),("b",R)])) ((1,["1","#"]), (2,[("1", H),("b",H)])) ...
Each line is the type: ((State, [Symbol]), (State, [(Symbol, Action)])).
For the first line, you should read: In state 0, if I have "0"