prev

next

out of 12

View

216Download

0

Embed Size (px)

8/10/2019 Distributed Graph Coloring

1/12

DISTRIBUTED GRAPH COLORING

Project Report Submitted

By

Abhijeet Sharma (14535001)

Ajay Yadav (14535002)

Amala Thampi (14535003)

Amit Kewal (145350004)

Ankur Tagra (14535005)

Anoop Kumar Singh(14535006)

Master of Technology ( 1styear ) CSE

Under the guidance of

Dr. Rajdeep Niyogi

Department of Computer Science and Engineering

Indian Institute of Technology Roorkee

Department of Computer Science and Engineering

Indian Institute of Technology , Roorkee

Roorkee-247667, India

8/10/2019 Distributed Graph Coloring

2/12

Acknowledgement

The satisfaction and euphoria that accompanies the successful completion of this task would be

Incomplete without the mention of the people who made it possible. Their constant guidance and

encouragement crowned our effort with successIt is a great pleasure to express our sincere thanks to Prof. Rajdeep Niyogi, Department of

Computer Science and Engineering, IIT Roorkee, for her encouragement valuable suggestions,

intellectual, influence and constant support during the course of the project.

We would like to express our gratitude toward our fellow classmates who helps us to complete

this project.

Date: 27 October 2014 Abhijeet Sharma (14535001)

Place: Roorkee Ajay Yadav (14535002)

Amala Thampi (14535003)

Amit Kewal (145350004)

Ankur Tagra (14535005)

Anoop Kumar Singh(14535006)

8/10/2019 Distributed Graph Coloring

3/12

[DISTRIBUTED GRAPH COLORING] 2014

Department of Computer Science and Engineering , IIT Roorkee 1

Distributed Graph Coloring

Abstract:We consider generalized colouring of a weighted Graph in a distributed setting, where each

node in the graph is represented by an independent agent. The target is to minimize theweight of edges connecting same-colour nodes. To avoid Getting stuck in a not-too-good

local optimum, we approach this Problem by finding the colourable subgraph with the

maximum Weight subset of edges. The agents run a basic distributed Graph colouring

algorithm, and an algorithm for adding and removing edges, operating on different time

scales. As basic Distributed algorithms to colour graphs we use distributed local Search

algorithms enabling plateau walks, together with a noise Strategy to escape local minima. We

evaluate performance in a setting inspired by self-organized resource allocation in a wireless

network, and show that a distributed algorithm finding a colourable subgraph can outperform

distributed greedy local search. As a related sub-problem, we investigate a procedure of

adding edges to random planar graphs, keeping the colourability.

Randomized distributed coloring:[2]

It has been proved that Randomized algorithm does not help in distributed coloring of graph.

However It is implicitly assumed that a k-round randomized coloring algorithm colors a

graph with s colors if algorithm always stops with a proper s-coloring after at most k rounds.

The proof does not hold if number of color is s in expectation or more probability or number

of rounds is exactly k. if we assume that number of color i.e. m is function of n then

randomization can help. Algorithm 1 describes a randomized algorithm which colors a given

network graph in one round.

Algorithm 1

Randomized coloring in one round (code for node v)

1: choose color tvuniformly at random from {1, . . . , /ln n};

2: send ID(v) and tvto all neighbours;

3: let Gtvbe the graph induced by all nodes u with tu= tv;

4: let tvbe the maximum degree of Gtv;

5: compute O(2tvlogm)-coloring of Gtv => color yv;

6: color xv:= yv[/ ln n] + tv 1

Distributed Graph Coloring in a few rounds[1]

The paper focuses on the problem that how many colors would be required by a Distributed

Graph Coloring algorithm to color a graph when only k rounds are available. The paper

proposes an algorithm that runs in O(k) rounds where k is bounded below by (log log n) and

bounded above by O(log n) and uses O(a.n1/k) colors where n is the number of vertices and a

is the arboricity of the graph.

