Types for Quantum Computing
Total Page:16
File Type:pdf, Size:1020Kb
Types for Quantum Computing Ross Duncan Merton College, Oxford Oxford University Computing Laboratory Submitted for the degree of Doctor of Philosophy Michaelmas Term 2006 Abstract This thesis is a study of the construction and representation of typed models of quantum mechanics for use in quantum computation. We introduce logical and graphical syntax for quantum mechanical processes and prove that these formal systems provide sound and complete representations of abstract quantum mechanics. In addition, we demonstrate how these representations may be used to reason about the behaviour of quantum computational processes. Quantum computation is presently mired in low-level formalisms, mostly de- rived directly from matrices over Hilbert spaces. These formalisms are an obsta- cle to the full understanding and exploitation of quantum effects in informatics since they obscure the essential structure of quantum states and processes. The aim of this work is to introduce higher level tools for quantum mechan- ics which will be better suited to computation than those presently employed in the field. Inessential details of Hilbert space representations are removed and the informatic structures are presented directly. Entangled states are partic- ularly important in this treatment, as is appropriate, since entanglement is a fundamental driver of quantum computation. The benefits two-fold: as well as producing foundational tools for the study of quantum computation this work also connects quantum mechanics to mainstream areas of computer science such as categorical logic, type theory, program language semantics, and rewriting. We describe, following Abramsky and Coecke, how quantum mechanics may be carried out without reference to Hilbert space, in a strongly compact closed category. In particular we show how to freely construct a categorical model of abstract quantum mechanics from an arbitrary category. We introduce Multiplicative Categorical Quantum Logic (mCQL), a sequent calculus whose proof rules capture the structure of compact closed categories. This sequent calculus is interpreted in a freely generated compact closed cate- gory, and its semantics is sound with respect to cut elimination. We define an equivalent graphical syntax, similar to linear logic’s proof-nets, and prove that these proof-nets provide a full and faithful representation of any freely generated compact closed category. Further analysis of the structure of quantum states which correspond to mCQL proofs using multiplicative linear logic shows that the linear type system describes the quantum entanglement found in such states. We show that the entanglement present in these states is always of a particularly simple form: collections of entangled pairs. In order to tackle arbitrary entanglement, we generalise the work of Kelly and Laplaza to give a representation theorem for the free compact closed cat- egory by a polycategory. Such categories are shown to be equivalent to a gen- eralised system of proof-nets whose axioms may have more than one premise i ii or conclusion. These axioms may be understood as abstract representatives of interactions involving several distinct quantum systems. A striking application of entanglement is the class of measurement-based models of quantum computation. In the final chapter, the diagrammatic no- tation is applied to the verification of programs in the measurement calculus of Danos, Kashefi, and Panangaden — a measurement-based model where the computation is coded directly in an entangled state. By exploiting their dia- grammatic form, some example programs are transformed to equivalent quan- tum circuits, thus proving the correctness of the original programs. Acknowledgements It is both an honour and a pleasure to acknowledge my debt to my supervisor, Samson Abramsky. This thesis would not have been possible without his insight, encouragement, patience and generosity. I also extend my warmest thanks to Bob Coecke, whose friendship and in- spiration over the past four years have been invaluable. Many colleagues have contributed through lectures and discussions from which I have benefited enormously: Prakash Panangaden, Phil Scott, Vincent Danos, Elham Kashefi, Peter Hines, Alexandru Baltag and Eric Paquette, to name only a few. Their ideas have helped shape this work and their interest en- couraged me to pursue it. Especial thanks to Ellie d’Hondt for helpful comments on a draft version. The Oxford University Computing Laboratory provided the necessary finan- cial support for this thesis in the form of a studentship; without this funding I would never have been able to embark on this project. The work was carried out while I was a member of Merton college, which provided generous financial and pastoral assistance. In particular I thank Luke Ong for his support as my tutor and Dean of graduates. I spent six months as a guest of the Ecole Normal Superieure in Paris while writing up; their generosity is acknowledged. The document was typeset using LATEX. I made use of Paul Taylor’s diagrams and prooftree macro packages. In many respects moral support is as important, if not more so, than the financial kind. I owe my sanity to my friends, in Oxford and elsewhere, without whom life would have been very bleak indeed. The value of their laughter, sympathy and kindness cannot be understated. To my family I express my bottomless gratitude for their love and support throughout my protracted education; and to Nora, for everything, thank you. iii iv Contents 1 Introduction 1 1.1 Quantum Mechanics . 5 1.2 Programs, Proofs and Categories . 10 1.3 Outline of the Thesis . 12 2 Categorical Background 15 2.1 Monoidal Categories . 16 2.2 Duality . 19 2.3 Compact Closed Categories . 21 2.4 Names and Conames . 24 2.5 Strong Compact Closure . 27 2.6 Trace . 28 2.7 Scalars and Loops . 29 2.8 Free Construction . 31 3 Categorical Quantum Mechanics 35 3.1 Multiplicative Quantum Mechanics . 36 3.2 FDHilb as a strong compact closed category . 37 3.3 Categorical Quantum Mechanics . 39 3.4 Free Models . 40 4 Multiplicative Categorical Quantum Logic 45 4.1 Formulae . 46 4.2 Sequent Calculus . 46 4.3 Proof-nets . 55 4.4 Example: Entanglement Swapping . 65 5 MLL and Entanglement 67 5.1 Entangled States . 68 5.2 Double Gluing . 70 5.3 Multiplicative Linear Logic . 72 5.3.1 Sequent Calculus . 72 5.3.2 Proof-nets . 73 5.3.3 Interpreting MLL in the Free Category . 74 v vi CONTENTS 6 Generalised mCQL 79 6.1 Polycategories . 82 6.2 Graphs and Circuits . 87 6.2.1 Graphs . 87 6.2.2 Circuits . 98 6.3 The Free Compact Closed Category on a Polycategory . 104 6.4 Scalars . 107 6.5 Homotopy . 108 6.5.1 Extended Labellings . 109 6.5.2 Homotopy Equivalence . 109 6.5.3 Circuits under Homotopy . 115 6.5.4 Quotients of the Free Structure . 116 6.6 Generalised Proof-nets . 117 6.6.1 PN(A) is equivalent to Circ(A) . 130 6.7 Relations and Rewriting . 133 6.8 Example: Proving No-cloning . 135 7 The One-Way Quantum Computer 137 7.1 The Measurement Calculus . 137 7.2 Representing the Measurement Calculus . 139 7.3 Examples . 146 7.3.1 Teleportation . 146 7.3.2 One qubit unitary . 146 7.3.3 Controlled-NOT . 147 7.3.4 Controlled-U . 148 7.4 Remark . 148 8 Further Work 151 Chapter 1 Introduction The relationship between the quantum computational model and its classical1 predecessor remains unclear. What are the truly “quantum” features of quan- tum computing? And how should they be represented? In the following chapters I aim to address these questions by describing the structural features of quan- tum computation, and other quantum systems, in the terms of logic and type theory. This thesis is a study of the construction and representation of typed models of quantum mechanics for use in quantum computation. I introduce logical and graphical syntax for quantum mechanical processes and prove that these formal systems provide sound and complete representations of abstract quantum mechanics. In addition, I demonstrate how these representations may be used to reason about the behaviour of quantum computational processes. The analysis of quantum systems is complicated by the phenomenon known as quantum entanglement. Entanglement allows seemingly disjoint systems to behave as a tightly coupled whole, and, as a consequence, quantum systems can- not be understood by simply examining their constituent parts: the entire sys- tem must examined together. The exploitation of entanglement is fundamental in quantum computation. It lies at the heart of the speed-up of quantum algo- rithms, and is used directly in many quantum communication protocols. Indeed, an entire class of quantum computational models, the so-called measurement- based models, is based on the use of entangled resources. Despite all this, the underlying structure of entanglement is poorly understood. A large portion of this thesis is spent developing a mathematical framework which captures the essential features of many-body entanglement in a high level fashion. My aim in so doing is to establish a foundation upon which the behaviour of entangled systems can be understood directly in terms of structural relationships between their subsystems. A point worth making early is that my focus falls exclusively on the tensor fragment of quantum theory, which, despite its fundamental importance, has not been seriously studied before. Other aspects of quantum mechanics, such as non-determinism and branching, are not considered. This sub-theory I refer to as multiplicative quantum mechanics, following the terminology of linear logic. 1The word classical is slightly overloaded when simultaneously discussing logic and quan- tum computation. Throughout this work I use it to denote non-quantum; it will not be necessary to discuss classical logic as distinct from linear or intuitionist logic. 1 2 CHAPTER 1. INTRODUCTION The general theoretical backdrop to this work is the Curry-Howard isomor- phism, also called propositions-as-types or, more accurately, proofs-as-programs [GLT89, SU06].