skip to main content
research-article

Structures for structural recursion

Published:29 August 2015Publication History
Skip Abstract Section

Abstract

Our goal is to develop co-induction from our understanding of induction, putting them on level ground as equal partners for reasoning about programs. We investigate several structures which represent well-founded forms of recursion in programs. These simple structures encapsulate reasoning by primitive and noetherian induction principles, and can be composed together to form complex recursion schemes for programs operating over a wide class of data and co-data types. At its heart, this study is guided by duality: each structure for recursion has a dual form, giving perfectly symmetric pairs of equal and opposite data and co-data types for representing recursion in programs. Duality is brought out through a framework presented in sequent style, which inherently includes control effects that are interpreted logically as classical reasoning principles. To accommodate the presence of effects, we give a calculus parameterized by a notion of strategy, which is strongly normalizing for a wide range of strategies. We also present a more traditional calculus for representing effect-free functional programs, but at the cost of losing some of the founding dualities.

References

  1. A. Abel. A Polymorphic Lambda Calculus with Sized Higher-Order Types. Ph.D. thesis, Ludwig-Maximilians-Universität München, 2006.Google ScholarGoogle Scholar
  2. A. Abel and B. Pientka. Wellfounded recursion with copatterns: a unified approach to termination and productivity. In ICFP, 2013. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. A. Abel, B. Pientka, D. Thibodeau, and A. Setzer. Copatterns: programming infinite structures by observations. In POPL, 2013. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. F. Barbanera and S. Berardi. A symmetric lambda calculus for "classical" program extraction. In TACS ’94, pages 495–515, 1994. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. T. Coquand and P. Dybjer. Inductive definitions and type theory an introduction. In FSTTCS, volume 880 of LNCS, 1994. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. P.-L. Curien and H. Herbelin. The duality of computation. In International Conference on Functional Programming, pages 233–243, 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. P.-L. Curien and G. Munch-Maccagnoni. The duality of computation under focus. Theoretical Computer Science, pages 165–181, 2010.Google ScholarGoogle ScholarCross RefCross Ref
  8. P. Downen and Z. M. Ariola. The duality of construction. In European Symposium on Programming, 2014.Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. J.-Y. Girard, P. Taylor, and Y. Lafont. Proofs and types. Cambridge University Press, 1989. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. K. Gödel. On a hitherto unexploited extension of the finitary standpoint. Journal of Philosophical Logic, 9(2):133–142, 1980.Google ScholarGoogle ScholarCross RefCross Ref
  11. T. Griffin. A formulae-as-types notion of control. In POPL, pages 47–58, 1990. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. T. Hagino. A typed lambda calculus with categorical type constructors. In Category Theory and Computer Science, 1987. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. J.-L. Krivine. Realizability in classical logic. In Interactive models of computation and program behaviour, volume 27, pages 197–229. Société Mathématique de France, 2009.Google ScholarGoogle Scholar
  14. S. Lengrand and A. Miquel. Classical Fω, orthogonality and symmetric candidates. Annals of Pure and Applied Logic, 153(1):3–20, 2008.Google ScholarGoogle ScholarCross RefCross Ref
  15. P. Martin-Löf. A theory of types. Technical Report 71-3, University of Stockholm, 1971.Google ScholarGoogle Scholar
  16. G. Munch-Maccagnoni. Focalisation and classical realisability. In Computer Science Logic, pages 409–423. Springer, 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. P. M. Nax. Inductive Definition in Type Theory. Ph.D. thesis, Cornell University, 1988.Google ScholarGoogle Scholar
  18. N. Oury. Coinductive types and type preservation. Message on the Coq-club mailing list, June 2008.Google ScholarGoogle Scholar
  19. S. Singh, S. P. Jones, U. Norell, F. Pottier, E. Meijer, and C. McBride. Sexy types—are we done yet? Software Summit, Apr. 2011.Google ScholarGoogle Scholar
  20. P. Wadler. Call-by-value is dual to call-by-name. In Proceedings of ICFP, pages 189–201. ACM, 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. N. Zeilberger. On the unity of duality. Annals of Pure Applied Logic, 153(1-3):66–96, 2008.Google ScholarGoogle ScholarCross RefCross Ref

Index Terms

  1. Structures for structural recursion

      Recommendations

      Comments

      Login options

      Check if you have access through your login credentials or your institution to get full access on this article.

      Sign in

      Full Access

      PDF Format

      View or Download as a PDF file.

      PDF

      eReader

      View online with eReader.

      eReader
      About Cookies On This Site

      We use cookies to ensure that we give you the best experience on our website.

      Learn more

      Got it!