1

I think it's true because you can reduce B to A and then run the probabilistic algorithm of A and if we got a reject then it's also a reject for B and at least half of the time if the input is in A we would get an accept which means that at least half of the time if the input is in B we would get an accept. So B is in RP, but I'm not sure.

What happens if the reduction is the other way around? If A is in RP and there is a polynomial time reduction from A to B, then is B in RP?

Berthur
  • 4,300
  • 2
  • 14
  • 28
yftach
  • 31
  • 2

1 Answers1

1

Reduction from B to A:

There's a catch. What if all instances of B happen to map to an instance of A that rejects? :)

This can happen, because B might still have over 50% true instances that accept, but which are just not in the image of your reduction.

Reduction from A to B:

As for your second question, consider this: We can reduce A to the halting problem as follows:

  1. Run our RP algorithm for a.
  2. If the answer is yes, return yes. Otherwise, go into an infinite loop.

Does this mean the halting problem is in RP? :)

Berthur
  • 4,300
  • 2
  • 14
  • 28
  • And what if the reduction was the opposite way? – yftach Jun 02 '22 at 13:13
  • @yftach I made an edit to address that question too. – Berthur Jun 02 '22 at 14:53
  • I have been thinking about this for a few hours and I'm still not sure. The first question I think I understand, but the second I still don't get. – yftach Jun 02 '22 at 21:24
  • @yftach Basically, just because you can turn problem A into problem B, doesn't magically tell us anything about problem B's complexity. In my example above, we successfully reduce A to the halting problem, which is an unsolvable problem (infinite time complexity, if you will). – Berthur Jun 03 '22 at 10:20