Presentation is loading. Please wait.

Presentation is loading. Please wait.

Drawing Plane Graphs Takao Nishizeki Tohoku University.

Similar presentations


Presentation on theme: "Drawing Plane Graphs Takao Nishizeki Tohoku University."— Presentation transcript:

1 Drawing Plane Graphs Takao Nishizeki Tohoku University

2 US President California Governor

3 US President California Governor What is the common feature?

4 Graphs and Graph Drawings A diagram of a computer network

5 Objectives of Graph Drawings To obtain a nice representation of a graph so that the structure of the graph is easily understandable. structure of the graph is difficult to understand structure of the graph is easy to understand Nice drawing Symmetric Eades, Hong

6 Objectives of Graph Drawings Nice drawing Ancient beauty Modern beauty

7 The drawing should satisfy some criterion arising from the application point of view. 1 2 3 4 5 7 8 not suitable for single layered PCB suitable for single layered PCB 1 2 3 4 6 8 5 7 Objectives of Graph Drawings Diagram of an electronic circuit Wire crossings

8 Drawings of Plane Graphs Convex drawing Straight line drawing

9 Drawings of Plane Graphs Rectangular drawing Orthogonal drawing Box-rectangular drawing

10 Book Planar Graph Drawing by Takao Nishizeki Md. Saidur Rahman http://www.nishizeki.ecei.tohoku.ac.jp/nszk/saidur/gdbook.html

11 Straight Line Drawing Plane graph

12 Straight Line Drawing Plane graph Straight line drawing

13 Straight Line Drawing Each vertex is drawn as a point. Plane graph Straight line drawing

14 Straight Line Drawing Each vertex is drawn as a point. Each edge is drawn as a single straight line segment. Plane graph Straight line drawing

15 Straight Line Drawing Each vertex is drawn as a point. Each edge is drawn as a single straight line segment. Plane graph Straight line drawing Every plane graph has a straight line drawing. Wagner ’36 Fary ’48 Polynomial-time algorithm

16 Straight Line Drawing Plane graph Straight line drawing W H W H

17 Straight Line Grid Drawing In a straight line grid drawing each vertex is drawn on a grid point. Plane graph Straight line grid drawing.

18 Wagner ’36 Fary ’48 Plane graph Straight line grid drawing. Grid-size is not polynomial of the number of vertices n

19 Plane graph Straight line grid drawing. de Fraysseix et al. ’90 Straight Line Grid Drawing

20 Plane graph Straight line grid drawing. de Fraysseix et al. ’90 Chrobak and Payne ’95 Linear algorithm

21 n-2 Schnyder ’90 W H Upper bound

22 What is the minimum size of a grid required for a straight line drawing?

23 Lower Bound

24 A restricted class of plane graphs may have more compact grid drawing. Triangulated plane graph 3-connected graph

25 4-connected ? not 4-connected disconnected

26 How much area is required for 4-connected plane graphs?

27 W < n/2 H < n/2 = = Straight line grid drawing Miura et al. ’01 Input: 4-connected plane graph G Output: a straight line grid drawing Grid Size : Area:

28 n-2 Area < 1/4 = Area=n 2 Area<n /4 2 W < n/2 H < n/2 = =.. = plane graph G 4 -connected plane graph G Schnyder ’90 Miura et al. ’01

29 The algorithm of Miura et al. is best possible

30 |slope|>1 Main idea G Step2: Divide G into two halves G’ and G” n/2=9 G” G’ 1 2 n-1=17 n=18 3 4 7 8 5 6 14 10 15 16 13 11 12 W < n/2 -1 = W/2 1 G’ G” Step3 and 4 : Draw G’ and G” in isosceles right-angled triangles G n/2 n/2 -1 Step5: Combine the drawings of G’ and G” Triangulate all inner faces 1 2 n-1=17 n=18 3 4 7 8 5 6 14 9 10 15 16 13 11 12 Step1: find a 4-canonical ordering |slope|<1 =

31 Straight line drawing Convex drawing Draw a graph G on the plane “nicely” A convex drawing is a straight line drawing where each face is drawn as a convex polygon.

