Hi Travis,

On 2016-08-05, Travis Scrimshaw <[email protected]> wrote:
> On Friday, August 5, 2016 at 10:11:13 AM UTC-5, Andrew wrote:
> It is not true that CFM is implemented in Python. The addition and scalar 
> coefficient action are done in cython in dict_addition. See 
> https://trac.sagemath.org/ticket/20680, and Nicolas and I also looked into 
> Cythonizing CFM elements (I have a branch with some progress on this).

As I said, I am a bit biased, and maybe I got a wrong impression from
the fact that sage.combinat.free_module is a python module.

> There are also likely improvements to be made to the current framework for 
> the algebras (i.e., the *_on_basis methods), but it makes a very simple way 
> to do implementations

True. But when I last looked at CFM (some time ago), it wasn't easy to
get a good performance, and I am glad that you and Nicolas are working
on cythonization.

> and removes a lot of redundancy.

Or *introduces* redundancy, since people may feel tempted to reimplement
stuff (without doubt in a cleaner way) that already is available.

One example that I recently met is not about CFM, but may illustrate what
I mean: There is a fast nasty boilerplate implementation of binary trees
at sage.misc.binary_tree, and IN ADDITION to that a hight level
implementation at sage.combinat.binary_tree written in Python and relying
on ClonableIntArray, which is fast but likely isn't a data structure
specially dedicated to binary trees.

Why should one rewrite everything ("reinvent the wheel") on top of
non-specific data structures rather than using the existing boilerplate
implementation as a backend of nicer code ("build the car")?

Cheers,
Simon

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.

Reply via email to