Set k is recursively enumerable non-recursive
Published May 26, 2022
-
By
Marco Garosi
Set
k in the computability theory is a “special” set, in the sense that it refers to a particular and well-defined set. Set
k is indeed defined as
k={x∣φx(x)↓} — that is, the set of all programs (
x) that halt when they’re passed themselves as input. (Note that this is possible because a program is really just a long binary string — namely, a binary number. That’s why a progam can be “passed” to itself as an input.)
Statement
Set
k={x∣φx(x)↓ } is recursively enumerable (r.e.) but it is not recursive.
Proof
Let’s define the code that implements the mathematical function defined by
k. We’ll call that program
k~:
input(x);if INT(x,x)↓ then output(YES)
Program
INT is nothing but an interpreter. Running an interpreter on program
x and feeding it inpux
x is equivalent to running program
x and passing it input
x, that is:
φINT(x,x)=φx(x).
Now, the function computed by
k~ is:
φk~(x)={1↑if x∈kotherwise
k~'s domain is denoted as
Wk~.
Wk~=k.
Now let’s suppose, for the sake of contradiction, that
kˉ (
k’s complement) is recursively enumerable (r.e.). Then
∃P program (P∈GitHub):WP=kˉ.
Since
kˉ is
k’s complement (that is,
kˉ=N∖k),
kˉ={x∣φx(x)↑}.
Therefore,
P∈kˉ⟺P∈WP. However,
Pinkˉ⟺φP(P)↑ and
P∈WP⟺φP(P)↓. Putting these all together, we get:
φP(P)↑⟺P∈kˉ⟺P∈WP⟺φP(P)↓, which is, of course, a contraditcion. Hence it is the case that
K is r.e. non-recursive.