21
Advances on Testing C- Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University Roma Tre) Fabrizio Frati (University of Sydney) Karsten Klein (Monash University)

Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

Embed Size (px)

Citation preview

Page 1: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

Advances on Testing C-Planarity of Embedded Flat Clustered Graphs

Markus Chimani (Osnabrück University)

Joint work withGuiseppe Di Battista (University Roma Tre)

Fabrizio Frati (University of Sydney)

Karsten Klein (Monash University)

Page 2: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

2

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

Clustered Planarity (C-Planarity)

30

74

1

8

52 6 9

C = (G,T)

3

0

7

4

1

8

5

2

6

9

3

0

7

4

1

8

5

2

6

9

Complexity of c-planarity testing

c-connected: O(|V|) [Dahlhaus 98]non c-connected: P? NP? open for ~20 years…

Page 3: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

3

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

Complexity for special cases

Polynomial cases…• C-connected [Feng et al. 95], [Dahlhaus 98]

• Completely c-connected [Cornelsen, Wagner 06]

• Almost c-connected [Gutwenger et al. 02]

• Extrovert [Goodrich et al. 05]

• “Cycles of Clusters” [Cortese et al. 05]

• and many more…

Unfortunately, most cases are very restricted and/or unnatural…Complexity even unknown for natural, seemingly simple subcases…• What if G is already embedded?• What if the cluster hierarchie is flat, i.e, only one level of clusters?• What if both?

Page 4: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

4

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

Now: Flat embedded clustered graphs• One level of clusters (= no nested clusters)• G is embedded.• Does there exist a drawing of the cluster regions such that the resulting

drawing is c-planar?

Known polynomial subcases:• Maximum face-size at most 5 or “single conflict” graph [Di Battista, Frati 09]• At most two components per cluster-induced graph [Jelinek et al. 09]• Clustered cycles:

3 clusters [Cortese et al. 05], 3 vertices/cluster [Jelinkova at al. 09]

Flat & Embedded

3

0

7

4

1

8

5

2

6

9

Page 5: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

5

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

Saturators

(Well known) idea: Flat embedded clustered graphs1. Each node starts within its own cluster region.2. Merge cluster regions along edges within the same cluster.

Step 2 is rather trivial to do in polynomial time…

3

0

7

4

1

8

5

10

9

6

YObserveNo nodes of same cluster are adjacent after Step 2.

2

X

Page 6: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

6

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

Saturators

(Well known) idea: Flat embedded clustered graphs1. Each node starts within its own cluster region.2. Merge cluster regions along edges within the same cluster.3. Merge cluster regions of same cluster by adding

connectivity-establishing edges (con-edges) Saturator

Step 2 is rather trivial to do in polynomial time……but how to choose the con-edges in Step 3?

7

1

8

56

Y2

X

Page 7: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

7

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

Saturators

(Well known) idea: Flat embedded clustered graphs1. Each node starts within its own cluster region.2. Merge cluster regions along edges within the same cluster.3. Merge cluster regions of same cluster by adding

connectivity-establishing edges (con-edges) Saturator

Step 2 is rather trivial to do in polynomial time……but how to choose the con-edges in Step 3?

7

1

8

56

Y2

X

AimFor each cluster, pick aspanning tree from itscon-edges, s.t. the differentspanning trees do not cross.

Page 8: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

8

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

Saturators

(Well known) idea: Flat embedded clustered graphs1. Each node starts within its own cluster region.2. Merge cluster regions along edges within the same cluster.3. Merge cluster regions of same cluster by adding

connectivity-establishing edges (con-edges) Saturator

Step 2 is rather trivial to do in polynomial time……but how to choose the con-edges in Step 3?

7

1

8

56

Y2

X

AimFor each cluster, pick aspanning tree from itscon-edges, s.t. the differentspanning trees do not cross.

Page 9: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

9

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

Single-conflict graph

“Single conflict graph”If every con-edge is involved in at most one crossing, the problem is polynomial time solvable [Di Battista, Frati 09]

So, this is not the case here…

7

1

8

56

Y2

X

Page 10: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

10

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

k

l

2 vertices per cluster on each face

Our restriction:At most two vertices per cluster on each face.(“Single-conflict” graphs are a subset of those graphs)

f

d

i

c

a e

b

j

g

h

k

Page 11: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

11

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

k

l

Not c-planar…

Here: By simple deduction, this graph is not c-planar

f

d

i

c

a e

b

j

g

h

k

Our algorithmAutomatically find a chain of deduction arguments to answer the c-planarity question.

Page 12: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

12

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

Algorithm – Overview

Sequence of 4 Tests (detect non-c-planarity) and8 Simplifications (shrink instance)

(1) if each remaining con-edge has at most one crossing thenreturn ALGORITHMFORSINGLECONFLICT [Di Battista, Frati 09]

(2) if Test1 = true then return “non-c-planar”(3) if Simpl1 applicable then perform Simpl1 & goto (1)(4) if Test2 = true then return “non-c-planar”(5) if Simpl2 applicable then perform Simpl2 & goto (1)(6) if Simpl3 applicable then perform Simpl3 & goto (1)(7–12) …(13) perform Simpl8 & goto (1) //always applicable of we got

that far

Page 13: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

13

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

Algorithm – Details

bd

ca

Let A[] the multigraph of all con-edges for cluster .

The first couple of tests & simplifications are trivial, e.g.• Test. Disconnected A[] No spanning tree non-c-planar

• Simplification. Bridge in A[] Merge vertices

cf

d

ba e

g

cdf

ba e

g

Page 14: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

14

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

Algorithm – Details

The next ones aren’t too hard either, e.g.• Test. Cyclic crossing sequence of odd length.

r

R

o

g

O

G

Page 15: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

15

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

The final ones are harder and more cumbersome – but interesting, e.g.• Simplifications 6–8. “-donut”

Simplification 6: If isomorphicconflicting structures at two spokes

remove one of the spokes and pick the crossing edges

Algorithm – Details

“spokes”

Page 16: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

16

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

Algorithm

Wrapping upEventually (after several applications of the various simplifications),all -donuts vanish.Þ No con-edges with multiple crossings anymoreÞ Single-conflict graph solvable in polynomial time.

Since each test and simplification requires only polynomial time:

Theorem. The above algorithm decides c-planarity for flat embedded clustered graphs with at most two vertices per cluster on each facecorrectly in polynomial time.

Thank you

Page 17: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

17

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

The road ahead…

What’s the problem with more vertices of the same cluster on a common face?

Page 18: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

18

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

The road ahead…

What’s the problem with more vertices of the same cluster on a common face?

Page 19: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

19

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

The road ahead…

What’s the problem with more vertices of the same cluster on a common face?

Page 20: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

20

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

The road ahead…

What’s the problem with more vertices of the same cluster on a common face?

Page 21: Advances on Testing C-Planarity of Embedded Flat Clustered Graphs Markus Chimani (Osnabrück University) Joint work with Guiseppe Di Battista (University

21

markus . chimani @ uni - osnabrueck . de C-Planarity @ Flat Embedded Graph Drawing 2014

The road ahead…

What’s the problem with more vertices of the same cluster on a common face?

Anyhow… is it possible to always deal with richer faces efficiently?

Thank you