An Ant-Based Algorithm for the Minimum Vertex Cover Problem
An Ant-Based Algorithm for the Minimum Vertex Cover Problem
An Ant-Based Algorithm for the Minimum Vertex Cover Problem
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
3 <strong>An</strong>t-<strong>Based</strong> MVC <strong>Algorithm</strong> 12Input: Graph G = (V, E)Output: A vertex cover C of Gbegin// initialization stageC ← ∅bestC ← Vwhile a degree 1 vertex u exists // preprocessing stepv ← neighbor(u)C ← C ∪ {v}V ← V − {u, v}remove all edges incident with v from Eend-whilecopyE ← Eposition ants on randomly selected edgesinitialize <strong>the</strong> pheromone level of all verticeswhile stopping criteria not met// exploration stageE ← copyE<strong>for</strong> step = 1 to numOfSteps<strong>for</strong> each ant a // more details in Figure 3.4select an edge (u, v) <strong>for</strong> <strong>the</strong> ant a to move to and move it <strong>the</strong>reupdate <strong>the</strong> pheromone level <strong>for</strong> all verticesend-<strong>for</strong>// construction stage – more details in Figure 3.5compute coverFactor <strong>for</strong> all verticeswhile E is not emptyadd <strong>the</strong> vertex u with highest coverFactor to Cremove all edges incident with u from Erecompute coverFactor <strong>for</strong> all verticesend-while// local optimization – more details in Figure 3.7 and Figure 3.8C ← Rebuild<strong>Cover</strong>(C)C ← Redundant<strong>Vertex</strong>Removal(C)if |C| < |bestC| <strong>the</strong>nbestC ← Cevaporate pheromone level globallyend-whilereturn bestCendFigure 3.1. <strong>An</strong> Overview of <strong>the</strong> AB–MVC <strong>Algorithm</strong>.