An NFA with $n$ states can be converted to an equivalent DFA. The resulting DFA has AT MOST how many states?
A$n$ states (same as NFA)
B$n^2$ states
C$2^n$ states (exponential blow-up)
D$n!$ states
Answer & Solution
Correct answer: C. $2^n$ states (exponential blow-up)
1. The SUBSET (powerset) CONSTRUCTION converts an NFA to an equivalent DFA.
2. Each state of the DFA represents a SUBSET of the NFA's states (the set of NFA states the NFA could be in after reading the input).
3. The number of subsets of an $n$-element set is $2^n$. So the DFA has at most $2^n$ states.
4. For SOME languages, this exponential blow-up is unavoidable — there exist NFAs with $n$ states whose minimal equivalent DFA needs $2^n$ states.
5. For OTHER languages, the DFA may be much smaller (e.g. for a single-state NFA the DFA has 1 state).
6. Options A, B, D underestimate the bound.
_Source: Jeff Erickson, "Models of Computation", §2.6 (Powerset construction)._
Keep practising Theory of Computation
Browse all Theory of Computation questions for GATE CSE, or explore more Computer Science topics.
Related questions
Which class of grammars generates ALL recursively enumerable languages?Which of the following languages is CONTEXT-FREE?Consider the grammar $S \to (S) \mid SS \mid \varepsilon$. The language generated isEvery regular language is also context-free. The PROOF construction isThe CYK algorithm parses a CFG in CNF. Its time complexity for a string of length $n$ isContext-free languages are RECOGNISED by which type of machine?A CFG is AMBIGUOUS ifConsider the CFG with rule $S \to aSb \mid \varepsilon$. The language generated is