Results 1  10
of
27
How to Declare an Imperative
, 1995
"... How can we integrate interaction into a purely declarative language? This tutorial describes a solution to this problem based on a monad. The solution has been implemented in the functional language Haskell and the declarative language Escher. Comparisons are given to other approaches to interaction ..."
Abstract

Cited by 98 (3 self)
 Add to MetaCart
How can we integrate interaction into a purely declarative language? This tutorial describes a solution to this problem based on a monad. The solution has been implemented in the functional language Haskell and the declarative language Escher. Comparisons are given to other approaches to interaction based on synchronous streams, continuations, linear logic, and side effects.
Monads and Effects
 IN INTERNATIONAL SUMMER SCHOOL ON APPLIED SEMANTICS APPSEMâ€™2000
, 2000
"... A tension in language design has been between simple semantics on the one hand, and rich possibilities for sideeffects, exception handling and so on on the other. The introduction of monads has made a large step towards reconciling these alternatives. First proposed by Moggi as a way of structu ..."
Abstract

Cited by 52 (6 self)
 Add to MetaCart
A tension in language design has been between simple semantics on the one hand, and rich possibilities for sideeffects, exception handling and so on on the other. The introduction of monads has made a large step towards reconciling these alternatives. First proposed by Moggi as a way of structuring semantic descriptions, they were adopted by Wadler to structure Haskell programs, and now offer a general technique for delimiting the scope of effects, thus reconciling referential transparency and imperative operations within one programming language. Monads have been used to solve longstanding problems such as adding pointers and assignment, interlanguage working, and exception handling to Haskell, without compromising its purely functional semantics. The course will introduce monads, effects and related notions, and exemplify their applications in programming (Haskell) and in compilation (MLj). The course will present typed metalanguages for monads and related categorica...
Functional Programming with Graphs
 2ND ACM SIGPLAN INT. CONF. ON FUNCTIONAL PROGRAMMING
, 1997
"... Graph algorithms expressed in functional languages often suffer from their inherited imperative, statebased style. In particular, this impedes formal program manipulation. We show how to model persistent graphs in functional languages by graph constructors. This provides a decompositional view of g ..."
Abstract

Cited by 29 (10 self)
 Add to MetaCart
Graph algorithms expressed in functional languages often suffer from their inherited imperative, statebased style. In particular, this impedes formal program manipulation. We show how to model persistent graphs in functional languages by graph constructors. This provides a decompositional view of graphs which is very close to that of data types and leads to a "more functional" formulation of graph algorithms. Graph constructors enable the definition of general fold operations for graphs. We present a promotion theorem for one of these folds that allows program fusion and the elimination of intermediate results. Fusion is not restricted to the elimination of treelike structures, and we prove another theorem that facilitates the elimination of intermediate graphs. We describe an MLimplementation of persistent graphs which efficiently supports the presented fold operators. For example, depthfirstsearch expressed by a fold over a functional graph has the same complexity as the corresp...
Tsukuba termination tool
 In Proc. 14th RTA, LNCS 2706
, 2003
"... We present a tool for automatically proving termination of firstorder rewrite systems. The tool is based on the dependency pair method of Arts and Giesl [1]. It incorporates several new ideas that make the method more efficient. The tool produces highquality output and has a convenient web interfa ..."
Abstract

Cited by 17 (1 self)
 Add to MetaCart
We present a tool for automatically proving termination of firstorder rewrite systems. The tool is based on the dependency pair method of Arts and Giesl [1]. It incorporates several new ideas that make the method more efficient. The tool produces highquality output and has a convenient web interface. If T T T succeeds in proving termination, it outputs a proof script which explains in considerable detail how termination was proved. This script is available in both HTML and L ATEX format. In the latter, the approximated dependency graph is visualized using the dot tool of the Graphviz toolkit. T T T is written in Objective Caml. We tested the various options of T T T on numerous examples. The results, as well as a comparison with other tools that implement the dependency pair method and some implementation details, can be found in [2, 3]. We describe some of the features of the tool (T T T in the sequel) by means of its web interface, displayed in Fig. 1. TRS The user inputs a TRS by typing the rules into the upper right text area or by uploading a file via the browse button. The exact input format is obtained by clicking the TRS link. Comment and Bibtex Anything typed into the upper right text area will appear as a footnote in the generated L ATEX code. This is useful to identify TRSs. L ATEX \cite commands may be included. In order for this to work correctly, a corresponding bibtex entry should be supplied. This can be done by typing the entry into the appropriate text area or by uploading an appropriate bibtex file via the browse button. Base Order The current version of T T T supports the following three base orders: LPO with strict precedence, LPO with quasiprecedence, and KBO with strict precedence. Dependency Pairs T T T supports the basic features of the dependency pair technique (argument filtering, dependency graph, cycle analysis) described below. Advanced features like narrowing, rewriting, and instantiation are not yet available. Also innermost termination analysis is not yet implemented.
Inductive Graphs and Functional Graph Algorithms
, 2001
"... We propose a new style of writing graph algorithms in functional languages which is based on an alternative view of graphs as inductively defined data types. We show how this graph model can be implemented efficiently, and then we demonstrate how graph algorithms can be succinctly given by recursive ..."
Abstract

