---
title: Quantum Finite Automata (QFAs) Overview
url: https://www.emergentmind.com/topics/quantum-finite-automata-qfas
type: topic
---

# Quantum Finite Automata (QFAs) Overview

A quantum finite automaton (QFA) is a theoretical model for computing in finite space using quantum operations. QFAs generalize classical finite automata (deterministic and probabilistic) by allowing state evolution through unitary matrices (or more generally, super-operators), with language acceptance determined by the outcome of a projective measurement. QFAs are strictly more expressive on unary alphabets than classical probabilistic automata, can achieve exponential succinctness in state complexity for certain promise problems, and permit uncountably many language classes with only two quantum states, demonstrating intrinsic quantum advantages in automata theory [1405.0055][1901.07992][1502.01462][1507.01988].

## 1. Formal Models: Quantum, Probabilistic, and Generalized Finite Automata

QFAs are best understood within a hierarchy of automata models:

- **Generalized Finite Automaton (GFA):** A 5-tuple $(Q, \Sigma, \{A_\sigma\}_{\sigma\in\Sigma}, v_0, f)$ operating over real matrices, computing acceptance via $f \cdot v_n$ after sequentially applying $A_{w_i}$ for input $w = w_1...w_n$.
- **Probabilistic Finite Automaton (PFA):** Restricts each $A_\sigma$ to a column-stochastic $k{\times}k$ matrix, with stochastic initial distribution $v_0$ and final (0-1) accepting vector $f$. PFA acceptance probability remains within $[0,1]$.
- **Moore–Crutchfield QFA (MCQFA):** A tuple $(Q, \Sigma, \{U_\sigma\}, |v_0\rangle, P)$ with $U_\sigma$ unitary, $|v_0\rangle$ a pure quantum state, and projective measurement $P$ at computation end. The acceptance probability for input $w$ is $f_M(w) = \|P_a |v_{|w|}\rangle\|^2$.
- **General QFA (super-operator QFA):** Allows each symbol to implement a general super-operator (CPTP map) acting on a density matrix $\rho$, admitting mixed states and arbitrary measurements, strictly generalizing classical and unitary quantum automata [1405.0055][1901.07992][1406.4048].

Equivalence results show that, with cutpoint acceptance, the language classes defined by GFAs, PFAs, and general QFAs coincide both in the unary case and in general: for any unary input alphabet $\Sigma = \{a\}$,
$$
\text{PseudoS} = S = \text{QAL},\quad \text{UnaryPseudoS} = \text{UnaryS} = \text{UnaryQAL}
$$
where PseudoS denotes pseudo-stochastic (general GFA), S denotes stochastic (PFA), and QAL denotes the class of quantum automaton languages [1405.0055].

## 2. State Complexity and Language Classes on Unary Alphabets

A central result is that **2-state MCQFAs over a unary alphabet can recognize uncountably many languages, parameterized by cutpoint**. The explicit construction is as follows:

Let $\theta/\pi \notin \mathbb{Q}$ be irrational, and define:
- $Q = \{q_1, q_2\}$
- $|v_0\rangle = |q_1\rangle$
- $U_a = R_\theta = \begin{pmatrix} \cos\theta & -\sin\theta \\ \sin\theta & \cos\theta \end{pmatrix}$
- Measurement: $P_a = |q_1\rangle \langle q_1|$

After reading $a^k$, the acceptance probability is $f_M(a^k) = \cos^2(k\theta)$. Since $\{\cos^2(k\theta)\}_{k\in\mathbb{N}}$ is dense in $[0,1]$, varying cutpoint $\lambda \in [0,1)$ yields uncountably many distinct languages $L_\lambda = \{a^k \mid \cos^2(k\theta) > \lambda\}$ [1405.0055][1406.4048].

Classically, 2-state PFAs in the unary case recognize only regular languages. To obtain uncountably many language classes, at least 3 states are required in the PFA model [1405.0055]. In the GFA model (over reals), the same 2-state construction suffices and is optimal.

Summary table:

| Model        | States required for uncountable unary languages | Language class             |
|--------------|-----------------------------------------------|----------------------------|
| MCQFA, GFA   | 2                                             | Uncountable, nonregular    |
| PFA          | 3                                             | Uncountable, nonregular    |
| DFA, NFA     | $\infty$ (cannot realize)                     | Regular only               |

The 1-state M(Q)CFA or PFA can recognize only $\emptyset$ or $a^*$ by cutpoint semantics; hence, 2 is optimal for nontriviality [1405.0055].

## 3. Inclusive/Exclusive Cutpoints and Classification

