Giter Club home page Giter Club logo

dfa-minimizer's Introduction

DFA-minimizer

First partial project carried out for the computational mathematics course.

Functionality

A program that reads from a file the elements that define an DFA and builds the equivalent minimized DFA. The program specifies if a string is accepted or not by the DFA.

The transition table will be defined in a txt file. The file shall be defined as follows:

  • The first line indicates the set of states of the automata separated by commas.
  • The second line indicates the alphabet symbols separated by commas.
  • The third line indicates the initial state.
  • The fourth line indicates the set of final states separated by commas.
  • The following lines indicate the evaluation of the extended transition function with the elements of the alphabet in the following format:

state, symbol = > state

Example, the following line

q0, a = > q1

indicates that the DFA processes the following: δ(q0,a) = q1

It is not necessary that all transitions are specified in this file. An evaluation may not appear if a state indicating that the result of that evaluation is the empty set

The outcome of this process is a minified version of the inputed DFA.

Dependencies

The functionality of this project relies on networkx and matplotlib libraries for the minified DFA visualization.

You can install them by using Python's PIP with the following commands:

pip install networkx

pip install matplotlib

Important note

This program doesn't validate the values in the input file, it assumes that they were built correctly.

Built with

Python Badge Networkx Badge Matplotlib Badge

dfa-minimizer's People

Contributors

richiesjt avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

Forkers

eduardoherreraj

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.