1 00:00:00,000 --> 00:00:25,140 [SQUEAKING] [RUSTLING] [CLICKING] 2 00:00:25,140 --> 00:00:27,140 PROFESSOR: All righty, why don't we get started. 3 00:00:31,200 --> 00:00:33,620 So welcome back. 4 00:00:33,620 --> 00:00:36,590 Nice to see you all. 5 00:00:36,590 --> 00:00:42,290 And what have we been doing in theory of computation? 6 00:00:42,290 --> 00:00:46,160 We have been talking about Turing machines 7 00:00:46,160 --> 00:00:50,750 and about the power of Turing machines. 8 00:00:50,750 --> 00:00:55,370 We started at the beginning by showing 9 00:00:55,370 --> 00:00:58,580 a bunch of decidability theorems that 10 00:00:58,580 --> 00:01:00,620 exhibit the power of Turing machines 11 00:01:00,620 --> 00:01:08,160 to calculate properties of finite automata, 12 00:01:08,160 --> 00:01:12,130 context free grammars, and so on in some cases. 13 00:01:12,130 --> 00:01:15,780 And last lecture, we talked about the limitations 14 00:01:15,780 --> 00:01:20,670 of the power of Turing machines by proving 15 00:01:20,670 --> 00:01:22,470 undecidability theorems. 16 00:01:22,470 --> 00:01:25,860 So we showed that this language A TM, 17 00:01:25,860 --> 00:01:29,280 the acceptance problem for Turing machines itself 18 00:01:29,280 --> 00:01:31,650 is an undecidable problem. 19 00:01:31,650 --> 00:01:33,660 That was the first of many undecidable problems 20 00:01:33,660 --> 00:01:35,790 that we're going to encounter. 21 00:01:35,790 --> 00:01:39,540 And though we proved the undecidability 22 00:01:39,540 --> 00:01:41,430 of A TM using the diagonalization 23 00:01:41,430 --> 00:01:44,160 method as hopefully you remember, 24 00:01:44,160 --> 00:01:46,140 we're going to introduce a new method which 25 00:01:46,140 --> 00:01:48,420 we kind of basically previewed last time 26 00:01:48,420 --> 00:01:50,430 called the reducibility method, which 27 00:01:50,430 --> 00:01:52,440 is the way other problems are typically 28 00:01:52,440 --> 00:01:56,420 shown to be undecidable. 29 00:01:56,420 --> 00:02:00,010 And so we're going to stick with that for this lecture 30 00:02:00,010 --> 00:02:01,850 and also next lecture. 31 00:02:01,850 --> 00:02:04,870 We're going to be talking about undecidability. 32 00:02:04,870 --> 00:02:08,889 And I think there's going to be a few additional discussions 33 00:02:08,889 --> 00:02:09,860 after that. 34 00:02:09,860 --> 00:02:12,970 But this is one of the important themes 35 00:02:12,970 --> 00:02:15,520 of the course is to understand that threshold 36 00:02:15,520 --> 00:02:18,160 between decidability and undecidability, 37 00:02:18,160 --> 00:02:23,780 or the limitations of computation, OK. 38 00:02:23,780 --> 00:02:26,300 So today, as I mentioned, we're going 39 00:02:26,300 --> 00:02:28,010 to talk about the reducibility method 40 00:02:28,010 --> 00:02:30,290 for proving problems undecidable and also 41 00:02:30,290 --> 00:02:34,760 for proving problems non-turing recognizable, 42 00:02:34,760 --> 00:02:36,590 Turing unrecognizable. 43 00:02:36,590 --> 00:02:39,110 We're going to introduce this notion 44 00:02:39,110 --> 00:02:41,960 of a reducibility in general. 45 00:02:41,960 --> 00:02:44,120 And we'll also talk about a very specific kind 46 00:02:44,120 --> 00:02:46,680 of reducibility called the mapping reducibility. 47 00:02:46,680 --> 00:02:48,650 So today as promised, we're going 48 00:02:48,650 --> 00:02:51,230 to talk about using reducibilities 49 00:02:51,230 --> 00:02:56,030 to prove problems are undecidable, or unrecognizable. 50 00:02:56,030 --> 00:02:58,820 So that's going to be our general method, 51 00:02:58,820 --> 00:03:02,060 oops, make myself smaller, thank you. 52 00:03:02,060 --> 00:03:04,580 I always forget. 53 00:03:04,580 --> 00:03:06,755 Thank you for the reminder. 54 00:03:10,980 --> 00:03:17,040 So using reducibilities to prove problems are undecidable, 55 00:03:17,040 --> 00:03:21,163 or unrecognizable, and the basic way that works 56 00:03:21,163 --> 00:03:23,580 is we're going to leverage another some problem we already 57 00:03:23,580 --> 00:03:26,790 know is undecidable say, or unrecognizable 58 00:03:26,790 --> 00:03:29,280 to prove other problems are unrecognizable. 59 00:03:29,280 --> 00:03:31,140 So we did a quick example of that last time. 60 00:03:31,140 --> 00:03:33,690 We're going to go over that example again just 61 00:03:33,690 --> 00:03:35,190 to set the stage. 62 00:03:35,190 --> 00:03:38,830 And then we're going to talk about that in greater detail. 63 00:03:38,830 --> 00:03:42,370 So as you recall from last time, we 64 00:03:42,370 --> 00:03:44,890 had this problem HALT TM, which is 65 00:03:44,890 --> 00:03:47,410 the problem of testing for a given Turing 66 00:03:47,410 --> 00:03:49,450 machine and an input to that Turing machine, 67 00:03:49,450 --> 00:03:51,640 whether the Turing machine halts, 68 00:03:51,640 --> 00:03:55,570 either accepting or rejecting, but just whether it halts. 69 00:03:55,570 --> 00:03:57,850 Which is a somewhat different problem, closely related 70 00:03:57,850 --> 00:04:00,160 obviously, but somewhat different than the A TM 71 00:04:00,160 --> 00:04:02,740 problem, which is just testing whether the Turing 72 00:04:02,740 --> 00:04:04,900 machine accepts. 73 00:04:04,900 --> 00:04:09,100 We already showed that A TM is undecidable. 74 00:04:09,100 --> 00:04:14,200 Now, conceivably, HALT TM might be decidable. 75 00:04:14,200 --> 00:04:16,390 You know, it's not exactly the same problem. 76 00:04:16,390 --> 00:04:19,000 But we're going to show that HALT TM is likewise 77 00:04:19,000 --> 00:04:20,360 undecidable. 78 00:04:20,360 --> 00:04:23,962 We did this last time, but I'm just going over it again. 79 00:04:23,962 --> 00:04:26,700 I'm going to likewise show that HALT TM is undecidable. 80 00:04:26,700 --> 00:04:30,480 We could go back to the diagonalization method 81 00:04:30,480 --> 00:04:31,710 and do it from scratch. 82 00:04:31,710 --> 00:04:34,140 But generally, that's not what's done. 83 00:04:34,140 --> 00:04:37,680 Generally what people do is they use a reducibility from a known 84 00:04:37,680 --> 00:04:39,340 undecidable problem. 85 00:04:39,340 --> 00:04:42,120 And so what we're going to show is a proof by contradiction 86 00:04:42,120 --> 00:04:49,840 which says that if HALT TM were decidable, 87 00:04:49,840 --> 00:04:51,730 then A TM would also be decidable. 88 00:04:51,730 --> 00:04:53,380 And we know it isn't. 89 00:04:53,380 --> 00:04:56,860 And that's by virtue of what we call a reducibility from A TM 90 00:04:56,860 --> 00:04:57,557 to HALT TM. 91 00:04:57,557 --> 00:04:59,140 And I'll explain with the terminology. 92 00:04:59,140 --> 00:05:01,870 And we'll have a chance to play with the concept 93 00:05:01,870 --> 00:05:03,640 all lecture long. 94 00:05:03,640 --> 00:05:07,720 So we're going to see all sorts of different variations. 95 00:05:07,720 --> 00:05:10,553 So as I said, we'll assume HALT TM is decidable 96 00:05:10,553 --> 00:05:12,970 and use that to show that A TM is decidable, which we know 97 00:05:12,970 --> 00:05:15,320 is not true. 98 00:05:15,320 --> 00:05:17,560 So quickly going through it because we did it already 99 00:05:17,560 --> 00:05:20,830 once before, we're going to assume 100 00:05:20,830 --> 00:05:22,780 that HALT TM is decidable. 101 00:05:22,780 --> 00:05:27,460 Let's say Turing machine R is the decider. 102 00:05:27,460 --> 00:05:28,960 And now we're going to show that ATM 103 00:05:28,960 --> 00:05:32,640 is decidable by constructing a Turing machine S, 104 00:05:32,640 --> 00:05:37,010 which uses R to decide A TM. 105 00:05:37,010 --> 00:05:39,730 That's going to be our contradiction. 106 00:05:39,730 --> 00:05:43,610 So here is the machine S. 107 00:05:43,610 --> 00:05:48,650 You have to keep in mind what the goal of S is. 108 00:05:48,650 --> 00:05:53,640 We're going to design S to solve A TM, which 109 00:05:53,640 --> 00:05:54,700 we know is not decidable. 110 00:05:54,700 --> 00:05:56,070 So don't get confused by that. 111 00:05:56,070 --> 00:05:59,500 We're aiming for a contradiction. 112 00:05:59,500 --> 00:06:02,227 So we're going to use S as typically-- 113 00:06:02,227 --> 00:06:03,810 well, there might be other variations. 114 00:06:03,810 --> 00:06:08,320 But for now, S is going to be used to decide A TM. 115 00:06:08,320 --> 00:06:12,280 So we can try to figure out, how can we decide A TM. 116 00:06:12,280 --> 00:06:20,050 And the way we're going to do it is use our HALT TM tester 117 00:06:20,050 --> 00:06:23,480 that we assumed to have. 118 00:06:23,480 --> 00:06:26,910 And we'll first take our M and w, 119 00:06:26,910 --> 00:06:29,970 where we're trying to determine, does M accept w? 120 00:06:29,970 --> 00:06:33,000 And we'll first test whether M halts on w. 121 00:06:33,000 --> 00:06:34,950 If it doesn't, we're done. 122 00:06:34,950 --> 00:06:37,170 Because it couldn't be accepting w, 123 00:06:37,170 --> 00:06:39,450 M couldn't be accepting w if it's not even 124 00:06:39,450 --> 00:06:40,620 just halting on w. 125 00:06:43,380 --> 00:06:50,210 So if R reports doesn't hold, we can reject right off. 126 00:06:50,210 --> 00:06:55,580 But even if R says it does halt, we're still in good shape 127 00:06:55,580 --> 00:06:59,120 because now we can run M on w until completion 128 00:06:59,120 --> 00:07:02,800 because R has promised us that it's going to halt. 129 00:07:02,800 --> 00:07:04,030 R is stated. 130 00:07:04,030 --> 00:07:06,060 And R is assumed to be correct. 131 00:07:06,060 --> 00:07:08,925 R is stated that M halts on w, so now we 132 00:07:08,925 --> 00:07:10,300 don't have to worry about getting 133 00:07:10,300 --> 00:07:12,220 into a loop, which we're not allowed to do 134 00:07:12,220 --> 00:07:14,500 since we're making a decider. 135 00:07:14,500 --> 00:07:16,720 We're trying to decide A TM here. 136 00:07:16,720 --> 00:07:18,640 But now we can run them on w to completion. 137 00:07:18,640 --> 00:07:21,220 We can find out what M does on w. 138 00:07:21,220 --> 00:07:22,878 And then we can act accordingly. 139 00:07:25,630 --> 00:07:29,220 So we're using the HALT TM decider to decide A TM. 140 00:07:29,220 --> 00:07:32,700 That's the name of the game here, OK? 141 00:07:32,700 --> 00:07:34,210 And that's a contradiction. 142 00:07:34,210 --> 00:07:37,133 And so therefore our assumption that HALT TM was decidable 143 00:07:37,133 --> 00:07:37,800 had to be false. 144 00:07:37,800 --> 00:07:39,300 So it's undecidable. 145 00:07:39,300 --> 00:07:41,070 OK? 146 00:07:41,070 --> 00:07:44,550 Important to understand this because this 147 00:07:44,550 --> 00:07:52,620 is sort of the prototype for all of the other undecidability 148 00:07:52,620 --> 00:07:54,810 proofs that we're going to do going forward. 149 00:07:54,810 --> 00:07:57,210 OK, so we can just take a few seconds here. 150 00:07:57,210 --> 00:08:00,840 If there's something that you're not getting about this, 151 00:08:00,840 --> 00:08:02,010 it's a good time to ask. 152 00:08:07,660 --> 00:08:12,760 Not seeing many messages here, or any, so why don't we go on? 153 00:08:12,760 --> 00:08:17,410 But if you ask, I can get to it next slide too, all right. 154 00:08:17,410 --> 00:08:18,050 Here we go. 155 00:08:18,050 --> 00:08:22,420 So here's the concept of reducibility. 156 00:08:22,420 --> 00:08:24,420 And I know, I've taught this course, many times. 157 00:08:24,420 --> 00:08:27,960 I know where the bumpy places are 158 00:08:27,960 --> 00:08:30,900 in terms of people struggling with material. 159 00:08:30,900 --> 00:08:37,750 The concept of reducibility is a bit tricky. 160 00:08:37,750 --> 00:08:40,890 So don't feel bad if you don't get it right away. 161 00:08:40,890 --> 00:08:42,390 You know, so that's why I'm going 162 00:08:42,390 --> 00:08:44,340 to try to go slowly in this lecture 163 00:08:44,340 --> 00:08:46,890 to make sure we're all together on understanding 164 00:08:46,890 --> 00:08:50,050 how reducibility works. 165 00:08:50,050 --> 00:08:52,300 OK, so the concept of reducibility 166 00:08:52,300 --> 00:08:55,870 is that we say one problem is reducible to another, 167 00:08:55,870 --> 00:08:59,470 say A reducible to B. It means that you 168 00:08:59,470 --> 00:09:04,700 can use B to solve A. That's what it means 169 00:09:04,700 --> 00:09:08,930 for A to be reducible to B. 170 00:09:08,930 --> 00:09:11,720 OK, so I'm going to give a bunch of sort 171 00:09:11,720 --> 00:09:16,090 of informal examples of that, or easy examples of that. 172 00:09:16,090 --> 00:09:19,450 And then we'll start to use it for real. 173 00:09:19,450 --> 00:09:23,733 So example 1, this is sort of really outside material 174 00:09:23,733 --> 00:09:24,400 from the course. 175 00:09:24,400 --> 00:09:28,375 But I think it's something you can appreciate. 176 00:09:28,375 --> 00:09:29,750 You know, everybody knows you can 177 00:09:29,750 --> 00:09:34,310 measure the area of a rectangle by measuring 178 00:09:34,310 --> 00:09:40,040 the lengths of the two sides, measuring the length 179 00:09:40,040 --> 00:09:43,920 and width of the rectangle. 180 00:09:43,920 --> 00:09:46,670 So in other words, if you had the problem 181 00:09:46,670 --> 00:09:51,320 of determining the area, you could reduce that problem 182 00:09:51,320 --> 00:09:53,600 to the problem of measuring the length 183 00:09:53,600 --> 00:09:57,340 and width of the rectangle. 184 00:09:57,340 --> 00:10:01,110 So here, we're taking one problem 185 00:10:01,110 --> 00:10:02,970 and reducing it to another problem. 186 00:10:02,970 --> 00:10:04,890 You know, it's conceivable that measuring 187 00:10:04,890 --> 00:10:10,890 the length and width is easier than it would 188 00:10:10,890 --> 00:10:14,580 be to measure the area directly by somehow covering 189 00:10:14,580 --> 00:10:22,090 the space with tiles, is one way of measuring it. 190 00:10:22,090 --> 00:10:25,605 But it tells you, you don't have to do that. 191 00:10:25,605 --> 00:10:26,980 The problem of measuring the area 192 00:10:26,980 --> 00:10:29,050 is easier than covering with tiles. 193 00:10:29,050 --> 00:10:32,820 You can just measure the length and width and you're done. 194 00:10:32,820 --> 00:10:34,800 So reducibility is a way of making 195 00:10:34,800 --> 00:10:44,357 problems easier by translating them into some easier problem. 196 00:10:44,357 --> 00:10:46,440 So here's another example that we've already seen. 197 00:10:46,440 --> 00:10:48,510 We didn't call it a reducibility. 198 00:10:48,510 --> 00:10:54,090 But if you remember back a couple of weeks ago, 199 00:10:54,090 --> 00:10:56,120 we were talking about the languages A NFA, 200 00:10:56,120 --> 00:11:01,300 and A DFA, the acceptance problems for NFAs and DFAs. 201 00:11:01,300 --> 00:11:03,760 And we gave a way of solving the A DFA problem. 202 00:11:03,760 --> 00:11:05,950 As you remember, the Turing machine 203 00:11:05,950 --> 00:11:09,710 simulated the finite automaton. 204 00:11:09,710 --> 00:11:13,280 And we solved the NFA problem not 205 00:11:13,280 --> 00:11:18,530 by doing it directly but by converting the NFA to a DFA 206 00:11:18,530 --> 00:11:20,825 and then using the solution for A DFA. 207 00:11:23,740 --> 00:11:25,330 In effect, what we were doing was 208 00:11:25,330 --> 00:11:28,840 we were reducing the A NFA problem to the A DFA problem. 209 00:11:38,250 --> 00:11:43,170 So let's do another example. 210 00:11:43,170 --> 00:11:44,210 Here's a problem. 211 00:11:44,210 --> 00:11:46,743 Here's an example that you again, 212 00:11:46,743 --> 00:11:48,410 probably didn't think about it this way. 213 00:11:48,410 --> 00:11:54,290 But from your homework, we had this pusher problem, 214 00:11:54,290 --> 00:11:58,280 the problem of determining whether a pushdown 215 00:11:58,280 --> 00:12:03,210 automaton ever pushes on its stack for any input. 216 00:12:03,210 --> 00:12:05,040 I know a bunch of you were struggling 217 00:12:05,040 --> 00:12:09,660 with that problem working on it, hopefully solving it 218 00:12:09,660 --> 00:12:10,900 in one way or another. 219 00:12:10,900 --> 00:12:14,790 So there's one way to solve it is in effect by reducing 220 00:12:14,790 --> 00:12:18,782 the pusher problem to the E CFG the emptiness for CFG 221 00:12:18,782 --> 00:12:20,865 which is the equivalent to the emptiness for PDAs. 222 00:12:28,320 --> 00:12:30,670 I mean, this is the solution I had in mind, 223 00:12:30,670 --> 00:12:33,600 which is a particularly simple and short solution. 224 00:12:33,600 --> 00:12:36,120 Of course, not the only solution. 225 00:12:36,120 --> 00:12:38,280 You can take your pushdown automaton 226 00:12:38,280 --> 00:12:41,870 where you're trying to determine if it ever pushes. 227 00:12:41,870 --> 00:12:48,160 And you can take the states that are about to make a push. 228 00:12:48,160 --> 00:12:50,680 And instead of making them make a push, 229 00:12:50,680 --> 00:12:52,030 you make them accept states. 230 00:12:52,030 --> 00:12:54,070 And you get rid of the original accept states. 231 00:12:56,660 --> 00:13:01,550 So now you've converted this automaton 232 00:13:01,550 --> 00:13:08,300 to one that accepts every time the original push on automaton 233 00:13:08,300 --> 00:13:10,278 pushes. 234 00:13:10,278 --> 00:13:12,820 And it accepts, and then has to move to the end of the input, 235 00:13:12,820 --> 00:13:13,960 of course. 236 00:13:13,960 --> 00:13:15,780 So it goes into an accept state and moves 237 00:13:15,780 --> 00:13:16,830 to the end of the input. 238 00:13:16,830 --> 00:13:20,190 So every time the original machine was about to push, 239 00:13:20,190 --> 00:13:23,610 the new machine that you're just creating here 240 00:13:23,610 --> 00:13:27,550 is going to go into an accept state at the end of the input. 241 00:13:27,550 --> 00:13:31,840 Now to test whether the original machine ever uses stack, 242 00:13:31,840 --> 00:13:34,720 it's enough to test whether the new machine ever 243 00:13:34,720 --> 00:13:36,752 accepts an S string. 244 00:13:40,060 --> 00:13:41,170 OK, so that's a way. 245 00:13:41,170 --> 00:13:43,817 I don't want to overcomplicate this right here and get 246 00:13:43,817 --> 00:13:45,400 you thinking about the homework again. 247 00:13:45,400 --> 00:13:50,320 But this is a way of reducing one problem to another problem. 248 00:13:50,320 --> 00:13:53,440 And if you don't quite get this one, 249 00:13:53,440 --> 00:13:55,130 just focus on the other two examples. 250 00:13:55,130 --> 00:13:57,700 I don't want to spend time on the homework set 2 right now. 251 00:13:57,700 --> 00:14:02,213 So we can address that all separately if you want. 252 00:14:02,213 --> 00:14:03,880 It's also the solution that's written up 253 00:14:03,880 --> 00:14:09,070 in the solution set that's posted on the home page 254 00:14:09,070 --> 00:14:09,580 by the way. 255 00:14:12,130 --> 00:14:15,680 OK, so getting back to let's see, 256 00:14:15,680 --> 00:14:19,830 thinking about reducibility. 257 00:14:19,830 --> 00:14:22,470 What I have in mind, again, this is sort of rephrasing it, 258 00:14:22,470 --> 00:14:26,970 but I'm trying to hammer it in that if A is reducible to B, 259 00:14:26,970 --> 00:14:33,050 then solving B gives a solution to A. 260 00:14:33,050 --> 00:14:36,560 Because that's what happens in each of these examples. 261 00:14:36,560 --> 00:14:38,840 Now, how are we going to use that? 262 00:14:38,840 --> 00:14:42,700 We're going to use that in the following two ways. 263 00:14:42,700 --> 00:14:48,000 One is to observe that, if A is reducible to B and B 264 00:14:48,000 --> 00:14:54,730 is an easy problem, then A must also 265 00:14:54,730 --> 00:14:57,310 be easy because we have a way of converting 266 00:14:57,310 --> 00:14:59,080 A problems into B problems. 267 00:14:59,080 --> 00:15:05,160 We have a way of solving A using B. So B is easy. 268 00:15:05,160 --> 00:15:08,990 Then now you can solve A too easily. 269 00:15:08,990 --> 00:15:12,950 Because you can solve A using B, which is easy. 270 00:15:12,950 --> 00:15:16,670 Maybe that's clearest up here in example 1, 271 00:15:16,670 --> 00:15:19,550 where measuring the area might seem at first glance hard. 272 00:15:19,550 --> 00:15:21,980 You could have to walk out over the whole area. 273 00:15:21,980 --> 00:15:23,510 But it's not hard because you only 274 00:15:23,510 --> 00:15:25,218 have to measure the length and the width. 275 00:15:27,340 --> 00:15:30,480 So the fact that B is easy tells you that A is easy. 276 00:15:30,480 --> 00:15:32,420 But actually, this is not the way 277 00:15:32,420 --> 00:15:34,170 we're going to be using it most typically. 278 00:15:34,170 --> 00:15:37,080 We're going to be most typically using it 279 00:15:37,080 --> 00:15:43,310 in the second version, which is a little bit more convoluted. 280 00:15:43,310 --> 00:15:46,210 But this is the way you're going to have to get used to this. 281 00:15:46,210 --> 00:15:49,265 So if A is reducible to B, and you 282 00:15:49,265 --> 00:15:53,540 know A is hard, undecidable, unrecognizable, 283 00:15:53,540 --> 00:15:56,340 whatever the form of hard you care about, 284 00:15:56,340 --> 00:16:01,050 if you know A is hard, and A is reducible to B, 285 00:16:01,050 --> 00:16:03,330 then that tells you B also has to be hard. 286 00:16:06,290 --> 00:16:08,550 Why? 287 00:16:08,550 --> 00:16:12,320 Because if B were easy, then A would be easy. 288 00:16:12,320 --> 00:16:15,960 But we're assuming that A is hard. 289 00:16:15,960 --> 00:16:17,480 So B also has to be hard. 290 00:16:20,350 --> 00:16:25,480 OK, so I'm inverting the logic here. 291 00:16:25,480 --> 00:16:29,240 But this is logically equivalent. 292 00:16:29,240 --> 00:16:31,780 So you have to mull that over a bit. 293 00:16:39,060 --> 00:16:40,710 So why don't you think about that. 294 00:16:40,710 --> 00:16:43,320 And let me just take a few questions on the chat 295 00:16:43,320 --> 00:16:45,540 and don't forget the TAs are there too. 296 00:16:45,540 --> 00:16:47,820 So they're happy to answer your questions. 297 00:16:47,820 --> 00:16:52,960 Don't make them sit there lonely, all right. 298 00:16:55,960 --> 00:16:58,180 So somebody is asking, is it possible 299 00:16:58,180 --> 00:17:03,630 that A is reducible to B and that B is also reducible to A? 300 00:17:03,630 --> 00:17:05,220 So that's a good question. 301 00:17:05,220 --> 00:17:07,319 That can certainly happen. 302 00:17:07,319 --> 00:17:09,480 In that case in a certain sense, A and B 303 00:17:09,480 --> 00:17:10,980 are going to be equivalent. 304 00:17:10,980 --> 00:17:16,290 So solving 1 is going to be just as easy or hard as solving 305 00:17:16,290 --> 00:17:18,500 the other one, OK? 306 00:17:18,500 --> 00:17:20,750 So they're going to be equivalent from the perspective 307 00:17:20,750 --> 00:17:23,760 of the difficulty of solving them. 308 00:17:23,760 --> 00:17:24,859 So somebody is asking-- 309 00:17:24,859 --> 00:17:29,600 and this is a perennial confusion-- 310 00:17:29,600 --> 00:17:34,206 so in the previous slide here, I think 311 00:17:34,206 --> 00:17:36,100 I'll just flip back to it here. 312 00:17:36,100 --> 00:17:37,710 So which direction are we doing? 313 00:17:37,710 --> 00:17:41,205 Are we reducing A TM to HALT TM or HALT TM to A TM? 314 00:17:41,205 --> 00:17:43,580 The way it's written on the slide is what I have in mind. 315 00:17:43,580 --> 00:17:46,570 Here we're reducing A TM to HALT TM 316 00:17:46,570 --> 00:17:52,250 because we're using HALT TM to solve A TM. 317 00:17:52,250 --> 00:17:56,030 And that's reducing A TM to HALT TM. 318 00:17:56,030 --> 00:18:04,100 Just like here, measuring the area 319 00:18:04,100 --> 00:18:06,350 is reducible to measuring the lengths of the sides, 320 00:18:06,350 --> 00:18:09,830 we're using measuring the length of the sides to solve the area. 321 00:18:12,350 --> 00:18:16,840 So we're reducing the area to the lengths, the area 322 00:18:16,840 --> 00:18:18,730 to the length of the sides. 323 00:18:18,730 --> 00:18:25,630 But I know you're going to have to play with it, 324 00:18:25,630 --> 00:18:27,340 digest it, get used to it. 325 00:18:31,350 --> 00:18:38,470 All right, OK, so let's continue. 326 00:18:38,470 --> 00:18:42,820 OK, so as I said, this latter one 327 00:18:42,820 --> 00:18:46,120 because the focus on this course is mainly 328 00:18:46,120 --> 00:18:48,700 on the limitations of computation. 329 00:18:48,700 --> 00:18:52,060 So we're going to be looking at ways of showing 330 00:18:52,060 --> 00:18:54,020 problems or difficulty. 331 00:18:54,020 --> 00:18:56,960 It could be difficult in principle, like undecidable. 332 00:18:56,960 --> 00:18:58,383 Or it could be difficult in terms 333 00:18:58,383 --> 00:19:00,050 of complexity, which is what we're going 334 00:19:00,050 --> 00:19:01,610 to focus on in the second half. 335 00:19:01,610 --> 00:19:03,920 But in both cases, we're going to be using 336 00:19:03,920 --> 00:19:05,720 the concept of reducibility. 337 00:19:05,720 --> 00:19:07,550 So reducibility is going to be a theme. 338 00:19:07,550 --> 00:19:11,660 You've got to get comfortable with reducibility, OK. 339 00:19:11,660 --> 00:19:14,060 So we're going to be focusing more on the notion 340 00:19:14,060 --> 00:19:17,600 that if you reduce A to B, and you know A is hard, 341 00:19:17,600 --> 00:19:20,990 that tells you B is also hard. 342 00:19:20,990 --> 00:19:25,310 OK, so I'm going to say that a few times 343 00:19:25,310 --> 00:19:26,810 during the course of today's lecture 344 00:19:26,810 --> 00:19:29,770 to try to help you get it. 345 00:19:29,770 --> 00:19:32,050 All right, here's a check in. 346 00:19:32,050 --> 00:19:35,650 A little bit sort of off to the side. 347 00:19:35,650 --> 00:19:37,990 But I thought it was a fun check in more. 348 00:19:41,420 --> 00:19:43,250 The question is, some people say biology 349 00:19:43,250 --> 00:19:44,813 is reducible to physics. 350 00:19:44,813 --> 00:19:46,730 Well, maybe everything is reducible to physics 351 00:19:46,730 --> 00:19:50,390 since physics tells you about the laws of the universe. 352 00:19:50,390 --> 00:19:54,020 And biology is part of the universe. 353 00:19:54,020 --> 00:19:57,410 So my question to you is, do you think? 354 00:19:57,410 --> 00:19:59,550 And there's no right answer here. 355 00:19:59,550 --> 00:20:01,410 Do you think, in your opinion, is 356 00:20:01,410 --> 00:20:03,690 biology reducible to physics? 357 00:20:03,690 --> 00:20:08,250 Maybe yes, or maybe there are some things like consciousness 358 00:20:08,250 --> 00:20:11,820 which cannot be reduced to physics. 359 00:20:11,820 --> 00:20:13,690 Or maybe we don't know. 360 00:20:13,690 --> 00:20:18,275 So I'm curious to know your thoughts. 361 00:20:23,110 --> 00:20:25,930 But it does kind of use in a sense 362 00:20:25,930 --> 00:20:28,360 the notion of reducible in the spirit 363 00:20:28,360 --> 00:20:31,420 of what I have in mind here. 364 00:20:31,420 --> 00:20:34,510 In the sense that if you could fully understand physics, 365 00:20:34,510 --> 00:20:37,435 would that allow you to fully understand biology? 366 00:20:42,640 --> 00:20:43,660 OK, here we are. 367 00:20:43,660 --> 00:20:50,400 We're almost-- kind of interesting, though not too 368 00:20:50,400 --> 00:20:51,480 unexpected I suppose. 369 00:20:55,700 --> 00:20:59,660 So we are, I think, just about done. 370 00:20:59,660 --> 00:21:03,830 5 seconds, pick anything if you want to get credit for this 371 00:21:03,830 --> 00:21:08,310 and you haven't selected yet. 372 00:21:08,310 --> 00:21:09,750 Ready to go, ending polling. 373 00:21:12,690 --> 00:21:13,565 Here are the results. 374 00:21:17,900 --> 00:21:20,500 And as I say, there's no right answer here. 375 00:21:20,500 --> 00:21:28,960 But if I had been in the class, I would have picked B. 376 00:21:28,960 --> 00:21:33,580 But I'm not surprised, especially in an MIT crowd 377 00:21:33,580 --> 00:21:39,195 that A is the winner, all right. 378 00:21:39,195 --> 00:21:39,820 Let's continue. 379 00:21:44,650 --> 00:21:48,410 OK, so now we're going to use reducibility again. 380 00:21:48,410 --> 00:21:50,960 This is going to be yet another example like the HALT TM 381 00:21:50,960 --> 00:21:53,030 example, but a little bit harder. 382 00:21:55,005 --> 00:21:56,380 And we're going to be doing this. 383 00:21:56,380 --> 00:21:57,838 You know, next lecture, we're going 384 00:21:57,838 --> 00:22:01,030 to be doing more reducibilities but much harder. 385 00:22:01,030 --> 00:22:08,415 So we really got to get really comfortable, all right. 386 00:22:08,415 --> 00:22:09,290 I want to show E TMs. 387 00:22:09,290 --> 00:22:11,900 So E TM is the emptiness problem for Turing machines. 388 00:22:11,900 --> 00:22:13,478 Is this language empty? 389 00:22:13,478 --> 00:22:15,020 I'm just going to give you a machine. 390 00:22:15,020 --> 00:22:16,937 I want to know, is this language empty or not? 391 00:22:16,937 --> 00:22:20,620 Does it accept something or is this language empty? 392 00:22:20,620 --> 00:22:24,130 That's going to be undecidable, no surprise, proof 393 00:22:24,130 --> 00:22:25,150 by contradiction. 394 00:22:25,150 --> 00:22:28,010 And we're going to show that A TM is reducible to E TM. 395 00:22:31,730 --> 00:22:37,160 So these things often take a very similar form. 396 00:22:37,160 --> 00:22:39,390 And I'm going to try to use the same form. 397 00:22:39,390 --> 00:22:40,970 So if you're feeling shaky on it, 398 00:22:40,970 --> 00:22:45,620 at least you'll get the form of the way the solution goes 399 00:22:45,620 --> 00:22:52,240 and that will help you maybe plug-in to solve problems, OK. 400 00:22:52,240 --> 00:22:57,290 So proof by contradiction, assume 401 00:22:57,290 --> 00:22:59,630 that E TM is decidable, opposite of what 402 00:22:59,630 --> 00:23:00,860 we've been trying to show. 403 00:23:00,860 --> 00:23:02,450 And then show that A TM is decidable, 404 00:23:02,450 --> 00:23:03,560 which you know is false. 405 00:23:06,160 --> 00:23:10,440 So we'll say we have a decider for A TM, 406 00:23:10,440 --> 00:23:14,560 R, using the same letters on purpose 407 00:23:14,560 --> 00:23:18,220 here just to try to get the pattern for you, 408 00:23:18,220 --> 00:23:20,020 so R deciding E TM. 409 00:23:20,020 --> 00:23:25,450 Construct S deciding A TM, OK. 410 00:23:25,450 --> 00:23:31,210 So now, let's think about it together for a minute 411 00:23:31,210 --> 00:23:32,620 before I just put it up there. 412 00:23:36,390 --> 00:23:41,300 So S, I'm trying to make a decider for A TM, 413 00:23:41,300 --> 00:23:48,850 using my decider for the emptiness problem, OK? 414 00:23:48,850 --> 00:23:55,000 So we have R, which can tell us whether M's language is empty. 415 00:23:55,000 --> 00:23:57,390 So why don't we just, I don't know, 416 00:23:57,390 --> 00:24:03,780 stick M into that emptiness tester and see what it says? 417 00:24:03,780 --> 00:24:05,280 I'm not saying this is the solution, 418 00:24:05,280 --> 00:24:07,425 but this is how one might think about coming up 419 00:24:07,425 --> 00:24:08,175 with the solution. 420 00:24:11,350 --> 00:24:13,060 So are you with me? 421 00:24:13,060 --> 00:24:17,350 We're going to take M, we have an emptiness tester. 422 00:24:17,350 --> 00:24:22,030 Let's take M and plug it into R, see what R says. 423 00:24:22,030 --> 00:24:25,420 R is going to come back and tell us whether M's language is 424 00:24:25,420 --> 00:24:28,190 empty or not. 425 00:24:28,190 --> 00:24:32,285 Now, one of those answers will make us happy. 426 00:24:36,040 --> 00:24:37,350 Why? 427 00:24:37,350 --> 00:24:45,640 Suppose R tells us that M's language is empty. 428 00:24:45,640 --> 00:24:48,270 Why is that good? 429 00:24:48,270 --> 00:24:50,800 With that, we're done. 430 00:24:50,800 --> 00:24:52,480 Because S is trying to figure out, 431 00:24:52,480 --> 00:24:55,810 we're trying to figure out exactly, 432 00:24:55,810 --> 00:24:58,720 somebody told me the answer which is correct. 433 00:24:58,720 --> 00:25:00,920 Because now we can reject. 434 00:25:00,920 --> 00:25:02,840 If M's language is empty, it's clearly not 435 00:25:02,840 --> 00:25:07,350 accepting w because it's not accepting anything. 436 00:25:07,350 --> 00:25:12,270 So if R says M's language is empty, then we're good. 437 00:25:12,270 --> 00:25:15,470 The only problem is we also say M's language is not empty. 438 00:25:15,470 --> 00:25:17,070 And then what do we know? 439 00:25:17,070 --> 00:25:20,750 Well, not much, not much that's useful for testing 440 00:25:20,750 --> 00:25:21,860 whether M accepts w. 441 00:25:21,860 --> 00:25:24,080 We just know M accepts something. 442 00:25:24,080 --> 00:25:26,720 But that something may or may not be w. 443 00:25:32,270 --> 00:25:35,490 OK, so what do we do? 444 00:25:35,490 --> 00:25:39,510 Well, the problem is that M is possibly 445 00:25:39,510 --> 00:25:44,310 accepting all sorts of strings besides w, which are 446 00:25:44,310 --> 00:25:46,620 kind of mucking up the works. 447 00:25:46,620 --> 00:25:51,240 They're interfering with the solution that we like. 448 00:25:51,240 --> 00:25:55,470 We'd like to be able to use R on M 449 00:25:55,470 --> 00:25:58,170 to tell us whether M is accepting w. 450 00:25:58,170 --> 00:25:59,640 But M is accepting other things. 451 00:25:59,640 --> 00:26:02,110 And that's making the picture complicated. 452 00:26:02,110 --> 00:26:04,920 So what I propose we do, why don't we 453 00:26:04,920 --> 00:26:10,830 modify M so that it never accepts anything besides w? 454 00:26:10,830 --> 00:26:14,250 The very first thing M does in the modified form 455 00:26:14,250 --> 00:26:16,170 is it looks at its input and sees 456 00:26:16,170 --> 00:26:17,953 whether it's different from w. 457 00:26:17,953 --> 00:26:19,995 If it's different from w, it immediately rejects. 458 00:26:22,880 --> 00:26:25,250 Now we take that modified machine, 459 00:26:25,250 --> 00:26:27,590 and we feed it into the emptiness tester. 460 00:26:30,860 --> 00:26:32,823 Now the emptiness tester is going 461 00:26:32,823 --> 00:26:34,490 to give us the information we're looking 462 00:26:34,490 --> 00:26:38,960 for because if the emptiness tester says the modified 463 00:26:38,960 --> 00:26:40,490 machines language is empty, well, 464 00:26:40,490 --> 00:26:44,180 we know that M is not accepting w 465 00:26:44,180 --> 00:26:49,490 because we haven't changed how M behaves when it's given w. 466 00:26:49,490 --> 00:26:56,330 But if R says M's language is not empty, 467 00:26:56,330 --> 00:26:58,850 well, then it must be that M is accepting w. 468 00:26:58,850 --> 00:27:00,560 Because we've already filtered out 469 00:27:00,560 --> 00:27:03,440 all of the other possibilities when 470 00:27:03,440 --> 00:27:06,280 we've modified the machine. 471 00:27:06,280 --> 00:27:08,910 So let me repeat that on the slide 472 00:27:08,910 --> 00:27:11,950 and write it down a little bit more formally. 473 00:27:11,950 --> 00:27:14,130 So what I'm going to do is I'm going to transform M 474 00:27:14,130 --> 00:27:15,300 to a new Turing machine. 475 00:27:15,300 --> 00:27:18,720 I'm going to call it M sub w to emphasize 476 00:27:18,720 --> 00:27:21,180 the fact that this new machine depends on W. 477 00:27:21,180 --> 00:27:23,790 It's going to actually have w built into as part 478 00:27:23,790 --> 00:27:26,668 of the rules of the machine. 479 00:27:26,668 --> 00:27:28,460 So for a different w, we're going to end up 480 00:27:28,460 --> 00:27:29,710 with a different machine here. 481 00:27:29,710 --> 00:27:32,360 So this is a machine whose structure is 482 00:27:32,360 --> 00:27:34,070 going to depend on knowing w. 483 00:27:37,030 --> 00:27:39,310 And that machine is going to be very much 484 00:27:39,310 --> 00:27:42,460 like the original machine M, except that 485 00:27:42,460 --> 00:27:45,940 when it gets an input, let's say it's called X now, 486 00:27:45,940 --> 00:27:50,790 that machine is going to compare X with w 487 00:27:50,790 --> 00:27:52,410 and reject if it's not equal. 488 00:27:55,590 --> 00:28:00,900 Otherwise, if X is equal to w, it's going to run M on w 489 00:28:00,900 --> 00:28:01,690 as before. 490 00:28:01,690 --> 00:28:05,520 So it's not going to change the behavior when the input is w. 491 00:28:05,520 --> 00:28:08,610 It's only going to change the behavior when the input is 492 00:28:08,610 --> 00:28:10,800 something different than w, and then it's 493 00:28:10,800 --> 00:28:16,350 going to reject, all right. 494 00:28:16,350 --> 00:28:21,660 So I'm going to look at two aspects of this. 495 00:28:21,660 --> 00:28:25,770 First, let's understand the language of this new machine. 496 00:28:25,770 --> 00:28:27,660 And then we'll also talk about how 497 00:28:27,660 --> 00:28:31,120 we go about doing this transformation. 498 00:28:31,120 --> 00:28:36,130 So first of all, just for emphasis, 499 00:28:36,130 --> 00:28:39,510 so Mw works just like M. It has all the rules of M 500 00:28:39,510 --> 00:28:42,600 in it, except some extra rules. 501 00:28:42,600 --> 00:28:45,750 It always at the very first step, 502 00:28:45,750 --> 00:28:53,600 it tests whether X is equal to w or not. 503 00:28:53,600 --> 00:28:56,590 And if it's not equal to, it rejects. 504 00:28:56,590 --> 00:28:57,650 Not equal to, reject. 505 00:28:57,650 --> 00:28:59,560 So the language of that new machine 506 00:28:59,560 --> 00:29:01,420 is either going to be just the string 507 00:29:01,420 --> 00:29:04,840 w when M accepts w because everything else is filtered 508 00:29:04,840 --> 00:29:05,950 out. 509 00:29:05,950 --> 00:29:08,373 Or the empty set if M rejects something. 510 00:29:11,140 --> 00:29:15,150 So it's important that you understand the behavior, 511 00:29:15,150 --> 00:29:18,790 at least, of this new machine. 512 00:29:18,790 --> 00:29:21,910 It's just like M except filtering out all 513 00:29:21,910 --> 00:29:25,570 of the inputs which are not w. 514 00:29:25,570 --> 00:29:30,250 Those are going to be automatically rejected. 515 00:29:30,250 --> 00:29:36,300 So it's also important that S be able to make 516 00:29:36,300 --> 00:29:38,720 this transformation. 517 00:29:38,720 --> 00:29:41,800 But I claim that you'll have to accept this 518 00:29:41,800 --> 00:29:43,780 if you don't totally see it. 519 00:29:43,780 --> 00:29:49,540 But the transformation is simply taking M 520 00:29:49,540 --> 00:29:54,670 and adding some new rules, some new transitions and states 521 00:29:54,670 --> 00:29:59,680 so that the very first thing that M sub w does 522 00:29:59,680 --> 00:30:03,700 is it just has a sequence of moves 523 00:30:03,700 --> 00:30:08,170 where it's checking that the input string is equal to w 524 00:30:08,170 --> 00:30:09,260 or not. 525 00:30:09,260 --> 00:30:13,720 And if it's not equal to w, it just rejects. 526 00:30:13,720 --> 00:30:16,240 So it's easy to modify M. You could easily 527 00:30:16,240 --> 00:30:19,420 write a program which would modify the states 528 00:30:19,420 --> 00:30:26,280 and transitions of M to make it do that test at the beginning. 529 00:30:26,280 --> 00:30:28,940 So I'm not going to elaborate on those kinds of things 530 00:30:28,940 --> 00:30:29,930 in the future. 531 00:30:29,930 --> 00:30:31,370 But just for the very first time, 532 00:30:31,370 --> 00:30:33,740 I just want to make sure you understand that we're not 533 00:30:33,740 --> 00:30:35,000 doing anything fishy here. 534 00:30:35,000 --> 00:30:41,570 This is a completely legitimate thing for S to be able to do. 535 00:30:41,570 --> 00:30:45,200 So S can modify M to this new machine 536 00:30:45,200 --> 00:30:48,840 Mw, which filters that new machine, 537 00:30:48,840 --> 00:30:55,110 filters out all strings except for w and rejects them. 538 00:30:55,110 --> 00:30:58,458 So S takes that new machine, and what is it going to do with it? 539 00:30:58,458 --> 00:31:00,000 Is it ever going to run that machine? 540 00:31:00,000 --> 00:31:01,750 No. 541 00:31:01,750 --> 00:31:04,780 This machine is built not for running. 542 00:31:04,780 --> 00:31:11,510 This machine is built for feeding into R. 543 00:31:11,510 --> 00:31:14,840 Because as you remember, feeding M into R 544 00:31:14,840 --> 00:31:17,630 had the problem that M might accept things besides w. 545 00:31:17,630 --> 00:31:20,810 And that confuses the result that we get from R in the sense 546 00:31:20,810 --> 00:31:22,230 that it's not useful. 547 00:31:22,230 --> 00:31:26,560 But if we feed Mw into R, now we're 548 00:31:26,560 --> 00:31:32,350 good because if the information about whether Mw's language is 549 00:31:32,350 --> 00:31:36,430 empty from over here tells us whether or not M accepts w. 550 00:31:39,500 --> 00:31:43,080 If Mw's language is not empty, then M accepts w. 551 00:31:43,080 --> 00:31:45,784 If M's language is empty, M rejects w. 552 00:31:51,690 --> 00:31:56,380 OK, so starting to get some good questions here. 553 00:31:56,380 --> 00:32:00,600 Let me just finish the description of S. 554 00:32:00,600 --> 00:32:02,260 So somebody is asking here. 555 00:32:02,260 --> 00:32:04,335 So this is an excellent question. 556 00:32:08,670 --> 00:32:15,440 How do we know that Mw halts on w, or whatever? 557 00:32:15,440 --> 00:32:16,700 We don't. 558 00:32:16,700 --> 00:32:18,470 Mw may not halt on w. 559 00:32:18,470 --> 00:32:20,820 We don't care. 560 00:32:20,820 --> 00:32:23,660 We're never going to run Mw on anything. 561 00:32:26,800 --> 00:32:28,780 We're going to take Mw as a machine, 562 00:32:28,780 --> 00:32:31,710 and we're going to feed it into R as a description. 563 00:32:31,710 --> 00:32:33,460 We are going to take the description of Mw 564 00:32:33,460 --> 00:32:37,000 and feed it into R. Then it's R's problem. 565 00:32:37,000 --> 00:32:43,710 But R has been assumed to answer emptiness testing. 566 00:32:43,710 --> 00:32:48,710 So we just took the original machine, modified it 567 00:32:48,710 --> 00:32:52,100 so that the only possible thing it could accept is w. 568 00:32:52,100 --> 00:32:54,500 And now feed it into the emptiness tester 569 00:32:54,500 --> 00:32:57,780 to see whether its language is empty or not. 570 00:32:57,780 --> 00:32:59,340 Now if its language is not empty, 571 00:32:59,340 --> 00:33:01,920 it has to be accepting w because it's built 572 00:33:01,920 --> 00:33:04,170 not to accept anything else. 573 00:33:04,170 --> 00:33:09,310 So we don't care whether Mw might end up looping. 574 00:33:09,310 --> 00:33:10,520 We're never going to run Mw. 575 00:33:13,380 --> 00:33:17,520 I acknowledge, it's a leap for many of you. 576 00:33:17,520 --> 00:33:21,610 So you're going to have to mull it over. 577 00:33:21,610 --> 00:33:26,880 So we're going to use R to test whether Mw's language is empty. 578 00:33:26,880 --> 00:33:29,820 If yes, that means that M rejects w. 579 00:33:29,820 --> 00:33:31,320 So then we're going to reject, if we 580 00:33:31,320 --> 00:33:33,570 know that Mw's language is empty, 581 00:33:33,570 --> 00:33:36,580 that must have been that M rejected w. 582 00:33:36,580 --> 00:33:40,560 So now as an A TM decider, which is what S is, 583 00:33:40,560 --> 00:33:44,310 S is supposed to reject, which is what we 584 00:33:44,310 --> 00:33:46,090 have here in the description. 585 00:33:46,090 --> 00:33:49,770 And if no, that means the language is not empty. 586 00:33:49,770 --> 00:33:52,830 So M accepts w, and so therefore we're accepting. 587 00:33:52,830 --> 00:33:55,660 So there's a little bit of a twist here also. 588 00:33:55,660 --> 00:33:57,445 OK, so let's take some more. 589 00:34:01,580 --> 00:34:03,980 I'm expecting some questions here. 590 00:34:03,980 --> 00:34:06,860 So somebody is asking, how do you 591 00:34:06,860 --> 00:34:09,969 determine if the language is decidable? 592 00:34:09,969 --> 00:34:13,100 I mean, that's what we're doing. 593 00:34:13,100 --> 00:34:17,420 You can show a language is decidable by exhibiting 594 00:34:17,420 --> 00:34:19,820 a Turing machine which decides it. 595 00:34:19,820 --> 00:34:22,429 And you can show a language is not decidable, 596 00:34:22,429 --> 00:34:24,620 which is what we're doing here by proving 597 00:34:24,620 --> 00:34:27,980 that it's not possible for a Turing machine to decide it. 598 00:34:27,980 --> 00:34:30,560 You know, we did that first with A TM. 599 00:34:30,560 --> 00:34:33,860 We got that contradiction by diagonalization. 600 00:34:33,860 --> 00:34:36,800 And here we're doing a reducibility 601 00:34:36,800 --> 00:34:43,570 to show as the method of proof, all right. 602 00:34:43,570 --> 00:34:45,679 Let's continue. 603 00:34:45,679 --> 00:34:49,210 So now we're going to talk about a special kind. 604 00:34:49,210 --> 00:34:52,270 So far we talked about reducibility. 605 00:34:52,270 --> 00:34:55,030 We didn't define it in a precise way 606 00:34:55,030 --> 00:34:57,130 because there are several different ways 607 00:34:57,130 --> 00:35:01,150 to get at the notion of reducibility precisely. 608 00:35:01,150 --> 00:35:03,940 And I'm going to introduce a one version, which is 609 00:35:03,940 --> 00:35:05,320 a little bit more restrictive. 610 00:35:05,320 --> 00:35:07,480 I mean, somewhat more restrictive and a little bit 611 00:35:07,480 --> 00:35:11,270 different way of looking at it than we have been doing so far. 612 00:35:11,270 --> 00:35:13,720 But there were going to be some benefits to looking 613 00:35:13,720 --> 00:35:16,060 at this particular kind of reducibility, which we're 614 00:35:16,060 --> 00:35:18,730 calling mapping reducibility. 615 00:35:18,730 --> 00:35:21,550 It's going to have several benefits for us immediately 616 00:35:21,550 --> 00:35:23,380 and down the road. 617 00:35:23,380 --> 00:35:27,760 But this is also a little technical 618 00:35:27,760 --> 00:35:37,450 so don't get scared off. 619 00:35:37,450 --> 00:35:39,140 It might look complicated at first. 620 00:35:39,140 --> 00:35:43,820 But we'll try to unpack it for you, OK. 621 00:35:43,820 --> 00:35:51,080 So first of all, we have to first of all talk 622 00:35:51,080 --> 00:35:54,040 about the notion of a computable function. 623 00:35:54,040 --> 00:35:56,740 So generally when we've had Turing machines, 624 00:35:56,740 --> 00:35:58,990 they're doing yes, no. 625 00:35:58,990 --> 00:36:02,210 They're doing accept, reject kinds of things. 626 00:36:02,210 --> 00:36:04,660 So it's like a function, just sort of a computing, 627 00:36:04,660 --> 00:36:07,630 sort of a binary function. 628 00:36:07,630 --> 00:36:10,840 For here, we're going to want to talk about Turing machines that 629 00:36:10,840 --> 00:36:15,040 are computing a function which converts 630 00:36:15,040 --> 00:36:17,760 one string to another string. 631 00:36:17,760 --> 00:36:22,810 So it's mapping from strings to strings. 632 00:36:22,810 --> 00:36:28,600 And it could be like the function which reverses 633 00:36:28,600 --> 00:36:30,700 the string, for example. 634 00:36:30,700 --> 00:36:34,960 That's one possible function you could be having here. 635 00:36:34,960 --> 00:36:38,080 But there's of course zillions of possible functions here. 636 00:36:38,080 --> 00:36:41,410 And we're going to talk about functions that you can compute 637 00:36:41,410 --> 00:36:42,760 with the Turing machine. 638 00:36:42,760 --> 00:36:45,190 And that basically means you provide the input 639 00:36:45,190 --> 00:36:47,470 to the function as input to the Turing machine. 640 00:36:47,470 --> 00:36:50,200 And the output of the function, the value of the function 641 00:36:50,200 --> 00:36:52,540 comes out as the output of the Turing machine, 642 00:36:52,540 --> 00:36:55,480 which let's just say it leaves that value on its tape 643 00:36:55,480 --> 00:36:56,440 when it halts. 644 00:36:56,440 --> 00:36:58,780 It halts with the value of the function on the tape. 645 00:37:01,950 --> 00:37:05,050 But just, we're thinking about algorithms here. 646 00:37:05,050 --> 00:37:06,640 Come up with your favorite method 647 00:37:06,640 --> 00:37:08,080 of thinking about algorithms. 648 00:37:08,080 --> 00:37:09,820 It has an input and an output. 649 00:37:09,820 --> 00:37:12,310 And the algorithm just computes the function 650 00:37:12,310 --> 00:37:16,222 by taking as input w, and the output is f of w. 651 00:37:16,222 --> 00:37:18,040 It doesn't have to be a Turing machine. 652 00:37:18,040 --> 00:37:20,410 Just any algorithm that can compute something 653 00:37:20,410 --> 00:37:22,150 is good enough. 654 00:37:22,150 --> 00:37:24,983 They are all equivalent. 655 00:37:24,983 --> 00:37:27,150 And now we're going to use this notion of a function 656 00:37:27,150 --> 00:37:31,260 that you can compute to define a kind of reducibility 657 00:37:31,260 --> 00:37:32,967 called mapping reducibility. 658 00:37:32,967 --> 00:37:34,800 I'm going to say that A is mapping reducible 659 00:37:34,800 --> 00:37:40,752 to B, written with this less than or equal to sub M symbol. 660 00:37:40,752 --> 00:37:42,210 And you're going to see that a lot. 661 00:37:42,210 --> 00:37:45,750 It's on the homework also by the way. 662 00:37:45,750 --> 00:37:49,890 If there is some computable function as I just described, 663 00:37:49,890 --> 00:37:58,530 where whenever w is in A, f of w is in B. 664 00:37:58,530 --> 00:38:01,700 And the way to think about it is with this picture. 665 00:38:01,700 --> 00:38:04,420 So A and B are languages, written like, 666 00:38:04,420 --> 00:38:07,800 here's A and here's B. 667 00:38:07,800 --> 00:38:09,645 And now there are strings. 668 00:38:12,370 --> 00:38:19,140 So w might be in A. It might be out of A. 669 00:38:19,140 --> 00:38:26,010 And you think of you're trying to solve A. You're trying 670 00:38:26,010 --> 00:38:30,360 to decide membership in A. So you want to test 671 00:38:30,360 --> 00:38:34,170 whether w is in A or not. 672 00:38:34,170 --> 00:38:36,910 A mapping reducible is a function 673 00:38:36,910 --> 00:38:42,970 which maps things from this space 674 00:38:42,970 --> 00:38:47,950 over to that space in a way that strings that are in A 675 00:38:47,950 --> 00:38:51,440 get mapped to strings that are in B. 676 00:38:51,440 --> 00:38:55,980 So if you start out with w in A, f of w is in B. 677 00:38:55,980 --> 00:39:04,490 And if w is not in A, then f of w is not in B. Pictorially 678 00:39:04,490 --> 00:39:06,218 it's a simple idea. 679 00:39:06,218 --> 00:39:07,760 We'll have to make sure we understand 680 00:39:07,760 --> 00:39:13,910 why this fits with our concept of reducibility. 681 00:39:13,910 --> 00:39:14,820 But we'll do that. 682 00:39:14,820 --> 00:39:16,400 But anyway, let's first understand 683 00:39:16,400 --> 00:39:17,930 just what we're doing here. 684 00:39:17,930 --> 00:39:20,540 We're just coming up with a function that 685 00:39:20,540 --> 00:39:22,400 can do this kind of a mapping. 686 00:39:22,400 --> 00:39:25,460 It sort of translates problems which 687 00:39:25,460 --> 00:39:32,390 inputs which may or may not be in A into other strings which 688 00:39:32,390 --> 00:39:40,970 may or may not be in B. But sort of maintaining 689 00:39:40,970 --> 00:39:42,330 the same membership property. 690 00:39:42,330 --> 00:39:44,630 So if you start out with something in A, 691 00:39:44,630 --> 00:39:48,860 when you apply f, you're going to end up with something in B. 692 00:39:48,860 --> 00:39:54,715 And conversely, if you're not in A, then you won't be in B, OK? 693 00:39:57,460 --> 00:40:01,700 Somebody is asking, so just a couple of questions here. 694 00:40:01,700 --> 00:40:03,280 Not necessarily 1-to-1? 695 00:40:03,280 --> 00:40:05,740 No, so the function doesn't have to be 1-to-1. 696 00:40:05,740 --> 00:40:08,455 There could be multiple things that map to the same point. 697 00:40:11,530 --> 00:40:13,820 And is there any restriction on the alphabet? 698 00:40:13,820 --> 00:40:14,320 No. 699 00:40:18,380 --> 00:40:24,400 So before we actually get into the example, 700 00:40:24,400 --> 00:40:27,570 let me try to give you a sense about why 701 00:40:27,570 --> 00:40:30,440 we call this a reducibility. 702 00:40:30,440 --> 00:40:36,700 And the reason is, suppose we have such an f which can 703 00:40:36,700 --> 00:40:39,520 do the mapping as I described. 704 00:40:39,520 --> 00:40:45,820 And we also have a way of deciding membership in B. 705 00:40:45,820 --> 00:40:48,610 So B is decidable. 706 00:40:48,610 --> 00:40:51,250 So that's going to tell us right away that A is decidable. 707 00:40:51,250 --> 00:40:54,040 Because if you have some input, and you want to know, 708 00:40:54,040 --> 00:41:02,380 is it an A or not, you can now apply f and test whether f of w 709 00:41:02,380 --> 00:41:09,230 is in B. So the test of w is in A, 710 00:41:09,230 --> 00:41:11,990 you're going to instead test whether f of w is in B. 711 00:41:11,990 --> 00:41:16,050 And we're assuming that shows that A is reducible to B. 712 00:41:16,050 --> 00:41:20,110 So if you could solve the B problem, that also gives you 713 00:41:20,110 --> 00:41:22,200 a way to solve the A problem. 714 00:41:22,200 --> 00:41:25,137 So again, we're going to say this several times 715 00:41:25,137 --> 00:41:26,220 in several different ways. 716 00:41:26,220 --> 00:41:31,040 So if you didn't quite get it yet, don't panic. 717 00:41:31,040 --> 00:41:34,370 So here is going to be an example. 718 00:41:34,370 --> 00:41:37,250 Sort of building on what we just showed last time 719 00:41:37,250 --> 00:41:39,350 in the previous slide, A TM, we're 720 00:41:39,350 --> 00:41:41,030 going to show how A TM is actually 721 00:41:41,030 --> 00:41:45,740 mapping reducible to the complement of E TM. 722 00:41:45,740 --> 00:41:47,450 And the complement is necessary here. 723 00:41:50,710 --> 00:41:53,110 The computable function that we're going to give, 724 00:41:53,110 --> 00:41:57,610 which is basically, the computable function 725 00:41:57,610 --> 00:42:01,660 is going to translate problems about A TM 726 00:42:01,660 --> 00:42:06,730 to problems about E TM because we're mapping reducing 727 00:42:06,730 --> 00:42:09,870 A TM to the complement of E TM. 728 00:42:09,870 --> 00:42:16,420 So what we're doing here is with mapping M and w to the machine 729 00:42:16,420 --> 00:42:16,920 Mw. 730 00:42:20,470 --> 00:42:23,890 Kind of in a way, we're boiling out the essence, 731 00:42:23,890 --> 00:42:26,200 boiling down to the essence of the proof 732 00:42:26,200 --> 00:42:28,470 that we gave in the previous slide. 733 00:42:28,470 --> 00:42:31,590 This is really the core of the proof. 734 00:42:31,590 --> 00:42:34,920 This translation of Mw where you want to know, 735 00:42:34,920 --> 00:42:39,780 is M accepting w to a new machine Mw where you're testing 736 00:42:39,780 --> 00:42:43,340 whether Mw's language is empty. 737 00:42:43,340 --> 00:42:47,180 And so remember Mw from before. 738 00:42:47,180 --> 00:42:48,920 It's the machine that filters out 739 00:42:48,920 --> 00:42:51,470 all the non-w's and rejects them. 740 00:42:54,060 --> 00:42:57,230 And the reason why this reduction function works 741 00:42:57,230 --> 00:43:02,930 is that Mw is in A TM, if and only if M sub w 742 00:43:02,930 --> 00:43:06,510 is in the complement of A TM. 743 00:43:06,510 --> 00:43:16,400 So M accepts w exactly when Mw's language is not empty, OK? 744 00:43:16,400 --> 00:43:19,820 So M accepts w if and only if the language of Mw 745 00:43:19,820 --> 00:43:21,180 is not empty. 746 00:43:21,180 --> 00:43:23,870 So you have to mull this over a bit to realize it's-- 747 00:43:23,870 --> 00:43:28,773 I know this can be a little tricky. 748 00:43:28,773 --> 00:43:30,440 But I think what we're going to do here, 749 00:43:30,440 --> 00:43:33,350 I think we're at the time for the break. 750 00:43:33,350 --> 00:43:36,260 So oh, no, there's one more slide. 751 00:43:36,260 --> 00:43:37,435 I apologize. 752 00:43:37,435 --> 00:43:38,810 So let's talk about this and then 753 00:43:38,810 --> 00:43:40,352 we're going to have our coffee break. 754 00:43:47,490 --> 00:43:50,250 So these properties are really going 755 00:43:50,250 --> 00:43:56,370 to be getting at what makes mapping reducibility 756 00:43:56,370 --> 00:44:00,310 fit with our understanding of what a reducibility should be. 757 00:44:00,310 --> 00:44:03,360 So if A is mapping reducible to B, and B is decidable, 758 00:44:03,360 --> 00:44:08,060 then so is A. So that fits with what we want. 759 00:44:08,060 --> 00:44:10,850 Because if A is reducible to B, and B is easy, then A is easy. 760 00:44:10,850 --> 00:44:14,073 So here easy means decidable. 761 00:44:14,073 --> 00:44:14,990 And here is the proof. 762 00:44:14,990 --> 00:44:17,420 Let's take a Turing machine that decides B 763 00:44:17,420 --> 00:44:23,010 and construct a Turing machine that decides A as claimed, 764 00:44:23,010 --> 00:44:24,600 S operates like this. 765 00:44:24,600 --> 00:44:28,860 It takes its input, computes f of that input, 766 00:44:28,860 --> 00:44:38,520 tests whether f of w is in B using the R 767 00:44:38,520 --> 00:44:40,440 machine that we were assuming. 768 00:44:40,440 --> 00:44:45,150 We have R deciding B. And if R halts then 769 00:44:45,150 --> 00:44:47,700 output the same result. 770 00:44:47,700 --> 00:44:49,550 So if R accepts, we're going to accept. 771 00:44:49,550 --> 00:44:51,590 If R halts and rejects, we'll reject. 772 00:44:51,590 --> 00:44:54,110 And of course we're going to be similarly running R. 773 00:44:54,110 --> 00:44:56,210 So if R is not going to be halting, 774 00:44:56,210 --> 00:44:58,630 we are not going to end up halting either. 775 00:44:58,630 --> 00:44:59,770 OK? 776 00:44:59,770 --> 00:45:02,200 So the corollary is, and this is the way 777 00:45:02,200 --> 00:45:09,620 we're going to be using it, if A is reducible to B 778 00:45:09,620 --> 00:45:17,090 and A is undecidable, then so is B. So this is as I mentioned, 779 00:45:17,090 --> 00:45:20,180 the focus for us is going to be on undecidability. 780 00:45:20,180 --> 00:45:22,250 And you may want to think about A 781 00:45:22,250 --> 00:45:27,020 is like the A TM problem which we know is undecidable. 782 00:45:27,020 --> 00:45:29,090 We're going to show the A TM is mapping 783 00:45:29,090 --> 00:45:31,640 reducible to some other problem to show that other problem is 784 00:45:31,640 --> 00:45:32,608 undecidable. 785 00:45:36,938 --> 00:45:38,480 And the important thing about mapping 786 00:45:38,480 --> 00:45:42,990 reducibility is that it also applies to recognizes. 787 00:45:42,990 --> 00:45:44,840 So if A is mapping reducible to B, 788 00:45:44,840 --> 00:45:48,150 and B is Turing recognizable, then so is A. 789 00:45:48,150 --> 00:45:51,630 So if you're reducing A to a recognizable problem, 790 00:45:51,630 --> 00:45:54,740 then A is also recognizable, same proof. 791 00:45:54,740 --> 00:45:58,910 Because you can just map your w to f of w 792 00:45:58,910 --> 00:46:01,130 and feed it into the recognizer. 793 00:46:01,130 --> 00:46:02,690 That's going to give you a recognizer 794 00:46:02,690 --> 00:46:03,773 for the original language. 795 00:46:07,010 --> 00:46:11,510 And the corollary is that if A is mapping reducible to B, 796 00:46:11,510 --> 00:46:14,300 and A is unrecognizable, then so is B. 797 00:46:14,300 --> 00:46:19,020 So this is again that inverted logic. 798 00:46:19,020 --> 00:46:20,970 So now I think we're-- 799 00:46:20,970 --> 00:46:25,170 oops, I meant to put this picture up earlier. 800 00:46:25,170 --> 00:46:28,710 OK, so here's a check in. 801 00:46:28,710 --> 00:46:30,780 It will be more of a check in for me to see 802 00:46:30,780 --> 00:46:34,660 how well you're following me. 803 00:46:34,660 --> 00:46:37,325 So these are some properties-- 804 00:46:37,325 --> 00:46:38,950 so I'll give you a minute here to think 805 00:46:38,950 --> 00:46:43,720 about this-- some properties of mapping reducibility. 806 00:46:43,720 --> 00:46:48,870 Suppose A is mapping reducible to B, what can we conclude? 807 00:46:48,870 --> 00:46:52,242 Does that mean that we can flip it around? 808 00:46:52,242 --> 00:46:53,950 If A is mapping reducible to B, does that 809 00:46:53,950 --> 00:46:56,660 mean that B is mapping reducible to A? 810 00:46:56,660 --> 00:46:58,250 What about this one? 811 00:46:58,250 --> 00:47:01,610 If A is mapping reducible to B, is the complement 812 00:47:01,610 --> 00:47:03,950 of A mapping reducible to the complement of B, 813 00:47:03,950 --> 00:47:04,760 or maybe neither? 814 00:47:04,760 --> 00:47:17,260 So you can check all that apply, multiple choice, 5 seconds. 815 00:47:20,490 --> 00:47:24,660 Sorry to pressure you, but we have to move on here. 816 00:47:24,660 --> 00:47:26,520 Pick anything. 817 00:47:26,520 --> 00:47:33,290 If you don't know, OK, 1, 2, 3, the end, OK. 818 00:47:36,780 --> 00:47:40,540 Well, the majority is correct. 819 00:47:40,540 --> 00:47:51,170 In fact, it's only B. Now, A really 820 00:47:51,170 --> 00:47:53,150 is not in the spirit of reducibility. 821 00:47:53,150 --> 00:47:59,810 Because as suggested even by the inequality sign there, 822 00:47:59,810 --> 00:48:03,080 A being reducible to B is really a rather different thing than B 823 00:48:03,080 --> 00:48:07,890 being reducible to A. 824 00:48:07,890 --> 00:48:09,482 So that's something. 825 00:48:09,482 --> 00:48:11,190 We're not going to prove that right here. 826 00:48:11,190 --> 00:48:17,760 But that's something that you could think about. 827 00:48:17,760 --> 00:48:22,500 But part B, I think, if you just look here 828 00:48:22,500 --> 00:48:26,370 at the definition of mapping reducibility, 829 00:48:26,370 --> 00:48:30,780 it maps strings in to in and out to out. 830 00:48:30,780 --> 00:48:33,960 Well, that's just going to be if you exchange in and out as you 831 00:48:33,960 --> 00:48:36,900 do when you're flipping compliments on both sides, 832 00:48:36,900 --> 00:48:40,380 it's still by the same f going to still work as a mapping 833 00:48:40,380 --> 00:48:42,420 reduction, OK? 834 00:48:42,420 --> 00:48:47,170 So now we're at our coffee break. 835 00:48:47,170 --> 00:48:54,920 So we're going to take five minutes here, 836 00:48:54,920 --> 00:49:02,910 and I'll be happy to take questions here. 837 00:49:02,910 --> 00:49:03,850 Don't forget the TAs. 838 00:49:03,850 --> 00:49:04,680 They're here to. 839 00:49:08,215 --> 00:49:08,715 OK. 840 00:49:19,530 --> 00:49:21,180 OK, so this is a fair question here. 841 00:49:21,180 --> 00:49:24,360 You know, so we had this notion of a general reduction 842 00:49:24,360 --> 00:49:26,460 and a mapping reduction. 843 00:49:26,460 --> 00:49:27,760 They are not the same. 844 00:49:27,760 --> 00:49:30,210 So any time you have a mapping reduction, 845 00:49:30,210 --> 00:49:33,390 it's going to be an example of a general reduction, but not 846 00:49:33,390 --> 00:49:35,170 the other way around. 847 00:49:35,170 --> 00:49:37,650 So if you go back and look at the reduction 848 00:49:37,650 --> 00:49:41,820 that we offered for HALT TM where 849 00:49:41,820 --> 00:49:46,350 we showed A TM is reducible to HALT TM where we started, 850 00:49:46,350 --> 00:49:49,743 it's actually not a mapping reduction 851 00:49:49,743 --> 00:49:51,660 because we're doing something more complicated 852 00:49:51,660 --> 00:49:55,020 than translating an A TM problem to a HALT TM. 853 00:49:55,020 --> 00:49:58,020 We're kind of using the HALT TM decider 854 00:49:58,020 --> 00:49:59,550 in a more complicated way. 855 00:49:59,550 --> 00:50:03,340 And there are cases where that's actually necessary. 856 00:50:03,340 --> 00:50:08,570 So we're not going to discuss that here. 857 00:50:08,570 --> 00:50:11,360 But it's actually kind of an interesting homework problem 858 00:50:11,360 --> 00:50:14,150 perhaps, or some kind of a problem to think about. 859 00:50:17,078 --> 00:50:22,850 So Turing machines for f's, it's not really a decider, 860 00:50:22,850 --> 00:50:23,893 but it has to be-- 861 00:50:23,893 --> 00:50:26,060 well, I guess it does have to be a decider in a way. 862 00:50:26,060 --> 00:50:26,900 It's always halts. 863 00:50:26,900 --> 00:50:29,090 The Turing machines for f has to always halt. 864 00:50:29,090 --> 00:50:30,570 It always has to have an output. 865 00:50:30,570 --> 00:50:41,910 So f for the computing the function always has to halt. 866 00:50:41,910 --> 00:50:46,730 So someone is asking me, can I explain the statement 867 00:50:46,730 --> 00:50:49,640 that if error halts, then output the same result? 868 00:50:49,640 --> 00:50:53,210 I just mean that in that previous slide, or two 869 00:50:53,210 --> 00:50:57,320 slides back, if R accepts, halts and accepts, 870 00:50:57,320 --> 00:50:58,850 then we're going to halt and accept. 871 00:50:58,850 --> 00:51:02,240 And if R halts and rejects, then we halt and reject. 872 00:51:02,240 --> 00:51:04,400 So I don't know if this is a good idea, 873 00:51:04,400 --> 00:51:06,870 but we can just pull that back here. 874 00:51:06,870 --> 00:51:08,270 So that was the statement here. 875 00:51:08,270 --> 00:51:10,310 If our halts and output the same result, 876 00:51:10,310 --> 00:51:12,980 I just mean that S is going to do the same. 877 00:51:12,980 --> 00:51:18,950 You know, we're translating an A problem to a B problem, 878 00:51:18,950 --> 00:51:21,270 and then answering the B problem. 879 00:51:21,270 --> 00:51:25,740 And we're going to give the same value, the same answer there. 880 00:51:25,740 --> 00:51:29,716 So whatever R says, we're going to say too, 881 00:51:29,716 --> 00:51:35,070 if that's helpful, all right. 882 00:51:37,653 --> 00:51:39,070 Boy, this is a good question here. 883 00:51:41,860 --> 00:51:46,600 If A is reducible to B, why can't we just get B reducible 884 00:51:46,600 --> 00:51:48,400 to A by inverting the function? 885 00:51:48,400 --> 00:51:49,400 That's a great question. 886 00:51:49,400 --> 00:51:52,450 I like that question. 887 00:51:52,450 --> 00:51:57,910 The reason is because the function that's mapping onto B 888 00:51:57,910 --> 00:52:01,420 doesn't have to be onto, subjective I guess. 889 00:52:01,420 --> 00:52:10,030 So if it was onto, so if it covered all of B, 890 00:52:10,030 --> 00:52:13,690 then I think then you would get an invertible function. 891 00:52:13,690 --> 00:52:18,560 And you would get the reduction going the other way as well. 892 00:52:18,560 --> 00:52:21,590 But though, I'm not sure what happens when you have. 893 00:52:21,590 --> 00:52:24,053 It doesn't matter if you have collisions. 894 00:52:24,053 --> 00:52:25,720 It turns out that's not going to matter. 895 00:52:25,720 --> 00:52:28,700 But anyway, let's not get it too complicated here. 896 00:52:28,700 --> 00:52:33,190 But the problem with inverting it is that it's not necessarily 897 00:52:33,190 --> 00:52:42,710 onto the whole range of B. 898 00:52:42,710 --> 00:52:44,165 So we're kind of out of time here. 899 00:52:47,144 --> 00:52:48,970 Is A reducible to A compliment? 900 00:52:48,970 --> 00:52:49,970 Let me just handle that. 901 00:52:49,970 --> 00:52:52,820 No, not necessarily. 902 00:52:52,820 --> 00:52:55,910 It's reducible. 903 00:52:55,910 --> 00:53:00,380 A is reducible to A complement, but not mapping reducible 904 00:53:00,380 --> 00:53:01,250 to A compliment. 905 00:53:01,250 --> 00:53:04,280 But A is general reducible to A compliment. 906 00:53:04,280 --> 00:53:05,810 So actually we'll talk. 907 00:53:05,810 --> 00:53:07,740 I have a slide on that. 908 00:53:07,740 --> 00:53:12,270 So let us move on, OK? 909 00:53:12,270 --> 00:53:14,370 Mapping I think, it's actually this line, mapping 910 00:53:14,370 --> 00:53:16,740 versus general reducibility. 911 00:53:16,740 --> 00:53:19,408 So we're going to contrast it to a bit. 912 00:53:19,408 --> 00:53:21,450 So mapping reducibility, which is what we've just 913 00:53:21,450 --> 00:53:22,990 been talking about has this picture, 914 00:53:22,990 --> 00:53:27,090 which is, I think, a very useful picture to remember. 915 00:53:27,090 --> 00:53:34,590 And because I like to think of a mapping reduction 916 00:53:34,590 --> 00:53:37,740 as a problem translator. 917 00:53:37,740 --> 00:53:40,080 Your problem is sort of in the A domain. 918 00:53:40,080 --> 00:53:43,290 And the mapping reduction allows you to translate that problem 919 00:53:43,290 --> 00:53:46,030 into the B domain. 920 00:53:46,030 --> 00:53:49,750 OK, and then if you have a way of solving it in the B domain, 921 00:53:49,750 --> 00:53:51,220 combining that with the reduction, 922 00:53:51,220 --> 00:53:55,730 you get a solution to the problem in the A domain. 923 00:53:55,730 --> 00:53:59,380 So that's why if A is mapping reducible to B, 924 00:53:59,380 --> 00:54:02,150 and B is solvable, then A is also solvable. 925 00:54:04,700 --> 00:54:08,830 So mapping reduction is a special kind of reducibility, 926 00:54:08,830 --> 00:54:11,440 as opposed to the general notion in general reducibility 927 00:54:11,440 --> 00:54:12,910 where we started. 928 00:54:12,910 --> 00:54:16,990 And it's particularly useful to prove Turing unrecognizability. 929 00:54:16,990 --> 00:54:22,600 So when you want to prove Turing unrecognizability, 930 00:54:22,600 --> 00:54:28,090 as we'll see, general reducibility is not fine 931 00:54:28,090 --> 00:54:31,690 enough in a way, it doesn't sort of differentiate things 932 00:54:31,690 --> 00:54:34,090 as well as mapping reducibility does. 933 00:54:34,090 --> 00:54:37,450 And for that reason, it's not always 934 00:54:37,450 --> 00:54:41,020 going to be useful to prove Turing unrecognizability. 935 00:54:41,020 --> 00:54:43,897 It's better for proving undecidability. 936 00:54:47,240 --> 00:54:49,300 So what we're calling reducibility, 937 00:54:49,300 --> 00:54:52,750 or general reducibility is where we just 938 00:54:52,750 --> 00:54:55,540 use a solvent for B to solve A in sort 939 00:54:55,540 --> 00:54:58,460 of a most general possible way. 940 00:54:58,460 --> 00:55:00,740 So I'm writing that as a picture here. 941 00:55:00,740 --> 00:55:02,920 If you want to solve A, you're going 942 00:55:02,920 --> 00:55:07,942 to use the B solver as a subroutine to solve A. 943 00:55:07,942 --> 00:55:13,270 That's the way we did the HALT TM reduction at the beginning. 944 00:55:13,270 --> 00:55:16,600 But we didn't necessarily translate an A TM problem 945 00:55:16,600 --> 00:55:18,830 to a HALT TM problem. 946 00:55:18,830 --> 00:55:20,850 It's slightly different. 947 00:55:20,850 --> 00:55:23,430 So you can go back and look at that. 948 00:55:23,430 --> 00:55:27,380 So I find that people struggle more with the mapping 949 00:55:27,380 --> 00:55:29,030 reducibility concept. 950 00:55:29,030 --> 00:55:30,680 And that the general reducibility 951 00:55:30,680 --> 00:55:33,650 is what people naturally gravitate towards. 952 00:55:33,650 --> 00:55:36,350 And so in some sense, it's conceptually simpler. 953 00:55:36,350 --> 00:55:38,520 And it's useful to proving undecidability. 954 00:55:38,520 --> 00:55:40,520 But you really have to be comfortable with both. 955 00:55:40,520 --> 00:55:43,430 And especially in the complexity part, 956 00:55:43,430 --> 00:55:48,060 we're going to be focusing on mapping reducibility. 957 00:55:48,060 --> 00:55:52,410 So one noteworthy difference here as sort of foreshadowed 958 00:55:52,410 --> 00:55:55,350 by the person who made this question, which 959 00:55:55,350 --> 00:55:59,220 is a good question, is that A is reducible 960 00:55:59,220 --> 00:56:02,370 using a general reduction to A compliment, which kind of makes 961 00:56:02,370 --> 00:56:03,300 sense. 962 00:56:03,300 --> 00:56:08,702 I mean, if I can test whether things are in A compliment, 963 00:56:08,702 --> 00:56:10,410 well, I can test whether things are in A. 964 00:56:10,410 --> 00:56:13,670 You just invert the answer. 965 00:56:13,670 --> 00:56:17,840 But A may not be mapping reducible to A compliment 966 00:56:17,840 --> 00:56:20,690 because there is a very special kind of reduction. 967 00:56:20,690 --> 00:56:24,945 And you have to just translate things in the language 968 00:56:24,945 --> 00:56:27,320 to things in the language, and things out of the language 969 00:56:27,320 --> 00:56:28,570 to things out of the language. 970 00:56:28,570 --> 00:56:32,000 And they don't necessarily allow you to do that inversion. 971 00:56:32,000 --> 00:56:36,620 So for example, A TM complement is not 972 00:56:36,620 --> 00:56:38,870 mapping reducible to A TM. 973 00:56:38,870 --> 00:56:42,420 Because as we pointed out, anything 974 00:56:42,420 --> 00:56:45,090 that's reducible to a recognizable language 975 00:56:45,090 --> 00:56:46,860 is going to be recognizable. 976 00:56:46,860 --> 00:56:50,100 Anything mapping reducible to a recognizable language 977 00:56:50,100 --> 00:56:52,600 is going to be recognizable. 978 00:56:52,600 --> 00:56:55,390 But we know that A TM complement is not recognizable. 979 00:56:55,390 --> 00:56:56,830 We showed that before. 980 00:56:56,830 --> 00:57:02,076 So it couldn't be mapping reducible to A TM. 981 00:57:02,076 --> 00:57:04,170 It's coming a little fast I realize. 982 00:57:04,170 --> 00:57:07,210 You're going to have to digest it. 983 00:57:07,210 --> 00:57:10,140 So here's the last check in for today. 984 00:57:16,350 --> 00:57:19,740 OK, we showed that if A is mapping reducible to B, 985 00:57:19,740 --> 00:57:23,740 and B is Turing recognizable, then so is A. 986 00:57:23,740 --> 00:57:26,290 And so let's just say that again carefully. 987 00:57:26,290 --> 00:57:32,220 If A is mapping reducible to B, and B is Turing recognizable, 988 00:57:32,220 --> 00:57:37,350 then so is A. And here are the emphasis on Turing recognizable 989 00:57:37,350 --> 00:57:41,030 as opposed to decidable. 990 00:57:41,030 --> 00:57:43,760 Is the same true if we use general reducibility instead 991 00:57:43,760 --> 00:57:47,690 of mapping reducibility? 992 00:57:47,690 --> 00:57:48,540 So you got it? 993 00:57:48,540 --> 00:57:51,350 So we're saying A is mapping reducible to B 994 00:57:51,350 --> 00:57:53,790 using this picture over here. 995 00:57:53,790 --> 00:57:59,670 And we're going to assume that B is Turing recognizable, 996 00:57:59,670 --> 00:58:02,970 so that we have a machine which halts an 997 00:58:02,970 --> 00:58:07,412 accepts when you're inside B, and you know, 998 00:58:07,412 --> 00:58:09,620 is going to reject possibly a looping when you're not 999 00:58:09,620 --> 00:58:10,820 inside B. 1000 00:58:10,820 --> 00:58:16,520 Now, that allows you to get a recognizer for A if you 1001 00:58:16,520 --> 00:58:18,790 have a mapping reduction. 1002 00:58:18,790 --> 00:58:21,040 Does it always work to give you a recognizer 1003 00:58:21,040 --> 00:58:23,210 if you have just a general reduction? 1004 00:58:23,210 --> 00:58:27,087 If you just have now, assuming you have a B solver, 1005 00:58:27,087 --> 00:58:29,170 and you're going to build an A solver out of that. 1006 00:58:32,650 --> 00:58:35,020 OK, so mull that over while I'm setting this thing up. 1007 00:58:37,680 --> 00:58:42,330 Well, the right answer is winning, but not by much. 1008 00:58:42,330 --> 00:58:47,190 I suppose I shouldn't be laughing about it. 1009 00:58:47,190 --> 00:58:49,903 But I knew that this is going to be challenging. 1010 00:58:49,903 --> 00:58:51,570 So I think it's the kind of thing you're 1011 00:58:51,570 --> 00:58:55,630 going to have to work at. 1012 00:58:55,630 --> 00:59:01,790 So let's see we're almost done here, 5 seconds to go. 1013 00:59:01,790 --> 00:59:03,590 Better answer that, I can see a few of you, 1014 00:59:03,590 --> 00:59:09,250 either you've left the room, or you're-- 1015 00:59:09,250 --> 00:59:12,820 OK, 2 seconds, 1, 2, 3. 1016 00:59:12,820 --> 00:59:14,170 Somebody hasn't answered it. 1017 00:59:18,750 --> 00:59:19,300 There we go. 1018 00:59:19,300 --> 00:59:24,000 So the correct answer is B. It's not the same. 1019 00:59:24,000 --> 00:59:26,667 The reason is that in general, I mean, 1020 00:59:26,667 --> 00:59:27,750 the picture is right here. 1021 00:59:35,360 --> 00:59:47,360 Let's see, how do I explain this? 1022 00:59:47,360 --> 00:59:58,080 So we know that a language is going to be-- 1023 00:59:58,080 --> 01:00:00,930 OK, if we're using general disability 1024 01:00:00,930 --> 01:00:11,490 and A is just reducible to B, 1025 01:00:11,490 --> 01:00:14,450 we know that a language is always 1026 01:00:14,450 --> 01:00:19,790 reducible to its complement in using general reducibility. 1027 01:00:19,790 --> 01:00:33,630 So if this were true, then we would have here 1028 01:00:33,630 --> 01:00:40,760 so if this were true, when a language is 1029 01:00:40,760 --> 01:00:43,430 reducible to its complement, if the complement were 1030 01:00:43,430 --> 01:00:46,940 recognizable, the language would also be recognizable. 1031 01:00:46,940 --> 01:00:53,040 That clearly is not going to be the case because you know, 1032 01:00:53,040 --> 01:00:56,390 A TM complement is reducible to A TM 1033 01:00:56,390 --> 01:00:58,820 using general reducibility. 1034 01:00:58,820 --> 01:01:02,690 But A TM complement is not recognizable 1035 01:01:02,690 --> 01:01:04,280 even though A TM is recognizable. 1036 01:01:04,280 --> 01:01:06,950 So we kind of have a proof that this has to be no. 1037 01:01:06,950 --> 01:01:12,170 But as you can see, I'm even getting myself confused. 1038 01:01:12,170 --> 01:01:14,390 So you have to stare at it. 1039 01:01:14,390 --> 01:01:17,630 So let me see, we can try to take a couple of questions 1040 01:01:17,630 --> 01:01:21,960 see if I can clear up people's confusion. 1041 01:01:21,960 --> 01:01:24,720 So why again, is A reducible to its complement 1042 01:01:24,720 --> 01:01:27,090 in the general sense? 1043 01:01:27,090 --> 01:01:29,810 So I'm saying, if you have a solver, 1044 01:01:29,810 --> 01:01:33,410 if you have a decider for A compliment, 1045 01:01:33,410 --> 01:01:38,180 it gives you a solver for A. You just ask the solver, 1046 01:01:38,180 --> 01:01:40,850 is the string in the language or not? 1047 01:01:40,850 --> 01:01:45,240 And now you just give the opposite answer 1048 01:01:45,240 --> 01:01:48,550 if you want to solve the complimentary problem. 1049 01:01:48,550 --> 01:01:53,250 So the A complement is general reducible to A. 1050 01:01:53,250 --> 01:01:56,250 You just invert the answer for whatever the solver is doing 1051 01:01:56,250 --> 01:01:58,830 for A. But you can't just do that inversion when 1052 01:01:58,830 --> 01:02:01,530 you have a mapping reduction. 1053 01:02:01,530 --> 01:02:07,690 It's a much more kind of specific translation that's 1054 01:02:07,690 --> 01:02:08,190 allowed. 1055 01:02:10,910 --> 01:02:12,740 I mean, the fundamental difference 1056 01:02:12,740 --> 01:02:14,990 between general reducibility and mapping reducibility, 1057 01:02:14,990 --> 01:02:17,630 I'm trying to bring it out here. 1058 01:02:17,630 --> 01:02:19,130 It's just a difference in the nature 1059 01:02:19,130 --> 01:02:20,750 of the way things are used. 1060 01:02:20,750 --> 01:02:23,030 Mapping reducibility is a special kind 1061 01:02:23,030 --> 01:02:25,010 of general reducibility. 1062 01:02:25,010 --> 01:02:27,140 So to answer the question about what's 1063 01:02:27,140 --> 01:02:31,580 the fundamental difference, one is using the problem 1064 01:02:31,580 --> 01:02:38,750 as a subroutine and the one is using it as a transformation. 1065 01:02:42,270 --> 01:02:46,540 Anyway, I think we're going to have to move on here. 1066 01:02:46,540 --> 01:02:49,660 And I am going to have couple of examples which may help. 1067 01:02:49,660 --> 01:02:57,750 And then, there are office hours too after the lecture. 1068 01:02:57,750 --> 01:03:02,070 OK, oh, yeah, so I wanted to again to help you. 1069 01:03:02,070 --> 01:03:04,290 I'm putting these down as sort of templates 1070 01:03:04,290 --> 01:03:07,290 for how do you use reducibility. 1071 01:03:07,290 --> 01:03:11,460 I'm not saying you should just apply things blindly. 1072 01:03:11,460 --> 01:03:14,370 But I think it's sometimes good just to see the pattern 1073 01:03:14,370 --> 01:03:16,290 and then to understand how the pattern works. 1074 01:03:16,290 --> 01:03:19,560 So once you just start to understand the pattern 1075 01:03:19,560 --> 01:03:21,100 of how things are used. 1076 01:03:21,100 --> 01:03:24,570 So to show a language is undecidable, 1077 01:03:24,570 --> 01:03:28,700 to prove a language B is undecidable, 1078 01:03:28,700 --> 01:03:32,590 show undecidable languages reducible to B. 1079 01:03:32,590 --> 01:03:36,850 Using just a general reduction is going to be good enough. 1080 01:03:36,850 --> 01:03:39,520 And the template for that is, assume 1081 01:03:39,520 --> 01:03:42,530 we have R deciding B, which you then 1082 01:03:42,530 --> 01:03:48,590 can use as a subroutine when you make a Turing machine S 1083 01:03:48,590 --> 01:03:51,560 deciding A. And that's going to be your contradiction. 1084 01:03:51,560 --> 01:03:55,894 If A was originally shown to be known to be undecidable. 1085 01:03:59,690 --> 01:04:03,260 But now to prove something unrecognizable, this kind 1086 01:04:03,260 --> 01:04:14,060 of reduction it's not as restrictive enough 1087 01:04:14,060 --> 01:04:18,330 because this kind of reduction allows for complementation 1088 01:04:18,330 --> 01:04:21,410 which is not going to be satisfactory when you're trying 1089 01:04:21,410 --> 01:04:23,960 to prove Turing unrecognizable. 1090 01:04:23,960 --> 01:04:27,115 So you're going to have to prohibit the complementation. 1091 01:04:27,115 --> 01:04:29,360 And that's really one of the effects of the mapping 1092 01:04:29,360 --> 01:04:33,470 reducibility if that sort of is getting at the essence of it. 1093 01:04:33,470 --> 01:04:36,950 So you're going to show an unTuring of a recognizable A 1094 01:04:36,950 --> 01:04:39,920 is mapping reducible to B. Often you start out 1095 01:04:39,920 --> 01:04:42,170 with the complement of A TM, which is a language 1096 01:04:42,170 --> 01:04:50,400 we know is Turing unrecognizable as we showed before, 1097 01:04:50,400 --> 01:04:53,820 OK, here the template is you give the reduction function f, 1098 01:04:53,820 --> 01:04:57,930 that computable function, OK. 1099 01:05:00,520 --> 01:05:02,590 So here are going to be two examples, 1100 01:05:02,590 --> 01:05:06,140 one showing that E TM is Turing unrecognizable. 1101 01:05:06,140 --> 01:05:08,470 We showed it was undecidable before. 1102 01:05:08,470 --> 01:05:12,580 Now we're going to show it's even in a sense worse. 1103 01:05:12,580 --> 01:05:16,220 It's not even recognizable. 1104 01:05:16,220 --> 01:05:23,710 And the way we'll do that is to reduce a known unrecognizable 1105 01:05:23,710 --> 01:05:28,375 language to E TM in the emptiness language. 1106 01:05:31,070 --> 01:05:33,550 So here is the picture that we have 1107 01:05:33,550 --> 01:05:37,010 when we're doing mapping reductions. 1108 01:05:37,010 --> 01:05:43,680 We're going to map strings that are in the complement of A TM, 1109 01:05:43,680 --> 01:05:45,630 so strings that are outside of A TM 1110 01:05:45,630 --> 01:05:51,923 if you wish to strings where the language is empty to machines 1111 01:05:51,923 --> 01:05:53,090 where the language is empty. 1112 01:05:53,090 --> 01:05:56,663 And here are strings describing machines which are 1113 01:05:56,663 --> 01:05:57,830 where the language is empty. 1114 01:05:57,830 --> 01:06:04,770 And here we're going to take A TM problems 1115 01:06:04,770 --> 01:06:09,650 and map them to machines where the language is not empty. 1116 01:06:09,650 --> 01:06:11,400 And the thing that's going to do the trick 1117 01:06:11,400 --> 01:06:14,257 is going to be that same reduction function 1118 01:06:14,257 --> 01:06:15,090 that we saw earlier. 1119 01:06:18,760 --> 01:06:22,600 We're going to take that machine w from before, 1120 01:06:22,600 --> 01:06:27,820 the machine that filters out all the non-w's. 1121 01:06:27,820 --> 01:06:36,860 And we're going to take Mw, which is an A TM compliment 1122 01:06:36,860 --> 01:06:37,360 problem. 1123 01:06:40,090 --> 01:06:45,100 So if M rejects w that it's in the complement of A TM, 1124 01:06:45,100 --> 01:06:50,860 and that's supposed to map to a string, a machine which 1125 01:06:50,860 --> 01:07:00,530 is where the language is empty, OK. 1126 01:07:00,530 --> 01:07:04,400 So if Mw is in the complement of A TM, so M rejects w, 1127 01:07:04,400 --> 01:07:06,410 then Mw's language is going to be empty, 1128 01:07:06,410 --> 01:07:08,900 which is what you want to have happen. 1129 01:07:11,510 --> 01:07:12,900 Let me move on to my last. 1130 01:07:12,900 --> 01:07:14,900 I mean, this example is in a way kind of similar 1131 01:07:14,900 --> 01:07:16,100 to the one we did before. 1132 01:07:16,100 --> 01:07:20,540 And I really want to get to the last example here. 1133 01:07:20,540 --> 01:07:24,650 OK, so we'll have to just talk through this 1134 01:07:24,650 --> 01:07:26,690 rather than having it build. 1135 01:07:29,480 --> 01:07:31,730 Let's take EQ TM. 1136 01:07:31,730 --> 01:07:35,870 That's the equivalence problem for Turing machines. 1137 01:07:35,870 --> 01:07:39,485 Do they recognize the same language? 1138 01:07:43,520 --> 01:07:47,630 So this is a language of a new kind for us. 1139 01:07:47,630 --> 01:07:51,020 This is a language where neither it nor its complement 1140 01:07:51,020 --> 01:07:53,648 are going to be recognizable, Turing recognizable. 1141 01:07:58,330 --> 01:08:05,550 So the way we get that is, the way we show problems are not 1142 01:08:05,550 --> 01:08:11,830 recognizable is mapping reduce a non-recognizable language 1143 01:08:11,830 --> 01:08:14,020 to typically the complement of A TM. 1144 01:08:14,020 --> 01:08:17,020 So we're going to mapping reduce the complement of A TM 1145 01:08:17,020 --> 01:08:23,200 to both EQ TM and to the complement of EQ TM 1146 01:08:23,200 --> 01:08:26,930 to show that both of those are not recognizable. 1147 01:08:26,930 --> 01:08:30,140 And here we're going to introduce a new machine 1148 01:08:30,140 --> 01:08:35,410 that we're going to be building inside the reduction function. 1149 01:08:35,410 --> 01:08:39,960 And that's going to be a machine I'm going to call Tw. 1150 01:08:39,960 --> 01:08:44,880 And Tw is a machine that always behaves the way 1151 01:08:44,880 --> 01:08:48,800 M behaves on w for every input. 1152 01:08:48,800 --> 01:08:53,600 So if M accepts w, T is going to accept everything. 1153 01:08:53,600 --> 01:08:57,850 If M rejects w, T is going to reject everything. 1154 01:08:57,850 --> 01:09:02,740 So it copies the behavior of M on w onto all inputs. 1155 01:09:02,740 --> 01:09:05,649 And the way I describe that machine Tw is it 1156 01:09:05,649 --> 01:09:06,520 ignores its input. 1157 01:09:06,520 --> 01:09:11,979 Whatever the input is, it just simulates M on w. 1158 01:09:11,979 --> 01:09:14,830 You could easily give an M and w, 1159 01:09:14,830 --> 01:09:16,899 you can build the machine Tw. 1160 01:09:16,899 --> 01:09:20,080 It just always runs M on w, no matter what input it gets. 1161 01:09:22,792 --> 01:09:24,750 And so now we're going to give a function which 1162 01:09:24,750 --> 01:09:27,779 maps A TM problems which have the form Mw. 1163 01:09:27,779 --> 01:09:30,040 So it's an A TM compliment problem. 1164 01:09:30,040 --> 01:09:33,790 So this want to test if M accepts w or not. 1165 01:09:33,790 --> 01:09:36,840 So that's an A TM compliment-type problem. 1166 01:09:36,840 --> 01:09:40,960 And I want to map that to an EQ TM problem with the form-- 1167 01:09:40,960 --> 01:09:44,140 you know, EQ TM problems repairs the machine 1168 01:09:44,140 --> 01:09:46,191 now, and where going to be testing equivalence. 1169 01:09:46,191 --> 01:09:48,399 So I'm just trying to give you the form of the output 1170 01:09:48,399 --> 01:09:52,300 of the reduction function f. 1171 01:09:52,300 --> 01:09:53,680 And specifically, what it's going 1172 01:09:53,680 --> 01:10:00,250 to look like is when we have f is processing on Mw, 1173 01:10:00,250 --> 01:10:01,720 it's going to produce two machines. 1174 01:10:01,720 --> 01:10:06,660 One of them is going to be Tw which always behaves 1175 01:10:06,660 --> 01:10:11,680 the way M behaves on w but expanded to all inputs, 1176 01:10:11,680 --> 01:10:17,230 and then a machine I'm going to call T reject, which just is 1177 01:10:17,230 --> 01:10:19,335 designed to reject everything. 1178 01:10:22,070 --> 01:10:25,690 Now, just walk through the logic with me. 1179 01:10:25,690 --> 01:10:32,470 If M rejects w, Tw rejects everything. 1180 01:10:32,470 --> 01:10:37,330 And so we'll be equivalent to the machine T reject. 1181 01:10:37,330 --> 01:10:38,740 That's what we want. 1182 01:10:38,740 --> 01:10:44,157 If M rejects w, so we're in the language A TM compliment, 1183 01:10:44,157 --> 01:10:46,240 then these two machines that I produce for you are 1184 01:10:46,240 --> 01:10:50,430 going to be in the EQ TM line. 1185 01:10:50,430 --> 01:10:52,670 That's what I want to have happen 1186 01:10:52,670 --> 01:10:57,570 for a reduction from A TM compliment to EQ TM. 1187 01:10:57,570 --> 01:11:02,670 Similarly, to do part 2, I'm going 1188 01:11:02,670 --> 01:11:06,930 to make here a different f, maybe I should call it f prime, 1189 01:11:06,930 --> 01:11:09,910 all right, f1 and f2 for the two different parts. 1190 01:11:09,910 --> 01:11:12,240 So these are two different f's. 1191 01:11:12,240 --> 01:11:13,380 I'm going to make f here. 1192 01:11:16,500 --> 01:11:20,070 Instead of generating Tw and T reject, 1193 01:11:20,070 --> 01:11:21,970 I'm going to have Tw and T accept 1194 01:11:21,970 --> 01:11:26,020 which is a Turing machine that always accepts its input. 1195 01:11:26,020 --> 01:11:32,850 Now, if M rejects w, it's in A TM compliment, 1196 01:11:32,850 --> 01:11:35,790 then Tw is going to reject everything. 1197 01:11:35,790 --> 01:11:40,230 And it's going to be different from its companion here, 1198 01:11:40,230 --> 01:11:41,810 T accept. 1199 01:11:41,810 --> 01:11:45,980 And so it won't be in EQ TM compliment. 1200 01:11:45,980 --> 01:11:50,360 But if M accepts w, then Tw is going to accept everything. 1201 01:11:50,360 --> 01:11:53,180 And it's going to be equivalent to T accept. 1202 01:11:53,180 --> 01:11:56,220 And you will be equivalent. 1203 01:11:56,220 --> 01:11:59,750 So the here is where we're taking A TM compliment 1204 01:11:59,750 --> 01:12:02,282 and mapping it to the compliment, the EQ TM. 1205 01:12:05,730 --> 01:12:08,370 Too many compliments here I realize. 1206 01:12:08,370 --> 01:12:09,640 Compliments are confusing. 1207 01:12:09,640 --> 01:12:13,140 But anyway, why don't you mull this over. 1208 01:12:13,140 --> 01:12:21,390 And just to summarize, OK, we're out of time here. 1209 01:12:21,390 --> 01:12:25,410 But why do we use reducing when we talk about reductions? 1210 01:12:25,410 --> 01:12:27,660 It's because when we reduce A to B, 1211 01:12:27,660 --> 01:12:30,990 we kind of bring A's difficulty down to B's difficulty, that's 1212 01:12:30,990 --> 01:12:34,510 where the reducing comes from. 1213 01:12:34,510 --> 01:12:38,210 Or we bring B's difficulty up to A's difficulty, 1214 01:12:38,210 --> 01:12:41,290 because it's really A's difficulty relative to B 1215 01:12:41,290 --> 01:12:43,750 that we're talking about when we're reducing A to B. 1216 01:12:43,750 --> 01:12:48,400 So that's why the term reducing seems a little out of place 1217 01:12:48,400 --> 01:12:51,430 when we're proving things undecidable, or unrecognizable. 1218 01:12:51,430 --> 01:12:52,930 But that's where it's coming from. 1219 01:12:52,930 --> 01:12:56,510 Anyway, quick review, we introduced 1220 01:12:56,510 --> 01:12:58,480 the reducibility method. 1221 01:12:58,480 --> 01:13:01,630 We defined mapping reducibility as a special kind 1222 01:13:01,630 --> 01:13:02,920 of reducibility. 1223 01:13:02,920 --> 01:13:06,310 We showed E TM as undecidable and unrecognizable. 1224 01:13:06,310 --> 01:13:09,340 And that EQ TM is both, it and it's 1225 01:13:09,340 --> 01:13:11,290 complement are unrecognizable. 1226 01:13:11,290 --> 01:13:13,480 So we're out of time. 1227 01:13:13,480 --> 01:13:16,220 I will shut this down. 1228 01:13:16,220 --> 01:13:18,197 But I'll take a few questions here actually. 1229 01:13:18,197 --> 01:13:19,780 I'll stick around for a few questions. 1230 01:13:19,780 --> 01:13:24,580 And then I'll move to the other chat room for office hours, OK? 1231 01:13:27,280 --> 01:13:34,950 So question, go over the case for the complement of EQ TM. 1232 01:13:34,950 --> 01:13:35,790 So I will do that. 1233 01:13:38,810 --> 01:13:43,000 So that's in this slide here. 1234 01:13:43,000 --> 01:13:51,790 OK, so this is proof part 2 for the person 1235 01:13:51,790 --> 01:13:53,080 who asked me to go over it. 1236 01:13:53,080 --> 01:13:56,920 But I think it's helpful for those of you who might 1237 01:13:56,920 --> 01:13:58,690 be a little bit shaky on this. 1238 01:14:01,270 --> 01:14:04,020 I want to mapping reduce the complement of A TM 1239 01:14:04,020 --> 01:14:05,325 to the complement of EQ TM. 1240 01:14:09,617 --> 01:14:11,950 By the way, I don't know if this is going to be helpful. 1241 01:14:11,950 --> 01:14:14,970 But as we pointed out in the check in a while back, 1242 01:14:14,970 --> 01:14:18,390 that's completely equivalent to having a mapping 1243 01:14:18,390 --> 01:14:21,270 reduction from A TM to EQ TM. 1244 01:14:21,270 --> 01:14:25,620 You can complement both sides, and you 1245 01:14:25,620 --> 01:14:28,530 get an equivalent statement. 1246 01:14:28,530 --> 01:14:32,430 Maybe let's stick with the compliments here though. 1247 01:14:32,430 --> 01:14:36,740 I hope that doesn't make it too confusing, OK. 1248 01:14:36,740 --> 01:14:39,200 We're trying to show the complement of A TM 1249 01:14:39,200 --> 01:14:42,170 is mapping reducible to the complement of EQ TM. 1250 01:14:42,170 --> 01:14:43,740 What does that mean? 1251 01:14:43,740 --> 01:14:49,490 So that means when M rejects w, so you're in the compliment, 1252 01:14:49,490 --> 01:14:55,130 we want the two Turing machines to be inequivalent. 1253 01:14:55,130 --> 01:14:58,235 No, yeah, so we're in the compliment of EQ TM. 1254 01:15:00,920 --> 01:15:04,010 So in other words, when we're in the complement of A TM, 1255 01:15:04,010 --> 01:15:12,090 we want the result of the f to be in the complement of EQ TM. 1256 01:15:12,090 --> 01:15:14,220 So in other words, when M rejects w, 1257 01:15:14,220 --> 01:15:16,020 the two machines should be inequivalent. 1258 01:15:19,690 --> 01:15:20,230 Right? 1259 01:15:20,230 --> 01:15:24,830 When M accepts w, the two machines should be equivalent. 1260 01:15:24,830 --> 01:15:29,090 Because when we're not in this language, so we're in A TM, 1261 01:15:29,090 --> 01:15:30,800 we want to be not in that language. 1262 01:15:30,800 --> 01:15:32,810 So we should be in EQ TM. 1263 01:15:32,810 --> 01:15:36,980 So when M accepts w, we should be equivalent. 1264 01:15:36,980 --> 01:15:39,710 When M rejects w, we should be inequivalent. 1265 01:15:39,710 --> 01:15:41,640 That's what we want. 1266 01:15:41,640 --> 01:15:44,220 Let's go down here. 1267 01:15:44,220 --> 01:15:51,720 So if M accepts w, we want them to-- so when M accepts w, 1268 01:15:51,720 --> 01:15:52,970 we want them to be equivalent. 1269 01:15:52,970 --> 01:15:57,260 So if M accepts w, Tw accepts everything. 1270 01:15:57,260 --> 01:15:59,270 And it's equivalent to T accept. 1271 01:15:59,270 --> 01:16:06,280 When M rejects w, Tw rejects everything. 1272 01:16:06,280 --> 01:16:08,170 And so it's not equivalent to the machine 1273 01:16:08,170 --> 01:16:09,960 that accepts everything. 1274 01:16:09,960 --> 01:16:15,493 So just go through the logic yourself. 1275 01:16:15,493 --> 01:16:16,660 You'll see why it's working. 1276 01:16:21,210 --> 01:16:24,200 All right, so, bye, bye, everyone.