An automata simulator.
This is a simulator for various types of automata, built with TypeScript. It allows you to define, visualize, and simulate the behavior of finite state machines:
- ✅ DFA (Deterministic Finite Automaton)
- 🔀 NFA (Non-deterministic Finite Automaton)
-
🔄 Finite State Automata Simulation
Supports both DFA and NFA simulations. -
🎨 Visualization
See the automaton graphically and follow transitions live. -
⏱️ Step-by-step Execution
Simulate your automaton one step at a time for better understanding. -
🧾 Clear Results
Displays simulation results in a user-friendly format.
-
Prerequisites
-
Clone the repository
git clone https://github.com/guychuk/automata-simulator.git cd automata-simulator
-
Install dependencies
npm install
-
Build the project
npm run build
This creates a
dist
folder with compiled files. -
Run locally
- Open
dist/index.html
in your browser.
- Open
-
Or start a local dev server
npm run serve
- Visit http://localhost:8080
-
Define your automaton:
- Enter your alphabet, states, initial state, accepting states, and transitions.
- Submit using the "Submit Automaton" button.
- Use an empty string for ε-transitions:
q0,,q2
-
Run the simulator:
- Enter your input string.
- (Optional) Adjust step duration.
- Click "Run" to start simulation.
This shows an automaton checking if a binary number is divisible by 3.
1010
(10) → ❌ Not divisible1011
(11) → ❌ Not divisible1100
(12) → ✅ Divisible
Try it now on GitHub Pages 👉 Live Demo.
This project was originally developed as part of the white-rabbit
repository.
To view the full commit history and earlier development, visit:
➡️ white-rabbit 🐇