6,163 research outputs found
Inductionârecursion and initial algebras
1 Introduction Induction-recursion is a powerful definition method in intuitionistic type theory in the sense of Scott ("Constructive Validity") [31] and Martin-L"of [17, 18, 19]. The first occurrence of formal induction-recursion is Martin-L"of's definition of a universe `a la Tarski [19], which consists of a set
Initial Algebra Semantics for Cyclic Sharing Tree Structures
Terms are a concise representation of tree structures. Since they can be
naturally defined by an inductive type, they offer data structures in
functional programming and mechanised reasoning with useful principles such as
structural induction and structural recursion. However, for graphs or
"tree-like" structures - trees involving cycles and sharing - it remains
unclear what kind of inductive structures exists and how we can faithfully
assign a term representation of them. In this paper we propose a simple term
syntax for cyclic sharing structures that admits structural induction and
recursion principles. We show that the obtained syntax is directly usable in
the functional language Haskell and the proof assistant Agda, as well as
ordinary data structures such as lists and trees. To achieve this goal, we use
a categorical approach to initial algebra semantics in a presheaf category.
That approach follows the line of Fiore, Plotkin and Turi's models of abstract
syntax with variable binding
Fibrational induction meets effects
This paper provides several induction rules that can be used to prove properties of effectful data types. Our results are semantic in nature and build upon Hermida and Jacobsâ fibrational formulation of induction for polynomial data types and its extension to all inductive data types by Ghani, Johann, and Fumex. An effectful data type ÎŒ(TF) is built from a functor F that describes data, and a monad T that computes effects. Our main contribution is to derive induction rules that are generic over all functors F and monads T such that ÎŒ(TF) exists. Along the way, we also derive a principle of definition by structural recursion for effectful data types that is similarly generic. Our induction rule is also generic over the kinds of properties to be proved: like the work on which we build, we work in a general fibrational setting and so can accommodate very general notions of properties, rather than just those of particular syntactic forms. We give examples exploiting the generality of our results, and show how our results specialize to those in the literature, particularly those of Filinski and StĂžvring
A Logic for Parametric Polymorphism
In this paper we introduce a logic for parametric polymorphism. Just as LCF is a
logic for the simply-typed -calculus with recursion and arithmetic, our logic is a logic for
System F. The logic permits the formal presentation and use of relational parametricity.
Parametricity yieldsâfor exampleâencodings of initial algebras, final co-algebras and
abstract datatypes, with corresponding proof principles of induction, co-induction and
simulation
On Sharing, Memoization, and Polynomial Time (Long Version)
We study how the adoption of an evaluation mechanism with sharing and
memoization impacts the class of functions which can be computed in polynomial
time. We first show how a natural cost model in which lookup for an already
computed value has no cost is indeed invariant. As a corollary, we then prove
that the most general notion of ramified recurrence is sound for polynomial
time, this way settling an open problem in implicit computational complexity
- âŠ