45
On the complexity of turning a graph into the analogue of a clique Julien Bensmail 1 Romaric Duvignau 1 Sergey Kirgizov 2 1 Combinatoire et Algorithmique LaBRI (Université de Bordeaux × CNRS) 2 Complex Networks LIP6 (UPMC × CNRS) 30 June – 4 July 2014

Slides

Embed Size (px)

Citation preview

Page 1: Slides

On the complexity of turning a graph intothe analogue of a clique

Julien Bensmail 1 Romaric Duvignau 1

Sergey Kirgizov 2

1Combinatoire et Algorithmique ⊂ LaBRI ⊂ (Université de Bordeaux × CNRS)

2Complex Networks ⊂ LIP6 ⊂ (UPMC × CNRS)

30 June – 4 July2014

Page 2: Slides

Gorientation7−−−−−−−→ −→G

Page 3: Slides

Sometimes−→G is o-clique

Page 4: Slides

Does such orientation existfor a given graph?

Page 5: Slides

How difficult is it to findthe answer?

Page 6: Slides

Outline

1 Some definitions

2 Can a given graph be turned into o-clique?

3 Family of related problems

4 Open question

3

Page 7: Slides

Definitions:orientations, o-cliques, oriented distances and diameters,Klostermeyer-MacGillivray lemma

Page 8: Slides

Orientation

Gorientation7−−−−−−→ −→G is an assignment of a direction to each edge

from undirected graph.

••

••

••

o1

o2

4

Page 9: Slides

Oriented chromatic number

χo(−→G ) is the minimal number of colors such that:

1 Colors of adjacent vertices are different

• •

2 All arcs between two colors have the same direction• •

• •

• •

5

Page 10: Slides

O-cliqueoriented analogue of usual clique

Undirected

G is clique ⇐⇒ χ(G ) = n

••

Oriented−→G is o-clique ⇐⇒ χo (−→G ) = n

• •

••

• • •

6

Page 11: Slides

Oriented distances and diameters

Strong

dists = max

(dist(u, v )dist(v , u)

)

diams = maxu,v∈−→G

dists (u, v )

Weak

distw = min

(dist(u, v )dist(v , u)

)

diamw = maxu,v∈−→G

distw (u, v )

7

Page 12: Slides

O-cliques & weak diameter

−→G is o-clique

χo (−→G ) = n diamw (−→G ) ≤ 2

[Klostermeyer, MacGillivray, 2004]

8

Page 13: Slides

Decision problem:Does G admit a 2-weak orientation?

Page 14: Slides

Does G admit a 2-weak orientation?

An orientation G 7→ −→G is called 2-weak when diamw (−→G ) ≤ 2

• • • ?

9

Page 15: Slides

Does G admit a 2-weak orientation?

An orientation G 7→ −→G is called 2-weak when diamw (−→G ) ≤ 2

• • • • • •

9

Page 16: Slides

Does G admit a 2-weak orientation?

An orientation G 7→ −→G is called 2-weak when diamw (−→G ) ≤ 2

• • •

••

• • •

?

9

Page 17: Slides

Does G admit a 2-weak orientation?

An orientation G 7→ −→G is called 2-weak when diamw (−→G ) ≤ 2

• • •

••

• • •

••

••

••

••

9

Page 18: Slides

Does G admit a 2-weak orientation?

An orientation G 7→ −→G is called 2-weak when diamw (−→G ) ≤ 2

• • •

••

• • •

••

••

••

••

diamw =∞ for any orientation of a claw9

Page 19: Slides

2-weak orientation is NP-complete

2-weak orientation is in NP

We just run BFS from all vertices to check whetherdiamw (−→G ) ≤ 2 or not.

2-weak orientation is NP-hard

We prove this by reduction from the monotone versionof Not-All-Equal 3SAT

10

Page 20: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

Monotone Not-All-Equal 3SAT

F is 3CNF formula without negations.Example: (x1 ∨ x2 ∨ x3) ∧ (x3 ∨ x3 ∨ x4) ∧ . . .Is F satisfiable in such way that no clausehave all literals set to same value?

NP-complete even when in every clause all variablesare different

11

Page 21: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

Monotone Not-All-Equal 3SAT

F is 3CNF formula without negations.Example: (x1 ∨ x2 ∨ x3) ∧ (x3 ∨ x3 ∨ x4) ∧ . . .Is F satisfiable in such way that no clausehave all literals set to same value?

