57 research outputs found

    Interactive Programs and Weakly Final Coalgebras in Dependent Type Theory (Extended Version)

    Get PDF
    We reconsider the representation of interactive programs in dependent type theory that the authors proposed in earlier papers. Whereas in previous versions the type of interactive programs was introduced in an ad hoc way, it is here defined as a weakly final coalgebra for a general form of polynomial functor. The are two versions: in the first the interface with the real world is fixed, while in the second the potential interactions can depend on the history of previous interactions. The second version may be appropriate for working with specifications of interactive programs. We focus on command-response interfaces, and consider both client and server programs, that run on opposite sides such an interface. We give formation/introduction/elimination/equality rules for these coalgebras. These are explored in two dimensions: coiterative versus corecursive, and monadic versus non-monadic. We also comment upon the relationship of the corresponding rules with guarded induction. It turns out that the introduction rules are nothing but a slightly restricted form of guarded induction. However, the form in which we write guarded induction is not recursive equations (which would break normalisation -- we show that type checking becomes undecidable), but instead involves an elimination operator in a crucial way

    Coalgebras as Types Determined by Their Elimination Rules

    Get PDF

    Coiterative Morphisms: Interactive Equational Reasoning for Bisimulation, using Coalgebras

    Get PDF
    ter: SEN 3 Abstract: We study several techniques for interactive equational reasoning with the bisimulation equivalence. Our work is based on a modular library, formalised in Coq, that axiomatises weakly final coalgebras and bisimulation. As a theory we derive some coalgebraic schemes and an associated coinduction principle. This will help in interactive proofs by coinduction, modular derivation of congruence and co-fixed point equations and enables an extensional treatment of bisimulation. Finally we present a version of the lambda-coinduction proof principle in our framework

    04381 Abstracts Collection -- Dependently Typed Programming

    Get PDF
    From 12.09.04 to 17.09.04, the Dagstuhl Seminar 04381 ``Dependently Typed Programming\u27\u27 was held in the International Conference and Research Center (IBFI), Schloss Dagstuhl. During the seminar, several participants presented their current research, and ongoing work and open problems were discussed. Abstracts of the presentations given during the seminar as well as abstracts of seminar results and ideas are put together in this paper. The first section describes the seminar topics and goals in general. Links to extended abstracts or full papers are provided, if available

    How to Reason Coinductively Informally

    Get PDF
    We start by giving an overview of the theory of indexed inductively and coinductively defined sets. We consider the theory of strictly positive indexed inductive definitions in a set theoretic setting. We show the equiv-alence between the definition as an indexed initial algebra, the definition via an induction principle, and the set theoretic definition of indexed in-ductive definitions. We review as well the equivalence of unique iteration, unique primitive recursion, and induction. Then we review the theory of indexed coinductively defined sets or final coalgebras. We construct indexed coinductively defined sets set theoretically, and show the equiv-alence between the category theoretic definition, the principle of unique coiteration, of unique corecursion, and of iteration together with bisimula-tion as equality. Bisimulation will be defined as an indexed coinductively defined set. Therefore proofs of bisimulation can be carried out corecur-sively. This fact can be considered together with bisimulation implying equality as the coinduction principle for the underlying coinductively de-fined set. Finally we introduce various schemata for reasoning about coin-ductively defined sets in an informal way: the schemata of corecursion, of indexed corecursion, of coinduction, and of corecursion for coinductively defined relations. This allows to reason about coinductively defined sets similarly as one does when reasoning about inductively defined sets using schemata of induction. We obtain the notion of a coinduction hypothesis, which is the dual of an induction hypothesis.

    Infinite Types, Infinite Data, Infinite Interaction

    Get PDF
    We describe a way to represent computable functions between coinductive types as particular transducers in type theory. This generalizes earlier work on functions between streams by P. Hancock to a much richer class of coinductive types. Those transducers can be defined in dependent type theory without any notion of equality but require inductive-recursive definitions. Most of the properties of these constructions only rely on a mild notion of equality (intensional equality) and can thus be formalized in the dependently typed language Agda

    Resumptions, Weak Bisimilarity and Big-Step Semantics for While with Interactive I/O: An Exercise in Mixed Induction-Coinduction

    Full text link
    We look at the operational semantics of languages with interactive I/O through the glasses of constructive type theory. Following on from our earlier work on coinductive trace-based semantics for While, we define several big-step semantics for While with interactive I/O, based on resumptions and termination-sensitive weak bisimilarity. These require nesting inductive definitions in coinductive definitions, which is interesting both mathematically and from the point-of-view of implementation in a proof assistant. After first defining a basic semantics of statements in terms of resumptions with explicit internal actions (delays), we introduce a semantics in terms of delay-free resumptions that essentially removes finite sequences of delays on the fly from those resumptions that are responsive. Finally, we also look at a semantics in terms of delay-free resumptions supplemented with a silent divergence option. This semantics hinges on decisions between convergence and divergence and is only equivalent to the basic one classically. We have fully formalized our development in Coq.Comment: In Proceedings SOS 2010, arXiv:1008.190

    Coinductive Formal Reasoning in Exact Real Arithmetic

    Full text link
    In this article we present a method for formally proving the correctness of the lazy algorithms for computing homographic and quadratic transformations -- of which field operations are special cases-- on a representation of real numbers by coinductive streams. The algorithms work on coinductive stream of M\"{o}bius maps and form the basis of the Edalat--Potts exact real arithmetic. We use the machinery of the Coq proof assistant for the coinductive types to present the formalisation. The formalised algorithms are only partially productive, i.e., they do not output provably infinite streams for all possible inputs. We show how to deal with this partiality in the presence of syntactic restrictions posed by the constructive type theory of Coq. Furthermore we show that the type theoretic techniques that we develop are compatible with the semantics of the algorithms as continuous maps on real numbers. The resulting Coq formalisation is available for public download.Comment: 40 page

    Interactive programming in Agda – Objects and graphical user interfaces

    Get PDF
    • …
    corecore