Is the theory of the category of topological spaces computable?

Let me assume choice. It is possible to distinguish discrete spaces from other spaces: those are precisely the spaces $X$ such that for any epimorphism $f:Y\to X$ admits a section $g:X\to Y$ (i.e. $g\circ f=\mathrm{id}_Y$). To see this, recall first that epimorphisms in Top are just the surjective continuous maps.

If $X$ is discrete, then for any epimorphism $Y\to X$ there is a set-theoretical section by AC, which is automatically continuous.

Conversely, suppose every epimorphism into $X$ splits. Let $Y$ have the same underlying space as $X$, but discrete topology. Then the identity on points is a continuous map from $Y\to X$, and since it's an epimorphism, it admits a section, which shows that $X$ is discrete too.

The subcategory of discrete topological spaces is equivalent to the category of sets, and you already know it's uncomputable. It follows the first-order theory of Top is undecidable.

It's not clear to me if this proof can be modified so as to avoid the use of AC.

Edit: a proof without the use of AC: we will again distinguish the subcategory of discrete spaces. Let $1$ be a one-point space (a terminal object) and $2$ a two-point discrete space (a space with exactly two maps from $1$ to it, and with $4$ maps from it to itself) and $i:1\to 2$ any map. Then $X$ is discrete iff for any map $f:1\to X$ there is a map $g:X\to 2$ such that $g\circ f=i$, and for any $f':1\to X,f'\neq f$, we have $g\circ f'\neq i$.

This expresses that for any point $x\in X$, there is a map $X\to 2$ which takes $x$ to one point, and all other points to a different one. Since $2$ was discrete, this implies $\{x\}$ is open, so $X$ is discrete.

Since you say you know Set has uncomputable theory even without AC, we deduce the same for Top.


Here is a method of defining natural numbers in $\mathbf{Set}$ (without Choice) which generalizes immediately to $\mathbf{Top}$. Namely, we can just express the second-order Peano axioms directly in our categorical language. Let us fix a terminal object $1$. Then we can define the natural numbers as a triple $(N,s,0)$ where $N$ is an object, $0:1\to N$ is a morphism, and $s:N\to N$ is a morphism such that they satisfy the second-order Peano axioms, namely:

  • $s$ is injective (i.e., monic).
  • $0$ is not in the image of $s$ (that is, $0$ cannot be factored as a composition $s\circ f$ for any $f:1\to N$).
  • No proper subobject of $N$ contains $0$ and is closed under $s$. That is, if $i:A\to N$ is any monic morphism such that $0$ factors through $i$ and $s\circ i$ factors through $i$, then $i$ is an isomorphism.

For $\mathbf{Set}$, these properties pick out the usual structure of natural numbers (up to isomorphism), and for $\mathbf{Top}$, they pick out the natural numbers with the discrete topology (proof: given any space $N$ with element $0$ and map $s:N\to N$ satisfying the first two conditions, the subset generated by $0$ under $s$ can be given the discrete topology to get a space $A$ and a continuous injection $i:A\to N$, and then the third condition implies $i$ is an isomorphism).

(As an aside, while these axioms work in $\mathbf{Set}$ or $\mathbf{Top}$, there are other axioms for natural numbers besides the Peano axioms which are more natural from a categorical perspective, such as the notion of a natural numbers object.)

We can then fix any such $(N,s,0)$ and define a natural number as a morphism $1\to N$. We can define morphisms $+:N\times N\to N$ and $\cdot:N\times N\to N$ as the unique morphisms satisfying the usual recursive definitions, and these give binary operations on our natural numbers, so we can interpret arithmetic in our category.