#10919: Addition of function ``is_uniform(k)`` for WordMorphism class
---------------------------------------+------------------------------------
   Reporter:  abmasse                  |       Owner:  abmasse     
       Type:  enhancement              |      Status:  needs_review
   Priority:  major                    |   Milestone:  sage-4.7    
  Component:  combinatorics            |    Keywords:              
     Author:  Alexandre Blondin Massé  |    Upstream:  N/A         
   Reviewer:                           |      Merged:              
Work_issues:                           |  
---------------------------------------+------------------------------------

Comment(by slabbe):

 With {{{trac_10919-uniform_morphism-abm.patch}}} :

 {{{
 sage: m = WordMorphism(dict(((i,[i]*i) for i in range(30))))
 sage: %timeit m.is_uniform()
 625 loops, best of 3: 25.5 µs per loop
 sage: %timeit m.is_uniform(4)
 625 loops, best of 3: 40.6 µs per loop
 }}}

 With {{{trac_10919-uniform_morphism-abm.patch}}} and {{{trac_10919_review-
 sl.patch}}}:

 {{{
 sage: m = WordMorphism(dict(((i,[i]*i) for i in range(30))))
 sage: %timeit m.is_uniform()
 625 loops, best of 3: 18 µs per loop
 sage: %timeit m.is_uniform(4)
 625 loops, best of 3: 5.72 µs per loop
 }}}

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/10919#comment:2>
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 post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/sage-trac?hl=en.

Reply via email to