Results 1  10
of
11
Bananas in Space: Extending Fold and Unfold to Exponential Types
, 1995
"... Fold and unfold are general purpose functionals for processing and constructing lists. By using the categorical approach of modelling recursive datatypes as fixed points of functors, these functionals and their algebraic properties were generalised from lists to polynomial (sumofproduct) datatypes ..."
Abstract

Cited by 97 (7 self)
 Add to MetaCart
(Show Context)
Fold and unfold are general purpose functionals for processing and constructing lists. By using the categorical approach of modelling recursive datatypes as fixed points of functors, these functionals and their algebraic properties were generalised from lists to polynomial (sumofproduct) datatypes. However, the restriction to polynomial datatypes is a serious limitation: it precludes the use of exponentials (functionspaces) , whereas it is central to functional programming that functions are firstclass values, and so exponentials should be able to be used freely in datatype definitions. In this paper we explain how Freyd's work on modelling recursive datatypes as fixed points of difunctors shows how to generalise fold and unfold from polynomial datatypes to those involving exponentials. Knowledge of category theory is not required; we use Gofer throughout as our metalanguage, making extensive use of constructor classes. 1 Introduction During the 1980s, Bird and Meertens [6, 22] d...
Modular Denotational Semantics for Compiler Construction
 In European Symposium on Programming
, 1996
"... . We show the benefits of applying modular monadic semantics to compiler construction. Modular monadic semantics allows us to define a language with a rich set of features from reusable building blocks, and use program transformation and equational reasoning to improve code. Compared to denotational ..."
Abstract

Cited by 65 (4 self)
 Add to MetaCart
. We show the benefits of applying modular monadic semantics to compiler construction. Modular monadic semantics allows us to define a language with a rich set of features from reusable building blocks, and use program transformation and equational reasoning to improve code. Compared to denotational semantics, reasoning in monadic style offers the added benefits of highly modularized proofs and more widely applicable results. To demonstrate, we present an axiomatization of environments, and use it to prove the correctness of a wellknown compilation technique. The monadic approach also facilitates generating code in various target languages with different sets of builtin features. 1 Introduction We propose a modular semantics which allows language designers to add (or remove) programming language features without causing global changes to the existing specification, derive a compilation scheme from semantic descriptions, prove the correctness of program transformation and compilation...
Datatype Laws without Signatures
, 1996
"... ing from syntax. Conventionally an equation for algebra ' is just a pair of terms built from variables, the constituent operations of ' , and some fixed standard operations. An equation is valid if the two terms are equal for all values of the variables. We are going to model a syntactic t ..."
Abstract

Cited by 22 (6 self)
 Add to MetaCart
