Code Monkey home page Code Monkey logo

well-founded-corecursion's Introduction

A cofixpoint combinator for mixed recursive-corecursive functions

This Agda library provides a cofixpoint combinator which does for productivity what well-founded recursion does for termination: It allows you to have arbitrary recursive calls in your corecursive functions if you can prove them terminating. Functions of this kind are sometimes called mixed recursive-corecursive, and their naive encoding is usually not obviously productive, so Agda rejects them. See the examples for some functions that are relatively easy to implement using this library.

Tested build configurations

Version 0.0.6

  • Agda 2.6.0.1; agda-stdlib 1.1
  • Agda 2.6.0.1; agda-stdlib 1.2

Version 0.0.5

  • Agda 2.6.0; agda-stdlib 1.0
  • Agda 2.6.0.1; agda-stdlib 1.1 (excluding examples!)

Version 0.0.4

  • Agda 2.5.4.2; agda-stdlib 0.17

Version 0.0.3

  • Agda 2.5.3; agda-stdlib 0.14 (excluding examples!)
  • Agda 2.5.4; agda-stdlib 0.16

Version 0.0.2

  • Agda 2.5.3; agda-stdlib 0.14
  • Agda 2.5.4; agda-stdlib 0.16 (excluding examples!)

Version 0.0.1

  • Agda 2.5.2; agda-stdlib 0.13
  • Agda 2.5.3; agda-stdlib 0.14 (excluding examples!)
  • Agda 2.5.4; agda-stdlib 0.16 (excluding examples!)

Installation

  1. Move this folder to a path of your choice, for example ~/.agda/lib/wellfounded-coind.

  2. Add the following entry to your ~/.agda/libraries:

    ~/.agda/lib/wellfounded-coind/wellfounded-coind.agda-lib
    

    (Substitute whatever path you chose in step 1.)

It should now be possible to import modules from this library in any of your Agda projects.

For details, read the packaging section of Agda's documentation.

Documentation

There is currently no comprehensive API documentation (sorry!). This repository contains a copy of my BSc thesis, paper.pdf, which describes the library in some detail, both from a user's and implementor's perspective. Some usage examples may also be found in examples/. Start with examples/Runs, which is the simplest and most complete.

Versioning contract

The 0.* series should be treated as unstable, meaning that anything can change at any time. After that, we'll see; I'm not sure what would be a sensible versioning policy for dependently typed languages.

Namespace

This library occupies the Coinduction.WellFounded.** module namespace.

well-founded-corecursion's People

Contributors

jlimperg avatar

Stargazers

 avatar Lîm Tsú-thuàn avatar Chris Lin avatar Anqur avatar Tesla Zhang‮ avatar Scott Fleischman avatar

Watchers

 avatar James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.