User loginNavigation |
FunctionalAcute: high-level programming language design for distributed computationFor more info, see the Main site, from which you can view papers and sample code. By Bryn Keller at 2004-08-06 15:55 | Functional | Implementation | Parallel/Distributed | login or register to post comments | other blogs | 14520 reads
Streaming Representation-Changers
Jeremy Gibbons (2004). Streaming Representation-Changers. To appear in Mathematics of Program Construction, July 2004.
Unfolds generate data structures, and folds consume them. A hylomorphism is a fold after an unfold, generating then consuming a virtual data structure. A metamorphism is the opposite composition, an unfold after a fold; typically, it will convert from one data representation to another. In general, metamorphisms are less interesting than hylomorphisms: there is no automatic fusion to deforest the intermediate virtual data structure. However, under certain conditions fusion is possible: some of the work of the unfold can be done before all of the work of the fold is complete. This permits streaming metamorphisms, and among other things allows conversion of infinite data representations. We present the theory of metamorphisms and outline some examples. More origami work from Gibbons. This paper is related to several previous papers by Gibbons that were mentioned here (e.g., spigot pi, arithmetic coding), and it could be said that it summarizes the main results. I don't think this paper was linked to directly, so here goes. Wobbly typesWobbly types: type inference for generalised algebraic data types
Edit: Made the title into a hyperlink, as the "Postscript" link could easily get lost in a sea of blue text... Edit 2:Quoted the article with a plain-ol' <blockquote> instead. Better? By Bryn Keller at 2004-07-19 16:19 | Functional | Type Theory | 7 comments | other blogs | 11461 reads
Functional programming in Java(Link)Vadim Nasardinov pointed out this article, which although pitched at an introductory level, provides a reasonably thorough overview of functional programming possibilities in Java. It focuses on the use of closures and higher-order functions, via Java's anonymous inner classes, and works its way up to "using closures to implement business rules" as one of its concrete examples. Perhaps a little too introductory for LtU, but articles like this can be a useful starting point when talking to Java programmers who've had little or no previous exposure to FP, or who need some hints about useful ways to apply FP concepts in Java. Using anonymous inner classes to implement e.g. GUI event listeners in Java is common practice, but often, more advanced and useful possibilities are overlooked. OCaml Release 3.08.0Objective Caml release 3.08.0 is official and incorporates many improvements. A big thank-you to the OCaml team for this stable release. Those on the bleeding edge of post-3.08 CVS work can follow Xavier's advice. Functional programming with GNU makeOne of the gems squirreled away on Oleg's site is "Makefile as a functional language program":
Although I've classified this under Fun, Oleg exploits
See the article for a code comparison By Anton van Straaten at 2004-07-11 19:19 | Fun | Functional | login or register to post comments | other blogs | 12982 reads
Enumerating the Rationals
Jeremy Gibbons, David Lester and Richard Bird (2004). Enumerating the Rationals. May 2004.
In this paper,we explain an elegant technique for enumerating the positive rationals without duplicates. Moreover, we show how to do so as a simple iteration, generating each element of the enumeration from the previous one alone,with constant cost per element (assuming unit cost for simple operations on arbitrary-precision rationals). Best of all, the resulting program is extremely simple... Cute. Nothing earth shattering, but fun none the less. Debugging Functional Programs
An interesting thread on the Haskell mailing list.
I am not sure whether the most reasonable conclusion from this thread isn't to not choose lazy languages. I don't think it's simply a problem of lack of tools. Debugging lazy code is iherently problematic. |
Browse archives
Active forum topics |
Recent comments
22 weeks 6 days ago
22 weeks 6 days ago
22 weeks 6 days ago
45 weeks 12 hours ago
49 weeks 2 days ago
50 weeks 6 days ago
50 weeks 6 days ago
1 year 1 week ago
1 year 6 weeks ago
1 year 6 weeks ago