#12874: Recognition of Comparability graphs and Permutation graphs
----------------------------------+-----------------------------------------
       Reporter:  ncohen          |         Owner:  tbd          
           Type:  enhancement     |        Status:  needs_review 
       Priority:  major           |     Milestone:  sage-5.1     
      Component:  graph theory    |    Resolution:               
       Keywords:                  |   Work issues:               
Report Upstream:  N/A             |     Reviewers:  David Coudert
        Authors:  Nathann Cohen   |     Merged in:               
   Dependencies:  #12816, #12872  |      Stopgaps:               
----------------------------------+-----------------------------------------

Comment (by dcoudert):

 In comparability.pyx:
  * "greedy_is_comparability": instead of using both variables cu and cv,
 you could use index j in second loop and then call directly h.add_edge(
 (u,i), (v,j) ). OK, your choice.
  * "greedy_is_comparability_with_certificate": it would be nicer to use
 "gg = g.copy()" rather than "g = g.copy()". This is correct but...
  * is_transitive": something is missing in the for loops since you always
 test the first n values of the distances array. May be a c_distances =
 c_distances+n?

 In graph.py:
  * in the example with RandomGNP graph, I suggest to add a
 set_random_seed(some value you like) before. Although the probability for
 having a bipartite graph is extremely low, it is not null ;)
  * "for w in self.neighbors(v)" -> "for w in self.neighbor_iterator(v)" ?

 Last, you could remove empty lines after """.

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/12874#comment:13>
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