Hallo,
im folgenden findest du den Text einer Datei, die auf flaci.com als json-Datei hochgeladen werden kann. Dort definiert das ganz eine Turing-Maschine, die bei der Eingabe 11001 die entsprechende Folge an Bandinhalten generiert. Außerdem wir die Maschine visualisiert.
Mfg Michael
PS: Zur Rückfrage: Ja.
Inhalt von Automaton_Umkehrer.json :
{ "name": "Umkehrer", "description": "Kehrt ein {0;1}-Wort um", "type": "TM", "automaton": { "simulationInput": [ "1", "0", "0", "1", "0" ], "Alphabet": [ "0", "1", "#", "D" ], "StackAlphabet": [ "|", "0", "1", "#", "D" ], "States": [ { "ID": 1, "Name": "q0", "x": 120, "y": 290, "Final": false, "Radius": 30, "Transitions": [ { "Source": 1, "Target": 1, "x": 0, "y": -150, "Labels": [ [ "0", "0", "R" ], [ "1", "1", "R" ] ] }, { "Source": 1, "Target": 2, "x": 0, "y": 0, "Labels": [ [ "|", "#", "L" ] ] } ], "Start": true }, { "ID": 2, "Name": "q1", "x": 340, "y": 290, "Final": false, "Radius": 30, "Transitions": [ { "Source": 2, "Target": 2, "x": -60, "y": -140, "Labels": [ [ "D", "D", "L" ] ] }, { "Source": 2, "Target": 3, "x": 0, "y": 0, "Labels": [ [ "0", "D", "R" ] ] }, { "Source": 2, "Target": 6, "x": 0, "y": 0, "Labels": [ [ "1", "D", "R" ] ] }, { "Source": 2, "Target": 9, "x": 0, "y": 0, "Labels": [ [ "|", "|", "R" ] ] } ], "Start": false }, { "ID": 3, "Name": "q2", "x": 490, "y": 200, "Final": false, "Radius": 30, "Transitions": [ { "Source": 3, "Target": 3, "x": 0, "y": -150, "Labels": [ [ "D", "D", "R" ] ] }, { "Source": 3, "Target": 4, "x": 0, "y": 0, "Labels": [ [ "#", "#", "R" ] ] } ], "Start": false }, { "ID": 4, "Name": "q3", "x": 740, "y": 200, "Final": false, "Radius": 30, "Transitions": [ { "Source": 4, "Target": 4, "x": 50, "y": -130, "Labels": [ [ "0", "0", "R" ], [ "1", "1", "R" ] ] }, { "Source": 4, "Target": 5, "x": -10, "y": -60, "Labels": [ [ "|", "0", "L" ] ] } ], "Start": false }, { "ID": 5, "Name": "q4", "x": 440, "y": 50, "Final": false, "Radius": 30, "Transitions": [ { "Source": 5, "Target": 5, "x": -90, "y": 0, "Labels": [ [ "0", "0", "L" ], [ "1", "1", "L" ] ] }, { "Source": 5, "Target": 2, "x": 0, "y": -10, "Labels": [ [ "#", "#", "L" ] ] } ], "Start": false }, { "ID": 6, "Name": "q5", "x": 490, "y": 380, "Final": false, "Radius": 30, "Transitions": [ { "Source": 6, "Target": 6, "x": 0, "y": -150, "Labels": [ [ "D", "D", "R" ] ] }, { "Source": 6, "Target": 7, "x": 0, "y": 0, "Labels": [ [ "#", "#", "R" ] ] } ], "Start": false }, { "ID": 7, "Name": "q6", "x": 740, "y": 380, "Final": false, "Radius": 30, "Transitions": [ { "Source": 7, "Target": 7, "x": 80, "y": -10, "Labels": [ [ "0", "0", "R" ], [ "1", "1", "R" ] ] }, { "Source": 7, "Target": 8, "x": 0, "y": 0, "Labels": [ [ "|", "1", "L" ] ] } ], "Start": false }, { "ID": 8, "Name": "q7", "x": 430, "y": 540, "Final": false, "Radius": 30, "Transitions": [ { "Source": 8, "Target": 2, "x": 0, "y": 0, "Labels": [ [ "#", "#", "L" ] ] }, { "Source": 8, "Target": 8, "x": -170, "y": -10, "Labels": [ [ "0", "0", "L" ], [ "1", "1", "L" ] ] } ], "Start": false }, { "ID": 9, "Name": "q8", "x": 240, "y": 380, "Final": true, "Radius": 30, "Transitions": [ { "Source": 9, "Target": 9, "x": -110, "y": 0, "Labels": [ [ "D", "|", "R" ], [ "#", "|", "R" ] ] } ], "Start": false } ], "lastInputs": [ [ "1", "0", "0", "1", "0" ] ] } }
|