32 Convex drawing Convex Drawing Tutte 1963 Every 3-connected planar graph has a convex drawing. A necessary and sufficient condition for a plane graph to have a convex drawing. Thomassen ’80

33 Convex drawing Convex Drawing Tutte 1963 Every 3-connected planar graph has a convex drawing A necessary and sufficient condition for a plane graph to have a convex drawing. Thomassen ’80 Chiba et al. ’84 O(n) time algorithm

34 n-2 Convex Grid Drawing Chrobak and Kant ’97 Input: 3-connected graph Output: convex grid drawing Area Grid Size

35 Input : 4 -connected plane graph W H Miura et al. 2000 Output: Convex grid drawing Half-perimeter Area Convex Grid Drawing Grid Size

36 Area < 1/4 = 3 -connected graph 4 -connected graph Area n-2 W H Area Chrobak and Kant ’97 Miura et al. 2000

37 W H The algorithm of Miura et al. is best possible

38 1: 4-canonical decomposition 12 3 45 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 13 14 15 1617 1819 20 21 11 12 9 10 78 6 3 4 5 4: Decide y-coordinates 1 2 Time complexity: O(n) 9 16 1 2 3 4 5 6 7 8 14 21 12 13 20 10 19 11 17 15 18 O(n)[NRN97] 2: Find paths 3: Decide x-coordinates Main idea

39 E A B C F G D VLSI Floorplanning Interconnection graph

40 E A B C F G D A B E C F G D VLSI Floorplanning Interconnection graph VLSI floorplan

41 E A B C F G D A B E C F G D VLSI Floorplanning Interconnection graph VLSI floorplan

42 E A B C F G D A B E C F G D VLSI Floorplanning Interconnection graph VLSI floorplan

43 E A B C F G D A B E C F G D VLSI Floorplanning A B E C F G D Interconnection graph VLSI floorplan Dual-like graph

44 E A B C F G D A B E C F G D VLSI Floorplanning A B E C F G D A B E C F G D Interconnection graph VLSI floorplan Dual-like graphAdd four corners

45 E A B C F G D A B E C F G D VLSI Floorplanning A B E C F G D A B E C F G D Interconnection graph VLSI floorplan Dual-like graphAdd four corners Rectangular drawing

46 Rectangular Drawings Plane graph G of Input

47 Rectangular Drawings Rectangular drawing of G Plane graph G of Input Output corner

48 Rectangular Drawings Rectangular drawing of G Plane graph G of Each vertex is drawn as a point. Input Output corner

49 Rectangular Drawings Rectangular drawing of G Plane graph G of Each edge is drawn as a horizontal or a vertical line segment. Each vertex is drawn as a point. Input Output corner

50 Rectangular Drawings Rectangular drawing of G Plane graph G of Each edge is drawn as a horizontal or a vertical line segment. Each face is drawn as a rectangle. Each vertex is drawn as a point. Input Output corner

51 Not every plane graph has a rectangular drawing.

52 Thomassen ’84, Necessary and sufficient condition Rahman, Nakano and Nishizeki ’98 Linear-time algorithms Rahman, Nakano and Nishizeki ’02 Linear algorithm for the case where corners are not designated in advance

53 G G has a rectangular drawing if and only if 2-legged cycles 3-legged cycles A Necessary and Sufficient Condition by Thomassen ’84 plane graph four vertices of degree 2 are designated as corners every 2-legged cycle in G contains at least two designated vertices; and every 3-legged cycle in G contains at least one designated vertex.

54 G G has a rectangular drawing if and only if 2-legged cycles A Necessary and Sufficient Condition by Thomassen ’84 plane graph four vertices of degree 2 are designated as corners every 2-legged cycle in G contains at least two designated vertices; and every 3-legged cycle in G contains at least one designated vertex.

55 G G has a rectangular drawing if and only if 2-legged cycles 3-legged cycles A Necessary and Sufficient Condition by Thomassen ’84 plane graph four vertices of degree 2 are designated as corners every 2-legged cycle in G contains at least two designated vertices; and every 3-legged cycle in G contains at least one designated vertex.

