Journal of Graph Algorithms and Applications Star-shaped and L-shaped Orthogonal Drawings

An orthogonal drawing of a plane graph G is a planar drawing of G, denoted by D(G), such that each vertex of G is drawn as a point on the plane, and each edge of G is drawn as a sequence of horizontal and vertical line segments with no crossings. An orthogonal polygon P is called orthogonally convex if the intersection of any horizontal or vertical line L and P is either a single line segment or empty. An orthogonal drawing D(G) is called orthogonally convex if all of its internal faces are orthogonally convex polygons. An orthogonal polygon P is called a star-shaped polygon if there is a point p ∈ P such that the entire P is visible from p. An orthogonal drawing D(G) is called a star-shaped orthogonal drawing (SSOD) if all of its internal faces are star-shaped polygons. Every SSOD is an orthogonally convex drawing, but the reverse is not true. SSOD is visually more appealing than orthogonally convex drawings. Recently, Chang et al. gave a necessary and sufficient condition for a plane graph to have an orthogonally convex drawing. In this paper, we show that if G satisfies the same condition given by Chang et al., it not only has an orthogonally convex drawing, but also a SSOD, which can be constructed in linear time. An orthogonal drawing D(G) is called an L-shaped drawing if each face of D(G) is an L-shaped polygon. In this paper we also show that an L-shaped orthogonal drawing can be constructed in O(n) time. The same algorithmic technique is used for solving both problems. It is based on regular edge labeling and is quite different from the methods used in previous results.


Introduction
Among many graph drawing styles, orthogonal drawing has attracted much attention due to its various applications in circuit schematics, relationship diagrams, data flow diagrams etc. [3].An orthogonal drawing of a plane graph G is a planar drawing, denoted by D(G), of G such that each vertex of G is drawn as a point on the plane, and each edge is drawn as a sequence of horizontal and vertical line segments with no crossings.A bend is a point where an edge changes its direction.(Figure 1 (b) shows an orthogonal drawing of the graph in Figure 1 (a).The point p is a bend.) Rahman et al. [12] gave a necessary and sufficient condition for a plane graph G of maximum degree 3 to have an orthogonal drawing without bends.A linear-time algorithm to find such a drawing was also obtained in [12].In the drawings constructed in [12], the faces of D(G) can be of complicated shapes.An orthogonal polygon P is orthogonally convex if, for any horizontal or vertical line L, the intersection of L and P is either empty or a single line segment.(Figure 1 (c) shows an orthogonally convex polygon.The face marked by F in Figure 1 (b) is not orthogonally convex.)An orthogonal drawing D(G) is orthogonally convex if all faces of D(G) are orthogonally convex polygons.The orthogonally convex drawings are more visually appealing than arbitrary orthogonal drawings.
Chang et al. [2] gave a necessary and sufficient condition (which strengthens the conditions in [12]) for a plane graph G of maximum degree 3 to have an orthogonal convex drawing without bends.A linear-time algorithm to find such a drawing was also obtained in [2].An orthogonal polygon P is called star-shaped if there exists a point p in P such that for all other point q in P , the line segment (p, q) is entirely contained in P .(In other words, the entire polygon P is visible from p. See Figure 1 (d).)It is easy to see that any star-shaped orthogonal polygon is always orthogonally convex.But the reverse is not true.An orthogonal drawing D(G) is called a star-shaped orthogonal drawing (SSOD) if every inner face of D(G) is a star-shaped orthogonal polygon.The star-shaped orthogonal drawings are more visually appealing than orthogonally convex drawings (see Figure 1 (c) and (d)).In this paper, we show that if G satisfies the same conditions given in [2], then G has a SSOD without bends.In addition, such a drawing can be constructed in linear time.
To the best knowledge of the authors, SSOD is a new drawing style.Although star-shaped drawings have been studied before [7,8], the polygons in their drawings are required to be star-shaped but not orthogonal.In [11,4], the problem of covering orthogonal polygons by star-shaped orthogonal polygons is studied.
An orthogonal polygon P is called L-shaped if P has exactly five convex corners and one concave corner (see Figure 1 (e)).An orthogonal drawing D(G) is called L-shaped if every face of D(G) is either a rectangle or an L-shaped polygon.In [13], an algorithm for testing if G has an L-shaped orthogonal drawing was given.The testing is done by checking if an axillary graph has a perfect matching and takes O(n 1.5 ) time.If G passes the test, an L-shaped drawing of G can be constructed in O(n 2 ) time [13].In [14], it was shown that the construction part can be done in linear time.In this paper, we show that our method can also be used to construct an L-shaped orthogonal drawing of G in linear time.Our algorithm is simpler and quite different from the algorithm in [14].
The paper is organized as follows.In Section 2, we present the definitions and preliminary results.Section 3 describes a special rectangular dual needed by our algorithm.In Section 4, we present our SSOD algorithm.In Section 5, we discuss how to construct an L-shaped orthogonal drawing.Section 6 concludes the paper.

