Chaya·Edu EDU.CHAYA.DEV
AI 232 · Theory of Computation · Notes 12

Notes 12 · Sessions 22–23 · Tuesday & Thursday, November 17 & 19, 2026

The Impossibility Photocopier

Last week we dug one hole, by hand, with a machine built out of spite. Tonight we stop digging: one ordinary trick copies that hole onto question after question — and then a stamp finishes the job wholesale.

Unit Week 12 Meets 6:00–7:50 PM · Google Meet This week Project 3 due Mon Nov 16, 11:59 PM Next Notes 13 · Time complexity, P, and NP
01

One hole, dug by hand

Last week you watched a job die. The stopping question — does this machine stop, on this input? — turned out to have no full-warranty answer, not now, not ever, because any checker that claims one can be wired into a Contrarian and fed its own rule table. That argument took real work: a custom machine with a bad attitude, two branches that eat themselves, a story you practiced telling in under a minute. Here is tonight's good news. You will never have to do that work again.

Because last week also hid a second trick in plain sight, and it's the one that scales. When we settled the watch-and-wait job — "does this machine ever say yes?" — we did not build a second Contrarian. We rewired: edit any machine so that every way of stopping says yes, and suddenly a solver for "ever says yes?" would hand you a solver for "does it stop?" — which is impossible, so the solver is too. And the notes told you, in so many words: file away the shape of that rewiring move — "if you could do this job, you could do halting." Next week we industrialize it.

It's next week. The Contrarian dug one hole. Tonight's gadget — call it the impossibility photocopier — copies that hole onto any question you can wire it to. By the end of the evening you'll have run the photocopier yourself, pointed it at three different questions, learned the one direction rule that keeps it honest, and then met the result that makes even the photocopier look slow: a single stamp that covers almost every question about what a program does. One hole, dug once, spent forever.

Dig one hole by hand. Then photocopy it onto everything else.
02

The photocopier: a translator, not a solver

Here's the machine at the heart of tonight, and the first thing to notice is how humble it is. The photocopier's engine is just a translator: a plain, ordinary program — with a full warranty of its own, it always finishes — that takes any instance of the stopping question and rewrites it as an instance of some new question, so that the answers match. If the old answer was yes, the new answer is yes. If the old answer was no, the new answer is no. The translator never solves anything. It never even runs anything. It just rephrases.

The translator — the photocopier's engine

An ordinary, always-finishing program that turns every instance of the stopping question into an instance of the new question, with the same answer — yes becomes yes, no becomes no. Build one of these, and the new question inherits the hole: a full-warranty solver for the new question, with the translator bolted on the front, would be a full-warranty solver for the stopping question. The Contrarian already buried that. So no such solver exists.

Read that argument once more, slowly, because it's the whole night. Suppose somebody claims to sell a solver for the new question — always stops, always right. You bolt the translator onto the front of their box: stopping question in, translated, their solver answers, and the answer carries straight back, because the translator made the answers match. You are now holding a working halting checker. But there is no working halting checker — a one-page argument with a barber in it made sure of that, permanently. The only way out: the solver they claimed to sell was never real.

the stopping question a stored machine + a stored input THE TRANSLATOR ordinary code always finishes runs nothing — rewrites the new question a freshly built machine A SOLVER (pretend it exists) dashed for a reason the answer flows home: YES means "it stops" · NO means "runs forever" translator in front + solver in back = a halting checker. no halting checker exists — so no solver does.
The photocopier, assembled. Everything solid in this picture is boring, legal, buildable code. The only dashed box is the solver — and the pipeline shows exactly why it has to stay imaginary.
The official name

Textbooks call the translator a mapping reduction — "reduce" as in: the stopping question reduces to the new question, old hole poured into new ground. The name is fine, the pictures in those books are fine, and when you meet the idea again in a later course you'll recognize it instantly. In this room we'll keep calling the whole rig the photocopier, because that's what it does: it doesn't solve the new question, it copies an old impossibility onto it.

Think first: the translator never runs the stored machine. How can it get away with being that lazy?