56 G G has a rectangular drawing if and only if 2-legged cycles 3-legged cycles A Necessary and Sufficient Condition by Thomassen ’84 plane graph four vertices of degree 2 are designated as corners every 2-legged cycle in G contains at least two designated vertices; and every 3-legged cycle in G contains at least one designated vertex. Bad cycles

57 Outline of the Algorithm of Rahman et al.

58

59

60

61

62

63

64 Bad cycle

65

66 Partition-pair

67 Splitting

68 Partition-pair

69

70 Rectangular drawing

71 Partition-pair Rectangular drawing Time complexity O(n)

72 Miura, Haga, N. ’03, Working paper Rectangular drawing of plane graph G with Δ ≤ 4 perfect matching in G d

73 G

74 GdGd G

75 GdGd perfect matching G

76 G

77 E A B C F G D A B E C F G D VLSI Floorplanning Interconnection graph VLSI floorplan Rectangular drawing

78 E A B C F G D A B E C F G D VLSI Floorplanning Interconnection graph VLSI floorplan Rectangular drawing Unwanted adjacency Not desirable for MCM floorplanning and for some architectural floorplanning.

79 A B E C F G D MCM Floorplanning Sherwani Sherwani Architectural Floorplanning Munemoto, Katoh, Imamura Munemoto, Katoh, Imamura E A B C F G D Interconnection graph

80 A B E C F G D MCM Floorplanning Architectural Floorplanning E A B C F G D Interconnection graph

81 MCM Floorplanning Architectural Floorplanning A E B F G C D E A B C F G D Interconnection graph Dual-like graph A B E C F G D

82 MCM Floorplanning Architectural Floorplanning A E B F G C D E A B C F G D Interconnection graph Dual-like graph A B E C F G D

83 MCM Floorplanning Architectural Floorplanning A E B F G C D E A B C F G D A E B F G C D Interconnection graph Dual-like graph A B E C F G D

84 MCM Floorplanning Architectural Floorplanning A E B F G C D E A B C F G D A E B F G C D Box-Rectangular drawing Interconnection graph Dual-like graph A B E C F G D dead space

85 Box-Rectangular Drawing Input Plane multigraph G a b c d

86 Box-Rectangular Drawing InputOutput Plane multigraph G a b c d a b c d Box-rectangular drawing

87 Box-Rectangular Drawing Input Each vertex is drawn as a rectangle. Plane multigraph G a b c d a b c d Output Box-rectangular drawing

88 Box-Rectangular Drawing Input Each vertex is drawn as a rectangle. Each edge is drawn as a horizontal or a vertical line segment. Plane multigraph G a b c d a b c d Output Box-rectangular drawing

89 Box-Rectangular Drawing Input Each vertex is drawn as a rectangle. Each edge is drawn as a horizontal or a vertical line segment. Each face is drawn as a rectangle. Plane multigraph G a b c d a b c d Output Box-rectangular drawing

90 A necessary and sufficient condition for a plane multigraph to have a box-rectangular drawing. A linear-time algorithm. Rahman et al. 2000, where m is the number of edges in G. W H a b c d

91 Algorithm of Rahman et al. Main Idea: Reduction to a rectangular drawing problem

92 G Outline

93 G Replace each vertex of degree four or more by a cycle

94 G Outline linear time [RNN98a] Rectangular drawing

95 G Outline linear time [RNN98a] Box-rectangular drawing

96 G Outline linear time [RNN98a] Box-rectangular drawing Time complexity O(n)

97 Orthogonal Drawings Input plane graph G a b c d e f g h i

98 Orthogonal Drawings Input Output plane graph G a b c d e f g h i a b c d e f g h i

99 Orthogonal Drawings Each edge is drawn as an alternating sequence of horizontal and vertical line segments. Input Output plane graph G bends a b c d e f g h i a b c d e f g h i

