The Evil Genius
Do our computers live in a simulation?
René Descartes is famous for countless things in mathematics—Cartesian products, Cartesian coordinates, Descartes’ rule of signs, the folium of Descartes. He is also famous for his work in philosophy and the notion of an evil genius. The evil genius presents a full illusion of a reality, and “fools” Descartes into believing there is a reality, while actually there is none.
Today Ken and I want to talk about the evil genius, and its relationship to the simulation hypothesis.
The hypothesis (SH) can be traced back far into history; even Descartes was not the first to wonder about reality and the possibility that it is an illusion. Recently the SH has surfaced as a “serious” thought. So Ken and I decided that we would comment on SH: did we really decide this on our own, or are we just part of the simulation? Oh well, who knows.
The Simulation Hypothesis
The SH is that we live not in what we take to be reality, but rather inside some type of simulation. Indeed what is reality is a longstanding issue that has puzzled humans since the beginning of sapience. Descartes over four hundred years ago asked basic questions about mind vs body, which can be viewed as early questions on the SH.
Jump forward to 2003. A paper by Nick Bostrom gives a probabilistic argument for the SH. Bostrom argues that a future civilization would have enormous computing power—plenty left over even after the demands of Windows Edition 4532—OK, I added that. (Or did I?) Then he uses a Carl Sagan type argument: there are so many civilizations, that it is likely that some advanced civilization would run such a simulation. Robert Scherrer, Professor and Chair of Physics at Vanderbilt University and a Princeton 1981 classmate of Ken, wrote a science fiction story hinting that the argument can further be viewed as an instance of the Copernican Principle:
Earth enjoys no special cosmological privileges.
If there are so many simulations out there that the weight of numbers favors being in one, then it even takes special pleading to assert that we are not in one.
This argument apparently convinces many, but we are not convinced. It goes beyond the “brain-in-a-vat” concept:
—to assert that the mere processing of information feels like consciousness. You make your own decision. Or perhaps the simulation itself makes the argument seem correct.
Detecting Simulation in Our World?
Now jump to 2012, or rather to last week. The paper Constraints on the Universe as a Numerical Simulation by Silas Beane, Zohreh Davoudi, and Martin Savage is an attempt to suggest possible empirical tests for SH. Roughly they argue that a simulation of reality would have to use a discrete grid type simulation of the kind physicists already use. But these simulations tend to make certain types of detectable errors, like the lamp labeled “Sirius” falling from the sky in the movie The Truman Show.
Their test turns on the fact that we human physicists do our own gridlike modeling of subatomic events as our way of being able to collate and interpret the high-energy data. Their argument seems to go that if Nature is “real” then we enjoy full oversight of the limitations of our models. But if Nature is being generated by someone else’s model, then the models could well “clash” in a detectable manner. In particular, they argue that cosmic rays would be registered as traveling across diagonals of our grids, despite our models being designed to register them along grid edges, and the rays would favor interactions in certain directions instead of a uniform pattern.
This strikes us as unconvincing on two counts. It seems first to claim that the super-advanced civilization would employ the same type of algorithms we use, just on faster hardware, and hence would be liable to same kind of modeling errors—which would tend to clash with our own like differently angled sheets of polaroid. But what if they had better algorithms? Second, what if their simulation already subsumes the kind of models we—the ones being simulated—are allowed to make?
Still, we buy the argument that a fortuitous proof of something tantamount to simulation is possible. Consider strings of (say) 50,000 “truly random” bits generated via quantum processes at John Walker’s HotBits service, or at Random.org. Suppose someone happened to find that can be generated exactly from a seed of length 1000 bits by a previously-known program. Some “universe-is-a-computer” proponents predict this kind of pseudo-randomness, while in a “real” Nature as standardly understood in quantum mechanics and relativistic causality, the processes must be truly random. Ken wrote a post on this blog on how these issues might be probed in a more subtle manner, where initializes a tabulation-hashing scheme for exponential-time programs that happen to be playing chess.
However, we can investigate similar issues being played on a battlefield right in front of your eyes, on almost every computer in the world. Let’s do that next.
Simulation As A Defense
Right this second, all over the world, there are countless on-going attempts to discover whether “they” live in a simulation. Yes, we are serious. The issue is that the “they” are not people, but programs. These programs are battling to discover whether they are being simulated.
The context is the battle between dark hats attacking computer systems with malware, and white hats defending them. One method for trying to stop malware is to use simulation. Actually hardware people prefer to call it emulation, rather than simulation. We will stay with simulation to synch up with what the others say.
Simulation is used as follows to help detect malware:
- A piece of code arrives at a computer—it could be your phone, your tablet, your laptop, or your server. Rather than just run and hope that it is okay, almost all systems check out . One method is to look to see if is some known malware. But assuming that it is not, a good strategy is to simulate in a controlled environment—sometimes called a sandbox. Essentaily, simulate instruction by instruction.
- If during this simulation the program does nothing strange, then it is declared okay and is run it in the normal mode on the real hardware. If it does anything suspicious during the simulation, it is declared malware. And the user is warned, or other remedies are taken.
This sounds like a pretty powerful method, which should be able to detect lots of dangerous malware. It does work quite well in practice. But. The “but” is that there are numerous ways that well-written malware can detect that it is being simulated.
Hmmm. This seems very close to the problem of detecting whether or not we live in a simulated world. So how does malware detect it is being simulated? Let’s look at some of the popular ways that it can do this. Security terminology is that there is a “failure of transparency” if there is an aspect of behavior that allows malware running on the simulator to distinguish it from real hardware.
Defeating A Simulation Defense
Suppose again that is our malware. When it runs it is being simulated an instruction at a time. Of course the simulator is smart enough so we get the same results as if we were run in a normal mode. If this were absolutely correct, then there would be no way for the malware to detect the simulation. But getting absolutely the same results is not that easy. Here are some tricks to see a difference, a violation of transparency.
Use Time: One idea is the malware can try and see if it is running slower. It could get the time, do some computing, then get the time again. If the time elapsed is larger than it should be, then has detected the simulation. Clearly, this is possible to block: have the simulator “lie” about the time. But, of course, this is quite delicate. The simulator must return the exact correct time, even a small error from what the malware expects could be revealing. It is possible, it can be done, but it is not trivial.
Use External Values: Another idea is the malware can ask to examine external values. They can be from other web sites or even just local information from some files. Again the simulator can “lie” and fake the values. Again this is delicate and must be done in ways that fool .
Use Bugs: One more idea is that the malware can exploit the fact that the real hardware has “bugs.” If the simulator does not know about a bug, then it will give the wrong answer to and it will reveal that a simulation is in progress. Modern processors are very complex, so getting the instruction by instruction simulation correct is again very delicate.
In all of these ways, the malware is detecting clashes between its model of the true machine and the simulator’s imperfect model of the machine it is trying to defend.
More on Bugs
Even fifty years ago processors were complex and hard to simulate correctly. When IBM introduced their first IBM/360 mainframe in order to make it easy for customers to switch to it, they included a “simulate 1401 mode.” An IBM/1401 was then a popular machine that many companies used for their computing needs, such as payroll. IBM engineers had a special feature built into the 360’s that directly simulated the 1401 instruction-by-instruction. This allowed customers to run existing payroll code, or other programs, on the new machine, thereby making the transition to the new machines easier and hopefully increasing sales.
A problem arose. Customers began to complain to IBM that their new 360’s machines did not work. In particular they did not run the old 1401 programs properly—the payroll checks were often incorrect. IBM of course quickly investigated this, looking for an error that they must have made. There was no error. The IBM engineers had exactly simulated the 1401 instructions. Well almost. The issue was that many customers used certain “illegal” instructions, ones that were not officially supported by the 1401, in their programs. They used these instructions to increase performance—some illegal instructions helped make programs go faster.
Even though the IBM engineers knew the the exact specification of a 1401, they did not imagine that they would need to handle illegal instructions exactly as the actual 1401’s did. This was quickly fixed. Clearly, even if the processor is yours, and you have full documentation, it is not always easy to simulate it perfectly.
The main question is, can we use the above and other ideas from malware attacks against simulators to help us see if we live in a simulation? I wonder of some of the above, or other ideas, could be exploited in the physics world. What do you think? And can we prevent an evil genius from gaining control of our computers?