On Thu, Oct 29, 2009 at 09:57:09PM +0100, Florent hivert wrote:
> [...]
> > For this reason, I don't think CategoryWithBasis (or more
> > generally CategoryWith[Free]Generators) is a natural
> > category -- unless the generators are structures intended
> > to be preserved, as is the case with a category of pointed
> > sets.
> 
> As Nicolas already explained, FreeModuleWithBasis (and all their friend) is
> *not* an (abstract) category in the mathematical sense of the term. It is the
> category FreeModule + a little assumption on how the object of the category
> are implemented (The object are stored as expanded on a particular
> basis). Sorry to use this kind of argument but we spend two year designing
> this stuff in MuPAD and six more using it in a *very* large scale. I'm more
> than convinced that this is a good design choice...
> 
> Here we are not just doing mathematics. We are speaking implementation and
> generic algorithms. It is not because you know that RR is a free QQ-module
> that you know an algorithm to compute the QQ-rank of a bunch of real (think
> about [sqrt(i) for i in range(100)]... However if you give me a basis and a
> way to expand any real on this basis, I can implement easily gaussian
> elimination...
> 
> The goal of the category theory is to provide generic reasoning and
> constructions. Here we have to be a little more concrete, because we want to
> provide generic implementations.

Most of this discussion boils down to a confusion about what
categories are/should be in Sage.

IMHO: they are a design pattern, supported by a programming
construct. The main purpose is of course to model mathematical
categories. However, accumulated experience (ours, on top of all that
of the MuPAD and Axiom developers) tells us that, for practical
purposes, it is useful, meaningful, and safe to enlarge a bit the
framework. Namely to accept some categories which do not quite model
mathematical categories, but still provide generic code and
mathematical information about parents sharing common properties.
Note that Axiom pushed this much further, with use cases which are
much closer from that of abstract classes (see e.g.
http://www.axiom-developer.org/axiom-website/dotabb.html).

The name "categories" might be a misnomer, but there is a long history
of using it for that purpose, so it's better to stick with it.

Of course, the documentation, and in particular the primer should be
very precise about this. Suggestions and patches welcome!

Cheers,
                                Nicolas
--
Nicolas M. ThiƩry "Isil" <nthi...@users.sf.net>
http://Nicolas.Thiery.name/

--~--~---------~--~----~------------~-------~--~----~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an email to 
sage-devel-unsubscr...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/sage-devel
URL: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---

Reply via email to