100 Orthogonal Drawings Each edge is drawn as an alternating sequence of horizontal and vertical line segments. Each vertex is drawn as a point. Input Output plane graph G bend a b c d e f g h i a b c d e f g h i

101 Applications Entity-relationship diagrams Flow diagrams

102 Applications Circuit schematics Minimization of bends reduces the number of “vias” or “throughholes,” and hence reduces VLSI fabrication costs.

103 plane graph G a b c d e f g h i a b c d e f g h i Objective 4 bends d e a b c f g h i minimum number of bends. 9 bend To minimize the number of bends in an orthogonal drawing.

104 Garg and Tamassia ’96 time for plane graph of Δ ≤4 Ideareduction to a minimum cost flow problem for 3-connected cubic plane graph Idea reduction to a rectangular drawing problem. Rahman, Nakano and Nishizeki ’99 Bend-Minimum Orthogonal Drawing Linear Rahman and Nishizeki ’02 Linear for plane graph of Δ≤3

105 Outline of the algorithm of [RNN99] a b c d a b c d orthogonal drawings b rectangular drawing of a c d orthogonal drawing of G a b c d

106 Open Problems and Future Research Direction More area-efficient straight-line or convex drawing algorithms. Prescribed face areas Prescribed length of some edges Prescribed positions of some vertices Practical Applications Linear algorithm for rectangular drawings of plane graphs of Δ ≤4. Drawing of plane graphs with constraints like for every planar graph? Linear algorithm for bend-minimal orthogonal drawings of plane graphs of Δ ≤4.

107 Book Planar Graph Drawing by Takao Nishizeki Md. Saidur Rahman http://www.nishizeki.ecei.tohoku.ac.jp/nszk/saidur/gdbook.html

108 Book Planar Graph Drawing by Takao Nishizeki Md. Saidur Rahman http://www.nishizeki.ecei.tohoku.ac.jp/nszk/saidur/gdbook.html

109 ISAAC in Sendai, Tohoku Probably 2007

110 Sendai Kyoto Tokyo

111

112 Properties of a drawing of G(C) minimum number of bends the six open halflines are free G(C)G(C) orthogonal drawing of G(C) x y z x y z

113 Main idea 4-canonical decomposition 12 3 45 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21

114 Main idea 4-canonical decomposition 12 3 45 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 13 14 15 1617 1819 20 21 11 12 9 10 78 6 3 4 5 1 2 12 3 45 6 7 8 9 20 21 Add a group of vertices one by one.

115 Main idea 4-canonical decomposition 12 3 45 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 13 14 15 1617 1819 20 21 11 12 9 10 78 6 3 4 5 1 2

116 1:4-canonical decomposition 12 3 45 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 13 14 15 1617 1819 20 21 11 12 9 10 78 6 3 4 5 4: Decide y-coordinates 1 2 Time complexity: O(n) 9 16 1 2 3 4 5 6 7 8 14 21 12 13 20 10 19 11 17 15 18 O(n)[NRN97] 2: Find paths 3: Decide x-coordinates Main idea

117 U3U3 G k G k -1 (a) G k G k -1 G k G (b) (c) face U k U k U k U 12 U 11 U 10 U9U9 U8U8 U7U7 U6U6 U5U5 U4U4 U2U2 4-canonical decomposition[NRN97] U1U1 (a generalization of st-numbering) G

118 G k G k -1 (a) G k G k -1 G k G (b) (c) face U 12 U 11 U 10 U9U9 U8U8 U7U7 U6U6 U5U5 U4U4 U3U3 U2U2 4-canonical decomposition[NRN97] U1U1 (a generalization of st-numbering)

119 U3U3 4-canonical decomposition[NRN97] (a generalization of st-numbering) G k -1 G k G k G (a) G k G k -1 G k G (b) (c) face

120 G k G k -1 (a) G k G k -1 G k G (b) (c) face U 12 U 11 U 10 U9U9 U8U8 U7U7 U6U6 U5U5 U4U4 U3U3 U2U2 4-canonical decomposition[NRN97] U1U1 (a generalization of st-numbering)

