151 research outputs found

    Structural Induction Principles for Functional Programmers

    Full text link
    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.Comment: In Proceedings TFPIE 2013, arXiv:1312.221

    Efficient Data Structures for Automated Theorem Proving in Expressive Higher-Order Logics

    Get PDF
    Church's Simple Theory of Types (STT), also referred to as classical higher-order logik, is an elegant and expressive formal system built on top of the simply typed λ-calculus. Its mechanisms of explicit binding and quantification over arbitrary sets and functions allow the representation of complex mathematical concepts and formulae in a concise and unambiguous manner. Higher-order automated theorem proving (ATP) has recently made major progress and several sophisticated ATP systems for higher-order logic have been developed, including Satallax, Osabelle/HOL and LEO-II. Still, higher-order theorem proving is not as mature as its first-order counterpart, and robust implementation techniques for efficient data structures are scarce. In this thesis, a higher-order term representation based upon the polymorphically typed λ-calculus is presented. This term representation employs spine notation, explicit substitutions and perfect term sharing for efficient term traversal, fast β-normalization and reuse of already constructed terms, respectively. An evaluation of the term representation is performed on the basis of a heterogeneous benchmark set. It shows that while the presented term data structure performs quite well in general, the normalization results indicate that a context dependent choice of reduction strategies is beneficial. A term indexing data structure for fast term retrieval based on various low-level criteria is presented and discussed. It supports symbol-based term retrieval, indexing of terms via structural properties, and subterm indexing

    The Vampire and the FOOL

    Full text link
    This paper presents new features recently implemented in the theorem prover Vampire, namely support for first-order logic with a first class boolean sort (FOOL) and polymorphic arrays. In addition to having a first class boolean sort, FOOL also contains if-then-else and let-in expressions. We argue that presented extensions facilitate reasoning-based program analysis, both by increasing the expressivity of first-order reasoners and by gains in efficiency

    Value Types in Eiffel

    Get PDF
    Identifies a number of problems with Eiffel's expanded types in modelling value types, and proposes a backward compatible syntactic extension, and a modified semantics. The latter is also shown to be (effectively) backward compatible, in the sense that existing programs would run unaffected if compilers implemented the new semantics. The benefits of the approach are discussed, including an elegant approach to rebuilding data structure libraries

    Tip: Tools for inductive provers

    Get PDF
    TIP is a toolbox for users and developers of inductive provers. It consists of a large number of tools which can, for example, simplify an inductive problem, monomorphise it or find counterexamples to it. We are using TIP to help maintain a set of benchmarks for inductive theorem provers, where its main job is to encode aspects of the problem that are not natively supported by the respective provers. TIP makes it easier to write inductive provers, by supplying necessary tools such as lemma discovery which prover authors can simply import into their own prover

    Rn and Gn Logics

    Get PDF
    This paper proposes a simple, set-theoretic framework providingexpressive typing, higher-order functions and initial models atthe same time. Building upon Russell's ramified theory of types, we developthe theory of Rn-logics, which are axiomatisable by an order-sortedequational Horn logic with a membership predicate, and of Gn-logics,that provide in addition partial functions. The latter are therefore moreadapted to the use in the program specification domain, while sharing interesting properties, like existence of an initial model, with Rn-logics. Operational semantics of Rn-/Gn-logics presentations is obtained throughorder-sorted conditional rewriting
    • …
    corecore