categories - Category Theory list
 help / color / mirror / Atom feed
* Re: additions
@ 2009-12-23  1:38 Fred E.J. Linton
  0 siblings, 0 replies; 23+ messages in thread
From: Fred E.J. Linton @ 2009-12-23  1:38 UTC (permalink / raw)
  To: categories

Responding to my tale of Sammy's having waved me away with his 

"Measure theory? That's analysis, isn't it? Go ask an analyst."

Michael Barr quite correctly remembered, in a private email, 

"But you did ask an analyst, as I recall. Lorch was your advisor."

True. But only after Sammy's "rejection," on the grounds given,
and Dick Kadison's subsequent rebuff after I approached him: 

"Measure Theory? Integration? That's Functional Analysis. 
I do Operator Theory. Go find a functional analyst."
 
Edgar Raymond Lorch was rather more ... umm ... open-minded :-) .

Though at one point, after I handed him the nth installment of my 
draft thesis to peruse, he did echo the words of Jesus, on the cross, 
when he was given a cup of vinegar to quench his thirst:

"Oh, Lord, must I drink of this?"

Cheers, -- FEJ Linton




[For admin and other information see: http://www.mta.ca/~cat-dist/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
  2009-12-29 23:17   ` additions Mike Stay
@ 2009-12-30 21:00     ` Greg Meredith
  0 siblings, 0 replies; 23+ messages in thread
From: Greg Meredith @ 2009-12-30 21:00 UTC (permalink / raw)
  To: Mike Stay

Dear Mike,

I suppose what I'm really looking for is cool algorithms like the one

described in Backhouse's paper "Fusion on Languages" (thanks, Neel!)

where they either wouldn't have been discovered without category

theory, or where category theory is the only decent way to understand

the algorithm.


While not quite what you are looking for Rydeheard and
Burstall<http://www.cs.manchester.ac.uk/~david/categories/book/book.pdf>might
provide a good jumping off point.

Best wishes,

--greg

On Tue, Dec 29, 2009 at 3:17 PM, Mike Stay <metaweta@gmail.com> wrote:

> 2009/12/25 Carsten Führmann <c.fuhrmann@bath.ac.uk>:
> > I used the term "functional [programming] language" on purpose (as
> > opposed to "functional programming style"), because of your statement
> >
> >> So there's not a lot of call for learning a functional programming
> >> language either.
> >
> > which I feel might be wrong.
>
> OK, I worded that badly.  I think there are lots of reasons to learn
> functional programming, and once you're doing functional programming,
> then you need to learn category theory to do it well.
>
> Most of the code we've got is not functional, and the languages we
> work with make it hard to use higher-order functions and closures.  So
> there's some resistance to overcome in convincing people to use
> functional style.
>

...


[For admin and other information see: http://www.mta.ca/~cat-dist/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
       [not found] ` <4B347567.9070603@bath.ac.uk>
@ 2009-12-29 23:17   ` Mike Stay
  2009-12-30 21:00     ` additions Greg Meredith
  0 siblings, 1 reply; 23+ messages in thread
From: Mike Stay @ 2009-12-29 23:17 UTC (permalink / raw)
  To: categories

2009/12/25 Carsten Führmann <c.fuhrmann@bath.ac.uk>:
> I used the term "functional [programming] language" on purpose (as
> opposed to "functional programming style"), because of your statement
>
>> So there's not a lot of call for learning a functional programming
>> language either.
>
> which I feel might be wrong.

OK, I worded that badly.  I think there are lots of reasons to learn
functional programming, and once you're doing functional programming,
then you need to learn category theory to do it well.

Most of the code we've got is not functional, and the languages we
work with make it hard to use higher-order functions and closures.  So
there's some resistance to overcome in convincing people to use
functional style.

> I meant that JavaScript is a functional
> programming language in the same way in which ML/OCaml/F#, Lisp, and
> Scheme are (just uglier, slower, and running in a sandbox called
> "browser"). These are considered functional languages by many, and
> their categorical semantics has been studied. (Well, the semantics of
> idealized versions.)  JavaScript is just riddled with some syntactic
> and semantic ugliness that makes it unattractive for formal study, but
> that doesn't make it un-functional in principle.

The syntax of those languages certainly encourages functional
composition over imperative programming, and they make it easy to
construct closures and higher-order functions.  However, none of them
are purely functional like Haskell.  I suppose I don't see the point
of making the distinction between functional and imperative unless you
really can't cause side-effects.

>> I'm not sure what you mean by "the whole monad business does not
>> apply".  There are lots of monads, each doing something different.
>> There are several monadic parsers I know of in JavaScript, for
>> instance.  Here's a monad for making JavaScript be lazily evaluated
>>instead of eager:
>>  function e(x) { return function() { return x; } }
>>  function m(x, y) { return function () { return x()(y()); } }
>
> Doesn't very fact that JavaScript allows you to write down the
> delaying monad give away its functional-language nature? And doesn't

I could write down the delaying monad in Java, too, but it would be
much larger.  If the only feature you require of a functional language
is that the syntax makes it *possible* to create closures, then nearly
any programming language will fit the bill.  If it has to be easy,
then Java and C/C++ are not functional, while Scheme, ML, JavaScript
and Perl are.  On the other hand, if you say that it should be hard to
use the imperative style in a functional language, then Scheme and ML
are functional, while Perl and JavaScript are not.

> the existence of monadic parsers in JavaScript underpin that it might
> be beneficial for real-life programmers to learn some functional
> programming?

Sure.  See above.

> By "monad business" I meant using monads to introduce side effects to
> lazy languages like Haskell, I could have been clearer there.
>
> Categorically, your monad is of a different kind, as I shall now
> sketch. (Just in case anyone is interested.)

Thanks, that _was_ interesting!

I suppose what I'm really looking for is cool algorithms like the one
described in Backhouse's paper "Fusion on Languages" (thanks, Neel!)
where they either wouldn't have been discovered without category
theory, or where category theory is the only decent way to understand
the algorithm.

> Happy holidays,
>   Carsten

Thanks!  To you, too.
-- 
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/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
  2009-12-22  2:24           ` additions Joyal, André
  2009-12-23 20:51             ` additions Thorsten Altenkirch
  2009-12-24 23:55             ` additions Dusko Pavlovic
@ 2009-12-26  2:14             ` Peter Selinger
  2 siblings, 0 replies; 23+ messages in thread
From: Peter Selinger @ 2009-12-26  2:14 UTC (permalink / raw)
  To: joyal.andre

In defense of Andre's list, the explanation he gave for his original
list was that subjects in category theory become hot from time to time
in response to factors such as new developments outside category
theory. The list was supposed to be a list of categorical subjects,
not a list of the respective developments that have inspired their use
and advancement.

The current use of category theory in quantum foundations is clearly
an interesting development, and has inspired new work in category
theory. But I would still be comfortable, for the time being, in
classifying this new work as falling within the existing subjects of
"monoidal categories" and "category theory and computer science" on
Andre's growing list. Recently also "topos theory" due to the work of
Andreas Doering, Klaas Landsman, and others on topos models for basic
physics.

As for the completeness result that Thorsten mentioned, the reference
is:

 M. Hasegawa, M. Hofmann and G. Plotkin, "Finite dimensional vector
 spaces are complete for traced symmetric monoidal categories".  In
 Pillars of Computer Science: Essays Dedicated to Boris (Boaz)
 Trakhtenbrot on the Occasion of His 85th Birthday, Springer LNCS
 4800, pages 367-385, February 2008.

The result is that an equation holds in all traced symmetric monoidal
categories if and only if it holds in finite dimensional vector
spaces. An immediate corollary is that the analogous result holds for
compact closed categories.  A simplified proof, and extension to
dagger compact closed categories (w.r.t. finite dimensional Hilbert
spaces), can be found here:

 P. Selinger, "Finite dimensional Hilbert spaces are complete for
 dagger compact closed categories". Extended abstract, to appear in
 Proceedings of the 5th International Workshop on Quantum Physics and
 Logic (QPL 2008), Reykjavik, 2010.

Merry Christmas to all, -- Peter


[For admin and other information see: http://www.mta.ca/~cat-dist/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
  2009-12-24 16:25   ` additions Mike Stay
@ 2009-12-26  0:03     ` Toby Bartels
  0 siblings, 0 replies; 23+ messages in thread
From: Toby Bartels @ 2009-12-26  0:03 UTC (permalink / raw)
  To: categories

Mike Stay wrote in part:

>Yes--most JavaScript development is done by amateurs who cut and paste
>someone else's code and try to tweak it to do what they want.  They
>are not mathematicians.

Actually, some of us *are* mathematicians.
But we are not programmers.


--Toby


[For admin and other information see: http://www.mta.ca/~cat-dist/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
       [not found]   ` <7f854b310912240825s39f195b2x2db16cc8f3a5cde7@mail.gmail.com>
@ 2009-12-25  8:18     ` Carsten Führmann
  0 siblings, 0 replies; 23+ messages in thread
From: Carsten Führmann @ 2009-12-25  8:18 UTC (permalink / raw)
  To: Mike Stay


Dear Mike,

 >> It might be worth noting that JavaScript is a functional language.
 >> (It has a lambda operator ("function"), closures, and can pass
 >> functions as parameters and return values.) However, because it has
 >> eager evaluation, the whole monad business does not apply, at least
 >> not
 >> in the way it applies to Haskell.
 >>
 >> In fact, JavaScript is probably the most widely used functional
 >> language
 >> on the planet.
 >
 > I think you're confusing the existence of first-class functions with
 > functional programming.  Functional programming avoids state and
 > mutable data. It emphasizes the application of functions, in contrast
 > to the imperative programming style, which emphasizes changes in
 > state.
 >
 > It's certainly possible to write functional programs in any of these
 > languages, but it takes a lot of conscious effort--in fact, I'd say
 > it's harder to write a functional program in JavaScript because of the
 > myriad of strange ways state changes occur.

I used the term "functional [programming] language" on purpose (as
opposed to "functional programming style"), because of your statement

 >> So there's not a lot of call for learning a functional programming
language either.

which I feel might be wrong. I meant that JavaScript is a functional
programming language in the same way in which ML/OCaml/F#, Lisp, and
Scheme are (just uglier, slower, and running in a sandbox called
"browser"). These are considered functional languages by many, and
their categorical semantics has been studied. (Well, the semantics of
idealized versions.)  JavaScript is just riddled with some syntactic
and semantic ugliness that makes it unattractive for formal study, but
that doesn't make it un-functional in principle.

 > I'm not sure what you mean by "the whole monad business does not
 > apply".  There are lots of monads, each doing something different.
 > There are several monadic parsers I know of in JavaScript, for
 > instance.  Here's a monad for making JavaScript be lazily evaluated
 >instead of eager:
 >  function e(x) { return function() { return x; } }
 >  function m(x, y) { return function () { return x()(y()); } }

Doesn't very fact that JavaScript allows you to write down the
delaying monad give away its functional-language nature? And doesn't
the existence of monadic parsers in JavaScript underpin that it might
be beneficial for real-life programmers to learn some functional
programming?

By "monad business" I meant using monads to introduce side effects to
lazy languages like Haskell, I could have been clearer there.

Categorically, your monad is of a different kind, as I shall now
sketch. (Just in case anyone is interested.)  First, we need to
observe that it is not straightforwardly a monad in the categorical
sense.  The reason is that the naturality square of the "unit" e does
not commute.  Considering that underlying functor T of the
monad-in-spe sends a morphism f to

T f = lambda g.lambda().f(g())

the naturality square would be

e \circ f == (lambda g.lambda (). f(g())) \circ e

which fails iff the f has a side effect (in the widest sense, which
includes going into an infinite loop): that effect would get invoked
on the equation's left side but not on the right.  However, your code
*does* represent a monad on the subcategory of (denotations of)
effect-free (and terminating) programs. Categorically, (T, m, e)
corresponds to an attempt to define a strong monad on an *unspecified*
subcategory of the symmetric premonoidal category (not CCC!)  that
models your eager language (long story...). Fortunately, such a
categories exist: e.g.  the maximum one is given by all morphisms
w.r.t. which your unit-in-spe is natural, but again that's a long
story.  At any rate, from a categorical and conceptional point of view
the delaying "monad" on an eager language differs from Haskell-style
monads.


Happy holidays,
    Carsten


http://www.cs.bath.ac.uk/~cf/


[For admin and other information see: http://www.mta.ca/~cat-dist/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
  2009-12-22  2:24           ` additions Joyal, André
  2009-12-23 20:51             ` additions Thorsten Altenkirch
@ 2009-12-24 23:55             ` Dusko Pavlovic
  2009-12-26  2:14             ` additions Peter Selinger
  2 siblings, 0 replies; 23+ messages in thread
From: Dusko Pavlovic @ 2009-12-24 23:55 UTC (permalink / raw)
  To: categories

bob coecke proposed to add quantum computing to andre joyal's list of
important directions of categorical research, but andre rejected it. i
cannot overstate my respect for andre's work and judgement. but this left
me pondering.

like andre, i must confess that i am quite ignorant about quantum
computing. (unlike andre, i am also ignorant about many other categorical
topics on his list.)  but we probably all know the following.

most results in quantum computing are theorems about hilbert spaces.
quantum computing is a *tensor calculus*. but it is a tensor calculus of a
special kind: it attempts to describe a wildly unintuitive world. even the
greatest contributors, like von neumann and feynman, deplored the gap
between the quantum world, imposed on us in the lab, and the intuitions
imposed on us in everyday life. now category theory often helps where the
common intuitions fail. many of its applications demonstrate this. so
quantum computation might be an opportunity for an effective application
of *geometry of tensor calculus*.

is it really wise to reject an attempt to develop this, as objectionable
as it might be in any details? physicists like string diagrams, category
theorists like string diagrams. most communities would actively reach
out...

is it just my impression, or are category theorists a little more
sceptical about the value of applications than most mathematical
communities? they seem to seek a recognition that categories are useful
across mathematics, but then hesitate to recognize the depth and value of
the applications in the other areas. --- can it be that we suffer from a
superiority complex of some sort?

the questions raised in the *well kept secret* thread were:

1) why are the achievements of category theory not recognized publicly?
2) what have we done to deserve the opprobium?
3) how can we convince the sceptics?

please allow me to add one more:

4) how can the achievements of category theory be used to expand its
future developments and applications, and not to constrain them?

with best wishes,
-- dusko



[For admin and other information see: http://www.mta.ca/~cat-dist/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
  2009-12-23 18:06             ` additions Mike Stay
  2009-12-24 13:12               ` additions Carsten Führmann
@ 2009-12-24 19:23               ` Dusko Pavlovic
  1 sibling, 0 replies; 23+ messages in thread
From: Dusko Pavlovic @ 2009-12-24 19:23 UTC (permalink / raw)
  To: Mike Stay

Mike Stay wrote:
> At Google,
> however, we use Java, C++ and Python (collectively "JCP") for programs

at one point, some googlers were interested in the conceptual views of
ranking. FWIW, a categorical view of the PagRank and some extensions is in
http://arxiv.org/abs/0802.1306
eg, the comma construction qpplies naturally...

-- dusko


[For admin and other information see: http://www.mta.ca/~cat-dist/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
       [not found] ` <4B3368C1.3000800@bath.ac.uk>
@ 2009-12-24 16:25   ` Mike Stay
  2009-12-26  0:03     ` additions Toby Bartels
       [not found]   ` <7f854b310912240825s39f195b2x2db16cc8f3a5cde7@mail.gmail.com>
  1 sibling, 1 reply; 23+ messages in thread
From: Mike Stay @ 2009-12-24 16:25 UTC (permalink / raw)
  To: Carsten Führmann

2009/12/24 Carsten Führmann <c.fuhrmann@bath.ac.uk>:
> Dear Mike,
>
>> Thanks, everyone for your replies!  Many of you suggested the same
>> approach as Steve, functional programming and monads.  At Google,
>> however, we use Java, C++ and Python (collectively "JCP") for programs
>> that run on our servers and JavaScript for programs that run in our
>> webpages.  So there's not a lot of call for learning a functional
>> programming language either.
>
> It might be worth noting that JavaScript is a functional language.
> (It has a lambda operator ("function"), closures, and can pass
> functions as parameters and return values.) However, because it has
> eager evaluation, the whole monad business does not apply, at least not
> in the way it applies to Haskell.
>
> In fact, JavaScript is probably the most widely used functional language
> on the planet.

I think you're confusing the existence of first-class functions with
functional programming.  Functional programming avoids state and
mutable data. It emphasizes the application of functions, in contrast
to the imperative programming style, which emphasizes changes in
state.

It's certainly possible to write functional programs in any of these
languages, but it takes a lot of conscious effort--in fact, I'd say
it's harder to write a functional program in JavaScript because of the
myriad of strange ways state changes occur.

I'm not sure what you mean by "the whole monad business does not
apply".  There are lots of monads, each doing something different.
There are several monadic parsers I know of in JavaScript, for
instance.  Here's a monad for making JavaScript be lazily evaluated
instead of eager:
  function e(x) { return function() { return x; } }
  function m(x, y) { return function () { return x()(y()); } }

> But there are two strange phenomena:
>
> - Functional-programming experts keep on overlooking JavaScript (probably
> because it is so ugly from a theorists point of view)

Probably because it's not functional.

> - Most professional JavaScript programmers fail to see the enormous
> functional potential of JavaScript.
>
> It is a very strange situation: the whole world uses a functional language
> and almost nobody is aware of it.
>
> Anyway, even though I am very category-prone, I must admit that category
> theory might be a very tough sell for the JavaScript crowd :)

Yes--most JavaScript development is done by amateurs who cut and paste
someone else's code and try to tweak it to do what they want.  They
are not mathematicians.

> Best,
>  Carsten
>



-- 
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/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
  2009-12-23 18:06             ` additions Mike Stay
@ 2009-12-24 13:12               ` Carsten Führmann
  2009-12-24 19:23               ` additions Dusko Pavlovic
  1 sibling, 0 replies; 23+ messages in thread
From: Carsten Führmann @ 2009-12-24 13:12 UTC (permalink / raw)
  To: Mike Stay

Dear Mike,

 > Thanks, everyone for your replies!  Many of you suggested the same
 > approach as Steve, functional programming and monads.  At Google,
 > however, we use Java, C++ and Python (collectively "JCP") for programs
 > that run on our servers and JavaScript for programs that run in our
 > webpages.  So there's not a lot of call for learning a functional
 > programming language either.

It might be worth noting that JavaScript is a functional language.
(It has a lambda operator ("function"), closures, and can pass
functions as parameters and return values.) However, because it has
eager evaluation, the whole monad business does not apply, at least not
in the way it applies to Haskell.

In fact, JavaScript is probably the most widely used functional language
on the planet.

But there are two strange phenomena:

- Functional-programming experts keep on overlooking JavaScript
(probably because it is so ugly from a theorists point of view)

- Most professional JavaScript programmers fail to see the enormous
functional potential of JavaScript.

It is a very strange situation: the whole world uses a functional
language and almost nobody is aware of it.

Anyway, even though I am very category-prone, I must admit that category
theory might be a very tough sell for the JavaScript crowd :)

Best,
   Carsten


[For admin and other information see: http://www.mta.ca/~cat-dist/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
  2009-12-22  2:24           ` additions Joyal, André
@ 2009-12-23 20:51             ` Thorsten Altenkirch
  2009-12-24 23:55             ` additions Dusko Pavlovic
  2009-12-26  2:14             ` additions Peter Selinger
  2 siblings, 0 replies; 23+ messages in thread
From: Thorsten Altenkirch @ 2009-12-23 20:51 UTC (permalink / raw)
  To: André

On 22 Dec 2009, at 02:24, Joyal, André wrote:

>  do not question the importance of the subject.
> But presently, I am not convinced that quantum computing can
> contribute significantly to category theory.

I have to admit that I am quite ignorant about many of the areas  
mentioned in the previous email. On the other hand developments in  
Computer Science I know about don't seem to feature. Maybe they are  
too mundane for Mathematicians.

As far as quantum computing goes, or maybe more general quantum theory  
from a computer science point of view, it seems to me that there are  
interesting interactions with category theory in the recent work by  
Samson Abramsky,  Bob Coecke, Peter Selinger and many others. E.g. the  
completeness of the graph theoretical calculus for dagger compact  
closed categories modelling finite dimensional Hilbert spaces.

Cheers,
Thorsten



[For admin and other information see: http://www.mta.ca/~cat-dist/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
  2009-12-23 11:19           ` additions Steve Vickers
  2009-12-23 18:06             ` additions Mike Stay
@ 2009-12-23 19:06             ` Thorsten Altenkirch
  1 sibling, 0 replies; 23+ messages in thread
From: Thorsten Altenkirch @ 2009-12-23 19:06 UTC (permalink / raw)
  To: Steve Vickers

Hi Steve & Mike,

I completely agree with Steve, I'd like to add  that instead of  
functional programming we could have said "mathematically structured  
programming". But then indeed the two terms are very closely related.

Category Theory helps us to structure abstractions. In Computer  
Science and in other areas (e.g. Physics). Some people seem to think  
that abstractions don't buy your anything concrete. E.g. they don't  
deliver faster algorithms or new physical theories. These people often  
overlook that everything they do relies essentially on abstractions  
which have been established a while ago.

Hence, while it is hard to measure the impact of abstractions exactly,  
IMHO it is almost impossible to underestimate their value.

Cheers,
Thorsten

On 23 Dec 2009, at 11:19, Steve Vickers wrote:

> 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.
>

[For admin and other information see: http://www.mta.ca/~cat-dist/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
  2009-12-23 11:19           ` additions Steve Vickers
@ 2009-12-23 18:06             ` Mike Stay
  2009-12-24 13:12               ` additions Carsten Führmann
  2009-12-24 19:23               ` additions Dusko Pavlovic
  2009-12-23 19:06             ` additions Thorsten Altenkirch
  1 sibling, 2 replies; 23+ messages in thread
From: Mike Stay @ 2009-12-23 18:06 UTC (permalink / raw)
  To: Steve Vickers

On Wed, Dec 23, 2009 at 3:19 AM, Steve Vickers
<s.j.vickers@cs.bham.ac.uk> wrote:
> 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...

> (2) More advanced, Haskell has made important use of monads as a programming
> technique...

> So it could be that the best way forward is to teach them Haskell first...

Thanks, everyone for your replies!  Many of you suggested the same
approach as Steve, functional programming and monads.  At Google,
however, we use Java, C++ and Python (collectively "JCP") for programs
that run on our servers and JavaScript for programs that run in our
webpages.  So there's not a lot of call for learning a functional
programming language either.

On the wikipedia page for monads in functional programming, I see
these examples:
* I/O--JCP aren't functional; side effects are easy.

* Maybe--This one's really exception handling, built into JCP.

* Identity--so trivial it's never used.

* Lists--built into JCP as arrays, together with the function "map";
the rest of the data structures are in the standard libraries, too.
Monads and catamorphisms certainly give a more unified picture, but
still not enough benefit to a programmer to justify the investment in
learning category theory.

* State & environment--as before, JCP aren't functional.  State and
environment are easy to come by.

* Continuation passing style transformation--useful for functional
language compiler writers for turning recursive programs into
iterative ones that don't consume the stack.  Very small audience.
Continuations are also useful for coroutines and "threadless actors",
but malicious code can consume all the resources--in this model,
there's no preemptive multitasking; it's all voluntary.

JCP are eagerly evaluated.  One monad that isn't on the wiki page is
for making a program be lazily
evaluated.  That can come in handy sometimes, but still doesn't
justify learning category theory.

I suppose the strongest argument I've heard for learning functional
programming (and thereby justifying learning category theory) is that
functional programs are much easier to test: there's no inaccessible
state to worry about setting up properly.  Monads allow the functional
programmer to do easily all these things he's used to from imperative
programming, while gaining the benefits of easy testability.

Other reasons I've received involve solving problems in specialized
domains.  I think if I have a long enough list of these, I could
probably convince my friends of category theory's utility.
-- 
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/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
  2009-12-23  0:05   ` additions Scott Morrison
@ 2009-12-23 14:13     ` Mark Weber
  0 siblings, 0 replies; 23+ messages in thread
From: Mark Weber @ 2009-12-23 14:13 UTC (permalink / raw)
  To: Scott Morrison, Michael Barr, categories

I wished to make the point that Tao uses categorical ideas and perspectives
freely. It would've been better if I'd referred to the specific postings in
which he does so ...

http://terrytao.wordpress.com/2009/10/19/grothendiecks-definition-of-a-group/
http://terrytao.wordpress.com/2009/12/21/the-free-nilpotent-group/

These postings aren't about themselves about category theory, but in them he
exhibits no inhibitions in using categorical language.

Regards,

Mark Weber

On Wed, Dec 23, 2009 at 1:05 AM, Scott Morrison <scott@tqft.net> wrote:

> Dear Mark,
>
> this is unfortunately a bad example. If you click through any of the
> results for "category" <http://terrytao.wordpress.com/?s=category> on
> Terry's page, you'll see that in nearly all cases, the only use of the
> word "category" is in "n-Category Cafe", which appears in the sidebar
> of every page, amongst the links to other blogs.
>
> best,
> Scott Morrison

[For admin and other information see: http://www.mta.ca/~cat-dist/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
  2009-12-22  0:39         ` additions Mike Stay
@ 2009-12-23 11:19           ` Steve Vickers
  2009-12-23 18:06             ` additions Mike Stay
  2009-12-23 19:06             ` additions Thorsten Altenkirch
  0 siblings, 2 replies; 23+ messages in thread
From: Steve Vickers @ 2009-12-23 11:19 UTC (permalink / raw)
  To: Mike Stay

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/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
  2009-12-22 12:21 ` additions Mark Weber
@ 2009-12-23  0:05   ` Scott Morrison
  2009-12-23 14:13     ` additions Mark Weber
  0 siblings, 1 reply; 23+ messages in thread
From: Scott Morrison @ 2009-12-23  0:05 UTC (permalink / raw)
  To: Mark Weber

Dear Mark,

this is unfortunately a bad example. If you click through any of the
results for "category" <http://terrytao.wordpress.com/?s=category> on
Terry's page, you'll see that in nearly all cases, the only use of the
word "category" is in "n-Category Cafe", which appears in the sidebar
of every page, amongst the links to other blogs.

best,
Scott Morrison

On Tue, Dec 22, 2009 at 06:21, Mark Weber
<mark.weber.math@googlemail.com> wrote:
> Dear Michael,
>
> 2009/12/21 Michael Barr <barr@math.mcgill.ca>
>
>> ...  His reply essentially was, "Oh, it's category theory language.  Well,
>> I won't allow any of that in MY notes. No analyst would use that language."
>>
>
> There's an easy reply to people infected with such silliness -- ask them if
> Terry Tao is an analyst, to which they'd probably reply "of course", and
> then tell them go to Tao's blog
>
> http://terrytao.wordpress.com/
>
> and do a search for "category" (the search bar on Terry's page is on the
> left just below "recent comments"). The results will speak for themselves.
>
> Mark Weber
>

[For admin and other information see: http://www.mta.ca/~cat-dist/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
  2009-12-17 23:30 A well kept secret? peasthope
  2009-12-18  4:09 ` John Baez
@ 2009-12-22 12:21 ` Mark Weber
  2009-12-23  0:05   ` additions Scott Morrison
       [not found] ` <4B3368C1.3000800@bath.ac.uk>
       [not found] ` <4B347567.9070603@bath.ac.uk>
  3 siblings, 1 reply; 23+ messages in thread
From: Mark Weber @ 2009-12-22 12:21 UTC (permalink / raw)
  To: Michael Barr, categories

Dear Michael,

2009/12/21 Michael Barr <barr@math.mcgill.ca>

> ...  His reply essentially was, "Oh, it's category theory language.  Well,
> I won't allow any of that in MY notes. No analyst would use that language."
>

There's an easy reply to people infected with such silliness -- ask them if
Terry Tao is an analyst, to which they'd probably reply "of course", and
then tell them go to Tao's blog

http://terrytao.wordpress.com/

and do a search for "category" (the search bar on Terry's page is on the
left just below "recent comments"). The results will speak for themselves.

Mark Weber


[For admin and other information see: http://www.mta.ca/~cat-dist/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
  2009-12-21 14:16         ` additions Bob Coecke
@ 2009-12-22  2:24           ` Joyal, André
  2009-12-23 20:51             ` additions Thorsten Altenkirch
                               ` (2 more replies)
  0 siblings, 3 replies; 23+ messages in thread
From: Joyal, André @ 2009-12-22  2:24 UTC (permalink / raw)
  To: Bob Coecke, categories

Dear Bob,

The subjects in my list were not chosen according to 
the size of research grants or the number of peoples hired in 
recent years by such and such institutions.
I know  first hand every subject in the list, at least at the basic level.
They make an essential use of category theory,
and they inspire new developements in the field.
I confess that I am quite ignorant about quantum computing.

You wrote:

>in funding terms
>this may currently be the 2nd most funded category-theory
>related area after Category Theory in Computer Science,
>with, for example, dedicated large EU grants, US Office
>of Naval Research support, and many others.  Also, this
>summer two researchers in the area obtained permanent
>positions in France, and here in Oxford we hired a
>3rd faculty member in the area.

I do not question the importance of the subject.
But presently, I am not convinced that quantum computing can
contribute significantly to category theory.

Best,
André

 


[For admin and other information see: http://www.mta.ca/~cat-dist/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
@ 2009-12-22  1:43 Fred E.J. Linton
  0 siblings, 0 replies; 23+ messages in thread
From: Fred E.J. Linton @ 2009-12-22  1:43 UTC (permalink / raw)
  To: categories

On Mon, 21 Dec 2009 07:20:29 PM EST, Michael Barr <barr@math.mcgill.ca>
reminisced:

> ... His 
> reply essentially was, "Oh, it's category theory language.  Well, I won't 
> allow any of that in MY notes. No analyst would use that language."

Amusing tale, reminding me of Sammy's response when I approached him, oh so
many decades ago, about supervising my proposed thesis on functorial measure 
theory: "Measure theory? That's analysis, isn't it? Go ask an analyst."

Cheers, and Seasons' Greetings, 

-- FEJ Linton




[For admin and other information see: http://www.mta.ca/~cat-dist/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
  2009-12-21  8:43       ` additions Joyal, André
  2009-12-21 14:16         ` additions Bob Coecke
@ 2009-12-22  0:39         ` Mike Stay
  2009-12-23 11:19           ` additions Steve Vickers
  1 sibling, 1 reply; 23+ messages in thread
From: Mike Stay @ 2009-12-22  0:39 UTC (permalink / raw)
  To: Joyal, André

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/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
  2009-12-18  4:09 ` John Baez
  2009-12-20 17:50   ` Joyal, André
@ 2009-12-21 19:20   ` Michael Barr
  1 sibling, 0 replies; 23+ messages in thread
From: Michael Barr @ 2009-12-21 19:20 UTC (permalink / raw)
  To: Joyal, André, categories

I would add something between 2 and 3 about Triples (allright, 
monads) and Equational theories.

Here is an example of the sort of thing we are up against.  A colleague 
called me this morning because a student had taken a set of notes (in 
French) on his course and was interested in publishing it.  My colleague 
had an objection because in describing conformal isomorphism from the 
complex plane (or maybe sphere) to itself, the student had used the word 
"towards" (vers) instead of "on".  His objection was that a conformal 
isomorphism was something between two spaces, not from one to the other. 
My answer was a specific such map was a map from one to the other.  His 
reply essentially was, "Oh, it's category theory language.  Well, I won't 
allow any of that in MY notes. No analyst would use that language."

Michael

On Mon, 21 Dec 2009, Joyal, André wrote:

> In my message to John Baez, I wrote:
>
>> I can distinguish approximatly 6 major currents:
>
>> 1) Algebraic topology and homological algebra
>> 2) Abelian categories
>> 3) Algebraic Geometry and topos theory
>> 4) Logic and elementary topos theory
>> 5) Category theory and computer science
>> 6) Higher categories with homotopy theory
>
> The list is too restrictive. I would like to expand it further:
>
> 1) Algebraic topology and homological algebra
> 2) Abelian categories
> 3) Algebraic geometry and topos theory
> 4) General cartesian algebra
> 5) Categorical logic
> 6) Homotopical algebra
> 7) Elementary topos theory and set theory
> 8) Monoidal categories and enriched category theory
> 9) General tensor algebra and coalgebra
> 10) Category theory and computer science
> 11) Quantum field theory
> 12) Higher categories and homotopy theory
>
> Algebraic theories and limit sketches are included in (4).
> Multicategories, operads are included in (9).
>
> I have included Quillen homotopical algebra in (6).
>
> Best,
> André
>