Graph coloring concerns the problem of assigning colors to the nodes of a graph such thatadjacent nodes do not share the same color. This problem is at the heart of several problems

8/10/2019 Distributed Graph Coloring

4/12

[DISTRIBUTED GRAPH COLORING] 2014

Department of Computer Science and Engineering , IIT Roorkee 2

arising in wireless ad hoc networks. Examples are TDMA slot assignment, wakeup

scheduling, and data collection. In these cases, time required to arrive at the solution is given

higher priority compared to the optimality of the solution so that higher-order tasks such as

routing and scheduling are minimally affected. The algorithm is presented that, for any k 2

log log n, runs in O(k) rounds on G to produce an (i) O(delta)-coloring when delta (max{k

n2/k^2

log1+1/k

n, 2k}) and an (ii) O(deltan

2/k^2)-coloring when delta(max{k log

1+1/kn, 2

k})

and the solution is more effective when delta

8/10/2019 Distributed Graph Coloring

5/12

[DISTRIBUTED GRAPH COLORING] 2014

Department of Computer Science and Engineering , IIT Roorkee 3

Consider two neighbors v and w such that w is an out-neighbor of v. In each round of the

algorithm each node tentatively picks a color from its palette and then coordinates with

neighbors to resolve conflicts in color choices. Suppose that both nodes v and w tentatively

choose the same color c. After one round of communication, node v detects an out-neighbor

with a conflicting color choice and uncolors itself. Node w ignores choices made by in-

neighbors and can finalize its choice of color c provided it has no out-neighbor that has

chosen color c in this round. Node u updates its palette by removing the colors permanently

chosen by its out-neighbors in the current round and communicates with its in-neighbors.

When OrientedRandColor terminates, the coloring may be partial, i.e., not all nodes may

have been assigned a color because k rounds may not suffice to color all vertices in G. It may

also result in improper coloring where 2 neighbors in the graph are colored with the same

color.

Example for OrientedRandColor Algorithm:

1

2

4

3 X X

5|X

1stRound :

Now 5 is randomly selected from Cu={1,2,3,4,5} and 5 will select color X then it will send X

to all the adjacent nodes. and let 2 and 4 already have different color Y and Z therefore they

will make Y and Z permanent and 2 will send Y to its adjacent uncolored nodes but all

adjacent nodes of 2 are colored hence it will not send any color and 4 will send Z to its

adjacent uncolored nodes i.e. 1 . 5, 2 and 4 will be deleted from Cu and hence Cu={1,3}.

Algorithm OrientedRandColor (k, Cu)

Comment: Cuis node us palette of colors

Begin-Algorithm1. for i := 1 to k do

2. Node u chooses a color cufrom Cu, uniformly at random.

3. Node u sends cuto all of its uncolored in-neighbors

4. if every color received by node u from an out-neighbor is distinct from cu, then

5. u makes cu its permanent color. Otherwise node u remains uncolored.

6. if u is permanently colored in Step 5 then

7. u sends it color choice to all uncolored in-neighbors

8. Node u deletes from Cuall colors assigned permanently to out-neighbors

9. end-for

End-Algorithm

8/10/2019 Distributed Graph Coloring

6/12

[DISTRIBUTED GRAPH COLORING] 2014

Department of Computer Science and Engineering , IIT Roorkee 4

Z

1

2|Y

4|Z

3 X X

5|X

Now 1 will receive Z since now 1 has no color therefore it will uncolored again.

2nd

Round:

Now we randomly select u i.e. 3 and Cu={1,3}. Let 3 also select Y then it will send color Y

to uncolored adjacent nodes i.e. 1 since 1 is uncolored therefore it will not assign any color to

it and 3 will be deleted from Cu ,now Cu=={1}.

Z

1

2|Y

Y 4|Z

3|Y X X

5|X

3rd

Round:

Now we select 1 and send color X and will not send to anyone since all adjacent nodes are

permanently colored.

Z1|X

2|Y

4|Z

3|Y X X

5|X

8/10/2019 Distributed Graph Coloring

