This preview shows pages 1–2. Sign up to view the full content.
University of Central Florida
School of Computer Science
COT 4210
Spring 2004
Prof. Rene Peralta
Homework 7: answers
1. The following is a hierarchy of subsets of
IN
.
regular
j
CFL
j
recursive
j
re.
j
P
(
IN
)
Show that the hierarchy is proper by giving examples of sets contained
in each level but not in the next one.
answer:
The question is poorly worded, apologies. But what I wanted
was explained in class:
1
• {
(2
n

1)2
n

1

n
≥
1
}
is contextfree but not regular.
• {
2
n
2

n
≥
0
}
is recursive but not contextfree.
•
Let
C
i
be the
i
th
C
program in some canonical ordering. Then
{
2
i
3
j

C
i
halts on input
j
}
is recursively enumerable but not re
cursive; and
{
2
i
3
j

C
i
loops on input
j
}
is not recursively enu
merable.
2. In this question, let
M
be a Turing machine which takes as input
a positive integer
i
and outputs (if it halts) a positive integer
M
(
i
).
Denote by
This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
This is the end of the preview. Sign up
to
access the rest of the document.
 Spring '08
 Staff
 Computer Science

Click to edit the document details