[For admin and other information see: http://www.mta.ca/~cat-dist/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* Re: additions
  2009-12-21  8:43       ` additions Joyal, André
@ 2009-12-21 14:16         ` Bob Coecke
  2009-12-22  2:24           ` additions Joyal, André
  2009-12-22  0:39         ` additions Mike Stay
  1 sibling, 1 reply; 23+ messages in thread
From: Bob Coecke @ 2009-12-21 14:16 UTC (permalink / raw)
  To: categories

Dear all,

May I point at another current activity:

> 1) Algebraic topology and homological algebra
> 2) Abelian categories
> 3) Algebraic geometry and topos theory
> 4) General cartesian algebra
> 5) Categorical logic
> 6) Homotopical algebra
> 7) Elementary topos theory and set theory
> 8) Monoidal categories and enriched category theory
> 9) General tensor algebra and coalgebra
> 10) Category theory and computer science
> 11) Quantum field theory
> 12) Higher categories and homotopy theory

13) Category theory in quantum information & quantum foundations

While only a quite recent activity, in funding terms
this may currently be the 2nd most funded category-theory
related area after Category Theory in Computer Science,
with, for example, dedicated large EU grants, US Office
of Naval Research support, and many others.  Also, this
summer two researchers in the area obtained permanent
positions in France, and here in Oxford we hired a
3rd faculty member in the area.