NP-complete even when in every clause all variablesare different

11

Page 22: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

Reduction overview:

F G

2this diagram commutes

F = nae-3-formulaeG = graphs2 = {good, bad}

12

Page 23: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

F 7→ G

F is nae-satisfiable ⇐⇒ ∃−→G : diamw (−→G ) ≤ 2

(•, •′) is a representative pair from G

(•, •′) is a non-representative pair from G

∃−→G : distw (•, •′) ≤ 2 ⇐⇒ F is nae-satisfiable

∃−→G : distw (•, •′) ≤ 2 by construction of G

13

Page 24: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

Variable gadget:

xi 7−−→ •vi •

v ′i

xi = TRUE 7−−→ •vi •

v ′i

xi = FALSE 7−−→ •vi •

v ′i

14

Page 25: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

Gadget for clause:

Ct = xi ∨ xj ∨ xk 7−−→

•vi •

v ′i •vi ,t

•vj

•v ′j

•vj ,t

•vk •

v ′k •vk,t

•wt

•w ′t

Ct is nae-satisfiable ⇐⇒ ∃−→G : distw (•, •′) ≤ 2

Using w ′t we can make distw (•, •′) ≤ 2when it is needed

15

Page 26: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

Gadget for clause:

Ct = xi ∨ xj ∨ xk 7−−→

•vi •

v ′i •vi ,t

•vj

•v ′j

•vj ,t

•vk •

v ′k •vk,t

•wt

•w ′t

Ct is nae-satisfiable ⇐⇒ ∃−→G : distw (•, •′) ≤ 2

Using w ′t we can make distw (•, •′) ≤ 2when it is needed

15

Page 27: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

Gadget for clause:

Ct = xi ∨ xj ∨ xk 7−−→

•vi •

v ′i •vi ,t

•vj

•v ′j

•vj ,t

•vk •

v ′k •vk,t

•wt

•w ′t

Ct is nae-satisfiable ⇐⇒ ∃−→G : distw (•, •′) ≤ 2

Using w ′t we can make distw (•, •′) ≤ 2when it is needed

15

Page 28: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

Gadget for clause:

Ct = xi ∨ xj ∨ xk 7−−→

•vi •

v ′i •vi ,t

•vj

•v ′j

•vj ,t

•vk •

v ′k •vk,t

•wt

•w ′t

Ct is nae-satisfiable ⇐⇒ ∃−→G : distw (•, •′) ≤ 2

Using w ′t we can make distw (•, •′) ≤ 2when it is needed

15

Page 29: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

Gadget for clause:

Ct = xi ∨ xj ∨ xk 7−−→

•vi •

v ′i •vi ,t

•vj

•v ′j

•vj ,t

•vk •

v ′k •vk,t

•wt

•w ′t

Ct is nae-satisfiable ⇐⇒ ∃−→G : distw (•, •′) ≤ 2

Using w ′t we can make distw (•, •′) ≤ 2when it is needed

15

Page 30: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

Gadget for clause:

Ct = xi ∨ xj ∨ xk 7−−→

•vi •

v ′i •vi ,t

•vj

•v ′j

•vj ,t

•vk •

v ′k •vk,t

•wt

•w ′t

Ct is nae-satisfiable ⇐⇒ ∃−→G : distw (•, •′) ≤ 2

Using w ′t we can make distw (•, •′) ≤ 2when it is needed

15

Page 31: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

Gadget for clause:

Ct = xi ∨ xj ∨ xk 7−−→

•vi •

v ′i •vi ,t

•vj

•v ′j

•vj ,t

•vk •

v ′k •vk,t

•wt

•w ′t

Ct is nae-satisfiable ⇐⇒ ∃−→G : distw (•, •′) ≤ 2

Using w ′t we can make distw (•, •′) ≤ 2when it is needed

15

Page 32: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

Gadget for clause:

Ct = xi ∨ xj ∨ xk 7−−→

•vi •

v ′i •vi ,t

•vj

•v ′j

•vj ,t

•vk •

v ′k •vk,t

•wt

•w ′t

Ct is nae-satisfiable ⇐⇒ ∃−→G : distw (•, •′) ≤ 2

Using w ′t we can make distw (•, •′) ≤ 2when it is needed

15

Page 33: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

Gadget for clause:

Ct = xi ∨ xj ∨ xk 7−−→

•vi •

v ′i •vi ,t

