The authors analyze some real accidents and proved that CAEva method appears as a very promising solution, especially in the cases of building renovations or temporary unavailability of escape routes. The tests performed on real accident showed that an appropriately configured program allows obtaining a realistic simulation of human evacuation. Proposed method, called Cellular Automata Evaluation (CAEva in short), is using cellular automata theory and could be used for checking buildings conditions for fire accident. There were a lot of fires in public places which kill many people. The control box allows the user to run individual words with adjustable speeds, run many words at once instantly, see the input alphabet and stack/queueĪlphabet actively used in the current machine, and reset the collage.Many serious real-life problems could be simulated using cellular automata theory. The user can use the keyboard to quickly manipulate the selected component too ("i" to toggle initial state, "f" to toggle accepting For edges, it allows the user to change the transition characters of an edge. The selection box allows states to be renamed (although only the first four characters of the name will show up in the collage due to size constraints), made initial, made accepting, or deleted. This will show the component's info in the selection box. A state or edge can be selected by clicking on it. Also, they can move states by clicking and dragging while not holding shift. The user can add states by double clicking on the collage and add edges by dragging between two states while holding down shift. The interface interface has three primary components: a collage, a control box, and a selection box where the user can edit the currently selected collage component. Queue automata with epsilon transitions are equivalent to Turing Machines, but my simulator does not allow epsilons for QAs. QAs are PDAs with a queue instead of a stack. My simulator does not allow epsilon transitions for PDAs to avoid the risk of non-terminating behavior (Apparently, PDAs withoutĮpsilon transitions are equivalent to PDAs with epsilons, according one Stack Exchange post:, but I'd have to look into that more before being convinced). Also, an NFA allows epsilon transitions which are taken without reading a character.Ī PDA is an NFA which maintains a stack for each current non-deterministic state while running and pushes or pops from the state while transitioning. For the simulator, the alphabet is the set of all unicode characters which the browser can recognize, and there is an implicit, non-accepting state which is the output of any transition for a state/character pair which the user hasn't been defined yet).Ī NFA is similar to a DFA except that multiple transitions can be defined for the same state/character pair, in which case the machine takes all possible transitions at once. I include four types of abstract machines, deterministic finite automata (DFA), non-deterministic finite automata (NFA), pushdown automata (PDA), and queue automata (QA).Ī DFA is a set of states, an initial state, a set of accepting states, and transitions between states such that given an input character, a state can transition to at most one state (Normally, a DFA requires an alphabet too, and that there is a transition defined for every character in that alphabet at every state. You can see a (somewhat-out-of-date) version running at: Īlternatively, you can run the code locally with Elm. There were two main components to this: an Elm file with an automaton data type and functions to construct and run an automaton (StateMachines.elm) and an Elm file to display a visual interface which the user could use to easily manipulate the simulator (FSA.elm). This is a simulator for several abstract machines in automata theory and formal languages written in Elm for CMSC 22300: Introduction to Functional Programming at UChicago.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |