CPSC 536: BAR VISIBILITY GRAPHS 1. Bar visibility graphs Bar

CPSC 536: BAR VISIBILITY GRAPHS
SCRIBE: KRISTINA NELSON
1. Bar visibility graphs
Bar visibility graphs were introduced as a simplified version of the rectangle visibility
graph problem from circuit design. See Steve Wismath’s 1985 paper[1] for an introduction.
Essentially, a bar visibility representation is a set of parallel, non-intersecting segments
(bars) and the visibility relation that two lines. v, w, can ‘see’ one another if it is possible
to draw a (non-degenerate) rectangle with opposite faces touching v and w and no other
bar intersecting the rectangle. A graph is then said to be a bar visibility graph if it has
some bar visibility representation (with a one to one map taking vertices to bars, and
edges to lines of sight). Bar visibility graphs use a single direction line-of-sight instead
of the two dimensions used in rectangular visibility graphs. As a result the problem and
characterization of bar visibility graphs is better understood.
Above we have defined a strong visibility graph (and this is the definition assumed from
now on). Weakening our segments to intervals (allowing, for example, half open intervals)
gives us the -visibility graphs; while keeping segments but allowing some lines of sight to
be extraneous - that is correspond to no edge of the underlying graph - gives us a weak
visibility graph. For a more in-depth definition see Tamassia and Tallis (1986)[2]. Finally,
a k-bar visibility graph generalizes the concept, allowing line-of-sight visibility through k
bars. The characterization of such graphs is unknown however.
Figure 1. A crudely drawn bar visibility graph (right) and representation (left).
It is relatively easy to go from a bar representation to the corresponding graph (with a line
sweep), however the reverse direction is less obvious. We seek to answer the following:
1
2
SCRIBE: KRISTINA NELSON
(1) Can we tell if a given graph has a bar visibility representation?
(2) And if so, can we construct the bar representation?
Claim 1: Every bar visibility graph is planar.
A formal proof is omitted, however this can be intuitively seen by drawing lines of sight
between the bars/vertices of the graph and then observing that when contracting the bars
to points no edges will need to cross.
The reverse, however, does not hold in general, see figure 2.
Figure 2. the smallest, planar and yet not bar representable graph.
Definition: given G = (V, E) with |V | = n, an st-numbering of G is a bijection
l : v → {1, 2, ..., n} with l(s) = 1, l(t) = n and for every other vertex v ∈ V − {s, t},
there exists (u, v) and (v, w) in E s.t. l(u) < l(v) < l(w).
Definition: an st-orientation of G is then simply a directing of the edges such that they
all run from low to high with respect to some st-numbering. Alternatively an st-ordering
could be defined as a directed version of G such that every vertex has at least one incoming
and outgoing edge, except for s and t (s having only outgoing and t only incoming).
Claim 2: If G is planar and has a st-numbering for some (s, t) ∈ E then G is a bar
visibility graph.
‘Proof’ of claim 2: The reader is directed to Steve Wismath’s paper[1] for a complete
proof, but we will outline the general line of attack here. Let l be an st-numbering of G
and let Γ be a planar embedding of G with s, t on an exterior face. We give a set of rules
to draw a bar visibility representation of G:
We determine the required widths of each bar progressively, from s to t. First fix the
width of the start node: width(s) = 1. Then, assuming that the width(v) has been defined
for all v ‘back-nighbours’ of u, the width of a directed (v, u) edge is:
CPSC 536: BAR VISIBILITY GRAPHS
( width(v)
(1)
width(v, u) =
df (v)
0,
3
, if (v, u) ∈ E.
otherwise.
Where df (v) is the forward or out degree of node v.
P
This gives us sufficient information to fix the width of u itself: width(u) = v width(v, u).
th
With this construction we allocate df1(v) of v’s width to each one of its forward neighbours. Summing over these pieces for each backward neighbour as we do then gives us
sufficient width for the next vertex.
The bars are then drawn to their assigned widths, and at height equal to their st-number.
It remains to be shown that these bars may actually be aligned to overlap as desired, and
for this we point the reader to Wismath’s paper.
Theorem: G (a connected graph) is a bar visibility iff G has a planar embedding with all
cut vertices on the outer face, see figure 2 for an example of this failing.
Figure 3. a planar graph with cut vertices only on the outer face.
We will use the following fact: G has an st-numbering for some (s, t) ∈ E if and only if G
is biconnected.
Proof of Theorem:
We begin with the harder direction. Assume we have a bar representation for G. As mentioned above, we can construct a planar embedding by contracting the bars to points and
bending the visibility lines of sign to be edges (as was done in figure 1).
4
SCRIBE: KRISTINA NELSON
Suppose a cut vertex c is not on the outer face. Let F be an internal face that contains
c and encloses components of G − c. By the construction of our planar embedding from
bars some component connected by c must either be above or below it (possibly both) wlog we assume above. Let v 6= c be the vertex of these enclosed components with largest
y-value (farthest from c). But v is in a cycle, implying it must have some ceiling over it
(a bar) which in turn implies there exists some edge from v to this bar and so c was not a
cut vertex after all.
Figure 4. vertices c, v and face F on an example G.
Now for the other direction: we have a planar embedding with all cut vertices on the
outer face. Let {Bi }ni=1 be the blocks of G with only one cut vertex ci (the leaves). Pick
out a set of n representative vertices: one vi from each Bi such that vi 6= ci , and vi on the
outer face of G. Add a vertex x and connect x to all vi in G, this forms G0 . Note that G0
is then biconnected.
Being biconnected then implies G0 has a st-numbering (with s = x, t = v1 ), which in
turn implies it has a bar representation. To get a bar representation for G from that of G0 ,
we only need to drop the bar corresponding to x.
CPSC 536: BAR VISIBILITY GRAPHS
5
Figure 5. A planar embedding with all cut vertices on the outer face; the
Bi ’s denoting ‘leaf’ components.
2. Topological Numbering
Given a directed graph G, a topological numbering is one which obeys the direction of
each edge, that is for every edge (u, v) ∈ E(G) we have u preceding v in our ordering.
It turns out we can also generate bar representations of graphs using topological numberings. Let G be directed, and with some source node s. Label each vertex with the
length of the longest path from s to it. We now have a topological ordering on G (and an
st-ordering, if we add an s − t edge).
Assign the labels ‘left’ and ‘right’ to the two sides of the outer face (and from here we
consider them two distinct faces). Then take a dual of G (in particular the dual where for
each edge in the original graph there exists an edge crossing it in the dual - this may lead
to multi-edges). Direct all edges in the dual so that they run from left to right across their
dual edge in the original graph (left to right when the original edge is directed upwards).
See figure 6 for an example of these steps. The result is a pair of graphs, which combined
can define the heights and widths of the bars and visibility lines (‘see’) in a representation
for our original graph:
bar(v) = (x(lef t(v)), x(right(v) − 1)) at y = y(v)
(where lef t(v) = the number of faces to the left of v).
see(u, v) = (y(u), y(v)) at x = x(lef t(u, v)).
6
SCRIBE: KRISTINA NELSON
Figure 6. Construction of the topological numbering and dual.
(a) graph G
(b) st-orientation (directed G)
(c) topological numbering
(d) dual
(e) dual numbered
CPSC 536: BAR VISIBILITY GRAPHS
Figure 7
(a) bar representation of G
(b) bars extended to avoid strong visibility lines
7
8
SCRIBE: KRISTINA NELSON
Figure 8. Further extending bars so that visibility occurs only in the case
of edges.
(a)
(b)
CPSC 536: BAR VISIBILITY GRAPHS
9
References
[1] Stephen K. Wismath, Characterizing Bar Line-of-Sight Graphs. University of Lethbridge, 1985.
[2] Roberto Tamassia, Ioannis G. Tollis, A Unified Approach to Visibility Representations of Planar Graphs.
University of Illinois, 1986.