Because its job is to rewrite the question, not answer it. Writing a program down is not running it — you did exactly this in Project 3 every time your workbench loaded a rule table it hadn't pressed play on. The translator copies the stored machine inside a new machine, like a letter sealed into an envelope, and finishes. If the translator ever had to run the stored machine to see what happens, it might hang — and then it wouldn't be a translator anymore, just another victim.

03

Photocopy no. 1: the ever-yes question

Time to build one, slowly, bolt by bolt. Target: the ever-yes question — "does this machine ever say yes, to any input at all?" Last week a quick rewiring showed this question is hopeless; tonight we redo it as an official photocopy, because this exact build is the template for every other one you'll ever make.

The translator receives an instance of the stopping question: a stored machine and a stored input, stapled together. It must output a single new machine whose ever-yes answer equals the stopping answer. Here's the machine it writes — call it the wrapper. The wrapper's entire program is three lines:

  1. Throw your own input away. Whatever you were handed — abba, the empty page, a love letter — into the trash, unread.
  2. Run the stored machine on the stored input. The one sealed in the envelope. Just run it, step by step, like the workbench does.
  3. If that run ever finishes — any way at all, yes or no — say yes.
THE WRAPPER the machine the translator writes any input (doomed) ① trash it, unread ② run the envelope the stored machine, on the stored input step by step, workbench-style finished? ③ say YES however it finished if the stored run STOPS… step ② always ends, on every input, so every run reaches ③: the wrapper says yes to EVERYTHING if the stored run NEVER stops… every run of the wrapper is stuck at ② forever; ③ is never reached: the wrapper says yes to NOTHING
The wrapper, inside and out. One machine, two possible lives — and which life it lives is decided entirely by the envelope. All-or-nothing by design: there is no third behavior.

Now check the mirror, both ways, because the matching answers are the entire job. If the stored run stops: step two always finishes — on every input the wrapper is handed, because step one threw that input away, so every run is the same run. Everything reaches step three. The wrapper says yes to everything, so "does it ever say yes?" is yes. If the stored run never stops: the wrapper spends eternity inside step two — again on every input — and never reaches the yes. Its yes pile is empty, so the ever-yes answer is no. Stops ↔ yes. Runs forever ↔ no. A perfect mirror — which means a solver for ever-yes, with this translator in front, answers the stopping question. Stamp it: the ever-yes question has no full warranty, ever.

One design choice deserves a spotlight: why does the wrapper trash its own input? Because the mirror needs the wrapper's fate to be all-or-nothing. If the wrapper peeked at its input, different inputs might end differently, and "ever says yes" would tangle up with what got fed in. Trash the input, and the wrapper has exactly one possible life, replayed on every input: either everything gets a yes or nothing does, and which one depends only on the envelope. That one rude move — ignore the customer, consult the envelope — is the signature move of nearly every photocopy ever built.

Think first: last week's rewiring turned REJECT into ACCEPT. Tonight's wrapper looks different. Is it the same trick?

Same trick, better packaging. Last week's rewiring answered "does the stored machine ever say yes?" by editing the stored machine itself — fine for that one question. The wrapper is the industrial version: it leaves the stored machine untouched inside the envelope and builds the mirror around it. That outer shell is what you can re-aim: swap what happens after "if the run finishes…" and the same chassis photocopies the hole onto a brand-new question. You'll re-aim it twice before the night is out.

04

Photocopy no. 2: the twins question

Second target, and this one should sting a little, because every teacher on Earth wants it: the twins question, also known as the same-yes-pile question — "do these two machines have the same yes pile?" Say yes to exactly the same inputs, no to exactly the same inputs: twins in behavior, whatever their rule tables look like. A solver for this is the dream autograder: compare the student's code to the reference answer on all inputs at once, no test cases needed.

The photocopy takes two sentences. The translator builds the same wrapper as before — trash your input, run the envelope, say yes if it finishes — and then grabs one more part off the shelf: the cheerleader, a one-rule machine that says yes to everything, instantly, no questions asked. The instance of the twins question is the pair: wrapper on the left, cheerleader on the right. Are they twins?