While money and science quality are obviously not always
that related to each other, funding is an essential
component for sustaining a research activity, enabeling
jobs for postdocs in the area, etc.

Best wishes, Bob.




[For admin and other information see: http://www.mta.ca/~cat-dist/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

* additions
       [not found]     ` <B3C24EA955FF0C4EA14658997CD3E25E2159B6AA@CAHIER.gst.uqam.ca>
@ 2009-12-21  8:43       ` Joyal, André
  2009-12-21 14:16         ` additions Bob Coecke
  2009-12-22  0:39         ` additions Mike Stay
  0 siblings, 2 replies; 23+ messages in thread
From: Joyal, André @ 2009-12-21  8:43 UTC (permalink / raw)
  To: categories

In my message to John Baez, I wrote:

>I can distinguish approximatly 6 major currents:

>1) Algebraic topology and homological algebra
>2) Abelian categories
>3) Algebraic Geometry and topos theory 
>4) Logic and elementary topos theory
>5) Category theory and computer science
>6) Higher categories with homotopy theory  

The list is too restrictive. I would like to expand it further:

1) Algebraic topology and homological algebra
2) Abelian categories
3) Algebraic geometry and topos theory 
4) General cartesian algebra
5) Categorical logic
6) Homotopical algebra
7) Elementary topos theory and set theory
8) Monoidal categories and enriched category theory
9) General tensor algebra and coalgebra
10) Category theory and computer science
11) Quantum field theory
12) Higher categories and homotopy theory  

