90
ogonal Drawings of Series-Parallel Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Embed Size (px)

Citation preview

Page 1: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Orthogonal Drawings of Series-Parallel Graphs

Joint work with Xiao Zhou

by

Tohoku University

Takao Nishizeki

Page 2: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Orthogonal Drawings of Series-Parallel Graphs

with Minimum Bends

Xiao Zhou and Takao Nishizeki

by

Tohoku University

1. each vertex is mapped to a point2. each edge is drawn as a sequence of alternate horizontal and

vertical line segments3. any two edges don’t cross except at their common ends

planar graph orthogonal drawings

Page 3: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Orthogonal Drawings of Series-Parallel Graphs

with Minimum Bends

Xiao Zhou and Takao Nishizeki

by

Tohoku University

1. each vertex is mapped to a point2. each edge is drawn as a sequence of alternate horizontal and

vertical line segments3. any two edges don’t cross except at their common ends

planar graph orthogonal drawings

bend

one bend

Page 4: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Orthogonal Drawings of Series-Parallel Graphs

with Minimum Bends

Xiao Zhou and Takao Nishizeki

by

Tohoku University

1. each vertex is mapped to a point2. each edge is drawn as a sequence of alternate horizontal and

vertical line segments3. any two edges don’t cross except at their common ends

planar graph orthogonal drawingscrossing

Page 5: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Orthogonal Drawings of Series-Parallel Graphs

with Minimum Bends

Xiao Zhou and Takao Nishizeki

by

Tohoku University

1. each vertex is mapped to a point2. each edge is drawn as a sequence of alternate horizontal and

vertical line segments3. any two edges don’t cross except at their common ends

planar graph orthogonal drawings

one bend no bend

another embedding

bend

Page 6: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

bend

An orthogonal drawing of a planar graph G is optimal if it has the minimum # of bends among all possible orthogonal drawings of G.

orthogonal drawings

one bend no bend

Optimal orthogonal drawing

optimal

planar graph

bend via-hole, through-hole VLSI design

Page 7: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Example

4 bends

Orthogonal Drawings

drawing

bendbendbendbend

Page 8: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Example

4 bends

Orthogonal Drawings

drawing

bendbendbendbend

Optimal ? No

Page 9: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Example

embedding

Orthogonal Drawings

drawing

bendbendbendbend

flip

4 bends

Page 10: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Example

embedding

flip

4 bends

Orthogonal Drawings

drawing

bendbendbendbend

Page 11: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Example

embedding

flip

4 bends

Orthogonal Drawings

drawing

bendbendbendbend

Page 12: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Example

embedding

flip

4 bends

Orthogonal Drawings

drawing

bendbendbendbend

Page 13: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Example

embedding

4 bends

Orthogonal Drawings

drawing

bendbendbendbend

Page 14: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Example

drawing

embedding

0 bend

optimal

4 bends

Orthogonal Drawings

drawing

bendbendbendbend

Page 15: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Orthogonal Drawings

drawing

bendbendbendbend

4 bends

Example

drawing

embedding

0 bend

optimal

Given a planar graph

Wish to findan optimal orthogonal drawing

Find an optimal orthogonal drawing of a given planar graph.

Problem

Page 16: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

wheredegree of vertex v: # of edges incident to vΔ : max degree

Δ=3, n=7

Known results

The problem:NP-complete for planar graphs of Δ≦4

A. Garg, R. Tamassia, 2001

If Δ≧5, then no orthogonal drawing.d(v)=2

d(v)=3

2

2 2

2

323

Page 17: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Known results

The problem:NP-complete for planar graphs of Δ≦4

A. Garg, R. Tamassia, 2001

D. Battista, et al. 1998If Δ≦3, O(n5logn) time

where n: # of vertices

Δ=3, n=7

Page 18: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Known results

The problem:NP-complete for planar graphs of Δ≦4

A. Garg, R. Tamassia, 2001

If Δ≦3, O(n5logn) time D. Battista, et al. 1998

