Final Exam Problems - Computability and Complexity | CS 590, Exams of Computer Science

Material Type: Exam; Class: Computability and Complexity; Subject: Computer Science; University: University of Idaho; Term: Unknown 1993;

Typology: Exams

Pre 2010

Uploaded on 09/17/2009

koofers-user-rnf
koofers-user-rnf 🇺🇸

10 documents

1 / 4

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
1
CS 590 Final Name:
This is a closed bo ok, closed notes examination, with the following ex-
ception: you may refer to a single 8.5x11 inch (or A4) sheet of notes|with
anything on it whichyou think might be useful. You may also use as much
blank scratch paper as you need.
This exam is worth 100 points, and each problem is worth 10 points.
It is a two hour exam.
Note: answers with proofs, or at least plausible arguments, will receive
more credit than those without.
CS 590 Theory of Computation. Test T
May 1993
Problem T-1:
Let
Fin
=
f
e
:
W
e
is nite
g
.Is
Fin
recursive?
Answer:
Fin
is a non-trivial index set, so it is not recursive by Rice's theorem.
Problem T-2:
Construct a set which is undecidable relativeto
K
|that is, it is unde-
cidable even when
K
is used as an oracle. (Hint: diagonalize).
Answer:
Let
W
e
(
K
)
be the set you can recognize with Turing machine
M
e
and oracle
K
. Let
K
(
K
)=
f
e
:
e
62
W
e
(
K
)
g
.
K
(
K
)
cannot be recognized by any machine
M
e
even with the oracle, since it diers from every such set on the value
e
.
Problem T-3:
Prove that there is a total, recursive function
m
such that
E
m
(
x
)
=
f
0
;
1
;
2
x
;
3
x
;:::
g
Answer:
Let
m
be such that
m
(
x
)
(
y
)=
y
x
.
There is an
f
as required.
pf3
pf4

Partial preview of the text

Download Final Exam Problems - Computability and Complexity | CS 590 and more Exams Computer Science in PDF only on Docsity!

CS 590 Final Name: This is a closed b o ok, closed notes examination, with the following ex- ception: you may refer to a single 8.5x11 inch (or A4) sheet of notes|with anything on it which you think might b e useful. You may also use as much blank scratch pap er as you need. This exam is worth 100 p oints, and each problem is worth 10 p oints. It is a two hour exam. Note: answers with pro ofs, or at least plausible arguments, will receive more credit than those without.

CS 590 Theory of Computation. Test T

May 1993

Problem T-1: Let F in = fe : We is niteg. Is F in recursive?

Answer: F in is a non-trivial index set, so it is not recursive by Rice's theorem.

Problem T-2: Construct a set which is undecidable relative to K |that is, it is unde- cidable even when K is used as an oracle. (Hint: diagonalize).

Answer: Let We (K ) b e the set you can recognize with Turing machine Me and oracle K. Let K (K ) = fe : e 62 We (K )g. K (K ) cannot b e recognized by any machine Me even with the oracle, since it di ers from every such set on the value e.

Problem T-3: Prove that there is a total, recursive function m such that

Em(x) = f 0 ; 1 ; 2 x^ ; 3 x^ ; : : :g

Answer: Let m b e such that m(x) (y ) = y x^. There is an f as required.

Problem T-4: Prove that if LO G = N LO G then D S P AC E (n) = N S P AC E (n).

Answer: A simple padding argument.

Problem T-5: Prove that there is an oracle A such that P (A) = P H (A). (Hint: P H (A)  P S P AC E (A) for all A).

Answer: Let A = QB F. Then P (A)  P H (A)  P S P AC E (A) = P S P AC E  P (A) The rst relation follows from the fact that  0 p (A) = P (A)   pk (A)  P H (A) for any oracle A|which follows from the fact that the pro of of Wrathall's theorem relativizes. Similarly, P H (A)  P S P AC E (A) for any oracle, since the pro of that P H  P S P AC E relativizes. We know that P S P AC E (QB F ) = P S P AC E as we saw in class. The last relation follows from the fact that every set in PSPACE is decidable in p olynomial time with access to QBF, since QBF is PSPACE-complete.

Problem T-6: Supp ose the function f is computable using p olynomial time (i.e., f 2 P F ). How complex is the set Gf = fy : f (x) = y for some xg?

Answer: It is in N P by Wrathall's theorem, since

Gf = fy : 9 p^ x(f (x) = y )g

and the predicate in parentheses is p olynomial time decidable. Note that f (x) is at most p olynomial longer than x, since only p olynomial time is available to compute f. That is, for some p olynomial p, jxj  p(jf (x)j).

Problem T-7: Prove that pm is re exive and transitive (i.e., for any A, B , and C , A pm A and if A pm B and B pm C then A pm C ).

Answer: See the b o ok.

Reject Else reject Accept

This algorithm is clearly p olynomial time, since each simulation is p olynomial time. It is correct b ecause it can guess an accepting path only if one exists, in which case x 62 A. On the other hand, if no accepting path exists, in which case x 2 A, then this algorithm accepts. So, this is an N P algorithm for A. So, A 2 N P P and N P 6 = P.

Answer: First, the enumeration of DTMs may not b e e ective in p oly time, so verifying the guess may not b e p oly time since just getting a description of Mn from n may take to o long. Second, even if a go o d enumeration were chosen, the length of the compu- tation path is the p olynomial b ounding Mn , and this will di er from machine to machine. So, we cannot conclude that there is a single p olynomial which b ounds the runtime of this algorithm.