Algebraic theories and limit sketches are included in (4).
Multicategories, operads are included in (9).

I have included Quillen homotopical algebra in (6).

Best, 
André


-------- Message d'origine--------
De: categories@mta.ca de la part de Joyal, André
Date: dim. 20/12/2009 12:50
À: John Baez; categories@mta.ca
Objet : categories: Re: A well kept secret?
 
John Baez wrote:

>They fought to convince the world that category theory was
>worthwhile. Some feel they lost that fight.  We came along later and
>are a bit puzzled by that attitude: if you look around at the
>landscape of mathematics today, categories are everywhere!  From
>Grothendieck to Voevodsky to Lurie, etc., much of the most exciting
>mathematics of our era would be inconceivable without categories.

Like most fields of mathematics, category theory keeps growing and evolving. 
It may be hard to identify the mechanism of this evolution 
but fashion must be playing a role.
But why are certain subjects becoming hot at a given time?
Probably because they resonate with new developments outside category theory.
When a trend becomes hot, it gives rise to a permanent current. 
I was able to distinguish approximatly 6 major currents:

1) Algebraic topology and homological algebra

2) Abelian categories

3) Algebraic Geometry and topos theory 

4) Logic and elementary topos theory

5) Category theory and computer science

6) Higher categories with homotopy theory  