If Δ≦4, O(n4) timeIf Δ≦3, O(n3) time

D. Battista, et al. 1998

D. Battista, et al. 1998

For biconnected series-parallel graphs

Page 19: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Our results

If Δ≦3, O(n) time our result

much simpler and faster than the known algorithms

For series-parallel graphs

Page 20: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Series-Parallel Graphs

(a)

if are SP graphs,

is a SP graph.

then are SP graphs

A SP graph is recursively defined as follows:

(b)

a single edge

Page 21: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Series-Parallel Graphs

(a)

if are SP graphs,

is a SP graph.

then are SP graphs

A SP graph is recursively defined as follows:

(b)

a single edge

Page 22: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

parallel-connection

Series-Parallel Graphs

(a)

if are SP graphs,

is a SP graph.

then are SP graphs

A SP graph is recursively defined as follows:

(b)

a single edge

Page 23: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

series-connection parallel-connection

Series-Parallel Graphs

(a)

if are SP graphs,

is a SP graph.

then are SP graphs

A SP graph is recursively defined as follows:

(b)

a single edge

Page 24: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Series-Parallel Graphs

(a)

if are SP graphs,

is a SP graph.

then are SP graphs

A SP graph is recursively defined as follows:

(b)

a single edge

Page 25: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Series-Parallel Graphs

Example

SP graph

Page 26: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Series-Parallel Graphs

Example

SP graphseries-connection

Page 27: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Series-Parallel Graphs

Example

SP graphparallel-connection

Page 28: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Series-Parallel Graphs

Example

SP graphSeries-connection

Page 29: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Series-Parallel Graphs

Example

SP graphParallel-connection

Page 30: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Series-Parallel Graphs

Example

Biconnected SP graphs

SP graphbiconnected

Biconnected graphs G:

G – v is connected for each vertex v.v v

Page 31: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Series-Parallel Graphs

Example

SP graphbiconnected

Biconnected graphs G:

G – v is connected for each vertex v.

not biconnected

v

Biconnected SP graphs

cut vertex

Page 32: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Series-Parallel Graphs

Example

SP graphsbiconnected

Page 33: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

(Our Main Idea)Lemma 1

Every biconnected SP graph G of Δ≦3 has one of thefollowing three substructures: (a) a diamond C (b) two adjacent vertices u and v s.t. d(u)=d(v)=2 (c) a triangle K3.

(a)

u v

(b)

K3

(c)

2

3

2

3 2 22

3 3

Page 34: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

(Our Main Idea)Lemma 1

Every biconnected SP graph G of Δ≦3 has one of thefollowing three substructures: (a) a diamond C (b) two adjacent vertices u and v s.t. d(u)=d(v)=2 (c) a triangle K3.

(a)

u v K3

(b) (c)

2

3

2

3 2 22

3 3

Page 35: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Algorithm(G)

Let G be a biconnected SP graph of Δ≦3.Case (a): ∃ a diamond , Recursively find an optimal drawing.

 Case (b): ∃

  Decompose to smaller subgraphs in series or

parallel, and iteratively find an optimal drawingCase (c): ∃

     Similar as Case (b).

Page 36: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Let G be a biconnected SP graph of Δ≦3.Case (a): ∃ a diamond ,  

Algorithm(G)

Algorithm( ),

Recur G to a smaller one     

find

optimal optimal

contractReturn

expand

expand

Page 37: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Let G be a biconnected SP graph of Δ≦3.Case (a): ∃ a diamond ,  

Algorithm(G)

Algorithm( ), find

optimal optimal

contractReturn

expand

expandcontract contract

Examplecontract

drawing

Page 38: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

delete edge

Let G be a biconnected SP graph of Δ≦3.Case (a): ∃ a diamond ,  

Algorithm(G)

Algorithm( ), find

contractReturn

expand

Case (b): ∃

Page 39: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

deg=1 deg=1

2-legged SP

Find an opt & U-shape

delete edge

Case (b): ∃

Page 40: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

terminals are drawn on the outer face;the drawing except terminals doesn’t intersect the north side

Our Main Idea

Definition of I- , L- and U-shaped drawings

I-shape L-shape U-shape

2-legged SP graph

s tU-shape U-shape

Page 41: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Our Main Idea

2-legged SP graph

s t

Definition of I- , L- and U-shaped drawings

L-shape U-shape

terminals are drawn on the outer face;the drawing except terminals intersects neither the north side nor the south side I-shape

I-shape

I-shape

Page 42: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

terminals are drawn on the outer face;the drawing except terminals intersects neither the north side nor the east side

Our Main Idea

Definition of I- , L- and U-shaped drawings

I-shape L-shape U-shape

2-legged SP graph

s tL-shapeL-shape

Page 43: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Lemma 2

Every 2-legged SP graph without diamond has optimal I-, L- and U-shaped drawings

I-shape

optimal

bend

L-shape

optimal

bend

U-shape

optimal

bend

Page 44: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Δ ≦ 3

deg=1 deg=1

2-legged SP

Find an opt & U-shape

parallel connectionseries connection

delete edge

Case (b): ∃

decompose

Page 45: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

opt & L-shape opt & L-shapeopt & U-shapeopt & U-shapeopt & L-shape

Find an opt & U-shape

delete edge

Case (b): ∃

Page 46: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

opt & U-shapeopt & I-shapeopt & U-shape

opt & U-shape

opt &I-shape

opt & U-shape

Find an opt & U-shape

delete edge

Case (b): ∃

Page 47: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

opt & U-shapeopt & I-shapeopt & U-shape

opt & U-shape

opt & I-shape

Find an opt & U-shape

delete edge

Return an optimal drawing

extend

Case (b): ∃

Page 48: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Algorithm( ),

Algorithm(G)

u vu v

Case (c):∃ a complete graph K3. opt & U-shape

Return optimal drawing

bend

expand

Let G be a biconnected SP graph of Δ≦3.Case (a): ∃ a diamond ,  

contraction

Case (b): ∃

Page 49: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

An optimal orthogonal drawing of a biconnected SP graph G of Δ≦3 can be found in linear time.

Theorem 1

Page 50: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

An optimal orthogonal drawing of a biconnected SP graph G of Δ≦3 can be found in linear time.

Theorem 1Our algorithm works well even if G is not biconnected.

find three types of drawings

best one of

Optimal drawing

=

bendbend

bend bendbend

bend bendbendbend

4 bends

2 bends

3 bends

Page 51: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

An optimal orthogonal drawing of a SP graph G of Δ≦3 can be found in linear time.

Theorem 1Conclusions

Page 52: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Conclusions

bend(G) ≦ n/3 for biconnected SP graphs G of Δ≦3

Grid size ≦ 8n/9

=width + height

width

height

Page 53: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki
Page 54: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Optimal orthogonal drawings ?

Optimal orthogonal drawing

planar graph

Page 55: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

a 2-bend orthogonal drawing

Optimal orthogonal drawing

1-connected SP graph

not optimal

one bend

bend

not optimal

one bend

bend

Is this optimal ?

∃a one-bend orthogonal drawing ?

Page 56: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Optimal orthogonal drawing

one bendno bendoptimal not optimal

bend

∃a one-bend orthogonal drawing ?

1-connected SP graph

Page 57: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Yes

one bend

one bendno bendoptimal not optimal

bendbend

∃a one-bend orthogonal drawing ?

Is this optimal ?

∃a 0-bend orthogonal drawing ?

Page 58: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

orthogonal drawings

Optimal orthogonal drawing

0 bend

optimal

∃a 0-bend orthogonal drawing ?

1-connected SP graph

Page 59: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

0 bend

Optimal orthogonal drawing

optimal

0 bend

optimal

∃a 0-bend orthogonal drawing ?

orthogonal drawings

1-connected SP graph

Page 60: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Optimal orthogonal drawing

No

optimal

no bend

optimal

no bend

crossing crossing

∃a 0-bend orthogonal drawing ?

1-connected SP graph

Page 61: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

one bendoptimal

bendbend

two bends

bend

1-connected SP graph

Page 62: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

An optimal orthogonal drawing of a biconnected SP graph G of Δ≦3 can be found in linear time.

Theorem 1Conclusions

Our algorithm works well even if G is not biconnected.

min # of bends

min # of bends=

1-connected SP graph

Page 63: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Conclusions

bend(G) ≦ (n+4)/3 for SP graphs G of Δ≦3

Our algorithm works well even if G is not biconnected.

Best possible

bend(G)= (n – 8)/3 + 4 = (n +4)/3

bend

bend bend

bend

bendbendbend

Page 64: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Is there an O(n)-time algorithm to find an optimal orthogonal drawing of G ?

For series-parallel graphs G with Δ=4

open

s t s t s t

s t s t

s toptimal I-shapeoptimal L-shape

no optimal U-shape

Page 65: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Optimal drawing

Page 66: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Our Main Idea

2-legged SP graph

A SP graph G is 2-legged if n(G) 3 and ≧ d(s)=d(t)=1 for the terminals s and t.

s t

Page 67: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Our Main Idea

2-legged SP graph

A SP graph G is 2-legged if n(G) 3 and ≧ d(s)=d(t)=1 for the terminals s and t.

s t

Definition of I- , L- and U-shaped drawings

L-shape U-shape

terminals are drawn on the outer face;the drawing except terminals intersects neither the north side nor the south side I-shape

I-shape

I-shape

Page 68: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

terminals are drawn on the outer face;the drawing except terminals intersects neither the north side nor the east side

Our Main Idea

2-legged SP graph

A SP graph G is 2-legged if n(G) 3 and ≧ d(s)=d(t)=1 for the terminals s and t.

Definition of I- , L- and U-shaped drawings

I-shape L-shape U-shape

s

L-shape

tL-shapeL-shape

Page 69: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

terminals are drawn on the outer face;the drawing except terminals doesn’t intersect the north side

Our Main Idea

2-legged SP graph

A SP graph G is 2-legged if n(G) 3 and ≧ d(s)=d(t)=1 for the terminals s and t.

st

Definition of I- , L- and U-shaped drawings

I-shape L-shape U-shape

U-shape tnot U-shapeU-shape

Page 70: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Lemma 2

The following (a) and (b) hold for a 2-legged SP graph Gof Δ 3 unless ≦ G has a diamond: (a) G has three optimal I-, L- and U-shaped drawings (b) such drawings can be found in linear time.

optimal U-shaped drawings

optimal I-shaped drawings

Page 71: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Lemma 2

The following (a) and (b) hold for a 2-legged SP graph Gof Δ 3 unless ≦ G has a diamond: (a) G has three optimal I-, L- and U-shaped drawings (b) such drawings can be found in linear time.

optimal

I-shape L-shape

optimal

U-shape

optimal

Page 72: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Definition of Diamond Graph

(a)

if are diamond graphs,

is a diamond graph.

then is a diamond graph

A Diamond graph is recursively defined as follows:

(b)

a path with three vertices

Page 73: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Definition of Diamond Graph

(a)

if are diamond graphs,

is a diamond graph.

then is a diamond graph

A Diamond graph is recursively defined as follows:

(b)

a path with three edges

Page 74: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Diamond Graph

(a) is a diamond graph.

If and are diamond graphs, (b)

then is a diamond graph

Page 75: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Diamond Graph

(a) is a diamond graph.

If and are diamond graphs, (b)

then is a diamond graph

Page 76: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

If G is a diamond graph, then (a) G has both a no-bend I-shaped drawing and a no-bend L-shaped drawing

(b) every no-bend drawing is either I-shaped or L-shaped.

Lemma 1

I-shape

