Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
Deterministic finite automaton
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
==Advantages and disadvantages== DFAs are one of the most practical models of computation, since there is a trivial linear time, constant-space, [[online algorithm]] to simulate a DFA on a stream of input. Also, there are efficient algorithms to find a DFA recognizing: * the complement of the language recognized by a given DFA. * the union/intersection of the languages recognized by two given DFAs. Because DFAs can be reduced to a ''canonical form'' ([[DFA minimization|minimal DFAs]]), there are also efficient algorithms to determine: * whether a DFA accepts any strings (Emptiness Problem) * whether a DFA accepts all strings (Universality Problem) * whether two DFAs recognize the same language (Equality Problem) * whether the language recognized by a DFA is included in the language recognized by a second DFA (Inclusion Problem) * the DFA with a minimum number of states for a particular regular language (Minimization Problem) DFAs are equivalent in computing power to [[nondeterministic finite automata]] (NFAs). This is because, firstly any DFA is also an NFA, so an NFA can do what a DFA can do. Also, given an NFA, using the [[powerset construction]] one can build a DFA that recognizes the same language as the NFA, although the DFA could have exponentially larger number of states than the NFA.{{sfn|Sakarovitch|2009|p=105}}{{sfn|Lawson|2004|p=63}} However, even though NFAs are computationally equivalent to DFAs, the above-mentioned problems are not necessarily solved efficiently also for NFAs. The non-universality problem for NFAs is [[PSPACE complete]] since there are small NFAs with shortest rejecting word in exponential size. A DFA is universal if and only if all states are final states, but this does not hold for NFAs. The Equality, Inclusion and Minimization Problems are also PSPACE complete since they require forming the complement of an NFA which results in an exponential blow up of size.<ref>{{Cite web |last1=Esparza Estaun |first1=Francisco Javier |last2=Sickert |first2=Salomon |last3=Blondin |first3=Michael |date=16 November 2016 |orig-date= |title=Operations and tests on sets: Implementation on DFAs |url=https://www7.in.tum.de/um/courses/auto/ws1718/slides1718/04-Implementations_sets.pdf |url-status=dead |archive-url=https://web.archive.org/web/20180808171506/https://www7.in.tum.de/um/courses/auto/ws1718/slides1718/04-Implementations_sets.pdf |archive-date=8 August 2018 |website=Automata and Formal Languages 2017/18 }}</ref> On the other hand, finite-state automata are of strictly limited power in the languages they can recognize; many simple languages, including any problem that requires more than constant space to solve, cannot be recognized by a DFA. The classic example of a simply described language that no DFA can recognize is bracket or [[Dyck language]], i.e., the language that consists of properly paired brackets such as word "(()())". Intuitively, no DFA can recognize the Dyck language because DFAs are not capable of counting: a DFA-like automaton needs to have a state to represent any possible number of "currently open" parentheses, meaning it would need an unbounded number of states. Another simpler example is the language consisting of strings of the form ''a<sup>n</sup>b<sup>n</sup>'' for some finite but arbitrary number of ''a''{{'}}s, followed by an equal number of ''b''{{'}}s.{{sfn|Lawson|2004|p=46}}
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)