Partial Functions and Recursion in Univalent Type Theory By

Partial Functions and Recursion in Univalent Type Theory By

Partial Functions and Recursion in Univalent Type Theory by Cory Knapp A thesis submitted to The University of Birmingham for the degree of Doctor of Philosophy School of Computer Science College of Engineering and Physical Sciences The University of Birmingham June 2018 University of Birmingham Research Archive e-theses repository This unpublished thesis/dissertation is copyright of the author and/or third parties. The intellectual property rights of the author or third parties in respect of this work are as defined by The Copyright Designs and Patents Act 1988 or as modified by any successor legislation. Any use made of information contained in this thesis/dissertation must be in accordance with that legislation and must be properly acknowledged. Further distribution or reproduction in any format is prohibited without the permission of the copyright holder. Abstract We investigate partial functions and computability theory from within a constructive, univalent type theory. The focus is on placing computability into a larger mathematical context, rather than on a complete development of computability theory. We begin with a treatment of partial functions, using the notion of dominance, which is used in synthetic domain theory to discuss classes of partial maps. We relate this and other ideas from synthetic domain theory to other approaches to partiality in type theory. We show that the notion of dominance is difficult to 1 apply in our setting: the set of Σ0 propositions investigated by Rosolini form a dominance precisely if a weak, but nevertheless unprovable, choice principle holds. To get around this problem, we suggest an alternative notion of partial function we call disciplined maps. In the presence of countable choice, this notion coincides with Rosolini’s. Using a general notion of partial function, we take the first steps in constructive computabil- ity theory. We do this both with computability as structure, where we have direct access to programs; and with computability as property, where we must work in a program-invariant way. We demonstrate the difference between these two approaches by showing how these approaches relate to facts about computability theory arising from topos-theoretic and type- theoretic concerns. Finally, we tie the two threads together: assuming countable choice and that all total functions N ! N are computable (both of which hold in the effective topos), the Rosolini partial functions, the disciplined maps, and the computable partial functions all co- incide. We observe, however, that the class of all partial functions includes non-computable partial functions. Acknowledgements As always, there are far too many people to thank, and I’m bound to miss some, so I’ll just leave it at the obvious, and academic: Thanks, especially, to my supervisor Martín Escardó, for patient explanations, sage advice, and long working meetings. I cannot express how helpful of a supervisor you have been. Thanks to the staff in the Birmingham theory group—especially to Paul Levy, for teaching me category theory faster than I knew it could be taught, and for consistently playing devil’s advocate; to Achim Jung, for explaining logical relations to me; and to Steve Vickers, for explaining geometric reasoning. Thanks also to the PhD Students in the group—especially to Auke for answering all my mathematical questions, and to everyone involved in CARGO for continuous motivation. Thank you to the examiners Steve Vickers and Bernhard Reus for taking the time to read this. Mike Shulman and Peter Lumsdaine may not know it, but they helped set me on the path that led here: one by being kind to a clueless undergrad, and the other by giving direction to a masters student in over his depth. Both have also given advice and encouragement since. Finally, of course, I couldn’t have done this without endless support from friends and family, but such thanks are better said in person. Contents Introduction 5 Summary of contributions . 11 I Univalent Mathematics 13 1 Type theory 16 1.1 Martin-Löf type theory . 16 1.2 Bishop-style mathematics and the Curry-Howard interpretation . 23 1.3 Informal mathematics and constructive taboos . 25 1.4 Topos logic . 28 1.5 Univalent foundations . 30 1.6 Structure versus Property . 33 1.7 Homotopies and equivalences . 36 1.8 Transport, identities and the basic types . 45 1.9 Equivalences and contractible fibers . 48 1.10 Discussion . 54 2 Univalent mathematics 55 2.1 Function extensionality . 56 2.2 Logic of propositions . 62 2.3 Surjections, embeddings and equivalences . 67 2.4 Proposition extensionality and univalence . 71 2.5 Resizing rules . 81 2.6 Homotopy levels and sets . 83 1 2.7 Higher-inductive types . 86 2.8 Discussion . 92 3 Mathematical foundations 94 3.1 Assumptions . 94 3.2 Predicates and relations . 95 3.3 Constancy . 99 3.4 Predicates on N ...................................... 101 3.5 Monads . 105 3.6 Choice principles . 107 3.7 Discussion . 111 II Partiality 113 4 Partiality in Type Theory and Topos Theory 116 4.1 N1 and the delay monad . 117 4.2 Partiality via higher-inductive types . 125 4.3 Synthetic domain theory and synthetic computability theory . 126 4.4 Discussion . 128 5 Partiality in Univalent Mathematics 129 5.1 Single-valued relations . 130 5.2 Partial elements . 133 5.3 Domain and range of partial functions . 139 5.4 Liftings are DCPOs . 140 5.5 Dominances and partial functions . 141 5.6 Size issues . 147 5.7 Rosolini propositions . 148 5.8 Choice principles and the dominance axiom . 153 5.9 Structural Dominances . 158 5.10 Disciplined maps . 161 5.11 Comparison with synthetic domain theory . 165 2 5.12 Discussion . 167 6 Partiality in Bishop Mathematics 169 6.1 Setoids . 170 6.2 Families of setoids . 171 6.3 Truncation and quotients . 172 6.4 The Delay monad . 173 6.5 Rosolini partial elements and functions . 174 6.6 The axiom of choice . 174 6.7 Discussion . 175 III Computability theory 178 7 Computability as structure 181 7.1 Primitive recursion . 181 7.2 Recursive machines . 189 7.3 Recursive predicates and minimization . 192 7.4 The Normal Form Theorem . 194 7.5 Basic Recursion Theory . 200 7.6 Discussion . 203 8 Computability as property 204 8.1 Primitive recursive functions . 205 8.2 Computable functions . 206 8.3 Recursion theory . 208 8.4 The halting problem . 209 8.5 Semidecidable propositions . 210 8.6 Discussion . 211 9 Computability and partiality 213 9.1 Semidecidable propositions and disciplined maps . 213 9.2 Which total functions can be computable? . 215 3 9.3 Which partial functions can be computable . 219 9.4 Discussion . 221 Further work 223 A model validating Church’s thesis . 223 Higher-type computation . 224 PCF and ultrametric spaces . 226 Conclusion and summary 228 References 238 4 Introduction In Mathematics as a Numerical Language [10], Bishop outlines what he viewed as the most impor- tant questions of constructive mathematics of his time. In it, he states “that mathematics con- cerns itself with the precise description of finitely performable abstract operations.” He also states that constructive mathematicians can use classical mathematics “as a guide” and that much of classical mathematics “will raise fundamental questions which classically are trivial or perhaps do not even make sense.” The essay continues by sketching three problems that are classically easy, but when viewed constructively demonstrate gaps in our conceptual un- derstanding. He states “Each of the three problems just discussed requires the development of new concepts appropriate to the constructive point of view. None of them is likely to be given an acceptable solution by the application of a general technique of constructivization.” In fact, for two of these problems (Birkhoff’s ergodic theorem and the construction of singular cohomology), there is no constructive solution, so a new approach must be taken to develop the field. For the third (Hilbert’s basis theorem), the proof itself is constructive, but exhibiting objects to which the theorem can be applied necessarily requires non-constructive arguments. This thesis is focused on computability theory, but done from the point of view of construc- tivization that we see in the previous paragraph. That is, · our mathematical work should describe “finitely performable abstract operations”; · we will be guided by the classical development of computability theory, but · we will pay special attention to fundamental questions which are classically trivial and on concepts that are appropriate for the constructive point of view. The goal, then, is not to develop a full constructive account of computability theory but to un- derstand how computability theory fits into a constructive mathematical world. In particular, the behavior of partial functions is more subtle in a constructive world, so we spend a consid- erable amount of time examining the theory of partial functions. 5 In order to proceed, we must fix a constructive framework for doing mathematics. For- mally, we use a modest extension of intensional Martin-Löf type theory (MLTT). This connects directly to our motivating paragraph: while introducing his type theory in [57], Martin-Löf cites Bishop [10, 9] as a motivation for MLTT..

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    246 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us