Dear Mike, Of course, in functional programming the applications of categories go far beyond lambda terms. (1) At a fairly elementary level, the treatment of list types in functional programming languages gives a good lead in to universal properties (e.g. list type = free monoid or free (empty, cons)- algebra). Things you do with the universal properties are present as well known tools in functional programming with lists. The universal properties can then be used to motivate the abstract structure of categories: they describe data types by their external interfaces with the rest of the world rather than by their concrete internal structure, and the morphisms play the role of saying what the external interactions are. Expositionally, for Mac Lane universal properties were an important example where the working mathematician had been doing category theory all along without knowing it. (2) More advanced, Haskell has made important use of monads as a programming technique for bringing side-effects, I/O etc into functional programming in an elegant way. (The way this came about is that it has long been more or less self-evident that categories are just what you need for describing the semantics, and the categorical experience of the semanticists led to the practical application of monads.) So it could be that the best way forward is to teach them Haskell first. (I gave a short introduction to categories at Imperial, in the Compujting Department, and I exploited heavily the fact that they had all done Miranda, a predecessor of Haskell.) Regards, Steve Vickers. On 22 Dec 2009, at 00:39, Mike Stay wrote:
On Mon, Dec 21, 2009 at 12:43 AM, Joyal, André <joyal.andre@uqam.ca> wrote:
In my message to John Baez, I wrote:
I can distinguish approximatly 6 major currents:
5) Category theory and computer science
I'm trying to expose my fellow programmers to the joys of category theory, but none of them have a math or physics background (or even a funcitonal programming background), which is where most of my experience with CT has been.
What have been the major applications of category theory to computer science that have affected programmers? Are there new algorithms? Are there really nice ways of solving certain problems? The fact that data types with equivalence classes of lambda terms between them form a cartesian closed category doesn't seem to inspire them very much. -- Mike Stay - metaweta@gmail.com http://math.ucr.edu/~mike http://reperiendi.wordpress.com
[For admin and other information see: http://www.mta.ca/~cat-dist/ ]