Question
Implement in C a deterministic finite automata (DFAs), nondeterministic finite automata (NFAs), and a converter than turns an NFA into an equivalent DFA. 1. Deterministic
Implement in C a deterministic finite automata (DFAs), nondeterministic finite automata (NFAs), and a converter than turns an NFA into an equivalent DFA.
1. Deterministic finite automata (DFAs) that, individually, recognize the following languages:
(a) Exactly the string computer
(b) Any string that starts with the characters rofl
(c) Binary input with an odd number of 0s
(d) Binary input with an odd number of both 0s and 1s
(e) At least one other pattern that you think is interesting (and hopefully different from other students)
2. Non-deterministic finite automata (NFAs) that individually recognize the following languages:
(a) Strings ending in emb
(b) Strings containing emb
(c) Strings with more than one a, g, h, i, o, s, t, or w, or more than two ns.
(d) At least one other pattern that is interesting
3. Implement a translator function that takes an instance of an NFA as its only parameter and returns a new instance of a DFA that is equivalent to the original NFA (accepts the same language). The program must demonstrate that the translator works by using the first two NFAs from Part 2, translating them to DFAs, printing out how many states are in the resulting DFA, and running it on user input as described below. That is, youll have four functions that produce NFAs from Part 2 of the project. For the first two of those, pass the NFA that they return to the converter and run the resulting DFA on user input as described below.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started