31.01.2014 Views

Version 5.0 The LEDA User Manual

Version 5.0 The LEDA User Manual

Version 5.0 The LEDA User Manual

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

int KURATOWSKI(graph& G, list& V, list& E,<br />

node array& deg)<br />

KURATOWKI computes a Kuratowski subdivision K<br />

of G as follows. V is the list of all nodes and subdivision<br />

points of K. For all v ∈ V the degree deg[v] is<br />

equal to 2 for subdivision points, 4 for all other nodes<br />

if K is a K 5 , and -3 (+3) for the nodes of the left<br />

(right) side if K is a K 3,3 . E is the list of all edges in<br />

the Kuratowski subdivision.<br />

list TRIANGULATE PLANAR MAP(graph& G)<br />

TRIANGULATE PLANAR MAP takes a directed<br />

graph G representing a planar map. It triangulates<br />

the faces of G by inserting additional edges. <strong>The</strong> list<br />

of inserted edges is returned.<br />

Precondition: G must be connected.<br />

<strong>The</strong> algorithm ([47]) has running time O(|V | + |E|).<br />

void FIVE COLOR(graph& G, node array& C)<br />

colors the nodes of G using 5 colors, more precisely,<br />

computes for every node v a color C[v] ∈ {0, . . . , 4},<br />

such that C[source(e)]! = C[target(e)] for every edge<br />

e. Precondition: G is planar. Remark: works also<br />

for many (sparse ?) non-planar graph.<br />

void INDEPENDENT SET(const graph& G, list& I)<br />

determines an independent set of nodes I in G. Every<br />

node in I has degree at most 9. If G is planar and has<br />

no parallel edges then I contains at least n/6 nodes.<br />

bool Is CCW Ordered(const graph& G, const node array& x,<br />

const node array& y)<br />

checks whether the cyclic adjacency list of any node<br />

v agrees with the counter-clockwise ordering of the<br />

neighbors of v around v defined by their geometric<br />

positions.<br />

bool SORT EDGES(graph& G, const node array& x,<br />

const node array& y)<br />

reorders all adjacency lists such the cyclic adjacency<br />

list of any node v agrees with the counter-clockwise<br />

order of v’s neighbors around v defined by their geometric<br />

positions. <strong>The</strong> function returns true if G is a<br />

plane map after the call.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!