Finite Automaton

Turkish equivalent: Sonlu otomatDomain: Software Engineering

An abstract machine with finitely many states and transitions that reads an input string symbol by symbol and ends in acceptance or rejection.

A finite automaton limits its memory to a finite set of states. The standard model is described by the state set Q, alphabet Σ, transition function δ, initial state q0, and accepting states F.

A deterministic automaton has one next state for each state-symbol pair. A nondeterministic automaton can admit several alternatives; despite that difference, DFA and NFA recognize the same class of regular languages.

In lexical analysis a finite automaton recognizes tokens from a character stream. Syntax involving unbounded nesting, such as balanced parentheses, generally needs a stack and is modeled with context-free grammars and pushdown automata. Recognizing tokens with a finite automaton is not equivalent to validating the complete syntax of a programming language.

The language of the automaton is the set of strings that take the machine from its initial state to an accepting state. See Right-Linear Grammar for the grammar view and Automata Theory and Formal Languages for the broader progression.