121 U9U9 4-canonical decomposition[NRN97] (a generalization of st-numbering) G k -1 G k face G k G k -1 (a) G k G k -1 G k G (b) (c) face

122 G k G k -1 (a) G k G k -1 G k G (b) (c) face U 12 U 11 U 10 U9U9 U8U8 U7U7 U6U6 U5U5 U4U4 U3U3 U2U2 4-canonical decomposition[NRN97] U1U1 (a generalization of st-numbering)

123 U5U5 4-canonical decomposition[NRN97] (a generalization of st-numbering) G k -1 G k face G k G k -1 (a) G k G k -1 G k G (b) (c) face

124 U1U1 U 12 U 11 U 10 U9U9 U8U8 U7U7 U6U6 U5U5 U4U4 U3U3 U2U2 4-canonical decomposition[NRN97] 12 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 n = 21 (a generalization of st-numbering) G k G k -1 (a) G k G k -1 G k G (b) (c) face U k U k U k G O(n)O(n)

125 Orthogonal Drawings Each edge is drawn as an alternating sequence of horizontal and vertical line segments. Each vertex is drawn as a point. Applications Circuit schematics, Data-flow diagrams, Entity- relationship diagrams [T87, BK97]. Objective To minimize the number of bends in an orthogonal drawing. Input Output plane graph G an orthogonal drawing with the minimum number of bends. 9 bends 4 bends a b c d e f g h i a b c d e f g h i d e a b c f g h i

126 Known Result Garg and Tamassia [GT96] time algorithm for finding an orthogonal drawing of a plane graph of Δ ≤4 with the minimum number of bends. Ideareduction to a minimum cost flow problem A linear time algorithm to find an orthogonal drawing of a 3-connected cubic plane graph with the minimum number of bends. Ideareduction to a rectangular drawing problem. Rahman, Nakano and Nishizeki [RNN99] A linear time algorithm to find an orthogonal drawing of a plane graph of Δ≤3 with the minimum number of bends. Ideareduction to a no-bend drawing problem. Rahman and Nishizeki [RN02]

127 Outline of the algorithm of [RNN99] rectangular drawing of orthogonal drawings orthogonal drawing of G Properties of a drawing of G(C) minimum number of bends the six open halflines are free G(C)G(C) orthogonal drawing of G(C) a b c d a b c d a b c d a b c d x y z x y z

128 Rectangular Drawings Rectangular drawing of G Plane graph G of Each edge is drawn as a horizontal or a vertical line segment. Each face is drawn as a rectangle. Each vertex is drawn as a point. Input Output corner Not every plane graph has a rectangular drawing. Thomassen [84], Rahman, Nakano and Nishizeki [02] A necessary and sufficient condition. Rahman, Nakano and Nishizeki [98, 02] A linear time algorithm

129 Rectangular Drawing Algorithm of [RNN98] Splitting Partition-pair Input

130 rectangular drawing of each subgraph Partition-pair

131 Modification of drawings patching Rectangular Drawings

132 Box-Rectangular Drawing Input Output Each vertex is drawn as a (possibly degenerated) rectangle on an integer grid. Each edge is drawn as a horizontal or a vertical line segment along grid line without bend. Each face is drawn as a rectangle. Rahman, Nakano and Nishizeki [RNN00] A necessary and sufficient condition. A linear-time algorithm. Plane multigraph Reduce the problem to a rectangular drawing problem.

133 Conclusions We surveyed the recent algorithmic results on various drawings of plane graphs. Open Problems Rectangular drawings of plane graphs of Δ ≤ 4. Efficient algorithm for bend-minimal orthogonal drawings of plane graphs of Δ ≤ 4 Parallel algorithms for drawing of plane graphs.

134 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 2 3 4 5 6 7 8 9 10 17 11 12 13 14 1516 Application VLSI floorplanning Interconnection Graph Floor plan

135 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 Dual-like graph Insertion of four corners

136 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 2 3 4 5 6 7 8 9 10 17 11 12 13 14 1516 Application VLSI floorplanning Interconnection Graph Floor plan