7/12

[DISTRIBUTED GRAPH COLORING] 2014

Department of Computer Science and Engineering , IIT Roorkee 5

2 Important lemmas are stated regarding the partial and improper coloring of vertices

during OrientedRandColor algorithm.

Lemma 1: If OrientedRandColor assigns the same color to two neighbors in G, then it does

so in different rounds.Lemma 2: Suppose that initially |Cu| delta 1+1/k n2/k^2 for all nodes u. After

OrientedRandColor has terminated, w.h.p., every oriented uncolored path in G has length at

most k.

Palette Inflation Technique[1]

Let the k rounds of OrientedRandColoralgorithm have completed and still some nodes are

left uncoloured. According to Lemma 2, each acyclic oriented path in graph have length

atmost k. After 1 round, every oriented uncoloured path has length atmost k-1. Similarly after

t rounds, oriented uncoloured path has length atmost k-t. Thus atmost k extra rounds are

required after the algorithm completes to color the graph thus leading to a total of 2k rounds

and can be colored using a(kdelta1+1/k

n2/k^2

) colors. Palette inflation technique leads to

an additional k factor to appear in the palette size. Technique employed in Grable and

Panconesi can be used to reduce the k-factor in palette size.

Each node starts the dozing phase with the palette {1, 2, . . . ,delta/k}. In each round, each as

yet uncolored node chooses to wake up with a probability p and if the node wakes up, it picks

a tentative color from amongst the available colors in its palette uniformly at random and

independent of the choices of other nodes. Color conflicts are resolved in the usual manner

and palettes are updated. The dozing phase runs for O(k) rounds. The key innovation of

Grable and Panconesi is to start the wake-up probability p at 1/k and then increase it in each

round. This ensures that in each round an appropriate fraction of the vertices are competing

for the colors in the color palettes. The manner in which p increases ensures that p equals 1 in

e * k rounds and this brings the algorithm to the trivial phase.

Distributed Generalized Graph Colouring[4]Introduction:The problem of generalized graph coloring is defined on a weighted graph with integer

weights assigned to the edges. The target is to find a coloring that minimizes the total weightof edges connecting nodes with the same color. Local search methods can be used to solve

the generalized graph coloring problem. We search for the minimum weighted coloring by

solving the maximum weight colourable subgraph problem. This problem is defined as:

Given a number of color, and a complete graph, find the maximum subgraph that is

colourable with this number of colors.

System model:

The generalized graph vertex coloring problem can be formulated as follows. Let a graph (V,

E) of vertices, v belong to V and edges e belong to E connecting two vertices be given. The

vertices consist, for example, of collections of wireless network elements which are able to

8/10/2019 Distributed Graph Coloring

8/12

[DISTRIBUTED GRAPH COLORING] 2014

Department of Computer Science and Engineering , IIT Roorkee 6

determine their resource usage on a much shorter time scale than that of the inter- node

communication, and may be interchangeably called nodes, or cells. An edge connects two

nodes if there is a conflict between the nodes when they use the same resource. In other

words ,the edge(u,v) belong to E if communication within the nodes v belong to V and u

belong to V would interfere with each other if they use the same channel. there is fixed

number of resources or color ,which are considered indistinguishable. The objective ofgeneralized graph coloring is to find the allocation of resources so that the total interference

in the colored network is minimized.

Semi greedy Distributed Local Search (SDLS)

Algorithm 4:

In SDLS each node periodically a routine which works as follows

1. Compute the number of neighbours Nold using the same resources.

2.Pick a resource not currently used uniformly at random.3.Compute the number of neighbours Nnew using this newly picked resource.

4. If Nnew

8/10/2019 Distributed Graph Coloring

9/12

[DISTRIBUTED GRAPH COLORING] 2014

Department of Computer Science and Engineering , IIT Roorkee 7

which are not adjacent in the neighbourhood graph. They may choose the same color. In a

one-round algorithm, every node can send its initial color to all its neighbours. All nodes then

