Does my solution show that the language is uncomputable by applying rice's theorem?
up vote
2
down vote
favorite
If p is a Turing machine then L(p) = {x | p(x) = yes}.
Let A = {p | p is a Turing machine and L(p) is a finite set}.
Is A computable? Justify your answer.
So I'm trying to figure out how to solve this question and here is the answer that I've come up with:
(i) So we know that A is a non-trivial problem since some turing machines L(p) is a finite state and some turing machines where L(p) is not a finite state.
(ii) A respects equivalence when given any 2 equivalent turing machines p and q.
p ε A ⇒ p is a turing machine and L(p) is a finite set
⇒ q is a turing machine and L(q) is a finite set
⇒ q ε A
Therefore, by applying Rice's theorem we can see that A is uncomputable.
discrete-mathematics computability automata turing-machines
New contributor
add a comment |
up vote
2
down vote
favorite
If p is a Turing machine then L(p) = {x | p(x) = yes}.
Let A = {p | p is a Turing machine and L(p) is a finite set}.
Is A computable? Justify your answer.
So I'm trying to figure out how to solve this question and here is the answer that I've come up with:
(i) So we know that A is a non-trivial problem since some turing machines L(p) is a finite state and some turing machines where L(p) is not a finite state.
(ii) A respects equivalence when given any 2 equivalent turing machines p and q.
p ε A ⇒ p is a turing machine and L(p) is a finite set
⇒ q is a turing machine and L(q) is a finite set
⇒ q ε A
Therefore, by applying Rice's theorem we can see that A is uncomputable.
discrete-mathematics computability automata turing-machines
New contributor
add a comment |
up vote
2
down vote
favorite
up vote
2
down vote
favorite
If p is a Turing machine then L(p) = {x | p(x) = yes}.
Let A = {p | p is a Turing machine and L(p) is a finite set}.
Is A computable? Justify your answer.
So I'm trying to figure out how to solve this question and here is the answer that I've come up with:
(i) So we know that A is a non-trivial problem since some turing machines L(p) is a finite state and some turing machines where L(p) is not a finite state.
(ii) A respects equivalence when given any 2 equivalent turing machines p and q.
p ε A ⇒ p is a turing machine and L(p) is a finite set
⇒ q is a turing machine and L(q) is a finite set
⇒ q ε A
Therefore, by applying Rice's theorem we can see that A is uncomputable.
discrete-mathematics computability automata turing-machines
New contributor
If p is a Turing machine then L(p) = {x | p(x) = yes}.
Let A = {p | p is a Turing machine and L(p) is a finite set}.
Is A computable? Justify your answer.
So I'm trying to figure out how to solve this question and here is the answer that I've come up with:
(i) So we know that A is a non-trivial problem since some turing machines L(p) is a finite state and some turing machines where L(p) is not a finite state.
(ii) A respects equivalence when given any 2 equivalent turing machines p and q.
p ε A ⇒ p is a turing machine and L(p) is a finite set
⇒ q is a turing machine and L(q) is a finite set
⇒ q ε A
Therefore, by applying Rice's theorem we can see that A is uncomputable.
discrete-mathematics computability automata turing-machines
discrete-mathematics computability automata turing-machines
New contributor
New contributor
New contributor
asked 2 days ago
ken6208
132
132
New contributor
New contributor
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
up vote
0
down vote
accepted
Yes, you are right that Rice's theorem applies here and implies $A$ is not computable.
For a direct reduction to the halting problem (which is really nothing more than the proof of Rice's theorem specialized to this particular case), given a program $a$ and input $i,$
- write a program that, for any input $j$, first runs $a$ on input $i$ and
then (if it finishes) returns $1,$ and then - use the oracle for $A$ to analyze this program to decide whether it
accepts only finitely many inputs or not, returning $0$ if it does,
and $1$ if it doesn't.
It's clear that this inner program is equivalent to "return $1$" if $a$ halts on input $i$ and equivalent to "loop" if it doesn't. And "return $1$" accepts infinitely many inputs (all of them) whereas "loop" accepts only finitely many (none).
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
0
down vote
accepted
Yes, you are right that Rice's theorem applies here and implies $A$ is not computable.
For a direct reduction to the halting problem (which is really nothing more than the proof of Rice's theorem specialized to this particular case), given a program $a$ and input $i,$
- write a program that, for any input $j$, first runs $a$ on input $i$ and
then (if it finishes) returns $1,$ and then - use the oracle for $A$ to analyze this program to decide whether it
accepts only finitely many inputs or not, returning $0$ if it does,
and $1$ if it doesn't.
It's clear that this inner program is equivalent to "return $1$" if $a$ halts on input $i$ and equivalent to "loop" if it doesn't. And "return $1$" accepts infinitely many inputs (all of them) whereas "loop" accepts only finitely many (none).
add a comment |
up vote
0
down vote
accepted
Yes, you are right that Rice's theorem applies here and implies $A$ is not computable.
For a direct reduction to the halting problem (which is really nothing more than the proof of Rice's theorem specialized to this particular case), given a program $a$ and input $i,$
- write a program that, for any input $j$, first runs $a$ on input $i$ and
then (if it finishes) returns $1,$ and then - use the oracle for $A$ to analyze this program to decide whether it
accepts only finitely many inputs or not, returning $0$ if it does,
and $1$ if it doesn't.
It's clear that this inner program is equivalent to "return $1$" if $a$ halts on input $i$ and equivalent to "loop" if it doesn't. And "return $1$" accepts infinitely many inputs (all of them) whereas "loop" accepts only finitely many (none).
add a comment |
up vote
0
down vote
accepted
up vote
0
down vote
accepted
Yes, you are right that Rice's theorem applies here and implies $A$ is not computable.
For a direct reduction to the halting problem (which is really nothing more than the proof of Rice's theorem specialized to this particular case), given a program $a$ and input $i,$
- write a program that, for any input $j$, first runs $a$ on input $i$ and
then (if it finishes) returns $1,$ and then - use the oracle for $A$ to analyze this program to decide whether it
accepts only finitely many inputs or not, returning $0$ if it does,
and $1$ if it doesn't.
It's clear that this inner program is equivalent to "return $1$" if $a$ halts on input $i$ and equivalent to "loop" if it doesn't. And "return $1$" accepts infinitely many inputs (all of them) whereas "loop" accepts only finitely many (none).
Yes, you are right that Rice's theorem applies here and implies $A$ is not computable.
For a direct reduction to the halting problem (which is really nothing more than the proof of Rice's theorem specialized to this particular case), given a program $a$ and input $i,$
- write a program that, for any input $j$, first runs $a$ on input $i$ and
then (if it finishes) returns $1,$ and then - use the oracle for $A$ to analyze this program to decide whether it
accepts only finitely many inputs or not, returning $0$ if it does,
and $1$ if it doesn't.
It's clear that this inner program is equivalent to "return $1$" if $a$ halts on input $i$ and equivalent to "loop" if it doesn't. And "return $1$" accepts infinitely many inputs (all of them) whereas "loop" accepts only finitely many (none).
edited yesterday
answered yesterday
spaceisdarkgreen
31.2k21552
31.2k21552
add a comment |
add a comment |
ken6208 is a new contributor. Be nice, and check out our Code of Conduct.
ken6208 is a new contributor. Be nice, and check out our Code of Conduct.
ken6208 is a new contributor. Be nice, and check out our Code of Conduct.
ken6208 is a new contributor. Be nice, and check out our Code of Conduct.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f2997747%2fdoes-my-solution-show-that-the-language-is-uncomputable-by-applying-rices-theor%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown