Tuesday, November 12, 2019

logical deduction - Switcheroo - Which switch turns on the light bulb?


There is a famous puzzle, asked several times on this site, regarding a light bulb hidden in a room. There are three switches outside. You can flip them however you want, but you cannot continue flipping them once you've opened the door to the bulb. How do you figure out which switch connects to the bulb? The answer, which I'll put in spoilers for those who don't know yet, is:



You flip one switch on, wait a few minutes, flip it off, and flip another switch on, then open the door. If it's on, it's the second switch. If it's off, but it's hot, it's the first switch. If it's off, but cold, it's the switch you didn't touch.



My question is as follows: Assuming you don't have a thermometer, can you increase the total number of switches beyond three and still be able to tell which switch connects to the bulb?



Once you're done with this one, check out the sequel.



Answer



The Pigeonhole Principle, if I'm interpreting the problem space correctly, should put an absolute upper bound of four switches on the question as it stands.


You have given a restriction that temperature is a binary state: hot or cold. Assuming the only other output is whether the light is shining, we have only four states:



  1. Hot and Lit => A

  2. Hot and Unlit => B

  3. Cold and Lit => C

  4. Cold and Unlit => D



The pigeonhole principle says every possibility has to go into one of those buckets, A-D. So if you had 5 switches, at least one of those buckets is guaranteed to have two possible entries (e.g. B = Switch 1 OR Switch 5). Now just from the nature of the outputs, we can't even get those 4 switches, but that's less theoretical and more nuanced.


Edit:


That said if you're looking for more cutesy answers, you can stretch it to four with a third output:



Whether the filament is intact (assuming a quality lightbulb). Flip switch one. Wait 100 years, then turn it off. Flip switch two for 5 minutes, then turn it off. Flip switch three. Enter the room. If the bulb's filament is destroyed, it was switch one. If it's hot but off, it was switch two. If it's on, it was switch three. Otherwise, it's switch four.



No comments:

Post a Comment

classical mechanics - Moment of a force about a given axis (Torque) - Scalar or vectorial?

I am studying Statics and saw that: The moment of a force about a given axis (or Torque) is defined by the equation: $M_X = (\vec r \times \...