For any QFA (or PFA, GFA), the notion of language recognition via cutpoints generalizes: for $M$ and $\lambda$, define

- Inclusive: $L(M,= \lambda) = \{w \mid f_M(w) = \lambda \}$
- Exclusive: $L(M, \neq \lambda) = \{w \mid f_M(w) \neq \lambda \}$

For MCQFAs, every language in the exclusive cutpoint class ($MCL^\neq$) can be recognized with exclusive cutpoint $0$, and these automata cannot recognize any nonempty finite language since their acceptance functions are "dense" (no finite language can be separated by cutpoint 0). Thus, $MCL^\neq$ is strictly contained in the general $QAL^\neq$ class [1405.0055].

Together, for any of the models GFA, PFA, QFA,
$$
\text{PseudoS}^= = \text{PseudoS}^\neq = S^= = S^\neq = QAL^= = QAL^\neq
$$
and these classes strictly contain the regular languages; i.e., there exist uncountably many non-regular languages even in inclusive/exclusive cutpoint semantics.

## 4. Succinctness, Expressiveness, and Open Problems

Quantum finite automata, even in their most elementary form, exhibit strict **state succinctness** compared to classical models for particular language families. For example, the language $L_p = \{a^{kp}\mid k\in \mathbb{N}\}$ can be recognized by a 2-state MCQFA with acceptance probability $f(a^n) = \cos^2(n\pi/p)$, giving exact acceptance on multiples of $p$, but requires at least $p$ states for a bounded-error PFA or DFA [1507.01988][2202.04915][2107.02262].

Bounded-error QFAs (constant cutpoint margin) separate the power of quantum and classical models even on **unary promise problems**:
- Promise problems exist such that a 2-state MCQFA solves them with bounded error, while no bounded-error unary PFA can solve them.
- Las Vegas QFAs (never err, "don't know" output allowed) and bounded-error PFAs are equivalent in power to DFAs over unary alphabets [1502.01462].

Open problems include: explicit tight state complexity bounds for QFAs for specific language/promises, extending the separation to non-unary alphabets, and finding natural languages (not promise problems) with exponential classical–quantum separation [1502.01462].

## 5. Generalizations, Alternation, and Nonregularity

Recent research extends QFAs beyond the basic one-way and measure-once models:
- **Measure-many QFAs (MM-1QFA)** can recognize strictly more regular languages than MO-1QFA, and alternating QFA (AQFA) models can recognize some nonregular unary languages such as $\{ a^{m^2}\}$ with bounded alternation [1901.07992][1407.0334].
- **Emptiness** of alternating QFAs (even on unary input and two alternations) is undecidable; for nondeterministic QFAs with rational or algebraic amplitudes it is decidable, contrasting with classical automata [1407.0334].
- The class of languages recognized by $k$-alternation AQFAs on unary alphabets remains incompletely characterized, and it is open how many alternations are necessary to recognize classes including all unary context-free or recursive languages [1407.0334].

## 6. Mathematical and Structural Insights

The key to the expressive power of 2-state unary MCQFAs is the density and aperiodicity of the sequence $\{\cos^2(k\theta) \mid k\in \mathbb{N}\}$ when $\theta/\pi$ is irrational; this sequence is non-periodic and fills $[0,1]$ densely, supporting uncountably many languages via cutpoint separation [1405.0055][1406.4048].

For 1-state pseudo-stochastic automata (GFAs), the recognized language class over general alphabets is exactly those defined by linear inequalities on Parikh vectors together with parity or indicator conditions; for unary input, this reduces to regular threshold languages.

The equivalence of pseudo-stochastic, stochastic, and quantum automata (with cutpoint semantics) fundamentally relies on the ability to encode probabilistic transitions and measurement outcomes as quantum operations (unitary or more generally CPTP maps), and vice versa [1405.0055].

---

**References**  
- "Quantum, Stochastic, and Pseudo Stochastic Languages with Few States" [1405.0055]  
- "Quantum finite automata: survey, status and research directions" [1901.07992]  
- "Unary probabilistic and quantum automata on promise problems" [1502.01462]  
- "Automata and Quantum Computing" [1507.01988]  
- "Quantum finite automata: A modern introduction" [1406.4048]  
- "Alternating, private alternating, and quantum alternating realtime automata" [1407.0334]  
- "Quantum advantage using high-dimensional twisted photons as quantum finite automata" [2202.04915]  
- "Cost-efficient QFA Algorithm for Quantum Computers" [2107.02262]

Source: https://www.emergentmind.com/topics/quantum-finite-automata-qfas