Preliminaries
Most definitions in this paper are standard.Let G = (V, E) be a graph with n vertices.Let N (v) denote the set of the neighbors of a vertex v.The degree of a vertex v is the number of neighbors of v in G.A vertex of degree 2 (respectively 3) is called a 2-vertex (respectively 3-vertex).The maximum degree of G is denoted by ∆ A planar graph is a graph G that can be drawn on the plane so that the vertices are drawn at points on the plane and the edges are drawn as curves connecting their end vertices without crossings.Such a drawing is called a plane embedding of G.A plane graph is a planar graph with a fixed plane embedding.For the problems considered in this paper, the case that G is only connected can be easily reduced to the biconnected case [12,2].Thus, as in [12,2], G always denotes a biconnected plane 3-graph in the rest of this paper.
A fixed embedding of G divides the plane into a set of connected regions called faces.The unbounded face of G is called the exterior face.The bounded faces are called the interior faces.The contour of a face f is the cycle formed by the vertices and the edges on the boundary of f .The contour of the exterior face of G is denoted by  , respectively) interior angle is called a convex (concave, respectively) corner.For an orthogonal drawing D(G) without bends, any concave corner a of D(G) must be a vertex of G, and since there are only two line segments incident to a, the degree of this vertex must be 2.
The algorithm Bi-Orthogonal-Draw in [12] finds an orthogonal drawing of the input graph G.The first step of algorithm Bi-Orthogonal-Draw arbitrarily selects four 2-vertices on the exterior face C o (G) and draw C o (G) as a rectangle with the selected four vertices as its four corners.The drawing algorithm in [2] is a modified version of the algorithm Bi-Orthogonal-Draw.It also draws the exterior face C o (G) as a rectangle with four selected vertices as the four corners of the exterior rectangle [2].We will following the same convention as in [12,2]: the input to our problem is a plane graph H with four specified 2-vertices a, b, c, d on C o (H) in clockwise order.Our goal is to produce an orthogonal drawing D(H) of H such that C o (H) is drawn as a rectangle with a, b, c, d as the northwest, northeast, southeast and southwest corner of D(H), respectively.
To further simplify the presentation, we construct a new graph G from H as follows (see Figure 2  Clearly, H has a no-bend orthogonal drawing with a, b, c, d as the four corners if and only if G has a no-bend orthogonal drawing with a , b , c , d as the four corners (see Figure 2 (b)).Note that G satisfies the following properties:  In the rest of the paper, without loss of generality, we always assume G satisfies Property 1.
Let C be a cycle of G.A leg of C is an edge e that is in the exterior of C and has exactly one vertex on C. The vertex of e that is on C is called a leg vertex of C. A k-legged cycle is a cycle C with exactly k legs.The k leg vertices divide C into k sub-paths.Each sub-path is called a contour path of C.
Theorem 1 [12] Let G be a plane graph that satisfies the conditions as in Property 1. Then G has an orthogonal drawing without bends if and only if the following two conditions hold: 1. Every 3-legged cycle C has at least one 2-vertex.Theorem 2 [2] Let G be a plane graph that satisfies the conditions in Property 1. Then G has an orthogonally convex drawing without bends if and only if the following two conditions hold: 1. Every 3-legged cycle C has at least one 2-vertex.
2. Every 2-legged cycle C has at least two 2-vertices, at least one on each of its two contour paths.Hence there exists no orthogonally convex drawing: In any drawing, the face outside of C (marked by F ) cannot be orthogonally convex.In Section 4, we will show that any graph satisfying the conditions in Theorem 2 has a SSOD without bends.
Let G * = (V * , E * ) be the dual graph of G. To avoid confusion, the members of V * are called nodes.Each node in V * corresponds to an interior face f of G, and two nodes in V * are adjacent to each other in G * if and only if their corresponding faces in G share an edge as common boundary.(Note that there is no node in V * corresponding to the exterior face of G.This is is slightly different from the normal definition of the dual graph.)Definition 1 Let G * be an internally triangulated plane graph whose exterior face has four nodes.A rectangular dual of G * is a rectangle R divided into smaller rectangles such that the following hold: 1.No four smaller rectangles meet at the same point.G is called a proper triangular plane (PTP) graph if it satisfies the two conditions in Theorem 3. Our algorithm heavily depends on the following concept: directed edges such that the following conditions hold: 1.For each interior node v, the edges incident to v appear in clockwise order around v as follows: a set of edges in T 1 leaving v; a set of edges in T 2 leaving v; a set of edges in T 1 entering v; a set of edges in T 2 entering v.
(All four sets are not empty.)Theorem 4 [5,6] Every PTP graph G * has an REL which can be constructed in linear time.From an REL of G * , a rectangular dual of G * can be constructed in linear time.

A Special Rectangular Dual
A PTP graph G * may have many different RELs.From the same REL of G * , we may obtain different rectangular duals.In this section, we describe a rectangular dual of G * with special properties, which is needed by our SSOD construction.First we outline the rectangular dual algorithm DUAL in [5].
Let G * be a PTP graph with an REL R = {T 1 , T 2 }.The SN subgraph G *

SN
is the directed subgraph of G * consisting of the edges in T 1 and the four exterior edges directed as Define the dual graph G SN of G * SN as follows.The vertex set of G SN is the set of the interior faces of G * SN plus two exterior faces f W and f E .For each directed edge e * in G * SN , the left face of e * , denoted by left(e * ), is the face in G * SN that is located to the left of e * when walking along e * .Similarly, the right face of e * , denoted by right(e * ), is the face in G * SN that is located to the right of e * when walking along e * .For each directed edge e * in G * SN , there is a corresponding edge e in G SN directed from the face left(e * ) to the face right(e * ).G SN is an acyclic directed graph with f W as the only source and f E as the only sink [5] and (2) if there is an edge from the vertex f to the vertex g in G SN , then F 1 (f ) < F 1 (g).(For example, a topological numbering of G SN is a consistent numbering.)(Figure 4 The algorithm DUAL in [5] assigns each node u in G * a rectangle with the left boundary x = l(u), the right boundary x = r(u), the bottom boundary y = b(u), and the top boundary y = t(u).It was shown in [5] these rectangles constitute a rectangular dual of G * .
The subgraphs G * SN and G * W E are completely defined by the given REL R = {T 1 , T 2 }.However, there may be many consistent numberings for G SN (and G W E .)Different numberings will result in different rectangular duals.In the following lemma, we show that G * has a rectangular dual with special properties.This special rectangular dual is important for our SSOD drawing and may have applications in solving other drawing problems.For a rectangular dual R of G * , let r u denote the rectangle in R corresponding to the node u.
Lemma 1 Any PTP graph G * has a rectangular dual R such that the following properties hold for any node u in G * .
1. Let v 1 → u be the first clockwise T 1 edge entering u and u → v 2 the first clockwise T 1 edge leaving u.Then there exists a vertical strip in R that intersects r v1 , r u , r v2 .
2. Let w 1 → u be the first clockwise T 2 edge entering u and u → w 2 the first clockwise T 2 edge leaving u.Then there exists a horizontal strip in R that intersects r w1 , r u , r w2 .
We use the right-most topological sort to calculate a consistent numbering F 1 of G SN which is defined as follows.
We run the topological sort algorithm on G SN starting from the (only) source vertex f W of G SN .Once a vertex u in G SN has been numbered, we number the outgoing neighbors of u in G SN .Among all neighbors of u, we always visit the right-most outgoing neighbor v 1 first.After all vertices that can be numbered from v 1 have been numbered, we continue to number the next rightmost outgoing neighbor of u, and so on.
).Let a be the number assigned to the left face of e * 1 and b be the number assigned to the right face of e * 2 .By the construction of DUAL algorithm in [5], the rectangle r u shares a boundary with and is located above the rectangle r v1 , and the rectangle r v2 shares a boundary with and is located above the rectangle r u .
Because F 1 is obtained by using the rightmost topological sort of G SN , we have a < b.This implies (4) l(v 1 ) ≤ a < b ≤ r(v 2 ).By (1) through (4), l(v 1 ), l(u), l(v 2 ) are all ≤ a and r(v 1 ), r(u), r(v 2 ) are all > a.Because all these quantities are integers, the vertical strip with the left vertical boundary line x = a and the right vertical boundary line x = a + 1 intersects the three rectangles r v1 , r u , r v2 .
So Statement 1 holds.Figure 4 (c) and (d) show two possible relative positions of r v1 , r u , r v2 .
Similarly, we can use the right-most topological sort to calculate a consistent numbering F 2 of G W E .By using the same argument, we can show Statement 2 holds.After we construct a SSOD D(H) of H, we can obtain a SSOD D(G) of G as follows: Consider any 2-vertex v that was contracted from G. Let u, w be the two neighbors of v in G.In the drawing D(H), the edge (u, w) is drawn as a line segment L. We simply draw v in the middle of L. After doing this for every contracted vertex v, we get a SSOD D(G) for G. Thus, without loss of generality, we assume G satisfies the conditions in Property 2 from now on.
Let G * be the dual graph of G, but without the node corresponding to the exterior face of G.So G * has exactly four nodes on its exterior face.Each 2-vertex of G corresponds to a pair of parallel edges in G * .We only keep one of them in G * .These edges in G * are called marked edges.
Note that every 3-legged cycle C in G corresponds to a separating triangle C * in G * , and every 2-legged cycle C in G corresponds to a separating 2-cycle C * in G * .A 3-legged cycle C is shown in Figure 5 (a).The edges in G are drawn as dashed lines, the edges in G * are drawn as solid lines.The nodes in G * are drawn as empty circles.The 2-vertex g in G corresponds to two parallel edges (w, x) in G * .We keep only one of them in G * and (w, x) is a marked edge.We first outline the main ideas of our algorithm.Basically, we want to construct a rectangular dual of G * which will be the "skeleton" of the drawing D(G).However, because G * has separating 2-cycles and 3-cycles, it is not a PTP graph and hence has no rectangular dual.We have to modify G * to get a PTP graph G * as follows.For each separating 2-cycle or 3-cycle C * in G * incident to a node x, we perform a node split operation on x (which will be defined later.)This operation "splits" x into two nodes and "destroys" C * .After all separating 2-cycles and 3-cycles in G * are destroyed, the resulting graph G * is a PTP graph.Each node x in G * either corresponds to a node in G * (if x is not split); or a set of nodes in G * (since there may be multiple separating cycles incident to x, we may have to split x multiple times.)We then find an REL R of G * and construct a rectangular dual D(G * ) of G * by Lemma 1. D(G * ) is a "skeleton" of a SSOD D(G) of G.Each face f of D(G) corresponds to a node x in G * , which either corresponds to a single rectangle in D(G * ) (if x is not split), or an orthogonal polygon F that is the union of several rectangles in D(G * ) (each rectangle corresponds to a split node of x.) Figure 5 (c) illustrates the drawing D(G) for the graph G in Figure 5 (a) by using this process.We split the node x into two nodes x 1 and x 2 in order to destroy the separating triangle C * = {u, v, x}.In Figure 5 (c), each rectangle corresponds to a node in G * .The union of the two rectangles marked by x 1 and x 2 corresponds to the node x.The drawing in Figure 5 (c) is an orthogonal drawing of the graph G in Figure 5 (a).Note the location of the 2-vertex g in D(G).
Since we want D(G) to be a SSOD of G, we must make sure each face F in D(G) is star-shaped.This is done by carefully constructing the REL R so that certain properties are satisfied (which are discussed later.)

Node Split Operation
In this subsection, we describe the details of our algorithm based on the ideas outlined above.Let G * 1 be the graph obtained from G * as follows: • For each maximal separating triangle C * in G * , delete all interior nodes of C * .
• For each maximal separating 2-cycle C * in G * , delete all interior nodes of C * , and replace the two edges of C * by a single edge.We call these edges the merged 2-cycle edges.
Clearly G * 1 is a PTP graph.By Theorem 4, G * 1 has an REL R 1 = {T 1 , T 2 }.We now need to add the deleted nodes back into G * 1 .We process the separating cycles of G * one by one.
First consider a separating triangle C * in G * .Let G * (C * ) denote the induced subgraph of G * consisting of the nodes on and in the interior of C * .Let G * 1 ∪ G * (C * ) be the graph obtained by adding the interior nodes of C * back into G * 1 .We want to construct an REL for G * 1 ∪ G * (C * ).However, G * 1 ∪ G * (C * ) is not a PTP graph because C * is a separating triangle.We must modify G * 1 ∪ G * (C * ) so that C * is not a separating triangle in it.Let C be the 3-legged cycle in G corresponding to C * .By Property 2, there is exactly one 2-vertex a in G on C. The vertex a corresponds to a marked edge e * a in G * .e * a must be incident to one of the three nodes of C * .Let x denote this node.We say the separating triangle C * is assigned to x.(In Figure 5 (a), the marked edge e * = (x, w) in G * corresponds to the 2-vertex g in G. e * is incident to the node x.So the separating triangle C * = {u, v, x} is assigned to x.) We perform the node split operation at x defined below: Definition 3 Let x be an interior node of G * with neighbors y 1 , ..., y p in clockwise order (see Figure 6.)The node split operation at x with respect to the two edges (x, y i ) and (x, y j ) (1 ≤ i < j ≤ p) is: 1. Delete x.Create two new nodes x 1 and x 2 .Add a new edge (x 1 , x 2 ). 2. For t = i + 1, ..., j − 1, replace the edge (x, y t ) by (x 1 , y t ).For t = j + 1, j + 2, ..., p, 1, ..., i − 1, replace the edge (x, y t ) by (x 2 , y t ).
Let e * 1 , e * 2 and e * 3 be the three edges of C * .Two of them, say e * 1 and e * 2 , are incident to x. Depending on the pattern of these two edges in R 1 , there are eight cases for node split operation at x (see Figure 7 (a) -( For example, consider the case south.We split x with respect to two edges: (z, x) is the marked edge in G * that is in the interior of C * ; and (x, y) is a T 1 edge in the exterior of C * leaving x (we will specify how to pick the edge (x, y) later.)In Figure 7  Note that when looking from outside of C * , the patterns of the involved edges are identical before and after the node split operation.After splitting  x into two nodes x 1 and x 2 , each of the two edges (z, x) and (x, y) is split into two edges.C * becomes a quadrangle with four exterior nodes x 1 , x 2 , u, v in clockwise order.We recursively construct an REL R(C * ) for G * (C * ) with x 1 , x 2 , u, v as the north, east, south and west node respectively.Now we put the nodes and the edges in the interior of the subgraph G * (C * ) back into G * 1 , together with the edge pattern specified in R(C * ).It is easy to see that after these operations, we get a valid REL of the graph G * 1 ∪ G * (C * ).The other cases are similar as shown in Figure 7 (b) -(h).Readers are invited to verify that, for each of the eight cases, we get a valid REL of the graph G * 1 ∪ G * (C * ) after splitting x and putting R(C * ) back into R 1 .For the cases south, east, north and west, the pattern of the third edge e * 3 of C * is unique (as shown in Figure 7 (a), (b), (g) and (h ) is incident to the node y.We say e * is assigned to both x and y.Or equivalently, we say the separating 2-cycle C * is assigned to both x and y.(In Figure 5 (b), the edges (x, v) and (y, w) are two marked edges in G * .They are incident to x and y, respectively.So the separating 2-cycle C * = {x, y} is assigned to both x and y.)The processing of C * is similar to a separating triangle.The only difference is that we need to split both x and y.Depending on the pattern of e * = (x, y) in R 1 , there are four cases.For example, if e * = y → x is in T 1 , then we split x according to the case south, and split y according to the case north.(See Figure 7 (i), case 2-cycle.)After performing these two node split operations, C * becomes a quadrangle with four exterior nodes x 1 , x 2 , y 2 , y 1 in clockwise order.We recursively construct an REL R(C * ) for G * (C * ) with x 1 , x 2 , y 2 , y 1 as the north, east, south and west nodes respectively.Putting R 1 and R(C * ) together, we get a valid REL of G * 1 ∪ G * (C * ).

The Edge Pattern around a Node
Although we can process the separating cycles of G * in arbitrary order to add all deleted nodes back into G * 1 , doing so does not guarantee a SSOD of G at the end.Consider a node x in G * 1 .Let C be the set of all separating cycles of G * assigned to x.If C contains several separating cycles, x must be split multiple times in order to destroy all separating cycles in C. The problem of breaking all separating triangles has been studied in [1].However, our goal here is different.To make sure the union of the rectangles corresponding to these split nodes constitutes a star-shaped orthogonal polygon, we must split the node x carefully as described below.
Figure 8 (a) shows the general pattern of the edges in G * 1 around x with respect to the REL R 1 = {T 1 , T 2 }.(In Figure 8 (a), a blue dotted circle indicates the component inside a separating triangle C * assigned to x.The blue dotted arrow indicates the marked edge inside C * .A thick line indicates a merged 2-cycle edge assigned to x.) We partition C into four subsets (some subsets may be empty): We create a subgraph around x as follows (see Figure 8 (b)): • Replace x by a new node x 0 and create a cycle K around x 0 .K contains four corner nodes x sw , x se , x ne , x nw .The edge • Between x sw and x se , K has a sub-path K S containing max{1, m S } edges.All edges in K S are in T 2 directed counterclockwise.The nodes on K S are named as x si (1 ≤ i ≤ m S − 1) counterclockwise.For 1 ≤ i < m S , the edge x si → x 0 is in T 1 .For 1 ≤ i ≤ m S , the edge (x s(i−1) , x si ) is used to destroy the separating cycle C * si .Namely, (x s(i−1) , x si ) is an edge of the quadrangle obtained from C * si .Here x s0 = x sw and x sm S = x se .
• Between x se and x ne , K has a sub-path K E containing max{1, m E } edges.All edges in K E are in T 1 directed counterclockwise.The nodes on K E are named as x ei (1 ≤ i ≤ m E − 1) counterclockwise.For 1 ≤ i < m E , the edge x 0 → x ei is in T 2 .For 1 ≤ i ≤ m E , the edge (x e(i−1) , x ei ) is used to destroy the separating cycle C * ei .Namely, (x e(i−1) , x ei ) is an edge of the quadrangle obtained from C * ei .Here x e0 = x se and x em E = x ne .• Between x ne and x nw , K has a sub-path K N containing max{1, m N } edges.All edges in K N are in T 2 directed clockwise.The nodes on K N are named as When some of the sets C S , C E , C N , C W are empty, they are treated as a special case.For example, suppose C W = ∅.Then K W just contains one T 1 edge x sw → x nw , and we split the T 2 edge w 1 → x into two T 2 edges w 1 → x sw and w 1 → x nw (see Figure 8   C N = {C * n1 , C * n2 } (C * n2 is the separating 2-cycle represented by the merged 2-cycle edge (x, n 3 )).For i = 1, 2, C * ni contains a marked edge (c i , x) in its interior.
C W = ∅.Note that, for each separating 2-cycle represented by a merged 2-cycle edge e * , both end nodes of e * are split after this operation.For example, the separating 2-cycle C * s3 (represented by e * = (s 3 , x)) becomes a quadrangle with nodes x s2 , x se , s 3 , s 3 (s 3 is a split node from s 3 .) This construction deals with the most general case.If some of the sets C S , C E , C N , C W are empty, the construction can be simplified.For example, if only C S is not empty, we can simply pick a T 1 edge x → y, and split all separating cycles C * si with respect to this edge.Figure 8 (c) shows the portion of the rectangular dual R for the nodes in the subgraph shown in Figure 8 (b).Each small rectangle in R is labeled by the node it represents.Let r x be the union of the rectangle x 0 and all rectangles x αi (α ∈ {s, e, n, w} and 1 ≤ i ≤ m α .)This orthogonal polygon r x is the face 2. Construct the dual graph G * of G.  Let S denote the set of separating cycles in G * .We can organize S into a tree like structure S T as follows [13].The root t 0 of S T corresponds to the entire graph.Let C * 1 , . . .C * k be all maximal separating cycles of G * .Then t 0 has k children t 1 , . . ., t k .Each t i corresponds to C * i (1 ≤ i ≤ k.) Below each t i , we recursively construct the tree representing the separating cycles within the subgraph G * (C * i ).The tree structure S T can be constructed in linear time [13,9].By using this data structure, we can show that, for each maximal separating cycle C * , the time needed to process G * (C * ) is linear of the size of G * (C * ).Therefore the entire algorithm takes linear time.In summary we have:

Construct the graph
Theorem 5 Let G be a graph that satisfies the conditions in Theorem 2. Then G has a SSOD without bends, which can be constructed in linear time.

L-shaped Orthogonal Drawing
Let G * be an internally triangulated plane graph with a quadrangular exterior face.If G * has separating triangles, then it does not have a rectangular dual.However, it is possible to represent G * by an L-shaped modules representation (LSMR) as follows [13]: An LSMR of G * is a rectangle R subdivided into a set of orthogonal modules.Each module is either a rectangle or an L-shaped polygon.Each node u of G * corresponds to a module r u in R. Two nodes u, v in G * are adjacent in G * if and only if their corresponding modules r u and r v share a common boundary.
Not every internally triangulated plane graph G * has LSMR.A necessary and sufficient condition for G * to have such a representation was obtained in [13], which is described below.
Let S be the set of all separating triangles in G * .A nested separating triangle sequence (NSTS) assigned to a node x in G * is a sequence of separating triangles T = {C 1 , C 2 , . . ., C k } ⊂ S such that: (1) C i is contained in the interior of C i+1 (1 ≤ i < k); and (2) all C i are incident to the node x.A valid assignment of S is a partition of S into a set of NSTS T 1 , T 2 , . . ., T q such that each node x in G * is assigned at most one T i .The following results are obtained in [13].
Theorem 6 [13] Let G * be an internally triangulated plane graph with a quadrangular exterior face.
1. G * has a LSMR if and only if there exists a valid assignment of S; 2. The existence of a valid assignment of S can be tested in O(n 1.5 ) time by finding a perfect matching in an auxiliary graph.
3. If a valid assignment of S is given, a LSMR of G * can be constructed in O(n 2 ) time.In [14], it was shown that if a valid assignment of S is given, then a LSMR can be constructed in linear time.In this section, we show that if a valid assignment of S is given, a LSMR of G * can be constructed in O(n) time.So our algorithm is an alternative of the algorithm in [14].Our method is totally different from the methods used in [14].
The basic idea is that we can destroy all separating triangles in S by using node split operation.Let T = {C 1 , . . ., C k } be a NSTS assigned to a node x in G * .If we split the node x with respect to an edge (z, x) in the interior of C 1 and an edge (x, y) in the exterior of C k , then all C i (1 ≤ i ≤ k) are destroyed.See Figure 9 (a).
We apply the same method in Section 4 to solve this problem.Suppose that we are given a valid assignment of S. Let G * 1 be the graph obtained from G * by deleting all nodes in the interior of all maximal separating triangles in G * .Then G * 1 is a PTP graph.So we can find a REL R 1 = {T 1 , T 2 } for G * 1 .Now we want to put the deleted nodes back into G * 1 .By the definition of valid assignment, at most one maximal separating triangle C is assigned to each node x in G * 1 .So there is no need to use the complicated scheme to split x.We simply apply one of the cases shown in Figure 7. Suppose that x is split with respect to the edges (z, x) and (x, y) (where (x, y) is in the exterior of C.) After the split operation, the edge (x, y) becomes two edges (x 1 , y) and (x 2 , y).In all eight cases, the type of (x 1 , y) and (x 2 , y) are the same.Namely they must be one of the following: (1) they are both in T 1 and entering y; (2) both in T 1 and leaving y; (3) both in T 2 and entering y; (4) both in T 2 and leaving y.
Let D(G) be the drawing of G obtained by Algorithm SSOD-Draw.Each node x is split at most once.So the module r x is the union of at most two rectangles.Because of the special edge pattern around the nodes x 1 and x 2 , r x is always an L-shaped polygon.(Figure 9

Conclusion
In this paper, we strengthen one of the results in the recent paper [2].We show that if G satisfies the same conditions in [2], it not only has an orthogonally convex drawing, but also a stronger star-shaped orthogonal drawing.The method we use is quite different from the methods in [2,12].By using the same technique, we show that an L-shaped module representation can be constructed in O(n) time.It will be interesting to see if this method can be used to solve other orthogonal drawing problems.

2 .
(a)): 1. Add eight new vertices a , a , b , b , c , c , d , d in the exterior face of G; connect them into a clockwise cycle.Add four new edges (a, a ), (b, b ), (c, c ), (d, d ).

Property 1 1 .
G is a biconnected plane 3-graph.2. G has eight vertices on its exterior face C o (G); four are 2-vertices and four are 3-vertices; the 2-vertices and 3-vertices alternate on C o (G).

3 .Figure 2 :
Figure 2: (a) The construction of G from H, (b) drawings of H and G, (c) and (d) conditions in Theorem 1, (e) conditions in Theorem 2.

Figure 2 (
Figure 2 (c) shows a 3-legged cycle C = {a, b, c, d} and an orthogonal drawing of C (d is a 2-vertex.)Figure 2 (d) shows a 2-legged cycle C = {a, b, c, d} and an orthogonal drawing of C (c and d are two 2-vertices.)

Figure 2 (
Figure 2 (e) shows a 2-legged cycle C = {a, b, c, d} and an orthogonal drawing of C (b and d are two 2-vertices.)Note that, in Figure 2 (d), the 2-legged cycle C satisfies the condition 2 in Theorem 1, but not the condition 2 in Theorem 2.Hence there exists no orthogonally convex drawing: In any drawing, the face outside of C (marked by F ) cannot be orthogonally convex.In Section 4, we will show that any graph satisfying the conditions in Theorem 2 has a SSOD without bends.

2 .
Each smaller rectangle corresponds to a node of G * .3.Two nodes of G * are adjacent in G * if and only if their corresponding small rectangles share a line segment as their common boundary.

Figure 3 (
Figure 3 (a) shows an orthogonal drawing D(G) of a graph G that satisfies the conditions in Property 1. Figure 3 (b) shows the dual graph G * of G.Note that the orthogonal drawing D(G) in Figure 3 (a) is also a rectangular dual R of G * (each face of D(G) is a rectangle).Not every internally triangulated graph G * has a rectangular dual.The following theorem characterizes such graphs.

Figure 3 ( 2 .
Figure 3 (a) shows an orthogonal drawing D(G) of a graph G that satisfies the conditions in Property 1. Figure 3 (b) shows the dual graph G * of G.Note that the orthogonal drawing D(G) in Figure 3 (a) is also a rectangular dual R of G * (each face of D(G) is a rectangle).Not every internally triangulated graph G * has a rectangular dual.The following theorem characterizes such graphs.Theorem 3 [10] A plane graph G * = (V * , E * ) has a rectangular dual with four rectangles on its boundary if and only if: 1.Every interior face of G * is a triangle and the exterior face of G * is a quadrangle.2. G * has no separating triangles.

Figure 3 :
Figure 3: (a) An orthogonal drawing D(G) of a graph G, which is also a rectangular dual of G * , (b) the dual graph G * of G with an REL R = {T 1 , T 2 }, (c) the subgraph G * SN , (d) the subgraph G * W E .

Figure 3 (
Figure 3 (b) shows an example of REL of a PTP graph.The red solid lines are edges in T 1 .The green dashed lines are edges in T 2 .
(a) shows an example: The small circles are nodes in G * SN , the solid lines are the edges in G * SN , the blue dashed lines are the edges in G SN , the small squares are the vertices in G SN , the number inside a square is the number assigned to the vertex of G SN .)The dual graph G W E of G * W E and the consistent numbering F 2 of G W E are defined similarly.For any node u in G * SN , the left face of u, denoted by left(u), is the face in G * SN bounded by the left most edge entering u and the left most edge leaving u.The right face of u, denoted by right(u), is the face in G * SN bounded by the right most edge entering u and the right most edge leaving u (see Figure 4 (b)).Define l(u) = F 1 (left(u)) and r(u) = F 1 (right(u)).Clearly, l(u) < r(u).For any node u in G * W E , the top face of u, denoted by top(u), is the face in G * W E bounded by the left most edge entering u and the left most edge leaving u.The bottom face of u, denoted by bottom(u), is the face in G * W E bounded by the right most edge entering u and the right most edge leaving u.Define t(u) = F 2 (top(u)) and b

Figure 4 (
a) shows the consistent numbering obtained by the right-most topological sort of G SN .

Figure 4 :
Figure 4: (a) The graph G * SN , its dual graph G SN , and a consistent numbering of G SN , (b) the pattern of the edges around a node u.The first clockwise edge entering u is e * 1 .The first clockwise edge leaving u is e * 2 , (c) and (d) two examples of the rectangles corresponding to the nodes v 1 , u, v 2 .

Figure 5 (
b) shows a 2-legged cycle and its corresponding separating 2-cycle in G * .
(a), the left figure for the case south shows the edge pattern of C * before the node split operation.The right figure shows the edge pattern of C * after the node split operation.In Figure 7 (a), a blue dotted circle indicates the component inside C * that was deleted.The blue dotted arrow (z, x) indicates the marked edge inside C * .

Figure 7 :
Figure 7: Cases of node split operation.
).)For the other four cases, there are two possible patterns for the edge e * 3 .Only one pattern of e * 3 is shown in Figure 7 (c), (d), (e) and (f).The other pattern of e * 3 is similar.(For example, for the case southwest, the edge e * 3 can also be in T 2 directed from v to u.In this case, e * 3 remains in T 2 directed from v to u after the node split operation.)Next consider a separating 2-cycle C * in G * .C * corresponds to a merged 2-cycle edge e * = (x, y) for some nodes x and y in G * 1 .Let C be the 2-legged cycle in G corresponding to C * .By Property 2, C has two 2-vertices, a and b, one on each of its two contour paths.a and b correspond to two marked edges e * a and e * b in G * .One of them, say e * a , is incident to the node x.The other (e * b

Figure 8 :
Figure 8: (a) The edge pattern around a node x, (b) the subgraph created for x, (c) the orthogonal drawing of the subgraph in (b). (b)).

Figure 8 (
a) and (b) show an example of this construction.The south neighbors of x are s 1 , s 2 , s 3 , s 4 .The east neighbors of x are e 1 , e 2 , e 3 .The north neighbors of x are n 1 , n 2 , n 3 .The west neighbors of x are w 1 , w 2 .C S = {C * s1 , C * s2 , C * s3 } (C * s3 is the separating 2-cycle represented by the merged 2-cycle edge (s 3 , x)).For i = 1, 2, 3, C * si contains a marked edge (a i , x) in its interior.C E = {C * e1 , C * e2 } (C * e2 is the separating 2-cycle represented by the merged 2-cycle edge (x, e 3 )).For i = 1, 2, C * ei contains a marked edge (b i , x) in its interior.

7 . 8 .Corollary 1
Let D(G) be the orthogonal drawing of G obtained from R as described above.Add the 2-vertices contracted during Step 1 back into D(G 0 ).The drawing D(G) constructed by Algorithm SSOD-Draw is a SSOD without bends for G. Proof: In Lemma 2, we have shown that for any node x in G * 1 , the orthogonal polygon r x corresponding to x is star-shaped.Any node y of G * not in G * 1 is in the interior of a maximal separating cycle C * .The orthogonal polygon r y for y in D(G) is contained in the drawing for G * (C * ).Our argument can be recursively applied to the drawing of G * (C * ) to show r y is star-shaped.Hence D(G) is a SSOD of G.During the entire process, no bends are introduced.Next we briefly analyze the run time of Algorithm SSOD-Draw.Let n 1 be the size (namely the number of nodes plus the number of edges) of G * 1 .All steps in Algorithm SSOD-Draw involving G * 1 can be done in O(n 1 ) time by Theorem 4 and basic algorithmic techniques for planar graphs.

Figure 9 :
Figure 9: (a) Splitting x destroys all three separating triangles assigned to x, (b) and (c) two examples of L-shaped polygon for x.
(b) and (c) show two examples.)Thus we have: Theorem 7 Let G * be an internally triangulated plane graph with a quadrangular exterior face.Given a valid assignment of S, a LSMR of G * can be constructed in linear time.
is called internally triangulated if all of its interior faces are triangles.G is called triangulated if all of its faces (both interior and exterior) are triangles.A cycle C of G divides the plane into two regions: the interior and the exterior region.A separating cycle of G is a cycle C such that there is at least one vertex in the interior region of C and at least one vertex in the exterior region of C. Note that a separating cycle may be contained in the interior of other separating cycles.A separating cycle C is called maximal if it's not contained in any other separating cycle C .Let D(G) be an orthogonal drawing of G without bends.Each cycle C of G is drawn as an orthogonal polygon, denoted by D(C), in D(G).Let a be a vertex of C. We will also use a to denote the point in D(C) that corresponds to a.A vertex a of D(C) is called a corner of D(C) if the interior angle of D(C) at a is 90 • or 270 • .A corner with 90 • (270 the four exterior nodes of G in clockwise order.All interior edges incident to v N are in T 1 and entering v N .All interior edges incident to v E are in T 2 and entering v E .All interior edges incident to v S are in T 1 and leaving v S .All interior edges incident to v W are in T 2 and leaving v W . JGAA, 21(2) 155-175 (2017) 161 h).)If both e * 1 and e * 2 are T 1 edges entering x, we call it the case south.If e * 1 is a T 2 edge entering x and e * 2 is a T 1 edge entering x, we call it the case southwest.The other six cases are respectively called the case southeast, east, northeast, north, northwest and west.
the edge (x n(i−1) , x ni ) is used to destroy the separating cycle C * ni .Namely, (x n(i−1) , x ni ) is an edge of the quadrangle obtained from C * ni .Here x n0 = x ne andx nm N = x nw .•Between x nw and x sw , K has a sub-path K W containing max{1, m W } edges.All edges in K W are in T 1 directed clockwise.The nodes on K W are named as x wi (1 ≤ i ≤ m W − 1) counterclockwise.For 1 ≤ i < m W , the edge x wi → x 0 is in T 2 .For 1 ≤ i ≤ m W , the edge (x w(i−1) , x wi ) is used to destroy the separating cycle C * wi .Namely, (x w(i−1) , x wi ) is an edge of the quadrangle obtained from C * wi .Here x w0 = x nw and x wm W = x sw .
G * 1 , by deleting all nodes in the interior of maximal separating cycles in G * .4. Construct a REL R 1 of G * 1 .5. By using the procedures described Subsections 4.1 and 4.2, perform node split operation for all nodes x with at least one maximal separating cycle C * assigned to it.Then C * becomes a quadrangle.Make recursive call to construct a REL R(C * ) for G * (C * ).Let G * be the PTP graph obtained from G * 1 by adding all deleted nodes back into G * 1 .Let R be the REL of G * obtained after this process.6. Construct a rectangular dual R of G * by using R , as described in Lemma 1.