Cited by 17 (2 self)
 Add to MetaCart
We propose a new style of writing graph algorithms in functional languages which is based on an alternative view of graphs as inductively defined data types. We show how this graph model can be implemented efficiently, and then we demonstrate how graph algorithms can be succinctly given by recursive function definitions based on the inductive graph view. We also regard this as a contribution to the teaching of algorithms and data structures in functional languages since we can use the functionalstyle graph algorithms instead of the imperative algorithms that are dominant today. Keywords: Graphs in Functional Languages, Recursive Graph Algorithms, Teaching Graph Algorithms in Functional Languages
Value Recursion in Monadic Computations
 OGI School of Science and Engineering, OHSU
, 2002
"... viii 1 ..."
Modular Lazy Search for Constraint Satisfaction Problems
 JOURNAL OF FUNCTIONAL PROGRAMMING
, 2001
"... We describe a unified, lazy, declarative framework for solving constraint satisfaction problems, an important subclass of combinatorial search problems. These problems are both practically significant and hard. Finding good solutions involves combining good generalpurpose search algorithms with p ..."
Abstract

Cited by 6 (1 self)
 Add to MetaCart
We describe a unified, lazy, declarative framework for solving constraint satisfaction problems, an important subclass of combinatorial search problems. These problems are both practically significant and hard. Finding good solutions involves combining good generalpurpose search algorithms with problemspecific heuristics. Conventional imperative algorithms are usually implemented and presented monolithically, which makes them hard to understand and reuse, even though new algorithms often are combinations of simpler ones. Lazy functional languages, such as Haskell, encourage modular structuring of search algorithms by separating the generation and testing of potential solutions into distinct functions communicating through an explicit, lazy intermediate data structure. But only relatively simple search algorithms have been treated in this way in the past. Our framework uses a generic generation and pruning algorithm parameterized by a labeling function that annotates search t...
Synthesis of Fast Programs for Maximum Segment Sum Problems
"... It is wellknown that a naive algorithm can often be turned into an efficient program by applying appropriate semanticspreserving transformations. This technique has been used to derive programs to solve a variety of maximumsum programs. One problem with this approach is that each problem variation ..."
Abstract

Cited by 3 (2 self)
 Add to MetaCart
It is wellknown that a naive algorithm can often be turned into an efficient program by applying appropriate semanticspreserving transformations. This technique has been used to derive programs to solve a variety of maximumsum programs. One problem with this approach is that each problem variation requires a new set of transformations to be derived. An alternative approach to synthesis combines problem specifications with flexible algorithm theories to derive efficient algorithms. We show how this approach can be implemented in Haskell and applied to solve constraint satisfaction problems. We illustrate this technique by deriving programs for three varieties of maximumweightsum problem. The derivations of the different programs are similar, and the resulting programs are asymptotically faster in practice than the programs created by transformation. 1.
A Pure Language with Default Strict Evaluation . . .
, 2003
"... We propose a pure language with a default strict evaluation order and explicit laziness annotations. These annotations do not make a distinction between the types of values and computations as is often done in lazy additions to strict languages. This supplies all the expressivity available in lazy l ..."
Abstract

Cited by 3 (0 self)
 Add to MetaCart
We propose a pure language with a default strict evaluation order and explicit laziness annotations. These annotations do not make a distinction between the types of values and computations as is often done in lazy additions to strict languages. This supplies all the expressivity available in lazy languages with much of the speed available in strict languages, for the modest cost of programmer supplied annotations. We explore the design space of mixed evaluation strategies, and compare our proposal with other work in this area. A simple implementation suggests that it is relatively straightforward for the programmer to supply the correct annotations.
A Second Year Course on Data Structures Based on Functional Programming
 Nijmegen (The Netherlands
, 1995
"... . In this paper, we make a proposal for a second year course on advanced programming, based on the functional paradigm. It assumes the existence of a first course on programming, also based on functional languages. Its main subject is data structures. We claim that advanced data structures and algo ..."
Abstract

Cited by 3 (1 self)
 Add to MetaCart
. In this paper, we make a proposal for a second year course on advanced programming, based on the functional paradigm. It assumes the existence of a first course on programming, also based on functional languages. Its main subject is data structures. We claim that advanced data structures and algorithms can be better taught at the functional paradigm than at the imperative one, and that this can be done without losing efficiency. We also claim that, as a consequence of the higher level of abstraction of functional languages, more subjects can be covered in the given amount of time. In the paper, numerous examples of unusual data structures and algorithms are presented illustrating the contents and the philosophy of the proposed course. 1 Introduction The controversy about the use of a functional language as the first programming language is still alive. Several proposals have been made on a first programming course based on the functional paradigm or on a mixture of the functional a...