Past exam of the mathematics course of the University of Cambridge 2019 ii Paper 1 12H Solution Created 2026-09-24 Updated 2026-09-29
Let be the extended transition function of a deterministic finite automaton. States are equivalent, or indistinguishable, whenThe quotient deterministic finite automaton by indistinguishable states has state set , initial state , accepting states , and transitionRight invariance of makes this well-defined, and the quotient accepts .
To prove minimality, choose for each state of the accessible automaton a word with . Run the same word in any DFA accepting , and assign the class the reached state of . If two distinct classes reached the same state of , every continuation would have the same acceptance result after and . Since and accept the same language, this would make and indistinguishable in , a contradiction. Thus has at least one distinct state for every class in , proving that the quotient is the minimal deterministic finite automaton.
For divisibility by seven, take states , initial state , accepting set , and transitionsAfter reading a word, the state is its binary value modulo seven, so this binary divisibility automaton accepts exactly the multiples of seven, with leading zeros allowed. Every state is accessible: the three-bit words representing reach the corresponding residues.
Past exam of the mathematics course of the University of Cambridge 2021 iii Paper 120 1 Solution 2026-09-28
The Knaster-Tarski theorem states that the fixed points of a monotone map on a complete lattice form a complete lattice. LetFor every , monotonicity gives , hence . Applying once more gives , so . The definition of then gives , and therefore . Thusis the least fixed point. The order-dual argument shows thatis the greatest fixed point.
More generally, for a family of fixed points, let be the set of prefixed points satisfying and for every . Its meet is again prefixed. Since for every , the element also lies in , so the preceding argument gives . It is the join of within the fixed-point order. The dual construction gives the meet of within that order, proving completeness.
For the Myhill-Nerode theorem, let and define the Myhill-Nerode equivalenceThis is an equivalence relation and a right congruence: implies for every letter .
If a deterministic finite automaton accepts , any two words reaching the same state are equivalent, because every continuation has the same subsequent run. Hence has at most as many classes as the automaton has states. Conversely, if has finitely many classes, define an automaton with state set , initial state , transitionand accepting states with . Right congruence makes the transition well defined, and induction on word length shows that the state reached by is , so the automaton accepts exactly . Therefore is a regular language exactly when has finite index. Moreover, every automaton for has at least one state for each equivalence class, so this quotient is the minimal deterministic finite automaton.
Past exam of the mathematics course of the University of Cambridge 2023 ii Paper 3 12I iv Solution Created 2026-09-24 Updated 2026-09-25
Suppose first that is a regular language, accepted by a deterministic finite automaton . If two words reach the same state, then every continuation is accepted from both or rejected from both. Thus they are equivalent under , and the number of equivalence classes is at most the finite number of states of .
Conversely, suppose has finitely many classes. Define a deterministic automaton byandThe transition is well defined: if , then for every suffix ,so . Likewise, membership in is independent of the representative by taking the empty suffix in the definition of . Induction givesso the automaton accepts exactly . It has finitely many states, and therefore is regular. This proves the Myhill-Nerode theorem in the stated formulation. The assumption merely says that the initial state is not accepting.
Past exam of the mathematics course of the University of Cambridge 2026 ii Paper 2 4I c Solution Created 2026-09-24 Updated 2026-09-25
The Myhill-Nerode theorem says this quotient is, up to isomorphism, the unique accessible DFA with the least possible number of states accepting the language.