Walk the mirror. If the stored run stops, the wrapper says yes to everything — which is precisely the cheerleader's yes pile. Same pile: the twins answer is yes. If the stored run never stops, the wrapper's pile is empty while the cheerleader's pile is everything — as far from twins as two machines can be. The answer is no. Stops ↔ yes, runs forever ↔ no, mirror confirmed. A twins solver would answer the stopping question through this two-sentence translation, so: stamped. No machine can always tell whether two machines behave the same. The dream autograder joins the halting checker in the museum of gadgets that never were.

Workshop note · parts on the shelf

You could have used the opposite teammate instead: the stonewaller, a machine that says yes to nothing, ever. Pair the wrapper with the stonewaller and the mirror simply flips — twins exactly when the stored run never stops, so a twins solver would still answer the stopping question, just with its yes and no swapped (swapping yes and no is one line of extra wiring; the translator's answers still match after the swap). The lesson: photocopies aren't fragile recipes. Once you own the wrapper, most builds are "wrapper, plus one stock part, plus one sentence of checking."

05

Point it the right way

Every powerful tool has the one way to hold it wrong, and here is the photocopier's. The translation must run from the question you already know is impossible, into the new one. From the stopping question, into fresh territory. Point it the other way and the machine still hums, lights still blink — and it proves absolutely nothing.

The direction rule — read twice, tattoo once

To stamp a new question, show: "a solver for the NEW question would let me answer the STOPPING question." That drags the new question down into the hole. Showing the reverse — "a halting checker could answer my new question" — says only that an impossible, magical gadget could do the job. Of course it could. A genie could too. Nothing true about the genie's to-do list makes your question hard.

Here's the analogy to keep: "If I could lift the car, I could certainly lift the couch." True! And it tells you nothing about the couch, because you can't lift the car — a claim that starts from an impossible feat ends nowhere. The useful direction is the other one: "if I could lift the couch, I could lift the car" — say, because a cunning system of levers turns one into the other. That would be big news about the couch: since the car is beyond everyone, the couch must be too. The translator is exactly that system of levers, and it must turn couch-lifting into car-lifting, not the reverse.

POINTED RIGHT ✓ "a solver for the NEW question would answer the STOPPING question" stopping question translate new question so if the new question had a solver, the halting checker would be reborn. it can't be. verdict: NEW Q: STAMPED POINTED WRONG ✗ "a HALTING CHECKER could answer my new question" halting checker (doesn't exist!) new question an impossible gadget "could" do anything. the new question might still be easy — a genie could also count your rule rows. PROVES NOTHING "if I could lift the car, I could lift the couch" — true, and worthless as news about the couch. you want: "if I could lift the couch, I could lift the car." THEN the couch is in trouble.
The direction rule, both ways. The impossibility flows along the arrow, from old question to new — never against it. On the exam, this is the single most common place to faceplant; in the lab below, the pipeline always starts at the stopping question for exactly this reason.
Think first: a classmate announces "a halting checker could easily answer my question, so my question is impossible." What did they actually show?

Nothing about their question. A halting checker could "easily answer" whether a rule table has ten rows, too — an impossible gadget is allowed to be good at everything, that's the perk of not existing. To stamp their question they need the arrow reversed: a translator turning every stopping-question instance into an instance of their question, answers matching. If they can't build that translator, maybe their question is simply… answerable.

06

The stamp: behavior, not paper

After a few photocopies, a pattern should be itching at you. Ever says yes? Stamped. Says yes to the empty page? Stamped — same wrapper, we'll run it in the lab. Same yes pile as another machine? Stamped. Every target so far has been a question about a machine's behavior — about its yes pile, about what it does. And meanwhile a whole family of questions never gets stamped at all, because they're not about behavior. They're about the paper.

"Does the rule table have more than ten rules?" Count the rows. "Does it ever mention the letter b?" Read the table. "More than five states?" List them. These are questions about the document — ink on a page, finite, sitting still, fully visible. You don't predict anything; you look. Full warranty, trivially, every time. The entire dark magic of this course lives on the other side of that line, where a finite page of ink commits the machine to an endless, unreadable future.

