← Lambdica / theory-of-computation

Decidability

Also known as: recursive, Turing-decidable, recursive set

A problem is decidable when a Turing machine exists that halts on every input and correctly classifies it as a yes-instance or a no-instance.

Formal definition

Let Σ\Sigma be a finite alphabet and LΣL \subseteq \Sigma^* a language. LL is decidable iff there exists a Turing machine MM such that, for every input string wΣw \in \Sigma^*,

M halts on wandM accepts w    wL.M \text{ halts on } w \quad \text{and} \quad M \text{ accepts } w \iff w \in L.

Equivalently, the characteristic function

χL:Σ{0,1},χL(w)={1wL0wL\chi_L : \Sigma^* \to \{0, 1\}, \qquad \chi_L(w) = \begin{cases} 1 & w \in L \\ 0 & w \notin L \end{cases}

is total computable: some Turing machine, given ww, outputs χL(w)\chi_L(w) in finite time for every ww, with no exceptions.

The class of decidable languages is traditionally denoted R\mathsf{R} (or REC\mathsf{REC}). In Kleene’s terminology it is the class of recursive sets, which is why decidable and recursive are synonymous across most of the literature.

Intuition

Decidability is the strictest form of algorithmic tractability that computability theory recognizes. It demands totality: not merely that the algorithm answers eventually on the yes-instances, but that it answers always — on yes-instances, no-instances, and everything in between — without ever looping forever.

This totality is precisely what separates R\mathsf{R} from the larger class RE\mathsf{RE} of recognizable (or recursively enumerable) languages. A recognizer is permitted to loop silently on strings outside the language; a decider must reject them explicitly. The gap between the two is exactly where the halting problem lives: HALTRER\text{HALT} \in \mathsf{RE} \setminus \mathsf{R}. Every decidable language is recognizable, but the converse fails, and it fails specifically because of diagonalization.

Decidability is a property of the language, not of any particular algorithm deciding it. Once some machine is shown to decide LL, the problem is closed: every other correct decider for LL joins the club automatically, regardless of how it works internally. Decidability asserts the existence of a method; it says nothing about any specific method’s cleverness or cost.

Examples

Decidable:

Undecidable:

Notes

The term recursive has nothing to do with recursion as self-reference in programming. It comes from Kleene’s work in the 1930s and 1940s on recursive function theory, where a recursive set is one whose characteristic function is built up from primitive recursion, composition, and the μ\mu-operator. The accidental clash with the programming-language sense of the word is unfortunate enough that modern textbooks increasingly prefer decidable and recognizable over recursive and recursively enumerable — though both pairs remain in active use, especially in proof theory and recursion theory.

By the Church–Turing thesis, decidability is independent of the model of computation. A language decidable by a Turing machine is decidable by a λ\lambda-calculus reduction strategy, by the μ\mu-recursive functions, by a random-access machine, by a Post production system, by any of the other formalisms known to compute the same class. All of them define the same R\mathsf{R}. This invariance is the essential content of Church 1936 and Turing 1936 taken jointly, and it is why decidability is treated as a property of the problem rather than of any particular piece of machinery.

Connections

depends_on

References

  • turing-1936-computable
  • church-1936-unsolvable
  • kleene-1952-metamathematics
  • sipser-2013-introduction