have to decide on a new color. Hence, every node has to choose a color based on its own

color and the colors of its neighbours only. After one round, the view of each node is a pair

(xv, x(v)) where xv is the initial color of v and where x(v) is the multi-set of the colors of

the neighbours of v. The value of xv and all elements of x(v) are integers between 1 and m.If we only consider graphs with degrees at most , we have |x(v)| and because we startwith a valid coloring, we also have xvbelong to x(v). There is a network graph with initial

coloring in which two one-hop views (xu, x(u)) and (xv, x(u)) are the one-hop views of

adjacent nodes if and only if xubelong to x(v) and xvbelong to x(u).

Figure: Looking into one round neighbourhood graph N1(6,3) of 6-colored degree 3 graphs .

Nodes {x,{x1,x2,x3}} depicted as star graphs with centre color x and leaf color x1,x2,x3.

we will discuss here the vertex coloring problem in a distributed network. in a distributed

network, we know that there is no shared memory. each node communicates to other nodes

via message passing. We want these nodes to compute a coloring of the associated graph.

A better approach to Distributed graph coloring :[3]

Algorithm 3:

Each vertex has three parameters:

degree: deg(v), random value: rndvalue(v),

palette of forbidden colors, which were used by its neighbors: usedcolor(v) (initially

empty).

Parameters: deg(v) and rndvalue(v) determine the order of coloring. Let v1; v belong to V .

We say that v1 has a higher priority then v2 if:

deg(v1)>deg(v2)

or

deg(v1)=deg(v2) and rndvalue(v1)>rndvalue(v2)

8/10/2019 Distributed Graph Coloring

10/12

[DISTRIBUTED GRAPH COLORING] 2014

Department of Computer Science and Engineering , IIT Roorkee

During each round every uncolored vertex v executes the following five steps:

1. Choose parameter rndvalue(v) 2 [0::1].

2. Send to all neighbors the following parameters: deg(v), rndvalue(v), and the first legal

color (not on the list of forbidden colors).3. Compare its own parameters with these received from the neighbors and check which

vertex has the highest priority.

4. If vertex v has the highest priority, keep the proposed color and stop.

5. If not, update list usedcolor(v).

Example:Initially:

After round 1:

8/10/2019 Distributed Graph Coloring

11/12

[DISTRIBUTED GRAPH COLORING] 2014

Department of Computer Science and Engineering , IIT Roorkee !

After round 2:

After round 3:

In this example, initially all the nodes and their links are given. First of all degree of every

node is calculated.

Then in first round node with highest degree is calculated and then it is assigned a color in

forbidden list of colors. i-e V1. Now adj.(V1)=V2,V3,V4,V5,V6 update their forbidden

colors.

In second round, V2,V4,V5 has degree 3. Rndvalue breaks the tie. And V5 is selected. Color

assigned to V5 is 2. V2 and V4 update their forbidden list of colors by 2. Also V3 and V6 are

independent so they are assigned color 2.

In third round, V2 and V4 are independent, so they update their color as 3.

8/10/2019 Distributed Graph Coloring

12/12

Bibliography:[1] K. Kothapalli, and S. Pemmaraju. Distributed graph coloring in a few rounds. In Proc. Of

the 30th ACM Symp. on Principles of Distributed Computing, pages 31-40,2011.

[2] F. Kuhn, and R. Wattenhofer. On the complexity of distributed graph coloring. In Proc. of

the 25th ACM Symp. on Principles of Distributed Computing , pages 715 ,2006.

[3] Kubale, M. and Kuszner, L.: A better practical algorithm for distributed graph coloring.

Proc. of IEEE International Conference on Parallel Computing in Electrical Engineering

(2002) 7275.

[4] J.-M. Koljonen, M. Alava, M. Peltomki, and O. Tirkkonen, Distributed generalized

graph coloring, in Proc. 4th IEEE Int. Conf. Self- Adapt. Self-Organizing Syst. , Sep. 2010,

pp. 174183.