rule 1: go,a → go,R… THE PAPER how many rules? mentions b? how many states? just look — full warranty every run, on every input, out to forever — the yes pile THE BEHAVIOR ever says yes? yes to the empty page? same pile as this other machine? NO FULL WARRANTY — EVER one sheet of ink on the left commits the machine to the whole endless cloud on the right
The whole law in one picture. Questions about the page: look and answer. Questions about the cloud: stamped — with two carve-outs below that make the law exact.

The stamp, stated plainly

The stamp

Every question about a machine's behavior — about its yes pile — gets the stamp: no full warranty, ever. Every one, with exactly one carve-out: the question must not be trivial. Trivial means the answer doesn't depend on the machine — every machine passes, or every machine fails ("does it have a yes pile, possibly empty?" — everyone passes; nothing to decide, nothing to stamp). The moment a behavior question can tell at least two machines apart — some machine would pass it, some machine would fail it — it's stamped. Not "most such questions." All of them.

And one honest boundary from the other side: the stamp is about the machine's whole, unbounded behavior. A question with a built-in patience slider — "does it stop within 1,000 steps on this input?" — isn't in the cloud at all. Just run it for 1,000 steps and look; a bounded run is a finite job, full warranty, done. The stamp owns the questions where the answer could hide past every step count you'll ever reach.

Here's why you should believe it

