358 Hints and Solutions
whenever p would. Whenever p
is simulating p on (, β)and is a
statement of the form :
i
∨
j
, p
just deletes (, β) from the list
and replaces it with (
i
,β)and(
j
,β). The equivalence of these two
computations might be called iterated distributivity. The program
p
has only simple assignments y := e(y) and universal assignments
y := ∀. Finally, p
halts and accepts if any one of the configurations
it is simulating is an accept statement.
(b) To show that the problem of deciding whether a given recursive
relation is well-founded is Π
1
1
-hard, observe that the computation
tree of p
on any input is a recursive tree, and is well-founded iff
p
accepts. But p
accepts iff the original program p accepts, and
acceptance of IND programs is Π
1
1
-hard, because by Kleene’s theo-
rem (Theorem 40.1) IND programs accept exactly the Π
1
1
relations
over N.
The problem is also in Π
1
1
, because it is accepted by an IND pro-
gram, as shown in Lecture 39.
2. Our plan is to use the lazy conditional test
ϕ
cond(i,j)
(x, y)=
ϕ
i
(y), if x =0,
ϕ
j
(y), if x =0
of Miscellaneous Exercise 111 and the recursion theorem (Theorem 33.1)
to construct a function h such that
h(x, y)=
y, if f(x, y)=0,
h(x, y +1), if f(x, y) =0,
(12)
then take
g(x)
def
= h(x, 0).
Let j, a, b, s,andi be indices for f , π
2
1
, π
2
2
, the successor function, and
the identity function, respectively, and let
σ(x)=pair(cond(b, comp(j, pair(a, comp(s, b)))), pair (x, i)). (13)
The function σ is total, therefore has a fixpoint h = ϕ
x
= ϕ
σ(x)
by the
recursion theorem, thus
h = ϕ
x
= ϕ
pair(cond(b,comp(j,pair(a,comp(s,b)))),pair(x,i))
.
To make a long story short, unwinding the definitions gives exactly (12).