Tuesday, March 28, 2017

Deterministic Finite Automation with Java

Hello everyone, just jumping in to drop off a short little java code demo. For those of computer science, they may enjoy this. For an assignment in Formal Languages and Automata, I was tasked with creating a program that excepted a user input string and then checked each character of the string to see if it is excepted. This machine is known as a DFA, or Deterministic finite automation machine. More on DFA's can be found here: https://en.wikipedia.org/wiki/Deterministic_finite_automaton.
The DFA I was tasked with is figure 2.2 from chapter 2, pg 52 in "An Introduction to Formal Languages and Automata" by Linz, Peter.
Here is the language defining the maching:
Which, as a finite state machine, looks like this: 

I hope you all enjoy the code or it helps your in your understanding and learning. I welcome all comments and questions. Remember, #sudoAptGetUpdateYourBrain
This code can be found at github here: GettinDatFoShow's DFAdemo (CSsoldier)



No comments:

Post a Comment