Results 1  10
of
75
A functional correspondence between monadic evaluators and abstract machines for languages with computational effects
 Theoretical Computer Science
, 2005
"... Abstract. We extend our correspondence between evaluators and abstract machines from the pure setting of the λcalculus to the impure setting of the computational λcalculus. We show how to derive new abstract machines from monadic evaluators for the computational λcalculus. Starting from (1) a gen ..."
Abstract

Cited by 47 (22 self)
 Add to MetaCart
(Show Context)
Abstract. We extend our correspondence between evaluators and abstract machines from the pure setting of the λcalculus to the impure setting of the computational λcalculus. We show how to derive new abstract machines from monadic evaluators for the computational λcalculus. Starting from (1) a generic evaluator parameterized by a monad and (2) a monad specifying a computational effect, we inline the components of the monad in the generic evaluator to obtain an evaluator written in a style that is specific to this computational effect. We then derive the corresponding abstract machine by closureconverting, CPStransforming, and defunctionalizing this specific evaluator. We illustrate the construction with the identity monad, obtaining yet again the CEK machine, and with a lifted state monad, obtaining a variant of the CEK machine with error and state. In addition, we characterize the tailrecursive stack inspection presented by Clements and Felleisen at ESOP 2003 as a lifted state monad. This enables us to combine the stackinspection monad with other monads and to construct abstract machines for languages with properly tailrecursive stack inspection and other computational effects. The construction scales to other monads—including one more properly dedicated to stack inspection than the lifted state monad—and other monadic evaluators. Keywords. Lambdacalculus, interpreters, abstract machines, closure conversion, transformation into continuationpassing style (CPS), defunctionalization, monads, effects, proper
Combining effects: sum and tensor
"... We seek a unified account of modularity for computational effects. We begin by reformulating Moggi’s monadic paradigm for modelling computational effects using the notion of enriched Lawvere theory, together with its relationship with strong monads; this emphasises the importance of the operations ..."
Abstract

Cited by 45 (5 self)
 Add to MetaCart
We seek a unified account of modularity for computational effects. We begin by reformulating Moggi’s monadic paradigm for modelling computational effects using the notion of enriched Lawvere theory, together with its relationship with strong monads; this emphasises the importance of the operations that produce the effects. Effects qua theories are then combined by appropriate bifunctors on the category of theories. We give a theory for the sum of computational effects, which in particular yields Moggi’s exceptions monad transformer and an interactive input/output monad transformer. We further give a theory of the commutative combination of effects, their tensor, which yields Moggi’s sideeffects monad transformer. Finally we give a theory of operation transformers, for redefining operations when adding new effects; we derive explicit forms for the operation transformers associated to the above monad transformers.
General recursion via coinductive types
 Logical Methods in Computer Science
"... Vol. 1 (2:1) 2005, pp. 1–28 ..."
(Show Context)
Handlers of Algebraic Effects
"... Abstract. We present an algebraic treatment of exception handlers and, more generally, introduce handlers for other computational effects representable by an algebraic theory. These include nondeterminism, interactive input/output, concurrency, state, time, and their combinations; in all cases the c ..."
Abstract

Cited by 24 (1 self)
 Add to MetaCart
Abstract. We present an algebraic treatment of exception handlers and, more generally, introduce handlers for other computational effects representable by an algebraic theory. These include nondeterminism, interactive input/output, concurrency, state, time, and their combinations; in all cases the computation monad is the freemodel monad of the theory. Each such handler corresponds to a model of the theory for the effects at hand. The handling construct, which applies a handler to a computation, is based on the one introduced by Benton and Kennedy, and is interpreted using the homomorphism induced by the universal property of the free model. This general construct can be used to describe previously unrelated concepts from both theory and practice. 1
The essence of dataflow programming
 In APLAS
, 2005
"... Abstract. We propose a novel, comonadic approach to dataflow (streambased) computation. This is based on the observation that both general and causal stream functions can be characterized as coKleisli arrows of comonads and on the intuition that comonads in general must be a good means to structure ..."
Abstract

Cited by 23 (3 self)
 Add to MetaCart
(Show Context)
Abstract. We propose a novel, comonadic approach to dataflow (streambased) computation. This is based on the observation that both general and causal stream functions can be characterized as coKleisli arrows of comonads and on the intuition that comonads in general must be a good means to structure contextdependent computation. In particular, we develop a generic comonadic interpreter of languages for contextdependent computation and instantiate it for streambased computation. We also discuss distributive laws of a comonad over a monad as a means to structure combinations of effectful and contextdependent computation. We apply the latter to analyse clocked dataflow (partial stream based) computation. 1
The essence of form abstraction
 In APLAS
, 2008
"... Abstract. Abstraction is the cornerstone of highlevel programming; HTML forms are the principal medium of web interaction. However, most web programming environments do not support abstraction of form components, leading to a lack of compositionality. Using a semantics based on idioms, we show how ..."
Abstract

Cited by 21 (8 self)
 Add to MetaCart
