arXiv:2610.40105cs.CCOct 2026

Manuscript Offprint

arXiv:2610.40105

Diagonalization and Undecidability in Semi-Thue Systems

Vesa Halava, Reino Niskanen

Abstract

We revisit classical diagonalization argument in the setting of semi-Thue systems, viewing computation as nondeterministic rewriting rather than sequential machine execution. Semi-Thue systems naturally generate derivation trees, making existential acceptance, reachability, and infinite derivations fundamental computational notions.

We formulate acceptance and decision directly in terms of derivation trees and study the associated assertion, word, and infiniteness problems. We prove that the complements of the assertion and word problems are not recursively enumerable by direct Post-style diagonal arguments. For the infiniteness problem, we give a constructive diagonalization based on a fixed universal semi-Thue system. Unlike the classical approach, the diagonal construction is carried out entirely within the rewriting formalism: the universal system remains an ordinary nondeterministic semi-Thue system while simulating encoded semi-Thue computations, including self-reference.

These results show that undecidability in semi-Thue systems arises naturally from universality and self-reference in nondeterministic rewriting, rather than from machine states or control mechanisms. This perspective clarifies the relationship between rewriting systems, recursive enumerability, and classical diagonal arguments originating in the work of Post and Turing.

1 Introduction

The unifying method behind the earliest undecidability results is diagonalization over effective descriptions of computational processes, conceptually rooted in Cantor's diagonal argument for the uncountability of the real numbers. This idea appears already in Turing's analysis of computable numbers, where the notion of circular-freeness is used to separate computable from non-computable real numbers by an explicit diagonal construction [10]. It is subsequently recast as an explicit decision problem in the formulation of the halting problem for Turing machines, as systematically developed by Davis [1]. Post's separation of recursive and recursively enumerable sets likewise relies on diagonal reasoning, carried out in the formalism of normal systems, an early nondeterministic rewriting model [6].

These results are standardly presented within machine-based formalisms and serve as canonical instances of undecidability obtained by diagonalization.

In this paper we revisit diagonalization in a markedly different computational model, namely semi-Thue systems, whose computations are inherently nondeterministic and tree-like, and whose derivations resemble proof search in a formal logical system rather than sequential machine execution. This perspective is already implicit in Post's use of normal systems as a rewriting formalism for recursively enumerable sets [6], where diagonalization is carried out over derivation trees rather than over machine-input pairs. Our contribution is to make this perspective explicit and systematic, and to formulate diagonal arguments directly at the level of semi-Thue derivations and their acceptance modes.

The first motivation of this work is to recall that diagonalization is not tied to the specific operational structure of Turing machines, but can be carried out directly in rewriting-based models of computation. Semi-Thue systems are among the simplest and most natural such models. They lack states, instruction counters, or explicit control mechanisms, yet they are computationally universal. This raises a conceptual question: how do classical undecidability arguments manifest themselves in a formalism where computation is given by a branching derivation tree rather than a linear run? Indeed, recall that universal Turing machines are deterministic with several papers investigating the boundaries of the universality with respect to the number of states and size of the input alphabet [9, 8, 12]. This makes it seem that the computational universality arises from computational devices that have sufficiently rich underlying structure.

From a contemporary perspective, tree-like and nondeterministic modes of computation are increasingly common. On one hand, they are present in SAT and SMT solvers, where an assignment can be nondeterministically restarted by the solver if the current computation takes too long. On the other hand, many modern computational systems, including large language models and related neural-symbolic architectures, operate operationally as forms of guided, branching search rather than as single linear executions. While such systems are not intended as formal models of effective computation, their prevalence highlights the naturalness of tree-structured computation as a basic computational paradigm.

Our primary technical goal is to give direct proofs of undecidability for natural problems of semi-Thue systems, treating these problems themselves as fundamental sources of undecidability, rather than establishing their undecidability by reduction from previously known undecidable problems for Turing machines. In particular, we study the assertion problem: given a semi-Thue system and a designated start word, does there exist a finite derivation in which a distinguished symbol occurs? This problem captures the recursively enumerable nature of semi-Thue computation in a particularly direct way. While assertion is semi-decidable by systematic enumeration of derivations, we show that it is not decidable; moreover, its complement is not recursively enumerable.

Closely related is the classical word problem for semi-Thue systems: given a system and two words, does there exist a finite derivation transforming one word into the other? Like assertion, the word problem is naturally formulated in existential terms over derivation trees and is therefore recursively enumerable. It provides a canonical notion of reachability in rewriting-based models of computation and serves as a standard benchmark problem for undecidability results in this setting.

We also consider non-termination properties, such as the existence of an infinite derivation. These correspond to non-halting or circular-freeness phenomena in Turing machine models and lie outside the class of recursively enumerable properties. We show that the undecidability of non-termination can likewise be obtained by a direct diagonalization argument using a universal semi-Thue system.

Historically, the approach taken here is closely related to that of Emil Post [5, 6]. In his work on normal systems, Post emphasized generative formalisms and treated computation as the production of assertions rather than as machine execution. Acceptance was represented by the appearance of a distinguished symbol. Our treatment follows this tradition.

At this point it is important to address the notion of control. What is commonly called control in a Turing machine—its states and halting states—is not intrinsic supervision of computation but a convention for communicating the result to an external observer. The machine itself merely follows local rules. The essential difference between Turing machines and semi-Thue systems is that the former compress an unbounded computation into a single finite observable configuration, whereas the latter distribute the result over a potentially infinite set of derivable words.