General Recursion via Coinductive Types
Open Access
- 13 July 2005
- journal article
- Published by Centre pour la Communication Scientifique Directe (CCSD) in Logical Methods in Computer Science
- Vol. ume 1, Iss
- https://doi.org/10.2168/lmcs-1(2:1)2005
Abstract
A fertile field of research in theoretical computer science investigates the representation of general recursive functions in intensional type theories. Among the most successful approaches are: the use of wellfounded relations, implementation of operational semantics, formalization of domain theory, and inductive definition of domain predicates. Here, a different solution is proposed: exploiting coinductive types to model infinite computations. To every type A we associate a type of partial elements Partial(A), coinductively generated by two constructors: the first, return(a) just returns an element a:A; the second, step(x), adds a computation step to a recursive element x:Partial(A). We show how this simple device is sufficient to formalize all recursive functions between two given types. It allows the definition of fixed points of finitary, that is, continuous, operators. We will compare this approach to different ones from the literature. Finally, we mention that the formalization, with appropriate structural maps, defines a strong monad.Keywords
All Related Versions
This publication has 35 references indexed in Scilit:
- Partial functions in comstructive formal theoriesPublished by Springer Nature ,2006
- A note on categorical datatypesPublished by Springer Nature ,2005
- Inductive definitions in the system Coq rules and propertiesPublished by Springer Nature ,2005
- Setoids in type theoryJournal of Functional Programming, 2003
- Type-based termination of recursive definitionsMathematical Structures in Computer Science, 1999
- The discoveries of continuationsHigher-Order and Symbolic Computation, 1993
- Inductively defined types in the Calculus of ConstructionsPublished by Springer Nature ,1990
- Terminating general recursionBIT Numerical Mathematics, 1988
- Constructing recursion operators in intuitionistic type theoryJournal of Symbolic Computation, 1986
- Domains for denotational semanticsPublished by Springer Nature ,1982