#10356: bipartite graph doesn't label a vertex when showing it
----------------------------+-----------------------------------------------
Reporter: jason | Owner: jason, ncohen, rlm
Type: defect | Status: new
Priority: major | Milestone: sage-4.6.2
Component: graph theory | Keywords:
Author: | Upstream: N/A
Reviewer: | Merged:
Work_issues: |
----------------------------+-----------------------------------------------
Comment(by gbe):
The problem seems to be that the reduced adjacency matrix code does the
following:
{{{
else:
for ii in range(ncols):
for jj in range(nrows):
if arg1[jj][ii] != 0:
self.add_edge((ii, jj + ncols))
}}}
This is fine if the graph is has no isolated vertices. However, any graphs
with isolated vertices will cause the similar problems:
{{{
sage: n = matrix(4,4,[1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0])
[1 1 1 1]
[0 0 0 0]
[0 0 0 0]
[0 0 0 0]
sage: g = BipartiteGraph(n)
sage: g
Bipartite graph on 5 vertices
sage: g.left, g.right
(set([0, 1, 2, 3]), set([4, 5, 6, 7]))
}}}
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/10356#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.