A nondeterministic finite automaton (NFA) generalizes the DFA by allowing multiple transitions from a single state on the same symbol, transitions on the empty string (epsilon-transitions), and missing transitions. An NFA accepts if there exists at least one computation path that reaches an accept state. The subset construction algorithm proves that every NFA can be converted to an equivalent DFA, establishing that NFAs recognize exactly the regular languages. The conversion may cause an exponential blowup in the number of states, but the language class remains the same.
Design an NFA for a language that would be awkward as a DFA — such as "strings whose third-from-last symbol is 1" — then apply the subset construction step by step. Seeing the DFA's state space explode makes the power-of-nondeterminism tradeoff concrete.
You've already built deterministic finite automata (DFAs): machines with a fixed transition function — from every state, on every input symbol, there is exactly one next state. The DFA's rigidity makes it easy to reason about but sometimes painful to design. A nondeterministic finite automaton (NFA) loosens this constraint in two ways. First, from a single state on a single input symbol, the machine may have zero, one, or multiple transitions — there's no requirement that the next state be unique. Second, the machine may take epsilon-transitions (ε-transitions): free moves that consume no input symbol at all.
The definition of acceptance changes to match this loosened structure. An NFA accepts an input string if *at least one* of the computation paths — one of the possible sequences of transitions the machine might take — ends in an accepting state. You can think of the machine as a parallel explorer: it clones itself at every branch point and pursues all paths simultaneously. If any clone reaches an accept state when the input is exhausted, the whole machine accepts. This is not how real hardware works, but it is a precise mathematical model that turns out to be computationally equivalent to DFAs despite appearing more powerful.
The key theorem — proved by the subset construction — is that every NFA can be converted into an equivalent DFA. The construction replaces each NFA state with a *set* of NFA states the machine could simultaneously be in after reading the input so far. If the NFA has n states, the DFA has at most 2^n states (one for each subset of the NFA's state set), though many of those subsets are often unreachable. The resulting DFA state is an accepting state if and only if it contains at least one NFA accept state. After including ε-closures (the set of states reachable by ε-transitions alone), the construction produces a DFA that mirrors the NFA's behavior exactly.
The practical implication is that NFAs and DFAs recognize the same class of languages — the regular languages — making NFAs a design tool rather than a new computational tier. NFAs are often dramatically easier to design: recognizing "strings whose third-from-last character is 1" takes a 4-state NFA but requires 8 DFA states via subset construction. The exponential state blowup in the worst case is real — and can be exhibited — but it never changes what's recognizable. This is in sharp contrast to nondeterminism in Turing machines and complexity classes like NP, where nondeterminism may confer genuine additional power. Finite automata are the clean counterexample where nondeterminism is purely a syntactic convenience.