One photocopier template handles every behavior question at once — that's the whole argument, and you already own every part. Take any behavior question that isn't trivial. First, look at the machine whose yes pile is empty (the stonewaller's pile): either it fails your question or it passes. Say it fails (if it passes instead, run everything below with your yes-glasses and no-glasses swapped — one extra wire, like in the twins build). Second, since your question isn't trivial, some machine passes it — pick any one and call it the pet. Now re-aim the wrapper from photocopy no. 1, changing only line three:

  1. Hold your input — don't read it yet.
  2. Run the envelope: the stored machine on the stored input.
  3. If that run ever finishes, dig your input back out and behave exactly like the pet on it — same answer the pet would give, yes or no.

If the stored run stops, every run of this wrapper gets past step two, and from there it is the pet, answer for answer: its yes pile is the pet's yes pile, so it passes your question. If the stored run never stops, the wrapper never answers yes to anything: empty pile, and we arranged for the empty pile to fail. Passes ↔ stops. Fails ↔ runs forever. That's a working translator from the stopping question into your question — whichever behavior question it was, because nothing in the build cared which. A solver for your question would resurrect the halting checker. Stamp comes down. The photocopier didn't just copy the hole one more time. It copied it onto an entire category, in one motion.

The official name · Rice's theorem

This wholesale result is Rice's theorem, worked out by the logician Henry Gordon Rice in his doctoral research around 1951. Textbook phrasing: every non-trivial property of what a program computes is undecidable. Same sentence we just said — behavior, not paper; not trivial; stamped — wearing a suit. It's widely considered the single most devastating one-liner in computer science: an infinite family of impossibility results, each of which would have been a respectable discovery on its own, dispatched by one reusable wrapper.

Think first: "does this machine's rule table contain a rule leading to ACCEPT?" — paper or behavior?

Paper — read the table and look for the word ACCEPT; full warranty. And here's the fun part: it sounds like it should settle "does it ever say yes?", but it doesn't even come close. A table can contain an ACCEPT rule that no run ever reaches — a door at the end of a hallway nobody ever walks down. Whether the door is drawn on the blueprint is paper. Whether anyone ever walks through it is behavior. That hallway is exactly the gap the stamp lives in.

07

The wall of stamped dreams

Let's spend the stamp. Each of these is a product somebody — your future boss, possibly — will one day ask you to build "perfectly." Each is a behavior question in a trench coat, and each one is already on the wall.

STAMPED

The perfect virus scanner

"Flag every program that will ever do harm — and never cry wolf." Whether a program ever misbehaves is pure behavior. Perfect scanning died tonight; "suspicious" lives on.

STAMPED

The perfect dead-code finder

"This line can never run — delete it safely." Whether a line is reached on some input is the ever-yes question with a line number taped to it.

STAMPED

"Will it ever return 7?"

Pick any value you like. "Does this function ever output it, on any input?" — ever-yes in a costume. Same wrapper, same funeral.

STAMPED

The dream autograder

"Does the student's code match the reference on all inputs?" The twins question with a gradebook. Your homework is safe from perfection forever.

STAMPED

The loop-catching compiler

"Refuse to compile anything containing an infinite loop." That's the stopping question itself, asked at the factory door. The original hole.

STAMPED

The always-safe optimizer

"Replace slow code with fast code, guaranteed to behave identically everywhere." Identical behavior everywhere — the twins question again, in a race car.

Now, before this turns into a funeral: look around. Virus scanners exist. Dead-code warnings exist. Autograders graded your Project 2. The wall didn't kill the tools — it killed the word perfect, and real tools shrugged and kept shipping, because they were never built on full warranties in the first place. They live on the fine print, and on something even humbler: the patience slider.

The hopeful turn · impossible to be perfect, easy to be useful

Last week's quiz already taught you the move: your IDE says "possible infinite loop," your scanner says "suspicious," your autograder runs the student's code on two hundred test inputs with a timeout — a bounded run, full warranty on each — and reports what it saw. Timeouts, approximations, "maybe": every one of those is an engineer politely stepping around tonight's wall instead of walking into it. The stamp forbids a tool that's always right. It says nothing against a tool that's right ninety-nine percent of the time, honest about the rest, and shipped by Friday. That gap between "perfect" and "useful" is where your entire career fits.

08

Lab: the photocopier, live

Run the production line yourself. Pick a target question and a test case, then step the order through the pipeline: watch the translator wire up the wrapper, watch the wrapper's fate get decided by the envelope, let the pretend solver answer, and watch the verdict flow home. Do all three targets, both cases each — six runs. By the third run you'll be narrating the steps before clicking them, which is the point.

Lab · the photocopier, live

three targets · two test cases · one hole

ORDER IN
Think first: the lab's pipeline always starts at the stopping question, never at the target. Why is that hard-wired?

The direction rule, §05. The impossibility flows from the old hole into the new ground, so the order must enter as a stopping-question instance and leave as a target-question instance. If the lab let you feed a target instance in and translate toward the stopping question, the lights would still blink — and the final STAMPED badge would be a lie, the car-to-couch direction. The machine is built so the honest direction is the only one it can run.

09

Lab: the stamp office

You're the clerk now. Twelve question cards hit your desk, one at a time. For each, decide: is it answerable with a full warranty — a paper question you can settle by looking, or a bounded run you can settle by running — or is it a genuine behavior question that gets the stamp? Fair warning: several cards are dressed to fool you, in both directions. The feedback is instant and each reason is one sentence; a wrong sort here is the cheapest tuition you'll pay all semester.

Lab · the stamp office

sort all 12 · traps included

SORT IT
sorted: 0 right, 0 wrong
Think first: the trap card "does it stop within 1,000 steps on this input?" went in the full-warranty bin. Change one word and it's stamped. Which word?

Delete "within 1,000 steps" — or change "1,000 steps" to "ever." The bound is the entire difference. With a cap, the job is finite: run, count, answer, done, no matter how the run behaves. Without the cap, "still running" never ripens into "never stops," and you're back at the original hole. Your Project 3 workbench is a full-warranty machine precisely because it carries a patience slider — and only ever claims what the slider lets it see.

10

Quick check

Six questions. Decide on your answer before you click — being wrong here is free, and useful.

0 of 6 answered
11

Before next week

Two weeks ago you owned one machine. Last week, one impossibility. Tonight, an infinite supply of both. Spend some of it:

Coming up

Notes 13 — time complexity, P, and NP. And with it, the great turn of the whole course. For eleven weeks we've asked one question: can this be done at all? We built the shelves, found the walls, stamped the impossible. Next week the question changes costume and becomes the one your laptop actually cares about: can it be done before the sun burns out? Because here's the uncomfortable discovery waiting there — a job can carry a full warranty, decidable, provably doable… and still need more steps than there are atoms in the universe. Possible is not the same as practical, and the gap between those two words contains the most famous unsolved question in computer science. Bring your patience slider. It's about to become the main character.

If anything tonight didn't land, email me — yair.chaya@liu.edu — or grab an office-hours slot. I reply within 24 hours.