Having trouble figuring out how to show this approximation, hoping someone could lend some advice. I'm quite new to approximation (especially with randomization) and having trouble figuring out how to narrow this down.
The problem:
Suppose we have a graph G = (V,E)
, each edge with a weight w
.
We want to color the graph with 2 colors, red
and blue
. We want to maximize the edge weight from each vertex from red
to blue
.
We randomly mark each vertex with either red
or blue
with probably 1/2
for each. The coloring is done independently of every vertex.
I need to show that this color assignment randomization algorithm is a 4-approximaton
. However, not entirely sure where to start. Anyone have any ideas?
Even the simplest greedy algorithm will produce better approximations than randomly assigning colors.
Like this:
Mark all nodes uncolored
Mark all edges unprocessed
Sort edges into decreasing weight
LOOP until all edges processed
Select heaviest unprocessed edge
IF both nodes uncoloured
color nodes on edge opposite colors
IF one node uncolored
color node opposite color to its partner
mark edge processed
ENDLOOP
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.