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.

list MIN WEIGHT PERFECT MATCHING T(const graph& G,<br />

const edge array& w,<br />

bool check = true,<br />

int heur = 2)<br />

computes a minimum-weight perfect matching M of the undirected graph<br />

G with weight function w. If G contains no perfect matching the empty<br />

set of edges is returned. If check is set to true, the optimality of M is<br />

checked internally. <strong>The</strong> heuristic used for the construction of an initial<br />

matching is determined by heur.<br />

template <br />

list MIN WEIGHT PERFECT MATCHING T(const graph& G,<br />

const edge array& w,<br />

node array& pot,<br />

array& BT , node array& b,<br />

bool check = true,<br />

int heur = 2)<br />

computes a minimum-weight perfect matching M of the undirected graph<br />

G with weight function w. If G contains no perfect matching the empty<br />

set of edges is returned. <strong>The</strong> function provides a proof of optimality in<br />

the form of a dual solution given by pot, BT and b. If check is set to<br />

true, the optimality of M is checked internally. <strong>The</strong> heuristic used for<br />

the construction of an initial matching is determined by heur.<br />

template <br />

bool CHECK MIN WEIGHT PERFECT MATCHING T(const graph& G,<br />

const edge array& w,<br />

const list& M,<br />

const node array& pot,<br />

const array& BT ,<br />

const node array& b)<br />

checks if M together with the dual solution represented by pot, BT and<br />

b are optimal. <strong>The</strong> function returns true iff M is a minimum-weight<br />

matching of G with weight function w.<br />

template

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

Saved successfully!

Ooh no, something went wrong!