#18137: Centrality betweenness in Sage
-------------------------+-------------------------------------------------
       Reporter:         |        Owner:
  ncohen                 |       Status:  needs_review
           Type:         |    Milestone:  sage-6.6
  enhancement            |   Resolution:
       Priority:  major  |    Merged in:
      Component:  graph  |    Reviewers:
  theory                 |  Work issues:
       Keywords:         |       Commit:
        Authors:         |  0402abffb7656e123ce64d38e6a8cb8392eecf89
  Nathann Cohen          |     Stopgaps:
Report Upstream:  N/A    |
         Branch:         |
  u/ncohen/18137         |
   Dependencies:         |
-------------------------+-------------------------------------------------

Comment (by dcoudert):

 Hello,

 I have only small remarks:
 - Wouldn't it be slightly faster to use arrays of bint rather than bitsets
 ? It would use more memory, but since you want to be fast, any saving is
 important.
 - You could add a doctest to compare the result of your implementation
 with networkx
 - You could pre-compute the `((n-1)*(n-2))`, although its minor
 improvement.
 - You could add `cdef double x`
 - Variables `k` and `d` are not used.
 - You wrote `from centrality import centrality_betweenness`. Shouldn't it
 be `from sage.graphs.centrality import centrality_betweenness` ?

--
Ticket URL: <http://trac.sagemath.org/ticket/18137#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 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