Here is an example of a recent applications of category theory to geometry:

"Associahedral categories, particles and Morse functor" 
by Jean-Yves Welschinger http://arxiv.org/abs/0906.4712 

The n-category caffé is an extraordinary experiment in 
research collaboration and dissimination of knowledge.
It maybe the way of the future.
But an old mathematicians like me find it 
difficult to adapt to this new form of collaboration. 

>The only real question is whether our current civilization, based on burning
>carbon, tearing up forests, and destroying oceans, lasts long enough to see
>this change.

Yep! And we should not remain passive.

Best,
AJ


[For admin and other information see: http://www.mta.ca/~cat-dist/ ]


^ permalink raw reply	[flat|nested] 23+ messages in thread

end of thread, other threads:[~2009-12-30 21:00 UTC | newest]

Thread overview: 23+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-12-23  1:38 additions Fred E.J. Linton
  -- strict thread matches above, loose matches on Subject: below --
2009-12-22  1:43 additions Fred E.J. Linton
2009-12-17 23:30 A well kept secret? peasthope
2009-12-18  4:09 ` John Baez
2009-12-20 17:50   ` Joyal, André
     [not found]     ` <B3C24EA955FF0C4EA14658997CD3E25E2159B6AA@CAHIER.gst.uqam.ca>
2009-12-21  8:43       ` additions Joyal, André
2009-12-21 14:16         ` additions Bob Coecke
2009-12-22  2:24           ` additions Joyal, André
2009-12-23 20:51             ` additions Thorsten Altenkirch
2009-12-24 23:55             ` additions Dusko Pavlovic
2009-12-26  2:14             ` additions Peter Selinger
2009-12-22  0:39         ` additions Mike Stay
2009-12-23 11:19           ` additions Steve Vickers
2009-12-23 18:06             ` additions Mike Stay
2009-12-24 13:12               ` additions Carsten Führmann
2009-12-24 19:23               ` additions Dusko Pavlovic
2009-12-23 19:06             ` additions Thorsten Altenkirch
2009-12-21 19:20   ` additions Michael Barr
2009-12-22 12:21 ` additions Mark Weber
2009-12-23  0:05   ` additions Scott Morrison
2009-12-23 14:13     ` additions Mark Weber
     [not found] ` <4B3368C1.3000800@bath.ac.uk>
2009-12-24 16:25   ` additions Mike Stay
2009-12-26  0:03     ` additions Toby Bartels
     [not found]   ` <7f854b310912240825s39f195b2x2db16cc8f3a5cde7@mail.gmail.com>
2009-12-25  8:18     ` additions Carsten Führmann
     [not found] ` <4B347567.9070603@bath.ac.uk>
2009-12-29 23:17   ` additions Mike Stay
2009-12-30 21:00     ` additions Greg Meredith

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).