(Show Context)
Abstract. Abstraction is the cornerstone of highlevel programming; HTML forms are the principal medium of web interaction. However, most web programming environments do not support abstraction of form components, leading to a lack of compositionality. Using a semantics based on idioms, we show how to support compositional form construction and give a convenient syntax. 1
Reducibility and ⊤⊤lifting for computation types
 In Proc. 7th International Conference on Typed Lambda Calculi and Applications (TLCA), volume 3461 of Lecture Notes in Computer Science
, 2005
"... Abstract. We propose ⊤⊤lifting as a technique for extending operational predicates to Moggi’s monadic computation types, independent of the choice of monad. We demonstrate the method with an application to GirardTait reducibility, using this to prove strong normalisation for the computational meta ..."
Abstract

Cited by 19 (3 self)
 Add to MetaCart
(Show Context)
Abstract. We propose ⊤⊤lifting as a technique for extending operational predicates to Moggi’s monadic computation types, independent of the choice of monad. We demonstrate the method with an application to GirardTait reducibility, using this to prove strong normalisation for the computational metalanguage λml. The particular challenge with reducibility is to apply this semantic notion at computation types when the exact meaning of “computation ” (stateful, sideeffecting, nondeterministic, etc.) is left unspecified. Our solution is to define reducibility for continuations and use that to support the jump from value types to computation types. The method appears robust: we apply it to show strong normalisation for the computational metalanguage extended with sums, and with exceptions. Based on these results, as well as previous work with local state, we suggest that this “leapfrog ” approach offers a general method for raising concepts defined at value types up to observable properties of computations. 1
in press), Intermittent thinning of Jakobshavn Isbræ, west Greenland, since the Little Ice Age
 Journal of Glaciology Cuffey, K.M., and G.D. Clow
, 1997
"... ABSTRACT. Rapid thinning and velocity increase on major Greenland outlet glaciers during the last two decades may indicate that these glaciers became unstable as a consequence of the Jakobshavn effect (Hughes, 1986), with terminus retreat leading to increased discharge from the interior and conseque ..."
Abstract

Cited by 18 (0 self)
 Add to MetaCart
(Show Context)
ABSTRACT. Rapid thinning and velocity increase on major Greenland outlet glaciers during the last two decades may indicate that these glaciers became unstable as a consequence of the Jakobshavn effect (Hughes, 1986), with terminus retreat leading to increased discharge from the interior and consequent further thinning and retreat. To assess whether recent trends deviate from longerterm behavior, we measured glacier surface elevations and terminus positions for Jakobshavn Isbræ, West Greenland, using historical photographs acquired in 1944, 1953, 1959, 1964 and 1985. These results were combined with data from historical records, aerial photographs, ground surveys, airborne laser altimetry and field mapping of lateral moraines and trimlines, to reconstruct the history of changes since the Little Ice Age (LIA). We identified three periods of rapid thinning since the LIA: 1902–13, 1930–59 and 1999–present. During the first half of the 20th century, the calving front appears to have been grounded and it started to float during the late 1940s. The south and north tributaries exhibit different behavior. For example, the north tributary was thinning between 1959 and 1985 during a period when the calving front was stationary and the south tributary was in balance. The record of intermittent thinning, combined with changes in icemarginal extent and position of the calving front, together with changes in velocity, imply that the behavior of the lower parts of this glacier represents a complex icedynamical response to local climate forcings and interactions with drainage from the interior.
Monatron: an extensible monad transformer library. Available at http://www.cs.nott.ac.uk/~mjj/pubs/monatron.pdf
"... Abstract. Monads are pervasive in functional programming. In order to reap the benefits of their abstraction power, combinator libraries for monads are necessary. Monad transformers provide the basis for such libraries, and are based on a design that has proved to be successful. In this article, we ..."
Abstract

Cited by 17 (2 self)
 Add to MetaCart
(Show Context)
Abstract. Monads are pervasive in functional programming. In order to reap the benefits of their abstraction power, combinator libraries for monads are necessary. Monad transformers provide the basis for such libraries, and are based on a design that has proved to be successful. In this article, we show that this design has a number of shortcomings and provide a new design that builds on the strengths of the traditional design, but addresses its problems. 1
Programming with algebraic effects and handlers, 2012. URL http:// math.andrej.com/2012/03/08/programmingwithalgebraiceffectsandhandlers
"... Eff is a programming language based on the algebraic approach to computational effects, in which effects are viewed as algebraic operations and effect handlers as homomorphisms from free algebras. Eff supports firstclass effects and handlers through which we may easily define new computational ef ..."
Abstract

Cited by 16 (0 self)
 Add to MetaCart
(Show Context)
Eff is a programming language based on the algebraic approach to computational effects, in which effects are viewed as algebraic operations and effect handlers as homomorphisms from free algebras. Eff supports firstclass effects and handlers through which we may easily define new computational effects, seamlessly combine existing ones, and handle them in novel ways. We give a denotational semantics of eff and discuss a prototype implementation based on it. Through examples we demonstrate how the standard effects are treated in eff, and how eff supports programming techniques that use various forms of delimited continuations, such as backtracking, breadthfirst search, selection functionals, cooperative multithreading, and others.