L-shape

∃no-bend U-shaped drawing ?

NO

1-bend U-shaped drawing

Page 77: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Lemma 2

The following (a) and (b) hold for a 2-legged SP graph Gof Δ≦3 unless G is a diamond graph (a) G has three optimal I-, L- and U-shaped drawings (b) such drawings can be found in linear time.

I-shape

L-shape

diamond graph

no-bend drawing I-shapeL-shape

not a diamond graph

U-shape

Page 78: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Known results

In the fixed embedding setting:

Min-cost flow problem

n : # of verticesn : # of verticesFor plane graph:

O(n2logn) time R. Tamassia, 1987

Page 79: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Known results

In the fixed embedding setting:

improved

n : # of verticesn : # of verticesFor plane graph:

O(n2logn) time R. Tamassia, 1987O(n7/4 logn) time A. Garg, R. Tamassia, 1997

Page 80: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Known results

In the fixed embedding setting:For plane graph:

O(n2logn) time R. Tamassia, 1987O(n7/4 logn) time A. Garg, R. Tamassia, 1997

In the variable embedding setting:NP-complete for planar graphs of Δ≦4

A. Garg, R. Tamassia, 2001

Page 81: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Known results

In the fixed embedding setting:For plane graph:

O(n2logn) time R. Tamassia, 1987O(n7/4 logn) time A. Garg, R. Tamassia, 1997

In the variable embedding setting:NP-complete for planar graphs of Δ≦4

A. Garg, R. Tamassia, 2001

If Δ≦3, O(n5logn) time D. Battista, et al. 1998

Page 82: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Lemma 3

Every biconnected SP graph G of Δ≦3 has one of thefollowing three substructures: (a) a diamond C (b) two adjacent vertices u and v s.t. d(u)=d(v)=2 (c) a complete graph K3.

(a) G

Page 83: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Proof

G G

bend(G) bend(≦ G )

Given an optimal drawing of G

Page 84: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Proof

G G

bend(G)≧bend(G )

Given an optimal drawing of G

Case 1: bend( ) = 0

Case 2: bend( ) = 1

Case 3: bend( ) 2≧omitted

Page 85: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Lemma 1

Every biconnected SP graph G of Δ≦3 has one of thefollowing three substructures: (a) a diamond (b) two adjacent vertices u and v s.t. d(u)=d(v)=2 (c) a complete graph K3.

u v

G

u v

G G

bend(G)=bend(G )

(Our Main Idea)

No diamonds

∃an optimal U-shape drawing

Page 86: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

G

Lemma 2

For each SP graph G If n ≧ 4, Δ≦3 and d(s)=d(t)=1, then ∃an optimal U-shape drawing

u v

G

u v

G

bend(G)=bend(G )

No diamonds

∃an optimal U-shape drawing

s t

optimal U-shaped drawing

s t

G

Page 87: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Lemma 1

Every biconnected SP graph G of Δ≦3 has one of thefollowing three substructures: (a) a diamond (b) two adjacent vertices u and v s.t. d(u)=d(v)=2 (c) a complete graph K3.

K3

G G

bend(G)=bend(G )+1

(Our Main Idea)

No diamonds G

∃an optimal U-shape drawing

Page 88: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Lemma 2

K3

G G G

bend(G)=bend(G )+1

No diamonds G

∃an optimal U-shape drawing

For each SP graph G If n ≧ 4, Δ≦3 and d(s)=d(t)=1, then ∃an optimal U-shape drawing

s t

optimal U-shaped drawing

s t

Page 89: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

Optimal orthogonal drawings ?

Optimal orthogonal drawing

1-connected planar graphnon

Page 90: Orthogonal Drawings of Series-Parallel Graphs Joint work with Xiao Zhou by Tohoku University Takao Nishizeki

deg=1 deg=1

2-leg SP

Find an opt & U-shape

U-shape not U-shapeU-shape

parallel connectionseries connection

delete edge

Case (b): ∃