ing from syntax. Conventionally an equation for algebra ' is just a pair of terms built from variables, the constituent operations of ' , and some fixed standard operations. An equation is valid if the two terms are equal for all values of the variables. We are going to model a syntactic term as a morphism that has the values of the variables as source. For example, the two terms ` x ' and ` x join x ' (with variable x of type tree ) are modeled by morphisms id and id \Delta id ; join of type tree ! tree . So, an equation for ' is modeled by a pair of terms (T '; T 0 ') , T and T 0 being mappings of morphisms which we call `transformers'. This faces us with the following problem: what properties must we require of an arbitrary mapping T in order that it model a classical syntactic Datatype Laws without Signatures 7 term? Or, rather, what properties of classical syntactic terms are semantically essential, and how can we formalise these as properties of a transformer T ? Of course...
Fusion of recursive programs with computational effects
 Theoretical Computer Science
"... ..."
(Show Context)
Modal Logics for Representing Incoherent Knowledge
 In Handbook of Defeasible Reasoning and Uncertainty Management
, 1995
"... In this paper we review ways of representing incoherent 'knowledge' in a consistent way, where the use of modal logic and Kripkestyle semantics is put central. Starting with a presentation of the basic modal framework, we discuss the basic modal systems K, KD (with an excursion to the rep ..."
Abstract

Cited by 5 (0 self)
 Add to MetaCart
In this paper we review ways of representing incoherent 'knowledge' in a consistent way, where the use of modal logic and Kripkestyle semantics is put central. Starting with a presentation of the basic modal framework, we discuss the basic modal systems K, KD (with an excursion to the representation of conflicting norms in deontic logic) and Chellas' minimal modal logic D. Next we look at the epistemic logics KD45, S4 and S5, including the logical omniscience problem and several nonstandard modal logics to overcome this problem. After this we turn to the issue of reasoning by default, where a conflict of defaults (or default beliefs) may arise. We give an epistemic treatment of default reasoning, and treat the way conflicts of defaults can be solved viewed from the more general perspective of resolving conflicts in meta level reasoning. Furthermore, special attention is paid to specificity in default reasoning as a principle to solve these conflicts, for which we develop an extension of Halpern & Moses' theory of honest formulas. Finally, we discuss several numerical modal logics in their capacity of ways of representation of incoherent information.
Trends and Developments in Computational Geometry
 COMPUTER GRAPHICS FORUM
, 1995
"... This report discusses some trends and achievements in computational geometry during the past five years, with emphasis on problems related to computer graphics. Furthermore, a direction of research in computational geometry is discussed, which could help in bringing the fields of computational ge ..."
Abstract

Cited by 2 (0 self)
 Add to MetaCart
This report discusses some trends and achievements in computational geometry during the past five years, with emphasis on problems related to computer graphics. Furthermore, a direction of research in computational geometry is discussed, which could help in bringing the fields of computational geometry and computer graphics closer together.
Modular Monadic Semantics
"... Modular monadic semantics is a highlevel and modular form of denotational semantics. It is capable of capturing individual programming language features as small building blocks which can be combined to form a programming language of arbitrary complexity. Interactions between features are isolated ..."
Abstract
 Add to MetaCart
(Show Context)
Modular monadic semantics is a highlevel and modular form of denotational semantics. It is capable of capturing individual programming language features as small building blocks which can be combined to form a programming language of arbitrary complexity. Interactions between features are isolated in such a way that the building blocks are invariant. This paper explores the theory and application of modular monadic semantics, including the building blocks for individual programming language features, equational reasoning with laws and axioms, modular proofs, program transformation, modular interpreters, and semanticsdirected compilation. We demonstrate that modular monadic semantics makes programming languages easier to specify, reason about, and implement than the alternative of using conventional denotational semantics. Our contributions include: (a) the design of a fully modular interpreter based on monad transformers, including important features missing from several earlier efforts, (b) a method to lift monad operations through monad transformers, including difficult cases not achieved in earlier work, (c) a study of the semantic implications of the order of monad transformer composition, (d) a formal theory of modular monadic semantics that justifies our choice of liftings based on a notion of naturality, and (e) an implementation of our interpreter in Gofer, whose constructor classes provide just the added power over Haskell type classes to allow precise and convenient expression of our ideas. A note to reviewers: this paper is rather long. Short of resorting to “Part I / Part II”, the one way we see to shorten it would be to remove Section 4 and its Appendix B, which would amount to eliminating contribution (e) above. This would shorten the paper by about 12 pages.
Abstract Bananas in Space: Extending Fold and Unfold to Exponential Types
"... Fold and unfold are general purpose functionals for processing and constructing lists. By using the categorical approach of modelling recursive datatypes as fixed points of functors, these functionals and their algebraic properties were generalised from lists to polynomial (sumofproduct) datatypes ..."
Abstract
 Add to MetaCart
(Show Context)
Fold and unfold are general purpose functionals for processing and constructing lists. By using the categorical approach of modelling recursive datatypes as fixed points of functors, these functionals and their algebraic properties were generalised from lists to polynomial (sumofproduct) datatypes. However, the restriction to polynomial datatypes is a serious limitation: it precludes the use of exponentials (functionspaces), whereas it is central to functional programming that functions are firstclass values, and so exponentials should be able to be used freely in datatype definitions. In this paper we explain how Freyd’s work on modelling recursive datatypes as fixed points of difunctors shows how to generalise fold and unfold from polynomial datatypes to those involving exponentials. Knowledge of category theory is not required; we use Gofer throughout as our metalanguage, making extensive use of constructor classes. 1
Language Prototyping using Modular Monadic Semantics
, 1999
"... Modular monadic semantics allows the modular development of interpreters from semantic specifications be means of monad transformers. In this paper we show how to structure semantic descriptions using folds and monadic folds over functors that express the shape of the programming language. A given l ..."
Abstract
 Add to MetaCart
(Show Context)
Modular monadic semantics allows the modular development of interpreters from semantic specifications be means of monad transformers. In this paper we show how to structure semantic descriptions using folds and monadic folds over functors that express the shape of the programming language. A given language can be extended combining those functors without changing the original definitions. This approach will facilitate the implementation of language prototypes from reusable components. * This research is partially supported by the Project PBPTIC9701"Sistema Integral Orientado a Objetos: Oviedo3" from the "II Plan Regional de Investigación del Principado de Asturias" Introduction While traditional denotational semantics maps terms to values, monadic semantics [24] maps terms to computations. Where each computation can be modelled using specific monads. In general, it is not possible to compose two monads to obtain a new monad [15] but it is possible to transform a monad into a new m...
An Implementation of Modular Monadic Semantics using Folds and Monadic Folds
, 1998
"... Modular monadic semantics can be implemented using folds or catamorphisms over a functor that expresses the abstract syntax of the language. By composing several functors, it is possible to obtain modular interpreters from reusable components. Monadic folds structure programs that process recursivel ..."
Abstract
 Add to MetaCart
(Show Context)
Modular monadic semantics can be implemented using folds or catamorphisms over a functor that expresses the abstract syntax of the language. By composing several functors, it is possible to obtain modular interpreters from reusable components. Monadic folds structure programs that process recursively their input and control the side effects of the output they produce. We consider that the semantic specification of a programming language is a natural framework for monadic folds that improves the abstraction level and modularity. In this paper we use folds and monadic folds to develop the modular monadic semantics of a simple language. Introduction Using monads to structure denotational semantics [20] facilitates more modular semantic specifications. While traditional denotational semantics maps terms to values, monadic semantics maps terms to computations where a computation is modelled with a monad. In general, it is not possible to compose two monads to obtain a new monad [13], but ...