#19416: Implement some generic category methods
-------------------------------------+-------------------------------------
       Reporter:  tscrim             |        Owner:  tscrim
           Type:  enhancement        |       Status:  needs_review
       Priority:  major              |    Milestone:  sage-6.10
      Component:  categories         |   Resolution:
       Keywords:                     |    Merged in:
        Authors:  Travis Scrimshaw   |    Reviewers:
Report Upstream:  N/A                |  Work issues:
         Branch:                     |       Commit:
  public/categories/generic_methods-19416|  
ff914dc988541148b4f10a3434dd688fc5ff7e75
   Dependencies:                     |     Stopgaps:
-------------------------------------+-------------------------------------

Comment (by tscrim):

 Replying to [comment:2 jhpalmieri]:
 > I would prefer if the docstring for `is_commutative` said "Return
 ''whether'' self is a commutative algebra" (or "Return whether this
 algebra is a commutative algebra").

 Done.

 > Is it worth saving any time by removing `self.one()` from the basis
 before doing the iteration? With the following change:
 > ...
 > it appears to be faster to check commutativity for
 `SymmetricGroupAlgebra(5, QQ)`. (I removed the `@cached_method` line
 before testing.) It's even a little faster for commutative algebras: the
 time spent removing the element from the list is made up by the time saved
 by not having as many iterations.

 The issue is that not all algebras in Sage have `one` as a basis element,
 so for those algebras, by adding this extra `remove` check, it might be
 longer. However, since the vast majority of algebras in Sage do have `one`
 as a basis element, and probably it appears early on, this should be
 faster and I think it is worthwhile to have it.

--
Ticket URL: <http://trac.sagemath.org/ticket/19416#comment:4>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica, 
and MATLAB

-- 
You received this message because you are subscribed to the Google Groups 
"sage-trac" 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 http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.

Reply via email to