97 research outputs found
Foundational Extensible Corecursion
This paper presents a formalized framework for defining corecursive functions
safely in a total setting, based on corecursion up-to and relational
parametricity. The end product is a general corecursor that allows corecursive
(and even recursive) calls under well-behaved operations, including
constructors. Corecursive functions that are well behaved can be registered as
such, thereby increasing the corecursor's expressiveness. The metatheory is
formalized in the Isabelle proof assistant and forms the core of a prototype
tool. The corecursor is derived from first principles, without requiring new
axioms or extensions of the logic
Friends with benefits: implementing corecursion in foundational proof assistants
We introduce AmiCo, a tool that extends a proof assistant, Isabelle/HOL, with flexible function definitions well beyond primitive corecursion. All definitions are certified by the assistantâs inference kernel to guard against inconsistencies. A central notion is that of friends: functions that preserve the productivity of their arguments and that are allowed in corecursive call contexts. As new friends are registered, corecursion benefits by becoming more expressive. We describe this process and its implementation, from the userâs specification to the synthesis of a higher-order definition to the registration of a friend. We show some substantial case studies where our approach makes a difference
Type-Based Termination, Inflationary Fixed-Points, and Mixed Inductive-Coinductive Types
Type systems certify program properties in a compositional way. From a bigger
program one can abstract out a part and certify the properties of the resulting
abstract program by just using the type of the part that was abstracted away.
Termination and productivity are non-trivial yet desired program properties,
and several type systems have been put forward that guarantee termination,
compositionally. These type systems are intimately connected to the definition
of least and greatest fixed-points by ordinal iteration. While most type
systems use conventional iteration, we consider inflationary iteration in this
article. We demonstrate how this leads to a more principled type system, with
recursion based on well-founded induction. The type system has a prototypical
implementation, MiniAgda, and we show in particular how it certifies
productivity of corecursive and mixed recursive-corecursive functions.Comment: In Proceedings FICS 2012, arXiv:1202.317
Friends with benefits: implementing corecursion in foundational proof assistants
We introduce AmiCo, a tool that extends a proof assistant, Isabelle/HOL, with flexible function definitions well beyond primitive corecursion. All definitions are certified by the assistantâs inference kernel to guard against inconsistencies. A central notion is that of friends: functions that preserve the productivity of their arguments and that are allowed in corecursive call contexts. As new friends are registered, corecursion benefits by becoming more expressive. We describe this process and its implementation, from the userâs specification to the synthesis of a higher-order definition to the registration of a friend. We show some substantial case studies where our approach makes a difference
Foundational extensible corecursion: a proof assistant perspective
This paper presents a formalized framework for defining corecursive functions safely in a total setting, based on corecursion up-to and relational parametricity. The end product is a general corecursor that allows corecursive (and even recursive) calls under âfriendlyâ operations, including constructors. Friendly corecursive functions can be registered as such, thereby increasing the corecursorâs expressiveness. The metatheory is formalized in the Isabelle proof assistant and forms the core of a prototype tool. The corecursor is derived from first principles, without requiring new axioms or extensions of the logic
Foundational extensible corecursion: a proof assistant perspective
This paper presents a formalized framework for defining corecursive functions safely in a total setting, based on corecursion up-to and relational parametricity. The end product is a general corecursor that allows corecursive (and even recursive) calls under âfriendlyâ operations, including constructors. Friendly corecursive functions can be registered as such, thereby increasing the corecursorâs expressiveness. The metatheory is formalized in the Isabelle proof assistant and forms the core of a prototype tool. The corecursor is derived from first principles, without requiring new axioms or extensions of the logic
An Equational Theory for Weak Bisimulation via Generalized Parameterized Coinduction
Coinductive reasoning about infinitary structures such as streams is widely
applicable. However, practical frameworks for developing coinductive proofs and
finding reasoning principles that help structure such proofs remain a
challenge, especially in the context of machine-checked formalization.
This paper gives a novel presentation of an equational theory for reasoning
about structures up to weak bisimulation. The theory is both compositional,
making it suitable for defining general-purpose lemmas, and also incremental,
meaning that the bisimulation can be created interactively. To prove the
theory's soundness, this paper also introduces generalized parameterized
coinduction, which addresses expressivity problems of earlier works and
provides a practical framework for coinductive reasoning. The paper presents
the resulting equational theory for streams, but the technique applies to other
structures too.
All of the results in this paper have been proved in Coq, and the generalized
parameterized coinduction framework is available as a Coq library.Comment: To be published in CPP 202
Copatterns: programming infinite structures by observations
This article which will appear in the proceedings of POPL 2013 in January 2013, introduces the dual of pattern matching, as it is used in functional programming for defining functions, by copatterns. Whereas data types are eliminated by pattern matching, i.e. by giving giving a choice for each constructor, coalgebras are introduced by copatterns, namely by giving the result of each eliminator. Patterns and copatterns are entirely symmetrical. This article introduces a language which allows to define data types, coalgebras, and functions by nested pattern and copattern matching. An operational semantics is introduced, and type soundness and subject reduction is shown
- âŠ