%!target: html %!encoding: utf-8 %!options(html): --toc-level=1 --mask-email --css-sugar --style standard.css %!postproc(html): '' 'Destate' %!postproc(html): '\[start_thumb\]' '

' %!postproc(html): '\[end_thumb\]' '

' = About = **Destate** (Discrete Event System Toolkit and inTeractive Environment) is a tool to create and do operations with automata. == Features == - Interactive visualization of the automaton (zoom, translation). - Interactive creation of the automaton (with command line). - Save and open automaton as XML files. - Visualization of the automaton data. - Multi visualization of automata. - Support to Deterministic and Non-deterministic. - **(in progress)** API for do operations with automata. - NFA to DFA conversion. = Installing = The following explains how install the **Destate** tool. == Requirements == To install **Destate** you have to satisfy the following dependencies: - Python: http://www.python.org/. - PyCairo: http://cairographics.org/pycairo/. - PyGTK and PyGObject: http://www.pygtk.org/. - PyDOT: http://code.google.com/p/pydot/ (tested with version [1.0.28 https://code.google.com/p/pydot/downloads/list]). - GraphViz: http://www.graphviz.org/. **Destate** works under Unix, Windows and Mac OS X (these two last are not tested yet, but probably can run without big problems) operating systems. == Download == Get latest version at the GitHub [repository https://github.com/labepi/destate]. = Using = To start the application you can execute this command: ``` $ python destate.pyw ``` If everything is correct, you'll see something like images in the screenshots section. You also may open some examples at //share/sample// directory. == Commands == To create the automaton you need use the command line interface (or, soon, load XML description file). Bellow we present a table with commands and their descriptions. || Command | Description | | ``do`` | Do operations with selected automaton. | | ``add`` | Add states, events or transitions. | | ``del`` | Delete states, events or transitions. | | ``init`` | Set the initial state. | | ``mark`` | Add a finalo state. | | ``unmark`` | Remove a initial state. | The commands ``add`` and ``del`` always are followed by a element token (//state//, //event// or //transition//) and a element argument. Before continue with the element arguments we need to define how can be defined a //state// and a //event//. In table bellow is discriminated with regular expression valid states and events. || Token | Regular expression | | ``state`` | [\w]+(,[\w])* | | ``event`` | [\w]+ | If you want to add two states called "A" and "b", an //event// called "x" and make a transition from "A" to "B" give "x" you must type: ``` add state A add state B add state C add event x add lambda A C add transition A x B ``` The commands ``init``, ``mark`` and ``unmark`` are followed by a //state// token. To set "A" the initial state of the automaton and "B" an final state you must type: ``` init A mark C ``` To remove final state flag from a state you can type ``unmark`` instead ``mark`` command. And finally, to convert an NFA to a DFA you can just type: ``` do nfa2dfa ``` == XML == **Destate** has the capability of read and write XML descriptions of automata. Below an example of a XML automaton description. ``` Destate XML example. ``` = Screenshots = [start_thumb] [[image/screenmini-01.png] image/screenshot-01.png] [[image/screenmini-02.png] image/screenshot-02.png] [[image/screenmini-03.png] image/screenshot-03.png] Screenshots above are based on Destate 0.2. [end_thumb] ----------------------------------------------------------------------------- View [[image/t2tpowered-white.png] http://txt2tags.sourceforge.net/] source file [%%infile %%infile].