Class MaximumMatching

java.lang.Object
  |
  +--MaximumMatching

public class MaximumMatching
extends java.lang.Object

The main program. This program will find the number of nodes in the maximum pairring in a graph. The graph is loaded from the file specified on the command-line.


Constructor Summary
MaximumMatching()
           
 
Method Summary
static java.lang.String calculateMaximumMatching(BipartiteGraph G)
          Calculates the maximum matching.
static void main(java.lang.String[] args)
          Starts the program.
static void usage()
          Prints a short usage message.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MaximumMatching

public MaximumMatching()
Method Detail

main

public static void main(java.lang.String[] args)
Starts the program. The program takes the following arguments:
Usage: java MaximumMatching <DATA> [OPTIONS]

A graph is read from the file DATA and the maximum matching is
reported along with the nodes in the matching. The program has the
following optional arguments:

-l, --latex GRAPH    Save the graph to the file graph-GRAPH-begin.tex
                     as an Xy-pic matrix. This is done just after
                     it is constructed. The graph is also saved to
                     graph-GRAPH-end.tex when the maximum
                     matching has been found.
-h, --help           Prints this message and exit with exitcode 0.
Parameters:
args - the command-line arguments.

usage

public static void usage()
Prints a short usage message.

calculateMaximumMatching

public static java.lang.String calculateMaximumMatching(BipartiteGraph G)
Calculates the maximum matching.
Parameters:
G - the graph that should be examined.
Returns:
a message that tells the user the number of nodes in the maximum matching along with the nodes themselves.