Title: Approximation algorithms
1Approximation algorithms
Giorgi Japaridze Theory of
Computability
Section 10.1
2An example of an approximation algorithm
10.1.a
Giorgi Japaridze Theory of Computability
Approximation algorithms find nearly optimal
solutions. Doing so, while sufficient for most
practical purposes, can also be dramatically
easier than finding the best (truly optimal)
solutions. We will look at one example. It is
about finding a smallest vertex cover in an
undirected graph.
A On input ltGgt, where G is an undirected
graph 1. Repeat the following until all
edges in G touch a marked edge 2.
Find an edge in G untouched by any marked edge,
and mark it. 3. Output the set X of all
nodes that are endpoints of marked edges.
Obviously A runs in polynomial time (why?).
And obviously its output X is indeed a vertex
cover in G (why?). We further claim that X is no
more than twice as large as Y, where Y is the
smallest vertex cover. This is so because,
where H is the set of edges that A marks, we
have (1) X is twice as large as H, and (2) H is
not larger than Y. (1) holds because every
edge in H contributes two nodes to X. (2)
holds for the following reason. Y is a vertex
cover, so every edge in H is touched by some node
in Y. No such node touches two edges in H because
the edges in H do not touch each other. So, for
each edge of H, Y contains a different node that
touches that edge. That is, Y has at least as
many nodes as the number of edges in H.