Teaching Computer Scientists Quantum Mechanics N
Total Page:16
File Type:pdf, Size:1020Kb
From Cbits to Qbits: Teaching computer scientists quantum mechanics N. David Mermin Laboratory of Atomic and Solid State Physics, Cornell University, Ithaca, New York 14853-2501 ͑Received 22 July 2002; accepted 26 September 2002͒ A strategy is suggested for teaching mathematically literate students, with no background in physics, just enough quantum mechanics for them to understand and develop algorithms in quantum computation and quantum information theory. Although the article as a whole addresses teachers of physics well versed in quantum mechanics, the central pedagogical development is addressed directly to computer scientists and mathematicians, with only occasional asides to their teacher. Physicists uninterested in quantum pedagogy may be amused ͑or irritated͒ by some of the views of standard quantum mechanics that arise naturally from this unorthodox perspective. © 2003 American Association of Physics Teachers. ͓DOI: 10.1119/1.1522741͔ I. COMPUTER SCIENCE AND QUANTUM to realize—is an extremely simple example of a physical MECHANICS system. It is discrete, not continuous. It is made out of a finite number of units, each of which is the simplest possible These ‘‘bras’’ and ‘‘kets’’—they’re just vectors! kind of quantum mechanical system, a 2-state system, whose —Newly enlightened computer scientist1 possible behavior is highly constrained and easily analyzed. There is a new audience for the teaching of quantum me- Much of the analytical complexity of learning quantum me- chanics whose background and needs require a new style of chanics is connected to mastering the description of continu- quantum pedagogy. The audience consists of computer sci- ous ͑infinite-state͒ systems in (3ϩ1)-dimensional space- entists. Compared with the usual students in an introductory time. By restricting attention to discrete transformations quantum mechanics course, they are mathematically sophis- acting on collections of 2-state systems, one can avoid much ticated, but are often ignorant of and uninterested in physics. suffering ͑and lose much wisdom, none of it—at least at this They want to understand the applications of quantum me- stage of the art—relevant to the theory of quantum compu- chanics during the past dozen years to information process- tation.͒ ing, and their focus is exclusively on algorithms ͑software͒, Second, the most difficult part of learning quantum me- not engineering ͑hardware͒. chanics is to get a good feeling for how the abstract formal- Although the obstacles to quantum computers becoming a ism can be applied to actual phenomena in the laboratory. viable technology are formidable, the profound conse- Such applications almost invariably involve formulating quences of quantum mechanics for the theory of computation oversimplified abstract models of the real phenomena, to discovered during the past decade ought to be part of the which the quantum formalism can effectively be applied. The intellectual equipment of every computer scientist, if only best physicists have an extraordinary intuition for what fea- because it provides dramatic proof that the abstract analysis tures of the actual phenomena are essential and must be rep- of computation cannot be divorced from the physical means resented in the abstract model, and what features are inessen- available for its execution. Future computer scientists ought tial and can be ignored. It takes years to develop such to learn quantum mechanics. intuition. Some never do. The theory of quantum computa- But how much quantum mechanics? In December 2001 I tion, however, is only concerned with the abstract model— was at a conference on quantum computation and informa- the easy part of the problem. tion at the Institute for Theoretical Physics in Santa Barbara. Third, to understand how to build a quantum computer, or At lunch one day I remarked to the Director of the ITP that I to study what physical systems are promising candidates for spent the first four or five lectures of my course2 on quantum realizing such a device, you must indeed have many years of computation teaching the necessary quantum mechanics to experience in quantum mechanics and its applications under the computer scientists in the class. His response was that your belt. But if you only want to know what such a device any application of quantum mechanics that could be taught is capable of doing in principle, then there is no reason to get after only a four hour introduction to the subject could not involved in the really difficult physics of the subject. The have serious intellectual content. After all, he remarked, it same holds for ordinary ͑‘‘classical’’͒ computers: one can be takes any physicist years to develop a feeling for quantum a masterful practitioner of computer science without having mechanics. the foggiest notion of what a transistor is, not to mention It’s a good point. Nevertheless, it is a fact that computer how it works. scientists and mathematicians with no background in physics So although the approach to quantum mechanics for com- have been able quickly to learn enough quantum mechanics puter scientists sketched below is focused and limited in to understand and contribute importantly to the theory of scope, it is neither oversimplified nor incomplete, for the quantum computation, even though quantum computation re- special task for which it is designed. ͑There is, however, an peatedly exploits the most notoriously paradoxical features isolated subset of quantum-computational theory called adia- of the subject. There are three main reasons for this: batic quantum computation that uses the quantum system First, a quantum computer—or, more accurately, the ab- more like an analogue than a digital computer, and does re- stract quantum computer that one hopes some day to be able quire a somewhat broader view of quantum theory.͒ 23 Am. J. Phys. 71 ͑1͒, January 2003 http://ojps.aip.org/ajp/ © 2003 American Association of Physics Teachers 23 ͉ ϭ͉ ϭ͉ ͉ ͉ ͉ ͉ ͉ II. CLASSICAL BITS 19͘6 010011͘ 0͘ 1͘ 0͘ 0͘ 1͘ 1͘ The first step in teaching quantum mechanics to computer ϭ͉0͘ ͉1͘ ͉0͘ ͉0͘ ͉1͘ ͉1͘. ͑7͒ scientists is to reformulate the language of conventional ͑ ͒ That the tensor product is a convenient and highly appro- classical computation in an unorthodox manner that intro- priate way to represent multi-Cbit states becomes clear if one duces much of the quantum formalism in an entirely familiar expands the vectors representing each Cbit as column vec- setting tors, To begin, we need a term for a physical system that can exist in two unambiguously distinguishable states, which are 1 0 ͉0͘$ͩ ͪ , ͉1͘$ͩ ͪ . ͑8͒ used to represent 0 and 1. Often such a system is called a bit, 0 1 but this can obscure the important distinction between the abstract bit ͑0or1͒ and the physical system used to represent The corresponding column vectors for tensor products are it. If one could establish a nomenclature for the field at this y 0z0 late date, I would argue for the term Cbit for a classical y 0 z0 y 0z1 physical system used to represent a bit, in parallel with the ͩ ͪͩ ͪ $ͩ ͪ , ͑9͒ y z y z term Qbit for its quantum generalization. Unfortunately, the 1 1 1 0 orthographically preposterous term qubit currently holds y 1z1 3 sway for the quantum system, while bit is used indiscrimi- x y z nately for both the classical system and the abstract bit. Be- 0 0 0 x y z cause clear distinctions between bits, Cbits, and Qbits are 0 0 1 crucial in the exposition that follows, I shall use this unfash- x0y 1z0 ionable terminology. It is inspired by Paul Dirac’s early use x0 y 0 z0 x0y 1z1 ͩ ͪͩ ͪͩ ͪ $ , ͑10͒ of c-number and q-number to describe classical variables x1 y 1 z1 ͩ x1y 0z0 ͪ and their generalizations to quantum-mechanical operators. x y z ͑ 1 0 1 ‘‘Cbit’’ and ‘‘Qbit’’ are preferable to ‘‘c-bit’’ and ‘‘q-bit,’’ x y z because the terms themselves often appear in hyphenated 1 1 0 x y z constructions.͒ 1 1 1 It can be fruitful, even on the strictly classical level, to etc. represent the two states of a Cbit by a pair of orthonormal Thus, for example, the 8-dimensional column vector rep- ͉ 2-vectors, denoted by the symbols resenting 5͘3 is given by ͉0͘ ͉1͘. ͑1͒ 0 0 This notation for vectors also goes back to Dirac. ͑For rea- 0 1 sons too silly to go into, he called such vectors kets, a termi- 0 2 nology that has survived to the present day.͒ 0 1 0 0 3 ͉5͘ ϭ͉101͘ϭ͉1͉͘0͉͘1͘ϭͩ ͪͩ ͪͩ ͪ ϭ ͑11͒ To do nontrivial computation requires more than one Cbit. 3 1 0 1 0 4 It is convenient ͑and, as we shall see in a moment, even ͩ ͪ 1 5 natural͒ to represent the four states of two Cbits as four or- thogonal vectors in four dimensions, formed by the tensor 0 6 products of two such pairs: 0 7 ͉0͘ ͉0͘ ͉0͘ ͉1͘ ͉1͘ ͉0͘ ͉1͘ ͉1͘. ͑2͒ which hasa0inevery entry except fora1intheentry ͑ One often omits the , writing ͑2͒ in the more compact, but labeled by the integer 5 that the three Cbits represent. Label equivalent form, the entries by counting down 0,1,2... from the top. The small numerals on the extreme right in ͑11͒ make this labeling ͉0͉͘0͘ ͉0͉͘1͘ ͉1͉͘0͘ ͉1͉͘1͘, ͑3͒ explicit.͒ This general rule for the column vector represent- ͉ ͘ or, more readably, ing x n, 1 in position x and 0 everywhere else, is the obvious generalization to n Cbits of the form for a 1-Cbit ͉ ͘ ͉ ͘ ͉ ͘ ͉ ͘ ͑ ͒ 00 01 10 11 , 4 column vector.