137 st-numbering[E79](2-connected graph ) (1) (1,n) is an edge of G (2) Each vertex k, 2 < k < n-1, has at least one neighbor and at least one upper neighbor 1 2 n=12 3 4 7 8 5 6 10 11 9 ==

138 1 2 3 47 8 5 6 14 10 15 16 13 11 12 9 Step 1: 4-canonical ordering [KH97] (4-connected graph) (1) (1,2) and (n,n-1) are edges on the outer face (2) Each vertex k, 3 < k < n-2, has at least two lower neighbors and has at least two upper neighbors n-1=17 n=18 = = (a generalization of st-numbering)

139 G’’ G’ |V’|= n/2 |V”|= n/2 Step 2: Divide G into G’and G” 1 2 n-1=17 n=18 3 47 8 5 6 14 10 15 16 13 11 12 n/2 =9

140 Step 3: Draw G’ in an isosceles right-angled triangle G 1 2 3 4 7 8 5 6 9 G’ |V’|= n/2 |slope| < 1 = 12 |slope| > 1 12 W/2 W < n/2 -1 =

141 G 1 2 3 4 7 8 5 6 9 G’ |V’|= n/2 1 :外周上の辺の傾きは高々 1 2 :外周上で点 1 から 2 へ時計回りに進む道の描画は x- 単調 | 外周上の辺の傾き | < 1 = x- 単調 12 | 外周上の辺の傾き | > 1 x- 単調ではない 12 Step 3: Draw G’ in an isosceles right-angled triangle

142 shift and put k 各点の座標の決め方 1 2 3 G 3 Initialization : k G k 1 :外周上の辺の傾きは高々 1 2 :外周上で点 1 から 2 へ時計回りに進む道の描画は x- 単調 各点 k, 4 < k < n/2 = = k G k -1

143 The drawing of the path passing through all k’s neighbors is “weakly convex” k k “weakly convex” not “weakly convex”

144 k G k -1 Case 1 : k has exactly one highest neighbor shift and put k G k k The rightmost neighbor of k is higher than the leftmost neighbor

145 shift and put k k G k k G k -1 The rightmost neighbor of k is higher than the leftmost neighbor Case 2 : k has exactly two or more highest neighbor

146 Drawing of G’ 1 2 3 G 3

147 shift Drawing of G’

148 +4 Drawing of G’

149 shift Drawing of G’

150 +5 Drawing of G’

151 shift Drawing of G’

152 +6 Drawing of G’

153 shift Drawing of G’

154 +7 Drawing of G’

155 shift Drawing of G’

156 +8 Drawing of G’

157 shift Drawing of G’

158 +9 Drawing of G’

159 G’ H’ <W’/2=( n/2 -1) 2 = W’ < n/2 -1 = Shift one time for each vertex Drawing of G’

160 G’ G” W < n/2 -1 W/2 1 = Step 5: Combine the drawing of G’ and G”

161 G’ G” W < n/2 -1 W/2 1 = | 辺の傾き |>1 | 外周上の辺の傾き | < 1 =

162 = G’ G” | 辺の傾き |>1 Step 5: Combine the drawing of G’ and G”

163 x- 単調 G’ G” Step 5: Combine the drawing of G’ and G”

164 G’ G” W < n/2 -1 W/2 1 = G W < n/2 -1 H< n/2 = = Step 5: Combine the drawing of G’ and G”

165 W = n/2 -1 H = n/2 Output: a straight line grid drawing Grid Size : (W +H < n-1) W < n/2 -1, H < n/2 = = = Area: W x H < = ( ) n -1 2 2 W < n/2 -1 H < n/2 = = Input: 4-connected plane graph G The algorithm is best possible Miura et al. ‘01

166 Objective To minimize the number of bends in an orthogonal drawing. an orthogonal drawing with the minimum number of bends. 4 bends d e a b c f g h i 9 bends a b c d e f g h i


Download ppt "Drawing Plane Graphs Takao Nishizeki Tohoku University."

Similar presentations


Ads by Google