•vj

•v ′j

•vj ,t

•vk •

v ′k •vk,t

•wt

•w ′t

Ct is nae-satisfiable ⇐⇒ ∃−→G : distw (•, •′) ≤ 2

Using w ′t we can make distw (•, •′) ≤ 2when it is needed

15

Page 34: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

Gadget for clause:

Ct = xi ∨ xj ∨ xk 7−−→

•vi •

v ′i •vi ,t

•vj

•v ′j

•vj ,t

•vk •

v ′k •vk,t

•wt

•w ′t

Ct is nae-satisfiable ⇐⇒ ∃−→G : distw (•, •′) ≤ 2

Using w ′t we can make distw (•, •′) ≤ 2when it is needed

15

Page 35: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

Gadget for clause:

Ct = xi ∨ xj ∨ xk 7−−→

•vi •

v ′i •vi ,t

•vj

•v ′j

•vj ,t

•vk •

v ′k •vk,t

•wt

•w ′t

Ct is nae-satisfiable ⇐⇒ ∃−→G : distw (•, •′) ≤ 2

Using w ′t we can make distw (•, •′) ≤ 2when it is needed

15

Page 36: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

GF is a union of clause gadgets. G = GF + smth.For any pair of vertices (u, v ) from GF we add the following:

•u

• •

• •

•v

distw (u, •) ≤ 2distw (v , •) ≤ 2

Here distw (u, v ) = 3, so we don’t break ourreduction by adding blue vertices.

16

Page 37: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

Also, for any non-representative pair of vertices (u,v) from GF

we add the following:

•u

• •

• •

•v

distw (u, •) = 1distw (v , •) = 1

Here distw (u, v ) = 2, so we ensure that the distancebetween non-representative vertices is ≤ 2

17

Page 38: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

Next, in order to ensure that ∀y ∈ GF : distw (y , •) ≤ 2we add the following:

•u

• •

• •

•v

••

• y — any other vertex from GF

distw (y , •) = 2

18

Page 39: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

Finally, turn all brown and blue vertices into one big clique,by adding all possible edges between them.

19

Page 40: Slides

2-weak orientation is NP-complete(xi ∨ xj ∨ xk ) ∧ . . . ∧ (xi ∨ xk ∨ xl ) 7→ G

∃−→G : distw (•, •′) ≤ 2 ⇐⇒ F is nae-satisfiable

∃−→G : distw (•, •′) ≤ 2

∃−→G : distw (•, •′) ≤ 2

∃−→G : distw (•, •′) ≤ 2

∃−→G : distw (•, •′) ≤ 2

∃−→G : distw (•, •′) ≤ 2

∃−→G : distw (•, •′) ≤ 2

by construction of G

F is nae-satisfiable ⇐⇒ ∃−→G : diamw (−→G ) ≤ 2

20

Page 41: Slides

Family of related problems:Does G admit an orientation G 7→ −→G such that prop(−→G )?

Page 42: Slides

Family of o-problemsDoes G admit an orientation G 7→ −→G such that prop(−→G )?

Strong orientation:

diams (−→G ) <∞ ⇐⇒ G is bridgeless [Robbins, 1939]

Linear time using Tarjan’s bridge-finding algorithm [1974]

k-strong orientation:

diams (−→G ) ≤ k

NP-complete for k = 2 [Chvátal, Thomassen, 1978]

21

Page 43: Slides

Family of o-problemsDoes G admit an orientation G 7→ −→G such that prop(−→G )?

Weak orientation:

diamw (−→G ) <∞ ⇐⇒ B-contraction(G ) is claw-free.

B-contraction means “replace allbridgeless subgraphs by vertices”

Linear time [Bensmail, Duvignau, Kirgizov 2013]

22

Page 44: Slides

Family of o-problemsDoes G admit an orientation G 7→ −→G such that prop(−→G )?

k-weak orientation:

diamw (−→G ) ≤ k

NP-complete for k ≥ 2 [Bensmail, Duvignau, Kirgizov, 2013]

Gk is a k-edge-coloured graph(e.g. 2-edge coloured graphs are just signified graphs)

∃−→G : diamw (−→G ) ≤ k ⇐⇒ ∃Gk : χk (Gk ) = n

23

Page 45: Slides

Open question:

Complexity of k-strongorientation when k > 2

Thank you for your attention

kirgizov.complexnetworks.fr/some-problems/orientation.html