Number: 160
Title: planar graph drawn with overlapping edges
Submitter: Lilian
Date: Thu Jun 20 10:18:05 2002
Subsys: Dot
Version: 1.8.5
System: x86-Linux-
Severity: cosmetic
Problem:
Hello,

The following graph is obviously planar, but dot insists on placing the input and the output on the same side of the channel, which makes some edges overlap. Is there any way to avoid this behavior ?

Thanks, Lilian.
Input:

digraph anything {
size="7,10"
edge [ decorate=1 fontsize=8 fontname=Helvetica labelfontname=Helvetica labelfontsize=8 ]
node [ fontsize=12 fontname="Helvetica-Bold" shape=ellipse ]
subgraph ports {
port0 [label="activate" style=bold shape=box ]
port1 [label="i" style=bold shape=box ]
port2 [label="o" style=bold shape=box ]
}
subgraph cluster_components {
 label="buffer_n"
comp0 [label="."]
comp1 [label="."]
comp2 [label="W."]
comp3 [label="buffer"]
comp4 [label="buffer"]
comp5 [label="."]
comp6 [label="buffer"]
comp7 [label="buffer"]
}
port0 -> comp2 [ label="C1: @14:20" arrowhead=odot arrowtail=dot dir=forward headlabel="0" taillabel="" ]
port1 -> comp3 [ label="C2: i" arrowhead=normal arrowtail=odot dir=forward headlabel="" taillabel="1" ]
comp4 -> port2 [ label="C3: o" arrowhead=normal arrowtail=dot dir=forward headlabel="" taillabel="2" ]
comp7 -> comp0 [ label="C4: c[3]" arrowhead=normal arrowtail=dot dir=forward headlabel="1" taillabel="2" ]
comp7 -> comp5 [ label="C5: c[2]" arrowhead=odot arrowtail=normal dir=back headlabel="0" taillabel="1" ]
comp2 -> comp7 [ label="C6: @17:12" arrowhead=odot arrowtail=dot dir=forward headlabel="0" taillabel="4" ]
comp6 -> comp5 [ label="C7: c[2]" arrowhead=normal arrowtail=dot dir=forward headlabel="1" taillabel="2" ]
comp6 -> comp1 [ label="C8: c[1]" arrowhead=odot arrowtail=normal dir=back headlabel="0" taillabel="1" ]
comp2 -> comp6 [ label="C9: @17:12" arrowhead=odot arrowtail=dot dir=forward headlabel="0" taillabel="3" ]
comp4 -> comp0 [ label="C10: c[3]" arrowhead=odot arrowtail=normal dir=back headlabel="0" taillabel="1" ]
comp2 -> comp4 [ label="C11: @15:10" arrowhead=odot arrowtail=dot dir=forward headlabel="0" taillabel="2" ]
comp3 -> comp1 [ label="C12: c[1]" arrowhead=normal arrowtail=dot dir=forward headlabel="1" taillabel="2" ]
comp2 -> comp3 [ label="C13: @14:10" arrowhead=odot arrowtail=dot dir=forward headlabel="0" taillabel="1" ]
}
Comments:
[erg] dot does not guarantee planarity. In fact, as with this graph, the aesthetics work against it. The user can make the graph planar by putting node o into the cluster and forcing the bottom nodes down a rank.
Owner: *
Status: Request