The Basic Linear Algebra Subprograms or BLAS provide the foundation for much of the software used in scientific computing. To date, BLAS has been implemented in C, Fortran, and directly in assembly. These languages al...
详细信息
The Basic Linear Algebra Subprograms or BLAS provide the foundation for much of the software used in scientific computing. To date, BLAS has been implemented in C, Fortran, and directly in assembly. These languages allow the implementations to be well optimized by hand ensuring when a BLAS routine is called that it is as fast a possible. functional programming languages, and in particular Haskell, do not allow the fine-grained control over memory, and their high-level features make it hard to optimize a single function to the level of C or assembly. However, Haskell has an advantage when optimizing combinations of container-based operations. Because of this we explore both implementing BLAS in Haskell and comparing the Glasgow Haskell Compiler’s ability to optimize scientific programs to that of a C compiler.
The combined use of user-defined infix operators and higher order functions allows the programmer to invent new control structures tailored to a particular problem area. This paper is to suggest that such a combinatio...
详细信息
The combined use of user-defined infix operators and higher order functions allows the programmer to invent new control structures tailored to a particular problem area. This paper is to suggest that such a combination has beneficial effects on the ease of both writing and reading programs, and hence can increase programmer productivity. As an example, a parser for a simple language is presented in this style. The compactness of this parser and its notational similarity to the BNF of the language are important advantages of the approach taken. It is hoped that the presentation will be palatable to people unfamiliar with the concepts of functional programming.
The article describes an IDE for functional programming, called WinHIPE. It provides an interactive and flexible tracer, as well as a powerful visualization and animation system. The former tool is based on the rewrit...
详细信息
The article describes an IDE for functional programming, called WinHIPE. It provides an interactive and flexible tracer, as well as a powerful visualization and animation system. The former tool is based on the rewriting model of evaluation, and the latter provides automatic generation of visualizations and animations, friendly support for customization, maintenance and exportation of animations to the Web, and facilities to cope with large scale. Its main advantage over other visualization systems is an effortless approach to animation creation and maintenance, based on generating visualizations and animations automatically, as a side effect of program execution. Finally, we briefly describe our experience using the system during several years in educational settings.
We report on our experience using functional programming languages in the development of a commercial GNU/Linux distribution, discussing features of several significant systems: hardware detection and system configura...
详细信息
Among the advantages claimed for a purely functional programming style is ease of designing and implementing large programs. However, little experience of actually doing so has been gained so far. The experience of wr...
详细信息
Among the advantages claimed for a purely functional programming style is ease of designing and implementing large programs. However, little experience of actually doing so has been gained so far. The experience of writing a particular medium sized program in a functional language is described here, with particular emphasis on the differences in programming style that were appropriate. This is compared with the experience of writing a very similar program in an imperative language. The main conclusions appear to be that the functional version was significantly easier to write, and was considerably smaller, though not by as large a factor as is sometimes claimed; that strong typing is, if anything, more desirable than in imperative systems; and that the question of debugging functional programs needs further research attention.
In this paper, we show how lazy functional programming techniques can be used within the Java programming language. We provide Java implementations of classic examples of lazy lists, such as the Sieve of Eratosthenes,...
详细信息
In this paper, we show how lazy functional programming techniques can be used within the Java programming language. We provide Java implementations of classic examples of lazy lists, such as the Sieve of Eratosthenes, the Eight Queens Problem, and natural-language parsing. We discuss how well these implementations succeed, compared to their original counterparts. We also point out the potential synergy between adding lazy techniques to Java, and adding generic types. The examples we provide would be suitable for teaching functional programming concepts in the context of a Java-based syllabus.
functional programming has its roots in Alonzo Church's lambda calculus. A functional program is a collection of functions that work together to transform data. Though Lisp brought functional programming to public...
详细信息
functional programming has its roots in Alonzo Church's lambda calculus. A functional program is a collection of functions that work together to transform data. Though Lisp brought functional programming to public attention in the 1950s, it was John Backus's 1977 Turing Award lecture criticizing the limitations of imperative programming languages that led to a resurgence of interest in this field. The 1970s and 1980s saw a number of advances, leading to the development of the language Haskell, which carefully combined ideas from many earlier languages. In this article, we explore some basic notions of functional programming via Haskell.
暂无评论