Opened 4 years ago

Closed 7 months ago

#22979 closed defect (duplicate)

The function show() duplicates some edges when using loops and edge_colors in an undirected graph

Reported by: boussica Owned by: iebousbaa
Priority: minor Milestone: sage-duplicate/invalid/wontfix
Component: graph theory Keywords: graph, edge_colors, show, multiedges, loop, edge, sagedays89
Cc: Merged in:
Authors: Adrien Boussicault Reviewers: David Coudert
Report Upstream: N/A Work issues:
Branch: u/iebousbaa/the_function_show___duplicates_some_edges_when_using_loops_and_edge_colors_in_an_undirected_graph (Commits, GitHub, GitLab) Commit: aff61d016156e16b0d28a6c27243492a1cba8e47
Dependencies: Stopgaps:

Status badges

Description

When we colorize the edges of an undirected graph containing a loop, the function show() draws some extra edges. For example, the following code corresponds to the situation :

E=[(1,1),(1,2)]
g1 = Graph( E, loops=True, multiedges=False )
g1.show()
g1.show( edge_colors={"blue":[(2,1)]} )

If no loop is present, the code works correctly :

E=[(1,2)]
g1 = Graph( E, loops=True, multiedges=False )
g1.show()
g1.show( edge_colors={"blue":[(2,1)]} )

Now, if we replace (2,1) by (1,2), all the codes work. We think that all our examples should work when using (2,1). Indeed, usually, inside an undirected graph, we can use (1,2) or (2,1) for an edge {1,2}.

Change History (13)

comment:1 Changed 4 years ago by boussica

  • Owner changed from (none) to boussica

comment:2 Changed 4 years ago by mabdel

  • Owner changed from boussica to mabdel

comment:3 Changed 4 years ago by iebousbaa

  • Branch set to u/iebousbaa/duplicate_edge_bug

comment:4 Changed 4 years ago by iebousbaa

  • Commit set to 83149d13cebabe2d3f8eb9648c6939eb219c1726
  • Owner changed from mabdel to iebousbaa

New commits:

88bacdeFirst implementation of BDiagrams
8e9cc62test
5214630Cleaning + sub-bdiagrams + coproduct
45289d8Coproduit debug ... and others ...
ac34a66trac 20014 relative import is now needed
9eac794Correct a bug in the product and add unit test
83149d1Trac #22979: Correction of edges duplication in show()

comment:5 Changed 4 years ago by chapoton

The branch contains material about Bdiagrams that has nothing to do with this ticket.

comment:6 Changed 4 years ago by chapoton

and who is iebousbaa ? your login was boussica

comment:7 Changed 4 years ago by iebousbaa

Dear Mr Chapoton,

We found the bug during the Sage days organized in Algeria. Mr Adrien Boussicault reported the bug except that we could not commit the correction on a branch using the university network. I erroneously pushed the correction on a new branch created locally from my branch # 20014. I'm still looking in the documentation the way to fix it. I'm sorry about that.

Imad Eddine Bousbaa

Last edited 4 years ago by iebousbaa (previous) (diff)

comment:8 Changed 4 years ago by iebousbaa

  • Branch u/iebousbaa/duplicate_edge_bug deleted
  • Commit 83149d13cebabe2d3f8eb9648c6939eb219c1726 deleted

comment:9 Changed 4 years ago by iebousbaa

  • Branch set to u/iebousbaa/the_function_show___duplicates_some_edges_when_using_loops_and_edge_colors_in_an_undirected_graph

comment:10 Changed 8 months ago by dcoudert

  • Commit set to aff61d016156e16b0d28a6c27243492a1cba8e47
  • Component changed from graphics to graph theory
  • Milestone changed from sage-8.0 to sage-duplicate/invalid/wontfix
  • Status changed from new to needs_review

This issue has been fixed in #24051. So I propose to close this ticket.


New commits:

aff61d0Trac #22979: Correction of duplicated edges in show()

comment:11 Changed 8 months ago by dcoudert

  • Status changed from needs_review to positive_review

This issue has been fixed in #24051. So I propose to close this ticket.

comment:12 Changed 7 months ago by dcoudert

  • Reviewers set to David Coudert

forgot to add reviewer name.

comment:13 Changed 7 months ago by chapoton

  • Resolution set to duplicate
  • Status changed from positive_review to closed
Note: See TracTickets for help on using tickets.