计算机科学 > 程序设计语言
[提交于 2013年12月10日]
标题:Structural Induction Principles for Functional Programmers
查看原文 PDF 中文 PDF (下批处理) EasyResearch 阅读摘要:User defined recursive types are a fundamental feature of modern functional programming languages like Haskell, Clean, and the ML family of languages. Properties of programs defined by recursion on the structure of recursive types are generally proved by structural induction on the type. It is well known in the theorem proving community how to generate structural induction principles from data type declarations. These methods deserve to be better know in the functional programming community. Existing functional programming textbooks gloss over this material. And yet, if functional programmers do not know how to write down the structural induction principle for a new type - how are they supposed to reason about it? In this paper we describe an algorithm to generate structural induction principles from data type declarations. We also discuss how these methods are taught in the functional programming course at the University of Wyoming. A Haskell implementation of the algorithm is included in an appendix.
提交历史
来自:EPTCS[v1] 2013年12月10日 星期二 08:00:53 UTC