\"Some computer programs are blind to the kind of input they are given. The program taking an object \"\"a\"\" and returning the pair \"\"(a,a)\"\" is such an example: its code is the same regardless of whether \"\"a\"\" is an integer, a real number, a vector or even another program. A...
\"Some computer programs are blind to the kind of input they are given. The program taking an object \"\"a\"\" and returning the pair \"\"(a,a)\"\" is such an example: its code is the same regardless of whether \"\"a\"\" is an integer, a real number, a vector or even another program. A programming language is polymorphic if it allows the writting of such programs. The aim of the PolyBar project is to define and study a computational translation from a polymorphic programming language into a non-polymorphic language extended with the bar recursion operator: an operator implementing recursion over well-founded trees. The concepts underlying polymorphism and bar recursion being very different, this translation will allow the study of polymorphism with new tools coming from recursion theory.
There exists connections involving the programming languages System F and System TBR and the mathematical theories Z2 and PA-AC: there is a curry-Howard correspondence between System F and Z2, a logical translation from Z2 to PA-AC, and a realizability interpretation of PA-AC into System TBR. The experienced researcher (ER) recently gave the first translation from System F to System TBR by composing these connections within a single framework. The PolyBar project aims at defining a direct computational translation from System F to System TBR, and exploiting it to give a new recursion-theoretic proof of termination of System F and unveil a connection between impredicativity and Zorn\'s lemma.
The PolyBar project gives new insights on polymorphic programming, paving the way for new tools for producing safer software. Proving properties about polymorphic programs is a particularly difficult task. Conversely, simply-typed programming languages often enjoy properties that allows for more straightforward proofs of correctness. This method is more flexible and direct than that of reducibility candidates and properties about simply-typed programs are often easier to obtain than in the polymorphic case.
The PolyBar project allows the extension of combinatorial techniques used in simply-typed languages to the polymorphic world. This will bring a new range of techniques for proving properties about polymorphic programs and promote the use of polymorphic languages in environments where safety is important. Formal proofs of computer software often require that the programmer works in a constrained programming language, ruling out polymorphism. The PolyBar project improves the state-of-the-art by extending the use of well-known proof techniques to polymorphic programming languages: computer programmers will be able to use the sophisticated features of polymorphism and still prove correctness properties on their programs.\"
During the reporting period the ER made significant progress on the computational behavior of bar recursion, when used to interpret the axiom scheme of comprehension. When realizing the axiom scheme of comprehension through bar recursion, the computational interpretation of the inductive case is instantiated with a computational interpretation of the excluded middle that performs backtracking. The bar recursion operator explores a well-founded tree, and since its argument backtracks, this exploration will backtrack to an ancestor node whenever the realizer of the exclude middle performs such a backtrack.
The ER analyzed several normalization proofs of system F and investigated the differences between their computational interpretations. With Girard\'s notion of reducibility candidate, the proof that any type interpretation is a reducibility candidate involves two nested inductions. The computational interpretation of such a proof therefore involves to nested recursions and becomes overly complex, both from the theoretical and practical perspectives. On the other hand, with Tait\'s notion of reducibility candidate, the proof that any type interpretation is a reducibility candidate is made by a simple induction on the type. This simplifies greatly the computational interpretation of the normalization proof of System F and is a better candidate for obtaining a direct translation from System F to System TBR. The drawback is that Tait\'s notion of reducibility candidates only provides a proof of weak head normalization while Girard\'s version provides a proof of strong normalization. This means that the translation is only able to compute the weak head normal form of a System F term. Nevertheless it is sufficient for the purposes of the project and it is therefore the solution that was retained by the ER.
The ER also discovered the possibility of making his translation from System F to System TBR more direct by working with a source language with control features and choosing a call-by-name or call-by-value reduction strategy. In the bar recursive exploration of the tree the strategies for exploring the tree in call-by-name and in call-by-value are dual. This discovery opens up many interesting possible developments, where variations on the evaluation strategy will be useful in obtaining an efficient translation from System F to System TBR.
\"The computational content of the interpretation of the axiom scheme of comprehension by bar recursion was never explored before and the description of it that was given by the ER as the exploration of a tree with backtracks controlled by the realizer of the excluded middle gives a completely new vision of what it means to manipulate sets of integers as evolving partial information about these sets. Indeed, the computational interpretation of the axiom scheme of comprehension through bar recursion consists in starting with a potential set of natural numbers for which there is no information. Then, as the environment asks for information about the set, this partial information is extended with an arbitrary decision. Later on, a backtrack may be triggered to change the information into the opposite. When such backtrack occurs, all information gathered since the arbitrary decision has been made is erased: membership of a natural number to a set can depend on membership of some previously seen natural number to this same set. While in the past membership in second-order arithmetic has always taken place at the meta-level, bar recursion turns this membership information into some partial function that can compute.
The outcome of the project will also have an impact on the reverse mathematics community. In reverse mathematics, subsystems of second-order arithmetic are studied, and these systems are obtained by restricting the comprehension axiom scheme to specific classes of formulas (decidable in RCA0, arithmetic in ACA0, pi-1-1 in pi-1-1-CA0). Thanks to the outcomes of the project, there is now a computational counterpart of these subsystems of second-order arithmetic. Indeed, restrictions on the comprehension axiom scheme correspond to restrictions on the computational content of the realizer of the excluded middle that performs backtracks. For example, restricting to decidable formulas means that such a realizer does not need to perform any backtrack: it is already decidable whether A or not A holds and there is no need to take a \"\"wild guess\"\". In that sense the use of bar recursion for interpreting RCA0 is a very restricted one involving no backtracking at all, and its complexity is easy to control. This discovery opens up the possibility of defining bar recursion instances that would be sufficient for interpreting ACA0 or pi-1-1-CA0.\"
More info: https://valentinblot.org/pro/.